linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [RESEND][PATCH]efi: initialize efi.runtime_version to make query_variable_info/update_capsule workable
@ 2012-08-06 18:37 Seiji Aguchi
  2012-08-16  7:53 ` Matt Fleming
  0 siblings, 1 reply; 4+ messages in thread
From: Seiji Aguchi @ 2012-08-06 18:37 UTC (permalink / raw)
  To: linux-kernel, linux-efi, x86,
	Thomas Gleixner (tglx@linutronix.de),
	'mingo@elte.hu' (mingo@elte.hu),
	H. Peter Anvin (hpa@linux.intel.com),
	matt.fleming, olof, Paul Gortmaker (paul.gortmaker@windriver.com)
  Cc: dle-develop, Satoru Moriya, Matthew Garrett

A value of efi.runtime_version is checked before calling
update_capsule()/query_variable_info() as follows.
But it isn't initialized anywhere.
<snip>
static efi_status_t virt_efi_query_variable_info(u32 attr,
                                                 u64 *storage_space,
                                                  u64 *remaining_space,
                                                 u64 *max_variable_size) {
        if (efi.runtime_version < EFI_2_00_SYSTEM_TABLE_REVISION)
                return EFI_UNSUPPORTED; 
<snip>

This patch initializes a value of efi.runtime_version at boot time.

Acked-by: Matthew Garrett <mjg@redhat.com>
Signed-off-by: Seiji Aguchi <seiji.aguchi@hds.com>
---
 arch/x86/platform/efi/efi.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

diff --git a/arch/x86/platform/efi/efi.c b/arch/x86/platform/efi/efi.c
index 2dc29f5..4c82998 100644
--- a/arch/x86/platform/efi/efi.c
+++ b/arch/x86/platform/efi/efi.c
@@ -868,6 +868,7 @@ void __init efi_enter_virtual_mode(void)
 	 *
 	 * Call EFI services through wrapper functions.
 	 */
+	efi.runtime_version = efi_systab.fw_revision;
 	efi.get_time = virt_efi_get_time;
 	efi.set_time = virt_efi_set_time;
 	efi.get_wakeup_time = virt_efi_get_wakeup_time;
-- 
1.7.1

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [RESEND][PATCH]efi: initialize efi.runtime_version to make query_variable_info/update_capsule workable
  2012-08-06 18:37 [RESEND][PATCH]efi: initialize efi.runtime_version to make query_variable_info/update_capsule workable Seiji Aguchi
@ 2012-08-16  7:53 ` Matt Fleming
  2012-08-16 21:43   ` H. Peter Anvin
  0 siblings, 1 reply; 4+ messages in thread
From: Matt Fleming @ 2012-08-16  7:53 UTC (permalink / raw)
  To: Seiji Aguchi
  Cc: linux-kernel, linux-efi, x86,
	Thomas Gleixner (tglx@linutronix.de),
	'mingo@elte.hu' (mingo@elte.hu),
	H. Peter Anvin (hpa@linux.intel.com),
	olof, Paul Gortmaker (paul.gortmaker@windriver.com),
	dle-develop, Satoru Moriya, Matthew Garrett

On Mon, 2012-08-06 at 18:37 +0000, Seiji Aguchi wrote:
> A value of efi.runtime_version is checked before calling
> update_capsule()/query_variable_info() as follows.
> But it isn't initialized anywhere.
> <snip>
> static efi_status_t virt_efi_query_variable_info(u32 attr,
>                                                  u64 *storage_space,
>                                                   u64 *remaining_space,
>                                                  u64 *max_variable_size) {
>         if (efi.runtime_version < EFI_2_00_SYSTEM_TABLE_REVISION)
>                 return EFI_UNSUPPORTED; 
> <snip>
> 
> This patch initializes a value of efi.runtime_version at boot time.
> 
> Acked-by: Matthew Garrett <mjg@redhat.com>
> Signed-off-by: Seiji Aguchi <seiji.aguchi@hds.com>
> ---
>  arch/x86/platform/efi/efi.c |    1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)

Thanks, I picked this up just so it doesn't get lost. It will probably
go to Linus via Peter Anvin.


^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [RESEND][PATCH]efi: initialize efi.runtime_version to make query_variable_info/update_capsule workable
  2012-08-16  7:53 ` Matt Fleming
@ 2012-08-16 21:43   ` H. Peter Anvin
  2012-08-17 10:31     ` Matt Fleming
  0 siblings, 1 reply; 4+ messages in thread
From: H. Peter Anvin @ 2012-08-16 21:43 UTC (permalink / raw)
  To: Matt Fleming
  Cc: Seiji Aguchi, linux-kernel, linux-efi, x86,
	Thomas Gleixner (tglx@linutronix.de),
	'mingo@elte.hu' (mingo@elte.hu),
	olof, Paul Gortmaker (paul.gortmaker@windriver.com),
	dle-develop, Satoru Moriya, Matthew Garrett

On 08/16/2012 12:53 AM, Matt Fleming wrote:
> On Mon, 2012-08-06 at 18:37 +0000, Seiji Aguchi wrote:
>> A value of efi.runtime_version is checked before calling
>> update_capsule()/query_variable_info() as follows.
>> But it isn't initialized anywhere.
>> <snip>
>> static efi_status_t virt_efi_query_variable_info(u32 attr,
>>                                                  u64 *storage_space,
>>                                                   u64 *remaining_space,
>>                                                  u64 *max_variable_size) {
>>         if (efi.runtime_version < EFI_2_00_SYSTEM_TABLE_REVISION)
>>                 return EFI_UNSUPPORTED; 
>> <snip>
>>
>> This patch initializes a value of efi.runtime_version at boot time.
>>
>> Acked-by: Matthew Garrett <mjg@redhat.com>
>> Signed-off-by: Seiji Aguchi <seiji.aguchi@hds.com>
>> ---
>>  arch/x86/platform/efi/efi.c |    1 +
>>  1 files changed, 1 insertions(+), 0 deletions(-)
> 
> Thanks, I picked this up just so it doesn't get lost. It will probably
> go to Linus via Peter Anvin.
> 

Should I take that as an Acked-by: on your part?

	-hpa



^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [RESEND][PATCH]efi: initialize efi.runtime_version to make query_variable_info/update_capsule workable
  2012-08-16 21:43   ` H. Peter Anvin
@ 2012-08-17 10:31     ` Matt Fleming
  0 siblings, 0 replies; 4+ messages in thread
From: Matt Fleming @ 2012-08-17 10:31 UTC (permalink / raw)
  To: H. Peter Anvin
  Cc: Seiji Aguchi, linux-kernel, linux-efi, x86,
	Thomas Gleixner (tglx@linutronix.de),
	'mingo@elte.hu' (mingo@elte.hu),
	olof, Paul Gortmaker (paul.gortmaker@windriver.com),
	dle-develop, Satoru Moriya, Matthew Garrett

On Thu, 2012-08-16 at 14:43 -0700, H. Peter Anvin wrote:
> On 08/16/2012 12:53 AM, Matt Fleming wrote:
> > On Mon, 2012-08-06 at 18:37 +0000, Seiji Aguchi wrote:
> >> A value of efi.runtime_version is checked before calling
> >> update_capsule()/query_variable_info() as follows.
> >> But it isn't initialized anywhere.
> >> <snip>
> >> static efi_status_t virt_efi_query_variable_info(u32 attr,
> >>                                                  u64 *storage_space,
> >>                                                   u64 *remaining_space,
> >>                                                  u64 *max_variable_size) {
> >>         if (efi.runtime_version < EFI_2_00_SYSTEM_TABLE_REVISION)
> >>                 return EFI_UNSUPPORTED; 
> >> <snip>
> >>
> >> This patch initializes a value of efi.runtime_version at boot time.
> >>
> >> Acked-by: Matthew Garrett <mjg@redhat.com>
> >> Signed-off-by: Seiji Aguchi <seiji.aguchi@hds.com>
> >> ---
> >>  arch/x86/platform/efi/efi.c |    1 +
> >>  1 files changed, 1 insertions(+), 0 deletions(-)
> > 
> > Thanks, I picked this up just so it doesn't get lost. It will probably
> > go to Linus via Peter Anvin.
> > 
> 
> Should I take that as an Acked-by: on your part?

Yep.




^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-08-17 10:31 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-08-06 18:37 [RESEND][PATCH]efi: initialize efi.runtime_version to make query_variable_info/update_capsule workable Seiji Aguchi
2012-08-16  7:53 ` Matt Fleming
2012-08-16 21:43   ` H. Peter Anvin
2012-08-17 10:31     ` Matt Fleming

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).