nemo (mtcoreboot(a)gmail.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/12882
-gerrit
commit 1f44588e2af7ce745efcbc60e780d5d6925bf1e2
Author: Marian Tietz <mtcoreboot(a)gmail.com>
Date: Sat Jan 9 18:18:47 2016 +0100
Enable USB 3 controller on ThinkPad X220
Since only X220 with i7 have the USB3 controller this was
probably overlooked.
Change-Id: I5e7e3f0c7d023f6206a7bec42a39f8955a3d9331
Signed-off-by: Marian Tietz <mtcoreboot(a)gmail.com>
---
src/mainboard/lenovo/x220/devicetree.cb | 4 +++-
src/mainboard/lenovo/x220/romstage.c | 2 +-
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/src/mainboard/lenovo/x220/devicetree.cb b/src/mainboard/lenovo/x220/devicetree.cb
index 9c9ac7c..9f25658 100644
--- a/src/mainboard/lenovo/x220/devicetree.cb
+++ b/src/mainboard/lenovo/x220/devicetree.cb
@@ -109,7 +109,9 @@ chip northbridge/intel/sandybridge
end
end # PCIe Port #5 (SD)
device pci 1c.5 off end # PCIe Port #6
- device pci 1c.6 off end # PCIe Port #7
+ device pci 1c.6 on
+ subsystemid 0x17aa 0x21db
+ end # PCIe Port #7
device pci 1c.7 off end # PCIe Port #8
device pci 1d.0 on
subsystemid 0x17aa 0x21db
diff --git a/src/mainboard/lenovo/x220/romstage.c b/src/mainboard/lenovo/x220/romstage.c
index 1d89d92..ce3f276 100644
--- a/src/mainboard/lenovo/x220/romstage.c
+++ b/src/mainboard/lenovo/x220/romstage.c
@@ -54,7 +54,7 @@ void pch_enable_lpc(void)
void rcba_config(void)
{
/* Disable unused devices (board specific) */
- RCBA32(FD) = 0x1fe41fe3;
+ RCBA32(FD) = 0x1fa41fe3;
RCBA32(BUC) = 0;
}
Nico Huber (nico.h(a)gmx.de) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/12884
-gerrit
commit 85420674b6961e125b8bc4cdcc7e49a67a4a3558
Author: Nico Huber <nico.h(a)gmx.de>
Date: Sat Jan 9 22:58:44 2016 +0100
nb/intel/gm45: Drop unnecessary panel power handling
Skip everything but the final setting of PP_CONTROL, i.e. triggering
the power up. The settings with PANEL_UNLOCK_REGS are useless as no
lockable registers were touched in between. Also the loop waiting for
the panel power up to finish was a no-op as the registers with the
power timings were never filled (see follow-up commits).
Change-Id: Ife27dcafdf197b2246c4e69f2bf7a3a6765d1d82
Signed-off-by: Nico Huber <nico.h(a)gmx.de>
---
src/northbridge/intel/gm45/gma.c | 15 ---------------
1 file changed, 15 deletions(-)
diff --git a/src/northbridge/intel/gm45/gma.c b/src/northbridge/intel/gm45/gma.c
index d5a133b..2824cf7 100644
--- a/src/northbridge/intel/gm45/gma.c
+++ b/src/northbridge/intel/gm45/gma.c
@@ -397,21 +397,6 @@ static void intel_gma_init(const struct northbridge_intel_gm45_config *info,
| LVDS_CLOCK_BOTH_POWERUP_ALL : 0)
| LVDS_BORDER_ENABLE | LVDS_CLOCK_A_POWERUP_ALL);
- write32(mmio + PP_CONTROL, PANEL_UNLOCK_REGS | PANEL_POWER_OFF);
- write32(mmio + PP_CONTROL, PANEL_UNLOCK_REGS | PANEL_POWER_RESET);
- mdelay(1);
- write32(mmio + PP_CONTROL, PANEL_UNLOCK_REGS
- | PANEL_POWER_ON | PANEL_POWER_RESET);
-
- printk (BIOS_DEBUG, "waiting for panel powerup\n");
- while (1) {
- u32 reg32;
- reg32 = read32(mmio + PP_STATUS);
- if (((reg32 >> 28) & 3) == 0)
- break;
- }
- printk (BIOS_DEBUG, "panel powered up\n");
-
write32(mmio + PP_CONTROL, PANEL_POWER_ON | PANEL_POWER_RESET);
/* Enable screen memory. */
the following patch was just integrated into master:
commit 8846382cbbbf301e313958aadc4bed2522796c1f
Author: Martin Roth <martinroth(a)google.com>
Date: Thu Jan 7 11:03:36 2016 -0700
buildgcc: Print out all missing tools then halt
Instead of printing out a single tool that needs to be installed
each time buildgcc is run, print out the entire list of tools
to be installed, then halt.
Change-Id: I7761760eef3c45ba371f882a4f987408945bb3e5
Signed-off-by: Martin Roth <martinroth(a)google.com>
Reviewed-on: https://review.coreboot.org/12856
Tested-by: build bot (Jenkins)
Reviewed-by: Stefan Reinauer <stefan.reinauer(a)coreboot.org>
See https://review.coreboot.org/12856 for details.
-gerrit
nemo (coreboot(a)nemo.ikkoku.de) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/12882
-gerrit
commit 427483f499603f65aa1ad1120a994bb1bd077cbe
Author: nemo <coreboot(a)nemo.ikkoku.de>
Date: Sat Jan 9 18:18:47 2016 +0100
Enable USB 3 controller on ThinkPad X220
Since only X220 with i7 have the USB3 controller this was
probably overlooked.
Change-Id: I5e7e3f0c7d023f6206a7bec42a39f8955a3d9331
Signed-off-by: nemo <coreboot(a)nemo.ikkoku.de>
---
src/mainboard/lenovo/x220/devicetree.cb | 4 +++-
src/mainboard/lenovo/x220/romstage.c | 2 +-
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/src/mainboard/lenovo/x220/devicetree.cb b/src/mainboard/lenovo/x220/devicetree.cb
index 9c9ac7c..9f25658 100644
--- a/src/mainboard/lenovo/x220/devicetree.cb
+++ b/src/mainboard/lenovo/x220/devicetree.cb
@@ -109,7 +109,9 @@ chip northbridge/intel/sandybridge
end
end # PCIe Port #5 (SD)
device pci 1c.5 off end # PCIe Port #6
- device pci 1c.6 off end # PCIe Port #7
+ device pci 1c.6 on
+ subsystemid 0x17aa 0x21db
+ end # PCIe Port #7
device pci 1c.7 off end # PCIe Port #8
device pci 1d.0 on
subsystemid 0x17aa 0x21db
diff --git a/src/mainboard/lenovo/x220/romstage.c b/src/mainboard/lenovo/x220/romstage.c
index 1d89d92..ce3f276 100644
--- a/src/mainboard/lenovo/x220/romstage.c
+++ b/src/mainboard/lenovo/x220/romstage.c
@@ -54,7 +54,7 @@ void pch_enable_lpc(void)
void rcba_config(void)
{
/* Disable unused devices (board specific) */
- RCBA32(FD) = 0x1fe41fe3;
+ RCBA32(FD) = 0x1fa41fe3;
RCBA32(BUC) = 0;
}
Alexandru Gagniuc (mr.nuke.me(a)gmail.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/12878
-gerrit
commit 133c7e9533826133c2b77878ba74d119be935f0d
Author: Alexandru Gagniuc <mr.nuke.me(a)gmail.com>
Date: Fri Jan 8 22:51:21 2016 -0800
cpu/qemu-x86/romstage_entry.inc: Remove redunant cache-as-ram code
This CPU doesn't use cache-as-ram; however, since it uses a C
environment bootblock, any such setup would have to be handled in the
bootblock anyway.
Ramstage is succesfully loaded and executed with this change.
Change-Id: Ib9a70fed933ac484f8a5632b6b8f1ab9f69a9ae0
Signed-off-by: Alexandru Gagniuc <mr.nuke.me(a)gmail.com>
---
src/cpu/qemu-x86/romstage_entry.inc | 18 ++++--------------
1 file changed, 4 insertions(+), 14 deletions(-)
diff --git a/src/cpu/qemu-x86/romstage_entry.inc b/src/cpu/qemu-x86/romstage_entry.inc
index fcd2d3b..9d7cf38 100644
--- a/src/cpu/qemu-x86/romstage_entry.inc
+++ b/src/cpu/qemu-x86/romstage_entry.inc
@@ -19,27 +19,17 @@
#include <cpu/x86/post_code.h>
#include <cbmem.h>
-#define CACHE_AS_RAM_SIZE 0x10000
-#define CACHE_AS_RAM_BASE 0xd0000
-
-#define CPU_PHYSMASK_HI (1 << (CONFIG_CPU_ADDR_BITS - 32) - 1)
+#define STACK_SIZE 0x10000
+#define STACK_BASE 0xd0000
/* Save the BIST result. */
movl %eax, %ebp
-cache_as_ram:
+qemu_x86_assembly_entry:
post_code(0x20)
- /* Clear the cache memory region. This will also fill up the cache */
- movl $CACHE_AS_RAM_BASE, %esi
- movl %esi, %edi
- movl $(CACHE_AS_RAM_SIZE >> 2), %ecx
- // movl $0x23322332, %eax
- xorl %eax, %eax
- rep stosl
- post_code(0x21)
/* Set up the stack pointer. */
- movl $(CACHE_AS_RAM_SIZE + CACHE_AS_RAM_BASE - 4), %eax
+ movl $(STACK_BASE + STACK_SIZE - 4), %eax
movl %eax, %esp
/* Restore the BIST result. */
Alexandru Gagniuc (mr.nuke.me(a)gmail.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/12879
-gerrit
commit 6f5ea8b84255f2d7e8b75c252d2bef53e7c66074
Author: Alexandru Gagniuc <mr.nuke.me(a)gmail.com>
Date: Fri Jan 8 22:57:58 2016 -0800
cpu/qemu-x86: Remove "bist" parameter handling from romstage
This parameter is unused at this point, so there is no reason hauling
it around in assembly in order to pass it to C code.
Change-Id: Ice3ff6f06f561099a3ed7764062f0ac0521855be
Signed-off-by: Alexandru Gagniuc <mr.nuke.me(a)gmail.com>
---
src/cpu/qemu-x86/romstage.h | 18 ++++++++++++++++++
src/cpu/qemu-x86/romstage_entry.inc | 8 --------
src/mainboard/emulation/qemu-i440fx/romstage.c | 4 ++--
src/mainboard/emulation/qemu-q35/romstage.c | 4 ++--
4 files changed, 22 insertions(+), 12 deletions(-)
diff --git a/src/cpu/qemu-x86/romstage.h b/src/cpu/qemu-x86/romstage.h
new file mode 100644
index 0000000..ea628c8
--- /dev/null
+++ b/src/cpu/qemu-x86/romstage.h
@@ -0,0 +1,18 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (C) 2016 Alexandru Gagniuc <mr.nuke.me(a)gmail.com>
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ */
+
+#ifndef _CPU_QEMU_X86_ROMSTAGE_H_
+#define _CPU_QEMU_X86_ROMSTAGE_H_
+
+/* romstage C entry point */
+void main(void);
+
+#endif /* _CPU_QEMU_X86_ROMSTAGE_H_ */
diff --git a/src/cpu/qemu-x86/romstage_entry.inc b/src/cpu/qemu-x86/romstage_entry.inc
index 9d7cf38..a2aba6a 100644
--- a/src/cpu/qemu-x86/romstage_entry.inc
+++ b/src/cpu/qemu-x86/romstage_entry.inc
@@ -22,9 +22,6 @@
#define STACK_SIZE 0x10000
#define STACK_BASE 0xd0000
- /* Save the BIST result. */
- movl %eax, %ebp
-
qemu_x86_assembly_entry:
post_code(0x20)
@@ -32,11 +29,6 @@ qemu_x86_assembly_entry:
movl $(STACK_BASE + STACK_SIZE - 4), %eax
movl %eax, %esp
- /* Restore the BIST result. */
- movl %ebp, %eax
- movl %esp, %ebp
- pushl %eax
-
before_romstage:
post_code(0x29)
/* Call romstage.c main function. */
diff --git a/src/mainboard/emulation/qemu-i440fx/romstage.c b/src/mainboard/emulation/qemu-i440fx/romstage.c
index 2d2a87e..1aa773d 100644
--- a/src/mainboard/emulation/qemu-i440fx/romstage.c
+++ b/src/mainboard/emulation/qemu-i440fx/romstage.c
@@ -27,8 +27,8 @@
#include "memory.c"
-#include <cpu/intel/romstage.h>
-void main(unsigned long bist)
+#include <cpu/qemu-x86/romstage.h>
+void main(void)
{
int cbmem_was_initted;
diff --git a/src/mainboard/emulation/qemu-q35/romstage.c b/src/mainboard/emulation/qemu-q35/romstage.c
index f6b7b63..bba605e 100644
--- a/src/mainboard/emulation/qemu-q35/romstage.c
+++ b/src/mainboard/emulation/qemu-q35/romstage.c
@@ -28,8 +28,8 @@
#include "../qemu-i440fx/memory.c"
-#include <cpu/intel/romstage.h>
-void main(unsigned long bist)
+#include <cpu/qemu-x86/romstage.h>
+void main(void)
{
int cbmem_was_initted;
Alexandru Gagniuc (mr.nuke.me(a)gmail.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/12881
-gerrit
commit 9f8d49f2dd87bbc41497f4250c1fb9e71d06949d
Author: Alexandru Gagniuc <mr.nuke.me(a)gmail.com>
Date: Fri Jan 8 23:08:09 2016 -0800
cpu/qemu-x86: Use run_romstage instead of custom inline assembly
Now that passing the BIST result to romstage is no longer required,
we no longer need to use custom assembly to call into romstage.
Instead, a lot of the logic in the bootblock can now be replaced by
a single call to run_romstage(). This is another step in converging
the bootblock with the generic bootblock logic in lib/.
Change-Id: I66436c8fba5121a3758d02955f691ac9d273b049
Signed-off-by: Alexandru Gagniuc <mr.nuke.me(a)gmail.com>
---
src/cpu/qemu-x86/bootblock.c | 34 ++--------------------------------
1 file changed, 2 insertions(+), 32 deletions(-)
diff --git a/src/cpu/qemu-x86/bootblock.c b/src/cpu/qemu-x86/bootblock.c
index b4700a7..056bde4 100644
--- a/src/cpu/qemu-x86/bootblock.c
+++ b/src/cpu/qemu-x86/bootblock.c
@@ -18,32 +18,8 @@
/* Called from assembly. Prototype not needed by external .c file */
asmlinkage void bootblock_main(uint32_t bist, uint32_t tsc_lo, uint32_t tsc_hi);
-/*
- * TODO: Implement a generic fallback/normal mechanism
- */
-static const char *get_next_stage_name(void)
-{
- if (IS_ENABLED(CONFIG_BOOTBLOCK_SIMPLE))
- return CONFIG_CBFS_PREFIX "/romstage";
-
- /* BOOTBLOCK_NORMAL not implemented */
- return CONFIG_CBFS_PREFIX "/romstage";
-}
-
-static void enter_romstage(void *romstage_entry, uint32_t bist)
-{
- asm volatile (
- "jmp *%0\n\t"
- : : "r" (romstage_entry), "a" (bist)
- );
-}
-
asmlinkage void bootblock_main(uint32_t bist, uint32_t tsc_lo, uint32_t tsc_hi)
{
- void *entry;
- struct cbfs_stage *romstage;
- const char* target1 = get_next_stage_name();
-
if (IS_ENABLED(CONFIG_BOOTBLOCK_CONSOLE))
console_init();
@@ -53,14 +29,8 @@ asmlinkage void bootblock_main(uint32_t bist, uint32_t tsc_lo, uint32_t tsc_hi)
*/
report_bist_failure(bist);
- romstage = cbfs_boot_map_with_leak(target1, CBFS_TYPE_STAGE, NULL);
+ run_romstage();
- /*
- * TODO: Do something constructive with tsc_lo and tsc_hi
- */
- if (romstage) {
- entry = (void *)(uintptr_t)romstage->entry;
- enter_romstage(entry, bist);
- }
+ /* Should never be reached, but halt just in case. */
halt();
}