summaryrefslogtreecommitdiffstats
path: root/drivers/target/target_core_tpg.c
diff options
context:
space:
mode:
authorAndy Grover2013-11-26 21:07:54 +0100
committerNicholas Bellinger2013-12-16 22:28:19 +0100
commitd344f8a15637e8b57a0d05a6d50182c11de08606 (patch)
treee4dc624eec2f9e2e8794d865f8ab62153666a72a /drivers/target/target_core_tpg.c
parenttarget: Refer to u32 luns as unpacked_lun (diff)
downloadkernel-qcow2-linux-d344f8a15637e8b57a0d05a6d50182c11de08606.tar.gz
kernel-qcow2-linux-d344f8a15637e8b57a0d05a6d50182c11de08606.tar.xz
kernel-qcow2-linux-d344f8a15637e8b57a0d05a6d50182c11de08606.zip
target: Rename core_tpg_{pre,post}_addlun for clarity
"pre" is really an allocation function. The only time it isn't called is for virtual_lun0, which is statically allocated. Renaming that to "alloc" lets the other function not need to be "post", and just be called core_tpg_add_lun. (nab: fix minor applying fuzz in core_tpg_setup_virtual_lun0) Signed-off-by: Andy Grover <agrover@redhat.com> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Diffstat (limited to 'drivers/target/target_core_tpg.c')
-rw-r--r--drivers/target/target_core_tpg.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/target/target_core_tpg.c b/drivers/target/target_core_tpg.c
index f697f8baec54..a1dbc9488183 100644
--- a/drivers/target/target_core_tpg.c
+++ b/drivers/target/target_core_tpg.c
@@ -662,7 +662,7 @@ static int core_tpg_setup_virtual_lun0(struct se_portal_group *se_tpg)
if (ret < 0)
return ret;
- ret = core_tpg_post_addlun(se_tpg, lun, lun_access, dev);
+ ret = core_tpg_add_lun(se_tpg, lun, lun_access, dev);
if (ret < 0) {
percpu_ref_cancel_init(&lun->lun_ref);
return ret;
@@ -789,7 +789,7 @@ int core_tpg_deregister(struct se_portal_group *se_tpg)
}
EXPORT_SYMBOL(core_tpg_deregister);
-struct se_lun *core_tpg_pre_addlun(
+struct se_lun *core_tpg_alloc_lun(
struct se_portal_group *tpg,
u32 unpacked_lun)
{
@@ -819,7 +819,7 @@ struct se_lun *core_tpg_pre_addlun(
return lun;
}
-int core_tpg_post_addlun(
+int core_tpg_add_lun(
struct se_portal_group *tpg,
struct se_lun *lun,
u32 lun_access,