On 2 June 2015 at 10:00, Haojian Zhuang haojian.zhuang@linaro.org wrote:
On Tue, 2015-06-02 at 09:53 +0200, Ard Biesheuvel wrote:
On 2 June 2015 at 08:20, Haojian Zhuang haojian.zhuang@linaro.org wrote:
Hi Fathi,
As we discussed yesterday, you mentioned that both "FDT support" and "Initrd support" should not be included in default boot args.
But the problem is at here. https://github.com/96boards/bugs/issues/40
Fathi & Leif, Since PcdDefaultBootType is set to 0 by default, the kernel image is recognized as an EFI application. So we can't set any FDT path and Initrd path when it creates the default boot entry in UEFI. And we also can't set them even when we create a new boot entry from the boot image. We have to specify them in boot args.
So I want to know what's the expected behavior in UEFI. Do we need to enhance the Bds to find FDT path & Initrd path even the kernel is recognized as an EFI application?
Unfortunately, there is no 'expected behavior' in the UEFI specification when it comes to initrd and FDT images. These are mostly implementation details of the ARM BDS, which itself does not comply with the UEFI spec in features like discovery of boot images on removable media (\EFI\BOOT\BOOTAA64.EFI) and will therefore be deprecated in favor of the Intel BDS at some point.
For the kernel to be able to interoperate with UEFI, PcdDefaultBootType needs to be 0, so it is really a matter of making the other things work in that case.
For the FDT, you can use the recently added support for FDT paths, both embedded and in the file system. Look at FdtPlatformDxe for details, and my recent changes to the ArmVExpress-FVP-AARCH64 target that embeds FDTs into the UEFI image.
I refered to Juno's implementation, and added InstallFdt driver. It'll load Fdt variable to compose Fdt path. Is it same as the FdtPlatformDxe that you're talking about?
For the initrd, you could either add the initrd= command line option, or boot via GRUB. Making changes to the ARM BDS to accommodate this is not recommended since it is going away anyway.
We don't have GRUB on hikey yet.
Fathi, Is it necessary to use GRUB on hikey?
No, it is not necessary, since you can also pass initrd= I just offered it as an alternative.