From patchwork Sun Oct 23 15:24:37 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shengyu Qu X-Patchwork-Id: 13016316 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 1F5BFFA3740 for ; Sun, 23 Oct 2022 15:26:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Date:Subject:Cc:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=Aexu8rp3BLUK0AIb4WjN8c0bYoJYFTEx1ca2/WsefTc=; b=fRjI9o6wn3MzZW Zv05rKSQA0vmY4v2QSodAF/D3O01FVZ5bumpvh72IRqPwW97AH5eOi5/9koeLFFc/pooeuHN4nie6 M+uSykNSKI8dYc5jJCuoommBEpVsjJslXbgJHMykCfm8b6BdtP2QXrn2FS7O1rqEh96KmsOApyqft NAJ2wp0VrVR+UpiRKkavf71NTsfTxsbzId6zEXa7SKwmLd++Kk/cKL7X9UMDtJuWQ+j5KAkLeIRDa J2/P12vjQ5FAK5RP8xIbqeuZIgBosvKETlTh7SAxBQkPr/P747vtxuH4UaV2zF5D0e1VXHnzYryXm X6sZ6w4LRO0B0hYylCzg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1omcqm-00FZ25-3A; Sun, 23 Oct 2022 15:25:20 +0000 Received: from mail-tycjpn01olkn2034.outbound.protection.outlook.com ([40.92.99.34] helo=JPN01-TYC-obe.outbound.protection.outlook.com) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1omcqb-00FZ0A-RQ; Sun, 23 Oct 2022 15:25:11 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=W6LVAlSC/kYptupXqlTR8t9jI7va+nAZ5JqO+R8QH6FZywqdO/DHlKp8LagygjfvcMBeakOzAm1Fq0qUveBRbMNkFEpd7iBIiosAjCUncc5Y4lrtWbKFjxEqbgBtXc11IStkLgb3qjgnoVT4rtTVZfRULBYZyemEM0te0z1uTam8IXAe2Pj0JzwJtAOlZQWStPpifimnQSKGazCNF01u/n3T2yeY7FalGbT2KKgSaaW0RUNaK43xfg7ImTer/RhklGmBbVtoJUCvyIqNREw91TEu5ql+GYeQVxTlWEc6QehlC+abq6lBTzjryZkoUJcXCJFnDV5gp+ngBQoyN1Ddug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=X6hiS37uoBVGNmSwq1StXLpeznmIMS0JGluHuTvrZmU=; b=Hg6MSb+Obex4Y4glykLM7Gzlb5IcJidjI6s0ROOlBiGjKZcGTPy2UEoJUiXmuBnxGS+Iei3NpV1ydb6WxoDlGRfyeTRBDIQbbByfYM0aK3buvFRSSKvFgeNMhy3Fx4cvNtm+hSLYXO5X6356Vzq9D1Oax92lRlvlaS3a8Fy9u2vwbiMhYSEdiiiGN5+6fn4s3aUyNIiAFpRnlzmvY5MocpS2h7HghXkPlm9cF661pkRBmd7/7g2S/fu4AMvRJCxpZUCahFTGFc9LtT2Nko2ynhPGAkVeljkAV4wRWt+Jnse24C8C9EaZzma9WQHSHuQH8ofcVRqLaOFfwwlPSxLJUw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=none; dmarc=none; dkim=none; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=outlook.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=X6hiS37uoBVGNmSwq1StXLpeznmIMS0JGluHuTvrZmU=; b=UQbsVxLtdJ227lHLdawDYOqLf5BHi8hAqyBId2nb60FGqdJFLE6v/VadccpFzVBWSqzhMSG8gWZipPKSryiRuqurqToRmMTMxM2mdg8wImi5iRmXSZXP481KC+hgo8oViFzEy5JrLy9WLB30lo/3OBqAdLnfHWow5rCPlcC6qtY+24rkhlPF0Yd5j3zqvEpaJ3XjCUrTGcM6CD8pRQp8PA/x4Y0KoNAad0aDQgCYJEYklbzF3xdGpNgy5+ThrA0jAC7btz6bfMEa9iPY76gaIgdY/KRmueGBg1JozADujuflDdH59bA8CXMONpYlyU1s5HfHFxT23rNR9RinMgStEQ== Received: from TY3P286MB2611.JPNP286.PROD.OUTLOOK.COM (2603:1096:400:252::12) by OS3P286MB3403.JPNP286.PROD.OUTLOOK.COM (2603:1096:604:208::9) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5746.23; Sun, 23 Oct 2022 15:25:07 +0000 Received: from TY3P286MB2611.JPNP286.PROD.OUTLOOK.COM ([fe80::4de9:f94b:b58f:948f]) by TY3P286MB2611.JPNP286.PROD.OUTLOOK.COM ([fe80::4de9:f94b:b58f:948f%6]) with mapi id 15.20.5746.021; Sun, 23 Oct 2022 15:25:07 +0000 From: Shengyu Qu To: robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, heiko@sntech.de, michael.riesch@wolfvision.net, s.hauer@pengutronix.de, pgwipeout@gmail.com, frattaroli.nicolas@gmail.com, frank-w@public-files.de, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org Cc: Shengyu Qu Subject: [PATCH] arm64: dts: rockchip: Add Bluetooth HFP support for Radxa Rock 3A Date: Sun, 23 Oct 2022 23:24:37 +0800 Message-ID: X-Mailer: git-send-email 2.25.1 In-Reply-To: <20221023152440.2546-1-wiagn233@outlook.com> References: <20221023152440.2546-1-wiagn233@outlook.com> X-TMN: [JJRhjLnDuDbSN9MmyWo3IPl2hvnH+Wtm] X-ClientProxiedBy: PS2PR03CA0010.apcprd03.prod.outlook.com (2603:1096:300:5b::22) To TY3P286MB2611.JPNP286.PROD.OUTLOOK.COM (2603:1096:400:252::12) X-Microsoft-Original-Message-ID: <20221023152440.2546-2-wiagn233@outlook.com> MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: TY3P286MB2611:EE_|OS3P286MB3403:EE_ X-MS-Office365-Filtering-Correlation-Id: c6d50817-9140-4b58-2d47-08dab50ac3ee X-MS-Exchange-SLBlob-MailProps: HeyTOiyEx6bXUCkHGqUvW+yTD5AlCjqABIMbdjslP6oNbFrLHUoo+prP9UBotq7qz851PeKMKEcuKgHKPzQW4PqF8NlZkosceKBmww28nC4aeWvydmwLralKMMIlh4pCANRC3hXZoo+viAV/0uTHEaIU9Y3w6CN5t+YMx3HROp4T1i+oKpBxaSV5cDGYSmtvRnaq7BFiCjkXa6W9PY3eiglBm9PZk1gQ97ZbY1PuIFciGaKWfj+ljJsd2rmiWGH+y4y43q3pZ2pXzbFFy/MRHXQNHlaDv/kfuV4z5btH4s5BnODimbXve6C6eLt7ZwZT1itQhmrIw1nsHTeGmmr9J8zQirZJ2ImZYVH5hYXj/bmaPduhBqDKIGjz9s/ldWPqQ4iVToWAPPrMxs3yjoxjGNV4v0QMLE+vAhddYoFvWziyv+o15yU9Lv86JxtrV0YG8/utgz3pnhIJ6vByK3RocZpxXa6ifrlvn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19IjGDu6xeWXEzyqR9Uyog40PG5olN1ctrNS88mrGOLrVZ1lcAN+STd8XM33RZB5PyRsI2VjMcFbvTUCX7CVo9zaGcKLxm5B66enwn2aj+9IHpNvUetGASyOStJiVrI+IAGm3G0JBT68xfOhwdB2vCnHqDSsE3Cjn9CELUKWH+90DfV2x/zlMFMh2Aw+qULTBykFiviX9bv0qqLU3J+7DgHdGRPsmLaNyPZYPUp2sU6Ppesf3t39XwUPwZ+EaAV2LCLqH23fyRfu0hpfd9s2kJze83Aw== X-OriginatorOrg: outlook.com X-MS-Exchange-CrossTenant-Network-Message-Id: c6d50817-9140-4b58-2d47-08dab50ac3ee X-MS-Exchange-CrossTenant-AuthSource: TY3P286MB2611.JPNP286.PROD.OUTLOOK.COM X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 23 Oct 2022 15:25:07.0624 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 84df9e7f-e9f6-40af-b435-aaaaaaaaaaaa X-MS-Exchange-CrossTenant-RMS-PersistedConsumerOrg: 00000000-0000-0000-0000-000000000000 X-MS-Exchange-Transport-CrossTenantHeadersStamped: OS3P286MB3403 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20221023_082509_914625_6B71F1DE X-CRM114-Status: UNSURE ( 8.12 ) X-CRM114-Notice: Please train this message. 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 Initial test. --- .../boot/dts/rockchip/rk3568-rock-3a.dts | 34 +++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/arch/arm64/boot/dts/rockchip/rk3568-rock-3a.dts b/arch/arm64/boot/dts/rockchip/rk3568-rock-3a.dts index 37676e8a258c..423558fbc200 100644 --- a/arch/arm64/boot/dts/rockchip/rk3568-rock-3a.dts +++ b/arch/arm64/boot/dts/rockchip/rk3568-rock-3a.dts @@ -60,6 +60,31 @@ simple-audio-card,codec { }; }; + bt-sco-audio { + compatible = "simple-audio-card"; + simple-audio-card,name = "rock-3a-bt-sco"; + simple-audio-card,format = "dsp_b"; + simple-audio-card,bitclock-inversion; + simple-audio-card,frame-master = <&bt_cpu>; + simple-audio-card,bitclock-master = <&bt_cpu>; + simple-audio-card,mclk-fs = <64>; + + bt_cpu: simple-audio-card,cpu { + sound-dai = <&i2s2_2ch>; + dai-tdm-slot-num = <2>; + dai-tdm-slot-width = <16>; + }; + + bt_codec: simple-audio-card,codec { + sound-dai = <&bt_sco_codec>; + }; + }; + + bt_sco_codec: bt-sco-codec { + compatible = "linux,bt-sco"; + #sound-dai-cells = <0>; + }; + sdio_pwrseq: sdio-pwrseq { compatible = "mmc-pwrseq-simple"; clocks = <&rk809 1>; @@ -611,6 +636,15 @@ bluetooth { compatible = "brcm,bcm43438-bt"; clocks = <&rk809 1>; clock-names = "lpo"; + brcm,bt-pcm-int-params = [00 02 00 00 00]; + /* + * Parameters: + * SCO routing: PCM + * PCM interface rate: 512KBps + * PCM frame type (0-1): short + * PCM sync mode (0-1): slave + * PCM clock mode (0-1): slave + */ device-wakeup-gpios = <&gpio4 RK_PB5 GPIO_ACTIVE_HIGH>; host-wakeup-gpios = <&gpio4 RK_PB4 GPIO_ACTIVE_HIGH>; shutdown-gpios = <&gpio4 RK_PB2 GPIO_ACTIVE_HIGH>;