nvme: Drop useless members of 'struct nvme_ns'

mode_select_num_blocks and mode_select_block_len in 'struct nvme_ns'
are not useful. Drop them.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
This commit is contained in:
Bin Meng 2021-06-22 21:16:20 +08:00
parent 8c60d40d69
commit 757cc4b1b2
2 changed files with 1 additions and 5 deletions

View File

@ -718,11 +718,9 @@ static int nvme_blk_probe(struct udevice *udev)
flbas = id->flbas & NVME_NS_FLBAS_LBA_MASK;
ns->flbas = flbas;
ns->lba_shift = id->lbaf[flbas].ds;
ns->mode_select_num_blocks = le64_to_cpu(id->nsze);
ns->mode_select_block_len = 1 << ns->lba_shift;
list_add(&ns->list, &ndev->namespaces);
desc->lba = ns->mode_select_num_blocks;
desc->lba = le64_to_cpu(id->nsze);
desc->log2blksz = ns->lba_shift;
desc->blksz = 1 << ns->lba_shift;
desc->bdev = udev;

View File

@ -633,8 +633,6 @@ struct nvme_ns {
int devnum;
int lba_shift;
u8 flbas;
u64 mode_select_num_blocks;
u32 mode_select_block_len;
};
#endif /* __DRIVER_NVME_H__ */