Commit ca731a6a authored by Pawel Kaminski's avatar Pawel Kaminski Committed by Tomasz Zawadzki
Browse files

rpc: Rename construct_vhost_nvme_controller to vhost_create_nvme_controller



Signed-off-by: default avatarPawel Kaminski <pawelx.kaminski@intel.com>
Change-Id: I3237352097cd78679ef95c519f970693a15c0c50
Reviewed-on: https://review.gerrithub.io/c/spdk/spdk/+/470395


Reviewed-by: default avatarTomasz Zawadzki <tomasz.zawadzki@intel.com>
Reviewed-by: default avatarJim Harris <james.r.harris@intel.com>
Tested-by: default avatarSPDK CI Jenkins <sys_sgci@intel.com>
parent 119e911a
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -4502,7 +4502,7 @@ Example response:
}
~~~

## construct_vhost_nvme_controller {#rpc_construct_vhost_nvme_controller}
## vhost_create_nvme_controller {#rpc_vhost_create_nvme_controller}

Construct empty vhost NVMe controller.

@@ -4527,7 +4527,7 @@ Example request:
    "ctrlr": "VhostNvme0"
  },
  "jsonrpc": "2.0",
  "method": "construct_vhost_nvme_controller",
  "method": "vhost_create_nvme_controller",
  "id": 1
}
~~~
+1 −1
Original line number Diff line number Diff line
@@ -180,7 +180,7 @@ controller. Users must specify the maximum I/O queues supported for the
controller, at least 1 Namespace is required for each controller.

~~~{.sh}
$rpc_py construct_vhost_nvme_controller --cpumask 0x1 vhost.2 16
$rpc_py vhost_create_nvme_controller --cpumask 0x1 vhost.2 16
$rpc_py add_vhost_nvme_ns vhost.2 Malloc0
~~~

+1 −1
Original line number Diff line number Diff line
@@ -1252,7 +1252,7 @@ spdk_vhost_nvme_write_config_json(struct spdk_vhost_dev *vdev, struct spdk_json_
	}

	spdk_json_write_object_begin(w);
	spdk_json_write_named_string(w, "method", "construct_vhost_nvme_controller");
	spdk_json_write_named_string(w, "method", "vhost_create_nvme_controller");

	spdk_json_write_named_object_begin(w, "params");
	spdk_json_write_named_string(w, "ctrlr", nvme->vdev.name);
+4 −3
Original line number Diff line number Diff line
@@ -542,7 +542,7 @@ free_rpc_vhost_nvme_ctrlr(struct rpc_vhost_nvme_ctrlr *req)
}

static void
spdk_rpc_construct_vhost_nvme_controller(struct spdk_jsonrpc_request *request,
spdk_rpc_vhost_create_nvme_controller(struct spdk_jsonrpc_request *request,
				      const struct spdk_json_val *params)
{
	struct rpc_vhost_nvme_ctrlr req = {};
@@ -574,8 +574,9 @@ invalid:
					 spdk_strerror(-rc));

}
SPDK_RPC_REGISTER("construct_vhost_nvme_controller", spdk_rpc_construct_vhost_nvme_controller,
SPDK_RPC_REGISTER("vhost_create_nvme_controller", spdk_rpc_vhost_create_nvme_controller,
		  SPDK_RPC_RUNTIME)
SPDK_RPC_REGISTER_ALIAS_DEPRECATED(vhost_create_nvme_controller, construct_vhost_nvme_controller)

struct rpc_add_vhost_nvme_ctrlr_ns {
	char *ctrlr;
+3 −3
Original line number Diff line number Diff line
@@ -20,7 +20,7 @@ bdev_dict["bdev_virtio_attach_controller"] = []
vhost_dict = OrderedDict()
vhost_dict["vhost_create_scsi_controller"] = []
vhost_dict["construct_vhost_blk_controller"] = []
vhost_dict["construct_vhost_nvme_controller"] = []
vhost_dict["vhost_create_nvme_controller"] = []

iscsi_dict = OrderedDict()
iscsi_dict["iscsi_set_options"] = []
@@ -452,7 +452,7 @@ def get_vhost_nvme_json(config, section):
    vhost_nvme_json = []
    vhost_nvme_json.append({
        "params": to_json_params(params[:3]),
        "method": "construct_vhost_nvme_controller"
        "method": "vhost_create_nvme_controller"
    })
    for namespace in params[3][3]:
        vhost_nvme_json.append({
@@ -705,7 +705,7 @@ if __name__ == "__main__":
                if match_section == "VhostScsi":
                    section_to_subsystem[match_section]["vhost_create_scsi_controller"].append(item)
                elif match_section == "VhostNvme":
                    section_to_subsystem[match_section]["construct_vhost_nvme_controller"].append(item)
                    section_to_subsystem[match_section]["vhost_create_nvme_controller"].append(item)
                elif match_section == "Subsystem":
                    section_to_subsystem[match_section]["subsystems"].append(item)
                else:
Loading