| #
51341de7 |
| 06-Jan-2025 |
Shawn Lin <shawn.lin@rock-chips.com> |
nvme: add quirks support
Change-Id: Ieeb3d993967973c160c477b3d833f6e27de31d26 Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
|
| #
9d9df2d6 |
| 06-Jan-2025 |
Shawn Lin <shawn.lin@rock-chips.com> |
nvme: Add write_zeroes support
Change-Id: I0c7256af24e5e5fa0ec351738ae2509c88114947 Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
|
| #
32a1e554 |
| 26-Jan-2024 |
Shawn Lin <shawn.lin@rock-chips.com> |
nvme: add erase support
Use discard to erase the desired LBA
[1] => md.l 0x44000000 0x200 #先读一下0x44000000的内存地址 44000000: 00000000 00000000 20014080 00000200 .........@. .... 44000010: 440044
nvme: add erase support
Use discard to erase the desired LBA
[1] => md.l 0x44000000 0x200 #先读一下0x44000000的内存地址 44000000: 00000000 00000000 20014080 00000200 .........@. .... 44000010: 44004400 02010108 00002000 24000200 .D.D..... .....$ 44000020: 08801000 10000000 00000000 80008018 ................
[2] => nvme read 0x44000000 0x0 1 #NVMe LBA 0读一个block到0x44000000
nvme read: device 0 block # 0, count 1 ... 1 blocks read: OK
[3] => md.l 0x44000000 0x200 #再读一下0x44000000的内存地址,变了 44000000: 4a400000 00000001 17c00000 00000002 ..@J............ 44000010: 4aa00000 00000001 16700000 00000002 ...J......p.....
[4] => nvme erase 0x0 0x1 #0地址开始,擦除一个block
nvme erase: device 0 block # 0, count 1 ... 1 blocks erased: OK
[5] => nvme read 0x44000000 0x0 1 #再从NVMe的LBA 0地址读一个block数据到0x44000000
nvme read: device 0 block # 0, count 1 ... 1 blocks read: OK
[6] => md.l 0x44000000 0x200 #NVMe第一个block的数据已经清除了 44000000: 00000000 00000000 00000000 00000000 ................ 44000010: 00000000 00000000 00000000 00000000 ................ 44000020: 00000000 00000000 00000000 00000000 ................ ...
Change-Id: I0495b3538acbfb1e522b027a635b74a078ccab15 Signed-off-by: Shawn Lin <shawn.lin@rock-chips.com>
show more ...
|
| #
11bd08e3 |
| 22-Jun-2021 |
Bin Meng <bmeng.cn@gmail.com> |
UPSTREAM: 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.
Change-Id: I2e2b2ffdf630d51654db3698e0c7c3a2
UPSTREAM: 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.
Change-Id: I2e2b2ffdf630d51654db3698e0c7c3a21edfd2f2 Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Signed-off-by: Jon Lin <jon.lin@rock-chips.com> (cherry picked from commit 757cc4b1b2725e445a94840aa6076f0f0d4f03b9)
show more ...
|
| #
ff15e123 |
| 03-Oct-2019 |
Patrick Wildt <patrick@blueri.se> |
UPSTREAM: nvme: add accessor to namespace id and eui64
This adds a function which can be used by e.g. EFI to retrieve the namespace identifier and EUI64. For that it adds the EUI64 to its driver in
UPSTREAM: nvme: add accessor to namespace id and eui64
This adds a function which can be used by e.g. EFI to retrieve the namespace identifier and EUI64. For that it adds the EUI64 to its driver internal namespace structure and copies the EUI64 during namespace identification.
Change-Id: I9ba01dbd7de1928e2e72aeaa37be534524d9035c Signed-off-by: Patrick Wildt <patrick@blueri.se> Tested-by: Heinrich Schuchardt <xypron.glpk@gmx.de> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Signed-off-by: Jon Lin <jon.lin@rock-chips.com> (cherry picked from commit c50b2883dfc1ce355dc37238741ef97cd2c5d000)
show more ...
|
| #
18aa5a41 |
| 22-Aug-2017 |
Bin Meng <bmeng.cn@gmail.com> |
nvme: Get rid of the global variable nvme_info
At present the NVMe uclass driver uses a global variable nvme_info to store global information like namespace id, and NVMe controller driver's priv str
nvme: Get rid of the global variable nvme_info
At present the NVMe uclass driver uses a global variable nvme_info to store global information like namespace id, and NVMe controller driver's priv struct has a blk_dev_start that is used to calculate the namespace id based on the global information from nvme_info.
This is not a good design in the DM world and can be replaced with the following changes:
- Encode the namespace id in the NVMe block device name during the NVMe uclass post probe - Extract the namespace id from the device name during the NVMe block device probe - Let BLK uclass calculate the devnum for us by passing -1 to blk_create_devicef() as the devnum
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
show more ...
|
| #
b65c6921 |
| 22-Aug-2017 |
Bin Meng <bmeng.cn@gmail.com> |
nvme: Cache controller's capabilities
Capabilities register is RO and accessed at various places in the driver. Let's cache it in the controller driver's priv struct.
Signed-off-by: Bin Meng <bmeng
nvme: Cache controller's capabilities
Capabilities register is RO and accessed at various places in the driver. Let's cache it in the controller driver's priv struct.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
show more ...
|
| #
e5dc2d26 |
| 22-Aug-2017 |
Bin Meng <bmeng.cn@gmail.com> |
nvme: Fix getting PCI vendor id of the NVMe block device
The codes currently try to read PCI vendor id of the NVMe block device by dm_pci_read_config16() with its parameter set as its root complex c
nvme: Fix getting PCI vendor id of the NVMe block device
The codes currently try to read PCI vendor id of the NVMe block device by dm_pci_read_config16() with its parameter set as its root complex controller (ndev->pdev) instead of itself. This is seriously wrong. We can read the vendor id by passing the correct udevice parameter to the dm_pci_read_config16() API, however there is a shortcut by reading the cached vendor id from the PCI device's struct pci_child_platdata.
While we are here fixing this bug, apparently the quirk stuff handle codes in nvme_get_info_from_identify() never takes effect since its logic has never been true at all. Remove these codes completely.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
show more ...
|
| #
abe25db6 |
| 22-Aug-2017 |
Bin Meng <bmeng.cn@gmail.com> |
nvme: Remove useless defines
These are leftover when the driver was ported from Linux and are not used by the U-Boot driver.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
|
| #
982388ea |
| 03-Aug-2017 |
Zhikang Zhang <zhikang.zhang@nxp.com> |
nvme: Add NVM Express driver support
NVM Express (NVMe) is a register level interface that allows host software to communicate with a non-volatile memory subsystem. This interface is optimized for e
nvme: Add NVM Express driver support
NVM Express (NVMe) is a register level interface that allows host software to communicate with a non-volatile memory subsystem. This interface is optimized for enterprise and client solid state drives, typically attached to the PCI express interface.
This adds a U-Boot driver support of devices that follow the NVMe standard [1] and supports basic read/write operations.
Tested with a 400GB Intel SSD 750 series NVMe card with controller id 8086:0953.
[1] http://www.nvmexpress.org/resources/specifications/
Signed-off-by: Zhikang Zhang <zhikang.zhang@nxp.com> Signed-off-by: Wenbin Song <wenbin.song@nxp.com> Signed-off-by: Bin Meng <bmeng.cn@gmail.com> Reviewed-by: Tom Rini <trini@konsulko.com>
show more ...
|