Re: [PATCH V2 2/2] block: fix "Directory XXXXX with parent 'block' already present!"

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

 



On Sun, Apr 24, 2022 at 10:53:29AM +0200, Hannes Reinecke wrote:
> On 4/23/22 16:39, Ming Lei wrote:
> > q->debugfs_dir is used by blk-mq debugfs and blktrace. The dentry is
> > created when adding disk, and removed when releasing request queue.
> > 
> > There is small window between releasing disk and releasing request
> > queue, and during the period, one disk with same name may be created
> > and added, so debugfs_create_dir() may complain with "Directory XXXXX
> > with parent 'block' already present!"
> > 
> > Fixes the issue by moving debugfs_create_dir() into blk_alloc_queue(),
> > and the dir name is named with q->id from beginning, and switched to
> > disk name when adding disk, and finally changed to q->id in disk_release().
> > 
> > Tested-by: Shin'ichiro Kawasaki <shinichiro.kawasaki@xxxxxxx>
> > Reported-by: Dan Williams <dan.j.williams@xxxxxxxxx>
> > Cc: yukuai (C) <yukuai3@xxxxxxxxxx>
> > Cc: Shin'ichiro Kawasaki <shinichiro.kawasaki@xxxxxxx>
> > Signed-off-by: Ming Lei <ming.lei@xxxxxxxxxx>
> > ---
> >   block/blk-core.c  | 4 ++++
> >   block/blk-sysfs.c | 4 ++--
> >   block/genhd.c     | 8 ++++++++
> >   3 files changed, 14 insertions(+), 2 deletions(-)
> > 
> Errm.
> 
> Isn't this superfluous now that Jens merged Yu Kuais patch?

Jens has dropped Yu Kuai's patch which caused kernel panic.


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