From patchwork Fri Jan 6 14:31:11 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Lin, Meng-Bo" X-Patchwork-Id: 639741 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6593CC54EF0 for ; Fri, 6 Jan 2023 14:32:30 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234002AbjAFOcA (ORCPT ); Fri, 6 Jan 2023 09:32:00 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37404 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234134AbjAFOb3 (ORCPT ); Fri, 6 Jan 2023 09:31:29 -0500 Received: from mail-40132.protonmail.ch (mail-40132.protonmail.ch [185.70.40.132]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7119680AC3; Fri, 6 Jan 2023 06:31:20 -0800 (PST) Date: Fri, 06 Jan 2023 14:31:11 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail3; t=1673015478; x=1673274678; bh=zwgxDtrvvsnKx3WwIiMDTQ8qwPQosXJZ2V7U0l4c1eg=; h=Date:To:From:Cc:Subject:Message-ID:In-Reply-To:References: Feedback-ID:From:To:Cc:Date:Subject:Reply-To:Feedback-ID: Message-ID:BIMI-Selector; b=kR4wRpqtPRneXInVTW1WRLYAwKN3zaJ8PjaTKTTL6DUL4lToK8fHTZ7oUHqMobIfw aO2D6qvOGUiz1YMm7MNWdXP7MrsaNWx8cLC9cWWocG20JpKAfqUhCo+bh8ChUtl32l hkiwW2JszoAATrIth6JSTeDzl8dPBYVwQTV+VspeZzHq/FavrKVwqC9oTXAYYwmaGc HIqeawU051Z+Ib5EnRWf+WEwWKJPBTIz9rk/cLbauksrhwnplOeVEg26n6kQ0T9Y2K RSkNf4fos+IcrX270MZciNChFrj6rVwo5rCqVuW1aoPU3i172UX0R/lnTAlK8lltf4 jI7tQj9kBxYpA== To: devicetree@vger.kernel.org From: "Lin, Meng-Bo" Cc: Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , Stephan Gerhold , Nikita Travkin , Julian Ribbeck , Josef W Menad , Markuss Broks , linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, ~postmarketos/upstreaming@lists.sr.ht, Krzysztof Kozlowski Subject: [PATCH v6 2/5] arm64: dts: qcom: msm8916-samsung-j5-common: Add initial common device tree Message-ID: <20230106143010.547140-1-linmengbo0689@protonmail.com> In-Reply-To: <20230106142748.546975-1-linmengbo0689@protonmail.com> References: <20230106142748.546975-1-linmengbo0689@protonmail.com> Feedback-ID: 40467236:user:proton MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org The smartphones below are using the MSM8916 SoC, which are released in 2015-2016: Samsung Galaxy J5 2015 (SM-J500*) Samsung Galaxy J5 2016 (SM-J510*) Move msm8916-samsung-j5.dts to msm8916-samsung-j5-common.dtsi, and add a common device tree for with initial support for: - GPIO keys - SDHCI (internal and external storage) - USB Device Mode - UART (on USB connector via the SM5703 MUIC) - WCNSS (WiFi/BT) - Regulators The two devices (all other variants of J5 released in 2015 and J5X released in 2016) are very similar, with some differences in display and GPIO pins. The common parts are shared in msm8916-samsung-j5-common.dtsi to reduce duplication. This patch rewrites J5 2015 devices, later patches will add support for other models. Signed-off-by: Lin, Meng-Bo Acked-by: Krzysztof Kozlowski --- ...-j5.dts => msm8916-samsung-j5-common.dtsi} | 7 - .../boot/dts/qcom/msm8916-samsung-j5.dts | 224 ++---------------- 2 files changed, 15 insertions(+), 216 deletions(-) copy arch/arm64/boot/dts/qcom/{msm8916-samsung-j5.dts => msm8916-samsung-j5-common.dtsi} (95%) rewrite arch/arm64/boot/dts/qcom/msm8916-samsung-j5.dts (93%) +++ b/arch/arm64/boot/dts/qcom/msm8916-samsung-j5.dts @@ -?,? +1,15 @@ +// SPDX-License-Identifier: GPL-2.0-only + +/dts-v1/; + +#include "msm8916-samsung-j5-common.dtsi" + +/ { + model = "Samsung Galaxy J5 (2015)"; + compatible = "samsung,j5", "qcom,msm8916"; + chassis-type = "handset"; +}; + +&usb_hs_phy { + qcom,init-seq = /bits/ 8 <0x1 0x19 0x2 0x0b>; +}; diff --git a/arch/arm64/boot/dts/qcom/msm8916-samsung-j5.dts b/arch/arm64/boot/dts/qcom/msm8916-samsung-j5-common.dtsi similarity index 95% copy from arch/arm64/boot/dts/qcom/msm8916-samsung-j5.dts copy to arch/arm64/boot/dts/qcom/msm8916-samsung-j5-common.dtsi index 7ac49a021563..502b38d4a61e 100644 --- a/arch/arm64/boot/dts/qcom/msm8916-samsung-j5.dts +++ b/arch/arm64/boot/dts/qcom/msm8916-samsung-j5-common.dtsi @@ -1,15 +1,9 @@ // SPDX-License-Identifier: GPL-2.0-only -/dts-v1/; - #include "msm8916-pm8916.dtsi" #include / { - model = "Samsung Galaxy J5 (2015)"; - compatible = "samsung,j5", "qcom,msm8916"; - chassis-type = "handset"; - aliases { serial0 = &blsp1_uart2; }; @@ -92,7 +86,6 @@ &usb { &usb_hs_phy { extcon = <&pm8916_usbin>; - qcom,init-seq = /bits/ 8 <0x1 0x19 0x2 0x0b>; }; &smd_rpm_regulators { diff --git a/arch/arm64/boot/dts/qcom/msm8916-samsung-j5.dts b/arch/arm64/boot/dts/qcom/msm8916-samsung-j5.dts dissimilarity index 93% index 7ac49a021563..0a32d33e9778 100644 --- a/arch/arm64/boot/dts/qcom/msm8916-samsung-j5.dts