iscsi: Move PG and IG configuration right before target nodes configuration
Object creation of portal, portal group, and initiator group can be done by JSON-RPC. This patch moves object creation of portal, portal group, and initiator group right before object creation of target node. The purpose of the patch series is - to separate iSCSI subsystem initialization and iSCSI subsystem configuration, and - to develop a new JSON-RPC by reusing the separated iSCSI subsystem initialization. Change-Id: If78beabb478923e7c920c09b16e42d6f8aa55775 Signed-off-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Reviewed-on: https://review.gerrithub.io/403141 Tested-by: SPDK Automated Test System <sys_sgsw@intel.com> Reviewed-by: Daniel Verkamp <daniel.verkamp@intel.com> Reviewed-by: Jim Harris <james.r.harris@intel.com>
This commit is contained in:
parent
6ef949f276
commit
ef02d13d3e
@ -807,20 +807,6 @@ spdk_iscsi_app_read_parameters(void)
|
||||
|
||||
spdk_iscsi_log_globals();
|
||||
|
||||
/* portal groups */
|
||||
rc = spdk_iscsi_portal_grp_array_create();
|
||||
if (rc < 0) {
|
||||
SPDK_ERRLOG("spdk_iscsi_portal_grp_array_create() failed\n");
|
||||
return -1;
|
||||
}
|
||||
|
||||
/* initiator groups */
|
||||
rc = spdk_iscsi_init_grp_array_create();
|
||||
if (rc < 0) {
|
||||
SPDK_ERRLOG("spdk_iscsi_init_grp_array_create() failed\n");
|
||||
return -1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -946,6 +932,20 @@ spdk_iscsi_init(spdk_iscsi_init_cb cb_fn, void *cb_arg)
|
||||
return;
|
||||
}
|
||||
|
||||
rc = spdk_iscsi_portal_grp_array_create();
|
||||
if (rc < 0) {
|
||||
SPDK_ERRLOG("spdk_iscsi_portal_grp_array_create() failed\n");
|
||||
spdk_iscsi_init_complete(-1);
|
||||
return;
|
||||
}
|
||||
|
||||
rc = spdk_iscsi_init_grp_array_create();
|
||||
if (rc < 0) {
|
||||
SPDK_ERRLOG("spdk_iscsi_init_grp_array_create() failed\n");
|
||||
spdk_iscsi_init_complete(-1);
|
||||
return;
|
||||
}
|
||||
|
||||
rc = spdk_iscsi_init_tgt_nodes();
|
||||
if (rc < 0) {
|
||||
SPDK_ERRLOG("spdk_iscsi_init_tgt_nodes() failed\n");
|
||||
|
Loading…
Reference in New Issue
Block a user