xcopy: loop over devices using idr helper
authorMike Christie <mchristi@redhat.com>
Fri, 23 Jun 2017 06:18:17 +0000 (01:18 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sun, 17 Jan 2021 12:55:13 +0000 (13:55 +0100)
commitb0b95504f4e60a2aae6706655dfae46152258c4b
tree29751851f820f5ff5f1ec1c0301dab74dbf98ce2
parentaf1fb5dcffb4348e37b9b36c4e7d8e5078c67bed
xcopy: loop over devices using idr helper

[ Upstream commit 6906d008b4b06e42cad393ac25bec76fbf31fabd ]

This converts the xcopy code to use the idr helper. The next patch
will drop the g_device_list and make g_device_mutex local to the
target_core_device.c file.

Signed-off-by: Mike Christie <mchristi@redhat.com>
Reviewed-by: Bart Van Assche <bart.vanassche@wdc.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/target/target_core_xcopy.c