From patchwork Wed Nov 27 15:49:23 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: E Shattow X-Patchwork-Id: 13887160 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CAB03D6ACEF for ; Wed, 27 Nov 2024 15:50:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=uTJq0417El69Lrs/hMDmzXeTXcsprx4aEm+Jgro3Q8w=; b=KYS8e4mZ7J0HC/ R9JvIpLWOqbU6sfpeRZNPMI7vyWJBOvpJTUwU06ioC1M9m9w6wWbZ6P/Fa/x9xIqxQ+DwgIGG8Jl5 v7MTw7sWjntWcsjS33gkx1GUHDNlxe88/cwoflYjevuXK36DhUb3BrD15xyHfrTOl8DlZSeHvYxSr WD/y6a+Pqxvc3L2yVLDIDbnWf7dLokdsM4npVDpPUaUYzAHoGA7lNLkRxaiQx5ewCjAh67w8do/vY i19J64NBxVWwiocsMxOFY9TeFSg1cQIYuK654CPcDPp3mMUYWBHK1NlU75m2HGp9urolGxD7emdJw HGwev7be4qP9l4QV6UVQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1tGKJB-0000000DYMr-3cDk; Wed, 27 Nov 2024 15:50:29 +0000 Received: from freeshell.de ([2a01:4f8:231:482b::2]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1tGKJ8-0000000DYLl-48hV for linux-riscv@lists.infradead.org; Wed, 27 Nov 2024 15:50:28 +0000 Received: from hay.lan. (unknown [IPv6:2605:59c8:31de:bf00:6ecf:39ff:fe00:8375]) (Authenticated sender: e) by freeshell.de (Postfix) with ESMTPSA id 319D6B4B1E33; Wed, 27 Nov 2024 16:50:23 +0100 (CET) From: E Shattow To: Emil Renner Berthing , Henry Bell Cc: E Shattow , Conor Dooley , Emil Renner Berthing , Rob Herring , Krzysztof Kozlowski , Paul Walmsley , Palmer Dabbelt , Albert Ou , linux-riscv@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v6 1/1] riscv: dts: starfive: jh7110-milkv-mars: enable usb0 host function Date: Wed, 27 Nov 2024 07:49:23 -0800 Message-ID: <20241127154958.71094-2-e@freeshell.de> X-Mailer: git-send-email 2.45.2 In-Reply-To: <20241127154958.71094-1-e@freeshell.de> References: <20241127154958.71094-1-e@freeshell.de> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241127_075027_165449_9343B8C9 X-CRM114-Status: UNSURE ( 7.81 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-riscv@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-riscv" Errors-To: linux-riscv-bounces+linux-riscv=archiver.kernel.org@lists.infradead.org Milk-V Mars board routes one of four USB-A ports to USB0 on the SoC rather than to the VL805 USB 3.0 <-> PCIe chip. Set JH7110 on-chip USB host mode and vbus pin assignment accordingly. Reviewed-by: Emil Renner Berthing Signed-off-by: E Shattow --- .../boot/dts/starfive/jh7110-milkv-mars.dts | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/arch/riscv/boot/dts/starfive/jh7110-milkv-mars.dts b/arch/riscv/boot/dts/starfive/jh7110-milkv-mars.dts index 0d248b671d4b..3bd62ab78523 100644 --- a/arch/riscv/boot/dts/starfive/jh7110-milkv-mars.dts +++ b/arch/riscv/boot/dts/starfive/jh7110-milkv-mars.dts @@ -53,7 +53,23 @@ &spi0 { status = "okay"; }; +&sysgpio { + usb0_pins: usb0-0 { + vbus-pins { + pinmux = ; + bias-disable; + input-disable; + input-schmitt-disable; + slew-rate = <0>; + }; + }; +}; + &usb0 { - dr_mode = "peripheral"; + dr_mode = "host"; + pinctrl-names = "default"; + pinctrl-0 = <&usb0_pins>; status = "okay"; };