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: <20220330012204-mutt-send-email-mst@kernel.org>
Date:   Wed, 30 Mar 2022 01:22:15 -0400
From:   "Michael S. Tsirkin" <mst@...hat.com>
To:     Jason Wang <jasowang@...hat.com>
Cc:     Stefano Garzarella <sgarzare@...hat.com>,
        virtualization@...ts.linux-foundation.org,
        linux-kernel@...r.kernel.org, maz@...nel.org, tglx@...utronix.de,
        peterz@...radead.org, keirf@...gle.com
Subject: Re: [PATCH 1/3] virtio: use virtio_device_ready() in
 virtio_device_restore()

On Fri, Mar 25, 2022 at 11:05:22AM +0800, Jason Wang wrote:
> 
> 在 2022/3/24 下午7:31, Stefano Garzarella 写道:
> > On Thu, Mar 24, 2022 at 07:07:09AM -0400, Michael S. Tsirkin wrote:
> > > On Thu, Mar 24, 2022 at 12:03:07PM +0100, Stefano Garzarella wrote:
> > > > On Thu, Mar 24, 2022 at 06:48:05AM -0400, Michael S. Tsirkin wrote:
> > > > > On Thu, Mar 24, 2022 at 04:40:02PM +0800, Jason Wang wrote:
> > > > > > From: Stefano Garzarella <sgarzare@...hat.com>
> > > > > >
> > > > > > This avoids setting DRIVER_OK twice for those drivers that call
> > > > > > virtio_device_ready() in the .restore
> > > > >
> > > > > Is this trying to say it's faster?
> > > > 
> > > > Nope, I mean, when I wrote the original version, I meant to do the same
> > > > things that we do in virtio_dev_probe() where we called
> > > > virtio_device_ready() which not only set the state, but also called
> > > > .enable_cbs callback.
> > > > 
> > > > Was this a side effect and maybe more compliant with the spec?
> > > 
> > > 
> > > Sorry I don't understand the question. it says "avoids setting
> > > DRIVER_OK twice" -
> > > why is that advantageous and worth calling out in the commit log?
> > 
> > I just wanted to say that it seems strange to set DRIVER_OK twice if we
> > read the spec. I don't think it's wrong, but weird.
> > 
> > Yes, maybe we should rewrite the commit message saying that we want to
> > use virtio_device_ready() everywhere to complete the setup before
> > setting DRIVER_OK so we can do all the necessary operations inside (like
> > in patch 3 or call enable_cbs).
> > 
> > Jason rewrote the commit log, so I don't know if he agrees.
> > 
> > Thanks,
> > Stefano
> 
> 
> I agree, I will tweak the log in V2.
> 
> Thanks

Still waiting for that v2.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ