diff options
author | Felix Held <felix.held@amd.corp-partner.google.com> | 2020-06-18 15:54:43 +0200 |
---|---|---|
committer | Felix Held <felix-coreboot@felixheld.de> | 2020-06-19 16:45:55 +0000 |
commit | 9412b3e9bbc1ff066d0ae5967624b339259a73c1 (patch) | |
tree | 4005822dffa35705b35acd091aa69c49d288b338 /src/soc/amd/picasso/Makefile.inc | |
parent | 02f7471b19c57c01d02343be9c09b4a9ea8c6fb9 (diff) |
soc/amd/picasso/uart: factor out console-related functions
Move uart_platform_base and uart_platform_refclk to their own
compilation unit to avoid preprocessor usage. The newly created
compilation unit is only added to the build when PICASSO_CONSOLE_UART
is selected.
Change-Id: I56911addc8c000a0772156e5166720867cdd26fe
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Reviewed-on: https://review.coreboot.org/c/coreboot/+/42517
Reviewed-by: Raul Rangel <rrangel@chromium.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
Diffstat (limited to 'src/soc/amd/picasso/Makefile.inc')
-rw-r--r-- | src/soc/amd/picasso/Makefile.inc | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/soc/amd/picasso/Makefile.inc b/src/soc/amd/picasso/Makefile.inc index 796f77cb71..39269e9fe2 100644 --- a/src/soc/amd/picasso/Makefile.inc +++ b/src/soc/amd/picasso/Makefile.inc @@ -16,6 +16,7 @@ bootblock-y += aoac.c bootblock-y += southbridge.c bootblock-y += i2c.c bootblock-y += uart.c +bootblock-$(CONFIG_PICASSO_CONSOLE_UART) += uart_console.c bootblock-y += tsc_freq.c bootblock-y += gpio.c bootblock-y += smi_util.c @@ -27,6 +28,7 @@ romstage-y += gpio.c romstage-y += pmutil.c romstage-y += memmap.c romstage-y += uart.c +romstage-$(CONFIG_PICASSO_CONSOLE_UART) += uart_console.c romstage-y += tsc_freq.c romstage-y += aoac.c romstage-y += southbridge.c @@ -41,6 +43,7 @@ verstage-y += pmutil.c verstage-y += config.c verstage-y += aoac.c verstage-y += uart.c +verstage-$(CONFIG_PICASSO_CONSOLE_UART) += uart_console.c verstage-y += tsc_freq.c ramstage-y += i2c.c @@ -61,6 +64,7 @@ ramstage-y += memmap.c ramstage-$(CONFIG_HAVE_SMI_HANDLER) += smi.c ramstage-$(CONFIG_HAVE_SMI_HANDLER) += smi_util.c ramstage-y += uart.c +ramstage-$(CONFIG_PICASSO_CONSOLE_UART) += uart_console.c ramstage-y += usb.c ramstage-y += tsc_freq.c ramstage-y += finalize.c @@ -76,7 +80,10 @@ all-y += reset.c smm-y += smihandler.c smm-y += smi_util.c smm-y += tsc_freq.c -smm-$(CONFIG_DEBUG_SMI) += uart.c +ifeq ($(CONFIG_DEBUG_SMI),y) +smm-y += uart.c +smm-$(CONFIG_PICASSO_CONSOLE_UART) += uart_console.c +endif smm-y += gpio.c smm-y += psp.c smm-y += smu.c |