]> www.infradead.org Git - users/sagi/nvme-cli.git/commitdiff
Fix typos in tests and utils
authorHarry Mallon <hjmallon@gmail.com>
Thu, 29 Nov 2018 13:44:52 +0000 (13:44 +0000)
committerHarry Mallon <hjmallon@gmail.com>
Thu, 29 Nov 2018 13:45:21 +0000 (13:45 +0000)
completions/README
nvme-print.c
nvme.c
plugins/huawei/huawei-nvme.c
plugins/netapp/netapp-nvme.c
tests/nvme_compare_test.py
tests/nvme_read_write_test.py
tests/nvme_test.py

index 9fe51b55ab4cffb168c3702c2e109ce769b4839c..ba1032ae1bc11be52031bda2885c0fbba744cc66 100644 (file)
@@ -23,7 +23,7 @@ just re-source nvme and .bashrc. To see a full list of auto-completable
 NVMe commands, type "nvme help " and hit TAB.
 
 You may also need to uncomment the "enable bash completion in interactive
-shells" part of /etc/bash.bashrc, which hopefully looks somehting like:
+shells" part of /etc/bash.bashrc, which hopefully looks something like:
 
 if [ -f /usr/share/bash-completion/bash_completion ]; then
        . /usr/share/bash-completion/bash_completion
index 61014d9f6a527c509d0a90c7db509471dc5debb4..025d8da527e3685f81c7549b1a753e2efa8ec734 100644 (file)
@@ -657,7 +657,7 @@ static void show_nvme_id_ns_dlfeat(__u8 dlfeat)
                printf("  [7:5] : %#x\tReserved\n", rsvd);
        printf("  [4:4] : %#x\tGuard Field of Deallocated Logical Blocks is set to %s\n",
                guard, guard ? "CRC of The Value Read" : "0xFFFF");
-       printf("  [3:3] : %#x\tDeallocate Bit in the Write Zeroes Commmand is %sSupported\n",
+       printf("  [3:3] : %#x\tDeallocate Bit in the Write Zeroes Command is %sSupported\n",
                dwz, dwz ? "" : "Not ");
        printf("  [2:0] : %#x\tBytes Read From a Deallocated Logical Block and its Metadata are %s\n", val,
                val == 2 ? "0xFF" :
@@ -3002,7 +3002,7 @@ static void show_registers_bpinfo_brs(__u8 brs)
                printf("No Boot Partition read operation requested\n");
                break;
        case 1:
-               printf("Boot Partition read in progres\n");
+               printf("Boot Partition read in progress\n");
                break;
        case 2:
                printf("Boot Partition read completed successfully\n");
diff --git a/nvme.c b/nvme.c
index 0e53472e8b7dec9cfc07c84803eebabba9ce32fa..be1e85c8b48c3011cb57133a5f1594192fed19bc 100644 (file)
--- a/nvme.c
+++ b/nvme.c
@@ -367,7 +367,7 @@ static int get_telemetry_log(int argc, char **argv, struct command *cmd, struct
        if (err) {
                fprintf(stderr, "NVMe Status:%s(%x)\n",
                        nvme_status_to_string(err), err);
-               fprintf(stderr, "Failed to aquire telemetry header %d!\n", err);
+               fprintf(stderr, "Failed to acquire telemetry header %d!\n", err);
                close(output);
                goto free_mem;
        }
@@ -401,7 +401,7 @@ static int get_telemetry_log(int argc, char **argv, struct command *cmd, struct
        while (offset != full_size) {
                err = nvme_get_telemetry_log(fd, page_log, 0, cfg.ctrl_init, bs, offset);
                if (err) {
-                       fprintf(stderr, "Failed to aquire full telemetry log!\n");
+                       fprintf(stderr, "Failed to acquire full telemetry log!\n");
                        fprintf(stderr, "NVMe Status:%s(%x)\n",
                                nvme_status_to_string(err), err);
                        break;
@@ -1903,7 +1903,7 @@ static int id_ctrl(int argc, char **argv, struct command *cmd, struct plugin *pl
 static int ns_descs(int argc, char **argv, struct command *cmd, struct plugin *plugin)
 {
        const char *desc = "Send Namespace Identification Descriptors command to the "\
-                           "given device, returns the namespace identifcation descriptors "\
+                           "given device, returns the namespace identification descriptors "\
                            "of the specific namespace in either human-readable or binary format.";
        const char *raw_binary = "show infos in binary format";
        const char *namespace_id = "identifier of desired namespace";
index f91d3e3bb43f2133f6f6d863cf60f15a17ff129d..b68e05c55aee37c4902e1f6af8aff88ba0c16e6c 100644 (file)
@@ -62,7 +62,7 @@ struct huawei_list_element_len {
        unsigned int ns_name;
        unsigned int nguid;
        unsigned int ns_id;
-       unsigned int useage;
+       unsigned int usage;
        unsigned int array_name;
 };
 
@@ -223,13 +223,13 @@ static void huawei_print_list_head(struct huawei_list_element_len element_len)
                element_len.ns_name, element_len.ns_name, "NS Name",
                element_len.nguid, element_len.nguid, "Nguid",
                element_len.ns_id, element_len.ns_id, "NS ID",
-               element_len.useage, element_len.useage, "Usage",
+               element_len.usage, element_len.usage, "Usage",
                element_len.array_name, element_len.array_name, "Array Name");
 
        printf("%-.*s %-.*s %-.*s %-.*s %-.*s %-.*s\n",
                element_len.node, dash, element_len.ns_name, dash,
                element_len.nguid, dash, element_len.ns_id, dash,
-               element_len.useage, dash, element_len.array_name, dash);
+               element_len.usage, dash, element_len.array_name, dash);
 }
 
 static void huawei_print_list_item(struct huawei_list_item list_item,
@@ -259,7 +259,7 @@ static void huawei_print_list_item(struct huawei_list_item list_item,
                element_len.ns_name, element_len.ns_name, list_item.ns_name,
                element_len.nguid, element_len.nguid, nguid_buf,
                element_len.ns_id, list_item.nsid,
-               element_len.useage, element_len.useage, usage,
+               element_len.usage, element_len.usage, usage,
                element_len.array_name, element_len.array_name, list_item.array_name);
 
 }
@@ -306,7 +306,7 @@ static void huawei_print_list_items(struct huawei_list_item *list_items, unsigne
        element_len.node = 16;
        element_len.nguid = 2 * sizeof(list_items->ns.nguid) + 1;
        element_len.ns_id = 9;
-       element_len.useage = 26;
+       element_len.usage = 26;
        element_len.ns_name = huawei_get_ns_len(list_items, len, MIN_NS_NAME_LEN);
        element_len.array_name = huawei_get_array_len(list_items, len, MIN_ARRAY_NAME_LEN);
 
index 542d35dcc19126665cfa496afff0f37bb7734665..416e74e611541c0beb0dbd7aa0a9513966eced19 100644 (file)
@@ -168,7 +168,7 @@ static int netapp_smdevices_get_info(int fd, struct smdevice_info *item,
 
        err = nvme_identify_ctrl(fd, &item->ctrl);
        if (err) {
-               fprintf(stderr, "Identify Controler failed to %s (%s)\n", dev,
+               fprintf(stderr, "Identify Controller failed to %s (%s)\n", dev,
                        strerror(err));
                return 0;
        }
index 34c140dd70e0f43859bcd7fc5c747bd9358a0bfb..c919c070aba02a0ef33d372a0699e91260f57b26 100644 (file)
@@ -40,7 +40,7 @@ class TestNVMeCompareCmd(TestNVMeIO):
         - Attributes:
               - data_size : data size to perform IO.
               - start_block : starting block of to perform IO.
-              - compare_file : data file to use in nvme comapre commmand.
+              - compare_file : data file to use in nvme compare command.
               - test_log_dir : directory for logs, temp files.
     """
 
index a5f457923c3347ec85d5f814d308a0aeb71ef85d..4a04f8ad7e7347fad915707cae7fa48cf82c450d 100644 (file)
@@ -38,7 +38,7 @@ class TestNVMeReadWriteTest(TestNVMeIO):
 
         - Attributes:
               - start_block : starting block of to perform IO.
-              - compare_file : data file to use in nvme comapre commmand.
+              - compare_file : data file to use in nvme compare command.
               - test_log_dir : directory for logs, temp files.
     """
     def __init__(self):
index d4409ecfe8829c1d9a86612b139c29540ad1fe62..c67b60d88ce98ee6ffd135e47873f3eb21c77140 100644 (file)
@@ -310,7 +310,7 @@ class TestNVMe(object):
     def attach_ns(self, ctrl_id, ns_id):
         """ Wrapper for attaching the namespace.
             - Args:
-                - ctrl_id : controller id to which namespace to be attched.
+                - ctrl_id : controller id to which namespace to be attached.
                 - nsid : new namespace id.
             - Returns:
                 - 0 on success, error code on failure.
@@ -334,7 +334,7 @@ class TestNVMe(object):
     def detach_ns(self, ctrl_id, nsid):
         """ Wrapper for detaching the namespace.
             - Args:
-                - ctrl_id : controller id to which namespace to be attched.
+                - ctrl_id : controller id to which namespace to be attached.
                 - nsid : new namespace id.
             - Returns:
                 - 0 on success, error code on failure.