[LinuxPPS] i915: disable interrupts before tearing down GEM state

gitweb.enneenne.com Git - linuxpps/rss log: Linus Torvalds <> webmaster at enneenne.com
Tue Oct 27 18:15:05 CET 2009


i915: disable interrupts before tearing down GEM state
    
    Reinette Chatre reports a frozen system (with blinking keyboard LEDs)
    when switching from graphics mode to the text console, or when
    suspending (which does the same thing). With netconsole, the oops
    turned out to be
    
    	BUG: unable to handle kernel NULL pointer dereference at 0000000000000084
    	IP: [<ffffffffa03ecaab>] i915_driver_irq_handler+0x26b/0xd20 [i915]
    
    and it's due to the i915_gem.c code doing drm_irq_uninstall() after
    having done i915_gem_idle(). And the i915_gem_idle() path will do
    
      i915_gem_idle() ->
        i915_gem_cleanup_ringbuffer() ->
          i915_gem_cleanup_hws() ->
            dev_priv->hw_status_page = NULL;
    
    but if an i915 interrupt comes in after this stage, it may want to
    access that hw_status_page, and gets the above NULL pointer dereference.
    
    And since the NULL pointer dereference happens from within an interrupt,
    and with the screen still in graphics mode, the common end result is
    simply a silently hung machine.
    
    Fix it by simply uninstalling the irq handler before idling rather than
    after. Fixes
    
        http://bugzilla.kernel.org/show_bug.cgi?id=13819
    
    Reported-and-tested-by: Reinette Chatre <reinette.chatre at intel.com>
    Acked-by: Jesse Barnes <jbarnes at virtuousgeek.org>
    Signed-off-by: Linus Torvalds <torvalds at linux-foundation.org>
    

  * [[D][1][H][2]] drivers/gpu/drm/i915/i915_gem.c

   [1]: http://gitweb.enneenne.com/?p=linuxpps;a=blobdiff;f=drivers/gpu/drm/i915/i915_gem.c;fp=drivers/gpu/drm/i915/i915_gem.c;h=80e5ba490dc28c8a15c4619865f4872f82a6625e;hp=7edb5b9d5792467a5515341cd5cb27c65573b785;hb=e6890f6f3dc2d9024a08b1a149d9bd5208eea350;hpb=7c8460db30dfd085ef3837c8fb02ecf2e718b983 (diff)
   [2]: http://gitweb.enneenne.com/?p=linuxpps;a=history;f=drivers/gpu/drm/i915/i915_gem.c;h=e6890f6f3dc2d9024a08b1a149d9bd5208eea350 (history)

URL: http://gitweb.enneenne.com/?p=linuxpps;a=commitdiff;h=e6890f6f3dc2d9024a08b1a149d9bd5208eea350



More information about the LinuxPPS mailing list