the following patch was just integrated into master:
commit 05e7498dcca3a17c2541d2a32b8fbcbd2c78feda
Author: Vladimir Serbinenko <phcoder(a)gmail.com>
Date: Wed Feb 19 22:12:02 2014 +0100
lib/edid: Don't set vbe_valid in decode_edid.
Decoding EDID doesn't yet mean that gfx mode is used.
Change-Id: Icedd36f26877754f34dd59233cce72271d7f0b19
Signed-off-by: Vladimir Serbinenko <phcoder(a)gmail.com>
See http://review.coreboot.org/5269 for details.
-gerrit
Edward O'Callaghan (eocallaghan(a)alterapraxis.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/4719
-gerrit
commit f92c7736b2e3c715a2261a6f80ac9f47a8bf1ce5
Author: Edward O'Callaghan <eocallaghan(a)alterapraxis.com>
Date: Thu Feb 20 05:10:09 2014 +1100
CAR_GLOBAL: enforce compiler to check if _start != _end
There are some fun rules C compilers can use to optimize their code.
One of them is the assumption that two symbols point to two different
addresses.
In this case this wasn't true, resulting in unintended code execution
(and later, a crash) with a clang build.
Change-Id: I1496b22e1d1869ed0610e321b6ec6a83252e9d8b
Signed-off-by: Patrick Georgi <patrick(a)georgi-clan.de>
Signed-off-by: Edward O'Callaghan <eocallaghan(a)alterapraxis.com>
---
src/arch/x86/init/romstage.ld | 1 +
src/cpu/x86/car.c | 3 +--
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/src/arch/x86/init/romstage.ld b/src/arch/x86/init/romstage.ld
index f44185f..5458cfc 100644
--- a/src/arch/x86/init/romstage.ld
+++ b/src/arch/x86/init/romstage.ld
@@ -37,6 +37,7 @@ SECTIONS
. = ALIGN(16);
_car_migrate_start = .;
*(.car.migrate);
+ LONG(0);
_car_migrate_end = .;
. = ALIGN(16);
_erom = .;
diff --git a/src/cpu/x86/car.c b/src/cpu/x86/car.c
index 481153d..a7e3842 100644
--- a/src/cpu/x86/car.c
+++ b/src/cpu/x86/car.c
@@ -26,7 +26,6 @@
typedef void (* const car_migration_func_t)(void);
extern car_migration_func_t _car_migrate_start;
-extern car_migration_func_t _car_migrate_end;
extern char _car_data_start[];
extern char _car_data_end[];
@@ -98,7 +97,7 @@ void car_migrate_variables(void)
/* Call all the migration functions. */
migrate_func = &_car_migrate_start;
- while (migrate_func != &_car_migrate_end) {
+ while (*migrate_func != NULL) {
(*migrate_func)();
migrate_func++;
}
Edward O'Callaghan (eocallaghan(a)alterapraxis.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/5272
-gerrit
commit b6eea31187d4be47e425beb2bd0af572e5b01ec8
Author: Edward O'Callaghan <eocallaghan(a)alterapraxis.com>
Date: Thu Feb 20 16:08:51 2014 +1100
qemu-i440fx: Ignore missing prototype for entry point main()
The main of romstage in qemu-i440fx is called as the entry point in
assembler and so should be compiled with -ffreestanding. We should also
ignore a missing prototype in this particular case.
Change-Id: Id0ce2348483c6e5388369000451811673f0c4eaa
Signed-off-by: Edward O'Callaghan <eocallaghan(a)alterapraxis.com>
---
src/arch/x86/Makefile.inc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/src/arch/x86/Makefile.inc b/src/arch/x86/Makefile.inc
index 4b28697..7362b64 100644
--- a/src/arch/x86/Makefile.inc
+++ b/src/arch/x86/Makefile.inc
@@ -266,7 +266,7 @@ else
$(obj)/mainboard/$(MAINBOARDDIR)/romstage.pre.inc: $(src)/mainboard/$(MAINBOARDDIR)/romstage.c $(OPTION_TABLE_H) $(obj)/build.h $(obj)/config.h
@printf " CC romstage.inc\n"
- $(CC) -MMD $(CFLAGS) -D__PRE_RAM__ -I$(src) -I. -I$(obj) -c -S $< -o $@
+ $(CC) -MMD $(CFLAGS) -ffreestanding -Wno-missing-prototypes -D__PRE_RAM__ -I$(src) -I. -I$(obj) -c -S $< -o $@
$(obj)/mainboard/$(MAINBOARDDIR)/romstage.inc: $(obj)/mainboard/$(MAINBOARDDIR)/romstage.pre.inc
@printf " POST romstage.inc\n"
Edward O'Callaghan (eocallaghan(a)alterapraxis.com) just uploaded a new patch set to gerrit, which you can find at http://review.coreboot.org/5273
-gerrit
commit c1f183f28cf0cc59fc96a7d916bef407c7c717ab
Author: Edward O'Callaghan <eocallaghan(a)alterapraxis.com>
Date: Thu Feb 20 19:37:42 2014 +1100
romcc.c: Suppress warning about unused function.
GCC suppresses warnings about unused static functions if they are
inline, however Clang only does this for header files. Add attribute to
suppress unused function warning on Clang.
Change-Id: Ia230beba3f6367237838d9b3d90536459e1d52cb
Signed-off-by: Edward O'Callaghan <eocallaghan(a)alterapraxis.com>
---
util/romcc/romcc.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/util/romcc/romcc.c b/util/romcc/romcc.c
index b045b46..3ac42f7 100644
--- a/util/romcc/romcc.c
+++ b/util/romcc/romcc.c
@@ -5648,6 +5648,7 @@ static struct type *invalid_type(struct compile_state *state, struct type *type)
#define MASK_UCHAR(X) ((X) & ((ulong_t)0xff))
#define MASK_USHORT(X) ((X) & (((ulong_t)1 << (SIZEOF_SHORT)) - 1))
+static inline ulong_t mask_uint(ulong_t x) __attribute__((unused));
static inline ulong_t mask_uint(ulong_t x)
{
if (SIZEOF_INT < SIZEOF_LONG) {