]> git.karo-electronics.de Git - karo-tx-linux.git/commit
3w-9xxx: fix iommu_iova leak
authorJames Bottomley <JBottomley@Parallels.com>
Sun, 18 Sep 2011 14:56:20 +0000 (18:56 +0400)
committerPaul Gortmaker <paul.gortmaker@windriver.com>
Fri, 17 Aug 2012 19:35:21 +0000 (15:35 -0400)
commit54b8e0add30691b9775d959ea0bf0f3acfce9fcb
treee417f2eeeaeb99fd7791942621181b59d50c76f9
parent0bd6318e63246b5ab0c0a088712b4e003bc4dbf1
3w-9xxx: fix iommu_iova leak

commit 96067723e46b0dd24ae7b934085ab4eff4d26a1b upstream.

Following reports on the list, it looks like the 3e-9xxx driver will leak dma
mappings every time we get a transient queueing error back from the card.
This is because it maps the sg list in the routine that sends the command, but
doesn't unmap again in the transient failure path (even though the command is
sent back to the block layer).  Fix by unmapping before returning the status.

Reported-by: Chris Boot <bootc@bootc.net>
Tested-by: Chris Boot <bootc@bootc.net>
Acked-by: Adam Radford <aradford@gmail.com>
Signed-off-by: James Bottomley <JBottomley@Parallels.com>
Signed-off-by: Paul Gortmaker <paul.gortmaker@windriver.com>
drivers/scsi/3w-9xxx.c