kbuild: Remove uncmd_spl logic

At this point in the conversion there should be no need to have logic to
disable some symbol during the SPL build as all symbols should have an
SPL counterpart.

The main real changes done here are that we now must make proper use of
CONFIG_IS_ENABLED(DM_SERIAL) rather than many of the odd tricks we
developed prior to CONFIG_IS_ENABLED() being available.

Signed-off-by: Tom Rini <trini@konsulko.com>
diff --git a/include/config_uncmd_spl.h b/include/config_uncmd_spl.h
deleted file mode 100644
index a59b9bb..0000000
--- a/include/config_uncmd_spl.h
+++ /dev/null
@@ -1,21 +0,0 @@
-/* SPDX-License-Identifier: GPL-2.0+ */
-/*
- * (C) Copyright 2012
- * Ilya Yanok, ilya.yanok@gmail.com
- */
-
-#ifndef __CONFIG_UNCMD_SPL_H__
-#define __CONFIG_UNCMD_SPL_H__
-
-#ifdef CONFIG_SPL_BUILD
-/* SPL needs only BOOTP + TFTP so undefine other stuff to save space */
-
-#ifndef CONFIG_SPL_DM
-#undef CONFIG_DM_SERIAL
-#undef CONFIG_DM_I2C
-#endif
-
-#undef CONFIG_DM_STDIO
-
-#endif /* CONFIG_SPL_BUILD */
-#endif /* __CONFIG_UNCMD_SPL_H__ */
diff --git a/include/configs/kmcent2.h b/include/configs/kmcent2.h
index 60fea59..e7ae18e 100644
--- a/include/configs/kmcent2.h
+++ b/include/configs/kmcent2.h
@@ -314,7 +314,7 @@
  * shorted - index 1
  * Retain non-DM serial port for debug purposes.
  */
-#if !defined(CONFIG_DM_SERIAL)
+#if !CONFIG_IS_ENABLED(DM_SERIAL)
 #define CFG_SYS_NS16550_CLK		(get_bus_freq(0) / 2)
 #define CFG_SYS_NS16550_COM1	(CFG_SYS_CCSRBAR + 0x11C500)
 #endif
diff --git a/include/configs/mv-common.h b/include/configs/mv-common.h
index fa275d6..3dfcb13 100644
--- a/include/configs/mv-common.h
+++ b/include/configs/mv-common.h
@@ -33,7 +33,7 @@
  * NS16550 Configuration
  */
 #define CFG_SYS_NS16550_CLK		CFG_SYS_TCLK
-#if !defined(CONFIG_DM_SERIAL)
+#if !CONFIG_IS_ENABLED(DM_SERIAL)
 #define CFG_SYS_NS16550_COM1		MV_UART_CONSOLE_BASE
 #endif
 
diff --git a/include/configs/sunxi-common.h b/include/configs/sunxi-common.h
index eae107f..8032abe 100644
--- a/include/configs/sunxi-common.h
+++ b/include/configs/sunxi-common.h
@@ -23,7 +23,7 @@
 #else
 #define CFG_SYS_NS16550_CLK		24000000
 #endif
-#ifndef CONFIG_DM_SERIAL
+#if !CONFIG_IS_ENABLED(DM_SERIAL)
 # define CFG_SYS_NS16550_COM1		SUNXI_UART0_BASE
 # define CFG_SYS_NS16550_COM2		SUNXI_UART1_BASE
 # define CFG_SYS_NS16550_COM3		SUNXI_UART2_BASE
diff --git a/include/configs/ti_omap4_common.h b/include/configs/ti_omap4_common.h
index 49f4263..9e312ac 100644
--- a/include/configs/ti_omap4_common.h
+++ b/include/configs/ti_omap4_common.h
@@ -28,7 +28,7 @@
  * Hardware drivers
  */
 #define CFG_SYS_NS16550_CLK		48000000
-#if defined(CONFIG_SPL_BUILD) || !defined(CONFIG_DM_SERIAL)
+#if !CONFIG_IS_ENABLED(DM_SERIAL)
 #define CFG_SYS_NS16550_COM3		UART3_BASE
 #endif
 
diff --git a/include/configs/x530.h b/include/configs/x530.h
index fddf00d..e1678e7 100644
--- a/include/configs/x530.h
+++ b/include/configs/x530.h
@@ -14,7 +14,7 @@
  * NS16550 Configuration
  */
 #define CFG_SYS_NS16550_CLK		CFG_SYS_TCLK
-#if !defined(CONFIG_DM_SERIAL)
+#if !CONFIG_IS_ENABLED(DM_SERIAL)
 #define CFG_SYS_NS16550_COM1		MV_UART_CONSOLE_BASE
 #endif
 
diff --git a/include/ns16550.h b/include/ns16550.h
index 0ee5c4d..f45fc8c 100644
--- a/include/ns16550.h
+++ b/include/ns16550.h
@@ -26,7 +26,7 @@
 
 #include <linux/types.h>
 
-#if defined(CONFIG_DM_SERIAL) && !defined(CONFIG_SYS_NS16550_REG_SIZE)
+#if CONFIG_IS_ENABLED(DM_SERIAL) && !defined(CONFIG_SYS_NS16550_REG_SIZE)
 /*
  * For driver model we always use one byte per register, and sort out the
  * differences in the driver
@@ -37,10 +37,10 @@
 #ifdef CONFIG_NS16550_DYNAMIC
 #define UART_REG(x)	unsigned char x
 #else
-#if !defined(CONFIG_SYS_NS16550_REG_SIZE) || (CONFIG_SYS_NS16550_REG_SIZE == 0)
-#error "Please define NS16550 registers size."
-#elif defined(CONFIG_SYS_NS16550_MEM32) && !defined(CONFIG_DM_SERIAL)
+#if defined(CONFIG_SYS_NS16550_MEM32) && !CONFIG_IS_ENABLED(DM_SERIAL)
 #define UART_REG(x) u32 x
+#elif !defined(CONFIG_SYS_NS16550_REG_SIZE) || (CONFIG_SYS_NS16550_REG_SIZE == 0)
+#error "Please define NS16550 registers size."
 #elif (CONFIG_SYS_NS16550_REG_SIZE > 0)
 #define UART_REG(x)						   \
 	unsigned char prepad_##x[CONFIG_SYS_NS16550_REG_SIZE - 1]; \
@@ -113,7 +113,7 @@
 	UART_REG(scr);		/* 10*/
 	UART_REG(ssr);		/* 11*/
 #endif
-#ifdef CONFIG_DM_SERIAL
+#if CONFIG_IS_ENABLED(DM_SERIAL)
 	struct ns16550_plat *plat;
 #endif
 };