Re: [PATCH] x86/efi: autoload efivars

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 9 July 2014 08:40, joeyli <jlee@xxxxxxxx> wrote:
> On Tue, Jul 08, 2014 at 01:19:42PM +0100, Ben Hutchings wrote:
>> On Tue, 2014-07-08 at 11:14 +0100, Matt Fleming wrote:
>> > On Tue, 08 Jul, at 11:00:58AM, Lee, Chun-Yi wrote:
>> [...]
>> > > --- a/arch/x86/platform/efi/efi.c
>> > > +++ b/arch/x86/platform/efi/efi.c
>> > > @@ -44,6 +44,7 @@
>> > >  #include <linux/io.h>
>> > >  #include <linux/reboot.h>
>> > >  #include <linux/bcd.h>
>> > > +#include <linux/platform_device.h>
>> > >
>> > >  #include <asm/setup.h>
>> > >  #include <asm/efi.h>
>> > > @@ -780,6 +781,20 @@ void __init efi_late_init(void)
>> > >   efi_bgrt_init();
>> > >  }
>> > >
>> > > +#ifdef CONFIG_EFI_VARS_MODULE
>> > > +static int __init efi_load_efivars(void)
>> > > +{
>> > > + struct platform_device *pdev;
>> > > +
>> > > + if (!efi_enabled(EFI_RUNTIME_SERVICES))
>> > > +         return 0;
>> > > +
>> > > + pdev = platform_device_register_simple("efivars", 0, NULL, 0);
>> > > + return IS_ERR(pdev) ? PTR_ERR(pdev) : 0;
>> > > +}
>> > > +device_initcall(efi_load_efivars);
>> > > +#endif
>> > > +
>> >
>> > Could this be moved to drivers/firmware/efi/efi.c? That way the arm64
>> > folks could benefit from it too.
>>
>> It seems like that should work now that efi_enabled() is not specific to
>> x86.
>>
>> Ben.
>>
>
> Thanks for Matt and Ban's review, I will move platform device register code to
> drivers/firmware/efi/efi.c and send version 2 patch.
>

Hi all,

I tested the version that is in Matt's -next now and it works fine on arm64.

-- 
Ard.
--
To unsubscribe from this list: send the line "unsubscribe linux-efi" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]

  Powered by Linux