1. 13 12月, 2018 14 次提交
  2. 12 12月, 2018 23 次提交
  3. 11 12月, 2018 3 次提交
    • M
      dm: fix request-based dm's use of dm_wait_for_completion · c4576aed
      Mike Snitzer 提交于
      The md->wait waitqueue is used by both bio-based and request-based DM.
      Commit dbd3bbd2 ("dm rq: leverage blk_mq_queue_busy() to check for
      outstanding IO") lost sight of the requirement that
      dm_wait_for_completion() must work with all types of DM devices.
      
      Fix md_in_flight() to call the blk-mq or bio-based method accordingly.
      
      Fixes: dbd3bbd2 ("dm rq: leverage blk_mq_queue_busy() to check for outstanding IO")
      Signed-off-by: NMike Snitzer <snitzer@redhat.com>
      Signed-off-by: NJens Axboe <axboe@kernel.dk>
      c4576aed
    • J
      nvme: fix irq vs io_queue calculations · 6451fe73
      Jens Axboe 提交于
      Guenter reported an boot hang issue on HPPA after we default to 0 poll
      queues. We have two issues in the queue count calculations:
      
      1) We don't separate the poll queues from the read/write queues. This is
         important, since the former doesn't need interrupts.
      2) The adjust logic is broken.
      
      Adjust the poll queue count before doing nvme_calc_io_queues(). The poll
      queue count is only limited by the IO queue count we were able to get
      from the controller, not failures in the IRQ allocation loop. This
      leaves nvme_calc_io_queues() just adjusting the read/write queue map.
      Reported-by: NReported-by: Guenter Roeck <linux@roeck-us.net>
      Reviewed-by: NChristoph Hellwig <hch@lst.de>
      Reviewed-by: NSagi Grimberg <sagi@grimberg.me>
      Signed-off-by: NJens Axboe <axboe@kernel.dk>
      6451fe73
    • J
      dm: fix inflight IO check · b7934ba4
      Jens Axboe 提交于
      After switching to percpu inflight counters, the inflight check
      is totally buggy. It's perfectly valid for some counters to be
      non-zero while having a total inflight IO count of 0, that's how
      these kinds of counters work (inc on one CPU, dec on another).
      Fix the md_in_flight() check to sum all counters before returning
      a false positive, potentially.
      
      While at it, remove the inflight read for IO completion. We don't
      need it, just wake anyone that's waiting for the IO count to drop
      to zero. The caller needs to re-check that value anyway when woken,
      which it does.
      
      Fixes: 6f757231 ("dm: remove the pending IO accounting")
      Acked-by: NMike Snitzer <snitzer@redhat.com>
      Reported-by: NChristoph Hellwig <hch@lst.de>
      Signed-off-by: NJens Axboe <axboe@kernel.dk>
      b7934ba4