Skip to contentSkip to conversation

section .data..init_task

PATCH In review Sean MacLennan 3 participants 11 messages Jun 28, 2010 – Jul 23, 2010 Generic include/asm header files

lore
Share & tools
lore
#0 lore raw

Anybody else seeing these messages?

ppc_4xxFP-ld: .tmp_vmlinux1: section .data..init_task lma 0xc0374000 overlaps previous sections
ppc_4xxFP-ld: .tmp_vmlinux2: section .data..init_task lma 0xc03a2000 overlaps previous sections
ppc_4xxFP-ld: vmlinux: section .data..init_task lma 0xc03a2000 overlaps previous sections

Or does anybody know what they mean? They started showing up in 2.6.35.

Very easy to reproduce, so don't hesitate to ask for more info.

Cheers,
Sean

#1 lore raw
Quoted 8 lines · On Mon, 28 Jun 2010 00:59:00 -0400 Sean MacLennan <[email protected]>…

Anybody else seeing these messages?

ppc_4xxFP-ld: .tmp_vmlinux1: section .data..init_task lma 0xc0374000 overlaps previous sections ppc_4xxFP-ld: .tmp_vmlinux2:
section .data..init_task lma 0xc03a2000 overlaps previous sections
ppc_4xxFP-ld: vmlinux: section .data..init_task lma 0xc03a2000 overlaps previous sections

Quoted 4 lines

Or does anybody know what they mean? They started showing up in 2.6.35.

Very easy to reproduce, so don't hesitate to ask for more info.

I had a bit of time, so I tracked this down. This patch seems to be the culprit: http://lkml.org/lkml/2010/2/19/366

Specifically, this code:

/* The initial task and kernel stack */
- .data.init_task : AT(ADDR(.data.init_task) - LOAD_OFFSET) {
- INIT_TASK_DATA(THREAD_SIZE)
- }
+ INIT_TASK_DATA_SECTION(THREAD_SIZE)

If I change it back to:

	/* The initial task and kernel stack */
	.data..init_task : AT(ADDR(.data..init_task) - LOAD_OFFSET) {
		INIT_TASK_DATA(THREAD_SIZE)
	}

not only do the warnings go away, but the kernel now boots again!

Cheers,
Sean

#2 lore raw
Quoted 27 lines · Sean MacLennan
Quoted 8 lines · On Mon, 28 Jun 2010 00:59:00 -0400 Sean MacLennan <[email protected]>…

Anybody else seeing these messages?

ppc_4xxFP-ld: .tmp_vmlinux1: section .data..init_task lma 0xc0374000 overlaps previous sections ppc_4xxFP-ld: .tmp_vmlinux2:
section .data..init_task lma 0xc03a2000 overlaps previous sections
ppc_4xxFP-ld: vmlinux: section .data..init_task lma 0xc03a2000 overlaps previous sections

Quoted 4 lines

Or does anybody know what they mean? They started showing up in 2.6.35.

Very easy to reproduce, so don't hesitate to ask for more info.

I had a bit of time, so I tracked this down. This patch seems to be the culprit: http://lkml.org/lkml/2010/2/19/366

Specifically, this code:

(quoted diff) +1 -3
 	/* The initial task and kernel stack */
-	.data.init_task : AT(ADDR(.data.init_task) - LOAD_OFFSET) {
-		INIT_TASK_DATA(THREAD_SIZE)
-	}
+	INIT_TASK_DATA_SECTION(THREAD_SIZE)
Quoted 8 lines

If I change it back to:

	/* The initial task and kernel stack */
	.data..init_task : AT(ADDR(.data..init_task) - LOAD_OFFSET) {
		INIT_TASK_DATA(THREAD_SIZE)
	}

not only do the warnings go away, but the kernel now boots again!

It looks like a missing AT() in the output section. The following patch should also fix it.

Please test and let us know.

Thanks,
Sam

include/asm-generic/vmlinux.lds.h +1 -1
index 48c5299..3c4bf03 100644
@@ -435,7 +435,7 @@
  */
 #define INIT_TASK_DATA_SECTION(align)					\
 	. = ALIGN(align);						\
-	.data..init_task : {						\
+	.data..init_task : AT(ADDR(.data..init_task) - LOAD_OFFSET) {	\
 		INIT_TASK_DATA(align)					\
 	}
 
#3 lore raw
Quoted 7 lines · On Tue, 13 Jul 2010 10:54:19 +0200 Sam Ravnborg <[email protected]> wrote:

It looks like a missing AT() in the output section. The following patch should also fix it.

Please test and let us know.

Thanks,
Sam

Applied the patch and it solves the problem. Thanks.

Cheers,
Sean

#4 lore raw
Quoted 6 lines · Sean MacLennan
Quoted 3 lines · On Tue, 13 Jul 2010 10:54:19 +0200 Sam Ravnborg <[email protected]> wrote:

It looks like a missing AT() in the output section. The following patch should also fix it.

Quoted 6 lines
Quoted 4 lines

Please test and let us know.

Thanks,
Sam

Applied the patch and it solves the problem. Thanks.

Thanks for the quick feedback!

Sam

#5 lore raw

[

In reply to Sean MacLennan
Quoted 1 line

From 851e645a7eee68380caaf026eb6d3be118876370 Mon Sep 17 00:00:00 2001

From: Sam Ravnborg <[email protected]>
Date: Tue, 13 Jul 2010 11:39:42 +0200
Subject: [PATCH] vmlinux.lds: fix .data..init_task output section (fix popwerpc boot)

The .data..init_task output section was missing a load offset causing a popwerpc target to fail to boot.

Sean MacLennan tracked it down to the definition of INIT_TASK_DATA_SECTION().

There are only two users of INIT_TASK_DATA_SECTION() in the kernel today: cris and popwerpc.
cris do not support relocatable kernels and is thus not impacted by this change.

Fix INIT_TASK_DATA_SECTION() to specify load offset like all other output sections.

---

On the assumption that Sean reports that it fixes the warnings/boot issue here is a real patch.

Ben - will you take it via the popwerpc tree or shall I ask Michal to take it via kbuild?

Sam

 include/asm-generic/vmlinux.lds.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
include/asm-generic/vmlinux.lds.h +1 -1
index 48c5299..cdfff74 100644
@@ -435,7 +435,7 @@
  */
 #define INIT_TASK_DATA_SECTION(align)					\
 	. = ALIGN(align);						\
-	.data..init_task : {						\
+	.data..init_task :  AT(ADDR(.data..init_task) - LOAD_OFFSET) {	\
 		INIT_TASK_DATA(align)					\
 	}
 
Signature · 1 line
1.6.0.6
#6 lore raw

Re: [

Quoted 2 lines · On Tue, 13 Jul 2010 11:50:24 +0200 Sam Ravnborg <[email protected]> wrote:

Ben - will you take it via the popwerpc tree
or shall I ask Michal to take it via kbuild?

Anything happening with this patch?

Cheers,
Sean

#7 lore raw

Re: [

Quoted 7 lines · Sean MacLennan
Quoted 2 lines · On Tue, 13 Jul 2010 11:50:24 +0200 Sam Ravnborg <[email protected]> wrote:

Ben - will you take it via the popwerpc tree
or shall I ask Michal to take it via kbuild?

Anything happening with this patch?

The subject line tripped my spam filter ...

I'm happy to take it.

Sean, make sure it's on patchwork and it will be in one of my next batches.

Cheers,
Ben.

#8 lore raw

PATCH 1/1 powerpc: fix .data..init_task output section

In reply to Sam Ravnborg
Quoted 50 lines · On Tue, 13 Jul 2010 11:50:24 +0200 Sam Ravnborg <[email protected]> wrote:

From 851e645a7eee68380caaf026eb6d3be118876370 Mon Sep 17 00:00:00 2001
From: Sam Ravnborg <[email protected]>
Date: Tue, 13 Jul 2010 11:39:42 +0200
Subject: [PATCH] vmlinux.lds: fix .data..init_task output section (fix popwerpc boot)

The .data..init_task output section was missing a load offset causing a popwerpc target to fail to boot.

Sean MacLennan tracked it down to the definition of INIT_TASK_DATA_SECTION().

There are only two users of INIT_TASK_DATA_SECTION() in the kernel today: cris and popwerpc.
cris do not support relocatable kernels and is thus not impacted by this change.

Fix INIT_TASK_DATA_SECTION() to specify load offset like all other output sections.

---

On the assumption that Sean reports that it fixes the warnings/boot issue here is a real patch.

Ben - will you take it via the popwerpc tree
or shall I ask Michal to take it via kbuild?

Sam

 include/asm-generic/vmlinux.lds.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
(quoted diff) +0 -0

b/include/asm-generic/vmlinux.lds.h index 48c5299..cdfff74 100644

include/asm-generic/vmlinux.lds.h +1 -1
@@ -435,7 +435,7 @@
  */
 #define
 INIT_TASK_DATA_SECTION(align)
 \ . = ALIGN(align);						\
-	.data..init_task :
 {						\
+	.data..init_task :  AT(ADDR(.data..init_task) - LOAD_OFFSET)
 {	\

INIT_TASK_DATA(align) \ }

Tested-by Sean MacLennan on v1 1/1
#9 lore raw

Re: [PATCH] powerpc: fix .data..init_task output section

Quoted 27 lines · Sean MacLennan
Quoted 24 lines · On Tue, 13 Jul 2010 11:50:24 +0200 Sam Ravnborg <[email protected]> wrote:

From 851e645a7eee68380caaf026eb6d3be118876370 Mon Sep 17 00:00:00 2001
From: Sam Ravnborg <[email protected]>
Date: Tue, 13 Jul 2010 11:39:42 +0200
Subject: [PATCH] vmlinux.lds: fix .data..init_task output section (fix popwerpc boot)

The .data..init_task output section was missing a load offset causing a popwerpc target to fail to boot.

Sean MacLennan tracked it down to the definition of INIT_TASK_DATA_SECTION().

There are only two users of INIT_TASK_DATA_SECTION() in the kernel today: cris and popwerpc.
cris do not support relocatable kernels and is thus not impacted by this change.

Fix INIT_TASK_DATA_SECTION() to specify load offset like all other output sections.

---

Quoted 7 lines
Quoted 7 lines

On the assumption that Sean reports that it fixes the warnings/boot issue here is a real patch.

Ben - will you take it via the popwerpc tree
or shall I ask Michal to take it via kbuild?

Sam

Sorry for the bad initial subject line!
As Sean reported that the patch fixes his isuse it deserves a:

Sam

#10 lore raw

Re: [PATCH] powerpc: fix .data..init_task output section

Quoted 8 lines
Quoted 8 lines
Quoted 8 lines

On the assumption that Sean reports that it fixes
the warnings/boot issue here is a real patch.

Ben - will you take it via the popwerpc tree
or shall I ask Michal to take it via kbuild?

Quoted 7 lines
Quoted 1 line
Quoted 1 line

Sam

Sorry for the bad initial subject line!
As Sean reported that the patch fixes his isuse it deserves a:

Heh. Too late, I already sent it to Linus :-)

Ben.