Thread (20 messages) 20 messages, 4 authors, 2025-03-04

Re: [PATCHv5 2/7] block: move q->sysfs_lock and queue-freeze under show/store method

From: Ming Lei <hidden>
Date: 2025-02-28 08:39:41

On Wed, Feb 26, 2025 at 06:09:55PM +0530, Nilay Shroff wrote:
In preparation to further simplify and group sysfs attributes which
don't require locking or require some form of locking other than q->
limits_lock, move acquire/release of q->sysfs_lock and queue freeze/
unfreeze under each attributes' respective show/store method.

While we are at it, also remove ->load_module() as it's used to load
the module before queue is freezed. Now as we moved queue-freeze under
->store(), we could load module directly from the attributes' store
method before we actually start freezing the queue. Currently, the
->load_module() is only used by "scheduler" attribute, so we now load
the relevant elevator module before we start freezing the queue in
elv_iosched_store().

Reviewed-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Nilay Shroff <redacted>
Ming Lei [off-list ref]


Thanks,
Ming
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help