1. 26 1月, 2008 1 次提交
    • O
      IB/fmr_pool: Flush serial numbers can get out of sync · a656eb75
      Olaf Kirch 提交于
      Normally, the serial numbers for flush requests and flushes executed
      for an FMR pool should be in sync.
      
      However, if the FMR pool flushes dirty FMRs because the
      dirty_watermark was reached, we wake up the cleanup thread and let it
      do its stuff.  As a side effect, the cleanup thread increments
      pool->flush_ser, which leaves it one higher than pool->req_ser.  The
      next time the user calls ib_flush_fmr_pool(), the cleanup thread will
      be woken up, but ib_flush_fmr_pool() won't wait for the flush to
      complete because flush_ser is already past req_ser.  This means the
      FMRs that the user expects to be flushed may not have all been flushed
      when the function returns.
      
      Fix this by telling the cleanup thread to do work exclusively by
      incrementing req_ser, and by moving the comparison of dirty_len and
      dirty_watermark into ib_fmr_pool_unmap().
      Signed-off-by: NOlaf Kirch <olaf.kirch@oracle.com>
      a656eb75
  2. 31 10月, 2007 1 次提交
  3. 10 10月, 2007 1 次提交
  4. 07 5月, 2007 1 次提交
  5. 17 2月, 2007 1 次提交
  6. 13 12月, 2006 1 次提交
    • R
      IB/fmr: ib_flush_fmr_pool() may wait too long · f47e22c6
      Roland Dreier 提交于
      ib_flush_fmr_pool() stashes away the request generation number
      properly, but then goes ahead and rereads it every time it tests
      whether the flush generation number has caught up.  This means that
      there is a theoretical possibility of livelock, if the request
      generation number keeps getting bumped and the flush generation number
      never catches up.  The fix is simple: use the request generation
      number read at the beginning of the function.
      
      Also, atomic_inc() followed by atomic_read() can be replaced with
      atomic_int_return().  There's no real requirement for atomicity here
      but we might as well shrink the code.
      
      This bug was discovered using David Binderman's list of "set but never
      used" warnings from icc.
      Signed-off-by: NRoland Dreier <rolandd@cisco.com>
      f47e22c6
  7. 15 7月, 2006 1 次提交
  8. 18 6月, 2006 1 次提交
  9. 21 3月, 2006 1 次提交
  10. 27 8月, 2005 2 次提交
  11. 28 7月, 2005 1 次提交
  12. 17 4月, 2005 3 次提交