Christoph Pomaska has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/35912 )
Change subject: [WIP] Documentation/basics: Add Super I/O section
......................................................................
[WIP] Documentation/basics: Add Super I/O section
This file contains and is supposed to contain basic information about
what a Super I/O is and what it does.
Change-Id: If288dcd79c4622a712868229b18f8b38e71d4af9
Signed-off-by: Christoph Pomaska <c.pomaska(a)hosting.de>
---
A Documentation/basics/superio.md
1 file changed, 29 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/12/35912/1
diff --git a/Documentation/basics/superio.md b/Documentation/basics/superio.md
new file mode 100644
index 0000000..5f17a4c
--- /dev/null
+++ b/Documentation/basics/superio.md
@@ -0,0 +1,29 @@
+# What is super I/O?
+
+Super I/O chips are a component that exist in PCs since the 1980s
+and are usually connected via ISA/LPC. They are specific to x86 based platforms.
+
+Super I/O components have a wide range of tasks, from which the most widely known are:
+- serial (e.g. RS232)
+- PS/2
+- parallel (IEEE 1284)
+- floppy-disk-controller
+- PECI (Platform Enviroment Controller Interface)
+
+They can also act as an EC (Embedded Controller) managing things like:
+- fancontrol
+- battery charge controlling (on laptops)
+- LED control
+
+BMC (Board Management Controller) and manage IPMI (Intelligent Platform Management Interface).
+Very most x86 mainboards have at least one Super I/O chip.
+
+In case of the Supermicro [X10SLM+-F](https://www.supermicro.com/en/products/motherboard/x10slm+-f) there is a Nuvoton NCT6776 and an Aspeed AST2400 used.
+The Nuvoton chip manages serial, PS/2 and hardware monitoring while the Aspeed chip manages the BMC functionality.
+As another example does the Supermicro X11SSH-TF board solely use the same Aspeed chip as BMC, but also for serial.
+
+
+## Super I/O and coreboot
+The registers that need to be configured to make a Super I/O work are mostly vendor-specific, but sometimes also chip-specific.
+coreboot ships a tool called [superiotool](../util.md) that reads out the most commonly used registers to determine which chip could be used on the board.
+Conveniently it also prints out the registers and their contents in case a superio is detected.
--
To view, visit https://review.coreboot.org/c/coreboot/+/35912
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: If288dcd79c4622a712868229b18f8b38e71d4af9
Gerrit-Change-Number: 35912
Gerrit-PatchSet: 1
Gerrit-Owner: Christoph Pomaska <github(a)aufmachen.jetzt>
Gerrit-MessageType: newchange
Daniel Maslowski has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/36010 )
Change subject: Documentation: add Gigabyte P34G v2
......................................................................
Documentation: add Gigabyte P34G v2
Change-Id: Ie8025f7bf4e7b40810c97a0b5fa80fd7c41e97eb
Signed-off-by: Daniel Maslowski <info(a)orangecms.org>
---
A Documentation/mainboard/gigabyte/p34g-v2.md
A Documentation/mainboard/gigabyte/p34g-v2_tpm_socket_spi_chip.jpg
M Documentation/mainboard/index.md
3 files changed, 89 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/10/36010/1
diff --git a/Documentation/mainboard/gigabyte/p34g-v2.md b/Documentation/mainboard/gigabyte/p34g-v2.md
new file mode 100644
index 0000000..4dfcf79
--- /dev/null
+++ b/Documentation/mainboard/gigabyte/p34g-v2.md
@@ -0,0 +1,88 @@
+# Gigabyte P34G v2
+
+This page describes how to run coreboot on the [Gigabyte P34G v2 gaming
+laptop](https://www.gigabyte.com/Laptop/P34G-v2).
+
+Original board name: GA-R3456R
+
+Rebrands:
+- Schenker XMG C404
+
+## Technology
+
+```eval_rst
++------------------+----------------------------------------------+
+| Northbridge | :doc:`../../northbridge/intel/haswell/index` |
++------------------+----------------------------------------------+
+| Southbridge | Lynx Point |
++------------------+----------------------------------------------+
+| CPU | i7-4710HQ |
++------------------+----------------------------------------------+
+| EC / SuperIO | ITE IT8587E |
++------------------+----------------------------------------------+
+| Coprocessor | Intel ME, `me_cleaner` untested |
++------------------+----------------------------------------------+
+| TPM | None, but socket exists (see photo below) |
++------------------+----------------------------------------------+
+```
+
+## Required proprietary blobs
+
+```eval_rst
+Please see :doc:`../../northbridge/intel/haswell/mrc.bin`.
+```
+
+## Flash chip
+
+![SPI chip and TPM location](p34g-v2_tpm_socket_spi_chip.jpg)
+
+```eval_rst
++---------------------+------------+
+| Type | Value |
++=====================+============+
+| Socketed flash | No |
++---------------------+------------+
+| Model | MX25L6406E |
++---------------------+------------+
+| Size | 8 MiB |
++---------------------+------------+
+| In circuit flashing | Yes |
++---------------------+------------+
+| Package | SOIC-8 |
++---------------------+------------+
+| Write protection | No |
++---------------------+------------+
+| Internal flashing | Untested |
++---------------------+------------+
+```
+
+## Flash layout
+
+```txt
+00000000:00000fff fd
+00400000:007fffff bios
+00001000:003fffff me
+```
+
+## EC firmware
+
+There is an additional 128KiB EC firmware blob within the BIOS region at
+`0x700000`. The EC has its own internal EPROM though, for which Gigabyte offers
+updates in a bundle with the UEFI firmware updates based on AMI Aptio. The EC
+firmware can be updated via AFU. An unmodified EC firmware version F005 seems
+to work fine with coreboot even without the extra 128KiB part. It could be
+extracted from a firmware update through `dd` etc and reinserted though. Other
+version have not been tested.
+
+## Known issues
+
+- EC / ACPI
+ * no suspend on LID close
+ * eject, sleep, backlight up/down, external screen buttons do not work
+ * Bluetooth LED shows inverted state, does not turn on on first press
+ * battery state can not be queried
+- CPU overheats on high load leading to force poweroff
+
+```eval_rst
+Please also see :doc:`../../northbridge/intel/haswell/known-issues`.
+```
diff --git a/Documentation/mainboard/gigabyte/p34g-v2_tpm_socket_spi_chip.jpg b/Documentation/mainboard/gigabyte/p34g-v2_tpm_socket_spi_chip.jpg
new file mode 100644
index 0000000..9835a8a
--- /dev/null
+++ b/Documentation/mainboard/gigabyte/p34g-v2_tpm_socket_spi_chip.jpg
Binary files differ
diff --git a/Documentation/mainboard/index.md b/Documentation/mainboard/index.md
index 83189757..f0f8f8e 100644
--- a/Documentation/mainboard/index.md
+++ b/Documentation/mainboard/index.md
@@ -40,6 +40,7 @@
## Gigabyte
- [GA-H61M-S2PV](gigabyte/ga-h61m-s2pv.md)
+- [P34G v2](gigabyte/p34g-v2.md)
## Google
--
To view, visit https://review.coreboot.org/c/coreboot/+/36010
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: Ie8025f7bf4e7b40810c97a0b5fa80fd7c41e97eb
Gerrit-Change-Number: 36010
Gerrit-PatchSet: 1
Gerrit-Owner: Daniel Maslowski <info(a)orangecms.org>
Gerrit-MessageType: newchange
Daniel Maslowski has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/36071 )
Change subject: superio: IT8587E (WIP)
......................................................................
superio: IT8587E (WIP)
Change-Id: I1e541daa2b3d48a4f5a0e7b7fa88a2c2f8a1b0c5
Signed-off-by: Daniel Maslowski <info(a)orangecms.org>
---
A src/superio/ite/it8587e/Kconfig
A src/superio/ite/it8587e/Makefile.inc
A src/superio/ite/it8587e/it8587e.h
A src/superio/ite/it8587e/superio.c
4 files changed, 137 insertions(+), 0 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/71/36071/1
diff --git a/src/superio/ite/it8587e/Kconfig b/src/superio/ite/it8587e/Kconfig
new file mode 100644
index 0000000..438bd3e
--- /dev/null
+++ b/src/superio/ite/it8587e/Kconfig
@@ -0,0 +1,16 @@
+##
+## This file is part of the coreboot project.
+##
+## 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.
+##
+
+config SUPERIO_ITE_IT8587E
+ bool
+ select SUPERIO_ITE_COMMON_PRE_RAM
diff --git a/src/superio/ite/it8587e/Makefile.inc b/src/superio/ite/it8587e/Makefile.inc
new file mode 100644
index 0000000..dbde0b7
--- /dev/null
+++ b/src/superio/ite/it8587e/Makefile.inc
@@ -0,0 +1,15 @@
+##
+## This file is part of the coreboot project.
+##
+## 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.
+##
+## 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.
+##
+
+ramstage-$(CONFIG_SUPERIO_ITE_IT8587E) += superio.c
diff --git a/src/superio/ite/it8587e/it8587e.h b/src/superio/ite/it8587e/it8587e.h
new file mode 100644
index 0000000..eab3527
--- /dev/null
+++ b/src/superio/ite/it8587e/it8587e.h
@@ -0,0 +1,34 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * 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.
+ *
+ * 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.
+ */
+
+#ifndef SUPERIO_ITE_IT8587E_H
+#define SUPERIO_ITE_IT8587E_H
+
+#define IT8528E_SP1 0x01 /* Com1 */
+#define IT8528E_SP2 0x02 /* Com2 */
+#define IT8587E_SWUC 0x04 /* System Wake-Up */
+#define IT8587E_KBCM 0x05 /* PS/2 mouse */
+#define IT8587E_KBCK 0x06 /* PS/2 keyboard */
+#define IT8587E_SMFI 0x0f /* Shared Memory/Flash Interface */
+#define IT8587E_RTCT 0x10 /* RTC-like Timer */
+#define IT8587E_PMC1 0x11 /* Power Management Channel 1 */
+#define IT8587E_PMC2 0x12 /* Power Management Channel 2 */
+#define IT8587E_SSPI 0x13 /* Serial Periphial Interface */
+#define IT8587E_PECI 0x14 /* Platform EC Interface */
+#define IT8587E_PMC3 0x17 /* Power Management Channel 3 */
+#define IT8587E_PMC4 0x18 /* Power Management Channel 4 */
+#define IT8587E_PMC5 0x19 /* Power Management Channel 5 */
+
+
+#endif /* SUPERIO_ITE_IT8587E_H */
diff --git a/src/superio/ite/it8587e/superio.c b/src/superio/ite/it8587e/superio.c
new file mode 100644
index 0000000..cdb97e6
--- /dev/null
+++ b/src/superio/ite/it8587e/superio.c
@@ -0,0 +1,72 @@
+/*
+ * This file is part of the coreboot project.
+ *
+ * Copyright (C) 2006 Uwe Hermann <uwe(a)hermann-uwe.de>
+ * Copyright (C) 2007 Philipp Degler <pdegler(a)rumms.uni-mannheim.de>
+ * Copyright (C) 2017 Gergely Kiss <mail.gery(a)gmail.com>
+ * Copyright (C) 2019 9Elements GmbH <patrick.rudolph(a)9elements.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.
+ *
+ * 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.
+ */
+
+#include <device/device.h>
+#include <device/pnp.h>
+#include <stdlib.h>
+#include <superio/conf_mode.h>
+
+#include "it8587e.h"
+
+static void it8587e_init(struct device *dev)
+{
+}
+
+static struct device_operations ops = {
+ .read_resources = pnp_read_resources,
+ .set_resources = pnp_set_resources,
+ .enable_resources = pnp_enable_resources,
+ .enable = pnp_alt_enable,
+ .init = it8587e_init,
+ .ops_pnp_mode = &pnp_conf_mode_870155_aa,
+};
+
+static struct pnp_info pnp_dev_info[] = {
+ { NULL, IT8587E_SP1, PNP_IO0 | PNP_IRQ0, 0x0ff8, },
+ { NULL, IT8587E_SP2, PNP_IO0 | PNP_IRQ0, 0x0ff8, },
+ { NULL, IT8587E_SWUC, PNP_IO0 | PNP_IRQ0, 0xfff0, },
+ /* Documentation: Unused */
+ { NULL, IT8587E_KBCM, PNP_IRQ0, },
+ /* Documentation: Program io0 = 0x60 and io1 = 0x64 */
+ { NULL, IT8587E_KBCK, PNP_IO0 | PNP_IO1 | PNP_IRQ0, 0x07ff, 0x07ff, },
+ { NULL, IT8587E_SMFI, PNP_IO0 | PNP_IRQ0, 0xfff0, },
+ /* Documentation: Program io0 = 0x70-0x73 */
+ { NULL, IT8587E_RTCT, PNP_IO0 | PNP_IO1 | PNP_IO2 | PNP_IO3 | PNP_IRQ0,
+ 0xfffe, 0xfffe, 0xfffe, 0xfffe},
+ /* Documentation: Program io0 = 0x62 and io1 = 0x66 */
+ { NULL, IT8587E_PMC1, PNP_IO0 | PNP_IO1 | PNP_IRQ0, 0x07ff, 0x07ff },
+ /* Documentation: Program io0 = 0x68 and io1 = 0x6c */
+ { NULL, IT8587E_PMC2, PNP_IO0 | PNP_IO1 | PNP_IRQ0, 0x07fc, 0x07fc },
+ /* Documentation: Program io0 = 0x6a and io1 = 0x6e */
+ { NULL, IT8587E_PMC3, PNP_IO0 | PNP_IO1 | PNP_IRQ0, 0x07ff, 0x07ff },
+ { NULL, IT8587E_PMC4, PNP_IO0 | PNP_IO1 | PNP_IRQ0, 0x07ff, 0x07ff },
+ { NULL, IT8587E_PMC5, PNP_IO0 | PNP_IO1 | PNP_IRQ0, 0x07ff, 0x07ff },
+ { NULL, IT8587E_SSPI, PNP_IO0 | PNP_IRQ0, 0xfff8 },
+ { NULL, IT8528E_PECI, PNP_IO0, 0xfff8 },
+};
+
+static void enable_dev(struct device *dev)
+{
+ pnp_enable_devices(dev, &ops, ARRAY_SIZE(pnp_dev_info), pnp_dev_info);
+}
+
+struct chip_operations superio_ite_it8587e_ops = {
+ CHIP_NAME("ITE IT8587E Super I/O")
+ .enable_dev = enable_dev,
+};
--
To view, visit https://review.coreboot.org/c/coreboot/+/36071
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I1e541daa2b3d48a4f5a0e7b7fa88a2c2f8a1b0c5
Gerrit-Change-Number: 36071
Gerrit-PatchSet: 1
Gerrit-Owner: Daniel Maslowski <info(a)orangecms.org>
Gerrit-Reviewer: Daniel Maslowski <info(a)orangecms.org>
Gerrit-Reviewer: Felix Held <felix-coreboot(a)felixheld.de>
Gerrit-Reviewer: Martin Roth <martinroth(a)google.com>
Gerrit-Reviewer: Patrick Georgi <pgeorgi(a)google.com>
Gerrit-MessageType: newchange
Arthur Heymans has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/36977 )
Change subject: cpu/x86/smm: Remove usused Kconfig symbol
......................................................................
cpu/x86/smm: Remove usused Kconfig symbol
These platforms now use parallel mp.
Change-Id: I73527a7feb6151d765295d6449262a2852b30177
Signed-off-by: Arthur Heymans <arthur(a)aheymans.xyz>
---
M src/cpu/x86/Kconfig
M src/cpu/x86/smm/smmhandler.S
2 files changed, 0 insertions(+), 37 deletions(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/77/36977/1
diff --git a/src/cpu/x86/Kconfig b/src/cpu/x86/Kconfig
index 85ebd83..5004cfd 100644
--- a/src/cpu/x86/Kconfig
+++ b/src/cpu/x86/Kconfig
@@ -137,13 +137,6 @@
endif
-config SMM_LAPIC_REMAP_MITIGATION
- bool
- default y if NORTHBRIDGE_INTEL_I945
- default y if NORTHBRIDGE_INTEL_GM45
- default y if NORTHBRIDGE_INTEL_NEHALEM
- default n
-
config SERIALIZED_SMM_INITIALIZATION
bool
default n
diff --git a/src/cpu/x86/smm/smmhandler.S b/src/cpu/x86/smm/smmhandler.S
index a2be7f2..6e8941e 100644
--- a/src/cpu/x86/smm/smmhandler.S
+++ b/src/cpu/x86/smm/smmhandler.S
@@ -75,36 +75,6 @@
#endif
.global smm_handler_start
smm_handler_start:
-#if CONFIG(SMM_LAPIC_REMAP_MITIGATION)
- /* Check if the LAPIC register block overlaps with SMM.
- * This block needs to work without data accesses because they
- * may be routed into the LAPIC register block.
- * Code accesses, on the other hand, are never routed to LAPIC,
- * which is what makes this work in the first place.
- */
- mov $LAPIC_BASE_MSR, %ecx
- rdmsr
- and $(~0xfff), %eax
- sub $(SMM_START), %eax
- cmp $(SMM_END - SMM_START), %eax
- ja untampered_lapic
-1:
- /* emit "Crash" on serial */
- mov $(CONFIG_TTYS0_BASE), %dx
- mov $'C', %al
- out %al, (%dx)
- mov $'r', %al
- out %al, (%dx)
- mov $'a', %al
- out %al, (%dx)
- mov $'s', %al
- out %al, (%dx)
- mov $'h', %al
- out %al, (%dx)
- /* now crash for real */
- ud2
-untampered_lapic:
-#endif
movw $(smm_gdtptr16 - smm_handler_start + SMM_HANDLER_OFFSET), %bx
lgdtl %cs:(%bx)
--
To view, visit https://review.coreboot.org/c/coreboot/+/36977
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I73527a7feb6151d765295d6449262a2852b30177
Gerrit-Change-Number: 36977
Gerrit-PatchSet: 1
Gerrit-Owner: Arthur Heymans <arthur(a)aheymans.xyz>
Gerrit-MessageType: newchange
Xiang Wang has uploaded this change for review. ( https://review.coreboot.org/c/coreboot/+/37130 )
Change subject: arch/riscv: Add error detection for supports_extension
......................................................................
arch/riscv: Add error detection for supports_extension
Change-Id: I5df3d82b9a9b4968beea6040b86628b58fd8a45d
Signed-off-by: Xiang Wang <merle(a)hardenedlinux.org>
---
M src/arch/riscv/include/arch/cpu.h
1 file changed, 8 insertions(+), 1 deletion(-)
git pull ssh://review.coreboot.org:29418/coreboot refs/changes/30/37130/1
diff --git a/src/arch/riscv/include/arch/cpu.h b/src/arch/riscv/include/arch/cpu.h
index 72a8a69..dd70af7 100644
--- a/src/arch/riscv/include/arch/cpu.h
+++ b/src/arch/riscv/include/arch/cpu.h
@@ -49,7 +49,7 @@
* */
int soc_supports_extension(char ext);
-static inline int supports_extension(char ext)
+static inline int supports_extension_imp(char ext)
{
uintptr_t isa = read_csr(misa);
if (isa)
@@ -58,6 +58,13 @@
return soc_supports_extension(ext);
}
+#define supports_extension(c)\
+({\
+ _Static_assert(((c >= 'A') && (c <= 'Z')),\
+ "The parameter of supports_extension must be [A-Z]");\
+ supports_extension_imp(c);\
+})
+
/* If the SOC does not implement misa, the read misa will be zero.
* Such SOC requires a non-standard mechanism to detect machine XLEN.
* If the soc does not implement misa, implement this function.
--
To view, visit https://review.coreboot.org/c/coreboot/+/37130
To unsubscribe, or for help writing mail filters, visit https://review.coreboot.org/settings
Gerrit-Project: coreboot
Gerrit-Branch: master
Gerrit-Change-Id: I5df3d82b9a9b4968beea6040b86628b58fd8a45d
Gerrit-Change-Number: 37130
Gerrit-PatchSet: 1
Gerrit-Owner: Xiang Wang <merle(a)hardenedlinux.org>
Gerrit-MessageType: newchange