summaryrefslogtreecommitdiffstats
path: root/Documentation
diff options
context:
space:
mode:
authorChristoph Hellwig <hch@lst.de>2015-04-13 13:51:16 -0400
committerNicholas Bellinger <nab@linux-iscsi.org>2015-05-31 01:42:23 -0400
commit144bc4c2a42a0f42a32c106d53f5bf2724fbf098 (patch)
tree1b1a1a6b0dabea88e6dcef368305c6bac3c33648 /Documentation
parente413f4727037e826c55a639c713a221006b6d61d (diff)
target: move node ACL allocation to core code
Signed-off-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
Diffstat (limited to 'Documentation')
-rwxr-xr-xDocumentation/target/tcm_mod_builder.py27
1 files changed, 0 insertions, 27 deletions
diff --git a/Documentation/target/tcm_mod_builder.py b/Documentation/target/tcm_mod_builder.py
index 3e54809b3aa1..07e7ef3d7429 100755
--- a/Documentation/target/tcm_mod_builder.py
+++ b/Documentation/target/tcm_mod_builder.py
@@ -313,8 +313,6 @@ def tcm_mod_build_configfs(proto_ident, fabric_mod_dir_var, fabric_mod_name):
313 buf += " .tpg_check_demo_mode_cache = " + fabric_mod_name + "_check_true,\n" 313 buf += " .tpg_check_demo_mode_cache = " + fabric_mod_name + "_check_true,\n"
314 buf += " .tpg_check_demo_mode_write_protect = " + fabric_mod_name + "_check_true,\n" 314 buf += " .tpg_check_demo_mode_write_protect = " + fabric_mod_name + "_check_true,\n"
315 buf += " .tpg_check_prod_mode_write_protect = " + fabric_mod_name + "_check_false,\n" 315 buf += " .tpg_check_prod_mode_write_protect = " + fabric_mod_name + "_check_false,\n"
316 buf += " .tpg_alloc_fabric_acl = " + fabric_mod_name + "_alloc_fabric_acl,\n"
317 buf += " .tpg_release_fabric_acl = " + fabric_mod_name + "_release_fabric_acl,\n"
318 buf += " .tpg_get_inst_index = " + fabric_mod_name + "_tpg_get_inst_index,\n" 316 buf += " .tpg_get_inst_index = " + fabric_mod_name + "_tpg_get_inst_index,\n"
319 buf += " .release_cmd = " + fabric_mod_name + "_release_cmd,\n" 317 buf += " .release_cmd = " + fabric_mod_name + "_release_cmd,\n"
320 buf += " .shutdown_session = " + fabric_mod_name + "_shutdown_session,\n" 318 buf += " .shutdown_session = " + fabric_mod_name + "_shutdown_session,\n"
@@ -624,31 +622,6 @@ def tcm_mod_dump_fabric_ops(proto_ident, fabric_mod_dir_var, fabric_mod_name):
624 bufi += "char *" + fabric_mod_name + "_parse_pr_out_transport_id(struct se_portal_group *,\n" 622 bufi += "char *" + fabric_mod_name + "_parse_pr_out_transport_id(struct se_portal_group *,\n"
625 bufi += " const char *, u32 *, char **);\n" 623 bufi += " const char *, u32 *, char **);\n"
626 624
627 if re.search('alloc_fabric_acl\)\(', fo):
628 buf += "struct se_node_acl *" + fabric_mod_name + "_alloc_fabric_acl(struct se_portal_group *se_tpg)\n"
629 buf += "{\n"
630 buf += " struct " + fabric_mod_name + "_nacl *nacl;\n\n"
631 buf += " nacl = kzalloc(sizeof(struct " + fabric_mod_name + "_nacl), GFP_KERNEL);\n"
632 buf += " if (!nacl) {\n"
633 buf += " printk(KERN_ERR \"Unable to allocate struct " + fabric_mod_name + "_nacl\\n\");\n"
634 buf += " return NULL;\n"
635 buf += " }\n\n"
636 buf += " return &nacl->se_node_acl;\n"
637 buf += "}\n\n"
638 bufi += "struct se_node_acl *" + fabric_mod_name + "_alloc_fabric_acl(struct se_portal_group *);\n"
639
640 if re.search('release_fabric_acl\)\(', fo):
641 buf += "void " + fabric_mod_name + "_release_fabric_acl(\n"
642 buf += " struct se_portal_group *se_tpg,\n"
643 buf += " struct se_node_acl *se_nacl)\n"
644 buf += "{\n"
645 buf += " struct " + fabric_mod_name + "_nacl *nacl = container_of(se_nacl,\n"
646 buf += " struct " + fabric_mod_name + "_nacl, se_node_acl);\n"
647 buf += " kfree(nacl);\n"
648 buf += "}\n\n"
649 bufi += "void " + fabric_mod_name + "_release_fabric_acl(struct se_portal_group *,\n"
650 bufi += " struct se_node_acl *);\n"
651
652 if re.search('tpg_get_inst_index\)\(', fo): 625 if re.search('tpg_get_inst_index\)\(', fo):
653 buf += "u32 " + fabric_mod_name + "_tpg_get_inst_index(struct se_portal_group *se_tpg)\n" 626 buf += "u32 " + fabric_mod_name + "_tpg_get_inst_index(struct se_portal_group *se_tpg)\n"
654 buf += "{\n" 627 buf += "{\n"