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: 112681 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp7067726vqr; Sun, 25 Jun 2023 12:38:55 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ6NlLXfJG1J6vzH4C60K7fiRsNjikNZjkXmc1JaXiwqmXnpTUbO4Jg5PJ0+pEFLs0Sb27uh X-Received: by 2002:a17:907:94c9:b0:989:3e0d:89fb with SMTP id dn9-20020a17090794c900b009893e0d89fbmr14087531ejc.45.1687721934864; Sun, 25 Jun 2023 12:38:54 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687721934; cv=none; d=google.com; s=arc-20160816; b=lBTP7bXxZe5S76kHhxHsuAMFmkclxkNRXIRIh5FMLT9tIZdGW0a8YYHB3w5ngwOZz2 v9IeJhNhI0niiE3VKfDHyerU+0+gLpK/xEzpwKqWZqPQw/n0HVaGXktEFVvnwNR6fIGS WcxETpijj8BdZWw2ro7SxPyLPS4uQFV+QhCjlU859ueznmdR09Xp20V1NPAxPomQjrO8 pbWMdpfEtxi5lGHlzxXKWv4weraX+DjnYgs979vv+XbpV7UDqYECQSDAISFSQFKyqb2V sEWpVzvQe/L6QU8NeV1sVhX5fRA30S3sdseKoO0Ua/jlKtPbZ4FHecxPiQ0Hk2jiwxds v+LA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=hOhkIMP+kNOLQ9YAs2dWlhnv2oixfRQubnTydB4EaJc=; fh=p58pEyGs9ZVmc0iWCS1JcSbg7GM1EacYwgZCiW6CZHo=; b=SwyNkwFqPzZJeRTzqAey/ukJvjkGW/Wt3RLdy+uYMMGQiSZkkxkvqNDkQs90aJ4Z2g HkYttiERBnpH8TK1Di9i2McpLtrvZya3/eqI1ud/ZahKjyZs9af6uUkcGse1TWCOAQSF H4QSpX4F8A6GRy8ESTCbwy0qq+B62wFF4+4l7NnjqILHPTvD1VzBi3z0e/7aVHGDXLxx 1pI3ZqkIYpbD5DSWkvVaI9K4OVjEhVVTf9X9v9F3iujT8ajix8W8WAAxMT2BPKeEBK0R koutBVSSe79BPpYnSdDu/wc11xjYokHjqW2xmPAxBmrYk6MYm2jn67Tg2KyCSTwtVkd8 ELRw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mailerdienst.de header.s=20200217 header.b=Z3J2zGRj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id kd16-20020a17090798d000b0098da8d0ce58si2050912ejc.868.2023.06.25.12.38.30; Sun, 25 Jun 2023 12:38:54 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@mailerdienst.de header.s=20200217 header.b=Z3J2zGRj; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229998AbjFYTML (ORCPT + 99 others); Sun, 25 Jun 2023 15:12:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41590 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229886AbjFYTMD (ORCPT ); Sun, 25 Jun 2023 15:12:03 -0400 Received: from mxout4.routing.net (mxout4.routing.net [134.0.28.9]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5785DB9; Sun, 25 Jun 2023 12:12:02 -0700 (PDT) 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-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1769704715973312569?= X-GMAIL-MSGID: =?utf-8?q?1769704715973312569?= 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: 112679 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a59:994d:0:b0:3d9:f83d:47d9 with SMTP id k13csp7062025vqr; Sun, 25 Jun 2023 12:21:53 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4hqkHAhb82mnZk9gvrbL0qKb791zB5+g9PXHFBr6KPVas2U600HLVD35bdZbNBPs7nqtSY X-Received: by 2002:a17:907:847:b0:987:fe18:1c53 with SMTP id ww7-20020a170907084700b00987fe181c53mr17425602ejb.5.1687720912965; Sun, 25 Jun 2023 12:21:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1687720912; cv=none; d=google.com; s=arc-20160816; b=o32pjPP1WqpiCm9gIdqjnzEKCHNB/ZPaQZvetpkYM+8+Wk11bk+vDxPfr8FjtokKPW sXQbXwBuyRhR2padnLSeBIq08cmRZ7e+I53TeqenEFrh75KMeqYyl5TXd5/zBJ3pg6IP KEVqVhVyXMvUYT1cOkmYhokInSmZPvsGRzDGwLP40v5RnziI/zf9PEF2YKu87UGVIxpN mkUIlc3BXbRXv6PKlWV04ngy693PVxoHN0uGGMasCrek0idTNeE0UgatI82FWXXN5kBx Wiz96Q21SZ6+Mg+ZslW/UPGkgWPdg7kYnn/TRFWV8hMZGRth6kU0pAdJkMuJWoXOBJLX D1Fg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=I8cdP6cF+nwTWlyfboIiQYyzWM6TGbsre5s255hDw1E=; fh=1D+qc4sAXkKNnQ3PxQy1SeTEtOqvF9vaWKsCr9vTrE0=; b=HHt+Z41ZrWxTF408GEqyJSqdmd+mK6Ax7RL4SpC0aheVKgPiDq2l6MsrbeBYjSRd65 K1Q28tB3M96f1bRvCdG47HO5YNOxlZak+lmo1mRrGE/sfiJ/IjCo5LNg475dGzm+iT2m Ftzx7e4FKZ9gETKDgGK/rJGtvWJuCxGxwsK5o1WVY5/kXALnsSd8lqvHg57xRXRLnYau mzhMUi2jgkMFhwTgraQeQiftBxEieiTslZZtQoE3WXR7PcNNWHLtGlFrHoJ0g74RjKmw 15U8ynl6RHSoeSCrxU++RCUkAXwZ1TF/eqO3/B5Bc3RXZevdJZ2QMhyTPK9ykyDda9vT vxAg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@mailerdienst.de header.s=20200217 header.b=Pl5yHLtQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id hk8-20020a170906c9c800b009881b31b396si2009695ejb.655.2023.06.25.12.21.27; Sun, 25 Jun 2023 12:21:52 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@mailerdienst.de header.s=20200217 header.b=Pl5yHLtQ; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229907AbjFYTMF (ORCPT + 99 others); Sun, 25 Jun 2023 15:12:05 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41588 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229606AbjFYTMD (ORCPT ); Sun, 25 Jun 2023 15:12:03 -0400 Received: from mxout3.routing.net (mxout3.routing.net [IPv6:2a03:2900:1:a::8]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 19227AB; Sun, 25 Jun 2023 12:12:01 -0700 (PDT) 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-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,RCVD_IN_DNSWL_NONE,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-getmail-retrieved-from-mailbox: =?utf-8?q?INBOX?= X-GMAIL-THRID: =?utf-8?q?1769703644342885292?= X-GMAIL-MSGID: =?utf-8?q?1769703644342885292?= 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>,