Skip to contentSkip to conversation

ieee802154: cc2520: Replace shift operations by BIT macro

PATCH In review Mohammad Jamal 3 participants 3 messages Jan 23, 2015 – Feb 2, 2015

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

PATCH 1/1 ieee802154: cc2520: Replace shift operations by BIT macro

This patch replaces the shifting operations by BIT macro

---
 drivers/net/ieee802154/cc2520.c |    6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
drivers/net/ieee802154/cc2520.c +3 -3
index 665a3db..181b349 100644
@@ -44,9 +44,9 @@
 #define	CC2520_FREG_MASK	0x3F
 
 /* status byte values */
-#define	CC2520_STATUS_XOSC32M_STABLE	(1 << 7)
-#define	CC2520_STATUS_RSSI_VALID	(1 << 6)
-#define	CC2520_STATUS_TX_UNDERFLOW	(1 << 3)
+#define	CC2520_STATUS_XOSC32M_STABLE	BIT(7)
+#define	CC2520_STATUS_RSSI_VALID	BIT(6)
+#define	CC2520_STATUS_TX_UNDERFLOW	BIT(3)
 
 /* IEEE-802.15.4 defined constants (2.4 GHz logical channels) */
 #define	CC2520_MINCHANNEL		11
Signature · 1 line
1.7.9.5
Acked-by on v1 1/1
#1 lore raw

Hi Jamal,

Quoted 1 line · Mohammad Jamal

This patch replaces the shifting operations by BIT macro

Thanks for the patch.

Quoted 22 lines
---
  drivers/net/ieee802154/cc2520.c |    6 +++---
  1 file changed, 3 insertions(+), 3 deletions(-)
drivers/net/ieee802154/cc2520.c +3 -3
index 665a3db..181b349 100644
@@ -44,9 +44,9 @@
  #define	CC2520_FREG_MASK	0x3F
 
  /* status byte values */
-#define	CC2520_STATUS_XOSC32M_STABLE	(1 << 7)
-#define	CC2520_STATUS_RSSI_VALID	(1 << 6)
-#define	CC2520_STATUS_TX_UNDERFLOW	(1 << 3)
+#define	CC2520_STATUS_XOSC32M_STABLE	BIT(7)
+#define	CC2520_STATUS_RSSI_VALID	BIT(6)
+#define	CC2520_STATUS_TX_UNDERFLOW	BIT(3)
 
  /* IEEE-802.15.4 defined constants (2.4 GHz logical channels) */
  #define	CC2520_MINCHANNEL		11
Signature · 2 lines
Thanks and Regards,
Varka Bhadram.