mirror of
https://source.denx.de/u-boot/u-boot.git
synced 2025-12-23 18:32:07 +01:00
env: fat: Add support for NVME
Add support for retrieving the FAT environment from an NVME device, the same way it can be retrieved from MMC, SCSI, or VIRTIO. To use the FAT environment from an NVME device, pass CONFIG_ENV_FAT_INTERFACE="nvme" in the defconfig. Signed-off-by: Fabio Estevam <festevam@gmail.com>
This commit is contained in:
parent
0572f7cad1
commit
afbed1ba2f
10
env/fat.c
vendored
10
env/fat.c
vendored
@ -14,8 +14,10 @@
|
||||
#include <memalign.h>
|
||||
#include <search.h>
|
||||
#include <errno.h>
|
||||
#include <init.h>
|
||||
#include <fat.h>
|
||||
#include <mmc.h>
|
||||
#include <nvme.h>
|
||||
#include <scsi.h>
|
||||
#include <virtio.h>
|
||||
#include <asm/cache.h>
|
||||
@ -136,6 +138,14 @@ static int env_fat_load(void)
|
||||
if (!strcmp(ifname, "virtio"))
|
||||
virtio_init();
|
||||
#endif
|
||||
#if defined(CONFIG_NVME)
|
||||
if (!strcmp(ifname, "nvme")) {
|
||||
if (IS_ENABLED(CONFIG_PCI))
|
||||
pci_init();
|
||||
|
||||
nvme_scan_namespace();
|
||||
}
|
||||
#endif
|
||||
#endif
|
||||
part = blk_get_device_part_str(ifname, dev_and_part,
|
||||
&dev_desc, &info, 1);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user