Re: [PATCH] fix dma_unmap_sg misuse

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



FUJITA Tomonori wrote:
> Looks like that libata misuses dma_unmap_sg though I'm not familiar
> with libata so I might completely misunderstand something.
> 
> =
> From: FUJITA Tomonori <fujita.tomonori@xxxxxxxxxxxxx>
> Subject: [PATCH] fix dma_unmap_sg misuse
> 
> DMA-mapping.txt says:
> 
> To unmap a scatterlist, just call:
> 
> 	pci_unmap_sg(pdev, sglist, nents, direction);
> 
> Again, make sure DMA activity has already finished.
> 
> PLEASE NOTE:  The 'nents' argument to the pci_unmap_sg call must be
>               the _same_ one you passed into the pci_map_sg call,
> 	      it should _NOT_ be the 'count' value _returned_ from the
>               pci_map_sg call.
> 
> Signed-off-by: FUJITA Tomonori <fujita.tomonori@xxxxxxxxxxxxx>

Right, nice spotting.

Acked-by: Tejun Heo <tj@xxxxxxxxxx>

Thanks.

-- 
tejun
--
To unsubscribe from this list: send the line "unsubscribe linux-ide" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Filesystems]     [Linux SCSI]     [Linux RAID]     [Git]     [Kernel Newbies]     [Linux Newbie]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Samba]     [Device Mapper]

  Powered by Linux