login
Login
/
Register
Search
Search this site:
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-kernel
»
2010
»
April
»
1
Re: [PATCH -v2] ibft, x86: Change reserve_ibft_region() to find_ibft_region()
view
thread
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
[view in full thread]
From: Randy Dunlap
Subject:
Re: [PATCH -v2] ibft, x86: Change reserve_ibft_region() to find_ibft_region()
Date: Thursday, April 1, 2010 - 2:54 pm
On Thu, 01 Apr 2010 14:32:43 -0700 Yinghai Lu wrote:
quoted text
> > > So arch code could decide the way to reserve the ibft. > > And We should reserve ibft as early as possible, instead of BOOTMEM stage, > in case the table is in RAM range and is not reserved by BIOS. > > move that just sfter find_smp_config() > > Also when CONFIG_NO_BOOTMEM=y, We will not have reserve_bootmem() anymorea > > -v2: fix typo about ibft pointed by Konrad Rzeszutek Wilk <konrad@darnok.org>
quoted text
> Signed-off-by: Yinghai Lu <yinghai@kernel.org> > Cc: Pekka Enberg <penberg@cs.helsinki.fi> > Cc: Peter Jones <pjones@redhat.com> > Cc: Konrad Rzeszutek Wilk <konrad@kernel.org> > CC: Jan Beulich <jbeulich@novell.com> > > --- > arch/x86/kernel/setup.c | 14 ++++++++++++-- > drivers/firmware/iscsi_ibft_find.c | 11 ++++++++--- > include/linux/iscsi_ibft.h | 8 ++++++-- > 3 files changed, 26 insertions(+), 7 deletions(-) > > Index: linux-2.6/arch/x86/kernel/setup.c > =================================================================== > --- linux-2.6.orig/arch/x86/kernel/setup.c > +++ linux-2.6/arch/x86/kernel/setup.c > @@ -608,6 +608,16 @@ static int __init setup_elfcorehdr(char > early_param("elfcorehdr", setup_elfcorehdr); > #endif > > +static __init void reserve_ibft_region(void) > +{ > + unsigned long addr, size = 0; > + > + addr = find_ibft_region(&size); > + > + if (size) > + reserve_early_overlap_ok(addr, addr + size, "ibft");
where is the correction?
quoted text
> +} > + > #ifdef CONFIG_X86_RESERVE_LOW_64K > static int __init dmi_low_memory_corruption(const struct dmi_system_id *d) > { > @@ -910,6 +920,8 @@ void __init setup_arch(char **cmdline_p) > */ > find_smp_config(); > > + reserve_ibft_region(); > + > reserve_trampoline_memory(); > > #ifdef CONFIG_ACPI_SLEEP > @@ -977,8 +989,6 @@ void __init setup_arch(char **cmdline_p) > > dma32_reserve_bootmem(); > > - reserve_ibft_region(); > - > #ifdef CONFIG_KVM_CLOCK > kvmclock_init(); > #endif > Index: linux-2.6/drivers/firmware/iscsi_ibft_find.c > =================================================================== > --- linux-2.6.orig/drivers/firmware/iscsi_ibft_find.c > +++ linux-2.6/drivers/firmware/iscsi_ibft_find.c > @@ -52,7 +52,7 @@ EXPORT_SYMBOL_GPL(ibft_addr); > * Routine used to find the iSCSI Boot Format Table. The logical > * kernel address is set in the ibft_addr global variable. > */ > -void __init reserve_ibft_region(void) > +unsigned long __init find_ibft_region(unsigned long *sizep) > { > unsigned long pos; > unsigned int len = 0; > @@ -78,6 +78,11 @@ void __init reserve_ibft_region(void) > } > } > } > - if (ibft_addr) > - reserve_bootmem(pos, PAGE_ALIGN(len), BOOTMEM_DEFAULT); > + if (ibft_addr) { > + *sizep = PAGE_ALIGN(len); > + return pos; > + } > + > + *sizep = 0; > + return 0; > } > Index: linux-2.6/include/linux/iscsi_ibft.h > =================================================================== > --- linux-2.6.orig/include/linux/iscsi_ibft.h > +++ linux-2.6/include/linux/iscsi_ibft.h > @@ -42,9 +42,13 @@ extern struct ibft_table_header *ibft_ad > * mapped address is set in the ibft_addr variable. > */ > #ifdef CONFIG_ISCSI_IBFT_FIND > -extern void __init reserve_ibft_region(void); > +unsigned long find_ibft_region(unsigned long *sizep); > #else > -static inline void reserve_ibft_region(void) { } > +static inline unsigned long find_ibft_region(unsigned long *sizep) > +{ > + *sizep = 0; > + return 0; > +} > #endif > > #endif /* ISCSI_IBFT_H */ > --
--- ~Randy --
unsubscribe notice
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to
majordomo@vger.kernel.org
More majordomo info at
http://vger.kernel.org/majordomo-info.html
Please read the FAQ at
http://www.tux.org/lkml/
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
Messages in current thread:
[PATCH] ibft, x86: Change reserve_ibft_region() to find_ib ...
, Yinghai Lu
, (Wed Mar 31, 7:07 pm)
Re: [PATCH] ibft, x86: Change reserve_ibft_region() to fin ...
, Konrad Rzeszutek Wilk
, (Thu Apr 1, 1:12 pm)
Re: [PATCH] ibft, x86: Change reserve_ibft_region() to fin ...
, Yinghai Lu
, (Thu Apr 1, 1:59 pm)
[PATCH -v2] ibft, x86: Change reserve_ibft_region() to fin ...
, Yinghai Lu
, (Thu Apr 1, 2:32 pm)
Re: [PATCH -v2] ibft, x86: Change reserve_ibft_region() to ...
, Randy Dunlap
, (Thu Apr 1, 2:54 pm)
Re: [PATCH -v2] ibft, x86: Change reserve_ibft_region() to ...
, Yinghai Lu
, (Thu Apr 1, 3:00 pm)
Re: [PATCH -v2] ibft, x86: Change reserve_ibft_region() to ...
, Randy Dunlap
, (Thu Apr 1, 3:03 pm)
[tip:x86/urgent] ibft, x86: Change reserve_ibft_region() t ...
, tip-bot for Yinghai Lu
, (Thu Apr 1, 4:51 pm)
Navigation
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
Ken Chen
[patch] sched: fix inconsistency when redistribute per-cpu tg->cfs_rq shares.
Ingo Molnar
Re: [PATCH v3] x86: merge the simple bitops and move them to bitops.h
Jan Engelhardt
Re: [PATCH] Allow Kconfig to set default mmap_min_addr protection
Dmitry Torokhov
Re: [2.6 patch] input/serio/hp_sdc.c section fix
Rafael J. Wysocki
[Bug #16380] Loop devices act strangely in 2.6.35
git
:
Steven Grimm
Using git as a general backup mechanism (was Re: Using GIT to store /etc)
Jeff King
Re: [PATCH] git-reset: allow --soft in a bare repo
Johannes Sixt
Re: [PATCH 01/14] msvc: Fix compilation errors in compat/win32/sys/poll.c
Johannes Schindelin
Re: [PATCH] Uninstall rule for top level Makefile
Shawn O. Pearce
Re: [PATCH v2] Speed up bash completion loading
git-commits-head
:
Linux Kernel Mailing List
cgroups: clean up cgroup_pidlist_find() a bit
Linux Kernel Mailing List
sony-laptop: Add support for extended hotkeys
Linux Kernel Mailing List
IB/core: Add support for masked atomic operations
Linux Kernel Mailing List
V4L/DVB (8939): cx18: fix sparse warnings
Linux Kernel Mailing List
ipv6 mcast: Check address family of gf_group in getsockopt(MS_FILTER).
linux-netdev
:
Inaky Perez-Gonzalez
[PATCH 40/40] wimax/i2400m: add CREDITS and MAINTAINERS entries
Karsten Keil
[mISDN PATCH v2 05/19] Reduce stack size in dsp_cmx_send()
linux
Re: 2.6.23-rc8 network problem. Mem leak? ip1000a?
David Miller
Re: tun: Use netif_receive_skb instead of netif_rx
David Miller
Re: [net-next PATCH v2] llc enhancements
freebsd-current
:
Matthew Fleming
Re: [RFC] Outline of USB process integration in the kernel taskqueue system
illoai@gmail.com
Re: OT: 2d password
Hartmut Brandt
Re: problem with nss_ldap
Andrew Reilly
Re: FreeBSD's problems as seen by the BSDForen.de community
Max Laier
Re: Upcoming ABI Breakage in RELENG_7
Colocation donated by:
Syndicate