This Replace all occurences of (1<<x) by BIT(x) and DMM32AT_CTRL(x),[snip]
DMM32AT_AI_CFG(x) macros to get rid of checkpatch.pl
"CHECK" output "Prefer using the BIT macro"
Signed-off-by: Ravishankar Karkala Mallikarjunayya <ravishankarkm32@xxxxxxxxx>
---
drivers/staging/comedi/drivers/dmm32at.c | 98 ++++++++++++++++----------------
1 file changed, 50 insertions(+), 48 deletions(-)
diff --git a/drivers/staging/comedi/drivers/dmm32at.c b/drivers/staging/comedi/drivers/dmm32at.c
index 958c0d4..0d50105 100644
--- a/drivers/staging/comedi/drivers/dmm32at.c
+++ b/drivers/staging/comedi/drivers/dmm32at.c
-#define DMM32AT_CTRL_RESETA (1 << 5)
-#define DMM32AT_CTRL_RESETD (1 << 4)
-#define DMM32AT_CTRL_INTRST (1 << 3)
-#define DMM32AT_CTRL_PAGE_8254 (0 << 0)
-#define DMM32AT_CTRL_PAGE_8255 (1 << 0)
-#define DMM32AT_CTRL_PAGE_CALIB (3 << 0)
+#define DMM32AT_CTRL_RESETA BIT(5)
+#define DMM32AT_CTRL_RESETD BIT(4)
+#define DMM32AT_CTRL_INTRST BIT(3)
+#define DMM32AT_CTRL(x) ((x) << 0)
+#define DMM32AT_CTRL_PAGE_8254 DMM32AT_CTRL(0)
+#define DMM32AT_CTRL_PAGE_8255 DMM32AT_CTRL(1)
+#define DMM32AT_CTRL_PAGE_CALIB DMM32AT_CTRL(3)
-#define DMM32AT_AI_CFG_SCINT_20US (0 << 4)
-#define DMM32AT_AI_CFG_SCINT_15US (1 << 4)
-#define DMM32AT_AI_CFG_SCINT_10US (2 << 4)
-#define DMM32AT_AI_CFG_SCINT_5US (3 << 4)
-#define DMM32AT_AI_CFG_RANGE (1 << 3) /* 0=5V 1=10V */
-#define DMM32AT_AI_CFG_ADBU (1 << 2) /* 0=bipolar 1=unipolar */
+#define DMM32AT_AI_CFG(x) ((x) << 4)
+#define DMM32AT_AI_CFG_SCINT_20US DMM32AT_AI_CFG(0)
+#define DMM32AT_AI_CFG_SCINT_15US DMM32AT_AI_CFG(1)
+#define DMM32AT_AI_CFG_SCINT_10US DMM32AT_AI_CFG(2)
+#define DMM32AT_AI_CFG_SCINT_5US DMM32AT_AI_CFG(3)