All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] advansys: remove dma_cache_sync misuse
@ 2009-06-04 10:33 FUJITA Tomonori
  2009-06-04 17:26 ` Grant Grundler
  0 siblings, 1 reply; 2+ messages in thread
From: FUJITA Tomonori @ 2009-06-04 10:33 UTC (permalink / raw)
  To: James.Bottomley; +Cc: linux-scsi, matthew

dma_cache_sync() is supposed to be used only with
dma_alloc_noncoherent().

We don't need to call any dma_sync_ functions here too.

Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>
---
 drivers/scsi/advansys.c |    2 --
 1 files changed, 0 insertions(+), 2 deletions(-)

diff --git a/drivers/scsi/advansys.c b/drivers/scsi/advansys.c
index b756041..6b72e2d 100644
--- a/drivers/scsi/advansys.c
+++ b/drivers/scsi/advansys.c
@@ -8349,8 +8349,6 @@ static __le32 advansys_get_sense_buffer_dma(struct scsi_cmnd *scp)
 	struct asc_board *board = shost_priv(scp->device->host);
 	scp->SCp.dma_handle = dma_map_single(board->dev, scp->sense_buffer,
 					     SCSI_SENSE_BUFFERSIZE, DMA_FROM_DEVICE);
-	dma_cache_sync(board->dev, scp->sense_buffer,
-		       SCSI_SENSE_BUFFERSIZE, DMA_FROM_DEVICE);
 	return cpu_to_le32(scp->SCp.dma_handle);
 }
 
-- 
1.6.0.6


^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] advansys: remove dma_cache_sync misuse
  2009-06-04 10:33 [PATCH] advansys: remove dma_cache_sync misuse FUJITA Tomonori
@ 2009-06-04 17:26 ` Grant Grundler
  0 siblings, 0 replies; 2+ messages in thread
From: Grant Grundler @ 2009-06-04 17:26 UTC (permalink / raw)
  To: FUJITA Tomonori; +Cc: James.Bottomley, linux-scsi, matthew

On Thu, Jun 4, 2009 at 3:33 AM, FUJITA Tomonori
<fujita.tomonori@lab.ntt.co.jp> wrote:
> dma_cache_sync() is supposed to be used only with
> dma_alloc_noncoherent().
>
> We don't need to call any dma_sync_ functions here too.
>
> Signed-off-by: FUJITA Tomonori <fujita.tomonori@lab.ntt.co.jp>

Reviewed-by: Grant Grundler <grundler@google.com>

(jejb should probably also add his here too)

thanks,
grant

> ---
>  drivers/scsi/advansys.c |    2 --
>  1 files changed, 0 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/scsi/advansys.c b/drivers/scsi/advansys.c
> index b756041..6b72e2d 100644
> --- a/drivers/scsi/advansys.c
> +++ b/drivers/scsi/advansys.c
> @@ -8349,8 +8349,6 @@ static __le32 advansys_get_sense_buffer_dma(struct scsi_cmnd *scp)
>        struct asc_board *board = shost_priv(scp->device->host);
>        scp->SCp.dma_handle = dma_map_single(board->dev, scp->sense_buffer,
>                                             SCSI_SENSE_BUFFERSIZE, DMA_FROM_DEVICE);
> -       dma_cache_sync(board->dev, scp->sense_buffer,
> -                      SCSI_SENSE_BUFFERSIZE, DMA_FROM_DEVICE);
>        return cpu_to_le32(scp->SCp.dma_handle);
>  }
>
> --
> 1.6.0.6
>
> --
> 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
>
--
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] 2+ messages in thread

end of thread, other threads:[~2009-06-04 17:26 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-06-04 10:33 [PATCH] advansys: remove dma_cache_sync misuse FUJITA Tomonori
2009-06-04 17:26 ` Grant Grundler

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.