Skip to contentSkip to conversation

dmaengine: qcom_hidma: use true,false for bool variable

PATCH Applied Jason Yan 3 participants 3 messages May 4, 2020 – May 13, 2020

Subsystems (3)
lore
Share & tools
lore

Jason Yan

author
#0 lore raw

PATCH 1/1 dmaengine: qcom_hidma: use true,false for bool variable

Fix the following coccicheck warning:

drivers/dma/qcom/hidma.c:553:1-17: WARNING: Assignment of 0/1 to bool variable

---
 drivers/dma/qcom/hidma.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/dma/qcom/hidma.c +1 -1
index 87490e125bc3..0a6d3ea08c78 100644
@@ -550,7 +550,7 @@ static void hidma_free_chan_resources(struct dma_chan *dmach)
 		kfree(mdesc);
 	}
 
-	mchan->allocated = 0;
+	mchan->allocated = false;
 	spin_unlock_irqrestore(&mchan->lock, irqflags);
 }
 
Signature · 1 line
2.21.1
maintainer
#1 lore raw
Quoted 15 lines · Jason Yan

Fix the following coccicheck warning:

drivers/dma/qcom/hidma.c:553:1-17: WARNING: Assignment of 0/1 to bool variable

---
 drivers/dma/qcom/hidma.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/dma/qcom/hidma.c +0 -0
index 87490e125bc3..0a6d3ea08c78 100644

drivers/dma/qcom/hidma.c static void hidma_free_chan_resources(struct dma_chan *dmach) · line 555

Quoted 7 lines
drivers/dma/qcom/hidma.c +1 -1
@@ -550,7 +550,7 @@ static void hidma_free_chan_resources(struct dma_chan *dmach)
 		kfree(mdesc);
 	}
 
-	mchan->allocated = 0;
+	mchan->allocated = false;
 	spin_unlock_irqrestore(&mchan->lock, irqflags);
 }

Acked By: Sinan Kaya <[email protected]>

maintainer Applied
#2 lore raw
In reply to Jason Yan
Quoted 4 lines · Jason Yan

Fix the following coccicheck warning:

drivers/dma/qcom/hidma.c:553:1-17: WARNING: Assignment of 0/1 to bool variable

Applied, thanks

Signature · 1 line
~Vinod