Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2025-01-10 Thread Yannick FERTRE
Hi Sean, Tested-by: Yannick Fertre Thanks for this patch, Yannick Le 25/11/2024 à 14:49, Sean Nyekjaer a écrit : Check if the required pixel clock is in within .5% range of the desired pixel clock. This will match the requirement for HDMI where a .5% tolerance is allowed. Signed-off-by: Sea

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2025-01-06 Thread Raphael Gallais-Pou
On 11/25/24 14:49, Sean Nyekjaer wrote: > Check if the required pixel clock is in within .5% range of the > desired pixel clock. > This will match the requirement for HDMI where a .5% tolerance is allowed. > > Signed-off-by: Sean Nyekjaer > --- > drivers/gpu/drm/drm_modes.c | 34 +++

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-12-02 Thread Maxime Ripard
On Tue, Nov 26, 2024 at 02:30:53PM +0100, Sean Nyekjaer wrote: > Hi Maxime, > > On Tue, Nov 26, 2024 at 08:36:01AM +0100, Sean Nyekjaer wrote: > > Hi Maxime, > > > > [...] > > > > > > > We probably need some kunit tests here too. > > > > Good idea, will be my first :) > > > > Would somethin

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-26 Thread Maxime Ripard
On Tue, Nov 26, 2024 at 02:24:12PM +0200, Jani Nikula wrote: > On Tue, 26 Nov 2024, Maxime Ripard wrote: > > On Tue, Nov 26, 2024 at 12:16:34PM +0200, Jani Nikula wrote: > >> On Mon, 25 Nov 2024, Maxime Ripard wrote: > >> > I wonder about the naming though (and prototype). I doesn't really > >> >

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-26 Thread Sean Nyekjaer
Hi Maxime, On Tue, Nov 26, 2024 at 08:36:01AM +0100, Sean Nyekjaer wrote: > Hi Maxime, > [...] > > > > We probably need some kunit tests here too. > > Good idea, will be my first :) > Would something like this work? diff --git a/drivers/gpu/drm/tests/drm_hdmi_state_helper_test.c b/drivers

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-26 Thread Jani Nikula
On Tue, 26 Nov 2024, Maxime Ripard wrote: > On Tue, Nov 26, 2024 at 12:16:34PM +0200, Jani Nikula wrote: >> On Mon, 25 Nov 2024, Maxime Ripard wrote: >> > I wonder about the naming though (and prototype). I doesn't really >> > validates a mode, but rather makes sure that a given rate is a good >>

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-26 Thread Sean Nyekjaer
On Tue, Nov 26, 2024 at 01:09:10PM +0100, Maxime Ripard wrote: > On Tue, Nov 26, 2024 at 12:34:26PM +0100, Sean Nyekjaer wrote: > > Hi, > > > > On Tue, Nov 26, 2024 at 09:38:55AM +0100, Maxime Ripard wrote: > > > Hi, > > > > > > On Tue, Nov 26, 2024 at 08:36:00AM +0100, Sean Nyekjaer wrote: > > >

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-26 Thread Maxime Ripard
On Tue, Nov 26, 2024 at 12:16:34PM +0200, Jani Nikula wrote: > On Mon, 25 Nov 2024, Maxime Ripard wrote: > > I wonder about the naming though (and prototype). I doesn't really > > validates a mode, but rather makes sure that a given rate is a good > > approximation of a pixel clock. So maybe somet

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-26 Thread Maxime Ripard
On Tue, Nov 26, 2024 at 12:34:26PM +0100, Sean Nyekjaer wrote: > Hi, > > On Tue, Nov 26, 2024 at 09:38:55AM +0100, Maxime Ripard wrote: > > Hi, > > > > On Tue, Nov 26, 2024 at 08:36:00AM +0100, Sean Nyekjaer wrote: > > > On Mon, Nov 25, 2024 at 05:00:56PM +0100, Maxime Ripard wrote: > > > > On Mo

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-26 Thread Sean Nyekjaer
Hi, On Tue, Nov 26, 2024 at 09:38:55AM +0100, Maxime Ripard wrote: > Hi, > > On Tue, Nov 26, 2024 at 08:36:00AM +0100, Sean Nyekjaer wrote: > > On Mon, Nov 25, 2024 at 05:00:56PM +0100, Maxime Ripard wrote: > > > On Mon, Nov 25, 2024 at 02:49:26PM +0100, Sean Nyekjaer wrote: > > > > Check if the

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-26 Thread Jani Nikula
On Mon, 25 Nov 2024, Maxime Ripard wrote: > I wonder about the naming though (and prototype). I doesn't really > validates a mode, but rather makes sure that a given rate is a good > approximation of a pixel clock. So maybe something like > drm_mode_check_pixel_clock? Quoting myself from a few we

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-26 Thread Maxime Ripard
On Tue, Nov 26, 2024 at 09:47:17AM +0100, Raphael Gallais-Pou wrote: > > On 11/26/24 08:36, Sean Nyekjaer wrote: > > Hi Maxime, > > > > On Mon, Nov 25, 2024 at 05:00:56PM +0100, Maxime Ripard wrote: > >> Hi Sean, > >> > >> On Mon, Nov 25, 2024 at 02:49:26PM +0100, Sean Nyekjaer wrote: > >>> Check

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-26 Thread Raphael Gallais-Pou
On 11/26/24 08:36, Sean Nyekjaer wrote: > Hi Maxime, > > On Mon, Nov 25, 2024 at 05:00:56PM +0100, Maxime Ripard wrote: >> Hi Sean, >> >> On Mon, Nov 25, 2024 at 02:49:26PM +0100, Sean Nyekjaer wrote: >>> Check if the required pixel clock is in within .5% range of the >>> desired pixel clock. >>>

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-26 Thread Maxime Ripard
Hi, On Tue, Nov 26, 2024 at 08:36:00AM +0100, Sean Nyekjaer wrote: > On Mon, Nov 25, 2024 at 05:00:56PM +0100, Maxime Ripard wrote: > > On Mon, Nov 25, 2024 at 02:49:26PM +0100, Sean Nyekjaer wrote: > > > Check if the required pixel clock is in within .5% range of the > > > desired pixel clock. >

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-25 Thread Sean Nyekjaer
Hi Maxime, On Mon, Nov 25, 2024 at 05:00:56PM +0100, Maxime Ripard wrote: > Hi Sean, > > On Mon, Nov 25, 2024 at 02:49:26PM +0100, Sean Nyekjaer wrote: > > Check if the required pixel clock is in within .5% range of the > > desired pixel clock. > > This will match the requirement for HDMI where a

Re: [PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-25 Thread Maxime Ripard
Hi Sean, On Mon, Nov 25, 2024 at 02:49:26PM +0100, Sean Nyekjaer wrote: > Check if the required pixel clock is in within .5% range of the > desired pixel clock. > This will match the requirement for HDMI where a .5% tolerance is allowed. > > Signed-off-by: Sean Nyekjaer > --- > drivers/gpu/drm/

[PATCH v2 1/3] drm/modes: introduce drm_mode_validate_mode() helper function

2024-11-25 Thread Sean Nyekjaer
Check if the required pixel clock is in within .5% range of the desired pixel clock. This will match the requirement for HDMI where a .5% tolerance is allowed. Signed-off-by: Sean Nyekjaer --- drivers/gpu/drm/drm_modes.c | 34 ++ include/drm/drm_modes.h | 2 +