nvmet-fc: use RCU list iterator for assoc_list
authorDaniel Wagner <dwagner@suse.de>
Wed, 31 Jan 2024 08:51:12 +0000 (09:51 +0100)
committerKeith Busch <kbusch@kernel.org>
Thu, 1 Feb 2024 15:44:52 +0000 (07:44 -0800)
commita90ac7b348770ff3d246fac575306783de381e51
tree41e00b711ebbd3e036d956b18726d222a870b144
parentfe506a74589326183297d5abdda02d0c76ae5a8b
nvmet-fc: use RCU list iterator for assoc_list

The assoc_list is a RCU protected list, thus use the RCU flavor of list
functions.

Let's use this opportunity and refactor this code and move the lookup
into a helper and give it a descriptive name.

Signed-off-by: Daniel Wagner <dwagner@suse.de>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Keith Busch <kbusch@kernel.org>
drivers/nvme/target/fc.c