From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 84CC8C4332F for ; Fri, 9 Dec 2022 06:56:59 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id C068783013; Fri, 9 Dec 2022 07:56:56 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1670569016; bh=Ia6t7YfQiHnE1GAO9AIiGJ7GW37+lMzezjn/YjNkb7k=; h=Date:Subject:To:Cc:References:From:In-Reply-To:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=lSYkJWQ3wZwg7mn8YIXTC/hJnHad6adumPQ9peVsoXtzwpEN0DXJNEDRe3dcU9oqU heJCmte6Grpw5QHVwNO9qHHlAgdwqsNsBHzee8My2RN1gTmaqQ9pQ8OUty6REWGfvx 5I1XoiM4X1+i00kyEflzd0ae5WBIhNY99tEKSJPs1UZ32qOdZQNbPGVGwKo6mJrfYN H3+Rvcg4EcE/COLPpo27f6TBk92xyPHAskip+ydLQ60OnSRjVZMTG5Lsh3C34hnzzj 8QlkyCRWGeJJ7w/cRmChPFQm+U8VaoPy5A+tiJIVTV6A3pvyOVIKYC+Z6k9wwVnDAV 9ukgeQLkDL1+g== Received: by phobos.denx.de (Postfix, from userid 109) id 4BD5F8452B; Fri, 9 Dec 2022 07:56:55 +0100 (CET) Received: from mout-u-204.mailbox.org (mout-u-204.mailbox.org [IPv6:2001:67c:2050:101:465::204]) (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 4B54481335 for ; Fri, 9 Dec 2022 07:56:53 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: phobos.denx.de; spf=fail smtp.mailfrom=sr@denx.de Received: from smtp202.mailbox.org (smtp202.mailbox.org [IPv6:2001:67c:2050:b231:465::202]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-u-204.mailbox.org (Postfix) with ESMTPS id 4NT1z30d82z9sXg; Fri, 9 Dec 2022 07:56:47 +0100 (CET) Message-ID: <94fd39c3-d186-79d2-3e36-5e408355c3ea@denx.de> Date: Fri, 9 Dec 2022 07:56:42 +0100 MIME-Version: 1.0 Subject: Re: Converting to DM SERIAL for Kirkwood boards To: Tony Dinh , Simon Glass , U-Boot Mailing List Cc: =?UTF-8?Q?Pali_Roh=c3=a1r?= References: Content-Language: en-US From: Stefan Roese In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Rspamd-Queue-Id: 4NT1z30d82z9sXg X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 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.103.6 at phobos.denx.de X-Virus-Status: Clean Hi Tony, On 12/9/22 04:55, Tony Dinh wrote: > Hi Simon et al, > > (Resend to include u-boot mailing list) > > I'm in the process of converting Kirkwood boards to use DM SERIAL. I > could not seem to get it to work, having tried adding > CONFIG_DM_SERIAL, and also playing with various related CONFIG > options (CONFIG_SPECIFY_CONSOLE_INDEX and CONFIG_CONS_INDEX ). From > my reading various board configurations that were already converted to > DM_SERIAL, I'm under the impression that just turning on > CONFIG_DM_SERIAL would work without any other addition. > > The board I'm testing is Zyxel NSA310S Kirkwood 6702 (6192) SoC. > > diff --git a/configs/nsa310s_defconfig b/configs/nsa310s_defconfig > index afa0cad041..e81d1495bd 100644 > --- a/configs/nsa310s_defconfig > +++ b/configs/nsa310s_defconfig > @@ -41,7 +41,6 @@ CONFIG_ENV_OVERWRITE=y > CONFIG_ENV_IS_IN_NAND=y > CONFIG_SYS_RELOC_GD_ENV_ADDR=y > CONFIG_NET_RANDOM_ETHADDR=y > -CONFIG_NETCONSOLE=y > CONFIG_SYS_FAULT_ECHO_LINK_DOWN=y > CONFIG_SATA_MV=y > CONFIG_SYS_SATA_MAX_DEVICE=1 > @@ -53,6 +52,7 @@ CONFIG_MTD_RAW_NAND=y > CONFIG_PHY_MARVELL=y > CONFIG_MVGBE=y > CONFIG_MII=y > +CONFIG_DM_SERIAL=y > CONFIG_SYS_NS16550=y > CONFIG_USB=y > CONFIG_USB_EHCI_HCD=y > > I also added kirkwood-nsa310s-u-boot.dtsi to help in running kwboot. > > &uart0 { > u-boot,dm-pre-reloc; > }; > > I've tried kwboot the new u-boot image, and also flashed this image to > NAND, and in both cases, I got a silent serial console. It seems to > hang up right off the bat. Hope you can help by giving me some > pointers on how to debug this. Might be that the alias is missing and / or that the uart DT node is not enabled. Please give this test-only patch a try: diff --git a/arch/arm/dts/kirkwood-nsa310s.dts b/arch/arm/dts/kirkwood-nsa310s.dts index 09ee76c2a2e0..ca7a49af9ba4 100644 --- a/arch/arm/dts/kirkwood-nsa310s.dts +++ b/arch/arm/dts/kirkwood-nsa310s.dts @@ -17,6 +17,10 @@ model = "Zyxel NSA310S"; compatible = "zyxel,nsa320s", "marvell,kirkwood-88f6702", "marvell,kirkwood"; + aliases { + serial0 = &uart0; + }; + memory { device_type = "memory"; reg = <0x00000000 0x10000000>; @@ -317,3 +321,8 @@ &pcie0 { status = "okay"; }; + +&uart0 { + status = "okay"; + u-boot,dm-pre-reloc; +}; Thanks, Stefan