From patchwork Wed Jun 3 15:44:20 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marcin Juszkiewicz X-Patchwork-Id: 1303072 X-Patchwork-Delegate: ykai007@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=85.214.62.61; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dmarc=fail (p=quarantine dis=none) header.from=juszkiewicz.com.pl Authentication-Results: ozlabs.org; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=juszkiewicz.com.pl header.i=@juszkiewicz.com.pl header.a=rsa-sha256 header.s=mail header.b=LwahabI3; dkim=fail reason="signature verification failed" (1024-bit key) header.d=juszkiewicz.com.pl header.i=@juszkiewicz.com.pl header.a=rsa-sha256 header.s=mail header.b=gvTD2wr3; dkim-atps=neutral Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 49cYBJ0cZvz9sRK for ; Thu, 4 Jun 2020 01:44:37 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 4201381D5C; Wed, 3 Jun 2020 17:44:31 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=fail (p=quarantine dis=none) header.from=juszkiewicz.com.pl Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=fail reason="signature verification failed" (1024-bit key; unprotected) header.d=juszkiewicz.com.pl header.i=@juszkiewicz.com.pl header.b="LwahabI3"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=juszkiewicz.com.pl header.i=@juszkiewicz.com.pl header.b="gvTD2wr3"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 09FC281D73; Wed, 3 Jun 2020 17:44:30 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,SPF_HELO_NONE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.2 Received: from muminek.juszkiewicz.com.pl (muminek.juszkiewicz.com.pl [213.251.184.221]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 5B54C81D4D for ; Wed, 3 Jun 2020 17:44:27 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=juszkiewicz.com.pl Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=marcin@juszkiewicz.com.pl Received: from localhost (localhost [127.0.0.1]) by muminek.juszkiewicz.com.pl (Postfix) with ESMTP id DD8D526195E; Wed, 3 Jun 2020 17:44:26 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=juszkiewicz.com.pl; s=mail; t=1591199066; bh=l4KojaKXgICSExE1JAjzftesQz3KtfRuxxOCRVhxPRo=; h=From:To:Cc:Subject:Date:From; b=LwahabI3lhxCGes/9BX/64elrOD3Zq8ew52nE9JWUqm2XblPH4qkOyf4Q9F47F6nl B7RVD0ijHzrsZi9jke0fsFUxNqE7wd4lVmPyjfJn/L3+XCTVpON8sEeebzI3ZunCxI Z+jH8dnurdYPFYmO/YTCpaQ/UtJ6fAHR139fXhc8= Received: from muminek.juszkiewicz.com.pl ([127.0.0.1]) by localhost (muminek.juszkiewicz.com.pl [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id kjlwZAScFUxS; Wed, 3 Jun 2020 17:44:25 +0200 (CEST) Received: from puchatek.local.com.pl (89-67-26-161.dynamic.chello.pl [89.67.26.161]) by muminek.juszkiewicz.com.pl (Postfix) with ESMTPSA id BBFCC261952; Wed, 3 Jun 2020 17:44:24 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=juszkiewicz.com.pl; s=mail; t=1591199064; bh=l4KojaKXgICSExE1JAjzftesQz3KtfRuxxOCRVhxPRo=; h=From:To:Cc:Subject:Date:From; b=gvTD2wr3qMa6HmIgQeqIJfhjEVDDxU0j50T4TkeRWfRST6OSKsH50qhEbRZ/fnYsq 38l3XqMGIVQ0dA5W0xlXJhHhfomneLLfC5cG6cLhIwhxGFzPtdhl38CpebkT1eObsZ WJ6uHoJh2OEoOM06Qlf80pJRDjsRW+MEfgMvQow4= From: Marcin Juszkiewicz To: u-boot@lists.denx.de Cc: Marcin Juszkiewicz Subject: [PATCH] rockchip: rockpro64: initialize USB in preboot Date: Wed, 3 Jun 2020 17:44:20 +0200 Message-Id: <20200603154420.3548127-1-marcin@juszkiewicz.com.pl> X-Mailer: git-send-email 2.26.2 MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.30rc1 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.102.2 at phobos.denx.de X-Virus-Status: Clean With video output enabled and USB keyboard supported there is no need for serial console. So let initialize USB subsystem so keyboard connected to board (either directly or via hub) can be used to interrupt autoboot. U-Boot TPL 2020.07-rc3-00123-g52d6cbd1a7 (Jun 03 2020 - 17:34:20) Channel 0: LPDDR4, 50MHz BW=32 Col=10 Bk=8 CS0 Row=16/15 CS=1 Die BW=16 Size=2048MB Channel 1: LPDDR4, 50MHz BW=32 Col=10 Bk=8 CS0 Row=16/15 CS=1 Die BW=16 Size=2048MB 256B stride 256B stride lpddr4_set_rate: change freq to 400000000 mhz 0, 1 lpddr4_set_rate: change freq to 800000000 mhz 1, 0 Trying to boot from BOOTROM Returning to boot ROM... U-Boot SPL 2020.07-rc3-00123-g52d6cbd1a7 (Jun 03 2020 - 17:34:20 +0200) Trying to boot from SPI U-Boot 2020.07-rc3-00123-g52d6cbd1a7 (Jun 03 2020 - 17:34:20 +0200) SoC: Rockchip rk3399 Reset cause: RST Model: Pine64 RockPro64 v2.1 DRAM: 3.9 GiB PMIC: RK808 MMC: mmc@fe310000: 2, mmc@fe320000: 1, sdhci@fe330000: 0 Loading Environment from SPI Flash... SF: Detected gd25q128 with page size 256 Bytes, erase size 4 KiB, total 16 MiB OK In: serial Out: vidconsole Err: vidconsole Model: Pine64 RockPro64 v2.1 Net: eth0: ethernet@fe300000 starting USB... Bus usb@fe380000: USB EHCI 1.00 Bus usb@fe3a0000: USB OHCI 1.0 Bus usb@fe3c0000: USB EHCI 1.00 Bus usb@fe3e0000: USB OHCI 1.0 Bus dwc3: Register 2000140 NbrPorts 2 Starting the controller USB XHCI 1.10 Bus dwc3: Register 2000140 NbrPorts 2 Starting the controller USB XHCI 1.10 scanning bus usb@fe380000 for devices... 1 USB Device(s) found scanning bus usb@fe3a0000 for devices... 1 USB Device(s) found scanning bus usb@fe3c0000 for devices... 1 USB Device(s) found scanning bus usb@fe3e0000 for devices... 2 USB Device(s) found scanning bus dwc3 for devices... 1 USB Device(s) found scanning bus dwc3 for devices... 2 USB Device(s) found scanning usb for storage devices... 1 Storage Device(s) found Hit any key to stop autoboot: 0 => Signed-off-by: Marcin Juszkiewicz Reviewed-by: Kever Yang --- configs/rockpro64-rk3399_defconfig | 2 ++ 1 file changed, 2 insertions(+) diff --git configs/rockpro64-rk3399_defconfig configs/rockpro64-rk3399_defconfig index 807747485a..a56126b042 100644 --- configs/rockpro64-rk3399_defconfig +++ configs/rockpro64-rk3399_defconfig @@ -11,6 +11,8 @@ CONFIG_DEBUG_UART_CLOCK=24000000 CONFIG_SPL_SPI_FLASH_SUPPORT=y CONFIG_SPL_SPI_SUPPORT=y CONFIG_DEBUG_UART=y +CONFIG_USE_PREBOOT=y +CONFIG_PREBOOT="usb start" CONFIG_DEFAULT_FDT_FILE="rockchip/rk3399-rockpro64.dtb" CONFIG_MISC_INIT_R=y CONFIG_DISPLAY_BOARDINFO_LATE=y