Received: by 2002:ab2:3350:0:b0:1f4:6588:b3a7 with SMTP id o16csp1915800lqe; Tue, 9 Apr 2024 04:39:32 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCU+icJCoHCUfNzeom97e9FeppKtpBzfYQ4ZYwDH3Q/xMlnQJ8wx9QhxoSdvYS77W0HSivYjoajNAhaLb7EgrjucO9fG2B78/uIf0bgQsw== X-Google-Smtp-Source: AGHT+IFy9RKOHEoZQ+NvVmXWOlHKR6rB3NtKvrZbmoNSeSOY9pTyd1TAessACOZPuHcw1aCRPoSl X-Received: by 2002:a17:907:9693:b0:a51:b1b7:3c07 with SMTP id hd19-20020a170907969300b00a51b1b73c07mr8899334ejc.19.1712662772268; Tue, 09 Apr 2024 04:39:32 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712662772; cv=pass; d=google.com; s=arc-20160816; b=hOcbLl6fE6gSqHTz5PrlZ2R0vy0CowSgIBiLP/8Tv5/HlpYjf1/N9KOl+XT5uidX1P RJZTmvM91/ul0WmMCcfRECx7bZiulph8nogt5QLUCDxe+qt8s7SnHTMoLqOXlBgCWNMI Ph/YSxTnihVkQJiG433G+zlXII9LLgkZqvoNOV+/aHYzAjCP4oefKLbTJxabT1VBsRNq pl8QP2REMDkWuHTipNST02YOWhKNLukrPkdiZ3z7JW7XuHLU1c1m4nkd3El8HiaGqYrX B+rffX/vnLgl7UsP2M9dVQk3POWtIt6fI9Ia9CRGhY/5DYnYOYqMiWTgiJpz2plm+R5l X/uQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=y7q83q+bA/QUBBbTmOc7VvdxAdgRHVRRKuHg6XBb3wQ=; fh=9iEt4iCRn9CzCxci4w2sdEG90CBf9Xi5ef9RsAZByLs=; b=HhoJyIgdiCrqV1WxtNmdx7om0StKLu3xxXkSOBHrb4lb6Q8u+BCciZT+xGYnjY2ggJ Qhq81Vcn0mGtw0VPitIstDh5vMb+z2Tesg2r587t9jlTfC+oiaU3UeRQTE9faqOkoS2K m5fikVWGRPgc9a2CJCYUxdlKcQozGLER9B+kUtJz9lCmvzZn2q/9yCE5tL8Ua1KzK7GC txAAUo57aTXH5ZHsP7FTb7A+1yetGA53HqfDv8IwBHNQ2+xsugsoKJYnUcN/i1wB1NH7 7ljKp3X+5ZMTpgpBxr827oJ97l6sO0jwnlPEgpEhMlz+Y6dfZ2emhulQb/eN6RXoM6lC r3Lw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=ce2Cd4mC; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-136788-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-136788-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id l8-20020a170906414800b00a5198d85cbfsi4526855ejk.403.2024.04.09.04.39.32 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 09 Apr 2024 04:39:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-136788-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=ce2Cd4mC; arc=pass (i=1 spf=pass spfdomain=collabora.com dkim=pass dkdomain=collabora.com dmarc=pass fromdomain=collabora.com); spf=pass (google.com: domain of linux-kernel+bounces-136788-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-136788-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 074181F209B4 for ; Tue, 9 Apr 2024 11:39:32 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 847DF136677; Tue, 9 Apr 2024 11:34:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b="ce2Cd4mC" Received: from madrid.collaboradmins.com (madrid.collaboradmins.com [46.235.227.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1ED82135A54; Tue, 9 Apr 2024 11:34:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=46.235.227.194 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712662453; cv=none; b=K9Iw6rq99/kx184nYgoBJD076ZJ8Mt1Zk4ixSMvOkPnzmy2wWsWWwU+UgK1IXao9lcBPjusQJSFQZfyEW++AzJKKVqwMrEwlOq4ttM6G+PjdDAk5zMzUtPmlrK7GD7QQMNfouf6CVbpxhuTOjfJw4Qa9Q+6WdEspcGz/dXbdUJk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712662453; c=relaxed/simple; bh=+JfrTVgrO4JkC6c7ui1/Sey7vbzN8l8IbPUAys7zK+A=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=GEvix65VBEraRnNZbFAeJBg+8h6Zdxvk7wflPVXaigCjZIXRxtbtTY3K3okF0X8o7UyLVgNPAtoRbwk7gDdbi9TzDv1FvJ15hf449v305dBl7jaUHSKNVIwukItPzCGx3AykXScWHjTHSb0yxsB3tTMwkmtKDpByIuC610G6Jj0= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com; spf=pass smtp.mailfrom=collabora.com; dkim=pass (2048-bit key) header.d=collabora.com header.i=@collabora.com header.b=ce2Cd4mC; arc=none smtp.client-ip=46.235.227.194 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=collabora.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1712662450; bh=+JfrTVgrO4JkC6c7ui1/Sey7vbzN8l8IbPUAys7zK+A=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ce2Cd4mCVU7Vhtoi0ILH3n35kwovkmajhigwTItpUOd+Msadx4h+NV3PnixFVviar wHMwoeoyixkvbBcwgBU4jwq4I9mBYgD2hTjw+pDvcAC80t0VdLfdG5KPgyIKVSxR1J aJZ8eukC2/FHA+gLkVlykHFcyWBj5NpwyJlR5lDzH+0okKqDX6NSonAf7Cyzhri+T4 OOIK9Xw32W5DIzJ4RUpndQAps8XE1ZeHx5l2QvillwcsDAhSN/3Y7JAJ3NwjumanGY lyCZG7iDbTMniTn3cq17jRuTiptI+EXUHOfj130bmtGb+kbl5cU11BlNpl/CC50taP uTMsfdK2FaYoA== Received: from IcarusMOD.eternityproject.eu (cola.collaboradmins.com [195.201.22.229]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: kholk11) by madrid.collaboradmins.com (Postfix) with ESMTPSA id 728E43782111; Tue, 9 Apr 2024 11:34:08 +0000 (UTC) From: AngeloGioacchino Del Regno To: broonie@kernel.org Cc: wenst@chromium.org, lgirdwood@gmail.com, robh@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org, matthias.bgg@gmail.com, perex@perex.cz, tiwai@suse.com, trevor.wu@mediatek.com, maso.huang@mediatek.com, xiazhengqiao@huaqin.corp-partner.google.com, arnd@arndb.de, kuninori.morimoto.gx@renesas.com, shraash@google.com, amergnat@baylibre.com, nicolas.ferre@microchip.com, u.kleine-koenig@pengutronix.de, dianders@chromium.org, frank.li@vivo.com, allen-kh.cheng@mediatek.com, eugen.hristev@collabora.com, claudiu.beznea@tuxon.dev, jarkko.nikula@bitmer.com, jiaxin.yu@mediatek.com, alpernebiyasak@gmail.com, ckeepax@opensource.cirrus.com, zhourui@huaqin.corp-partner.google.com, nfraprado@collabora.com, alsa-devel@alsa-project.org, shane.chien@mediatek.com, linux-sound@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-mediatek@lists.infradead.org, kernel@collabora.com, AngeloGioacchino Del Regno Subject: [PATCH v4 17/18] arm64: dts: mediatek: mt8195-cherry: Specify sound DAI links and routing Date: Tue, 9 Apr 2024 13:33:09 +0200 Message-ID: <20240409113310.303261-18-angelogioacchino.delregno@collabora.com> X-Mailer: git-send-email 2.44.0 In-Reply-To: <20240409113310.303261-1-angelogioacchino.delregno@collabora.com> References: <20240409113310.303261-1-angelogioacchino.delregno@collabora.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit The drivers and bindings acquired support for specifying audio hardware and links in device tree: describe and link the sound related HW of this machine. Signed-off-by: AngeloGioacchino Del Regno --- .../boot/dts/mediatek/mt8195-cherry.dtsi | 45 +++++++++++++++++++ 1 file changed, 45 insertions(+) diff --git a/arch/arm64/boot/dts/mediatek/mt8195-cherry.dtsi b/arch/arm64/boot/dts/mediatek/mt8195-cherry.dtsi index 4a11918da370..e35adff02469 100644 --- a/arch/arm64/boot/dts/mediatek/mt8195-cherry.dtsi +++ b/arch/arm64/boot/dts/mediatek/mt8195-cherry.dtsi @@ -240,6 +240,7 @@ adsp_device_mem: memory@60e80000 { spk_amplifier: rt1019p { compatible = "realtek,rt1019p"; label = "rt1019p"; + #sound-dai-cells = <0>; pinctrl-names = "default"; pinctrl-0 = <&rt1019p_pins_default>; sdb-gpios = <&pio 100 GPIO_ACTIVE_HIGH>; @@ -366,6 +367,7 @@ &disp_pwm0 { &dp_tx { status = "okay"; + #sound-dai-cells = <0>; pinctrl-names = "default"; pinctrl-0 = <&dptx_pin>; @@ -436,6 +438,7 @@ audio_codec: codec@1a { /* Realtek RT5682i or RT5682s, sharing the same configuration */ reg = <0x1a>; interrupts-extended = <&pio 89 IRQ_TYPE_EDGE_BOTH>; + #sound-dai-cells = <0>; realtek,jd-src = <1>; AVDD-supply = <&mt6359_vio18_ldo_reg>; @@ -1162,6 +1165,48 @@ &sound { "AFE_SOF_DL2", "AFE_SOF_DL3", "AFE_SOF_UL4", "AFE_SOF_UL5"; pinctrl-names = "default"; pinctrl-0 = <&aud_pins_default>; + + audio-routing = + "Headphone", "HPOL", + "Headphone", "HPOR", + "IN1P", "Headset Mic", + "Ext Spk", "Speaker"; + + mm-dai-link { + link-name = "ETDM1_IN_BE"; + mediatek,clk-provider = "cpu"; + }; + + hs-playback-dai-link { + link-name = "ETDM1_OUT_BE"; + mediatek,clk-provider = "cpu"; + codec { + sound-dai = <&audio_codec>; + }; + }; + + hs-capture-dai-link { + link-name = "ETDM2_IN_BE"; + mediatek,clk-provider = "cpu"; + codec { + sound-dai = <&audio_codec>; + }; + }; + + spk-playback-dai-link { + link-name = "ETDM2_OUT_BE"; + mediatek,clk-provider = "cpu"; + codec { + sound-dai = <&spk_amplifier>; + }; + }; + + displayport-dai-link { + link-name = "DPTX_BE"; + codec { + sound-dai = <&dp_tx>; + }; + }; }; &spi0 { -- 2.44.0