* [PATCH] mptsas: fix dma alignment
@ 2009-09-01 21:03 Vitaly Bordug
2009-09-07 11:12 ` Desai, Kashyap
0 siblings, 1 reply; 6+ messages in thread
From: Vitaly Bordug @ 2009-09-01 21:03 UTC (permalink / raw)
To: Eric Moore; +Cc: DL-MPTFusionLinux, linux-scsi
From: Yuri Tikhonov <yur@emcraft.com>
fusion mptsas: fix dma alignment
Since the 465ff.. commit from James Bottomley relaxes the default
SCSI DMA alignment from 512 bytes to 4 bytes, then, in the mptsas
driver, we should explicitly set the alignment to the workable
512 bytes value.
Signed-off-by: Ilya Yanok <yanok@emcraft.com>
Signed-off-by: Yuri Tikhonov <yur@emcraft.com>
Signed-off-by: Sergei Poselenov <sposelenov@emcraft.com>
Signed-off-by: Vitaly Bordug <vitb@kernel.crashing.org>
---
drivers/message/fusion/mptsas.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/drivers/message/fusion/mptsas.c
b/drivers/message/fusion/mptsas.c index 55ff252..2334f26 100644
--- a/drivers/message/fusion/mptsas.c
+++ b/drivers/message/fusion/mptsas.c
@@ -1843,6 +1843,7 @@ mptsas_slave_alloc(struct scsi_device *sdev)
return -ENXIO;
out:
+ blk_queue_update_dma_alignment(sdev->request_queue, 511);
vdevice->vtarget->num_luns++;
sdev->hostdata = vdevice;
return 0;
^ permalink raw reply [flat|nested] 6+ messages in thread* RE: [PATCH] mptsas: fix dma alignment
2009-09-01 21:03 [PATCH] mptsas: fix dma alignment Vitaly Bordug
@ 2009-09-07 11:12 ` Desai, Kashyap
2009-09-07 13:45 ` Vitaly Bordug
0 siblings, 1 reply; 6+ messages in thread
From: Desai, Kashyap @ 2009-09-07 11:12 UTC (permalink / raw)
To: Vitaly Bordug, Moore, Eric
Cc: DL-MPT Fusion Linux, linux-scsi@vger.kernel.org
Can you send an exact link for "465ff.. commit"?
Thanks,
Kashyap
-----Original Message-----
From: Vitaly Bordug [mailto:vitb@kernel.crashing.org]
Sent: Wednesday, September 02, 2009 2:34 AM
To: Moore, Eric
Cc: DL-MPT Fusion Linux; linux-scsi@vger.kernel.org
Subject: [PATCH] mptsas: fix dma alignment
From: Yuri Tikhonov <yur@emcraft.com>
fusion mptsas: fix dma alignment
Since the 465ff.. commit from James Bottomley relaxes the default
SCSI DMA alignment from 512 bytes to 4 bytes, then, in the mptsas
driver, we should explicitly set the alignment to the workable
512 bytes value.
Signed-off-by: Ilya Yanok <yanok@emcraft.com>
Signed-off-by: Yuri Tikhonov <yur@emcraft.com>
Signed-off-by: Sergei Poselenov <sposelenov@emcraft.com>
Signed-off-by: Vitaly Bordug <vitb@kernel.crashing.org>
---
drivers/message/fusion/mptsas.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/drivers/message/fusion/mptsas.c
b/drivers/message/fusion/mptsas.c index 55ff252..2334f26 100644
--- a/drivers/message/fusion/mptsas.c
+++ b/drivers/message/fusion/mptsas.c
@@ -1843,6 +1843,7 @@ mptsas_slave_alloc(struct scsi_device *sdev)
return -ENXIO;
out:
+ blk_queue_update_dma_alignment(sdev->request_queue, 511);
vdevice->vtarget->num_luns++;
sdev->hostdata = vdevice;
return 0;
^ permalink raw reply [flat|nested] 6+ messages in thread* Re: [PATCH] mptsas: fix dma alignment
2009-09-07 11:12 ` Desai, Kashyap
@ 2009-09-07 13:45 ` Vitaly Bordug
2009-09-08 8:19 ` Desai, Kashyap
0 siblings, 1 reply; 6+ messages in thread
From: Vitaly Bordug @ 2009-09-07 13:45 UTC (permalink / raw)
To: Desai, Kashyap
Cc: Moore, Eric, DL-MPT Fusion Linux, linux-scsi@vger.kernel.org
В Mon, 7 Sep 2009 16:42:54 +0530
"Desai, Kashyap" <Kashyap.Desai@lsi.com> пишет:
> Can you send an exact link for "465ff.. commit"?
>
Sure,
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=465ff3185e0cb76d46137335a4d21d0d9d3ac8a2
> Thanks,
> Kashyap
>
> -----Original Message-----
> From: Vitaly Bordug [mailto:vitb@kernel.crashing.org]
> Sent: Wednesday, September 02, 2009 2:34 AM
> To: Moore, Eric
> Cc: DL-MPT Fusion Linux; linux-scsi@vger.kernel.org
> Subject: [PATCH] mptsas: fix dma alignment
>
>
> From: Yuri Tikhonov <yur@emcraft.com>
>
> fusion mptsas: fix dma alignment
>
> Since the 465ff.. commit from James Bottomley relaxes the default
> SCSI DMA alignment from 512 bytes to 4 bytes, then, in the mptsas
> driver, we should explicitly set the alignment to the workable
> 512 bytes value.
>
> Signed-off-by: Ilya Yanok <yanok@emcraft.com>
> Signed-off-by: Yuri Tikhonov <yur@emcraft.com>
> Signed-off-by: Sergei Poselenov <sposelenov@emcraft.com>
> Signed-off-by: Vitaly Bordug <vitb@kernel.crashing.org>
> ---
>
> drivers/message/fusion/mptsas.c | 1 +
> 1 files changed, 1 insertions(+), 0 deletions(-)
>
>
> diff --git a/drivers/message/fusion/mptsas.c
> b/drivers/message/fusion/mptsas.c index 55ff252..2334f26 100644
> --- a/drivers/message/fusion/mptsas.c
> +++ b/drivers/message/fusion/mptsas.c
> @@ -1843,6 +1843,7 @@ mptsas_slave_alloc(struct scsi_device *sdev)
> return -ENXIO;
>
> out:
> + blk_queue_update_dma_alignment(sdev->request_queue, 511);
> vdevice->vtarget->num_luns++;
> sdev->hostdata = vdevice;
> return 0;
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: [PATCH] mptsas: fix dma alignment
2009-09-07 13:45 ` Vitaly Bordug
@ 2009-09-08 8:19 ` Desai, Kashyap
2009-09-08 14:22 ` James Bottomley
0 siblings, 1 reply; 6+ messages in thread
From: Desai, Kashyap @ 2009-09-08 8:19 UTC (permalink / raw)
To: Vitaly Bordug
Cc: Moore, Eric, DL-MPT Fusion Linux, linux-scsi@vger.kernel.org
After seeing original commit from James, this patch looks OK to me.
Please consider this patch as ACKed by me.
Thanks,
Kashyap
-----Original Message-----
From: Vitaly Bordug [mailto:vitb@kernel.crashing.org]
Sent: Monday, September 07, 2009 7:16 PM
To: Desai, Kashyap
Cc: Moore, Eric; DL-MPT Fusion Linux; linux-scsi@vger.kernel.org
Subject: Re: [PATCH] mptsas: fix dma alignment
В Mon, 7 Sep 2009 16:42:54 +0530
"Desai, Kashyap" <Kashyap.Desai@lsi.com> пишет:
> Can you send an exact link for "465ff.. commit"?
>
Sure,
http://git.kernel.org/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=465ff3185e0cb76d46137335a4d21d0d9d3ac8a2
> Thanks,
> Kashyap
>
> -----Original Message-----
> From: Vitaly Bordug [mailto:vitb@kernel.crashing.org]
> Sent: Wednesday, September 02, 2009 2:34 AM
> To: Moore, Eric
> Cc: DL-MPT Fusion Linux; linux-scsi@vger.kernel.org
> Subject: [PATCH] mptsas: fix dma alignment
>
>
> From: Yuri Tikhonov <yur@emcraft.com>
>
> fusion mptsas: fix dma alignment
>
> Since the 465ff.. commit from James Bottomley relaxes the default
> SCSI DMA alignment from 512 bytes to 4 bytes, then, in the mptsas
> driver, we should explicitly set the alignment to the workable
> 512 bytes value.
>
> Signed-off-by: Ilya Yanok <yanok@emcraft.com>
> Signed-off-by: Yuri Tikhonov <yur@emcraft.com>
> Signed-off-by: Sergei Poselenov <sposelenov@emcraft.com>
> Signed-off-by: Vitaly Bordug <vitb@kernel.crashing.org>
> ---
>
> drivers/message/fusion/mptsas.c | 1 +
> 1 files changed, 1 insertions(+), 0 deletions(-)
>
>
> diff --git a/drivers/message/fusion/mptsas.c
> b/drivers/message/fusion/mptsas.c index 55ff252..2334f26 100644
> --- a/drivers/message/fusion/mptsas.c
> +++ b/drivers/message/fusion/mptsas.c
> @@ -1843,6 +1843,7 @@ mptsas_slave_alloc(struct scsi_device *sdev)
> return -ENXIO;
>
> out:
> + blk_queue_update_dma_alignment(sdev->request_queue, 511);
> vdevice->vtarget->num_luns++;
> sdev->hostdata = vdevice;
> return 0;
--
To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: [PATCH] mptsas: fix dma alignment
2009-09-08 8:19 ` Desai, Kashyap
@ 2009-09-08 14:22 ` James Bottomley
2009-09-08 16:19 ` Moore, Eric
0 siblings, 1 reply; 6+ messages in thread
From: James Bottomley @ 2009-09-08 14:22 UTC (permalink / raw)
To: Desai, Kashyap
Cc: Vitaly Bordug, Moore, Eric, DL-MPT Fusion Linux,
linux-scsi@vger.kernel.org
On Tue, 2009-09-08 at 13:49 +0530, Desai, Kashyap wrote:
> After seeing original commit from James, this patch looks OK to me.
> Please consider this patch as ACKed by me.
If you're sure it's a problem. The reason for the original was that all
DMA engines (including the old LSI 1010) can transfer on word
boundaries. I didn't realise the 1030 had regressed in terms of DMA
alignment requirements.
James
^ permalink raw reply [flat|nested] 6+ messages in thread
* RE: [PATCH] mptsas: fix dma alignment
2009-09-08 14:22 ` James Bottomley
@ 2009-09-08 16:19 ` Moore, Eric
0 siblings, 0 replies; 6+ messages in thread
From: Moore, Eric @ 2009-09-08 16:19 UTC (permalink / raw)
To: James Bottomley, Desai, Kashyap
Cc: Vitaly Bordug, DL-MPT Fusion Linux, linux-scsi@vger.kernel.org
On Tuesday, September 08, 2009 8:23 AM, James Bottomley wrote:
> On Tue, 2009-09-08 at 13:49 +0530, Desai, Kashyap wrote:
> > After seeing original commit from James, this patch looks OK to me.
> > Please consider this patch as ACKed by me.
>
> If you're sure it's a problem. The reason for the original
> was that all
> DMA engines (including the old LSI 1010) can transfer on word
> boundaries. I didn't realise the 1030 had regressed in terms of DMA
> alignment requirements.
>
James, correct. The scatter gather elements themselfs have to be on 4 byte boundary. Thus I don't believe this patch is required.
However the alignment restrictions are for Request Message Frames, chains, and sense buffer can't cross 4GB boundary. The reason is the driver reports the upper 32bit address in the ioc_init request at driver load time.
Eric
^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2009-09-08 16:19 UTC | newest]
Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-09-01 21:03 [PATCH] mptsas: fix dma alignment Vitaly Bordug
2009-09-07 11:12 ` Desai, Kashyap
2009-09-07 13:45 ` Vitaly Bordug
2009-09-08 8:19 ` Desai, Kashyap
2009-09-08 14:22 ` James Bottomley
2009-09-08 16:19 ` Moore, Eric
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox