]> www.infradead.org Git - nvme.git/commitdiff
nvme: reorganize nvme_ns_head fields nvme-6.11-2024-08-08
authorKanchan Joshi <joshi.k@samsung.com>
Tue, 30 Jul 2024 10:31:38 +0000 (16:01 +0530)
committerKeith Busch <kbusch@kernel.org>
Wed, 31 Jul 2024 14:40:10 +0000 (07:40 -0700)
shuffle few fields to reduce the holes within nvme_ns_head.
On x86_64, the size is reduced to 1104 bytes from 1120 bytes.

Signed-off-by: Kanchan Joshi <joshi.k@samsung.com>
Reviewed-by: Sagi Grimberg <sagi@grimberg.me>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Keith Busch <kbusch@kernel.org>
drivers/nvme/host/nvme.h

index 6039dc78b36e3dd7db3a0a0558c0208b619c22da..ae5314d32943e8c9ba43c0d287de411fbd201679 100644 (file)
@@ -462,19 +462,19 @@ struct nvme_ns_head {
        struct srcu_struct      srcu;
        struct nvme_subsystem   *subsys;
        struct nvme_ns_ids      ids;
+       u8                      lba_shift;
+       u16                     ms;
+       u16                     pi_size;
+       u8                      pi_type;
+       u8                      guard_type;
        struct list_head        entry;
        struct kref             ref;
        bool                    shared;
        bool                    passthru_err_log_enabled;
-       int                     instance;
        struct nvme_effects_log *effects;
        u64                     nuse;
        unsigned                ns_id;
-       u8                      lba_shift;
-       u16                     ms;
-       u16                     pi_size;
-       u8                      pi_type;
-       u8                      guard_type;
+       int                     instance;
 #ifdef CONFIG_BLK_DEV_ZONED
        u64                     zsze;
 #endif