From patchwork Tue Nov 15 17:28:28 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Konrad Dybcio X-Patchwork-Id: 20490 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a5d:6687:0:0:0:0:0 with SMTP id l7csp2856912wru; Tue, 15 Nov 2022 09:37:37 -0800 (PST) X-Google-Smtp-Source: AA0mqf432TlDJ/hswmblhTEIYml4pCw4YbM5RoWj4xUpWKwXdKRksayYblyAfnvQAgUdiybIuDp5 X-Received: by 2002:a17:906:9f0c:b0:7ae:7d78:9fa1 with SMTP id fy12-20020a1709069f0c00b007ae7d789fa1mr14192450ejc.98.1668533857111; Tue, 15 Nov 2022 09:37:37 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668533857; cv=none; d=google.com; s=arc-20160816; b=Ham937eh/NjI7yA+nxWKKzLeCaCiHLNrp+leaQtx6GQfz+PRFY7B0yBaN5HmrgAJon Fgj+XtiykIen0IaVLI5iU24t7sHVOhZpk1b6uhs41jFjXbh7StChaLpvmytpj+ZYApDs tCqJ90pWHMUhQNRwymZwDjOvxNPtC/oLH4GHFiE+E9ObTExAt+CuC3Y4JwIl5DMywqCV TJotP/Iuz3+r/KKCtgaz825senRVFmtFxzP0/u/EetTav2/y3N5+JWX3jSjqDAHA9Xi1 RUiS6K2/g37Y8H5cmC2raaqDFKZaIabd+LqE5TcQXSjMFN/xVCVZjiJm/hnUxiNlR/Ur PF7g== 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=qnzzFvDnrUNiU88yEZt6sQdtp0kEECaqorraO0GqvxU=; b=OPMZR5cxQ75Wt/HDQ5xmBW8/4wgwRzZMwL8rQ4bLRC+/z17YT1eZg8pi6E0S9HlwQB DPJibtI1fvJlDVBgf0iSvJBeuCEG8bNlATe+AQawNDihANjNnLq2z2n2i6gWKM6ogKPa y5WD6EiSgzNFByNkisIWeQI9YAYfodEOiekOO225pTkOnM/0ggUZ+CR1/EPA123ZwRyx ZG7qhdY1WfWcyCENft8SqIYlxP6Pzor3PUsV+OcBsV5WWzh7XKuTD4iDD5FTgtSUg9Ym Ih15MpCcBxJTZ7I0hyU9OLRqGUrtK1m116cK1eDE96Bpit5sAoB3z8UZx0yrMZuGuqU0 1naw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=gTqXfTfz; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id y5-20020aa7ccc5000000b00463153e5b14si9841687edt.517.2022.11.15.09.37.12; Tue, 15 Nov 2022 09:37:37 -0800 (PST) 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=@linaro.org header.s=google header.b=gTqXfTfz; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231679AbiKOR3E (ORCPT + 99 others); Tue, 15 Nov 2022 12:29:04 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:59622 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231779AbiKOR2m (ORCPT ); Tue, 15 Nov 2022 12:28:42 -0500 Received: from mail-lf1-x132.google.com (mail-lf1-x132.google.com [IPv6:2a00:1450:4864:20::132]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4B06927CE8 for ; Tue, 15 Nov 2022 09:28:40 -0800 (PST) Received: by mail-lf1-x132.google.com with SMTP id s8so8383590lfc.8 for ; Tue, 15 Nov 2022 09:28:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=qnzzFvDnrUNiU88yEZt6sQdtp0kEECaqorraO0GqvxU=; b=gTqXfTfz1AawXgaddIVtPqg4+pkukv3DqH6QpxMlqCBS05LIvP+2dQ4b6OMEevO4kA FHj86IBdobrG3d5IdXt/+3TCHAqqGWj7BmXM4FluMRmhulHmbEe5m0nXfF6h4N6N0+3n znqac4WQsqsJdf44MkWe6m4u5H+yNPTs63KaTASt2BnjxAZq/98zjcYD8Al4EFI54bEU QqtUy4uUBwj4NKrABJcJqUAW+u4RH3y95bTU2KY9/wJr8NkScoBaNXb7FrgeRbGujFTf mtDvGyealO5gkDiuH5wrlXwrTfAJbO+wzBFX9fYvNonCrOQYraxjuRY14Zkz3nz+ld+n lMJw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=qnzzFvDnrUNiU88yEZt6sQdtp0kEECaqorraO0GqvxU=; b=vT0xhz6nvEnfXxHOXjtZNozQQdk18tCiSwXAfVBpu8CHOrng3itLAC0j9W7yDrnQk/ R3gps06uHwNrkLILCrCz+B2dXL3UJveg2nvjN5uI2NhL7fmbDeBRdqi6x0bOUybU5+As 2BIK30fOJ3sXqQ94bhI2UR9n+DuXWwizbPGFjh8AaBYaDdnPSDf3krLrZ8ZABymmwpwp 8sb04WUT5QVnhyftca7JbIJcEAANAwt/IH31U55sfb4TZAZbieQYw0ky/DlcYvpXoTZm 1HYV5UDqooy6dfz2Ql4qPUngsmPvSJgM7jxwQ4D7zN0GWvShTvZHScZIeVi0YhZ4tKPV 1fAw== X-Gm-Message-State: ANoB5pk4qWak9PjD5AZOzhx3LISpwfMMrP2H6sMXSEctiWMk/4qKcEPi AwP55wTvwFERzJMKc7+lRog6sQ== X-Received: by 2002:a05:6512:3c8e:b0:4a0:5393:3749 with SMTP id h14-20020a0565123c8e00b004a053933749mr6050082lfv.494.1668533319861; Tue, 15 Nov 2022 09:28:39 -0800 (PST) Received: from localhost.localdomain ([194.29.137.22]) by smtp.gmail.com with ESMTPSA id b42-20020a0565120baa00b00496d3e6b131sm2261511lfv.234.2022.11.15.09.28.38 (version=TLS1_3 cipher=TLS_CHACHA20_POLY1305_SHA256 bits=256/256); Tue, 15 Nov 2022 09:28:39 -0800 (PST) From: Konrad Dybcio To: linux-arm-msm@vger.kernel.org, andersson@kernel.org, agross@kernel.org, krzysztof.kozlowski@linaro.org Cc: patches@linaro.org, Konrad Dybcio , Ulf Hansson , Rob Herring , Krzysztof Kozlowski , Bhupesh Sharma , linux-mmc@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, Konrad Dybcio Subject: [PATCH 4/4] arm64: dts: qcom: sm8350-sagami: Wire up SDHCI2 Date: Tue, 15 Nov 2022 18:28:28 +0100 Message-Id: <20221115172828.14372-4-konrad.dybcio@linaro.org> X-Mailer: git-send-email 2.32.0 (Apple Git-132) In-Reply-To: <20221115172828.14372-1-konrad.dybcio@linaro.org> References: <20221115172828.14372-1-konrad.dybcio@linaro.org> MIME-Version: 1.0 X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS 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?1749584557696911891?= X-GMAIL-MSGID: =?utf-8?q?1749584557696911891?= Adjust regulators, add required pin setup and finally enable SDHCI2 to get the SD Card slot going on Sagami Xperias. Signed-off-by: Konrad Dybcio --- .../dts/qcom/sm8350-sony-xperia-sagami.dtsi | 30 ++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/qcom/sm8350-sony-xperia-sagami.dtsi b/arch/arm64/boot/dts/qcom/sm8350-sony-xperia-sagami.dtsi index a428ce31ab4e..fdf95b763cf4 100644 --- a/arch/arm64/boot/dts/qcom/sm8350-sony-xperia-sagami.dtsi +++ b/arch/arm64/boot/dts/qcom/sm8350-sony-xperia-sagami.dtsi @@ -312,7 +312,8 @@ pm8350c_l8: ldo8 { pm8350c_l9: ldo9 { regulator-name = "pm8350c_l9"; regulator-min-microvolt = <2960000>; - regulator-max-microvolt = <3008000>; + /* Originally max = 3008000 but SDHCI expects 2960000 */ + regulator-max-microvolt = <2960000>; regulator-initial-mode = ; }; @@ -558,6 +559,19 @@ &qupv3_id_2 { status = "okay"; }; +&sdhc_2 { + cd-gpios = <&tlmm 92 GPIO_ACTIVE_HIGH>; + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&sdc2_default_state &sdc2_card_det_active>; + pinctrl-1 = <&sdc2_sleep_state &sdc2_card_det_sleep>; + vmmc-supply = <&pm8350c_l9>; + vqmmc-supply = <&pm8350c_l6>; + no-sdio; + no-mmc; + status = "okay"; +}; + + &slpi { status = "okay"; firmware-name = "qcom/sm8350/Sony/sagami/slpi.mbn"; @@ -782,6 +796,20 @@ ts_int_default: ts-int-default-state { bias-disable; input-enable; }; + + sdc2_card_det_active: sd-card-det-active-state { + pins = "gpio92"; + function = "gpio"; + drive-strength = <2>; + bias-pull-up; + }; + + sdc2_card_det_sleep: sd-card-det-sleep-state { + pins = "gpio92"; + function = "gpio"; + drive-strength = <2>; + bias-disable; + }; }; /* BIG WARNING! DO NOT TOUCH UFS, YOUR DEVICE WILL DIE! */