Skip to contentSkip to conversation

mx2_camera: use GFP_ATOMIC under spin lock.

PATCH Superseded Cyril Roelandt 1 participant 1 message Nov 19, 2012

Subsystems (2)

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mx2_camera: use GFP_ATOMIC under spin lock.

Found using the following semantic patch:

<spml>
@@
@@
spin_lock_irqsave(...);
... when != spin_unlock_irqrestore(...);
* GFP_KERNEL
</spml>

---
 drivers/media/platform/soc_camera/mx2_camera.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/media/platform/soc_camera/mx2_camera.c +1 -1
index e575ae8..516b3a3 100644
@@ -909,7 +909,7 @@ static int mx2_start_streaming(struct vb2_queue *q, unsigned int count)
 		pcdev->discard_size = icd->user_height * bytesperline;
 		pcdev->discard_buffer = dma_alloc_coherent(ici->v4l2_dev.dev,
 				pcdev->discard_size, &pcdev->discard_buffer_dma,
-				GFP_KERNEL);
+				GFP_ATOMIC);
 		if (!pcdev->discard_buffer)
 			return -ENOMEM;
 
Signature · 1 line
1.7.10.4