1. 09 Oct, 2018 37 commits
  2. 08 Oct, 2018 3 commits
    • Ming Lei's avatar
      blk-mq: complete req in softirq context in case of single queue · 36e76539
      Ming Lei authored
      Lot of controllers may have only one irq vector for completing IO
      request. And usually affinity of the only irq vector is all possible
      CPUs, however, on most of ARCH, there may be only one specific CPU
      for handling this interrupt.
      
      So if all IOs are completed in hardirq context, it is inevitable to
      degrade IO performance because of increased irq latency.
      
      This patch tries to address this issue by allowing to complete request
      in softirq context, like the legacy IO path.
      
      IOPS is observed as ~13%+ in the following randread test on raid0 over
      virtio-scsi.
      
      mdadm --create --verbose /dev/md0 --level=0 --chunk=1024 --raid-devices=8 /dev/sdb /dev/sdc /dev/sdd /dev/sde /dev/sdf /dev/sdg /dev/sdh /dev/sdi
      
      fio --time_based --name=benchmark --runtime=30 --filename=/dev/md0 --nrfiles=1 --ioengine=libaio --iodepth=32 --direct=1 --invalidate=1 --verify=0 --verify_fatal=0 --numjobs=32 --rw=randread --blocksize=4k
      
      Cc: Dongli Zhang <dongli.zhang@oracle.com>
      Cc: Zach Marano <zmarano@google.com>
      Cc: Christoph Hellwig <hch@lst.de>
      Cc: Bart Van Assche <bvanassche@acm.org>
      Cc: Jianchao Wang <jianchao.w.wang@oracle.com>
      Signed-off-by: default avatarMing Lei <ming.lei@redhat.com>
      Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
      36e76539
    • Dongbo Cao's avatar
      bcache: panic fix for making cache device · 3a646fd7
      Dongbo Cao authored
      when the nbuckets of cache device is smaller than 1024, making cache
      device will trigger BUG_ON in kernel, add a condition to avoid this.
      Reported-by: default avatarnitroxis <n@nxs.re>
      Signed-off-by: default avatarDongbo Cao <cdbdyx@163.com>
      Signed-off-by: default avatarColy Li <colyli@suse.de>
      Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
      3a646fd7
    • Dongbo Cao's avatar
      bcache: split combined if-condition code into separate ones · f6027bca
      Dongbo Cao authored
      Split the combined '||' statements in if() check, to make the code easier
      for debug.
      Signed-off-by: default avatarDongbo Cao <cdbdyx@163.com>
      Signed-off-by: default avatarColy Li <colyli@suse.de>
      Signed-off-by: default avatarJens Axboe <axboe@kernel.dk>
      f6027bca