|
@@ -75,6 +75,14 @@ FEATURE ( FEATURE_PROTOCOL, "iSCSI", DHCP_EB_FEATURE_ISCSI, 1 );
|
75
|
75
|
__einfo_error ( EINFO_EINVAL_NO_TARGET_IQN )
|
76
|
76
|
#define EINFO_EINVAL_NO_TARGET_IQN \
|
77
|
77
|
__einfo_uniqify ( EINFO_EINVAL, 0x04, "No target IQN" )
|
|
78
|
+#define EIO_TARGET_UNAVAILABLE \
|
|
79
|
+ __einfo_error ( EINFO_EIO_TARGET_UNAVAILABLE )
|
|
80
|
+#define EINFO_EIO_TARGET_UNAVAILABLE \
|
|
81
|
+ __einfo_uniqify ( EINFO_EIO, 0x01, "Target not currently operational" )
|
|
82
|
+#define EIO_TARGET_NO_RESOURCES \
|
|
83
|
+ __einfo_error ( EINFO_EIO_TARGET_NO_RESOURCES )
|
|
84
|
+#define EINFO_EIO_TARGET_NO_RESOURCES \
|
|
85
|
+ __einfo_uniqify ( EINFO_EIO, 0x02, "Target out of resources" )
|
78
|
86
|
#define ENOTSUP_INITIATOR_STATUS \
|
79
|
87
|
__einfo_error ( EINFO_ENOTSUP_INITIATOR_STATUS )
|
80
|
88
|
#define EINFO_ENOTSUP_INITIATOR_STATUS \
|
|
@@ -87,6 +95,10 @@ FEATURE ( FEATURE_PROTOCOL, "iSCSI", DHCP_EB_FEATURE_ISCSI, 1 );
|
87
|
95
|
__einfo_error ( EINFO_ENOTSUP_DISCOVERY )
|
88
|
96
|
#define EINFO_ENOTSUP_DISCOVERY \
|
89
|
97
|
__einfo_uniqify ( EINFO_ENOTSUP, 0x03, "Discovery not supported" )
|
|
98
|
+#define ENOTSUP_TARGET_STATUS \
|
|
99
|
+ __einfo_error ( EINFO_ENOTSUP_TARGET_STATUS )
|
|
100
|
+#define EINFO_ENOTSUP_TARGET_STATUS \
|
|
101
|
+ __einfo_uniqify ( EINFO_ENOTSUP, 0x04, "Unsupported target status" )
|
90
|
102
|
#define EPERM_INITIATOR_AUTHENTICATION \
|
91
|
103
|
__einfo_error ( EINFO_EPERM_INITIATOR_AUTHENTICATION )
|
92
|
104
|
#define EINFO_EPERM_INITIATOR_AUTHENTICATION \
|
|
@@ -1157,7 +1169,14 @@ static int iscsi_status_to_rc ( unsigned int status_class,
|
1157
|
1169
|
return -ENOTSUP_INITIATOR_STATUS;
|
1158
|
1170
|
}
|
1159
|
1171
|
case ISCSI_STATUS_TARGET_ERROR :
|
1160
|
|
- return -EIO;
|
|
1172
|
+ switch ( status_detail ) {
|
|
1173
|
+ case ISCSI_STATUS_TARGET_ERROR_UNAVAILABLE:
|
|
1174
|
+ return -EIO_TARGET_UNAVAILABLE;
|
|
1175
|
+ case ISCSI_STATUS_TARGET_ERROR_NO_RESOURCES:
|
|
1176
|
+ return -EIO_TARGET_NO_RESOURCES;
|
|
1177
|
+ default:
|
|
1178
|
+ return -ENOTSUP_TARGET_STATUS;
|
|
1179
|
+ }
|
1161
|
1180
|
default :
|
1162
|
1181
|
return -EINVAL;
|
1163
|
1182
|
}
|