From patchwork Thu Sep 29 01:15:55 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Torokhov X-Patchwork-Id: 12993331 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 4845FC04A95 for ; Thu, 29 Sep 2022 01:17:21 +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: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:In-Reply-To:References: List-Owner; bh=M3zGN6X1CyEquMdejJC1jCKWa7Xw3khk9+FFxdlPAPo=; b=oMY7VMXnPvClhM YOYO2ViwNLEamJz/VeF+iLSpczG/ikqkMA3sbqqGdn302tHwpMe5ZWRuzLpa2bhtanlIy7cB/3N9C 0mxfHUPXoKn5pE4gvWfzs+cYX3jvIg17IF3yPhMIGHgF72iYmcCwqWWauUWQ6ojiiv0dWK2iSdyLj 8T0H+6zQ2Qs+dtkqNdtZOUmP7KN2gwBWdGJisYYNG3NvlNJ0/Rka0Q6+igO08HJCax6fjp3bYXJ0w FYSuDKi9sTU6VYEceuUxKaoJMNjznHhPspoFfO6je4/6QzthZc613Y3qVYaMFcMNmOZAM5/tfK3FE NxtXb0f0APtxeKPYmOgQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1odi9p-000oLu-G5; Thu, 29 Sep 2022 01:16:09 +0000 Received: from mail-pf1-x429.google.com ([2607:f8b0:4864:20::429]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1odi9j-000oKt-ID for linux-arm-kernel@lists.infradead.org; Thu, 29 Sep 2022 01:16:07 +0000 Received: by mail-pf1-x429.google.com with SMTP id d10so100772pfh.6 for ; Wed, 28 Sep 2022 18:16:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date; bh=BU+nDgTp4FzYVpuKCb0JHUgNuGWH3Om1JL3bunVELiE=; b=A0x2qxxd7VgDTwVVmF44TCkowfDAT8LZM/ThFvomS1q6mGKiPpWLuHmLPozdAIQ6bk 8DGmPjWUuHqevrxLJRSxTeQz+ghGSlSFzb9V8IjihndL5lzA/gbT/jsLrSKbpIeAlxTM iNvGazSV6E/BTLTq5+jUfMfh153cyZ24zEIaWdFp5eZOEd2HUF9It3wPdSjH4y5Bz7Ly WL8HcE+xScGlqCiG89WS/xvsaTzmdMGBwHXSPtGLqaoQ3VXWo8Ru8wEfkAIOsexx7P0u gn5Xsi7qHkrRcJOjofGsS6C8okv42dPYeXKuzuogvAmGAIkRBWK/JDVYBMJMBI4p93b3 ez1A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date; bh=BU+nDgTp4FzYVpuKCb0JHUgNuGWH3Om1JL3bunVELiE=; b=JuEYwFadxtcgOLkQ1upKVRVLmbfVJo7xLUnptYJZwmE5Z8O2H0TH4WQz1992kLbucU Ez/4CE8nW3tRtaqycdgKJrrKyZ4Uuw9CqL23kI9xKj9volAVEUqwiaucirOyH7bLPaS9 m/+3TQO0pxACkEFABdVUgfYoJS+4KPFXz1b7/jTD0+2FGG5ZqbFlNrRzA2yaD8FqC9q9 Kkiwu56ad4HZvPIyA9pGS8Yk7wCUB3Oe52fpK4+pJfK9ai1ONcZyVDRwerVNjJO60Ets GzVtQ7jK0MRRrddzzetk/X4njp5iuedjDBOnA8dKWmnowIK0Vc6BMmyUMuRFFPvvKIPz ztLg== X-Gm-Message-State: ACrzQf3dxrSrSh3vx8E3wc6zFInYNKQZWLk1+MQFpshHRJtpwRmkNX4B j7QB/f8JSHCd3V5MkrPUsy/e4bPmcNM= X-Google-Smtp-Source: AMsMyM6hjulu0JTSOCybn1i/7qzxsqC/IdkN8d1HzIAGH28CBW+sxxckdBQvuc2a8V8BGBIRzXn/ow== X-Received: by 2002:a63:3348:0:b0:439:db24:8b02 with SMTP id z69-20020a633348000000b00439db248b02mr568358pgz.425.1664414161469; Wed, 28 Sep 2022 18:16:01 -0700 (PDT) Received: from dtor-ws.mtv.corp.google.com ([2620:15c:9d:2:637c:7f23:f348:a9e6]) by smtp.gmail.com with ESMTPSA id y16-20020aa78f30000000b00540a3252191sm4737655pfr.28.2022.09.28.18.16.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Sep 2022 18:16:00 -0700 (PDT) From: Dmitry Torokhov To: Krzysztof Kozlowski , Bjorn Andersson Cc: Krzysztof Opasiak , Alim Akhtar , Andy Gross , linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 1/3] arm64: dts: exynos: fix polarity of "enable" line of NFC chip Date: Wed, 28 Sep 2022 18:15:55 -0700 Message-Id: <20220929011557.4165216-1-dmitry.torokhov@gmail.com> X-Mailer: git-send-email 2.38.0.rc1.362.ged0d419d3c-goog MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220928_181603_622869_513C5555 X-CRM114-Status: GOOD ( 13.38 ) 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 According to s3fwrn5 driver code the "enable" GPIO line is driven "high" when chip is not in use (mode is S3FWRN5_MODE_COLD), and is driven "low" when chip is in use. s3fwrn5_phy_power_ctrl(): ... gpio_set_value(phy->gpio_en, 1); ... if (mode != S3FWRN5_MODE_COLD) { msleep(S3FWRN5_EN_WAIT_TIME); gpio_set_value(phy->gpio_en, 0); msleep(S3FWRN5_EN_WAIT_TIME); } Therefore the line described by "en-gpios" property should be annotated as "active low". The wakeup gpio appears to have correct polarity (active high). Signed-off-by: Dmitry Torokhov --- arch/arm64/boot/dts/exynos/exynos5433-tm2-common.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/exynos/exynos5433-tm2-common.dtsi b/arch/arm64/boot/dts/exynos/exynos5433-tm2-common.dtsi index 91c9bd1b47dd..bde6a6bb8dfc 100644 --- a/arch/arm64/boot/dts/exynos/exynos5433-tm2-common.dtsi +++ b/arch/arm64/boot/dts/exynos/exynos5433-tm2-common.dtsi @@ -795,7 +795,7 @@ s3fwrn5: nfc@27 { reg = <0x27>; interrupt-parent = <&gpa1>; interrupts = <3 IRQ_TYPE_EDGE_RISING>; - en-gpios = <&gpf1 4 GPIO_ACTIVE_HIGH>; + en-gpios = <&gpf1 4 GPIO_ACTIVE_LOW>; wake-gpios = <&gpj0 2 GPIO_ACTIVE_HIGH>; }; }; From patchwork Thu Sep 29 01:15:56 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Torokhov X-Patchwork-Id: 12993332 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 BCA00C54EE9 for ; Thu, 29 Sep 2022 01:17:22 +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=GBRpqtYa1Wf4c+jm0qHAm832p7z2FFdrrvxoZNLauho=; b=XHVN9AMlWgu5R9 pH0DhKbf5ubqkSlAIrx4qvxLhl4fYNnVK6W6/UDmOxUDiX+/L8cUxhnrFR8nTZz0Cj330ESwqm3vq taOBeXiNz97O/qmADHbBod/HWYtYnHI+1cQu7UJjXEQSTwXnZD1ZkQy72Ey7XGMTGjoudKsJAwgRM cqSrd1RWpEaAhqyhwhdZ6FcQWMzG333eNVa1sHww6xWROSJugfO8evRAiIleClh48MHh2vx19OI16 Kgdw3JbIjH9MP0vEyhgOlSJByabZgZwduv9IxQ1TVDR306KBdwzaQXmpnKuhnKMrjdzKmHbpMFd/m sHJ5XPz2ZMNShW9qOygQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1odi9x-000oNx-Qi; Thu, 29 Sep 2022 01:16:17 +0000 Received: from mail-pg1-x533.google.com ([2607:f8b0:4864:20::533]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1odi9k-000oL8-Ii for linux-arm-kernel@lists.infradead.org; Thu, 29 Sep 2022 01:16:08 +0000 Received: by mail-pg1-x533.google.com with SMTP id b5so105087pgb.6 for ; Wed, 28 Sep 2022 18:16:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=F1+FkqfkwmhLCAn3NJHPER+7hJ8fiY2kv2ckZW4kL50=; b=nPFXGWzu0dPPBXFHQLhus1nG59TKq06lJtiE/k+1gx0JnzAwLbA5ZyrUNqZIRtut1O BQRHZ/v6M48oWSs5zoV43CwygfbdG3SaWP58dOlOTaNgGzU4gKQVld3GWu5RU5PMenry X7GOPLcCxUzwkY2jRHgSjZZsCAuK3sCUsffbXir+us8+HsAF40yqqKCF9qMKOjXOWGdm WtYC6da+eAo46nbc5WwQUBrj5IF3Qe8YF7ig3gR7sYYsR6viZ8rg79bxo08G5uQsW/QQ bB0Uby4mOlI11XzSUNyV247k9QFo/PdGWu9nCwKOmQ+BERvmuWdt6a/MLpgiN43ziOys qvrg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=F1+FkqfkwmhLCAn3NJHPER+7hJ8fiY2kv2ckZW4kL50=; b=nkK7zdo4nzKSbXa2pH9YqplUg+KnavrREWIspWtmz2umce/jfwRDOKlbDPDRV4Wfpq Od0pLz6Gcq9jYRelsqAmy1EKLtNBAOYllIW0Mq7Fz9rz4NiQCJcIgN96vb84P9eTEqR5 N2oLLPKxWwKmv0p+eJqxmm3ni78Ipq1RpEAID29uheALk3kIXf65EIaJ+Fce/IwrMLEb 8UcXueNxpS2UmELloHQq8MAwoHaq10RrIizW1ht5i8gv9l0TpYxPqIBDB87h4IaVMfY6 b534pkcJTh3kok6pUy78cjnMtyhCkeYKK8yrl9uLVJzIb7rwdyNvEGM+/WP6p45IgmT7 d4RQ== X-Gm-Message-State: ACrzQf16nJL7n+F/2ygyLst+qpvVdH0924JYAAgJK2POd3SV94hpyQVM TszccVZIzOomi4a4w+iqVLE= X-Google-Smtp-Source: AMsMyM5JPA+5q3wy9oMlFnpsgGaUSHQrsazaUXbFoWfvqOvAQv+3m85/9snz/Wp5nsecy3cR9zM3ag== X-Received: by 2002:a05:6a02:318:b0:43c:e24a:961c with SMTP id bn24-20020a056a02031800b0043ce24a961cmr559038pgb.589.1664414163405; Wed, 28 Sep 2022 18:16:03 -0700 (PDT) Received: from dtor-ws.mtv.corp.google.com ([2620:15c:9d:2:637c:7f23:f348:a9e6]) by smtp.gmail.com with ESMTPSA id y16-20020aa78f30000000b00540a3252191sm4737655pfr.28.2022.09.28.18.16.01 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Sep 2022 18:16:02 -0700 (PDT) From: Dmitry Torokhov To: Krzysztof Kozlowski , Bjorn Andersson Cc: Krzysztof Opasiak , Alim Akhtar , Andy Gross , linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/3] arm64: dts: qcom: msm8916-samsung-a2015: fix polarity of "enable" line of NFC chip Date: Wed, 28 Sep 2022 18:15:56 -0700 Message-Id: <20220929011557.4165216-2-dmitry.torokhov@gmail.com> X-Mailer: git-send-email 2.38.0.rc1.362.ged0d419d3c-goog In-Reply-To: <20220929011557.4165216-1-dmitry.torokhov@gmail.com> References: <20220929011557.4165216-1-dmitry.torokhov@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220928_181604_631379_12E3A6A9 X-CRM114-Status: GOOD ( 13.87 ) 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 According to s3fwrn5 driver code the "enable" GPIO line is driven "high" when chip is not in use (mode is S3FWRN5_MODE_COLD), and is driven "low" when chip is in use. s3fwrn5_phy_power_ctrl(): ... gpio_set_value(phy->gpio_en, 1); ... if (mode != S3FWRN5_MODE_COLD) { msleep(S3FWRN5_EN_WAIT_TIME); gpio_set_value(phy->gpio_en, 0); msleep(S3FWRN5_EN_WAIT_TIME); } Therefore the line described by "en-gpios" property should be annotated as "active low". The wakeup gpio appears to have correct polarity (active high). Signed-off-by: Dmitry Torokhov --- arch/arm64/boot/dts/qcom/msm8916-samsung-a2015-common.dtsi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm64/boot/dts/qcom/msm8916-samsung-a2015-common.dtsi b/arch/arm64/boot/dts/qcom/msm8916-samsung-a2015-common.dtsi index 3255bd3fcb55..5f7cec347a4f 100644 --- a/arch/arm64/boot/dts/qcom/msm8916-samsung-a2015-common.dtsi +++ b/arch/arm64/boot/dts/qcom/msm8916-samsung-a2015-common.dtsi @@ -144,7 +144,7 @@ nfc@27 { interrupt-parent = <&msmgpio>; interrupts = <21 IRQ_TYPE_EDGE_RISING>; - en-gpios = <&msmgpio 20 GPIO_ACTIVE_HIGH>; + en-gpios = <&msmgpio 20 GPIO_ACTIVE_LOW>; wake-gpios = <&msmgpio 49 GPIO_ACTIVE_HIGH>; clocks = <&rpmcc RPM_SMD_BB_CLK2_PIN>; From patchwork Thu Sep 29 01:15:57 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dmitry Torokhov X-Patchwork-Id: 12993333 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 906DFC32771 for ; Thu, 29 Sep 2022 01:17:26 +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=jFR9L6IwvmOW3WZq/8wKMd6sbLK4Q/mGfVWFvDIkssY=; b=jTr6C+kmSJj6zy SAcVgIhXKJkDUP31N8DzsT9uV7FCDdFT+cgnMJYoupD/Bf4AbidzXifc2MRwxqv0XgeNAQ0GdZZgp Y/7mDeuEBgDCLmjhKIncevBVkkrexWmvVBopDRcaFUbqdhJDGSVAKRGr8AF7ReAbEqtMXAxGYbcBO /lu1C01oMpt/2hCe+s4zRyxrlZo/luhiAv1p5rvjCo9zfeFgsQbJX78Hx8lWu3hIQv5cNUd2Gum7i tdYLimw+jQ+9AnXmiFUWVbZyuswpDqSmq3nLLS4E5gcq4Smg/jRFpCUIUK1AYfhmik10bMbPNuWuM MBpqCMFCc1XBO3DscWCA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1odiA6-000oOi-4L; Thu, 29 Sep 2022 01:16:26 +0000 Received: from mail-pl1-x62e.google.com ([2607:f8b0:4864:20::62e]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1odi9p-000oLM-He for linux-arm-kernel@lists.infradead.org; Thu, 29 Sep 2022 01:16:10 +0000 Received: by mail-pl1-x62e.google.com with SMTP id y20so3083641plb.2 for ; Wed, 28 Sep 2022 18:16:05 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=P6xn5k2w04qcw40pGqvk2hfkeCe3OpcAGkUOVnCrECg=; b=Mdix1ez2UFJ0v4X3ERTqjEVLBAX9bje7HCmdZdqxkh5iAyyTeZvi3aAqNO/fiNSp7I Z/lntDcF6QR+G68aq3MgndSDp+JFIaYFgi8V8DKBTSkBIVFvIaMpX0ABhRkpnGtjawbm JGF/8CEIRT28F7knuwnzS3c0SxMMU0YkJmMDKME7+yDrYO8rx2RAa3kEwMjNw4tP9Pnf 7Uzld5hjUSfayZEz4ZNOZowzPYJ2SqyyjJB+gxysKLzwA9b5Bypd/9wV8g20vpq9hBDW eMsBEynGINXNkOt6ExbYa0Y3WjBmAs1BnpYL23BLxmc+GZ4g3IY8nleJPMRg8TGtJjLR a8EA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date; bh=P6xn5k2w04qcw40pGqvk2hfkeCe3OpcAGkUOVnCrECg=; b=MKHn7as5K4a606E6MZgBlHGquh5TmmvQbYuwfDO6Z1/vjI4s5nlrWRwCmi//ErX53U GBuCsG3eBeGFX/dn/6KkHzK2vO5KcVHAHU/77cTV6QJsKeX/pwb7tr2B9emGWBv+IcjN lYDp3ZOFmYXOlZ0Sh68nJhxAUYjKiCotRVMKSyufnrrFL4epvq3QhMwo3Fc1hHQlm0UZ 9EWLYom/tfWwI8Pl8L7GCU5WCVmvHQzj9cDrCKchPCxTp0m+BPRyfme5uzE5i4Plxr25 HYkyHt+EmV1J5qvJL/TE+tyLOlLC9AT78oqwcBn+AD/LWkBHMAzJxciwNyGtT7ew8Wn3 U0AA== X-Gm-Message-State: ACrzQf19bzRSrlIo/e/Y1UjGRxJPza0+UaAJitN6243QJb5qfh3HQgXj 9+Mlc1fEt3ECpAjZjLpJtpU= X-Google-Smtp-Source: AMsMyM5ChV5LYfzLI0YM2SoghglQe4b1wxlFtJR8tcjNmOWHl+jSTjBmhN/5o3xp/JHVkrc6T/BaUw== X-Received: by 2002:a17:902:a511:b0:178:9702:7199 with SMTP id s17-20020a170902a51100b0017897027199mr779310plq.155.1664414164652; Wed, 28 Sep 2022 18:16:04 -0700 (PDT) Received: from dtor-ws.mtv.corp.google.com ([2620:15c:9d:2:637c:7f23:f348:a9e6]) by smtp.gmail.com with ESMTPSA id y16-20020aa78f30000000b00540a3252191sm4737655pfr.28.2022.09.28.18.16.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 28 Sep 2022 18:16:04 -0700 (PDT) From: Dmitry Torokhov To: Krzysztof Kozlowski , Bjorn Andersson Cc: Krzysztof Opasiak , Alim Akhtar , Andy Gross , linux-arm-kernel@lists.infradead.org, linux-samsung-soc@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: [PATCH 3/3] dt-bindings: net: nfc: s3fwrn5: fix polarity of "enable" line of NFC chip Date: Wed, 28 Sep 2022 18:15:57 -0700 Message-Id: <20220929011557.4165216-3-dmitry.torokhov@gmail.com> X-Mailer: git-send-email 2.38.0.rc1.362.ged0d419d3c-goog In-Reply-To: <20220929011557.4165216-1-dmitry.torokhov@gmail.com> References: <20220929011557.4165216-1-dmitry.torokhov@gmail.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220928_181609_604792_00A169F8 X-CRM114-Status: GOOD ( 13.39 ) 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 According to s3fwrn5 driver code the "enable" GPIO line is driven "high" when chip is not in use (mode is S3FWRN5_MODE_COLD), and is driven "low" when chip is in use. s3fwrn5_phy_power_ctrl(): ... gpio_set_value(phy->gpio_en, 1); ... if (mode != S3FWRN5_MODE_COLD) { msleep(S3FWRN5_EN_WAIT_TIME); gpio_set_value(phy->gpio_en, 0); msleep(S3FWRN5_EN_WAIT_TIME); } Therefore the line described by "en-gpios" property should be annotated as "active low". The wakeup gpio appears to have correct polarity (active high). Signed-off-by: Dmitry Torokhov --- .../devicetree/bindings/net/nfc/samsung,s3fwrn5.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Documentation/devicetree/bindings/net/nfc/samsung,s3fwrn5.yaml b/Documentation/devicetree/bindings/net/nfc/samsung,s3fwrn5.yaml index 64995cbb0f97..78e3c13f1acb 100644 --- a/Documentation/devicetree/bindings/net/nfc/samsung,s3fwrn5.yaml +++ b/Documentation/devicetree/bindings/net/nfc/samsung,s3fwrn5.yaml @@ -81,7 +81,7 @@ examples: interrupt-parent = <&gpa1>; interrupts = <3 IRQ_TYPE_EDGE_RISING>; - en-gpios = <&gpf1 4 GPIO_ACTIVE_HIGH>; + en-gpios = <&gpf1 4 GPIO_ACTIVE_LOW>; wake-gpios = <&gpj0 2 GPIO_ACTIVE_HIGH>; clocks = <&rpmcc 20>; @@ -93,7 +93,7 @@ examples: nfc { compatible = "samsung,s3fwrn82"; - en-gpios = <&gpio 20 GPIO_ACTIVE_HIGH>; + en-gpios = <&gpio 20 GPIO_ACTIVE_LOW>; wake-gpios = <&gpio 16 GPIO_ACTIVE_HIGH>; };