summaryrefslogtreecommitdiff
path: root/src/drivers/uart/Makefile.mk
diff options
context:
space:
mode:
authorMartin Roth <gaumless@gmail.com>2024-01-18 15:33:45 -0700
committerFelix Singer <service+coreboot-gerrit@felixsinger.de>2024-01-24 10:04:33 +0000
commit367fff56faaff6fca27240f481c6c0a40113d68b (patch)
treefd8e4ab82b710b4df37fd194e53608b1e23cc63a /src/drivers/uart/Makefile.mk
parentaf880447028ae532428224097ca171a3e729afd4 (diff)
driver/parade to /driver/wwan: Rename Makefiles from .inc to .mk
The .inc suffix is confusing to various tools as it's not specific to Makefiles. This means that editors don't recognize the files, and don't open them with highlighting and any other specific editor functionality. This issue is also seen in the release notes generation script where Makefiles get renamed before running cloc. Signed-off-by: Martin Roth <gaumless@gmail.com> Change-Id: I8cf3d2e2cd1b6ebe4e941ad64f27698379fef696 Reviewed-on: https://review.coreboot.org/c/coreboot/+/80080 Reviewed-by: Felix Singer <service+coreboot-gerrit@felixsinger.de> Reviewed-by: Maximilian Brune <maximilian.brune@9elements.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/drivers/uart/Makefile.mk')
-rw-r--r--src/drivers/uart/Makefile.mk56
1 files changed, 56 insertions, 0 deletions
diff --git a/src/drivers/uart/Makefile.mk b/src/drivers/uart/Makefile.mk
new file mode 100644
index 0000000000..9fd1fb3998
--- /dev/null
+++ b/src/drivers/uart/Makefile.mk
@@ -0,0 +1,56 @@
+## SPDX-License-Identifier: GPL-2.0-only
+
+ifeq ($(CONFIG_DRIVERS_UART),y)
+
+romstage-y += util.c
+postcar-y += util.c
+ramstage-y += util.c
+bootblock-y += util.c
+verstage-y += util.c
+smm-$(CONFIG_DEBUG_SMI) += util.c
+
+# Add the driver, only one can be enabled. The driver files may
+# be located in the soc/ or cpu/ directories instead of here.
+
+ifeq ($(CONFIG_DRIVERS_UART_8250IO),y)
+bootblock-y += uart8250io.c
+verstage-y += uart8250io.c
+romstage-y += uart8250io.c
+postcar-y += uart8250io.c
+ramstage-y += uart8250io.c
+smm-$(CONFIG_DEBUG_SMI) += uart8250io.c
+endif
+
+ifeq ($(CONFIG_DRIVERS_UART_8250MEM),y)
+bootblock-y += uart8250mem.c
+verstage-y += uart8250mem.c
+romstage-y += uart8250mem.c
+postcar-y += uart8250mem.c
+ramstage-y += uart8250mem.c
+smm-$(CONFIG_DEBUG_SMI) += uart8250mem.c
+endif
+
+ifeq ($(CONFIG_DRIVERS_UART_OXPCIE),y)
+bootblock-y += oxpcie_early.c
+verstage-y += oxpcie_early.c
+romstage-y += oxpcie_early.c
+postcar-y += oxpcie_early.c
+ramstage-y += oxpcie_early.c oxpcie.c
+endif
+
+ifeq ($(CONFIG_DRIVERS_UART_PL011),y)
+bootblock-$(CONFIG_BOOTBLOCK_CONSOLE) += pl011.c
+romstage-y += pl011.c
+postcar-y += pl011.c
+ramstage-y += pl011.c
+verstage-y += pl011.c
+endif
+
+ifeq ($(CONFIG_DRIVERS_UART_SIFIVE),y)
+bootblock-$(CONFIG_BOOTBLOCK_CONSOLE) += sifive.c
+romstage-y += sifive.c
+postcar-y += sifive.c
+ramstage-y += sifive.c
+endif
+
+endif