From patchwork Thu Sep 5 09:07:02 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: Alexandre Mergnat X-Patchwork-Id: 13791999 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 37204CD4F5F for ; Thu, 5 Sep 2024 09:14:04 +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:Cc:To:In-Reply-To:References :Message-Id:Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date: From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=amEp3d9dA2kLes/bKsPMBk46Liy76YOCyltVKKQIsdk=; b=lqD1mnxnK5Aotae7HaY6nzyNvo FwM9PC4KB8nbvr8kkIdT7MGdSFp6PWa0jk72Xd4rxU+Pm0+QJdR0GCNPLUWGb4kIztCVehBDRoDka dWhyWmn+95bVeTUEE2kk8s3E8bN9xcT+L0VXpYfMvqtqmpgBRNZq3fbL8bkOdOBxNV4L2DNtOjy+5 AeST/HU/73PwkZgBs4/gorWVNEY8vAaNBVJDGJ7vDAjDOb2iicY3UXssHc5ikJ+rT9zDNEg88Qpho Oh6iQABdJVDM2uEzKYYot/j5Zc3rKlEccvFXQwR2tzVVErFfUtoBchYSHmsOPmNAumK8lniqdjAkX 8Scq2EIw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1sm8Yq-00000007iBV-3tcs; Thu, 05 Sep 2024 09:13:52 +0000 Received: from mail-lf1-x12d.google.com ([2a00:1450:4864:20::12d]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1sm8T5-00000007gpK-2zyc for linux-arm-kernel@lists.infradead.org; Thu, 05 Sep 2024 09:07:56 +0000 Received: by mail-lf1-x12d.google.com with SMTP id 2adb3069b0e04-5353d0b7463so756100e87.3 for ; Thu, 05 Sep 2024 02:07:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1725527274; x=1726132074; darn=lists.infradead.org; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=amEp3d9dA2kLes/bKsPMBk46Liy76YOCyltVKKQIsdk=; b=bJIC6QhyNWsUFujcucpTQ1Uksp842rQ9e45vM4BCU/tUhb3ZLbk0Te+hRgVo0Gw98h YhkbyiW24zc4VaSw3VSeS/fo/aE0cV0B4oLM1jw5KoeUMgJmcwqVmkZrqeVhtL9lTu36 8R54/bOX3S9HHoxIyCiLhcXSHlqrBE4qSZ0Zc79VxLiurqKMJ75GRKaLmaIFJgI9SlK3 5Xd/QGSfsrFaNx6pHZtP66YSO/E9xgXlumxmtTL/6XElcjnJMEfNsyKqwhElwqQ5d+bb LHtT+eGyqqxZEmgj2IyUFO9eYpeezG5roAJ8DybQDlEKRfNoRV2HUfNrLi3bthRu2jBG MHQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1725527274; x=1726132074; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=amEp3d9dA2kLes/bKsPMBk46Liy76YOCyltVKKQIsdk=; b=dubZydKr+qDViLennD3CCcEIhQLeqdhO2Yg2YXbDCPLtbdrMLFdhn8EbtDEwLAZ7ys KjefG+9F9kVGSbydZioy10cjgBCrd8N/AEJLp3moWcSVYEw9toaaF3OanRHviZU3ApiW PBF3UuK7N8A8/8ozxYtj5a1X3Q0DxJ5ULkHpthaxgO7Y972HiBrv7rRY4sHWIXQAYPT7 4G6gVht80eLcrGD9LRAdejIOLaZeM/6YKuf8AvhxFuVydzfNnRgY/C/PAjeL1trKqBki tqJKGyKD/vwQN+8T9KSwvfPudc51LzVABjna25ou9enj6NGdFyK6rJLJvzurOEYS7pkf 2P5g== X-Forwarded-Encrypted: i=1; AJvYcCUV+sAZmWodyfz99xB6maatmFgiefws8w9BY3JGWNNM2NdGuekVBJfNQWuYdQ50D2DrQMW/DxpjS8Y6wbn2Drt7@lists.infradead.org X-Gm-Message-State: AOJu0YwLfRMRtsm8UUYoHstCCBnbdseY8UOYCNzxJnPB5OF6zZ9tsUsk 2qOY/icW9Z9JshwqnHzV0R15Kmu1bZKbp7g8RzXLd+wGpXIHO9RViBe8iaFDfwI= X-Google-Smtp-Source: AGHT+IEXxv3v/7gChECZyOGuQolflyMIMwnjLiTaBnwFPxxgLEbat0KiTCUHf92EE0SVtscCFlRltg== X-Received: by 2002:a05:6512:1593:b0:536:53e3:feae with SMTP id 2adb3069b0e04-53653e400aamr788908e87.11.1725527259850; Thu, 05 Sep 2024 02:07:39 -0700 (PDT) Received: from [127.0.1.1] (88-127-185-239.subs.proxad.net. [88.127.185.239]) by smtp.googlemail.com with ESMTPSA id 2adb3069b0e04-535406e5549sm2554188e87.0.2024.09.05.02.07.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 05 Sep 2024 02:07:39 -0700 (PDT) From: Alexandre Mergnat Date: Thu, 05 Sep 2024 11:07:02 +0200 Subject: [PATCH v8 5/5] arm64: dts: mediatek: add audio support for mt8365-evk MIME-Version: 1.0 Message-Id: <20240226-audio-i350-v8-5-e80a57d026ce@baylibre.com> References: <20240226-audio-i350-v8-0-e80a57d026ce@baylibre.com> In-Reply-To: <20240226-audio-i350-v8-0-e80a57d026ce@baylibre.com> To: Liam Girdwood , Mark Brown , Jaroslav Kysela , Takashi Iwai , Matthias Brugger , AngeloGioacchino Del Regno , Catalin Marinas , Will Deacon , Rob Herring , Krzysztof Kozlowski , Conor Dooley Cc: linux-kernel@vger.kernel.org, linux-sound@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, devicetree@vger.kernel.org, Alexandre Mergnat X-Mailer: b4 0.12.2 X-Developer-Signature: v=1; a=openpgp-sha256; l=3691; i=amergnat@baylibre.com; h=from:subject:message-id; bh=FIwNsi2/7C6h+hTUlPdOVAIygtslJZRWw1saG4r7H9A=; b=owEBbQKS/ZANAwAKAStGSZ1+MdRFAcsmYgBm2XTORpSVxJ3WbTSdgdCVCYCnTzKrNLC1U02Hx9yO uJ38TEmJAjMEAAEKAB0WIQQjG17X8+qqcA5g/osrRkmdfjHURQUCZtl0zgAKCRArRkmdfjHURdtGD/ 9QPgfVxIgAgeB4+Wq1OA6v2H1AeKw1PS2HUIJjwj/wYkXZehlBvs+xePlZPiQN4/TRR/CVjAhWCkoF zf51VPxBZ/lp90Dlugv+8vp32PrpJfmS9WD6aB2RYg5jbnUbOWEa8KsDi47EXIP4Y27TFLQvFzTY0Y h12/eeBEo2b8MyIt3ILEv+HCALp5gKledvonGxIt+6fmZETN6LrhyW0SPp2Bq5hvO2TvoDUz18ZfG9 2KPqWUU8fwjIYzJF+Jg/23G/lZwab/DXH7rXBMbq6dP4GW7gFNd9tyMrButbSQc2FqKiFuzJoaZw53 MV92eRMwEItx4bC3iF2lNyOO0vvYyuNIfQM2+RFZ1X9kS+pKt8YsX7bnFmFn8YBibxBomvFh3EP0PK BpDDxSwd8W8SjrqfTqwpZh/97bbv0GzRXLTGPKvthkIenQraunMIjpU6Vx8WRODrliBlqdANnw7xT+ YLvteJ2EOAkVtcJIAnOis3y7NhfCDtnngmHCksnkzcnywYKKjPJdOx0lzfL/o8w7OsSwT1vYlP8MUo xeDkui005HYUMjGbc+pT9IujVhpu555SYHNYKx+w1A4RISxic4hSUcmu7p+/3MNpBGt1H6LjmZCAqH 2ux5hGjZYZBJcaBojKfPHEMr3myzjvFPFynmx2GmmKXusBFk9GzAOOCndFrw== X-Developer-Key: i=amergnat@baylibre.com; a=openpgp; fpr=231B5ED7F3EAAA700E60FE8B2B46499D7E31D445 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240905_020755_763635_4E1ECA26 X-CRM114-Status: GOOD ( 11.89 ) 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 Add the sound node which is linked to the MT8365 SoC AFE and the MT6357 audio codec. Update the file header. Reviewed-by: AngeloGioacchino Del Regno Signed-off-by: Alexandre Mergnat --- arch/arm64/boot/dts/mediatek/mt8365-evk.dts | 86 +++++++++++++++++++++++++++++ 1 file changed, 86 insertions(+) diff --git a/arch/arm64/boot/dts/mediatek/mt8365-evk.dts b/arch/arm64/boot/dts/mediatek/mt8365-evk.dts index 4211a992dd9d..7d90112a7e27 100644 --- a/arch/arm64/boot/dts/mediatek/mt8365-evk.dts +++ b/arch/arm64/boot/dts/mediatek/mt8365-evk.dts @@ -4,6 +4,7 @@ * Authors: * Fabien Parent * Bernhard Rosenkränzer + * Alexandre Mergnat */ /dts-v1/; @@ -86,6 +87,28 @@ optee_reserved: optee@43200000 { reg = <0 0x43200000 0 0x00c00000>; }; }; + + sound: sound { + compatible = "mediatek,mt8365-mt6357"; + pinctrl-names = "default", + "dmic", + "miso_off", + "miso_on", + "mosi_off", + "mosi_on"; + pinctrl-0 = <&aud_default_pins>; + pinctrl-1 = <&aud_dmic_pins>; + pinctrl-2 = <&aud_miso_off_pins>; + pinctrl-3 = <&aud_miso_on_pins>; + pinctrl-4 = <&aud_mosi_off_pins>; + pinctrl-5 = <&aud_mosi_on_pins>; + mediatek,platform = <&afe>; + }; +}; + +&afe { + mediatek,dmic-mode = <1>; + status = "okay"; }; &cpu0 { @@ -178,9 +201,72 @@ &mt6357_pmic { interrupts-extended = <&pio 145 IRQ_TYPE_LEVEL_HIGH>; interrupt-controller; #interrupt-cells = <2>; + mediatek,micbias0-microvolt = <1900000>; + mediatek,micbias1-microvolt = <1700000>; }; &pio { + aud_default_pins: audiodefault-pins { + clk-dat-pins { + pinmux = , + , + , + ; + }; + }; + + aud_dmic_pins: audiodmic-pins { + clk-dat-pins { + pinmux = , + , + ; + }; + }; + + aud_miso_off_pins: misooff-pins { + clk-dat-pins { + pinmux = , + , + , + ; + input-enable; + bias-pull-down; + drive-strength = <2>; + }; + }; + + aud_miso_on_pins: misoon-pins { + clk-dat-pins { + pinmux = , + , + , + ; + drive-strength = <6>; + }; + }; + + aud_mosi_off_pins: mosioff-pins { + clk-dat-pins { + pinmux = , + , + , + ; + input-enable; + bias-pull-down; + drive-strength = <2>; + }; + }; + + aud_mosi_on_pins: mosion-pins { + clk-dat-pins { + pinmux = , + , + , + ; + drive-strength = <6>; + }; + }; + ethernet_pins: ethernet-pins { phy_reset_pins { pinmux = ;