blk-integrity: register sysfs attributes on struct device
Upstream commit ff53cd52. The "integrity" kobject only acted as a holder for static sysfs entries. It also was embedded into struct gendisk without managing it, violating assumptions of the driver core. Instead register the sysfs entries directly onto the struct device. Also drop the now unused member integrity_kobj from struct gendisk. Suggested-by:Christoph Hellwig <hch@infradead.org> Signed-off-by:
Thomas Weißschuh <linux@weissschuh.net> Reviewed-by:
Christoph Hellwig <hch@lst.de> Reviewed-by:
Martin K. Petersen <martin.petersen@oracle.com> Link: https://lore.kernel.org/r/20230309-kobj_release-gendisk_integrity-v3-3-ceccb4493c46@weissschuh.net Signed-off-by:
Jens Axboe <axboe@kernel.dk> [cascardo: conflict because of constification of integrity_ktype] Signed-off-by:
Thadeu Lima de Souza Cascardo <cascardo@igalia.com> Signed-off-by:
Sasha Levin <sashal@kernel.org>
Loading
Please sign in to comment