Merge branch 'for-4.11/next' into for-4.11/linus-merge
authorJens Axboe <axboe@fb.com>
Fri, 17 Feb 2017 21:08:19 +0000 (14:08 -0700)
committerJens Axboe <axboe@fb.com>
Fri, 17 Feb 2017 21:08:19 +0000 (14:08 -0700)
Signed-off-by: Jens Axboe <axboe@fb.com>
26 files changed:
1  2 
block/Kconfig
block/Makefile
block/bio.c
block/blk-core.c
block/blk-mq.c
block/elevator.c
drivers/block/cciss.c
drivers/block/null_blk.c
drivers/block/xen-blkfront.c
drivers/cdrom/cdrom.c
drivers/cdrom/gdrom.c
drivers/ide/ide-cd.c
drivers/md/dm-mpath.c
drivers/md/dm-rq.c
drivers/md/md.c
drivers/md/raid5.c
drivers/nvme/host/core.c
drivers/nvme/host/fc.c
drivers/nvme/host/pci.c
drivers/scsi/mpt3sas/mpt3sas_scsih.c
drivers/scsi/qla2xxx/qla_isr.c
drivers/scsi/sd.c
drivers/scsi/sr.c
fs/block_dev.c
fs/xfs/xfs_buf.c
include/linux/nvme.h

diff --cc block/Kconfig
Simple merge
diff --cc block/Makefile
Simple merge
diff --cc block/bio.c
Simple merge
Simple merge
diff --cc block/blk-mq.c
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
diff --cc drivers/md/md.c
Simple merge
Simple merge
Simple merge
Simple merge
Simple merge
@@@ -4717,20 -4715,6 +4717,20 @@@ _scsih_io_done(struct MPT3SAS_ADAPTER *
        }
  
        xfer_cnt = le32_to_cpu(mpi_reply->TransferCount);
-       if (unlikely(scmd->request->cmd_type == REQ_TYPE_FS && sector_sz &&
 +
 +      /* In case of bogus fw or device, we could end up having
 +       * unaligned partial completion. We can force alignment here,
 +       * then scsi-ml does not need to handle this misbehavior.
 +       */
 +      sector_sz = scmd->device->sector_size;
++      if (unlikely(!blk_rq_is_passthrough(scmd->request) && sector_sz &&
 +                   xfer_cnt % sector_sz)) {
 +              sdev_printk(KERN_INFO, scmd->device,
 +                  "unaligned partial completion avoided (xfer_cnt=%u, sector_sz=%u)\n",
 +                          xfer_cnt, sector_sz);
 +              xfer_cnt = round_down(xfer_cnt, sector_sz);
 +      }
 +
        scsi_set_resid(scmd, scsi_bufflen(scmd) - xfer_cnt);
        if (ioc_status & MPI2_IOCSTATUS_FLAG_LOG_INFO_AVAILABLE)
                log_info =  le32_to_cpu(mpi_reply->IOCLogInfo);
Simple merge
Simple merge
Simple merge
diff --cc fs/block_dev.c
Simple merge
Simple merge
Simple merge