1. 18 1月, 2008 1 次提交
  2. 15 1月, 2008 3 次提交
  3. 12 1月, 2008 2 次提交
    • J
      ps3fb: fix deadlock on kexec() · 8dab6376
      Jeremy Kerr 提交于
      Since the introduction of the acquire_console_sem calls in
      0333d835, kexecing can cause the
      kernel to deadlock:
      
       ps3fb_shutdown()
        -> unregister_framebuffer()
        -> fb_notifier_call_chain(FB_EVENT_FB_UNBIND)
        -> fbcon_fb_unbind()
        -> unbind_con_driver()
        -> bind_con_driver()
      	[ acquires console_sem ]
        -> fbcon_deinit()
        -> fbops->fb_release(newinfo, 0)
        -> ps3fb_release()
        -> ps3fb_sync()
      	[ acquires console_sem ]
      
      This change avoids the deadlock by moving the acquire_console_sem()
      out of ps3fb_sync(), and puts it into the two other callsites, leaving
      ps3fb_release() to call ps3fb_sync() without the console semaphore.
      
      [Geert]
        - Corrected call sequence above
        - ps3fb_release() may be called with and without console_sem held. This is an
          inconsistency that should be fixed at the fb level, but for now, try to
          acquire console_sem in ps3fb_release().
      
          I think it's safer to let ps3fb_release() try to acquire console_sem and
          not refresh the screen if it fails, than to call ps3fb_sync() without
          holding console_sem, as ps3fb_par may be modified at the same time, causing
          crashes or lockups.
      
          Besides, ps3fb_release() only calls ps3fb_sync() to refresh the screen
          when display flipping is disabled, which is an uncommon case (except during
          shutdown/kexec).
      Signed-off-by: NJeremy Kerr <jk@ozlabs.org>
      Signed-off-by: NGeert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      8dab6376
    • J
      ps3fb: prevent use after free of fb_info · ba21611c
      Jeremy Kerr 提交于
      In ps3fb_shutdown, freeing the framebuffer will cause fb_info (in
      dev->core.driver_data) to be free()ed, which we potentially access
      from the ps3fbd kthread.
      
      This change frees the framebuffer after stopping the ps3fbd kthread.
      Signed-off-by: NJeremy Kerr <jk@ozlabs.org>
      Signed-off-by: NGeert Uytterhoeven <Geert.Uytterhoeven@sonycom.com>
      Signed-off-by: NLinus Torvalds <torvalds@linux-foundation.org>
      ba21611c
  4. 20 12月, 2007 2 次提交
  5. 30 11月, 2007 5 次提交
  6. 27 11月, 2007 1 次提交
  7. 23 11月, 2007 1 次提交
  8. 15 11月, 2007 7 次提交
  9. 09 11月, 2007 1 次提交
  10. 31 10月, 2007 1 次提交
  11. 30 10月, 2007 2 次提交
  12. 28 10月, 2007 1 次提交
  13. 20 10月, 2007 7 次提交
  14. 19 10月, 2007 5 次提交
  15. 18 10月, 2007 1 次提交