Re: [U-Boot] [PATCH v3 1/3] armv8/ls1043aqds: Select lpuart pins of various muxes
Hi Wenbin, On Thu, Jan 21, 2016 at 2:32 PM, Wenbin Songwrote: > From: Shaohui Xie > > Set Board Configuration Register to select the lpuart pins of various > muxes. > > Signed-off-by: Shaohui Xie > Signed-off-by: Mingkai Hu > --- Please always include a changelog when you do new version so that other people know what's changed. > board/freescale/ls1043aqds/ls1043aqds.c | 15 +++ > 1 file changed, 15 insertions(+) > > diff --git a/board/freescale/ls1043aqds/ls1043aqds.c > b/board/freescale/ls1043aqds/ls1043aqds.c > index d6696ca..67f4c4b 100644 > --- a/board/freescale/ls1043aqds/ls1043aqds.c > +++ b/board/freescale/ls1043aqds/ls1043aqds.c > @@ -40,6 +40,9 @@ enum { > #define CFG_SD_MUX3_MUX4 0x1 /* MUX4 */ > #define CFG_SD_MUX4_SLOT3 0x0 /* SLOT3 TX/RX1 */ > #define CFG_SD_MUX4_SLOT1 0x1 /* SLOT1 TX/RX3 */ > +#define CFG_UART_MUX_MASK 0x6 > +#define CFG_UART_MUX_SHIFT 1 > +#define CFG_LPUART_EN 0x1 > > int checkboard(void) > { > @@ -218,7 +221,19 @@ void board_retimer_init(void) > > int board_early_init_f(void) > { > +#ifdef CONFIG_LPUART > + u8 uart; > +#endif > fsl_lsch2_early_init_f(); > +#ifdef CONFIG_LPUART > + nits: this blank line is not needed > +/* We use lpuart1 as system console. */ nits: ending period is not needed > + > + uart = QIXIS_READ(brdcfg[14]); > + uart &= ~CFG_UART_MUX_MASK; > + uart |= CFG_LPUART_EN << CFG_UART_MUX_SHIFT; > + QIXIS_WRITE(brdcfg[14], uart); > +#endif > > return 0; > } > -- Other than that, Reviewed-by: Bin Meng Regards, Bin ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
Re: [U-Boot] [PATCH v3 1/3] armv8/ls1043aqds: Select lpuart pins of various muxes
Hi Wenbin, On Thu, Jan 21, 2016 at 4:35 PM, Bin Mengwrote: > Hi Wenbin, > > On Thu, Jan 21, 2016 at 2:32 PM, Wenbin Song wrote: >> From: Shaohui Xie >> >> Set Board Configuration Register to select the lpuart pins of various >> muxes. >> >> Signed-off-by: Shaohui Xie >> Signed-off-by: Mingkai Hu >> --- > > Please always include a changelog when you do new version so that > other people know what's changed. > >> board/freescale/ls1043aqds/ls1043aqds.c | 15 +++ >> 1 file changed, 15 insertions(+) >> >> diff --git a/board/freescale/ls1043aqds/ls1043aqds.c >> b/board/freescale/ls1043aqds/ls1043aqds.c >> index d6696ca..67f4c4b 100644 >> --- a/board/freescale/ls1043aqds/ls1043aqds.c >> +++ b/board/freescale/ls1043aqds/ls1043aqds.c >> @@ -40,6 +40,9 @@ enum { >> #define CFG_SD_MUX3_MUX4 0x1 /* MUX4 */ >> #define CFG_SD_MUX4_SLOT3 0x0 /* SLOT3 TX/RX1 */ >> #define CFG_SD_MUX4_SLOT1 0x1 /* SLOT1 TX/RX3 */ >> +#define CFG_UART_MUX_MASK 0x6 >> +#define CFG_UART_MUX_SHIFT 1 >> +#define CFG_LPUART_EN 0x1 >> >> int checkboard(void) >> { >> @@ -218,7 +221,19 @@ void board_retimer_init(void) >> >> int board_early_init_f(void) >> { >> +#ifdef CONFIG_LPUART >> + u8 uart; >> +#endif >> fsl_lsch2_early_init_f(); >> +#ifdef CONFIG_LPUART >> + > > nits: this blank line is not needed > >> +/* We use lpuart1 as system console. */ One more question: in your patch 3, you listed lpuart0 as the /chosen node, but here the comments says lpuart1. Which one is correct? > > nits: ending period is not needed > >> + >> + uart = QIXIS_READ(brdcfg[14]); >> + uart &= ~CFG_UART_MUX_MASK; >> + uart |= CFG_LPUART_EN << CFG_UART_MUX_SHIFT; >> + QIXIS_WRITE(brdcfg[14], uart); >> +#endif >> >> return 0; >> } >> -- > > Other than that, > Reviewed-by: Bin Meng > > Regards, > Bin ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot
[U-Boot] [PATCH v3 1/3] armv8/ls1043aqds: Select lpuart pins of various muxes
From: Shaohui XieSet Board Configuration Register to select the lpuart pins of various muxes. Signed-off-by: Shaohui Xie Signed-off-by: Mingkai Hu --- board/freescale/ls1043aqds/ls1043aqds.c | 15 +++ 1 file changed, 15 insertions(+) diff --git a/board/freescale/ls1043aqds/ls1043aqds.c b/board/freescale/ls1043aqds/ls1043aqds.c index d6696ca..67f4c4b 100644 --- a/board/freescale/ls1043aqds/ls1043aqds.c +++ b/board/freescale/ls1043aqds/ls1043aqds.c @@ -40,6 +40,9 @@ enum { #define CFG_SD_MUX3_MUX4 0x1 /* MUX4 */ #define CFG_SD_MUX4_SLOT3 0x0 /* SLOT3 TX/RX1 */ #define CFG_SD_MUX4_SLOT1 0x1 /* SLOT1 TX/RX3 */ +#define CFG_UART_MUX_MASK 0x6 +#define CFG_UART_MUX_SHIFT 1 +#define CFG_LPUART_EN 0x1 int checkboard(void) { @@ -218,7 +221,19 @@ void board_retimer_init(void) int board_early_init_f(void) { +#ifdef CONFIG_LPUART + u8 uart; +#endif fsl_lsch2_early_init_f(); +#ifdef CONFIG_LPUART + +/* We use lpuart1 as system console. */ + + uart = QIXIS_READ(brdcfg[14]); + uart &= ~CFG_UART_MUX_MASK; + uart |= CFG_LPUART_EN << CFG_UART_MUX_SHIFT; + QIXIS_WRITE(brdcfg[14], uart); +#endif return 0; } -- 2.1.0.27.g96db324 ___ U-Boot mailing list U-Boot@lists.denx.de http://lists.denx.de/mailman/listinfo/u-boot