From patchwork Sun Jun 25 19:11:50 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frank Wunderlich X-Patchwork-Id: 13292097 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 19131EB64DC for ; Sun, 25 Jun 2023 19:12:31 +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=FmfUifdVNGIufX30KB1HTuq/KwispXH9LDi/Hb3J7x0=; b=F6Y0o4j2EUNN90 hUlkOPDg5N730jE69xyxQBa2aLca0bb7h4QbTMjw3qGXpIGkrnw3MFgp23pqnbM2lWaUD8jyve8DC ao90qgdPyET+SkYEFxHy6c7Jki2xc43VfuRsuMDShE74WrNsp36kJhiR4K+wuJ9h0AtJaxW7uEaMa p6eSi3FQCYWLql8PRWvzQlEyeynSRPCwJMaLonhR3tOfx0UxekV1h0KRHaTfPX2z/uYaKRJ0KPA+P Jk3cRof/9MVx1R4Jz3AQDiY+72WCzoM5LBKTr8EOgHn4mrQt+A7ENeKXBlfvQjTJ7y+0vBcD0AZi1 VUhj+4WpvQU79wdnX/8w==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qDV9c-008Wgf-2m; Sun, 25 Jun 2023 19:12:08 +0000 Received: from mxout4.routing.net ([2a03:2900:1:a::9]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qDV9Z-008Wec-1G; Sun, 25 Jun 2023 19:12:07 +0000 Received: from mxbox3.masterlogin.de (unknown [192.168.10.78]) by mxout4.routing.net (Postfix) with ESMTP id 7227B100877; Sun, 25 Jun 2023 19:11:58 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mailerdienst.de; s=20200217; t=1687720318; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=hOhkIMP+kNOLQ9YAs2dWlhnv2oixfRQubnTydB4EaJc=; b=Z3J2zGRjRQFq636jMHZKVXR0v7VK1OT6o//nDMxRKiErjeESe5un7dVgJNFsr2D4R280oJ ux7H1TtvlRrnHvN1bBHEv/RJk7nVAuu07iOZd+c+Dz7FgAMyqZjttI1TJkEwR3EDvm4QlU f3YG1zgMPUz3IQb8AqehVB7EFDDNNZk= Received: from frank-G5.. (fttx-pool-217.61.151.158.bambit.de [217.61.151.158]) by mxbox3.masterlogin.de (Postfix) with ESMTPSA id B5DB0360931; Sun, 25 Jun 2023 19:11:57 +0000 (UTC) From: Frank Wunderlich To: linux-mediatek@lists.infradead.org Cc: Frank Wunderlich , Chaotian Jing , Ulf Hansson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Matthias Brugger , AngeloGioacchino Del Regno , Wenbin Mei , Sam Shih , linux-mmc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: [PATCH v1 1/2] dt-bindings: mmc: mtk-sd: update assigned-clocks/clock-parents for mt7986 Date: Sun, 25 Jun 2023 21:11:50 +0200 Message-Id: <20230625191151.7808-2-linux@fw-web.de> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230625191151.7808-1-linux@fw-web.de> References: <20230625191151.7808-1-linux@fw-web.de> MIME-Version: 1.0 X-Mail-ID: 111d6e13-9401-4ca9-bbed-5c71f5bd419c X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230625_121205_613273_B7C80022 X-CRM114-Status: UNSURE ( 8.62 ) X-CRM114-Notice: Please train this message. X-BeenThere: linux-arm-kernel@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-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Frank Wunderlich MT7986 has 2 clock-parents so update the binding for it. Signed-off-by: Frank Wunderlich --- Documentation/devicetree/bindings/mmc/mtk-sd.yaml | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Documentation/devicetree/bindings/mmc/mtk-sd.yaml b/Documentation/devicetree/bindings/mmc/mtk-sd.yaml index 46eefdd19a2c..485516dcc759 100644 --- a/Documentation/devicetree/bindings/mmc/mtk-sd.yaml +++ b/Documentation/devicetree/bindings/mmc/mtk-sd.yaml @@ -247,6 +247,10 @@ allOf: - mediatek,mt7986-mmc then: properties: + assigned-clocks: + maxItems: 2 + assigned-clock-parents: + maxItems: 2 clocks: minItems: 3 items: From patchwork Sun Jun 25 19:11:51 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Frank Wunderlich X-Patchwork-Id: 13292099 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 71E92C0015E for ; Sun, 25 Jun 2023 19:12:46 +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=TFuwujWv/JG0hj3d+0HXZz8fjlsy2qmag6uzA7pKhvU=; b=PJJ8QxSwKk8+wn zsUcEUaSPOVqxG62dSwj7Bo1xgX4nOB3x1iCgpUexGEOE2blZd30oIS66DCt/VH4as6ieQtH6Dt92 XhzdwtBoKPdnjLygWiiCC4DryCLoY53kXTJJTJ4kGa4vCXmqXSH4OOlTbleckt03oG+FdCZ3mVmUL IT7AdsJNbGUp72DCUgFGl71qCpOXtJhEKl0ay7pY+6m0Rzg4Fpq361jT41LTN2UjtHU8rT4coATWq uQJos4MTCOkCw+kPA2ZB3ZvtqGFxH+seJmIFqgY9wzfh6zjJYzlzv75u8QgQwEp+cr2VF+VhhU5ZR hMtNWv97YXAg9GNNfVFQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qDV9s-008Wl2-0r; Sun, 25 Jun 2023 19:12:24 +0000 Received: from mxout3.routing.net ([2a03:2900:1:a::8]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qDV9Z-008WeU-1G; Sun, 25 Jun 2023 19:12:08 +0000 Received: from mxbox3.masterlogin.de (unknown [192.168.10.78]) by mxout3.routing.net (Postfix) with ESMTP id 33B6361D70; Sun, 25 Jun 2023 19:11:59 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mailerdienst.de; s=20200217; t=1687720319; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=I8cdP6cF+nwTWlyfboIiQYyzWM6TGbsre5s255hDw1E=; b=Pl5yHLtQhlZRf6IaetH73juzzgAcv8wvmRT4gxomHF6ZkFCxpKIkojkR90tRkMaLqkgfKY NpKwS9ev3rY8UQUu2n9vZbd4hDRSP4LXhWqEoo+0CMv4krDL6OzHgzdD4tSwTkN2mMl7uq zMfOaBSaX20rnMpkbuXrgEnYY7yBRt8= Received: from frank-G5.. (fttx-pool-217.61.151.158.bambit.de [217.61.151.158]) by mxbox3.masterlogin.de (Postfix) with ESMTPSA id 614883603F2; Sun, 25 Jun 2023 19:11:58 +0000 (UTC) From: Frank Wunderlich To: linux-mediatek@lists.infradead.org Cc: Frank Wunderlich , Chaotian Jing , Ulf Hansson , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Matthias Brugger , AngeloGioacchino Del Regno , Wenbin Mei , Sam Shih , linux-mmc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, Eric Woudstra , stable@vger.kernel.org Subject: [PATCH v1 2/2] arm64: dts: mt7986: fix emmc hs400 mode without uboot initialization Date: Sun, 25 Jun 2023 21:11:51 +0200 Message-Id: <20230625191151.7808-3-linux@fw-web.de> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230625191151.7808-1-linux@fw-web.de> References: <20230625191151.7808-1-linux@fw-web.de> MIME-Version: 1.0 X-Mail-ID: e50c288a-9e4f-4e10-8878-4503de1b0770 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230625_121205_759560_1AF992D3 X-CRM114-Status: GOOD ( 10.10 ) X-BeenThere: linux-arm-kernel@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-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org From: Eric Woudstra Eric reports errors on emmc with hs400 mode when booting linux on bpi-r3 without uboot [1]. Booting with uboot does not show this because clocks seem to be initialized by uboot. Fix this by adding assigned-clocks and assigned-clock-parents like it's done in uboot [2]. [1] https://forum.banana-pi.org/t/bpi-r3-kernel-fails-setting-emmc-clock-to-416m-depends-on-u-boot/15170 [2] https://github.com/u-boot/u-boot/blob/master/arch/arm/dts/mt7986.dtsi#L287 Cc: stable@vger.kernel.org Fixes: 513b49d19b34 ("arm64: dts: mt7986: add mmc related device nodes") Signed-off-by: Eric Woudstra Signed-off-by: Frank Wunderlich --- arch/arm64/boot/dts/mediatek/mt7986a.dtsi | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/arch/arm64/boot/dts/mediatek/mt7986a.dtsi b/arch/arm64/boot/dts/mediatek/mt7986a.dtsi index 68539ea788df..207510abda89 100644 --- a/arch/arm64/boot/dts/mediatek/mt7986a.dtsi +++ b/arch/arm64/boot/dts/mediatek/mt7986a.dtsi @@ -374,6 +374,10 @@ mmc0: mmc@11230000 { reg = <0 0x11230000 0 0x1000>, <0 0x11c20000 0 0x1000>; interrupts = ; + assigned-clocks = <&topckgen CLK_TOP_EMMC_416M_SEL>, + <&topckgen CLK_TOP_EMMC_250M_SEL>; + assigned-clock-parents = <&apmixedsys CLK_APMIXED_MPLL>, + <&topckgen CLK_TOP_NET1PLL_D5_D2>; clocks = <&topckgen CLK_TOP_EMMC_416M_SEL>, <&infracfg CLK_INFRA_MSDC_HCK_CK>, <&infracfg CLK_INFRA_MSDC_CK>,