xen-netback: use true and false for boolean values
authorGustavo A. R. Silva <gustavo@embeddedor.com>
Thu, 2 Aug 2018 00:31:01 +0000 (19:31 -0500)
committerDavid S. Miller <davem@davemloft.net>
Thu, 2 Aug 2018 21:43:04 +0000 (14:43 -0700)
Return statements in functions returning bool should use true or false
instead of an integer value.

This issue was detected with the help of Coccinelle.

Signed-off-by: Gustavo A. R. Silva <gustavo@embeddedor.com>
Acked-by: Wei Liu <wei.liu2@citrix.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/xen-netback/netback.c

index a27daa23c9dc9f4f5b52c5c2da335527f07a1366..3621e05a7494c43a94084fa79a6959fa428f64ec 100644 (file)
@@ -1603,9 +1603,9 @@ static void xenvif_ctrl_action(struct xenvif *vif)
 static bool xenvif_ctrl_work_todo(struct xenvif *vif)
 {
        if (likely(RING_HAS_UNCONSUMED_REQUESTS(&vif->ctrl)))
-               return 1;
+               return true;
 
-       return 0;
+       return false;
 }
 
 irqreturn_t xenvif_ctrl_irq_fn(int irq, void *data)