lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Thu,  7 May 2009 15:26:51 -0700
From:	"H. Peter Anvin" <hpa@...ux.intel.com>
To:	linux-kernel@...r.kernel.org
Cc:	vgoyal@...hat.com, hbabu@...ibm.com, kexec@...ts.infradead.org,
	ying.huang@...el.com, mingo@...e.hu, tglx@...utronix.de,
	ebiederm@...ssion.com, sam@...nborg.org,
	"H. Peter Anvin" <hpa@...or.com>
Subject: [PATCH 03/14] x86, config: change defaults PHYSICAL_START and PHYSICAL_ALIGN

From: H. Peter Anvin <hpa@...or.com>

Change the default for CONFIG_PHYSICAL_START to 16 MB; 4 MB if
EMBEDDED.  Change the default for CONFIG_PHYSICAL_ALIGN to match up
with a large page alignment datum (4 MB for non-PAE, 2 MB for PAE.)

The default of 16 MB is designed to avoid occupying ZONE_DMA, as well
as avoiding a 15-16 MB memory hole, which some vendors inexplicably
still have in their systems.

[ Impact: minor performance improvement, leave ZONE_DMA free ]

Signed-off-by: H. Peter Anvin <hpa@...or.com>
---
 arch/x86/Kconfig |   19 +++++++++++--------
 1 files changed, 11 insertions(+), 8 deletions(-)

diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
index 039c3f0..13b3a5a 100644
--- a/arch/x86/Kconfig
+++ b/arch/x86/Kconfig
@@ -1455,17 +1455,20 @@ config KEXEC_JUMP
 
 config PHYSICAL_START
 	hex "Physical address where the kernel is loaded" if (EMBEDDED || CRASH_DUMP)
-	default "0x1000000" if X86_NUMAQ
-	default "0x200000" if X86_64
-	default "0x100000"
+	default "0x400000" if EMBEDDED
+	default "0x1000000"
 	---help---
 	  This gives the physical address where the kernel is loaded.
 
 	  If kernel is a not relocatable (CONFIG_RELOCATABLE=n) then
 	  bzImage will decompress itself to above physical address and
-	  run from there. Otherwise, bzImage will run from the address where
-	  it has been loaded by the boot loader and will ignore above physical
-	  address.
+	  run from there. Otherwise, bzImage will run from the either
+	  the above physical address or where it has been loaded by
+	  the boot loader, whichever is higher.
+
+	  For embedded machines with very small memory (less than
+	  about 24 MB) this may need to be adjusted downward from the
+	  default value of 0x1000000 (16 MB).
 
 	  In normal kdump cases one does not have to set/change this option
 	  as now bzImage can be compiled as a completely relocatable image
@@ -1516,8 +1519,8 @@ config RELOCATABLE
 config PHYSICAL_ALIGN
 	hex
 	prompt "Alignment value to which kernel should be aligned" if X86_32
-	default "0x100000" if X86_32
-	default "0x200000" if X86_64
+	default "0x200000" if X86_64 || X86_PAE
+	default "0x400000"
 	range 0x2000 0x400000
 	---help---
 	  This value puts the alignment restrictions on physical address
-- 
1.6.0.6

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ