login
Login
/
Register
Search
Forums
News
Blogs
Features
Site
Home
»
Mailing list archives
»
linux-kernel
»
2008
»
January
»
15
Re: [PATCH] i386 : Make arch/x86/kernel/acpi/wakeup_32.S use a separate text section
view
thread
!MAILaRCHIVE_VOTE_RePLACE
Previous message: [
thread
] [
date
] [
author
]
Next message: [
thread
] [
date
] [
author
]
[view in full thread]
From:
Pavel Machek <pavel@...>
To: Eric Dumazet <dada1@...>, Rafael J. Wysocki <rjw@...>
Cc: Ingo Molnar <mingo@...>, linux kernel <linux-kernel@...>
Subject:
Re: [PATCH] i386 : Make arch/x86/kernel/acpi/wakeup_32.S use a separate text section
Date: Tuesday, January 15, 2008 - 6:08 pm
On Thu 2008-01-03 21:04:26, Eric Dumazet wrote:
quoted text
> While examining vmlinux namelist on i386 (nm -v vmlinux) I noticed : > > c01021d0 t es7000_rename_gsi > c010221a T es7000_start_cpu > <Big Hole> > c0103000 T thread_saved_pc > > and > > c0113218 T acpi_restore_state_mem > c0113219 T acpi_save_state_mem > <Big Hole> > c0114000 t wakeup_code > > This is because arch/x86/kernel/acpi/wakeup_32.S forces a .text alignment > of 4096 bytes. (I have no idea if it is really needed, since > arch/x86/kernel/acpi/wakeup_64.S uses a 16 bytes alignment *only*) > > So arch/x86/kernel/built-in.o also has this alignment > > arch/x86/kernel/built-in.o: file format elf32-i386 > > Sections: > Idx Name Size VMA LMA File off Algn > 0 .text 00018c94 00000000 00000000 00001000 2**12 > CONTENTS, ALLOC, LOAD, RELOC, READONLY, CODE > > But as arch/x86/kernel/acpi/wakeup_32.o is not the first object linked > into arch/x86/kernel/built-in.o, linker had to build several holes to meet > alignement requirements, because of .o nestings in the kbuild process. > > This can be solved by using a special section, .text.page_aligned, so that > no holes are needed. > > > # size vmlinux.before vmlinux.after > text data bss dec hex filename > 4619942 422838 458752 5501532 53f25c vmlinux.before > 4610534 422838 458752 5492124 53cd9c vmlinux.after > > This saves 9408 bytes > > Signed-off-by: Eric Dumazet <dada1@cosmosbay.com>
Seems okay to me, but I did not test it.
quoted text
> diff --git a/arch/x86/kernel/acpi/wakeup_32.S b/arch/x86/kernel/acpi/wakeup_32.S > index 1e931aa..f53e327 100644 > --- a/arch/x86/kernel/acpi/wakeup_32.S > +++ b/arch/x86/kernel/acpi/wakeup_32.S > @@ -1,4 +1,4 @@ > -.text > + .section .text.page_aligned > #include <linux/linkage.h> > #include <asm/segment.h> > #include <asm/page.h> > diff --git a/arch/x86/kernel/vmlinux_32.lds.S b/arch/x86/kernel/vmlinux_32.lds.S > index 7d72cce..113a831 100644 > --- a/arch/x86/kernel/vmlinux_32.lds.S > +++ b/arch/x86/kernel/vmlinux_32.lds.S > @@ -44,6 +44,8 @@ SECTIONS > > /* read-only */ > .text : AT(ADDR(.text) - LOAD_OFFSET) { > + . = ALIGN(4096); /* not really needed, already page aligned */ > + *(.text.page_aligned) > TEXT_TEXT > SCHED_TEXT > LOCK_TEXT > > -- > 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/
-- (english)
http://www.livejournal.com/~pavelmachek
(cesky, pictures)
http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
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] i386 : Make arch/x86/kernel/acpi/wakeup_32.S use a s...
, Eric Dumazet
, (Thu Jan 3, 4:04 pm)
Re: [PATCH] i386 : Make arch/x86/kernel/acpi/wakeup_32.S use...
, Pavel Machek
, (Tue Jan 15, 6:08 pm)
Re: [PATCH] i386 : Make arch/x86/kernel/acpi/wakeup_32.S use...
, Ingo Molnar
, (Sat Jan 5, 11:11 am)
Re: [PATCH] i386 : Make arch/x86/kernel/acpi/wakeup_32.S use...
, Matt Mackall
, (Tue Jan 8, 5:27 pm)
Navigation
Create content
Mailing list archives
Recent posts
Popular discussions
linux-kernel
:
david
Re: Dual-Licensing Linux Kernel with GPL V2 and GPL V3
Greg Kroah-Hartman
[PATCH 001/196] Chinese: Add the known_regression URI to the HOWTO
Justin C. Sherrill
Mailing list archive
Ingo Molnar
[patch 08/13] syslets: x86, add move_user_context() method
git
:
linux-netdev
:
Steven Rostedt
Re: -rt scheduling: wakeup bug?
David Miller
[GIT]: Networking
Jarek Poplawski
Re: [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock().
Gerrit Renker
[PATCH 27/37] dccp: Integration of dynamic feature activation - part 2 (server side)
openbsd-misc
:
Colocation donated by:
Who's online
There are currently
14 users
and
935 guests
online.
Online users
strcmp
zeekec
childrensfurni
electricpatioh
loanschicagopx
torontomortgag
razmikmckayjzs
findphonenumbe
extralongshowe
xphomenetworkt
uniquechristma
sellinvestment
mr.chaka
cleanseynw
Syndicate