public inbox for linux-rdma@vger.kernel.org
 help / color / mirror / Atom feed
From: Jason Gunthorpe <jgg@nvidia.com>
To: Weihang Li <liweihang@huawei.com>
Cc: dledford@redhat.com, leon@kernel.org, linux-rdma@vger.kernel.org,
	linuxarm@huawei.com, Yixing Liu <liuyixing1@huawei.com>
Subject: Re: [PATCH for-next 8/9] RDMA/hns: Simplify the function config_eqc()
Date: Thu, 8 Apr 2021 16:13:34 -0300	[thread overview]
Message-ID: <20210408191334.GC692402@nvidia.com> (raw)
In-Reply-To: <1617354454-47840-9-git-send-email-liweihang@huawei.com>

On Fri, Apr 02, 2021 at 05:07:33PM +0800, Weihang Li wrote:
> -	roce_set_field(eqc->byte_40, HNS_ROCE_EQC_NXT_EQE_BA_L_M,
> -		       HNS_ROCE_EQC_NXT_EQE_BA_L_S, eqe_ba[1] >> 12);
> -
> -	roce_set_field(eqc->byte_44, HNS_ROCE_EQC_NXT_EQE_BA_H_M,
> -		       HNS_ROCE_EQC_NXT_EQE_BA_H_S, eqe_ba[1] >> 44);
> -
> -	roce_set_field(eqc->byte_44, HNS_ROCE_EQC_EQE_SIZE_M,
> -		       HNS_ROCE_EQC_EQE_SIZE_S,
> -		       eq->eqe_size == HNS_ROCE_V3_EQE_SIZE ? 1 : 0);
> +	hr_reg_write(eqc, EQC_EQ_ST, HNS_ROCE_V2_EQ_STATE_VALID);
> +	hr_reg_write(eqc, EQC_EQE_HOP_NUM, eq->hop_num);
> +	hr_reg_write(eqc, EQC_OVER_IGNORE, eq->over_ignore);
> +	hr_reg_write(eqc, EQC_COALESCE, eq->coalesce);

This really is a lot better like this, isn't it?

Jason

  reply	other threads:[~2021-04-08 19:13 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-04-02  9:07 [PATCH for-next 0/9] RDMA/hns: Misc updates for 5.13 Weihang Li
2021-04-02  9:07 ` [PATCH for-next 1/9] RDMA/hns: Avoid enabling RQ inline on UD Weihang Li
2021-04-02  9:07 ` [PATCH for-next 2/9] RDMA/hns: Fix missing assignment of max_inline_data Weihang Li
2021-04-02  9:07 ` [PATCH for-next 3/9] RDMA/hns: Delete redundant condition judgment related to eq Weihang Li
2021-04-02  9:07 ` [PATCH for-next 4/9] RDMA/hns: Delete redundant abnormal interrupt status Weihang Li
2021-04-02  9:07 ` [PATCH for-next 5/9] RDMA/hns: Delete unused members in the structure hns_roce_hw Weihang Li
2021-04-02  9:07 ` [PATCH for-next 6/9] RDMA/hns: Remove unsupported QP types Weihang Li
2021-04-02  9:07 ` [PATCH for-next 7/9] RDMA/hns: Add XRC subtype in QPC and XRC type in SRQC Weihang Li
2021-04-02  9:07 ` [PATCH for-next 8/9] RDMA/hns: Simplify the function config_eqc() Weihang Li
2021-04-08 19:13   ` Jason Gunthorpe [this message]
2021-04-09  1:39     ` liweihang
2021-04-02  9:07 ` [PATCH for-next 9/9] RDMA/hns: Prevent le32 from being implicitly converted to u32 Weihang Li
2021-04-08 19:14 ` [PATCH for-next 0/9] RDMA/hns: Misc updates for 5.13 Jason Gunthorpe

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210408191334.GC692402@nvidia.com \
    --to=jgg@nvidia.com \
    --cc=dledford@redhat.com \
    --cc=leon@kernel.org \
    --cc=linux-rdma@vger.kernel.org \
    --cc=linuxarm@huawei.com \
    --cc=liuyixing1@huawei.com \
    --cc=liweihang@huawei.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox