scripts/rpc: remove default values from bdev_nvme_add_error_injection

Removing default options from parser command to prevent overwrite by
argparse the defaults defined in the .c files.

Signed-off-by: Jaroslaw Chachulski <jaroslawx.chachulski@intel.com>
Change-Id: I757b893a65a1c0e21310171fa8b89a87e28b87a4
Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/12871
Community-CI: Broadcom CI <spdk-ci.pdl@broadcom.com>
Community-CI: Mellanox Build Bot
Tested-by: SPDK CI Jenkins <sys_sgci@intel.com>
Reviewed-by: Konrad Sztyber <konrad.sztyber@intel.com>
Reviewed-by: Ben Walker <benjamin.walker@intel.com>
This commit is contained in:
Jaroslaw Chachulski 2022-06-02 09:48:43 -04:00 committed by Tomasz Zawadzki
parent 7386b6ed09
commit 5960c74d04

View File

@ -2864,10 +2864,10 @@ Format: 'user:u1 secret:s1 muser:mu1 msecret:ms1,user:u2 secret:s2 muser:mu2 mse
p.add_argument('-t', '--cmd-type', help="""Type of NVMe command. Valid values are: admin, io""", required=True)
p.add_argument('-o', '--opc', help="""Opcode of the NVMe command.""", required=True, type=int)
p.add_argument('-s', '--do-not-submit',
help="""Set to true if request should not be submitted to the controller (default false)""",
default=False, dest="do_not_submit", action='store_true')
help="""Set to true if request should not be submitted to the controller""",
dest="do_not_submit", action='store_true')
p.add_argument('-w', '--timeout-in-us', help="""Wait specified microseconds when do_not_submit is true""", type=int)
p.add_argument('-e', '--err-count', help="""Number of matching NVMe commands to inject errors (default 1)""", type=int, default=1)
p.add_argument('-e', '--err-count', help="""Number of matching NVMe commands to inject errors""", type=int)
p.add_argument('-u', '--sct', help="""Status code type""", type=int)
p.add_argument('-c', '--sc', help="""Status code""", type=int)
p.set_defaults(func=bdev_nvme_add_error_injection)