Re: [PATCH] ibmvscsi: Correct DMA mapping leak

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

 



Acked by: Brian King <brking@xxxxxxxxxxxxxxxxxx>

Robert Jennings wrote:
> The ibmvscsi client driver is not unmapping the SCSI command after
> encountering a DMA mapping error while trying to map an indirect
> scattergather list for the event pool.  This leads to a leak of DMA
> entitlement that could result in the device failing future DMA operations
> in a CMO environment.
> 
> Signed-off-by: Robert Jennings <rcj@xxxxxxxxxxxxxxxxxx>
> ---
>  drivers/scsi/ibmvscsi/ibmvscsi.c |    1 +
>  1 file changed, 1 insertion(+)
> 
> Index: b/drivers/scsi/ibmvscsi/ibmvscsi.c
> ===================================================================
> --- a/drivers/scsi/ibmvscsi/ibmvscsi.c
> +++ b/drivers/scsi/ibmvscsi/ibmvscsi.c
> @@ -432,6 +432,7 @@ static int map_sg_data(struct scsi_cmnd 
>  				sdev_printk(KERN_ERR, cmd->device,
>  				            "Can't allocate memory "
>  				            "for indirect table\n");
> +			scsi_dma_unmap(cmd);
>  			return 0;
>  		}
>  	}
> --
> To unsubscribe from this list: send the line "unsubscribe linux-scsi" in
> the body of a message to majordomo@xxxxxxxxxxxxxxx
> More majordomo info at  http://vger.kernel.org/majordomo-info.html


-- 
Brian King
Linux on Power Virtualization
IBM Linux Technology Center


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

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [SCSI Target Devel]     [Linux SCSI Target Infrastructure]     [Kernel Newbies]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Linux IIO]     [Samba]     [Device Mapper]
  Powered by Linux