[PATCH] edid: Adjust rounding of max_clock

Alex Deucher alexdeucher at gmail.com
Fri Aug 20 07:35:02 PDT 2010


On Fri, Aug 20, 2010 at 8:51 AM, Chris Wilson <chris at chris-wilson.co.uk> wrote:
> A simple hack to accommodate various EDID who have detailed modes that
> exceed the EDID's max pixel clock. The pixel clock is only defined in
> units of 10MHz and often appears as the maximum pixel code of the
> detailed modes, rounded to the nearest 10MHz. Adjusting the max_clock to
> include an extra 5MHz prevents the parser from rejecting the detailed
> modes.
>
> The kernel uses the same fuzz and by including it in X we can use the
> same modes in X as for the console.
>
> Fixes:
>
>  Bug 23833 - X uses different refresh rate to that set by kernel module
>  https://bugs.freedesktop.org/show_bug.cgi?id=23833
>
> In the future, we will want to try harder to keep the KMS modes but at
> the same time we need to apply the restrictions as specified by the
> user's configuration, and need to fill in modes for fullscreen games on
> fixed-mode panels.
>
> Reported-and-tested-by: Fabio Pedretti <fabio.ped at libero.it>
> Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>

Looks reasonable to me.

Reviewed-by: Alex Deucher <alexdeucher at gmail.com>

> ---
>  hw/xfree86/ddc/interpret_edid.c |    2 +-
>  1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/hw/xfree86/ddc/interpret_edid.c b/hw/xfree86/ddc/interpret_edid.c
> index acb7efa..46958f7 100644
> --- a/hw/xfree86/ddc/interpret_edid.c
> +++ b/hw/xfree86/ddc/interpret_edid.c
> @@ -552,7 +552,7 @@ get_monitor_ranges(Uchar *c, struct monitor_ranges *r)
>     r->max_h = MAX_H;
>     r->max_clock = 0;
>     if(MAX_CLOCK != 0xff) /* is specified? */
> -       r->max_clock = MAX_CLOCK * 10;
> +       r->max_clock = MAX_CLOCK * 10 + 5;
>     if (HAVE_2ND_GTF) {
>        r->gtf_2nd_f = F_2ND_GTF;
>        r->gtf_2nd_c = C_2ND_GTF;
> --
> 1.7.1
>
> _______________________________________________
> xorg-devel at lists.x.org: X.Org development
> Archives: http://lists.x.org/archives/xorg-devel
> Info: http://lists.x.org/mailman/listinfo/xorg-devel
>


More information about the xorg-devel mailing list