Re: [PATCH] loop: add WQ_MEM_RECLAIM flag to per device workqueue

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

 



On Thu, Mar 17, 2022 at 11:08:04PM +0900, Tetsuo Handa wrote:
> Commit 87579e9b7d8dc36e ("loop: use worker per cgroup instead of kworker")
> again started using per device workqueue
> 
> -       lo->worker_task = kthread_run(loop_kthread_worker_fn,
> -                       &lo->worker, "loop%d", lo->lo_number);
> +       lo->workqueue = alloc_workqueue("loop%d",
> +                                       WQ_UNBOUND | WQ_FREEZABLE,
> +                                       0,
> +                                       lo->lo_number);
> 
> but forgot to restore WQ_MEM_RECLAIM flag.

Early versions of the patch did have WQ_MEM_RECLAIM but it was
removed. I looked up my notes and found this:

Changes since V11:

* Removed WQ_MEM_RECLAIM flag from loop workqueue. Technically, this
  can be driven by writeback, but this was causing a warning in xfs
  and likely other filesystems aren't equipped to be driven by reclaim
  at the VFS layer.

I don't know if this is still the case. Can you test it?

> I don't know why WQ_FREEZABLE flag was added

My memory here is hazy and I don't have it in my notes but the same is
done in block/blk-cgroup.c which is conceptually quite similar.



[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