All of lore.kernel.org
 help / color / mirror / Atom feed
From: Ian Pilcher <arequipeno@gmail.com>
To: dri-devel@lists.freedesktop.org
Subject: Enhancing EDID quirk functionality
Date: Thu, 19 Apr 2012 14:16:55 -0500	[thread overview]
Message-ID: <jmpob8$9v4$1@dough.gmane.org> (raw)

Greetings all!

I recently discovered that my nice 1900x1200 display is horribly
confused by the InfoFrame functionality that was added to the nouveau
driver in Linux 3.3.  Additional testing has shown that it has the same
problem with the i915 driver and NVIDIA's proprietary driver.

NVIDIA's Windows 7 driver does not exhibit the problem, but it appears
that the problem was seen a few years ago on Windows Vista.  See this
Red Hat Bugzilla for all the gory details:

  https://bugzilla.redhat.com/show_bug.cgi?id=806091

Ben Skeggs suggested that the proper way to proceed is an EDID quirk
that will disable InfoFrames by causing drm_detect_hdmi_monitor() return
false.  I'm thinking of EDID_QUIRK_DISABLE_HDMI as the symbolic name for
this quirk.

After looking through drm_edid.c and noticing that my display appears to
be reporting non-existent audio functionality, I believe that quirk
which disables HDMI audio functionality (by causing
drm_detect_monitor_audio() to return false) might also be useful.

Before I start turning things off, however, I think it's really
important to provide users with a way to override these quirks.  (Who's
to say there isn't a variant of my display out there somewhere with
exactly the same EDID that actually does have speakers?)  And wouldn't
it be extremely useful for users to be able to add EDID quirks on the
kernel command line -- for testing/workaround purposes?

I'm thinking of a syntax like:

  drm.edid_quirk=ACR:44358:0x01,ACR:2423:0x20

This would be parsed into a separate quirks list (edid_user_quirk_list?)
which could add new quirks or override built-in quirks (by changing
edid_get_quirks()).

Parsing the quirks will be a bit of a pain.  I'm new to writing kernel
code, so pointers to any appropriate helper functions or examples of
parsing somewhat complex strings in-kernel would be appreciated.

The other prerequisite, IMO, is for the kernel to log the displays that
it detects, so that users know what the first two fields of a quirk
should be.  (Currently, the easiest place to get this is the X log.)  I
tried adding this logging to drm_get_edid(), but the results were overly
verbose; apparently that function gets called fairly frequently.  Is
there a better place to log a newly detected display?

So my specific questions at this time are:

1.  Any objections to the functionality or approach that I've outlined
    above?

2.  How should I go about parsing a "quirk string"?  (Pointers to helper
    functions and/or examples of similar parsing requested.)

3.  What is the best place at which to log newly detected displays?

Thanks!

-- 
========================================================================
Ian Pilcher                                         arequipeno@gmail.com
"If you're going to shift my paradigm ... at least buy me dinner first."
========================================================================

             reply	other threads:[~2012-04-19 19:20 UTC|newest]

Thread overview: 32+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-19 19:16 Ian Pilcher [this message]
2012-04-24  9:07 ` Enhancing EDID quirk functionality Lars-Peter Clausen
2012-04-24 19:00   ` Ian Pilcher
2012-05-03 18:01     ` Ian Pilcher
2012-05-03 19:42       ` Adam Jackson
2012-05-07 19:50         ` Ian Pilcher
2012-05-07 21:38           ` Adam Jackson
2012-08-10  4:23             ` Ian Pilcher
2012-08-10  4:23               ` [PATCH] drm: EDID quirk improvements Ian Pilcher
2012-08-10 18:44                 ` Ian Pilcher
2012-08-10 18:44                   ` Ian Pilcher
2012-08-11  8:31                     ` Paul Menzel
2012-08-11 15:38                       ` Ian Pilcher
2012-08-11 19:52                         ` Paul Menzel
2012-08-11 19:37                     ` Paul Menzel
2012-08-12  4:30                       ` [PATCH v3 0/2] Enhanced EDID quirk functionality Ian Pilcher
2012-08-12  4:30                         ` [PATCH v3 1/2] drm: Add user-defined EDID quirks capability Ian Pilcher
2012-08-12 15:39                           ` Paul Menzel
2012-08-12  4:30                         ` [PATCH v3 2/2] drm: Add EDID quirks to disable HDMI audio and InfoFrames Ian Pilcher
2012-08-12 15:45                           ` Paul Menzel
2012-08-12  6:58                         ` [PATCH v3 0/2] Enhanced EDID quirk functionality Paul Menzel
2012-08-12 20:07                           ` [PATCH v4 0/3] " Ian Pilcher
2012-08-12 20:07                             ` [PATCH v4 1/3] drm: Add user-defined EDID quirks capability Ian Pilcher
2012-08-14 15:13                               ` Paul Menzel
2012-08-14 15:45                                 ` Ian Pilcher
2012-08-15  6:41                                   ` Paul Menzel
2012-08-12 20:07                             ` [PATCH v4 2/3] drm: Add EDID quirks to disable HDMI audio and InfoFrames Ian Pilcher
2012-08-12 20:08                             ` [PATCH v4 3/3] drm: Add EDID quirk for LG L246WP Ian Pilcher
2012-09-04 14:52                               ` Paul Menzel
2012-08-12 21:29                             ` [PATCH v4 0/3] Enhanced EDID quirk functionality Christian König
2012-08-12 21:31                             ` Paul Menzel
2012-08-13 14:39                               ` Ian Pilcher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='jmpob8$9v4$1@dough.gmane.org' \
    --to=arequipeno@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.