[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <ZgHOR3BA2ui5zvVH@slm.duckdns.org>
Date: Mon, 25 Mar 2024 09:19:35 -1000
From: Tejun Heo <tj@...nel.org>
To: Dan Williams <dan.j.williams@...el.com>
Cc: Lai Jiangshan <jiangshanlai@...il.com>, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] workqueue: Cleanup subsys attribute registration
On Thu, Mar 07, 2024 at 09:39:32PM -0800, Dan Williams wrote:
> While reviewing users of subsys_virtual_register() I noticed that
> wq_sysfs_init() ignores the @groups argument. This looks like a
> historical artifact as the original wq_subsys only had one attribute to
> register.
>
> On the way to building up an @groups argument to pass to
> subsys_virtual_register() a few more cleanups fell out:
>
> * Use DEVICE_ATTR_RO() and DEVICE_ATTR_RW() for
> cpumask_{isolated,requested} and cpumask respectively. Rename the
> @show and @store methods accordingly.
>
> * Co-locate the attribute definition with the methods. This required
> moving wq_unbound_cpumask_show down next to wq_unbound_cpumask_store
> (renamed to cpumask_show() and cpumask_store())
>
> * Use ATTRIBUTE_GROUPS() to skip some boilerplate declarations
>
> Cc: Tejun Heo <tj@...nel.org>
> Cc: Lai Jiangshan <jiangshanlai@...il.com>
> Signed-off-by: Dan Williams <dan.j.williams@...el.com>
> ---
> Hi Tejun, just a drive-by cleanup while poking around sysfs.
Applied to wq/for-6.10. Thank you so much.
--
tejun
Powered by blists - more mailing lists