Thread (28 messages) 28 messages, 3 authors, 2016-05-23

Re: [RESEND PATCH v7 07/21] IB/hns: Add event queue support

From: Doug Ledford <hidden>
Date: 2016-05-13 21:21:51
Also in: linux-rdma, lkml

On 05/09/2016 11:04 PM, Lijun Ou wrote:
quoted hunk ↗ jump to hunk
--- a/drivers/infiniband/hw/hns/hns_roce_device.h
+++ b/drivers/infiniband/hw/hns/hns_roce_device.h
quoted hunk ↗ jump to hunk
@@ -29,10 +31,93 @@
 #define HNS_ROCE_AEQE_VEC_NUM			1
 #define HNS_ROCE_AEQE_OF_VEC_NUM		1
 
+#define ADDR_SHIFT_12				12
 #define ADDR_SHIFT_32				32
+#define ADDR_SHIFT_44				44
I saw some of the early review requests to replace hard coded values
with defines so that things made more sense.  And you've done a lot of
that quite well.  However, this one is not so helpful.  Sure, it's an
address shift, but the define gives no context as to why these shifts
are what they are.  Someone from the x86 world might mistakenly think
the 12 shift is all about page size shifting, but on arm you have
multiple different page sizes and 12 may not work at all.  So, some
context in the name for these items, or else a comment above these
defines letting us know what's special about these three shift values
would be helpful.

-- 
Doug Ledford [off-list ref]
              GPG KeyID: 0E572FDD

Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help