From: Xiubo Li
If there has BIDI data, its first iov[] will overwrite the last
iov[] for se_cmd->t_data_sg.
To fix this, we can just increase the iov pointer, but this may
introuduce a new memory leakage bug: If the se_cmd->data_length
and se_cmd->t_bidi_data_sg->length are all not aligned up to
From: Xiubo Li
Changed for V5:
- This only includes #1 and #2. And for old #3, #4 are still reviewing.
- #1, since the issue reported by Ilias is a separate new one, and will
create a new patch later.
- #2, address the issue pointed out by Mike, thanks.
- #1 and #2 have been tested by Ilias in
It sounds like you don't want to support traditional discard at all,
but only WRITE ZEROES. So in many ways this series is the right way
forward. It would be nice if we could do a full blown
REQ_OP_WRITE_ZEROES for dm_think that zeroes out partial blocks,
similar to what hardware that implements
On Thu, Mar 23, 2017 at 11:10:38AM -0400, Mike Snitzer wrote:
> Not sure why you've split out the dm-kcopyd patch, likely best to just
> fold it into the previous dm support patch.
The dm-kcopyd patch switches to using WRITE_ZEROES instead of write
same for dm as user of these interfaces. The one
From: Xiubo Li
The t_data_nents and t_bidi_data_nents are the numbers of the
segments, but it couldn't be sure the block size equals to size
of the segment.
For the worst case, all the blocks are discontiguous and there
will need the same number of iovecs, that's to say: blocks == iovs.
So here
On Mon, Mar 27 2017 at 5:10am -0400,
Christoph Hellwig wrote:
> It sounds like you don't want to support traditional discard at all,
> but only WRITE ZEROES. So in many ways this series is the right way
> forward. It would be nice if we could do a full blown
> REQ_OP_WRITE_ZEROES for dm_think
If device reports a small max_xfer_blocks and a zero opt_xfer_blocks, we
end up using BLK_DEF_MAX_SECTORS, which is wrong and r/w of that size
may get error.
Fixes: ca369d51b3e ("block/sd: Fix device-imposed transfer length limits")
Signed-off-by: Fam Zheng
---
drivers/scsi/sd.c | 1 +
1 file ch
On Mon, Mar 27, 2017 at 10:03:07AM -0400, Mike Snitzer wrote:
> By "you" I assume you're referring to Lars?
Yes.
> Lars' approach for discard,
> when drbd is layered on dm-thinp, feels over-engineered. Not his fault,
> the way discard and zeroing got conflated certainly lends itself to
> these u
On Mon, 2017-03-27 at 10:03 -0400, Mike Snitzer wrote:
> As for the blkdev_issue_zeroout() resorting to manually zeroing the
> range, if the discard fails or dzd not supported, that certainly
> requires DM thinp to implement manual zeroing of the head and tail of
> the range if partial blocks are b
- Original Message -
> From: "Fam Zheng"
> To: linux-ker...@vger.kernel.org
> Cc: "Martin K. Petersen" , f...@redhat.com,
> linux-scsi@vger.kernel.org, "James E.J.
> Bottomley"
> Sent: Monday, March 27, 2017 10:18:31 AM
> Subject: [PATCH] sd: Consider max_xfer_blocks if opt_xfer_blocks
Hi Long Li,
A kernel bug report was opened against Ubuntu [0]. After a kernel
bisect, it was found that reverting the following commit resolved this bug:
commit 40630f462824ee24bc00d692865c86c3828094e0
Author: Long Li
Date: Wed Dec 14 18:46:03 2016 -0800
scsi: storvsc: properly set resid
Are you sure the real problem is not the one fixed by this commit?
commit f1c635b439a5c01776fe3a25b1e2dc546ea82e6f
Author: Stephen Hemminger
Date: Tue Mar 7 09:15:53 2017 -0800
scsi: storvsc: Workaround for virtual DVD SCSI version
Hyper-V host emulation of SCSI for virtual DVD de
On Mon, 2017-03-20 at 16:43 -0400, Christoph Hellwig wrote:
> + u64 sector = blk_rq_pos(rq) >> (ilog2(sdp->sector_size) - 9);
> + u32 nr_sectors = blk_rq_sectors(rq) >> (ilog2(sdp->sector_size) - 9);
Although I know this is an issue in the existing code and not something
introduced by you:
On 03/27/2017 06:14 PM, Stephen Hemminger wrote:
> Are you sure the real problem is not the one fixed by this commit?
>
> commit f1c635b439a5c01776fe3a25b1e2dc546ea82e6f
> Author: Stephen Hemminger
> Date: Tue Mar 7 09:15:53 2017 -0800
>
> scsi: storvsc: Workaround for virtual DVD SCSI versi
On Mon, 2017-03-20 at 16:43 -0400, Christoph Hellwig wrote:
> + case SD_LBP_ATA_TRIM:
> + max_blocks = 65535 * (512 / sizeof(__le64));
> + if (sdkp->device->ata_trim_zeroes_data)
> + q->limits.discard_zeroes_data = 1;
> + break;
Do we nee
On Mon, 2017-03-20 at 16:43 -0400, Christoph Hellwig wrote:
> diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
> index 5a7da607ca04..3b3bd646f580 100644
> --- a/include/linux/blkdev.h
> +++ b/include/linux/blkdev.h
> @@ -333,6 +333,7 @@ struct queue_limits {
> unsigned short
On Mon, 2017-03-20 at 16:43 -0400, Christoph Hellwig wrote:
> @@ -698,13 +698,19 @@ static void sd_config_discard(struct scsi_disk *sdkp,
> unsigned int mode)
> break;
>
> case SD_LBP_ATA_TRIM:
> - max_blocks = 65535 * (512 / sizeof(__le64));
> + max_r
On Mon, 2017-03-20 at 16:43 -0400, Christoph Hellwig wrote:
> We're never touching the contents of the page, so save a memory
> allocation for these cases.
>
> Signed-off-by: Christoph Hellwig
> ---
> drivers/scsi/sd.c | 7 ---
> 1 file changed, 4 insertions(+), 3 deletions(-)
>
> diff --gi
Hello,
I'm new to this list and I signed up, because I found an instability
with the following sata controller:
Product name: Delock 89384 10 Port PCIe 2.0 x2 Low Profile retail
Identifies as: 03:00.0 SATA controller: ASMedia Technology Inc. Device
0625 (rev 01)
(PCIe to 10x sata controller card)
Jaehoon Chung writes:
Jaehoon,
> There are same conditions for checking whether supporting clkscaling
> or not. When ufshcd is supporting clkscaling, active_reqs should be
> decreased by two.
Applied to 4.11/scsi-fixes.
Thank you!
--
Martin K. Petersen Oracle Linux Engineering
Dan Carpenter writes:
> We don't call the remove() function unless probe() succeeds so "oud"
> can't be NULL here. Plus, if it were NULL, we dereference it on the
> next line so it would crash anyway.
Applied to 4.12/scsi-queue (by hand).
--
Martin K. Petersen Oracle Linux Engineering
kusumi.tomoh...@gmail.com writes:
> From: Tomohiro Kusumi
>
> These aren't really falling through to anywhere meaningful.
>
> Signed-off-by: Tomohiro Kusumi
Applied to 4.12/scsi-queue.
Thanks!
--
Martin K. Petersen Oracle Linux Engineering
Jitendra Bhivare writes:
> This patch is generated against for-next branch.
>
> v3 changes:
> be2iscsi: Fix closing of connection
> - Fixed per Tomas's review comments.
>
> v2 changes:
> +be2iscsi: Update Copyright
>
> Jitendra Bhivare (10):
> be2iscsi: Check tag in beiscsi_mccq_compl_w
Fam Zheng writes:
Hi Fam,
> --- a/drivers/scsi/sd.c
> +++ b/drivers/scsi/sd.c
> @@ -2957,6 +2957,7 @@ static int sd_revalidate_disk(struct gendisk *disk)
> rw_max = logical_to_sectors(sdp, sdkp->opt_xfer_blocks);
> } else
> rw_max = BLK_DEF_MAX_SECTORS;
> +
If device reports a small max_xfer_blocks and a zero opt_xfer_blocks, we
end up using BLK_DEF_MAX_SECTORS, which is wrong and r/w of that size
may get error.
Fixes: ca369d51b3e ("block/sd: Fix device-imposed transfer length limits")
Signed-off-by: Fam Zheng
---
v2: Fix granularity mismatch. [Ma
25 matches
Mail list logo