From: Leon Romanovsky <leon@kernel.org>
To: Christoph Hellwig <hch@infradead.org>
Cc: Doug Ledford <dledford@redhat.com>,
Jason Gunthorpe <jgg@nvidia.com>,
Yishai Hadas <yishaih@mellanox.com>,
linux-rdma@vger.kernel.org
Subject: Re: [PATCH rdma-next 2/4] IB/core: Enable ODP sync without faulting
Date: Wed, 16 Sep 2020 21:19:11 +0300 [thread overview]
Message-ID: <20200916181911.GL486552@unreal> (raw)
In-Reply-To: <20200916164706.GB11582@infradead.org>
On Wed, Sep 16, 2020 at 05:47:06PM +0100, Christoph Hellwig wrote:
> > + if (fault) {
> > + /*
> > + * Since we asked for hmm_range_fault() to populate pages,
>
> Totally pointless line over 80 characters.
checkpatch.pl was updated to allow 100 symbols.
Regarding "pointless", at least for me it wasn't clear why we don't
have HMM_PFN_ERROR check in non-fault path so I asked form Yishai to
add this comment.
>
> > + access_mask = (range.hmm_pfns[pfn_index] & HMM_PFN_WRITE) ?
> > + (ODP_READ_ALLOWED_BIT | ODP_WRITE_ALLOWED_BIT) :
> > + ODP_READ_ALLOWED_BIT;
> > + }
>
> Another weird overly long line, caused by rather osfucated code. This
> really should be something like:
>
> access_mask = ODP_READ_ALLOWED_BIT;
> if (range.hmm_pfns[pfn_index] & HMM_PFN_WRITE)
> access_mask |= ODP_WRITE_ALLOWED_BIT;
Sure
>
next prev parent reply other threads:[~2020-09-16 18:19 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-14 11:39 [PATCH rdma-next 0/4] Improve ODP by using HMM API Leon Romanovsky
2020-09-14 11:39 ` [PATCH rdma-next 1/4] IB/core: Improve ODP to use hmm_range_fault() Leon Romanovsky
2020-09-16 16:45 ` Christoph Hellwig
2020-09-16 17:21 ` Jason Gunthorpe
2020-09-16 17:22 ` Christoph Hellwig
2020-09-17 10:01 ` Yishai Hadas
2020-09-17 9:54 ` Yishai Hadas
2020-09-14 11:39 ` [PATCH rdma-next 2/4] IB/core: Enable ODP sync without faulting Leon Romanovsky
2020-09-16 16:47 ` Christoph Hellwig
2020-09-16 18:19 ` Leon Romanovsky [this message]
2020-09-16 18:25 ` Christoph Hellwig
2020-09-16 18:30 ` Leon Romanovsky
2020-09-17 10:05 ` Yishai Hadas
2020-09-14 11:39 ` [PATCH rdma-next 3/4] RDMA/mlx5: Extend advice MR to support non faulting mode Leon Romanovsky
2020-09-14 11:39 ` [PATCH rdma-next 4/4] RDMA/mlx5: Sync device with CPU pages upon ODP MR registration Leon Romanovsky
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=20200916181911.GL486552@unreal \
--to=leon@kernel.org \
--cc=dledford@redhat.com \
--cc=hch@infradead.org \
--cc=jgg@nvidia.com \
--cc=linux-rdma@vger.kernel.org \
--cc=yishaih@mellanox.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.