summaryrefslogtreecommitdiff
path: root/src/soc/intel/common
diff options
context:
space:
mode:
authorArthur Heymans <arthur@aheymans.xyz>2024-06-06 11:41:08 +0200
committerNico Huber <nico.h@gmx.de>2024-06-07 11:15:00 +0000
commit2993553de6cc849a938e7ccaba5bb929ea36a804 (patch)
treeb8d4874744fbce44aedb1896e749845bcdd754e4 /src/soc/intel/common
parentca9f94854176808651d075b968aa7551cf4d2ae6 (diff)
soc/intel/common/uart: Drop chip in favor of devicetree ops
It is now possible to hook up device ops directly to devices in devicetree which removes the need for a fake chip. This also fixes Hermes booting as the PCI ops were incorrectly hooked up to a dummy device. The intel uart driver was requesting a resource from the generic device and died since it does not exist: [EMERG] GENERIC: 0.0 missing resource: 10 This was broken in commit b9165199c32a (mb/prodrive/hermes: Rework UART devicetree entry). Change-Id: I3b32d1cc52afaed2a321eea5815f2957fe730f79 Signed-off-by: Arthur Heymans <arthur@aheymans.xyz> Reviewed-on: https://review.coreboot.org/c/coreboot/+/82940 Reviewed-by: Christian Walter <christian.walter@9elements.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Angel Pons <th3fanbus@gmail.com> Reviewed-by: Nico Huber <nico.h@gmx.de>
Diffstat (limited to 'src/soc/intel/common')
-rw-r--r--src/soc/intel/common/block/uart/chip.h15
-rw-r--r--src/soc/intel/common/block/uart/uart.c14
2 files changed, 0 insertions, 29 deletions
diff --git a/src/soc/intel/common/block/uart/chip.h b/src/soc/intel/common/block/uart/chip.h
deleted file mode 100644
index 5981126fa9..0000000000
--- a/src/soc/intel/common/block/uart/chip.h
+++ /dev/null
@@ -1,15 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0-only */
-
-#include <stdint.h>
-/* Indirect include for static.c: */
-#include <device/pci_ids.h>
-
-#ifndef _SOC_INTEL_COMMON_BLOCK_UART_CHIP_H_
-#define _SOC_INTEL_COMMON_BLOCK_UART_CHIP_H_
-
-struct soc_intel_common_block_uart_config {
- /* The Device ID read from config space at offset[2:4] when not hidden */
- u16 devid;
-};
-
-#endif /* _SOC_INTEL_COMMON_BLOCK_UART_CHIP_H_ */
diff --git a/src/soc/intel/common/block/uart/uart.c b/src/soc/intel/common/block/uart/uart.c
index e52bb0f62e..e454f7e91a 100644
--- a/src/soc/intel/common/block/uart/uart.c
+++ b/src/soc/intel/common/block/uart/uart.c
@@ -14,7 +14,6 @@
#include <soc/pci_devs.h>
#include <soc/iomap.h>
#include <soc/nvs.h>
-#include "chip.h"
#define UART_PCI_ENABLE (PCI_COMMAND_MEMORY | PCI_COMMAND_MASTER)
@@ -430,17 +429,4 @@ static const struct pci_driver pch_uart __pci_driver = {
.vendor = PCI_VID_INTEL,
.devices = pci_device_ids,
};
-
-static void uart_enable(struct device *dev)
-{
- struct soc_intel_common_block_uart_config *conf = dev->chip_info;
- dev->ops = &uart_ops;
- dev->device = conf ? conf->devid : 0;
-}
-
-struct chip_operations soc_intel_common_block_uart_ops = {
- .name = "LPSS UART in ACPI mode",
- .enable_dev = uart_enable
-};
-
#endif /* ENV_RAMSTAGE */