Lines Matching +full:target +full:- +full:module

2 The TCM v4 fabric module script generator
7 This document is intended to be a mini-HOWTO for using the tcm_mod_builder.py
8 script to generate a brand new functional TCM v4 fabric .ko module of your very own,
13 mkdir -p /sys/kernel/config/target/$TCM_NEW_MOD
15 This script will create a new drivers/target/$TCM_NEW_MOD/, and will do the following
17 1) Generate new API callers for drivers/target/target_core_fabric_configs.c logic
18 ->make_tpg(), ->drop_tpg(), ->make_wwn(), ->drop_wwn(). These are created
20 2) Generate basic infrastructure for loading/unloading LKMs and TCM/ConfigFS fabric module
22 3) Based on user defined T10 Proto_Ident for the new fabric module being built,
23 the TransportID / Initiator and Target WWPN related handlers for
24 SPC-3 persistent reservation are automatically generated in $TCM_NEW_MOD/$TCM_NEW_MOD_fabric.c
25 using drivers/target/target_core_fabric_lib.c logic.
29 tcm_mod_builder.py depends upon the mandatory '-p $PROTO_IDENT' and '-m
32target:/mnt/sdb/lio-core-2.6.git/Documentation/target# python tcm_mod_builder.py -p iSCSI -m tcm_n…
33 tcm_dir: /mnt/sdb/lio-core-2.6.git/Documentation/target/../../
36 /mnt/sdb/lio-core-2.6.git/Documentation/target/../../drivers/target/tcm_nab5000
39 /mnt/sdb/lio-core-2.6.git/Documentation/target/../../drivers/target/tcm_nab5000
41 /mnt/sdb/lio-core-2.6.git/Documentation/target/../../drivers/target/tcm_nab5000/tcm_nab5000_base.h
43 /mnt/sdb/lio-core-2.6.git/Documentation/target/../../include/target/target_core_fabric_ops.h
45 …/mnt/sdb/lio-core-2.6.git/Documentation/target/../../drivers/target/tcm_nab5000/tcm_nab5000_fabric…
47 …/mnt/sdb/lio-core-2.6.git/Documentation/target/../../drivers/target/tcm_nab5000/tcm_nab5000_fabric…
49 …/mnt/sdb/lio-core-2.6.git/Documentation/target/../../drivers/target/tcm_nab5000/tcm_nab5000_config…
51 /mnt/sdb/lio-core-2.6.git/Documentation/target/../../drivers/target/tcm_nab5000/Kbuild
53 /mnt/sdb/lio-core-2.6.git/Documentation/target/../../drivers/target/tcm_nab5000/Kconfig
54 Would you like to add tcm_nab5000to drivers/target/Kbuild..? [yes,no]: yes
55 Would you like to add tcm_nab5000to drivers/target/Kconfig..? [yes,no]: yes
58 line to drivers/target/Kbuild::
60 obj-$(CONFIG_TCM_NAB5000) += tcm_nab5000/
62 and the same for drivers/target/Kconfig::
64 source "drivers/target/tcm_nab5000/Kconfig"
68 <M> TCM_NAB5000 fabric module
72 target:/mnt/sdb/lio-core-2.6.git# ls -la drivers/target/tcm_nab5000/
74 drwxr-xr-x 2 root root 4096 2010-10-05 03:23 .
75 drwxr-xr-x 9 root root 4096 2010-10-05 03:22 ..
76 -rw-r--r-- 1 root root 282 2010-10-05 03:22 Kbuild
77 -rw-r--r-- 1 root root 171 2010-10-05 03:22 Kconfig
78 -rw-r--r-- 1 root root 49 2010-10-05 03:23 modules.order
79 -rw-r--r-- 1 root root 738 2010-10-05 03:22 tcm_nab5000_base.h
80 -rw-r--r-- 1 root root 9096 2010-10-05 03:22 tcm_nab5000_configfs.c
81 -rw-r--r-- 1 root root 191200 2010-10-05 03:23 tcm_nab5000_configfs.o
82 -rw-r--r-- 1 root root 40504 2010-10-05 03:23 .tcm_nab5000_configfs.o.cmd
83 -rw-r--r-- 1 root root 5414 2010-10-05 03:22 tcm_nab5000_fabric.c
84 -rw-r--r-- 1 root root 2016 2010-10-05 03:22 tcm_nab5000_fabric.h
85 -rw-r--r-- 1 root root 190932 2010-10-05 03:23 tcm_nab5000_fabric.o
86 -rw-r--r-- 1 root root 40713 2010-10-05 03:23 .tcm_nab5000_fabric.o.cmd
87 -rw-r--r-- 1 root root 401861 2010-10-05 03:23 tcm_nab5000.ko
88 -rw-r--r-- 1 root root 265 2010-10-05 03:23 .tcm_nab5000.ko.cmd
89 -rw-r--r-- 1 root root 459 2010-10-05 03:23 tcm_nab5000.mod.c
90 -rw-r--r-- 1 root root 23896 2010-10-05 03:23 tcm_nab5000.mod.o
91 -rw-r--r-- 1 root root 22655 2010-10-05 03:23 .tcm_nab5000.mod.o.cmd
92 -rw-r--r-- 1 root root 379022 2010-10-05 03:23 tcm_nab5000.o
93 -rw-r--r-- 1 root root 211 2010-10-05 03:23 .tcm_nab5000.o.cmd
95 #) Load the new module, create a lun_0 configfs group, and add new TCM Core
98 target:/mnt/sdb/lio-core-2.6.git# insmod drivers/target/tcm_nab5000.ko
99target:/mnt/sdb/lio-core-2.6.git# mkdir -p /sys/kernel/config/target/nab5000/iqn.foo/tpgt_1/lun/lu…
100 target:/mnt/sdb/lio-core-2.6.git# cd /sys/kernel/config/target/nab5000/iqn.foo/tpgt_1/lun/lun_0/
101target:/sys/kernel/config/target/nab5000/iqn.foo/tpgt_1/lun/lun_0# ln -s /sys/kernel/config/target
103 target:/sys/kernel/config/target/nab5000/iqn.foo/tpgt_1/lun/lun_0# cd -
104 target:/mnt/sdb/lio-core-2.6.git# tree /sys/kernel/config/target/nab5000/
105 /sys/kernel/config/target/nab5000/
106 |-- discovery_auth
107 |-- iqn.foo
108 | `-- tpgt_1
109 | |-- acls
110 | |-- attrib
111 | |-- lun
112 | | `-- lun_0
113 | | |-- alua_tg_pt_gp
114 | | |-- alua_tg_pt_offline
115 | | |-- alua_tg_pt_status
116 | | |-- alua_tg_pt_write_md
117 | | `-- nab5000_port -> ../../../../../../target/core/iblock_0/lvm_test0
118 | |-- np
119 | `-- param
120 `-- version
122 target:/mnt/sdb/lio-core-2.6.git# lsmod
123 Module Size Used by
137 ----------------------------------------------------------------------
144 defs directly from include/target/target_core_fabric_ops.h:struct target_core_fabric_ops
149 Nicholas A. Bellinger <nab@linux-iscsi.org>