Patrick Georgi (pgeorgi(a)google.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/14087
-gerrit
commit fed41960a6a2d9f9965af6d8dace5673b04c2177
Author: Koro Chen <koro.chen(a)mediatek.com>
Date: Mon Mar 7 11:27:26 2016 +0800
google/oak: Remove EC_SUSPEND_L from AP
This pin is not used anymore since Rev5.
BRANCH=none
BUG=chrome-os-partner:49375
TEST=make and boot on Rev4/5
Change-Id: I3c775eb2b5e05256523bfd8be814e516944a2f90
Signed-off-by: Patrick Georgi <pgeorgi(a)chromium.org>
Original-Commit-Id: a87e3babe28413bd879a2d95d4612a5b6b541419
Original-Change-Id: I87972ff8961309ecdad03639e1b6fac1da119cd7
Original-Signed-off-by: Koro Chen <koro.chen(a)mediatek.com>
Original-Reviewed-on: https://chromium-review.googlesource.com/331810
Original-Commit-Ready: Yidi Lin <yidi.lin(a)mediatek.com>
Original-Tested-by: Yidi Lin <yidi.lin(a)mediatek.com>
Original-Reviewed-by: Julius Werner <jwerner(a)chromium.org>
---
src/mainboard/google/oak/chromeos.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/src/mainboard/google/oak/chromeos.c b/src/mainboard/google/oak/chromeos.c
index 47d816b..8ea975a 100644
--- a/src/mainboard/google/oak/chromeos.c
+++ b/src/mainboard/google/oak/chromeos.c
@@ -13,6 +13,7 @@
* GNU General Public License for more details.
*/
+#include <boardid.h>
#include <boot/coreboot_tables.h>
#include <console/console.h>
#include <ec/google/chromeec/ec.h>
@@ -30,7 +31,8 @@ void setup_chromeos_gpios(void)
gpio_input_pullup(EC_IRQ);
gpio_input_pullup(LID);
gpio_input_pullup(POWER_BUTTON);
- gpio_output(EC_SUSPEND_L, 1);
+ if (board_id() < 5)
+ gpio_output(EC_SUSPEND_L, 1);
}
void fill_lb_gpios(struct lb_gpios *gpios)
Patrick Georgi (pgeorgi(a)google.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/13968
-gerrit
commit 64dfa631c77666c7d196d8fc6bdeef0fd34ce77f
Author: Patrick Georgi <pgeorgi(a)chromium.org>
Date: Tue Mar 8 21:42:00 2016 +0100
mediatek/mt8173: Enable ARM trusted firmware integration
In Chromium OS downstream this was done together with adding the support
for ATF, but unfortunately ATF upstream isn't ready yet. This commit
is a reminder to enable things once ATF caught up.
Change-Id: Id0d6908d906a1e54cdda4f232d572d996d9c556f
Signed-off-by: Patrick Georgi <pgeorgi(a)chromium.org>
---
src/soc/mediatek/mt8173/Kconfig | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/soc/mediatek/mt8173/Kconfig b/src/soc/mediatek/mt8173/Kconfig
index 91a8d4f..ec3481e 100644
--- a/src/soc/mediatek/mt8173/Kconfig
+++ b/src/soc/mediatek/mt8173/Kconfig
@@ -6,6 +6,7 @@ config SOC_MEDIATEK_MT8173
select ARCH_RAMSTAGE_ARMV8_64
select ARCH_ROMSTAGE_ARMV8_64
select ARCH_VERSTAGE_ARMV8_64
+ select ARM64_USE_ARM_TRUSTED_FIRMWARE
select BOOTBLOCK_CONSOLE
select HAVE_UART_SPECIAL
select SPI_ATOMIC_SEQUENCING if SPI_FLASH
the following patch was just integrated into master:
commit 59be62480e2b9f51a66b5da3d552ae47425db9c6
Author: Duncan Laurie <dlaurie(a)chromium.org>
Date: Mon Mar 7 13:21:56 2016 -0800
intel/fsp1.1: Mark graphics init done after SiliconInit phase
If the VBT was provided to the FSP GOP driver then graphics init
will be done as part of SiliconInit step and we can mark that
when it is completed.
This will result in the "oprom" flag being set properly in the
coreboot gpio table and the netboot firmware will have video.
[pg: avoided conflict with Quark that comes without
silicon_init_params.GraphicsConfigPtr]
BUG=chrome-os-partner:50864
BRANCH=glados
TEST=boot image.net.bin on chell and get working graphics
without being setuck in a reboot loop thinking graphics needs
to be started when it already has been.
Change-Id: I0e481b4be57096ed5c60d78e3fa00f3bb2a4eae1
Signed-off-by: Patrick Georgi <pgeorgi(a)chromium.org>
Original-Commit-Id: 089d93c712431d1b5923e844137c558994555e95
Original-Signed-off-by: Duncan Laurie <dlaurie(a)chromium.org>
Original-Reviewed-on: https://chromium-review.googlesource.com/331301
Original-Reviewed-by: Aaron Durbin <adurbin(a)chromium.org>
Original-(cherry picked from commit eeb9d470d8118422feb39ca71106972f2882e240)
Original-Change-Id: Ic59bad27eb9f184ca3eba24643851bfadfe23ab5
Original-Reviewed-on: https://chromium-review.googlesource.com/331355
Reviewed-on: https://review.coreboot.org/13986
Tested-by: build bot (Jenkins)
Reviewed-by: Leroy P Leahy <leroy.p.leahy(a)intel.com>
See https://review.coreboot.org/13986 for details.
-gerrit
Paul Menzel (paulepanter(a)users.sourceforge.net) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/14086
-gerrit
commit 56eab4d43db5a0127d9a19301a5e387a4181526a
Author: Aaron Durbin <adurbin(a)chromium.org>
Date: Sat Mar 12 08:41:34 2016 +0100
util/cbmem: Scale time stamp values correctly
Commit c49014e (timestamp: add tick frequency to exported table)
refactors the code, but forgets to correctly scale the frequency to
megahertz, where the value is read from sysfs, so that printing time
stamp information shows milliseconds instead of microseconds, as can be
seen on the output `cbmem -t` for the ASRock E350M1 below.
```
0:1st timestamp 515
10:start of ramstage 515 (0)
30:device enumeration 515 (0)
40:device configuration 610 (94)
50:device enable 614 (4)
60:device initialization 624 (9)
70:device setup done 639 (14)
75:cbmem post 844 (205)
80:write tables 844 (0)
90:load payload 849 (4)
15:starting LZMA decompress (ignore for x86) 849 (0)
16:finished LZMA decompress (ignore for x86) 869 (20)
99:selfboot jump 869 (0)
Total Time: 350
```
So scale the return value correctly to megahertz, by dividing it with
1000.
```
0:1st timestamp 515,655
10:start of ramstage 515,655 (0)
30:device enumeration 515,663 (7)
40:device configuration 610,620 (94,957)
50:device enable 614,680 (4,059)
60:device initialization 624,618 (9,938)
70:device setup done 639,553 (14,934)
75:cbmem post 844,707 (205,154)
80:write tables 844,710 (2)
90:load payload 849,532 (4,821)
15:starting LZMA decompress (ignore for x86) 849,655 (123)
16:finished LZMA decompress (ignore for x86) 869,903 (20,247)
99:selfboot jump 869,922 (19)
Total Time: 354,261
```
Change-Id: Iea032c62487c7946b6194a90268755034c6350df
Signed-off-by: Aaron Durbin <adurbin(a)chromium.org>
Signed-off-by: Paul Menzel <paulepanter(a)users.sourceforge.net>
---
util/cbmem/cbmem.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/util/cbmem/cbmem.c b/util/cbmem/cbmem.c
index 4c563c8..7a6f9d7 100644
--- a/util/cbmem/cbmem.c
+++ b/util/cbmem/cbmem.c
@@ -362,7 +362,7 @@ static int parse_cbtable(u64 address, size_t table_size, uint8_t abort_on_failur
#if defined(linux) && (defined(__i386__) || defined(__x86_64__))
/*
- * read CPU frequency from a sysfs file, return an frequency in Kilohertz as
+ * read CPU frequency from a sysfs file, return an frequency in Megahertz as
* an int or exit on any error.
*/
static unsigned long arch_tick_frequency(void)
@@ -394,7 +394,8 @@ static unsigned long arch_tick_frequency(void)
rv = strtoull(freqs, &endp, 10);
if (*endp == '\0' || *endp == '\n')
- return rv;
+ /* cpuinfo_max_freq is in kHz. Convert it to MHz. */
+ return rv /1000;
fprintf(stderr, "Wrong formatted value ^%s^ read from %s\n",
freqs, freq_file);
exit(1);
Martin Roth (martinroth(a)google.com) just uploaded a new patch set to gerrit, which you can find at https://review.coreboot.org/14085
-gerrit
commit 63c1de1fb1d765e7d04d1462f847253427154883
Author: Martin Roth <martinroth(a)google.com>
Date: Sun Mar 13 13:00:43 2016 -0600
payloads: add iPXE 'payload' build
We already have the ability to add a pxe rom to cbfs, but it needs to be
configured and built separately.
This moves the existing Kconfig options for PXE from device/Kconfig and
the top level Makefile.inc to payloads, and adds the option to download
and build iPXE as part of the coreboot build process.
This configures the serial output of iPXE to match coreboot's serial
port configuration by editing the .h files. iPXE doesn't give any
real build-time method of setting these configuration options.
Change-Id: I3d77b2c6845b7f5f644440f6910c3b4533a0d415
Signed-off-by: Martin Roth <martinroth(a)google.com>
---
.gitignore | 1 +
Makefile.inc | 4 --
payloads/Kconfig | 63 +++++++++++++++++++++++++++++++
payloads/Makefile.inc | 3 +-
payloads/external/Makefile.inc | 28 ++++++++++++++
payloads/external/iPXE/Makefile.inc | 74 +++++++++++++++++++++++++++++++++++++
src/device/Kconfig | 30 ---------------
7 files changed, 168 insertions(+), 35 deletions(-)
diff --git a/.gitignore b/.gitignore
index 7b3797f..14a42c9 100644
--- a/.gitignore
+++ b/.gitignore
@@ -13,6 +13,7 @@ payloads/external/GRUB2/grub2/
payloads/external/SeaBIOS/seabios/
payloads/external/U-Boot/u-boot/
payloads/external/Memtest86Plus/memtest86plus/
+payloads/external/iPXE/ipxe/
util/crossgcc/acpica-unix-*/
util/crossgcc/binutils-*/
util/crossgcc/build-*BINUTILS/
diff --git a/Makefile.inc b/Makefile.inc
index a07f92a..02e4e5e 100644
--- a/Makefile.inc
+++ b/Makefile.inc
@@ -823,10 +823,6 @@ cbfs-files-$(CONFIG_SEABIOS_VGA_COREBOOT) += vgaroms/seavgabios.bin
vgaroms/seavgabios.bin-file := $(CONFIG_PAYLOAD_VGABIOS_FILE)
vgaroms/seavgabios.bin-type := raw
-cbfs-files-$(CONFIG_PXE_ROM) += pci$(CONFIG_PXE_ROM_ID).rom
-pci$(CONFIG_PXE_ROM_ID).rom-file := $(CONFIG_PXE_ROM_FILE)
-pci$(CONFIG_PXE_ROM_ID).rom-type := raw
-
cbfs-files-$(CONFIG_INCLUDE_CONFIG_FILE) += config
config-file := $(DOTCONFIG):defconfig
config-type := raw
diff --git a/payloads/Kconfig b/payloads/Kconfig
index c7b9e2a..09876d8 100644
--- a/payloads/Kconfig
+++ b/payloads/Kconfig
@@ -78,4 +78,67 @@ config MEMTEST_SECONDARY_PAYLOAD
or any other payload that can load additional payloads.
endmenu # "Secondary Payloads"
+
+choice
+ prompt "Add a PXE ROM"
+ default PXE_ROM
+ depends on ARCH_X86
+ optional
+
+config PXE_ROM
+ bool "Add an existing PXE ROM image"
+ help
+ Select this option if you have a PXE ROM image that you would
+ like to add to your ROM.
+
+config BUILD_IPXE
+ bool "Build and add an iPXE ROM"
+ help
+ Select this option to fetch and build a ROM from the iPXE project.
+
+endchoice
+
+choice
+ prompt "iPXE version"
+ default IPXE_STABLE
+ depends on BUILD_IPXE
+
+config IPXE_STABLE
+ bool "2016.2"
+ help
+ iPXE uses a rolling release, with no stable version, for
+ reproducibility, use the last commit of each month as the
+ 'stable' version.
+ This is iPXE from the end of February 26, 2016.
+
+config IPXE_MASTER
+ bool "master"
+ help
+ Newest iPXE version.
+
+endchoice
+
+config PXE_ROM_FILE
+ string "PXE ROM filename"
+ depends on PXE_ROM
+ default "pxe.rom"
+ help
+ The path and filename of the file to use as PXE ROM.
+
+config PXE_ROM_ID
+ string "network card PCI IDs"
+ depends on PXE_ROM || BUILD_IPXE
+ default "10ec,8168"
+ help
+ The comma-separated PCI vendor and device ID that would associate
+ your PXE ROM to your network card.
+
+ Example: 10ec,8168
+
+ In the above example 10ec is the PCI vendor ID (in hex, but without
+ the "0x" prefix) and 8168 specifies the PCI device ID of the
+ network card (also in hex, without "0x" prefix).
+
+ Under GNU/Linux you can run `lspci -nn` to list the IDs of your PCI devices.
+
endmenu
diff --git a/payloads/Makefile.inc b/payloads/Makefile.inc
index 4269715..224238a 100644
--- a/payloads/Makefile.inc
+++ b/payloads/Makefile.inc
@@ -26,7 +26,7 @@ clean-payloads:
$(MAKE) -C payloads/external/SeaBIOS -f Makefile.inc clean
$(MAKE) -C payloads/external/U-Boot -f Makefile.inc clean
$(MAKE) -C payloads/external/Memtest86Plus -f Makefile.inc clean
-
+ $(MAKE) -C payloads/external/iPXE -f Makefile.inc clean
distclean-payloads:
$(MAKE) -C payloads/coreinfo distclean
@@ -34,5 +34,6 @@ distclean-payloads:
$(MAKE) -C payloads/external/SeaBIOS -f Makefile.inc distclean
$(MAKE) -C payloads/external/U-Boot -f Makefile.inc distclean
$(MAKE) -C payloads/external/Memtest86Plus -f Makefile.inc distclean
+ $(MAKE) -C payloads/external/iPXE -f Makefile.inc distclean
.phony: clean-payloads distclean-payloads
diff --git a/payloads/external/Makefile.inc b/payloads/external/Makefile.inc
index 3c20e13..ef843e4 100644
--- a/payloads/external/Makefile.inc
+++ b/payloads/external/Makefile.inc
@@ -103,3 +103,31 @@ payloads/external/Memtest86Plus/memtest86plus/memtest: $(top)/$(DOTCONFIG)
AS="$(AS_x86_32)" \
$(MEMTEST_SERIAL_OPTIONS) \
MFLAGS= MAKEFLAGS=
+
+PXE_ROM_PCI_ID:=$(subst $(comma),,$(CONFIG_PXE_ROM_ID))
+
+ifeq ($(CONFIG_PXE_ROM),y)
+PXE_ROM_FILE:=$(CONFIG_PXE_ROM_FILE)
+endif
+ifeq ($(CONFIG_BUILD_IPXE),y)
+PXE_ROM_FILE:=payloads/external/iPXE/ipxe/ipxe.rom
+endif
+
+ifeq ($(CONFIG_CONSOLE_SERIAL)$(CONFIG_DRIVERS_UART_8250IO),yy)
+IPXE_UART=COM$(call int-add,$(CONFIG_UART_FOR_CONSOLE) 1)
+endif
+
+cbfs-files-$(CONFIG_PXE_ROM)$(CONFIG_BUILD_IPXE) += pci$(CONFIG_PXE_ROM_ID).rom
+pci$(CONFIG_PXE_ROM_ID).rom-file := $(PXE_ROM_FILE)
+pci$(CONFIG_PXE_ROM_ID).rom-type := raw
+
+payloads/external/iPXE/ipxe/ipxe.rom ipxe: $(top)/$(DOTCONFIG)
+ $(MAKE) -C payloads/external/iPXE -f Makefile.inc all \
+ CROSS_COMPILE="$(CROSS_COMPILE_$(ARCH-ramstage-y))" \
+ PXE_ROM_PCI_ID=$(PXE_ROM_PCI_ID) \
+ CONFIG_IPXE_MASTER=$(CONFIG_IPXE_MASTER) \
+ CONFIG_IPXE_STABLE=$(CONFIG_IPXE_STABLE) \
+ CONSOLE_SERIAL=$(CONFIG_CONSOLE_SERIAL)$(CONFIG_DRIVERS_UART_8250IO) \
+ IPXE_UART=$(IPXE_UART) \
+ CONFIG_TTYS0_BAUD=$(CONFIG_TTYS0_BAUD)
+ MFLAGS= MAKEFLAGS=
diff --git a/payloads/external/iPXE/Makefile.inc b/payloads/external/iPXE/Makefile.inc
new file mode 100644
index 0000000..f01087c
--- /dev/null
+++ b/payloads/external/iPXE/Makefile.inc
@@ -0,0 +1,74 @@
+##
+## This file is part of the coreboot project.
+##
+## Copyright (C) 2016 Google Inc.
+##
+## 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; version 2 of the License.
+##
+## This program is distributed in the hope that it will be useful,
+## but WITHOUT ANY WARRANTY; without even the implied warranty of
+## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+## GNU General Public License for more details.
+##
+
+# 2016.2 - Last commit of February 2016
+# When updating, change here and in payloads/external/Kconfig
+STABLE_COMMIT_ID=99b5216b1c71dba22dab734e0945887525493cde
+
+TAG-$(CONFIG_IPXE_MASTER)=origin/master
+TAG-$(CONFIG_IPXE_STABLE)=$(STABLE_COMMIT_ID)
+
+project_name=iPXE
+project_dir=ipxe
+project_git_repo=git://git.ipxe.org/ipxe.git
+
+all: build
+
+$(project_dir):
+ echo " Cloning $(project_name) from Git"
+ git clone $(project_git_repo) $(project_dir)
+
+fetch: $(project_dir)
+ cd $(project_dir); \
+ git show $(TAG-y) >/dev/null 2>&1 ; \
+ if [ $$? -ne 0 ] || [ "$(TAG-y)" = "origin/master" ]; then \
+ echo " Fetching new commits from the $(project_name) repo"; \
+ git fetch; \
+ fi
+
+checkout: fetch
+ echo " Checking out $(project_name) revision $(TAG-y)"
+ cd $(project_dir); \
+ git checkout master; \
+ git branch -D coreboot 2>/dev/null; \
+ git checkout -b coreboot $(TAG-y)
+
+config: checkout
+ifeq ($(CONSOLE_SERIAL),yy)
+ cp "$(project_dir)/src/config/console.h" "$(project_dir)/src/config/console.h.cb"
+ cp "$(project_dir)/src/config/serial.h" "$(project_dir)/src/config/serial.h.cb"
+ sed 's|//#define\s*CONSOLE_SERIAL.*|#define CONSOLE_SERIAL|' "$(project_dir)/src/config/console.h" > "$(project_dir)/src/config/console.h.tmp"
+ mv "$(project_dir)/src/config/console.h.tmp" "$(project_dir)/src/config/console.h"
+ sed 's|#define\s*COMCONSOLE.*|#define COMCONSOLE $(IPXE_UART)|' "$(project_dir)/src/config/serial.h" > "$(project_dir)/src/config/serial.h.tmp"
+ sed 's|#define\s*COMSPEED.*|#define COMSPEED $(CONFIG_TTYS0_BAUD)|' "$(project_dir)/src/config/serial.h.tmp" > "$(project_dir)/src/config/serial.h"
+endif
+
+build: config
+ echo " MAKE $(project_name) $(TAG-y)"
+ $(MAKE) -C $(project_dir)/src bin/$(PXE_ROM_PCI_ID).rom
+ cp $(project_dir)/src/bin/$(PXE_ROM_PCI_ID).rom $(project_dir)/ipxe.rom
+ifeq ($(CONSOLE_SERIAL),yy)
+ cp "$(project_dir)/src/config/console.h.cb" "$(project_dir)/src/config/console.h"
+ cp "$(project_dir)/src/config/serial.h.cb" "$(project_dir)/src/config/serial.h"
+endif
+
+clean:
+ test -d $(project_dir) && $(MAKE) -C $(project_dir)/src veryclean || exit 0
+ rm -f $(project_dir)/ipxe.rom
+
+distclean:
+ rm -rf $(project_dir)
+
+.PHONY: all fetch config build clean distclean
diff --git a/src/device/Kconfig b/src/device/Kconfig
index d156d36..b1f8dae 100644
--- a/src/device/Kconfig
+++ b/src/device/Kconfig
@@ -351,36 +351,6 @@ config MBI_FILE
help
The path and filename of the file to use as VGA BIOS.
-config PXE_ROM
- bool "Add a PXE ROM image"
- depends on ARCH_X86
- help
- Select this option if you have a PXE ROM image that you would
- like to add to your ROM.
-
-config PXE_ROM_FILE
- string "PXE ROM filename"
- depends on PXE_ROM
- default "pxe.rom"
- help
- The path and filename of the file to use as PXE ROM.
-
-config PXE_ROM_ID
- string "network card PCI IDs"
- depends on PXE_ROM
- default "10ec,8168"
- help
- The comma-separated PCI vendor and device ID that would associate
- your PXE ROM to your network card.
-
- Example: 10ec,8168
-
- In the above example 10ec is the PCI vendor ID (in hex, but without
- the "0x" prefix) and 8168 specifies the PCI device ID of the
- network card (also in hex, without "0x" prefix).
-
- Under GNU/Linux you can run `lspci -nn` to list the IDs of your PCI devices.
-
config SOFTWARE_I2C
bool "Enable I2C controller emulation in software"
default n