Received: by 2002:a05:6358:f14:b0:e5:3b68:ec04 with SMTP id b20csp597559rwj; Thu, 22 Dec 2022 11:53:01 -0800 (PST) X-Google-Smtp-Source: AMrXdXthldzFKgusn260jCiNgPJ3Rw8mFbW6e2weaypYqWtJyvGnWTjoUYiwxgUrFWpFUgP93emD X-Received: by 2002:a17:902:9f97:b0:18d:4b59:cae5 with SMTP id g23-20020a1709029f9700b0018d4b59cae5mr20950385plq.49.1671738781382; Thu, 22 Dec 2022 11:53:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1671738781; cv=none; d=google.com; s=arc-20160816; b=usdzn8s/+zfX5VblI/ylBl2LRxmggbi4BRq4wpg9ZXY5OrtHtxdSpAMpP5W0WS6Vwp yGXAzRevyOMfdMMO/bv0ijNQAaGhE892BkwAiJHNLSivukgUH1BIdgTxt4jNcttmXh60 QgGhFObLZHWtu9hLHyJB3Z+egNXgZdRj4yHq2ipSclNneI9LEYfoOZtY/rcmX1La2j9I uB7vtafbIiqaCztZnnPcJhbD5iRyv3W2L/c/7QIXUvkQ5yeqgn2UuAWUqyWvUFpxXS4e DT3Ms6XLEy6XiWh4qbV3xDBJqcGDuEtBYfRo19Ut/17CsgCcfPDnoLWYJaSPURVVOunj vdcw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :message-id:date:subject:cc:to:from; bh=bx2KOtnfpmlq6gD3MVdWbZZ66/NDzPL0vwpYVF7bbZ4=; b=g6Rwe0JBV/LwnOhlQzQd5jydJEslBLdOn6AfxBKSfSL/XVHKbYrImYcr+Wv9KE0FD0 tJn8m+UgBoGS9dFaZBxWpA5jzNuE3tiUd65am2BkNJkZAvv+Gs3oUbeB95/N7ZhVtk53 cWvxTNGrsPmTiVd9j0lt7fkh3RfvLxsgDjuxKPfSk8ghkO4zxDlWJrIctvQLKmZiaaUM nBrMzAHSNX6l7Wm5lWQJjh+AHvMWsD6zLXGr5RLPGG7ltW0JX0KsXTTLdwgIKnHyvKgs sFhLqwpdFhueOJpEO0lhSpSlXQnRzYTHZoru1FSVlrOg0WsVaWaTfgIFSbhOuhE/gNCc wWjw== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id j18-20020a170902da9200b00180680b8f1bsi1466940plx.264.2022.12.22.11.52.52; Thu, 22 Dec 2022 11:53:01 -0800 (PST) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229545AbiLVTY5 (ORCPT + 68 others); Thu, 22 Dec 2022 14:24:57 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:50756 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229734AbiLVTY4 (ORCPT ); Thu, 22 Dec 2022 14:24:56 -0500 Received: from relay02.th.seeweb.it (relay02.th.seeweb.it [IPv6:2001:4b7a:2000:18::163]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 47E19FD2D for ; Thu, 22 Dec 2022 11:24:55 -0800 (PST) Received: from localhost.localdomain (94-209-172-39.cable.dynamic.v4.ziggo.nl [94.209.172.39]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by m-r1.th.seeweb.it (Postfix) with ESMTPSA id 5540D201A4; Thu, 22 Dec 2022 20:24:53 +0100 (CET) From: Marijn Suijten To: phone-devel@vger.kernel.org Cc: ~postmarketos/upstreaming@lists.sr.ht, AngeloGioacchino Del Regno , Konrad Dybcio , Martin Botka , Jami Kettunen , Marijn Suijten , Andy Gross , Bjorn Andersson , Konrad Dybcio , Rob Herring , Krzysztof Kozlowski , linux-arm-msm@vger.kernel.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH v2] arm64: dts: qcom: sm6125-seine: Clean up gpio-keys (volume down) Date: Thu, 22 Dec 2022 20:24:43 +0100 Message-Id: <20221222192443.119103-1-marijn.suijten@somainline.org> X-Mailer: git-send-email 2.39.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_NONE, SPF_HELO_NONE,SPF_PASS 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 - Remove autorepeat (leave key repetition to userspace); - Remove unneeded status = "okay" (this is the default); - Remove unneeded linux,input-type (this is the default for gpio-keys); - Allow the interrupt line for this button to be disabled; - Use a full, descriptive node name; - Set proper bias on the GPIO via pinctrl; - Sort properties; - Replace deprecated gpio-key,wakeup property with wakeup-source. Fixes: 82e1783890b7 ("arm64: dts: qcom: sm6125: Add support for Sony Xperia 10II") Signed-off-by: Marijn Suijten --- Changes since v1: - Flatten gpio-keys pinctrl state into controlling just the volume-down pin; - Replace deprecated gpio-key,wakeup property with wakeup-source. v1: https://lore.kernel.org/linux-arm-msm/20221217100455.52593-1-marijn.suijten@somainline.org/ .../qcom/sm6125-sony-xperia-seine-pdx201.dts | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/arch/arm64/boot/dts/qcom/sm6125-sony-xperia-seine-pdx201.dts b/arch/arm64/boot/dts/qcom/sm6125-sony-xperia-seine-pdx201.dts index 0de6c5b7f742..09cff5d1d0ae 100644 --- a/arch/arm64/boot/dts/qcom/sm6125-sony-xperia-seine-pdx201.dts +++ b/arch/arm64/boot/dts/qcom/sm6125-sony-xperia-seine-pdx201.dts @@ -41,17 +41,18 @@ extcon_usb: extcon-usb { }; gpio-keys { - status = "okay"; compatible = "gpio-keys"; - autorepeat; - key-vol-dn { + pinctrl-0 = <&vol_down_n>; + pinctrl-names = "default"; + + key-volume-down { label = "Volume Down"; gpios = <&tlmm 47 GPIO_ACTIVE_LOW>; - linux,input-type = <1>; linux,code = ; - gpio-key,wakeup; debounce-interval = <15>; + linux,can-disable; + wakeup-source; }; }; @@ -270,6 +271,14 @@ &sdhc_1 { &tlmm { gpio-reserved-ranges = <22 2>, <28 6>; + + vol_down_n: vol-down-n-state { + pins = "gpio47"; + function = "gpio"; + drive-strength = <2>; + bias-disable; + input-enable; + }; }; &usb3 { -- 2.39.0