1. 21 10月, 2008 1 次提交
    • J
      powerpc/spufs: Use state_mutex for switch_log locking, and prevent multiple openers · f5ed0eb6
      Jeremy Kerr 提交于
      Currently, we use ctx->mapping_lock and ctx->switch_log->lock for the
      context switch log. The mapping lock only prevents concurrent open()s,
      so we require the switch_lock->lock for reads.
      
      Since writes to the switch log buffer occur on context switches, we're
      better off synchronising with the state_mutex, which is held during a
      switch. Since we're serialised througout the buffer reads and writes,
      we can use the state mutex to protect open and release too, and
      can now kfree() the log buffer on release. This allows us to perform
      the switch log notify without taking any extra locks.
      
      Because the buffer is only present while the file is open, we can use
      it to prevent multiple simultaneous openers.
      Signed-off-by: NJeremy Kerr <jk@ozlabs.org>
      f5ed0eb6
  2. 25 7月, 2008 1 次提交
  3. 09 7月, 2008 5 次提交
  4. 30 6月, 2008 1 次提交
  5. 15 5月, 2008 1 次提交
  6. 30 4月, 2008 1 次提交
  7. 19 4月, 2008 1 次提交
  8. 01 4月, 2008 1 次提交
  9. 28 3月, 2008 1 次提交
  10. 27 2月, 2008 1 次提交
    • J
      [POWERPC] spufs: fix context destruction during psmap fault · d5883137
      Jeremy Kerr 提交于
      We have a small window where a spu context may be destroyed while
      we're servicing a page fault (from another thread) to the context's
      problem state mapping.
      
      After we up_read() the mmap_sem, it's possible that the context is
      destroyed by its owning thread, and so the later references to ctx
      are invalid. This can maifest as a deadlock on the (now free()-ed)
      context state mutex.
      
      This change adds a reference to the context before we release the
      mmap_sem, so that the context cannot be destroyed.
      Signed-off-by: NJeremy Kerr <jk@ozlabs.org>
      d5883137
  11. 09 2月, 2008 2 次提交
  12. 08 2月, 2008 1 次提交
  13. 06 2月, 2008 1 次提交
  14. 21 12月, 2007 5 次提交
  15. 20 10月, 2007 1 次提交
  16. 26 9月, 2007 1 次提交
  17. 19 9月, 2007 7 次提交
  18. 23 7月, 2007 1 次提交
  19. 22 7月, 2007 1 次提交
  20. 21 7月, 2007 4 次提交
  21. 03 7月, 2007 2 次提交