md: stop using for_each_mddev in md_exit
authorChristoph Hellwig <hch@lst.de>
Tue, 19 Jul 2022 09:18:22 +0000 (11:18 +0200)
committerSong Liu <song@kernel.org>
Wed, 20 Jul 2022 05:41:37 +0000 (22:41 -0700)
commit45e0d274008202cc336ba2fdf1f2129b4d888ea3
tree2d988a9d20b734236aae53d98052ed25e98a9ece
parent32389bb813f970befb44dcbde09704c937509cb4
md: stop using for_each_mddev in md_exit

Just do a simple list_for_each_entry_safe on all_mddevs, and only grab a
reference when we drop the lock and delete the now unused for_each_mddev
macro.

Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Logan Gunthorpe <logang@deltatee.com>
Reviewed-by: Hannes Reinecke <hare@suse.de>
Signed-off-by: Song Liu <song@kernel.org>
drivers/md/md.c