linux-rdma.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/1] staging: rdma: hfi1 : Prefer using the BIT macro
@ 2015-11-05 11:58 Sunny Kumar
  2015-11-05 13:27 ` Leon Romanovsky
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Sunny Kumar @ 2015-11-05 11:58 UTC (permalink / raw)
  To: Mike Marciniszyn, Doug Ledford, Sean Hefty, Hal Rosenstock,
	Greg Kroah-Hartman, linux-rdma-u79uwXL29TY76Z2rM5mHXA,
	devel-gWbeCf7V1WCQmaza687I9mD2FQJk+8+b,
	linux-kernel-u79uwXL29TY76Z2rM5mHXA
  Cc: Sunny Kumar

This patch replaces bit shifting on 1 with the BIT(x) macro

Signed-off-by: Sunny Kumar <sunnyk-If5XQcfNmg0@public.gmane.org>
---
 drivers/staging/rdma/hfi1/user_sdma.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/staging/rdma/hfi1/user_sdma.c b/drivers/staging/rdma/hfi1/user_sdma.c
index 36c838d..95a6d99 100644
--- a/drivers/staging/rdma/hfi1/user_sdma.c
+++ b/drivers/staging/rdma/hfi1/user_sdma.c
@@ -146,8 +146,8 @@ MODULE_PARM_DESC(sdma_comp_size, "Size of User SDMA completion ring. Default: 12
 #define KDETH_OM_MAX_SIZE  (1 << ((KDETH_OM_LARGE / KDETH_OM_SMALL) + 1))
 
 /* Last packet in the request */
-#define TXREQ_FLAGS_REQ_LAST_PKT   (1 << 0)
-#define TXREQ_FLAGS_IOVEC_LAST_PKT (1 << 0)
+#define TXREQ_FLAGS_REQ_LAST_PKT   BIT(1 << 0)
+#define TXREQ_FLAGS_IOVEC_LAST_PKT BIT(1 << 0)
 
 #define SDMA_REQ_IN_USE     0
 #define SDMA_REQ_FOR_THREAD 1
@@ -156,9 +156,9 @@ MODULE_PARM_DESC(sdma_comp_size, "Size of User SDMA completion ring. Default: 12
 #define SDMA_REQ_HAS_ERROR  4
 #define SDMA_REQ_DONE_ERROR 5
 
-#define SDMA_PKT_Q_INACTIVE (1 << 0)
-#define SDMA_PKT_Q_ACTIVE   (1 << 1)
-#define SDMA_PKT_Q_DEFERRED (1 << 2)
+#define SDMA_PKT_Q_INACTIVE BIT(1 << 0)
+#define SDMA_PKT_Q_ACTIVE   BIT(1 << 1)
+#define SDMA_PKT_Q_DEFERRED BIT(1 << 2)
 
 /*
  * Maximum retry attempts to submit a TX request
-- 
2.1.4

--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2015-11-05 17:06 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-11-05 11:58 [PATCH 1/1] staging: rdma: hfi1 : Prefer using the BIT macro Sunny Kumar
2015-11-05 13:27 ` Leon Romanovsky
2015-11-05 14:24 ` Marciniszyn, Mike
2015-11-05 17:06 ` ira.weiny

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).