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] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200410143412.GK11244@42.do-not-panic.com>
Date:   Fri, 10 Apr 2020 14:34:12 +0000
From:   Luis Chamberlain <mcgrof@...nel.org>
To:     Bart Van Assche <bvanassche@....org>
Cc:     axboe@...nel.dk, viro@...iv.linux.org.uk,
        gregkh@...uxfoundation.org, rostedt@...dmis.org, mingo@...hat.com,
        jack@...e.cz, ming.lei@...hat.com, nstange@...e.de,
        akpm@...ux-foundation.org, mhocko@...e.com, yukuai3@...wei.com,
        linux-block@...r.kernel.org, linux-fsdevel@...r.kernel.org,
        linux-mm@...ck.org, linux-kernel@...r.kernel.org,
        Omar Sandoval <osandov@...com>,
        Hannes Reinecke <hare@...e.com>,
        Michal Hocko <mhocko@...nel.org>
Subject: Re: [RFC v2 5/5] block: revert back to synchronous request_queue
 removal

On Thu, Apr 09, 2020 at 08:12:21PM -0700, Bart Van Assche wrote:
> On 2020-04-09 14:45, Luis Chamberlain wrote:
> > blk_put_queue() puts decrements the refcount for the request_queue
>                   ^^^^
>         can this word be left out?

Sure.

> > diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h
> > index 8b1cab52cef9..46fee1ef92e3 100644
> > --- a/include/linux/blkdev.h
> > +++ b/include/linux/blkdev.h
> > @@ -614,6 +614,7 @@ struct request_queue {
> >  #define QUEUE_FLAG_PCI_P2PDMA	25	/* device supports PCI p2p requests */
> >  #define QUEUE_FLAG_ZONE_RESETALL 26	/* supports Zone Reset All */
> >  #define QUEUE_FLAG_RQ_ALLOC_TIME 27	/* record rq->alloc_time_ns */
> > +#define QUEUE_FLAG_DEFER_REMOVAL 28	/* defer queue removal */
> >  
> >  #define QUEUE_FLAG_MQ_DEFAULT	((1 << QUEUE_FLAG_IO_STAT) |		\
> >  				 (1 << QUEUE_FLAG_SAME_COMP))
> > @@ -648,6 +649,8 @@ bool blk_queue_flag_test_and_set(unsigned int flag, struct request_queue *q);
> >  #else
> >  #define blk_queue_rq_alloc_time(q)	false
> >  #endif
> > +#define blk_queue_defer_removal(q) \
> > +	test_bit(QUEUE_FLAG_DEFER_REMOVAL, &(q)->queue_flags)
> 
> Since blk_queue_defer_removal() has no callers the code that depends on
> QUEUE_FLAG_DEFER_REMOVAL to be set will be subject to bitrot. It would
> make me happy if the QUEUE_FLAG_DEFER_REMOVAL flag and the code that
> depends on that flag would be removed.

Sure thing.

Feedback on the cover letter thread patch 0/5 about whether or not to
consider userspace impact changes on these changes should be detailed on
the commit log would be useful.

> Please add a might_sleep() call in blk_put_queue() since with this patch
> applied it is no longer allowed to call blk_put_queue() from atomic context.

Sure thing.

  Luis

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ