On Tue, 11 Dec 2018 at 10:23, Pankaj Bansal <[email protected]> wrote: > > > > > -----Original Message----- > > From: Ard Biesheuvel [mailto:[email protected]] > > Sent: Tuesday, December 11, 2018 2:48 PM > > To: Pankaj Bansal <[email protected]> > > Cc: Mark Rutland <[email protected]>; Leif Lindholm > > <[email protected]>; Grant Likely <[email protected]>; Varun Sethi > > <[email protected]>; Udit Kumar <[email protected]>; Bhupesh Sharma > > <[email protected]>; linux-efi <[email protected]> > > Subject: Re: [PATCH v2 2/2] drivers: firmware: efi: install new fdt in > > configuration table > > > > On Tue, 11 Dec 2018 at 10:04, Pankaj Bansal <[email protected]> wrote: > > > > > > Bootloader may need to fixup the device tree before OS can use it. > > > > > > Therefore, install fdt used by OS in configuration tables and > > > associate it with device tree guid. > > > > > > UEFI/DXE drivers can fixup this device tree in their respective > > > ExitBootServices events. > > > > > > Cc: Ard Biesheuvel <[email protected]> > > > Cc: [email protected] > > > Signed-off-by: Pankaj Bansal <[email protected]> > > > > I still think this is a bad idea. The firmware is closely tied to the > > platform, so it > > should provide the DT instead of the kernel. > > It is. It's just that firmware is responsible to fix the status of devices > before kernel > can use those. In efi stub, the fdt is copied into new_fdt before exit boot > services. > We need to fix the status of devices as part of exit boot services. We cannot > do it > before, because firmware is using these device and they are not ready for > kernel to use yet. >
That doesn't matter. The kernel will not use devices from the DT before ExitBootServices() anyway.
