Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1400991

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

From Doug Ledford <dledford@redhat.com>
Newsgroups linux.kernel
Subject Re: [RESEND PATCH v7 07/21] IB/hns: Add event queue support
Date 2016-05-13 23:30 +0200
Message-ID <rysOK-35p-1@gated-at.bofh.it> (permalink)
References <rx63T-1LN-5@gated-at.bofh.it> <rx63U-1LN-23@gated-at.bofh.it>
Organization Red Hat, Inc.

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

On 05/09/2016 11:04 PM, Lijun Ou wrote:

> --- a/drivers/infiniband/hw/hns/hns_roce_device.h
> +++ b/drivers/infiniband/hw/hns/hns_roce_device.h

> @@ -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 <dledford@redhat.com>
              GPG KeyID: 0E572FDD


Back to linux.kernel | Previous | Next | Find similar | Unroll thread


Thread

Re: [RESEND PATCH v7 07/21] IB/hns: Add event queue support Doug Ledford <dledford@redhat.com> - 2016-05-13 23:30 +0200

csiph-web