Re: [PATCH] block: disable the elevator int del_gendisk

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Jun 01, 2022 at 09:14:29AM +0200, Christoph Hellwig wrote:
> On Wed, Jun 01, 2022 at 03:09:26PM +0800, Ming Lei wrote:
> > > Yes, we probably need a blk_mq_quiesce_queue call like in the incremental
> > > patch below.  Do you have any good reproducer, though?
> > 
> > blktests block/027 should cover this.
> 
> That did not trigger the problem for me.

This kind of issue is often not 100% duplicated.

> 
> > >  	if (q->elevator) {
> > > +		blk_mq_quiesce_queue(q);
> > > +
> > >  		mutex_lock(&q->sysfs_lock);
> > >  		elevator_exit(q);
> > >  		mutex_unlock(&q->sysfs_lock);
> > > +
> > > +		blk_mq_unquiesce_queue(q);
> > >  	}
> > >  
> > 
> > I am afraid the above way may slow down disk shutdown a lot, see
> > the following commit, that is also the reason why I moved it into disk
> > release handler, when any sync io submission are done.
> 
> SCSI devices that are just probed and never had a disk attached will
> not have q->elevator set and not hit this quiesce at all.

Yes, but host with hundreds of real LUNs may be shutdown slowly too
since sd_remove() won't be called in async way.


Thanks,
Ming




[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux