From: Julia Lawall Date: Sat, 29 Aug 2015 17:30:05 +0000 (+0200) Subject: staging: lustre: include: put constant on the right of binary operator X-Git-Url: http://drtracing.org/?a=commitdiff_plain;h=625a31217eb2cca358d7a3d6976bca402beaa7a5;p=deliverable%2Flinux.git staging: lustre: include: put constant on the right of binary operator Move constants to the right of binary operators. A simplified version of the semantic patch that makes this change is as follows: (http://coccinelle.lip6.fr/) // @@ constant c; expression e; binary operator b = {==,!=,&,|}; @@ ( - c + e b - e + c | - c < e + e > c ) // Signed-off-by: Julia Lawall Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/lustre/include/linux/lnet/types.h b/drivers/staging/lustre/include/linux/lnet/types.h index 940f73f266d1..11630180c5e7 100644 --- a/drivers/staging/lustre/include/linux/lnet/types.h +++ b/drivers/staging/lustre/include/linux/lnet/types.h @@ -303,7 +303,7 @@ static inline int LNetHandleIsEqual(lnet_handle_any_t h1, lnet_handle_any_t h2) */ static inline int LNetHandleIsInvalid(lnet_handle_any_t h) { - return LNET_WIRE_HANDLE_COOKIE_NONE == h.cookie; + return h.cookie == LNET_WIRE_HANDLE_COOKIE_NONE; } /**