1. 20 3月, 2012 1 次提交
    • C
      drm: allow loading an EDID as firmware to override broken monitor · da0df92b
      Carsten Emde 提交于
      Broken monitors and/or broken graphic boards may send erroneous or no
      EDID data. This also applies to broken KVM devices that are unable to
      correctly forward the EDID data of the connected monitor but invent
      their own fantasy data.
      
      This patch allows to specify an EDID data set to be used instead of
      probing the monitor for it. It contains built-in data sets of frequently
      used screen resolutions. In addition, a particular EDID data set may be
      provided in the /lib/firmware directory and loaded via the firmware
      interface. The name is passed to the kernel as module parameter of the
      drm_kms_helper module either when loaded
        options drm_kms_helper edid_firmware=edid/1280x1024.bin
      or as kernel commandline parameter
        drm_kms_helper.edid_firmware=edid/1280x1024.bin
      
      It is also possible to restrict the usage of a specified EDID data set
      to a particular connector. This is done by prepending the name of the
      connector to the name of the EDID data set using the syntax
        edid_firmware=[<connector>:]<edid>
      such as, for example,
        edid_firmware=DVI-I-1:edid/1920x1080.bin
      in which case no other connector will be affected.
      
      The built-in data sets are
      Resolution    Name
      --------------------------------
      1024x768      edid/1024x768.bin
      1280x1024     edid/1280x1024.bin
      1680x1050     edid/1680x1050.bin
      1920x1080     edid/1920x1080.bin
      
      They are ignored, if a file with the same name is available in the
      /lib/firmware directory.
      
      The built-in EDID data sets are based on standard timings that may not
      apply to a particular monitor and even crash it. Ideally, EDID data of
      the connected monitor should be used. They may be obtained through the
      drm/cardX/cardX-<connector>/edid entry in the /sys/devices PCI directory
      of a correctly working graphics adapter.
      
      It is even possible to specify the name of an EDID data set on-the-fly
      via the /sys/module interface, e.g.
      echo edid/myedid.bin >/sys/module/drm_kms_helper/parameters/edid_firmware
      The new screen mode is considered when the related kernel function is
      called for the first time after the change. Such calls are made when the
      X server is started or when the display settings dialog is opened in an
      already running X server.
      Signed-off-by: NCarsten Emde <C.Emde@osadl.org>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      da0df92b
  2. 22 9月, 2011 1 次提交
    • W
      drm: support routines for HDMI/DP ELD · 76adaa34
      Wu Fengguang 提交于
      ELD (EDID-Like Data) describes to the HDMI/DP audio driver the audio
      capabilities of the plugged monitor.
      
      This adds drm_edid_to_eld() for converting EDID to ELD. The converted
      ELD will be saved in a new drm_connector.eld[128] data field. This is
      necessary because the graphics driver will need to fixup some of the
      data fields (eg. HDMI/DP connection type, AV sync delay) before writing
      to the hardware ELD buffer. drm_av_sync_delay() will help the graphics
      drivers dynamically compute the AV sync delay for fixing-up the ELD.
      
      ELD selection policy: it's possible for one encoder to be associated
      with multiple connectors (ie. monitors), in which case the first found
      ELD will be returned by drm_select_eld(). This policy may not be
      suitable for all users, but let's start it simple first.
      
      The impact of ELD selection policy: assume there are two monitors, one
      supports stereo playback and the other has 8-channel output; cloned
      display mode is used, so that the two monitors are associated with the
      same internal encoder. If only the stereo playback capability is reported,
      the user won't be able to start 8-channel playback; if the 8-channel ELD
      is reported, then user space applications may send 8-channel samples
      down, however the user may actually be listening to the 2-channel
      monitor and not connecting speakers to the 8-channel monitor.
      
      According to James, many TVs will either refuse the display anything or
      pop-up an OSD warning whenever they receive hdmi audio which they cannot
      handle. Eventually we will require configurability and/or per-monitor
      audio control even when the video is cloned.
      
      CC: Zhao Yakui <yakui.zhao@intel.com>
      CC: Wang Zhenyu <zhenyu.z.wang@intel.com>
      CC: Jeremy Bush <contractfrombelow@gmail.com>
      CC: Christopher White <c.white@pulseforce.com>
      CC: Pierre-Louis Bossart <pierre-louis.bossart@intel.com>
      CC: Paul Menzel <paulepanter@users.sourceforge.net>
      CC: James Cloos <cloos@jhcloos.com>
      CC: Chris Wilson <chris@chris-wilson.co.uk>
      Signed-off-by: NBen Skeggs <bskeggs@redhat.com>
      Signed-off-by: NWu Fengguang <fengguang.wu@intel.com>
      Signed-off-by: NKeith Packard <keithp@keithp.com>
      76adaa34
  3. 28 4月, 2011 2 次提交
  4. 10 8月, 2010 1 次提交
  5. 18 5月, 2010 1 次提交
    • D
      drm_edid: There should be 6 Standard Timings · 96525a2f
      Dan Carpenter 提交于
      Smatch complained that we initialize 6 elements in add_detailed_modes()
      but the timings[] array is declared with 5 elements.  Adam Jackson
      verified that 6 is the correct number of timings.
      
      On Mon, May 10, 2010 at 12:08:24PM -0400, Adam Jackson wrote:
      > > >                 struct std_timing timings[5];
      > > >                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
      >
      > This decl is wrong, should be 6.  From the 1.4 spec:
      >
      > "Six additional Standard Timings may be listed as a display descriptor
      > (tag #FAh)."
      >
      > The 1.3 spec is a little less explicit about it, but does show 6
      > standard timing codes in the 0xFA detailed subblock, terminated by 0x0A
      > in the 18th byte.  I don't have the docs for 1.2 or earlier, but we're
      > paranoid enough about not adding broken timings that we should be fine.
      
      This patch is basically a clean up, because timings[] is declared inside
      a union and increasing the number of elements here doesn't change the
      overall size of the union.
      Signed-off-by: NDan Carpenter <error27@gmail.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      96525a2f
  6. 06 4月, 2010 1 次提交
  7. 09 2月, 2010 1 次提交
  8. 04 12月, 2009 2 次提交
  9. 24 6月, 2009 1 次提交
  10. 19 6月, 2009 1 次提交
  11. 11 3月, 2009 1 次提交
  12. 25 2月, 2009 1 次提交
  13. 29 12月, 2008 1 次提交
    • D
      DRM: add mode setting support · f453ba04
      Dave Airlie 提交于
      Add mode setting support to the DRM layer.
      
      This is a fairly big chunk of work that allows DRM drivers to provide
      full output control and configuration capabilities to userspace.  It was
      motivated by several factors:
        - the fb layer's APIs aren't suited for anything but simple
          configurations
        - coordination between the fb layer, DRM layer, and various userspace
          drivers is poor to non-existent (radeonfb excepted)
        - user level mode setting drivers makes displaying panic & oops
          messages more difficult
        - suspend/resume of graphics state is possible in many more
          configurations with kernel level support
      
      This commit just adds the core DRM part of the mode setting APIs.
      Driver specific commits using these new structure and APIs will follow.
      
      Co-authors: Jesse Barnes <jbarnes@virtuousgeek.org>, Jakob Bornecrantz <jakob@tungstengraphics.com>
      Contributors: Alan Hourihane <alanh@tungstengraphics.com>, Maarten Maathuis <madman2003@gmail.com>
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NEric Anholt <eric@anholt.net>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      f453ba04