]> asedeno.scripts.mit.edu Git - linux.git/commit
target: use idr for se_device dev index
authorMike Christie <mchristi@redhat.com>
Fri, 23 Jun 2017 06:18:13 +0000 (01:18 -0500)
committerNicholas Bellinger <nab@linux-iscsi.org>
Fri, 7 Jul 2017 06:11:37 +0000 (23:11 -0700)
commit0a5eee647b78e53da05e081362f42a11b4b674eb
tree3cd717baa7b335e9887c9c198f90b1e084419a3d
parent926347061ef1f4d3873829fd1960c6e4b965aa9f
target: use idr for se_device dev index

In the next patches we will add tcmu netlink support that allows
userspace to send commands to target_core_user. To execute operations
on a se_device/tcmu_dev we need to be able to look up a dev by any old
id. This patch replaces the se_device->dev_index with a idr created
id.

The next patches will also remove the g_device_list and replace it with
the idr.

Signed-off-by: Mike Christie <mchristi@redhat.com>
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
drivers/target/target_core_device.c
include/target/target_core_base.h