lkml.org 
[lkml]   [2009]   [Apr]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [PATCH 05/15] arm: convert to use __HEAD and HEAD_TEXT macros.


On Mon, 27 Apr 2009, Tim Abbott wrote:
>
> Does .head.text actually need its own output section here?

Probably not. Does the ARM build system massage the end result some way
looking for that .text.head section in the end? As you note, nobody else
cares, and the proper patch may be more along the lines of something
below.

Of course, most other architectures put the "init" section at the end, and
leave the HEAD_TEXT in the regular text section, but I suspect the ARM way
of laying things out (init text first) is probably better, since it allows
you to free that head code too.

Not that it likely much matters.

Linus

---
arch/arm/kernel/vmlinux.lds.S | 8 +++-----
1 files changed, 3 insertions(+), 5 deletions(-)
diff --git a/arch/arm/kernel/vmlinux.lds.S b/arch/arm/kernel/vmlinux.lds.S
index c90f272..15520be 100644
--- a/arch/arm/kernel/vmlinux.lds.S
+++ b/arch/arm/kernel/vmlinux.lds.S
@@ -23,13 +23,11 @@ SECTIONS
#else
. = PAGE_OFFSET + TEXT_OFFSET;
#endif
- .text.head : {
- _stext = .;
- _sinittext = .;
- *(.text.head)
- }

.init : { /* Init code and data */
+ _stext = .;
+ _sinittext = .;
+ HEAD_TEXT
INIT_TEXT
_einittext = .;
__proc_info_begin = .;

\
 
 \ /
  Last update: 2009-04-27 19:29    [W:0.300 / U:0.320 seconds]
©2003-2014 Jasper Spaans. Advertise on this site