linux-efi.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Linn Crosetto <linn@hp.com>
To: matt.fleming@intel.com, hpa@zytor.com, tglx@linutronix.de,
	mingo@redhat.com, x86@kernel.org, yinghai@kernel.org,
	penberg@kernel.org, jacob.shin@amd.com,
	linux-efi@vger.kernel.org
Cc: linux-kernel@vger.kernel.org, Linn Crosetto <linn@hp.com>
Subject: [RFC PATCH 2/4] efi: Add memory_setup function efi_memory_setup()
Date: Mon, 19 Aug 2013 14:00:17 -0600	[thread overview]
Message-ID: <1376942419-5684-3-git-send-email-linn@hp.com> (raw)
In-Reply-To: <1376942419-5684-1-git-send-email-linn@hp.com>

Adding efi_memory_setup() to be used to override the default
memory_setup function when the EFI memory map should be used instead of
a BIOS provided e820 map.

Signed-off-by: Linn Crosetto <linn@hp.com>
---
 arch/x86/platform/efi/efi.c | 8 ++++++++
 include/linux/efi.h         | 1 +
 2 files changed, 9 insertions(+)

diff --git a/arch/x86/platform/efi/efi.c b/arch/x86/platform/efi/efi.c
index 32da922..c2a660c 100644
--- a/arch/x86/platform/efi/efi.c
+++ b/arch/x86/platform/efi/efi.c
@@ -711,6 +711,14 @@ static int __init efi_runtime_init(void)
 	return 0;
 }
 
+char * __init efi_memory_setup(void)
+{
+	char *who = "EFI";
+	efi_memmap_init();
+	do_add_efi_memmap();
+	return who;
+}
+
 void __init efi_init(void)
 {
 	efi_char16_t *c16;
diff --git a/include/linux/efi.h b/include/linux/efi.h
index 5f8f176..977bbc7 100644
--- a/include/linux/efi.h
+++ b/include/linux/efi.h
@@ -567,6 +567,7 @@ efi_guid_unparse(efi_guid_t *guid, char *out)
         return out;
 }
 
+extern char *efi_memory_setup(void);
 extern void efi_init (void);
 extern void *efi_get_pal_addr (void);
 extern void efi_map_pal_code (void);
-- 
1.7.11.3

  parent reply	other threads:[~2013-08-19 20:00 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-19 20:00 [RFC PATCH 0/4] EFI boot stub memory map fix Linn Crosetto
     [not found] ` <1376942419-5684-1-git-send-email-linn-VXdhtT5mjnY@public.gmane.org>
2013-08-19 20:00   ` [RFC PATCH 1/4] efi: Decouple efi_memmap_init() and do_add_efi_memmap() Linn Crosetto
2013-08-19 20:06   ` [RFC PATCH 0/4] EFI boot stub memory map fix H. Peter Anvin
     [not found]     ` <e7fc4e2f-4cda-4eef-8d37-bb87773f58e8-2ueSQiBKiTY7tOexoI0I+QC/G2K4zDHf@public.gmane.org>
2013-08-19 20:47       ` Yinghai Lu
2013-08-19 21:09         ` Linn Crosetto
     [not found]           ` <20130819210939.GJ14273-QpTgeCMhooRo/CpIj0byZw@public.gmane.org>
2013-08-19 21:39             ` Yinghai Lu
2013-08-19 20:00 ` Linn Crosetto [this message]
2013-08-19 20:00 ` [RFC PATCH 3/4] efi: Add efi_memmap_needed() Linn Crosetto
2013-08-19 20:00 ` [RFC PATCH 4/4] x86: Fix EFI boot stub for large memory maps Linn Crosetto

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1376942419-5684-3-git-send-email-linn@hp.com \
    --to=linn@hp.com \
    --cc=hpa@zytor.com \
    --cc=jacob.shin@amd.com \
    --cc=linux-efi@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=matt.fleming@intel.com \
    --cc=mingo@redhat.com \
    --cc=penberg@kernel.org \
    --cc=tglx@linutronix.de \
    --cc=x86@kernel.org \
    --cc=yinghai@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).