From: Heiko Stuebner <heiko@sntech.de>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v2 2/9] ARM: rockchip: rk3188: Remove the pinctrl setup and enable uart at SPL
Date: Sat, 05 Jan 2019 18:19:07 +0100 [thread overview]
Message-ID: <2188614.4Kt4vNU6pO@phil> (raw)
In-Reply-To: <5945404.LMZMiQBCTc@phil>
Am Samstag, 5. Januar 2019, 18:17:34 CET schrieb Heiko Stuebner:
> Hi David,
>
> Am Mittwoch, 2. Januar 2019, 13:50:58 CET schrieb David Wu:
> > When the boot ROM sets up MMC we don't need to do it again. Remove the
> > MMC setup code entirely, but we also need to enable uart for debug message.
> >
> > Signed-off-by: David Wu <david.wu@rock-chips.com>
> > ---
> >
> > Changes in v2: None
> >
> > arch/arm/mach-rockchip/rk3188-board-spl.c | 41 ++---------------------
> > 1 file changed, 2 insertions(+), 39 deletions(-)
> >
> > diff --git a/arch/arm/mach-rockchip/rk3188-board-spl.c b/arch/arm/mach-rockchip/rk3188-board-spl.c
> > index 3c6c3d3c09..a5e4d39cb7 100644
> > --- a/arch/arm/mach-rockchip/rk3188-board-spl.c
> > +++ b/arch/arm/mach-rockchip/rk3188-board-spl.c
> > @@ -120,7 +120,7 @@ void board_debug_uart_init(void)
> >
> > void board_init_f(ulong dummy)
> > {
> > - struct udevice *pinctrl, *dev;
> > + struct udevice *dev;
> > int ret;
> >
> > #define EARLY_UART
> > @@ -134,10 +134,7 @@ void board_init_f(ulong dummy)
> > * printascii("string");
> > */
> > debug_uart_init();
> > - printch('s');
> > - printch('p');
> > - printch('l');
> > - printch('\n');
> > + printascii("U-Boot SPL board init");
>
> Did you test this change?
> I remember rk3188 having issues (aka hanging) when trying to print
> strings through the debug uart and only printch working at all.
> (Timer issue or so?) ... Not sure if this got fixed in the meantime?
>
> > #endif
> >
> > #ifdef CONFIG_ROCKCHIP_USB_UART
> > @@ -171,12 +168,6 @@ void board_init_f(ulong dummy)
> > return;
> > }
> >
> > - ret = uclass_get_device(UCLASS_PINCTRL, 0, &pinctrl);
> > - if (ret) {
> > - debug("Pinctrl init failed: %d\n", ret);
> > - return;
> > - }
> > -
> > ret = uclass_get_device(UCLASS_RAM, 0, &dev);
> > if (ret) {
> > debug("DRAM init failed: %d\n", ret);
> > @@ -214,7 +205,6 @@ static int setup_led(void)
> >
> > void spl_board_init(void)
> > {
> > - struct udevice *pinctrl;
> > int ret;
> >
> > ret = setup_led();
> > @@ -223,36 +213,9 @@ void spl_board_init(void)
> > hang();
> > }
> >
> > - ret = uclass_get_device(UCLASS_PINCTRL, 0, &pinctrl);
> > - if (ret) {
> > - debug("%s: Cannot find pinctrl device\n", __func__);
> > - goto err;
> > - }
> > -
> > -#ifdef CONFIG_SPL_MMC_SUPPORT
> > - ret = pinctrl_request_noflags(pinctrl, PERIPH_ID_SDCARD);
> > - if (ret) {
> > - debug("%s: Failed to set up SD card\n", __func__);
> > - goto err;
> > - }
> > -#endif
> > -
> > - /* Enable debug UART */
> > - ret = pinctrl_request_noflags(pinctrl, PERIPH_ID_UART_DBG);
> > - if (ret) {
> > - debug("%s: Failed to set up console UART\n", __func__);
> > - goto err;
> > - }
> > -
>
> Hmm, I see that you're removing the uarts setup in the spl-stage,
> but where do you expect it to get setup now, in the case that
> only the regular uart but no debug uart gets setup in spl?
Ah, looking at the following patch, I guess you expect the new
pinctrl driver to set this up, right? The this looks good.
Heiko
next prev parent reply other threads:[~2019-01-05 17:19 UTC|newest]
Thread overview: 53+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-01-02 12:50 [U-Boot] [PATCH v2 0/9] Add common pinctrl driver support for rockchip David Wu
2019-01-02 12:50 ` [U-Boot] [PATCH v2 1/9] rockchip: rk3399-evb: defconfig: Enable FDT for new pinctrl driver David Wu
2019-01-10 12:56 ` Simon Glass
2019-01-22 9:11 ` Kever Yang
2019-01-31 10:15 ` [U-Boot] [U-Boot, v2, " Philipp Tomsich
2019-01-31 21:12 ` Philipp Tomsich
2019-01-02 12:50 ` [U-Boot] [PATCH v2 2/9] ARM: rockchip: rk3188: Remove the pinctrl setup and enable uart at SPL David Wu
2019-01-05 17:17 ` Heiko Stuebner
2019-01-05 17:19 ` Heiko Stuebner [this message]
2019-01-22 8:57 ` Kever Yang
2019-01-14 12:01 ` David Wu
2019-01-18 23:34 ` Lukasz Majewski
2019-01-22 9:04 ` [U-Boot] [PATCH v2 2/9] ARM: rockchip: rk3188: Remove the pinctrl setup and enable uart at SPL【请注意,邮件由u-boot-bounces@lists.denx.de代发】 Kever Yang
2019-01-22 10:27 ` Lukasz Majewski
2019-01-22 9:10 ` [U-Boot] [PATCH v2 2/9] ARM: rockchip: rk3188: Remove the pinctrl setup and enable uart at SPL David Wu
2019-01-22 9:11 ` Kever Yang
2019-01-31 10:15 ` [U-Boot] [U-Boot, v2, " Philipp Tomsich
2019-01-31 21:12 ` Philipp Tomsich
2019-01-02 12:50 ` [U-Boot] [PATCH v2 3/9] ARM: rockchip: Kconfig: Remove the SPL_PINCTRL for rk3188 David Wu
2019-01-22 9:12 ` Kever Yang
2019-01-31 10:15 ` [U-Boot] [U-Boot, v2, " Philipp Tomsich
2019-01-31 21:12 ` Philipp Tomsich
2019-01-02 12:51 ` [U-Boot] [PATCH v2 4/9] ARM: rockchip: Remove the pinctrl request at rk3288-board-spl David Wu
2019-01-22 9:12 ` Kever Yang
2019-01-31 10:15 ` [U-Boot] [U-Boot, v2, " Philipp Tomsich
2019-01-31 21:12 ` Philipp Tomsich
2019-01-02 13:00 ` [U-Boot] [PATCH v2 5/9] rk3288: chrome: defconfig: Enable FDT for new pinctrl driver David Wu
2019-01-31 10:15 ` [U-Boot] [U-Boot, v2, " Philipp Tomsich
2019-01-31 21:12 ` Philipp Tomsich
2019-01-02 13:00 ` [U-Boot] [PATCH v2 6/9] pinctrl: rockchip: Add common rockchip " David Wu
2019-01-05 17:27 ` Heiko Stuebner
2019-01-06 18:57 ` Philipp Tomsich
2019-01-06 20:49 ` Heiko Stuebner
2019-01-22 9:15 ` Kever Yang
2019-01-31 10:15 ` [U-Boot] [U-Boot, v2, " Philipp Tomsich
2019-01-31 21:12 ` Philipp Tomsich
2019-01-02 13:01 ` [U-Boot] [PATCH v2 7/9] rockchip: defconfig: Clean the unused pinctrl config David Wu
2019-01-22 9:16 ` Kever Yang
2019-01-31 10:15 ` [U-Boot] [U-Boot, v2, " Philipp Tomsich
2019-01-31 21:12 ` Philipp Tomsich
2019-02-05 10:49 ` Emmanuel Vadot
2019-02-05 10:51 ` Philipp Tomsich
2019-01-02 13:02 ` [U-Boot] [PATCH v2 8/9] pinctrl: rockchip: Clean the unused rockchip pinctrl drivers David Wu
2019-01-10 12:56 ` Simon Glass
2019-01-22 9:16 ` Kever Yang
2019-01-31 10:15 ` [U-Boot] [U-Boot, v2, " Philipp Tomsich
2019-01-31 21:12 ` Philipp Tomsich
2019-01-02 13:02 ` [U-Boot] [PATCH v2 9/9] ARM: dts: rk322x: Correct the uart2 default pin configuration David Wu
2019-01-22 9:16 ` Kever Yang
2019-01-31 10:15 ` [U-Boot] [U-Boot, v2, " Philipp Tomsich
2019-01-31 21:12 ` Philipp Tomsich
2019-01-21 18:50 ` [U-Boot] [PATCH v2 0/9] Add common pinctrl driver support for rockchip Simon Glass
2019-01-24 2:26 ` David Wu
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=2188614.4Kt4vNU6pO@phil \
--to=heiko@sntech.de \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox