On Wed, Sep 11, 2019 at 05:42:01PM +0100, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" <dgilb...@redhat.com> > > Use the automatic read unlocker in migration/ram.c; > only for the cases where the unlock is at the end of the function. > > Signed-off-by: Dr. David Alan Gilbert <dgilb...@redhat.com> > --- > migration/ram.c | 25 +++++++++---------------- > 1 file changed, 9 insertions(+), 16 deletions(-) > > diff --git a/migration/ram.c b/migration/ram.c > index b2bd618a89..750d198f37 100644 > --- a/migration/ram.c > +++ b/migration/ram.c > @@ -181,14 +181,14 @@ int foreach_not_ignored_block(RAMBlockIterFunc func, > void *opaque) > RAMBlock *block; > int ret = 0; > > - rcu_read_lock(); > + RCU_READ_LOCK_AUTO
FWIW, I'm not a fan of macros which are used without a trailing ';' as I believe it can confuses editors' code indentation logic. Regards, Daniel -- |: https://berrange.com -o- https://www.flickr.com/photos/dberrange :| |: https://libvirt.org -o- https://fstop138.berrange.com :| |: https://entangle-photo.org -o- https://www.instagram.com/dberrange :|