Message ID | 20180418134030.55127-7-agraf@suse.de |
---|---|
State | Superseded |
Headers | show |
Series | riscv: Enable efi_loader support | expand |
On 04/18/2018 03:40 PM, Alexander Graf wrote: > While we don't have VCI or UEFI naming conventions for RISC-V file paths yet, > we need to search for something. So let's make up a few defines that at least > allow us to get started until the specs officially include RISC-V. > > Signed-off-by: Alexander Graf <agraf@suse.de> > --- > include/config_distro_bootcmd.h | 14 +++++++++++++- > 1 file changed, 13 insertions(+), 1 deletion(-) > > diff --git a/include/config_distro_bootcmd.h b/include/config_distro_bootcmd.h > index f567cebd38..7b95872958 100644 > --- a/include/config_distro_bootcmd.h > +++ b/include/config_distro_bootcmd.h > @@ -100,6 +100,10 @@ > #define BOOTEFI_NAME "bootia32.efi" > #elif defined(CONFIG_X86_RUN_64BIT) > #define BOOTEFI_NAME "bootx64.efi" > +#elif defined(CONFIG_CPU_RISCV_32) > +#define BOOTEFI_NAME "bootrv32.efi" > +#elif defined(CONFIG_CPU_RISCV_64) > +#define BOOTEFI_NAME "bootrv64.efi" Hello Alex, I suggest to use the same values as the RISC-V branch of EDK2. https://github.com/tianocore/edk2-staging/blob/RISC-V/MdePkg/Include/Uefi/UefiSpec.h#L2171 BOOTRISCV32.EFI BOOTRISCV64.EFI These values are not standardized yet. But we have not better hint of what to expect in the next version of the spec. Best regards Heinrich > #endif > #endif > > @@ -250,7 +254,15 @@ > #elif defined(CONFIG_X86) > /* Always assume we're running 64bit */ > #define BOOTENV_EFI_PXE_ARCH "0x7" > -#define BOOTENV_EFI_PXE_VCI "PXEClient:Arch:00007:UNDI:003000" > +#define BOOTENV_EFI_PXE_VCI "PXEClient:Arch:0000:UNDI:003000" > +#elif defined(CONFIG_CPU_RISCV_32) > +/* TODO: Register VCI identifier via RFC */ > +#define BOOTENV_EFI_PXE_ARCH "0x5032" > +#define BOOTENV_EFI_PXE_VCI "PXEClient:Arch:5032:UNDI:003000" > +#elif defined(CONFIG_CPU_RISCV_64) > +/* TODO: Register VCI identifier via RFC */ > +#define BOOTENV_EFI_PXE_ARCH "0x5064" > +#define BOOTENV_EFI_PXE_VCI "PXEClient:Arch:5064:UNDI:003000" > #else > #error Please specify an EFI client identifier > #endif >
diff --git a/include/config_distro_bootcmd.h b/include/config_distro_bootcmd.h index f567cebd38..7b95872958 100644 --- a/include/config_distro_bootcmd.h +++ b/include/config_distro_bootcmd.h @@ -100,6 +100,10 @@ #define BOOTEFI_NAME "bootia32.efi" #elif defined(CONFIG_X86_RUN_64BIT) #define BOOTEFI_NAME "bootx64.efi" +#elif defined(CONFIG_CPU_RISCV_32) +#define BOOTEFI_NAME "bootrv32.efi" +#elif defined(CONFIG_CPU_RISCV_64) +#define BOOTEFI_NAME "bootrv64.efi" #endif #endif @@ -250,7 +254,15 @@ #elif defined(CONFIG_X86) /* Always assume we're running 64bit */ #define BOOTENV_EFI_PXE_ARCH "0x7" -#define BOOTENV_EFI_PXE_VCI "PXEClient:Arch:00007:UNDI:003000" +#define BOOTENV_EFI_PXE_VCI "PXEClient:Arch:0000:UNDI:003000" +#elif defined(CONFIG_CPU_RISCV_32) +/* TODO: Register VCI identifier via RFC */ +#define BOOTENV_EFI_PXE_ARCH "0x5032" +#define BOOTENV_EFI_PXE_VCI "PXEClient:Arch:5032:UNDI:003000" +#elif defined(CONFIG_CPU_RISCV_64) +/* TODO: Register VCI identifier via RFC */ +#define BOOTENV_EFI_PXE_ARCH "0x5064" +#define BOOTENV_EFI_PXE_VCI "PXEClient:Arch:5064:UNDI:003000" #else #error Please specify an EFI client identifier #endif
While we don't have VCI or UEFI naming conventions for RISC-V file paths yet, we need to search for something. So let's make up a few defines that at least allow us to get started until the specs officially include RISC-V. Signed-off-by: Alexander Graf <agraf@suse.de> --- include/config_distro_bootcmd.h | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-)