From: Marcel Ziswiler Date: Mon, 14 Nov 2016 20:40:28 +0000 (+0100) Subject: colibri_pxa270: transition to driver model for serial X-Git-Url: http://git.dujemihanovic.xyz/?a=commitdiff_plain;h=136179bec19f4bc84227cba138214ea392a723ea;p=u-boot.git colibri_pxa270: transition to driver model for serial Add serial platform data to board file. Enable driver model for PXA serial driver. Signed-off-by: Marcel Ziswiler --- diff --git a/board/toradex/colibri_pxa270/colibri_pxa270.c b/board/toradex/colibri_pxa270/colibri_pxa270.c index 3def0a6fd0..2e3e03a152 100644 --- a/board/toradex/colibri_pxa270/colibri_pxa270.c +++ b/board/toradex/colibri_pxa270/colibri_pxa270.c @@ -8,10 +8,13 @@ #include #include -#include #include -#include +#include +#include #include +#include +#include +#include #include #include @@ -105,3 +108,14 @@ int board_mmc_init(bd_t *bis) return 0; } #endif + +static const struct pxa_serial_platdata serial_platdata = { + .base = (struct pxa_uart_regs *)FFUART_BASE, + .port = FFUART_INDEX, + .baudrate = CONFIG_BAUDRATE, +}; + +U_BOOT_DEVICE(pxa_serials) = { + .name = "serial_pxa", + .platdata = &serial_platdata, +}; diff --git a/configs/colibri_pxa270_defconfig b/configs/colibri_pxa270_defconfig index 0b5c20dfed..e0a36f13dd 100644 --- a/configs/colibri_pxa270_defconfig +++ b/configs/colibri_pxa270_defconfig @@ -16,6 +16,8 @@ CONFIG_CMD_DHCP=y CONFIG_CMD_PING=y CONFIG_CMD_EXT2=y CONFIG_CMD_FAT=y +CONFIG_DM=y +CONFIG_DM_SERIAL=y CONFIG_PXA_SERIAL=y CONFIG_USB=y CONFIG_USB_STORAGE=y diff --git a/include/configs/colibri_pxa270.h b/include/configs/colibri_pxa270.h index 39fd94b3de..31eb5e9b9a 100644 --- a/include/configs/colibri_pxa270.h +++ b/include/configs/colibri_pxa270.h @@ -43,8 +43,6 @@ /* * Serial Console Configuration */ -#define CONFIG_FFUART 1 -#define CONFIG_CONS_INDEX 3 #define CONFIG_BAUDRATE 115200 /*