1. 26 1月, 2011 1 次提交
  2. 09 12月, 2010 1 次提交
  3. 06 10月, 2010 1 次提交
  4. 10 8月, 2010 2 次提交
  5. 21 7月, 2010 2 次提交
    • C
      drm: Return EBUSY if the framebuffer is unbound when flipping. · 90c1efdd
      Chris Wilson 提交于
      It looks like there is a race condition between unbinding a framebuffer
      on a hotplug event and user space trying to flip:
      
      BUG: unable to handle kernel NULL pointer dereference at 0000000000000058
      IP: [<ffffffffa008c7d3>] intel_crtc_page_flip+0xc9/0x39c [i915]
      PGD 114724067 PUD 1145bd067 PMD 0
      Oops: 0000 [#1] SMP
      Pid: 10954, comm: X Not tainted 2.6.35-rc5_stable_20100714+ #1
      P5Q-EM/P5Q-EM
      RIP: 0010:[<ffffffffa008c7d3>]  [<ffffffffa008c7d3>]
      intel_crtc_page_flip+0xc9/0x39c [i915]
      RSP: 0018:ffff880114927cc8  EFLAGS: 00010282
      RAX: 0000000000000000 RBX: ffff88012df48320 RCX: ffff88010c945600
      RDX: ffff880001a109c8 RSI: ffff88010c945840 RDI: ffff88012df48320
      RBP: ffff880114927d18 R08: ffff88012df48280 R09: ffff88012df48320
      R10: 0000000003c2e0b0 R11: 0000000000003246 R12: ffff88010c945840
      R13: ffff88012df48000 R14: 0000000000000060 R15: ffff88012dbb8000
      FS:  00007f9e6078e830(0000) GS:ffff880001a00000(0000)
      knlGS:0000000000000000
      CS:  0010 DS: 0000 ES: 0000 CR0: 000000008005003b
      CR2: 0000000000000058 CR3: 00000001177a8000 CR4: 00000000000406f0
      DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
      DR3: 0000000000000000 DR6: 00000000ffff0ff0 DR7: 0000000000000400
      Process X (pid: 10954, threadinfo ffff880114926000, task
      ffff88012a4a1690)
      Stack:
       ffff88010c945600 ffff880115b176c0 ffff88012db10000 0000000000000246
      <0> fffffff40006101c ffff88010c945600 00000000ffffffea ffff88010c945600
      <0> ffff88012df48320 ffff88011b4b6780 ffff880114927d78 ffffffffa003bd0e
      Call Trace:
       [<ffffffffa003bd0e>] drm_mode_page_flip_ioctl+0x1bc/0x214 [drm]
       [<ffffffffa00311fc>] drm_ioctl+0x25e/0x35e [drm]
       [<ffffffffa003bb52>] ? drm_mode_page_flip_ioctl+0x0/0x214 [drm]
       [<ffffffff810f1c3c>] vfs_ioctl+0x2a/0x9e
       [<ffffffff810f227e>] do_vfs_ioctl+0x531/0x565
       [<ffffffff810f2307>] sys_ioctl+0x55/0x77
       [<ffffffff810e56d6>] ? sys_read+0x47/0x6f
       [<ffffffff81002a2b>] system_call_fastpath+0x16/0x1b
      Code: 45 d4 f4 ff ff ff 0f 84 e0 02 00 00 48 8b 4d b0 49 8d 9d 20 03 00 00 48
      89 df 49 89 4c 24 38 49 8b 07 49 89 44 24 20 49 8b 47 20 <48> 8b 40 58 49 c7 04
      24 00 00 00 00 49 c7 44 24 18 a9 a5 08 a0
      RIP  [<ffffffffa008c7d3>] intel_crtc_page_flip+0xc9/0x39c [i915]
       RSP <ffff880114927cc8>
      CR2: 0000000000000058
      
      References:
      
        Bug 28811 - [page-flipping] GPU hang when modeset after unplugging
                    another monitor (under compiz)
        https://bugs.freedesktop.org/show_bug.cgi?id=28811Signed-off-by: NChris Wilson <chris@chris-wilson.co.uk>
      Reviewed-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      90c1efdd
    • B
      drm: add "auto" dithering method · 92897b5c
      Ben Skeggs 提交于
      There's no convenient/reliable way for drivers to both obey the dithering
      mode property, and to be able to attempt to provide a good default in all
      cases.
      
      This commit adds an "auto" method to the property which drivers can default
      to if they wish, whilst still allowing the user to override the choice as
      they do now.
      Signed-off-by: NBen Skeggs <bskeggs@redhat.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      92897b5c
  6. 16 7月, 2010 1 次提交
  7. 08 6月, 2010 1 次提交
  8. 07 4月, 2010 2 次提交
    • D
      drm/kms/fb: separate fbdev connector list from core drm connectors · 0b4c0f3f
      Dave Airlie 提交于
      This breaks the connection between the core drm connector list
      and the fbdev connector usage, and allows them to become disjoint
      in the future. It also removes the untype void* that was in the
      connector struct to support this.
      
      All connectors are added to the fbdev now but this could be
      changed in the future.
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      0b4c0f3f
    • D
      drm/fb: fix fbdev object model + cleanup properly. · 38651674
      Dave Airlie 提交于
      The fbdev layer in the kms code should act like a consumer of the kms services and avoid having relying on information being store in the kms core structures in order for it to work.
      
      This patch
      
      a) removes the info pointer/psuedo palette from the core drm_framebuffer structure and moves it to the fbdev helper layer, it also removes the core drm keeping a list of kernel kms fbdevs.
      b) migrated all the fb helper functions out of the crtc helper file into the fb helper file.
      c) pushed the fb probing/hotplug control into the driver
      d) makes the surface sizes into a structure for ease of passing
      This changes the intel/radeon/nouveau drivers to use the new helper.
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      38651674
  9. 06 4月, 2010 1 次提交
  10. 30 3月, 2010 1 次提交
    • T
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking... · 5a0e3ad6
      Tejun Heo 提交于
      include cleanup: Update gfp.h and slab.h includes to prepare for breaking implicit slab.h inclusion from percpu.h
      
      percpu.h is included by sched.h and module.h and thus ends up being
      included when building most .c files.  percpu.h includes slab.h which
      in turn includes gfp.h making everything defined by the two files
      universally available and complicating inclusion dependencies.
      
      percpu.h -> slab.h dependency is about to be removed.  Prepare for
      this change by updating users of gfp and slab facilities include those
      headers directly instead of assuming availability.  As this conversion
      needs to touch large number of source files, the following script is
      used as the basis of conversion.
      
        http://userweb.kernel.org/~tj/misc/slabh-sweep.py
      
      The script does the followings.
      
      * Scan files for gfp and slab usages and update includes such that
        only the necessary includes are there.  ie. if only gfp is used,
        gfp.h, if slab is used, slab.h.
      
      * When the script inserts a new include, it looks at the include
        blocks and try to put the new include such that its order conforms
        to its surrounding.  It's put in the include block which contains
        core kernel includes, in the same order that the rest are ordered -
        alphabetical, Christmas tree, rev-Xmas-tree or at the end if there
        doesn't seem to be any matching order.
      
      * If the script can't find a place to put a new include (mostly
        because the file doesn't have fitting include block), it prints out
        an error message indicating which .h file needs to be added to the
        file.
      
      The conversion was done in the following steps.
      
      1. The initial automatic conversion of all .c files updated slightly
         over 4000 files, deleting around 700 includes and adding ~480 gfp.h
         and ~3000 slab.h inclusions.  The script emitted errors for ~400
         files.
      
      2. Each error was manually checked.  Some didn't need the inclusion,
         some needed manual addition while adding it to implementation .h or
         embedding .c file was more appropriate for others.  This step added
         inclusions to around 150 files.
      
      3. The script was run again and the output was compared to the edits
         from #2 to make sure no file was left behind.
      
      4. Several build tests were done and a couple of problems were fixed.
         e.g. lib/decompress_*.c used malloc/free() wrappers around slab
         APIs requiring slab.h to be added manually.
      
      5. The script was run on all .h files but without automatically
         editing them as sprinkling gfp.h and slab.h inclusions around .h
         files could easily lead to inclusion dependency hell.  Most gfp.h
         inclusion directives were ignored as stuff from gfp.h was usually
         wildly available and often used in preprocessor macros.  Each
         slab.h inclusion directive was examined and added manually as
         necessary.
      
      6. percpu.h was updated not to include slab.h.
      
      7. Build test were done on the following configurations and failures
         were fixed.  CONFIG_GCOV_KERNEL was turned off for all tests (as my
         distributed build env didn't work with gcov compiles) and a few
         more options had to be turned off depending on archs to make things
         build (like ipr on powerpc/64 which failed due to missing writeq).
      
         * x86 and x86_64 UP and SMP allmodconfig and a custom test config.
         * powerpc and powerpc64 SMP allmodconfig
         * sparc and sparc64 SMP allmodconfig
         * ia64 SMP allmodconfig
         * s390 SMP allmodconfig
         * alpha SMP allmodconfig
         * um on x86_64 SMP allmodconfig
      
      8. percpu.h modifications were reverted so that it could be applied as
         a separate patch and serve as bisection point.
      
      Given the fact that I had only a couple of failures from tests on step
      6, I'm fairly confident about the coverage of this conversion patch.
      If there is a breakage, it's likely to be something in one of the arch
      headers which should be easily discoverable easily on most builds of
      the specific arch.
      Signed-off-by: NTejun Heo <tj@kernel.org>
      Guess-its-ok-by: NChristoph Lameter <cl@linux-foundation.org>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Lee Schermerhorn <Lee.Schermerhorn@hp.com>
      5a0e3ad6
  11. 08 1月, 2010 1 次提交
  12. 04 12月, 2009 2 次提交
  13. 02 12月, 2009 1 次提交
  14. 18 11月, 2009 1 次提交
  15. 06 11月, 2009 1 次提交
  16. 05 10月, 2009 1 次提交
  17. 25 9月, 2009 1 次提交
    • D
      drm/kms: start adding command line interface using fb. · d50ba256
      Dave Airlie 提交于
      [note this requires an fb patch posted to linux-fbdev-devel already]
      
      This uses the normal video= command line option to control the kms
      output setup at boot time. It is used to override the autodetection
      done by kms.
      
      video= normally takes a framebuffer as the first parameter, in kms
      it will take a connector name, DVI-I-1, or LVDS-1 etc. If no output
      connector is specified the mode string will apply to all connectors.
      
      The mode specification used will match down the probed modes, and if
      no mode is found it will add a CVT mode that matches.
      
      video=1024x768 - all connectors match a 1024x768 mode or add a CVT on
      video=VGA-1:1024x768, VGA-1 connector gets mode only.
      
      The same strings as used in current fb modedb.c are used, except I've
      added three more letters, e, D, d, e = enable, D = enable Digital,
      d = disable, which allow a connector to be forced into a certain state.
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      d50ba256
  18. 07 9月, 2009 1 次提交
  19. 19 8月, 2009 2 次提交
  20. 13 8月, 2009 1 次提交
  21. 04 8月, 2009 5 次提交
  22. 04 6月, 2009 1 次提交
    • K
      drm: Hook up DPMS property handling in drm_crtc.c. Add drm_helper_connector_dpms. · c9fb15f6
      Keith Packard 提交于
      Making the drm_crtc.c code recognize the DPMS property and invoke the
      connector->dpms function doesn't remove any capability from the driver while
      reducing code duplication.
      
      That just highlighted the problem with the existing DPMS functions which
      could turn off the connector, but failed to turn off any relevant crtcs. The
      new drm_helper_connector_dpms function manages all of that, using the
      drm_helper-specific crtc and encoder dpms functions, automatically computing
      the appropriate DPMS level for each object in the system.
      
      This fixes the current troubles in the i915 driver which left PLLs, pipes
      and planes running while in DPMS_OFF mode or even while they were unused.
      Signed-off-by: NKeith Packard <keithp@keithp.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      c9fb15f6
  23. 20 2月, 2009 1 次提交
  24. 22 1月, 2009 1 次提交
    • J
      drm: create mode_config idr lock · ad2563c2
      Jesse Barnes 提交于
      Create a separate mode_config IDR lock for simplicity.  The core DRM
      config structures (connector, mode, etc. lists) are still protected by
      the mode_config mutex, but the CRTC IDR (used for the various identifier
      IDs) is now protected by the mode_config idr_mutex.  Simplifies the
      locking a bit and removes a warning.
      
      All objects are protected by the config mutex, we may in the future,
      split the object further to have reference counts.
      Signed-off-by: NJesse Barnes <jbarnes@virtuousgeek.org>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      ad2563c2
  25. 08 1月, 2009 1 次提交
  26. 29 12月, 2008 3 次提交
    • K
      drm: drop DRM_IOCTL_MODE_REPLACEFB, add+remove works just as well. · 0c7c2664
      Kristian H�gsberg 提交于
      The replace fb ioctl replaces the backing buffer object for a modesetting
      framebuffer object.  This can be acheived by just creating a new
      framebuffer backed by the new buffer object, setting that for the crtcs
      in question and then removing the old framebuffer object.
      Signed-off-by: NKristian Hogsberg <krh@redhat.com>
      Acked-by: NJakob Bornecrantz <jakob@vmware.com>
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      0c7c2664
    • J
      drm: sanitise drm modesetting API + remove unused hotplug · e0c8463a
      Jakob Bornecrantz 提交于
      The initially merged modesetting API has some uglies in it, this
      cleans up the struct members and ioctl ordering for initial submission.
      
      It also removes the unneeded hotplug infrastructure.
      
      airlied:- I've pulled this patch in from git modesetting-gem tree.
      Signed-off-by: NDave Airlie <airlied@redhat.com>
      e0c8463a
    • 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