From mboxrd@z Thu Jan 1 00:00:00 1970 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 44147C79F80 for ; Fri, 4 Sep 2026 08:44:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From: Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=7ZE0hpHw4voLLfSdVdvFiuLaZ8hcT2SD2vYw6zXNC1k=; b=qKciJgV6nr6DCYX7bUuSsuqjzd 3yTbRjKvk7W7ZeAzFKRJqFKrIcyM6Hj/o5NNnwI5Khz6qifUY4vnppBLyqrTN+U+SJblWcAbtyoIx xgr8OKCAYi0HHArPn8GEVuWO+vuAMwv6N4GDYYOHlpdzY18nbZ90nGpXK6558bofB1Wrl0szXGclW 05y5jJT7ep7Kzk6t+vO1BGYWpBwgDvbmInqrf1U1FLbudLyi2jOGcIgnhK3bhVyHGDRTK25owxymy MZH8WKYcKCzB/FzKN0RCTltIVvQ7kO1ZVx2kjvZx2MmbdvRqpE5u/6wkiSTLn38qYPi2kZdyB42XC Q0gB606A==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.99.1 #2 (Red Hat Linux)) id 1x2PXT-00000001R10-2J6C; Fri, 04 Sep 2026 08:44:47 +0000 Received: from mail-pl1-x635.google.com ([2607:f8b0:4864:20::635]) by bombadil.infradead.org with esmtps (Exim 4.99.1 #2 (Red Hat Linux)) id 1x2PXQ-00000001QxB-2hHU for linux-arm-kernel@lists.infradead.org; Fri, 04 Sep 2026 08:44:46 +0000 Received: by mail-pl1-x635.google.com with SMTP id d9443c01a7336-2ceab75934dso7388015ad.2 for ; Fri, 04 Sep 2026 01:44:44 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1788511484; x=1789116284; darn=lists.infradead.org; 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:content-type; bh=7ZE0hpHw4voLLfSdVdvFiuLaZ8hcT2SD2vYw6zXNC1k=; b=Fp9nMwkLhYsIGd8S32TI65rgIg9GyZL0NXAn3QLZkPtLFQUO5vapykZa4ovs53DeIU K2mfKSLvJwveZqfSGF6adsNf7QbnGShCMVsPGDsKMKaLPy+cANjiaj0wWN8bNSISdsF1 iBs2WR5AwQ2zMBHjrH5XJSwmUr7sBCuCFrvxA= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1788511484; x=1789116284; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to:content-type; bh=7ZE0hpHw4voLLfSdVdvFiuLaZ8hcT2SD2vYw6zXNC1k=; b=m70k+VJ9An4mOyReEWP5yFcTr1RCLVdC568TiBVcG1DHVYf/0bnuStxr3aipdpqCb0 HR09XiuDj5CKNQYIDL2cQEHUvb1b2DgRJY3eAensP+0eZ5Yap+4RxAITiAVutWDm6Q55 Q5l4YM7ARgPbRwKOYEsxa4UJhH/8enuoXpWR8sZtPX7ua8zw5MdWrKUU9PKAvhmtaapU KqI6Fn4jzLT0vG1rWTC/9KEPzPV9xqKKCj+H1LBW9ANLIIC2WFnutI2nk3hQlRhNmfYV 5S3rmCD+ngUTK4kthjgm7aX3JpvlXid4Ycg2rGJJ4zPhtdsyC1xYz++sEwMrwJvtWYGY 3Jmw== X-Forwarded-Encrypted: i=1; AKwUvBwUt2hAIz6Yy0OEjIgyxxbiD11+EGYpjuQUDWx9ZoA2+kfQ0uOWtUbPmamCyFGPewrUNEbsy8KVK8ZfotP5lEv7@lists.infradead.org X-Gm-Message-State: AFuF++krlYguoiMuNveCAfxDlUlS6sHZd0A6/vIjRm/7ortPsDshjxat AlGjUeUnAiVKQJNsoZenRD2gycGy8qbEq9Vzi/boaGDOpvPK03o5rwI5yVPrSD4Yvw== X-Gm-Gg: AYBFou3Mdbn4lRuZwDp0FMARSDfEqxGLH68D2E4IegmkIitK8njJrRLOdv5/WpBWfAj 8Trj1/fYEodGVz5iuzdL3i6L9MVP/Zu5a2sYA2jmjcVU89BTvdi1Rk2dXIUJI50tjoY3VSQFwI1 IyK9df1kc7yzd65xh+YPveSWR0O19ZVhaPT0EPTJUtIhR554yToSPE9hL0kvT/brzyvLPsymTcl apNAWrPzMMMAKg+/dAB1iIgbjo4i0Q/WLyeqWtSf7XD+VeGVWeSuiHylTVuMgS8o9q8R54Nmsaf 0/HNuD8BkSoT07ZEqweXSp3D0F28+QuKdHApDzcd8gcQVUmQv4AUfoflpBN4gG7cleCQw3SzZxT Lp99szXk/jNcIVnnBykGvjMFznP5FLw89aSwh2ABUcl6WFMmGYeoFe+EBbwOIri/0FvKVnTfk/H VqLN60T6wa31Y+cKZjyxonkjyArSLe5EmetwNNjUZGAtehBH3aUlh4QJaLMwJ6Hu17r+xoLFNeo 77vpPC/C2iVytCrLGK/oPTs4O82NDUxwdpl6wbVzFVU X-Received: by 2002:a17:90b:1c8b:b0:398:9bd5:490c with SMTP id 98e67ed59e1d1-39b26214502mr5922699a91.19.1788511483659; Fri, 04 Sep 2026 01:44:43 -0700 (PDT) Received: from wenst-7875.tpe.corp.google.com ([2a00:79e0:201d:8:343:bf21:3095:9c5]) by smtp.gmail.com with ESMTPSA id 98e67ed59e1d1-39b260fdf9asm3343538a91.9.2026.09.04.01.44.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 04 Sep 2026 01:44:43 -0700 (PDT) From: Chen-Yu Tsai To: Bartosz Golaszewski , Greg Kroah-Hartman , Andy Shevchenko , Daniel Scally , Heikki Krogerus , Sakari Ailus , "Rafael J. Wysocki" , Danilo Krummrich , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Matthias Brugger , AngeloGioacchino Del Regno Cc: Wei Deng , Konrad Dybcio , Chen-Yu Tsai , linux-acpi@vger.kernel.org, driver-core@lists.linux.dev, linux-pm@vger.kernel.org, linux-usb@vger.kernel.org, devicetree@vger.kernel.org, linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Manivannan Sadhasivam , Alan Stern , Bartosz Golaszewski Subject: [PATCH v8 16/16] arm64: dts: mediatek: mt8188-geralt: Add WiFi/BT as M.2 E-key slot Date: Fri, 4 Sep 2026 16:41:55 +0800 Message-ID: <20260904084158.1341550-17-wenst@chromium.org> X-Mailer: git-send-email 2.55.0.979.g7e5102b832-goog In-Reply-To: <20260904084158.1341550-1-wenst@chromium.org> References: <20260904084158.1341550-1-wenst@chromium.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.9.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20260904_014445_209619_866E2CA9 X-CRM114-Status: GOOD ( 17.93 ) 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 The MT8188 Geralt design features a chip-on-board WiFi/BT solution. This is a M.2 E-key WiFi/BT board layout directly inserted into the mainboard design. The connections to the rest of the board are almost the same as if it were a separate M.2 card. The only addition is the PMU_EN pin on the chip; on M.2 cards this would be tied to the primary power source. Model the chip-on-board WiFi/BT solution as a M.2 E-key slot with PCIe, USB and auxiliary signals. The PMU_EN pin, which enables the internal power controls and regulators, is modeled as a regulator fed by the pp3300_wlan regulator. Since power sequencing is now correctly modeled using the M.2 E-key slot, drop the "regulator-always-on" property one pp3300_wlan regulator. Also drop the comment in xhci2 saying "MT7921's power is controlled by PCIe". Also drop the voltage range on the pp3300_wlan regulator. This "regulator" is just a load switch and does not provide any regulation. Reviewed-by: Bartosz Golaszewski Signed-off-by: Chen-Yu Tsai --- Changes since v2: - Drop default GPIO output state from kill pins pinconfig --- .../boot/dts/mediatek/mt8188-geralt.dtsi | 92 ++++++++++++++++++- 1 file changed, 88 insertions(+), 4 deletions(-) diff --git a/arch/arm64/boot/dts/mediatek/mt8188-geralt.dtsi b/arch/arm64/boot/dts/mediatek/mt8188-geralt.dtsi index dee946309121..73b5c0fdeae6 100644 --- a/arch/arm64/boot/dts/mediatek/mt8188-geralt.dtsi +++ b/arch/arm64/boot/dts/mediatek/mt8188-geralt.dtsi @@ -88,13 +88,11 @@ pp3300_z1: regulator-pp3300-z1 { pp3300_wlan: regulator-pp3300-wlan { compatible = "regulator-fixed"; regulator-name = "pp3300_wlan"; - regulator-always-on; - regulator-min-microvolt = <3300000>; - regulator-max-microvolt = <3300000>; enable-active-high; gpio = <&pio 12 GPIO_ACTIVE_HIGH>; pinctrl-0 = <&wlan_en>; pinctrl-names = "default"; + /* load switch */ vin-supply = <&pp3300_z1>; }; @@ -161,6 +159,17 @@ ppvar_mipi_disp_avee: regulator-ppvar-mipi-disp-avee { vin-supply = <&pp5000_z1>; }; + /* PMU_EN pin controls internal regulators and power sequence */ + wlan_pmu: regulator-wlan-pmu { + compatible = "regulator-fixed"; + regulator-name = "wlan-pmu"; + enable-active-high; + gpio = <&pio 145 GPIO_ACTIVE_HIGH>; + pinctrl-0 = <&wlan_pmu_en>; + pinctrl-names = "default"; + vin-supply = <&pp3300_wlan>; + }; + reserved_memory: reserved-memory { #address-cells = <2>; #size-cells = <2>; @@ -195,6 +204,39 @@ adsp_dma_mem: memory@61000000 { no-map; }; }; + + wifi-bt-connector { + compatible = "pcie-m2-e-connector"; + pinctrl-names = "default"; + pinctrl-0 = <&m2_e_key_kill_pins>; + vpcie1v8-supply = <&mt6359_vcn18_ldo_reg>; + vpcie3v3-supply = <&wlan_pmu>; + w-disable1-gpios = <&pio 13 GPIO_ACTIVE_LOW>; + w-disable2-gpios = <&pio 14 GPIO_ACTIVE_LOW>; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + /* PCIe for WiFi */ + port@0 { + reg = <0>; + + wifi_ep: endpoint { + remote-endpoint = <&pcie_ep>; + }; + }; + + /* USB for Bluetooth */ + port@2 { + reg = <2>; + + bt_ep: endpoint { + remote-endpoint = <&usb2_ep>; + }; + }; + }; + }; }; &adsp { @@ -659,6 +701,22 @@ &pcie { pinctrl-names = "default"; pinctrl-0 = <&pcie_pins>; status = "okay"; + + pcie@0 { + compatible = "pciclass,0604"; + reg = <0 0 0 0 0>; + device_type = "pci"; + num-lanes = <1>; + #address-cells = <3>; + #size-cells = <2>; + ranges; + + port { + pcie_ep: endpoint { + remote-endpoint = <&wifi_ep>; + }; + }; + }; }; &pciephy { @@ -1002,6 +1060,13 @@ pins-bus { }; }; + m2_e_key_kill_pins: m2-e-key-kill-pins { + pins-kill { + pinmux = , + ; + }; + }; + mipi_disp_avdd_en: mipi-disp-avdd-en-pins { pins-en-ppvar-mipi-disp { pinmux = ; @@ -1174,6 +1239,13 @@ pins-bus { }; }; + wlan_pmu_en: wlan-pmu-en-pins { + pins-wlan-pmu-en { + pinmux = ; + output-low; + }; + }; + wlan_en: wlan-en-pins { pins-en-pp3300-wlan { pinmux = ; @@ -1417,10 +1489,22 @@ vdosys1_ep_ext: endpoint@1 { }; &xhci2 { - /* no power supply since MT7921's power is controlled by PCIe */ /* MT7921's USB BT has issues with USB2 LPM */ usb2-lpm-disable; status = "okay"; + + ports { + #address-cells = <1>; + #size-cells = <0>; + + port@1 { + reg = <1>; + + usb2_ep: endpoint { + remote-endpoint = <&bt_ep>; + }; + }; + }; }; #include -- 2.55.0.979.g7e5102b832-goog