mptsas: fix dma alignment
Subsystems (2)
PATCH 1/1 mptsas: fix dma alignment
From: Yuri Tikhonov <[email protected]>
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.
---
drivers/message/fusion/mptsas.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
(quoted diff) +0 -0
b/drivers/message/fusion/mptsas.c index 55ff252..2334f26 100644
drivers/message/fusion/mptsas.c +1 -0
@@ -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 ;
Can you send an exact link for "465ff.. commit"?
Thanks,
Kashyap
-----Original Message-----
From: Vitaly Bordug [mailto:[email protected]]
Sent: Wednesday, September 02, 2009 2:34 AM
To: Moore, Eric
Cc: DL-MPT Fusion Linux; [email protected]
Subject: [PATCH] mptsas: fix dma alignment
From: Yuri Tikhonov <[email protected]>
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.
---
drivers/message/fusion/mptsas.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
(quoted diff) +0 -0
b/drivers/message/fusion/mptsas.c index 55ff252..2334f26 100644
drivers/message/fusion/mptsas.c +1 -0
@@ -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 ;
В Mon, 7 Sep 2009 16:42:54 +0530
"Desai, Kashyap" <[email protected]> пишет:
Quoted 2 lines
Can you send an exact link for "465ff.. commit"?
Quoted 35 lines
Thanks,
Kashyap-----Original Message-----
From: Vitaly Bordug [mailto:[email protected]]
Sent: Wednesday, September 02, 2009 2:34 AM
To: Moore, Eric
Cc: DL-MPT Fusion Linux; [email protected]
Subject: [PATCH] mptsas: fix dma alignmentFrom: Yuri Tikhonov <[email protected]>
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 <[email protected]>Signed-off-by Yuri Tikhonov <[email protected]>Signed-off-by Sergei Poselenov <[email protected]>Signed-off-by Vitaly Bordug <[email protected]>---
drivers/message/fusion/mptsas.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)(quoted diff) +0
-0
b/drivers/message/fusion/mptsas.cindex 55ff252..2334f26 100644
drivers/message/fusion/mptsas.c mptsas_slave_alloc(struct scsi_device *sdev) · line 1849
Quoted 7 lines
drivers/message/fusion/mptsas.c +1
-0@@ -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 [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
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:[email protected]]
Sent: Monday, September 07, 2009 7:16 PM
To: Desai, Kashyap
Cc: Moore, Eric; DL-MPT Fusion Linux; [email protected]
Subject: Re: [PATCH] mptsas: fix dma alignment
В Mon, 7 Sep 2009 16:42:54 +0530
"Desai, Kashyap" <[email protected]> пишет:
Quoted 2 lines
Can you send an exact link for "465ff.. commit"?
Quoted 35 lines
Thanks,
Kashyap-----Original Message-----
From: Vitaly Bordug [mailto:[email protected]]
Sent: Wednesday, September 02, 2009 2:34 AM
To: Moore, Eric
Cc: DL-MPT Fusion Linux; [email protected]
Subject: [PATCH] mptsas: fix dma alignmentFrom: Yuri Tikhonov <[email protected]>
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 <[email protected]>Signed-off-by Yuri Tikhonov <[email protected]>Signed-off-by Sergei Poselenov <[email protected]>Signed-off-by Vitaly Bordug <[email protected]>---
drivers/message/fusion/mptsas.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)(quoted diff) +0
-0
b/drivers/message/fusion/mptsas.cindex 55ff252..2334f26 100644
drivers/message/fusion/mptsas.c mptsas_slave_alloc(struct scsi_device *sdev) · line 1849
Quoted 7 lines
drivers/message/fusion/mptsas.c +1
-0@@ -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 [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 2 lines · Kashyap
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
Quoted 10 lines · James Bottomley
Quoted 2 lines · Kashyap
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