lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <CAOhMmr4K3kbGRSozw9GLpeo=8pTExeb3_Zu0A4O0UXdykHGEyQ@mail.gmail.com>
Date:   Wed, 27 Jan 2021 19:39:22 -0600
From:   Lijun Pan <lijunp213@...il.com>
To:     Jakub Kicinski <kuba@...nel.org>
Cc:     Lijun Pan <ljp@...ux.ibm.com>, netdev@...r.kernel.org
Subject: Re: [PATCH net v2] ibmvnic: Ensure that CRQ entry read are correctly ordered

On Wed, Jan 27, 2021 at 7:31 PM Jakub Kicinski <kuba@...nel.org> wrote:
>
> On Wed, 27 Jan 2021 19:22:25 -0600 Lijun Pan wrote:
> > On Wed, Jan 27, 2021 at 7:06 PM Jakub Kicinski <kuba@...nel.org> wrote:
> > >
> > > On Mon, 25 Jan 2021 17:20:23 -0600 Lijun Pan wrote:
> > > > Ensure that received Command-Response Queue (CRQ) entries are
> > > > properly read in order by the driver. dma_rmb barrier has
> > > > been added before accessing the CRQ descriptor to ensure
> > > > the entire descriptor is read before processing.
> > > >
> > > > Fixes: 032c5e82847a ("Driver for IBM System i/p VNIC protocol")
> > > > Signed-off-by: Lijun Pan <ljp@...ux.ibm.com>
> > > > ---
> > > > v2: drop dma_wmb according to Jakub's opinion
> > > >
> > > >  drivers/net/ethernet/ibm/ibmvnic.c | 8 ++++++++
> > > >  1 file changed, 8 insertions(+)
> > > >
> > > > diff --git a/drivers/net/ethernet/ibm/ibmvnic.c b/drivers/net/ethernet/ibm/ibmvnic.c
> > > > index 9778c83150f1..d84369bd5fc9 100644
> > > > --- a/drivers/net/ethernet/ibm/ibmvnic.c
> > > > +++ b/drivers/net/ethernet/ibm/ibmvnic.c
> > > > @@ -5084,6 +5084,14 @@ static void ibmvnic_tasklet(struct tasklet_struct *t)
> > > >       while (!done) {
> > > >               /* Pull all the valid messages off the CRQ */
> > > >               while ((crq = ibmvnic_next_crq(adapter)) != NULL) {
> > > > +                     /* Ensure that the entire CRQ descriptor queue->msgs
> > > > +                      * has been loaded before reading its contents.
> > >
> > > I still find this sentence confusing, maybe you mean to say stored
> > > instead of loaded?
> >
> > The above 2 lines are the general description. The below 4 lines are
> > detailed explanations. If it is still confusing, we can delete the above
> > 2 lines of comments.
>
> Yes, I'd find the comment clearer without them, thanks.

v3 has been sent out:
https://patchwork.kernel.org/project/netdevbpf/patch/20210128013442.88319-1-ljp@linux.ibm.com/

Thanks,
Lijun

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ