[Xen-devel] [PATCH 1/3] arm64: add grub_xen_boot env to indicate that we have xen_* commands
From: Fu Wei Signed-off-by: Fu Wei --- grub-core/loader/arm64/xen_boot.c | 8 1 file changed, 8 insertions(+) diff --git a/grub-core/loader/arm64/xen_boot.c b/grub-core/loader/arm64/xen_boot.c index 8ae43d7..ef03111 100644 --- a/grub-core/loader/arm64/xen_boot.c +++ b/grub-core/loader/arm64/xen_boot.c @@ -20,6 +20,7 @@ #include #include #include +#include #include #include #include @@ -490,10 +491,17 @@ GRUB_MOD_INIT (xen_boot) grub_register_command ("xen_module", grub_cmd_xen_module, 0, N_("Load a xen module.")); my_mod = mod; + +/* setup a env to indicate that + * we have xen_* commands. + */ + grub_env_set ("grub_xen_boot", "y"); + grub_env_export ("grub_xen_boot"); } GRUB_MOD_FINI (xen_boot) { grub_unregister_command (cmd_xen_hypervisor); grub_unregister_command (cmd_xen_module); + grub_env_unset ("grub_xen_boot"); } -- 2.5.0 ___ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel
Re: [Xen-devel] [PATCH 1/3] arm64: add grub_xen_boot env to indicate that we have xen_* commands
24.02.2016 21:01, fu@linaro.org пишет: > From: Fu Wei > > Signed-off-by: Fu Wei > --- > grub-core/loader/arm64/xen_boot.c | 8 > 1 file changed, 8 insertions(+) > > diff --git a/grub-core/loader/arm64/xen_boot.c > b/grub-core/loader/arm64/xen_boot.c > index 8ae43d7..ef03111 100644 > --- a/grub-core/loader/arm64/xen_boot.c > +++ b/grub-core/loader/arm64/xen_boot.c > @@ -20,6 +20,7 @@ > #include > #include > #include > +#include > #include > #include > #include > @@ -490,10 +491,17 @@ GRUB_MOD_INIT (xen_boot) > grub_register_command ("xen_module", grub_cmd_xen_module, 0, > N_("Load a xen module.")); >my_mod = mod; > + > +/* setup a env to indicate that > + * we have xen_* commands. > + */ > + grub_env_set ("grub_xen_boot", "y"); > + grub_env_export ("grub_xen_boot"); > } Please define feature for it, see grub-core/normal/main.c. > > GRUB_MOD_FINI (xen_boot) > { >grub_unregister_command (cmd_xen_hypervisor); >grub_unregister_command (cmd_xen_module); > + grub_env_unset ("grub_xen_boot"); > } > ___ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel
Re: [Xen-devel] [PATCH 1/3] arm64: add grub_xen_boot env to indicate that we have xen_* commands
Hi Andrei. On 25 February 2016 at 02:12, Andrei Borzenkov wrote: > 24.02.2016 21:01, fu@linaro.org пишет: >> From: Fu Wei >> >> Signed-off-by: Fu Wei >> --- >> grub-core/loader/arm64/xen_boot.c | 8 >> 1 file changed, 8 insertions(+) >> >> diff --git a/grub-core/loader/arm64/xen_boot.c >> b/grub-core/loader/arm64/xen_boot.c >> index 8ae43d7..ef03111 100644 >> --- a/grub-core/loader/arm64/xen_boot.c >> +++ b/grub-core/loader/arm64/xen_boot.c >> @@ -20,6 +20,7 @@ >> #include >> #include >> #include >> +#include >> #include >> #include >> #include >> @@ -490,10 +491,17 @@ GRUB_MOD_INIT (xen_boot) >> grub_register_command ("xen_module", grub_cmd_xen_module, 0, >> N_("Load a xen module.")); >>my_mod = mod; >> + >> +/* setup a env to indicate that >> + * we have xen_* commands. >> + */ >> + grub_env_set ("grub_xen_boot", "y"); >> + grub_env_export ("grub_xen_boot"); >> } > > Please define feature for it, see grub-core/normal/main.c. Thanks for your suggestion > >> >> GRUB_MOD_FINI (xen_boot) >> { >>grub_unregister_command (cmd_xen_hypervisor); >>grub_unregister_command (cmd_xen_module); >> + grub_env_unset ("grub_xen_boot"); >> } >> > -- Best regards, Fu Wei Software Engineer Red Hat Software (Beijing) Co.,Ltd.Shanghai Branch Ph: +86 21 61221326(direct) Ph: +86 186 2020 4684 (mobile) Room 1512, Regus One Corporate Avenue,Level 15, One Corporate Avenue,222 Hubin Road,Huangpu District, Shanghai,China 200021 ___ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel