]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
iio:adc:ad7923: Use BIT macro instead of bitshift
authorBárbara Fernandes <barbara.fernandes@usp.br>
Fri, 22 Feb 2019 20:31:57 +0000 (17:31 -0300)
committerJonathan Cameron <Jonathan.Cameron@huawei.com>
Thu, 4 Apr 2019 19:19:45 +0000 (20:19 +0100)
Replace use of the operation '<<' by the BIT macro. Solves checkpath.pl's
message:

CHECK: Prefer using the BIT macro

Signed-off-by: Bárbara Fernandes <barbara.fernandes@usp.br>
Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
drivers/iio/adc/ad7923.c

index ebae7522710a57b3d6a6f03f9c82c5f447d0c597..b39ea834cdd6df6e350ad0d651e299107dd1d0d5 100644 (file)
@@ -24,9 +24,9 @@
 #include <linux/iio/trigger_consumer.h>
 #include <linux/iio/triggered_buffer.h>
 
-#define AD7923_WRITE_CR                (1 << 11)       /* write control register */
-#define AD7923_RANGE           (1 << 1)        /* range to REFin */
-#define AD7923_CODING          (1 << 0)        /* coding is straight binary */
+#define AD7923_WRITE_CR                BIT(11)         /* write control register */
+#define AD7923_RANGE           BIT(1)          /* range to REFin */
+#define AD7923_CODING          BIT(0)          /* coding is straight binary */
 #define AD7923_PM_MODE_AS      (1)             /* auto shutdown */
 #define AD7923_PM_MODE_FS      (2)             /* full shutdown */
 #define AD7923_PM_MODE_OPS     (3)             /* normal operation */