Received: by 2002:a05:6358:9144:b0:117:f937:c515 with SMTP id r4csp2292896rwr; Fri, 21 Apr 2023 07:05:57 -0700 (PDT) X-Google-Smtp-Source: AKy350Yk4RNBwCvP+CvqHScRSpmk2MieE7/er9b97eOULFUPsTJR2soZdqG0Wdhqk3OSDhcKyky6 X-Received: by 2002:a05:7500:448c:b0:101:714c:c92e with SMTP id gb12-20020a057500448c00b00101714cc92emr161334gab.1.1682085957446; Fri, 21 Apr 2023 07:05:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1682085957; cv=none; d=google.com; s=arc-20160816; b=y39yXiTmXc6UztpdDrbaSqKCdKQGkViQimR+3Es92P2YBAEERmOwhE5vPeAwDC7iUq cG+GkEGpWLj2+e/YNTTzz7e3Mkxz1bAhMmEtE/K1k2Il4RBSwKJdl88wIMLjdLt0NYGH PUGsm41YIePnzGJAwyXWq7nu/UHROoJ9Q//q+sEzLK0CrDfCEmNI0ROypUiBHPKTqBhT FHETGvIBxIDNZNneS2BgQxRFUemBNJW0L+AbAQdZMkpmmRQ9k4/EcSsBPLXpgTo6JP8g p7NfkvdzJJO4ANcuJg2Gbc11iB2l46Ckj7WGgntKztjntw6eH0Qxr44CUaPjASnom0bR cu2Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=YALT7Js4KtxSk5x/izulh6BNtKTawyF4l7eDmYfrvlI=; b=IRIGs6CimBF6N8c8Vvdu8YGJNDZZDjl17QD3D6y+R3zMtzrElYviTQH/NxKsQdTb1e nHTEJTnuGBgZwuWrKvNyPZnNVvAG2X7CpTqqNwVseILRpsziOkq6AhzHHhCA12nxdc/k fiTzmXufpQ6wKwPw9NprwQlxEVdBQ15FFwQ6W50xcRBSu6KJRHINONsLx130nlbpUETg cC2BjZjz1iuoD37Bb52RyKmx9Jg6+gKMelz9MKnd4FP+LvIOfTMFMO/rYNx43VxK/iwH OeFxhW4dZMpWjoqTRGdSh09GuYt67X+pgLeUyZjiS33yEbc/9vxE5jcLwf1BWgsgxnJZ H0iA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=CMON1N7K; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id i13-20020a05610220cd00b004300b7d4e13si1062519vsr.349.2023.04.21.07.05.31; Fri, 21 Apr 2023 07:05:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@collabora.com header.s=mail header.b=CMON1N7K; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=collabora.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232212AbjDUOBt (ORCPT + 99 others); Fri, 21 Apr 2023 10:01:49 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41886 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232501AbjDUOBd (ORCPT ); Fri, 21 Apr 2023 10:01:33 -0400 Received: from madras.collabora.co.uk (madras.collabora.co.uk [46.235.227.172]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6B8A2E55; Fri, 21 Apr 2023 07:01:28 -0700 (PDT) Received: from notapiano (unknown [IPv6:2600:4041:5b1a:cd00:524d:e95d:1a9c:492a]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-256) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: nfraprado) by madras.collabora.co.uk (Postfix) with ESMTPSA id 54ED26603276; Fri, 21 Apr 2023 15:01:26 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1682085687; bh=1vgwclP5B6vfVz7wXujyKjNoyVDTIACdOwUdXtZG1fg=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=CMON1N7KEo0dGRHeB/EiSYBZlhMPw0PYScmX0/QFGDPPFm+oWqrpAvR76ZxglqN+o NwyR7DrKTqyh2Wi++ziTgeKQX9wIcPovn7nnYxELH5D03DoKmCwinXpQmF5WmROY46 wmw3xa7D4gf/HrbOiRWLyWOeobTzGJh0HrxLgNlVdDSB9zujcekTqpnP6VEjhSrYrW InfVmI/WgAuTgxPK4CnBkfecqVfYte4BGNHUL3w2Is9yenf0BlvKqPtloyYfYEibza uDZFA4GYDnAZjXmytM9CTjKWdwjXV62zGhbcQPDwRGWff6RtgzZUEj1kmlR9uvgT7Z OxKbvf+8rfYVg== Date: Fri, 21 Apr 2023 10:01:22 -0400 From: =?utf-8?B?TsOtY29sYXMgRi4gUi4gQS4=?= Prado To: Chen-Yu Tsai Cc: Matthias Brugger , AngeloGioacchino Del Regno , devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, Rob Herring , Krzysztof Kozlowski Subject: Re: [PATCH] arm64: dts: mediatek: mt8192-asurada-hayato: Enable Bluetooth Message-ID: <872e8b77-c1ea-410a-b978-dd8f49f9904b@notapiano> References: <20230421110327.2395804-1-wenst@chromium.org> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20230421110327.2395804-1-wenst@chromium.org> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Apr 21, 2023 at 07:03:27PM +0800, Chen-Yu Tsai wrote: > Hayato's Realtek WiFi/BT module has it's Bluetooth function wired to > UART1. > > Add and enable the relevant device nodes for it. > > Signed-off-by: Chen-Yu Tsai > --- > .../dts/mediatek/mt8192-asurada-hayato-r1.dts | 80 +++++++++++++++++++ > 1 file changed, 80 insertions(+) > > diff --git a/arch/arm64/boot/dts/mediatek/mt8192-asurada-hayato-r1.dts b/arch/arm64/boot/dts/mediatek/mt8192-asurada-hayato-r1.dts > index 43a823990a92..6a7d7870525b 100644 > --- a/arch/arm64/boot/dts/mediatek/mt8192-asurada-hayato-r1.dts > +++ b/arch/arm64/boot/dts/mediatek/mt8192-asurada-hayato-r1.dts > @@ -40,9 +40,89 @@ CROS_STD_MAIN_KEYMAP > >; > }; > > +&pio { > + bt_pins: bt-pins { > + bt_kill: pins-bt-kill { Drop this label and for the other pinconfigs below as they'll never be referenced. > + pinmux = ; /* BT_KILL_L */ I'd also drop this and the other comments, as they're already documented in the gpio-line-names property. > + output-low; > + }; > + > + bt_wake: pins-bt-wake { > + pinmux = ; /* bt to wake ap */ > + bias-pull-up; > + }; > + > + ap_wake_bt: pins-ap-wake-bt { > + pinmux = ; /* AP_WAKE_BT_H */ > + output-low; > + }; > + }; > + > + uart1_pins: uart1-pins { > + pins-rx { > + pinmux = ; > + input-enable; > + bias-pull-up; > + }; > + > + pins-tx { > + pinmux = ; > + }; > + > + pins-cts { > + pinmux = ; > + input-enable; > + }; > + > + pins-rts { > + pinmux = ; > + output-enable; Looks like the dt-binding doesn't currently support output-enable, but the driver does, so please just add a patch with output-enable: true on mediatek,mt8192-pinctrl.yaml > + }; > + }; > + > + uart1_pins_sleep: uart1-pins-sleep { "-pins" needs to come last in the name otherwise the dt-binding will complain. > + pins-rx { > + pinmux = ; > + input-enable; > + bias-pull-up; > + }; > + pins-tx { > + pinmux = ; > + }; > + pins-cts { > + pinmux = ; > + input-enable; > + }; > + pins-rts { > + pinmux = ; > + output-enable; > + }; > + }; > +}; > + > &touchscreen { > compatible = "hid-over-i2c"; > post-power-on-delay-ms = <10>; > hid-descr-addr = <0x0001>; > vdd-supply = <&pp3300_u>; > }; > + > +&uart1 { > + status = "okay"; > + pinctrl-names = "default", "sleep"; > + pinctrl-0 = <&uart1_pins>; > + pinctrl-1 = <&uart1_pins_sleep>; > + /delete-property/ interrupts; > + interrupts-extended = <&gic GIC_SPI 110 IRQ_TYPE_LEVEL_HIGH 0>, > + <&pio 94 IRQ_TYPE_EDGE_FALLING>; > + > + bluetooth: bluetooth { I'd also drop this label and only introduce it if/when needed. Reviewed-by: N?colas F. R. A. Prado Thanks, N?colas > + compatible = "realtek,rtl8822cs-bt"; > + pinctrl-names = "default"; > + pinctrl-0 = <&bt_pins>; > + > + enable-gpios = <&pio 144 GPIO_ACTIVE_HIGH>; > + device-wake-gpios = <&pio 168 GPIO_ACTIVE_HIGH>; > + host-wake-gpios = <&pio 22 GPIO_ACTIVE_LOW>; > + }; > +}; > -- > 2.40.0.634.g4ca3ef3211-goog >