summaryrefslogtreecommitdiff
path: root/src/southbridge
diff options
context:
space:
mode:
authorAlexandru Gagniuc <mr.nuke.me@gmail.com>2015-10-02 10:59:13 -0700
committerAlexandru Gagniuc <mr.nuke.me@gmail.com>2015-10-07 03:08:58 +0000
commit72bb66eb9cecf94b66a4aca3586165d5495fcfdb (patch)
tree181f29ae1450f1a3596c4ba70c40688e35671137 /src/southbridge
parent3f4a997529dfedaa4eefd00dc7d5ab32aa8e7b77 (diff)
x86/bootblock: Use LDFLAGS_bootblock to enable garbage collection
The x86 bootblock linking is a mess. The bootblock is treated in a very special manner, and never received the update to link-time garbage collection. On newer x86 platforms, the boot media is no longer memory-mapped. That means we need to do a lot more setup in the bootblock. ROMCC is unsuitable for this task, and walkcbfs only works on memory-mapped CBFS. We need to revise the x86 bootflow for this new case. The approach this patch series takes is to perform CAR setup in the bootblock, and load the following stage (either romstage or verstage) from the boot media. This approach is not new, but has been done on our ARM ports for years. Since we will be adding .c files to the bootblock, it is prudent to use link-time garbage collection. This is also consistent to how we do things on other architectures. Unification FTW! Change-Id: I16b78456df56e0053984a9aca9367e2542adfdc9 Signed-off-by: Alexandru Gagniuc <mr.nuke.me@gmail.com> Reviewed-on: http://review.coreboot.org/11781 Tested-by: build bot (Jenkins) Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Diffstat (limited to 'src/southbridge')
-rw-r--r--src/southbridge/nvidia/ck804/romstrap.ld2
-rw-r--r--src/southbridge/nvidia/mcp55/romstrap.ld2
-rw-r--r--src/southbridge/sis/sis966/romstrap.ld2
-rw-r--r--src/southbridge/via/k8t890/romstrap.ld2
4 files changed, 4 insertions, 4 deletions
diff --git a/src/southbridge/nvidia/ck804/romstrap.ld b/src/southbridge/nvidia/ck804/romstrap.ld
index e75e6a4be0..1d074ab7a4 100644
--- a/src/southbridge/nvidia/ck804/romstrap.ld
+++ b/src/southbridge/nvidia/ck804/romstrap.ld
@@ -21,6 +21,6 @@
SECTIONS {
. = (0xffffffff - 0x10) - (__romstrap_end - __romstrap_start) + 1;
.romstrap (.): {
- *(.romstrap)
+ KEEP(*(.romstrap))
}
}
diff --git a/src/southbridge/nvidia/mcp55/romstrap.ld b/src/southbridge/nvidia/mcp55/romstrap.ld
index 05685be497..ad2bf05bde 100644
--- a/src/southbridge/nvidia/mcp55/romstrap.ld
+++ b/src/southbridge/nvidia/mcp55/romstrap.ld
@@ -22,6 +22,6 @@
SECTIONS {
. = (0xffffffff - 0x10) - (__romstrap_end - __romstrap_start) + 1;
.romstrap (.): {
- *(.romstrap)
+ KEEP(*(.romstrap))
}
}
diff --git a/src/southbridge/sis/sis966/romstrap.ld b/src/southbridge/sis/sis966/romstrap.ld
index 05685be497..ad2bf05bde 100644
--- a/src/southbridge/sis/sis966/romstrap.ld
+++ b/src/southbridge/sis/sis966/romstrap.ld
@@ -22,6 +22,6 @@
SECTIONS {
. = (0xffffffff - 0x10) - (__romstrap_end - __romstrap_start) + 1;
.romstrap (.): {
- *(.romstrap)
+ KEEP(*(.romstrap))
}
}
diff --git a/src/southbridge/via/k8t890/romstrap.ld b/src/southbridge/via/k8t890/romstrap.ld
index 71349e09ff..cf17b368a2 100644
--- a/src/southbridge/via/k8t890/romstrap.ld
+++ b/src/southbridge/via/k8t890/romstrap.ld
@@ -24,6 +24,6 @@
SECTIONS {
. = (0xffffffff - 0x2c) - (__romstrap_end - __romstrap_start) + 1;
.romstrap (.): {
- *(.romstrap)
+ KEEP(*(.romstrap))
}
}