Skip to contentSkip to conversation

genwqe: card_base: Use true and false for boolean values

PATCH New Gustavo A. R. Silva 1 participant 1 message Aug 5, 2018

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 genwqe: card_base: Use true and false for boolean values

Return statements in functions returning bool should use true or false instead of an integer value.

This code was detected with the help of Coccinelle.

---
 drivers/misc/genwqe/card_base.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/misc/genwqe/card_base.h +1 -1
index 1c3967f..120738d 100644
@@ -497,7 +497,7 @@ int  genwqe_user_vunmap(struct genwqe_dev *cd, struct dma_mapping *m);
 static inline bool dma_mapping_used(struct dma_mapping *m)
 {
 	if (!m)
-		return 0;
+		return false;
 	return m->size != 0;
 }
 
Signature · 1 line
2.7.4