doc: add jsonrpc docs for compress bdev RPCs
Signed-off-by: paul luse <paul.e.luse@intel.com> Change-Id: I38585f1cd609bb53f90ec8c169b14fb09808b6e1 Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/4155 Reviewed-by: Shuhei Matsumoto <shuhei.matsumoto.xt@hitachi.com> Reviewed-by: Ben Walker <benjamin.walker@intel.com> Community-CI: Broadcom CI Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
This commit is contained in:
parent
2b29a2b16c
commit
7ad510b930
139
doc/jsonrpc.md
139
doc/jsonrpc.md
@ -1131,6 +1131,145 @@ Example response:
|
|||||||
}
|
}
|
||||||
~~~
|
~~~
|
||||||
|
|
||||||
|
## bdev_compress_create {#rpc_bdev_compress_create}
|
||||||
|
|
||||||
|
Create a new compress bdev on a given base bdev.
|
||||||
|
|
||||||
|
### Parameters
|
||||||
|
|
||||||
|
Name | Optional | Type | Description
|
||||||
|
----------------------- | -------- | ----------- | -----------
|
||||||
|
base_bdev_name | Required | string | Name of the base bdev
|
||||||
|
pm_path | Required | string | Path to persistent memory
|
||||||
|
lb_size | Optional | int | Compressed vol logical block size (512 or 4096)
|
||||||
|
|
||||||
|
### Result
|
||||||
|
|
||||||
|
Name of newly created bdev.
|
||||||
|
|
||||||
|
### Example
|
||||||
|
|
||||||
|
Example request:
|
||||||
|
|
||||||
|
~~~
|
||||||
|
{
|
||||||
|
"params": {
|
||||||
|
"base_bdev_name": "Nvme0n1",
|
||||||
|
"pm_path": "/pm_files",
|
||||||
|
"lb_size": 4096
|
||||||
|
},
|
||||||
|
"jsonrpc": "2.0",
|
||||||
|
"method": "bdev_compress_create",
|
||||||
|
"id": 1
|
||||||
|
}
|
||||||
|
~~~
|
||||||
|
|
||||||
|
## bdev_compress_delete {#rpc_bdev_compress_delete}
|
||||||
|
|
||||||
|
Delete a compressed bdev.
|
||||||
|
|
||||||
|
### Parameters
|
||||||
|
|
||||||
|
Name | Optional | Type | Description
|
||||||
|
----------------------- | -------- | ----------- | -----------
|
||||||
|
name | Required | string | Name of the compress bdev
|
||||||
|
|
||||||
|
### Example
|
||||||
|
|
||||||
|
Example request:
|
||||||
|
|
||||||
|
~~~
|
||||||
|
{
|
||||||
|
"params": {
|
||||||
|
"name": "COMP_Nvme0n1"
|
||||||
|
},
|
||||||
|
"jsonrpc": "2.0",
|
||||||
|
"method": "bdev_compress_delete",
|
||||||
|
"id": 1
|
||||||
|
}
|
||||||
|
~~~
|
||||||
|
|
||||||
|
Example response:
|
||||||
|
|
||||||
|
~~~
|
||||||
|
{
|
||||||
|
"jsonrpc": "2.0",
|
||||||
|
"id": 1,
|
||||||
|
"result": true
|
||||||
|
}
|
||||||
|
~~~
|
||||||
|
|
||||||
|
## bdev_compress_get_orphans {#rpc_bdev_compress_get_orphans}
|
||||||
|
|
||||||
|
Get a list of compressed volumes that are missing their pmem metadata.
|
||||||
|
|
||||||
|
### Parameters
|
||||||
|
|
||||||
|
Name | Optional | Type | Description
|
||||||
|
----------------------- | -------- | ----------- | -----------
|
||||||
|
name | Required | string | Name of the compress bdev
|
||||||
|
|
||||||
|
### Example
|
||||||
|
|
||||||
|
Example request:
|
||||||
|
|
||||||
|
~~~
|
||||||
|
{
|
||||||
|
"params": {
|
||||||
|
"name": "COMP_Nvme0n1"
|
||||||
|
},
|
||||||
|
"jsonrpc": "2.0",
|
||||||
|
"method": "bdev_compress_get_orphans",
|
||||||
|
"id": 1
|
||||||
|
}
|
||||||
|
~~~
|
||||||
|
|
||||||
|
Example response:
|
||||||
|
|
||||||
|
~~~
|
||||||
|
{
|
||||||
|
"jsonrpc": "2.0",
|
||||||
|
"id": 1,
|
||||||
|
"name": "COMP_Nvme0n1"
|
||||||
|
}
|
||||||
|
~~~
|
||||||
|
|
||||||
|
## bdev_compress_set_pmd {#rpc_bdev_compress_set_pmd}
|
||||||
|
|
||||||
|
Select the DPDK polled mode driver (pmd) for a compressed bdev,
|
||||||
|
0 = auto-select, 1= QAT only, 2 = ISAL only.
|
||||||
|
|
||||||
|
### Parameters
|
||||||
|
|
||||||
|
Name | Optional | Type | Description
|
||||||
|
----------------------- | -------- | ----------- | -----------
|
||||||
|
pmd | Required | int | pmd selection
|
||||||
|
|
||||||
|
### Example
|
||||||
|
|
||||||
|
Example request:
|
||||||
|
|
||||||
|
~~~
|
||||||
|
{
|
||||||
|
"params": {
|
||||||
|
"pmd": 1
|
||||||
|
},
|
||||||
|
"jsonrpc": "2.0",
|
||||||
|
"method": "bdev_compress_set_pmd",
|
||||||
|
"id": 1
|
||||||
|
}
|
||||||
|
~~~
|
||||||
|
|
||||||
|
Example response:
|
||||||
|
|
||||||
|
~~~
|
||||||
|
{
|
||||||
|
"jsonrpc": "2.0",
|
||||||
|
"id": 1,
|
||||||
|
"result": true
|
||||||
|
}
|
||||||
|
~~~
|
||||||
|
|
||||||
## bdev_ocf_create {#rpc_bdev_ocf_create}
|
## bdev_ocf_create {#rpc_bdev_ocf_create}
|
||||||
|
|
||||||
Construct new OCF bdev.
|
Construct new OCF bdev.
|
||||||
|
Loading…
Reference in New Issue
Block a user