1
2 #include <target/target_core_base.h>
3 #include <linux/btree.h>
4
5
6 #define TCM_QLA2XXX_NAMELEN 32
7
8
9
10
11 #define TCM_QLA2XXX_DEFAULT_TAGS 2088
12
13 #include "qla_target.h"
14
15 struct tcm_qla2xxx_nacl {
16 struct se_node_acl se_node_acl;
17
18
19 u32 nport_id;
20
21 u64 nport_wwnn;
22
23 char nport_name[TCM_QLA2XXX_NAMELEN];
24
25 struct fc_port *fc_port;
26
27 struct se_session *nport_nexus;
28 };
29
30 struct tcm_qla2xxx_tpg_attrib {
31 int generate_node_acls;
32 int cache_dynamic_acls;
33 int demo_mode_write_protect;
34 int prod_mode_write_protect;
35 int demo_mode_login_only;
36 int fabric_prot_type;
37 int jam_host;
38 };
39
40 struct tcm_qla2xxx_tpg {
41
42 u16 lport_tpgt;
43
44 atomic_t lport_tpg_enabled;
45
46 struct tcm_qla2xxx_lport *lport;
47
48 struct tcm_qla2xxx_tpg_attrib tpg_attrib;
49
50 struct se_portal_group se_tpg;
51 };
52
53 struct tcm_qla2xxx_fc_loopid {
54 struct se_node_acl *se_nacl;
55 };
56
57 struct tcm_qla2xxx_lport {
58
59 u64 lport_wwpn;
60
61 u64 lport_npiv_wwpn;
62
63 u64 lport_npiv_wwnn;
64
65 char lport_name[TCM_QLA2XXX_NAMELEN];
66
67 char lport_naa_name[TCM_QLA2XXX_NAMELEN];
68
69 struct btree_head32 lport_fcport_map;
70
71 struct tcm_qla2xxx_fc_loopid *lport_loopid_map;
72
73 struct scsi_qla_host *qla_vha;
74
75 struct qla_tgt lport_qla_tgt;
76
77 struct tcm_qla2xxx_tpg *tpg_1;
78
79 struct se_wwn lport_wwn;
80 };