Re: [PATCH v4 01/10] blk-mq: Register /queue/mq after having registered /queue

Hannes Reinecke
2017-04-24T07:25:05Z

On 04/22/2017 01:40 AM, Bart Van Assche wrote:
> A later patch in this series will modify blk_mq_debugfs_register()
> such that it uses q->kobj.parent to determine the name of a
> request queue. Hence make sure that that pointer is initialized
> before blk_mq_debugfs_register() is called. To avoid lock inversion,
> protect sysfs / debugfs registration with the queue sysfs_lock
> instead of the global mutex all_q_mutex.
>
> Signed-off-by: Bart Van Assche <bart.vanassche@sandisk.com>
> Cc: Omar Sandoval <osandov@fb.com>
> Cc: Hannes Reinecke <hare@suse.com>
> ---
> block/blk-mq-sysfs.c | 35 ++++++++++++++++++++++++++++-------
> block/blk-mq.h | 1 +
> block/blk-sysfs.c | 6 +++---
> 3 files changed, 32 insertions(+), 10 deletions(-)
>
Reviewed-by: Hannes Reinecke <hare@suse.com>

Cheers,

Hannes
--
Dr. Hannes Reinecke zSeries & Storage
hare@suse.com +49 911 74053 688
SUSE LINUX GmbH, Maxfeldstr. 5, 90409 Nï¿½rnberg
GF: F. Imendï¿½rffer, J. Smithard, D. Upmanyu, G. Norton
HRB 21284 (AG Nï¿½rnberg)