diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-07-27 16:21:40 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-07-27 16:21:40 -0400 |
commit | 91d41fdf31f74e6e2e5f3cb018eca4200e36e202 (patch) | |
tree | 81ef11f06bd8047031a2d93706dc263fa1bacd56 /drivers/target/iscsi/iscsi_target_stat.h | |
parent | c1095c6da518b0b64e724f629051fa67655cd8d9 (diff) | |
parent | 277c5f27a2c86a9a733c0ec0f6a9b1032dfa3e15 (diff) |
Merge branch 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending
* 'for-next' of git://git.kernel.org/pub/scm/linux/kernel/git/nab/target-pending:
target: Convert to DIV_ROUND_UP_SECTOR_T usage for sectors / dev_max_sectors
kernel.h: Add DIV_ROUND_UP_ULL and DIV_ROUND_UP_SECTOR_T macro usage
iscsi-target: Add iSCSI fabric support for target v4.1
iscsi: Add Serial Number Arithmetic LT and GT into iscsi_proto.h
iscsi: Use struct scsi_lun in iscsi structs instead of u8[8]
iscsi: Resolve iscsi_proto.h naming conflicts with drivers/target/iscsi
Diffstat (limited to 'drivers/target/iscsi/iscsi_target_stat.h')
-rw-r--r-- | drivers/target/iscsi/iscsi_target_stat.h | 64 |
1 files changed, 64 insertions, 0 deletions
diff --git a/drivers/target/iscsi/iscsi_target_stat.h b/drivers/target/iscsi/iscsi_target_stat.h new file mode 100644 index 000000000000..3ff76b4faad3 --- /dev/null +++ b/drivers/target/iscsi/iscsi_target_stat.h | |||
@@ -0,0 +1,64 @@ | |||
1 | #ifndef ISCSI_TARGET_STAT_H | ||
2 | #define ISCSI_TARGET_STAT_H | ||
3 | |||
4 | /* | ||
5 | * For struct iscsi_tiqn->tiqn_wwn default groups | ||
6 | */ | ||
7 | extern struct config_item_type iscsi_stat_instance_cit; | ||
8 | extern struct config_item_type iscsi_stat_sess_err_cit; | ||
9 | extern struct config_item_type iscsi_stat_tgt_attr_cit; | ||
10 | extern struct config_item_type iscsi_stat_login_cit; | ||
11 | extern struct config_item_type iscsi_stat_logout_cit; | ||
12 | |||
13 | /* | ||
14 | * For struct iscsi_session->se_sess default groups | ||
15 | */ | ||
16 | extern struct config_item_type iscsi_stat_sess_cit; | ||
17 | |||
18 | /* iSCSI session error types */ | ||
19 | #define ISCSI_SESS_ERR_UNKNOWN 0 | ||
20 | #define ISCSI_SESS_ERR_DIGEST 1 | ||
21 | #define ISCSI_SESS_ERR_CXN_TIMEOUT 2 | ||
22 | #define ISCSI_SESS_ERR_PDU_FORMAT 3 | ||
23 | |||
24 | /* iSCSI session error stats */ | ||
25 | struct iscsi_sess_err_stats { | ||
26 | spinlock_t lock; | ||
27 | u32 digest_errors; | ||
28 | u32 cxn_timeout_errors; | ||
29 | u32 pdu_format_errors; | ||
30 | u32 last_sess_failure_type; | ||
31 | char last_sess_fail_rem_name[224]; | ||
32 | } ____cacheline_aligned; | ||
33 | |||
34 | /* iSCSI login failure types (sub oids) */ | ||
35 | #define ISCSI_LOGIN_FAIL_OTHER 2 | ||
36 | #define ISCSI_LOGIN_FAIL_REDIRECT 3 | ||
37 | #define ISCSI_LOGIN_FAIL_AUTHORIZE 4 | ||
38 | #define ISCSI_LOGIN_FAIL_AUTHENTICATE 5 | ||
39 | #define ISCSI_LOGIN_FAIL_NEGOTIATE 6 | ||
40 | |||
41 | /* iSCSI login stats */ | ||
42 | struct iscsi_login_stats { | ||
43 | spinlock_t lock; | ||
44 | u32 accepts; | ||
45 | u32 other_fails; | ||
46 | u32 redirects; | ||
47 | u32 authorize_fails; | ||
48 | u32 authenticate_fails; | ||
49 | u32 negotiate_fails; /* used for notifications */ | ||
50 | u64 last_fail_time; /* time stamp (jiffies) */ | ||
51 | u32 last_fail_type; | ||
52 | int last_intr_fail_ip_family; | ||
53 | unsigned char last_intr_fail_ip_addr[IPV6_ADDRESS_SPACE]; | ||
54 | char last_intr_fail_name[224]; | ||
55 | } ____cacheline_aligned; | ||
56 | |||
57 | /* iSCSI logout stats */ | ||
58 | struct iscsi_logout_stats { | ||
59 | spinlock_t lock; | ||
60 | u32 normal_logouts; | ||
61 | u32 abnormal_logouts; | ||
62 | } ____cacheline_aligned; | ||
63 | |||
64 | #endif /*** ISCSI_TARGET_STAT_H ***/ | ||