Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a5b0e406 authored by Bryant G. Ly's avatar Bryant G. Ly Committed by Bart Van Assche
Browse files

ibmvscsis: Fix sleeping in interrupt context



Currently, dma_alloc_coherent is being called with a GFP_KERNEL
flag which allows it to sleep in an interrupt context, need to
change to GFP_ATOMIC.

Cc: stable@vger.kernel.org
Tested-by: default avatarSteven Royer <seroyer@linux.vnet.ibm.com>
Reviewed-by: default avatarMichael Cyr <mikecyr@linux.vnet.ibm.com>
Signed-off-by: default avatarBryant G. Ly <bryantly@linux.vnet.ibm.com>
Signed-off-by: default avatarBart Van Assche <bart.vanassche@sandisk.com>
parent 387b978c
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -1392,7 +1392,7 @@ static long ibmvscsis_adapter_info(struct scsi_info *vscsi,
	}

	info = dma_alloc_coherent(&vscsi->dma_dev->dev, sizeof(*info), &token,
				  GFP_KERNEL);
				  GFP_ATOMIC);
	if (!info) {
		dev_err(&vscsi->dev, "bad dma_alloc_coherent %p\n",
			iue->target);
@@ -1510,7 +1510,7 @@ static int ibmvscsis_cap_mad(struct scsi_info *vscsi, struct iu_entry *iue)
	}

	cap = dma_alloc_coherent(&vscsi->dma_dev->dev, olen, &token,
				 GFP_KERNEL);
				 GFP_ATOMIC);
	if (!cap) {
		dev_err(&vscsi->dev, "bad dma_alloc_coherent %p\n",
			iue->target);