From patchwork Sat Jan 7 14:41:48 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Klaus Kudielka X-Patchwork-Id: 640496 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4C718C54EBC for ; Sat, 7 Jan 2023 14:43:29 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229475AbjAGOn1 (ORCPT ); Sat, 7 Jan 2023 09:43:27 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53058 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231422AbjAGOn0 (ORCPT ); Sat, 7 Jan 2023 09:43:26 -0500 Received: from mail-wm1-x336.google.com (mail-wm1-x336.google.com [IPv6:2a00:1450:4864:20::336]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D2E5A58FAB; Sat, 7 Jan 2023 06:43:24 -0800 (PST) Received: by mail-wm1-x336.google.com with SMTP id z8-20020a05600c220800b003d33b0bda11so5081662wml.0; Sat, 07 Jan 2023 06:43:24 -0800 (PST) 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:message-id:reply-to; bh=i3d+gOAD88oLabVtrIfzPXu7o2OZ8RNw65o7EHr8oIk=; b=PBWCnhEA0udMeH0tYHbUBalF84o9wZ5bM+etdc+3pGDNTYq5mI+4ECgwElxr7EHe4S cSY4QWGUJwJRUE/vuoEq9NEFfUqp6bIIu5bvwbPiOl+GCoDq6zuM7VQy1bRIiCzeqpSF 1szcdZgeInDIZMHVAYx3TQQv5vzcunM7SUjDbRc3SPPk2rAuYi4Dan0TXRPhcQYMac3Z z9dNnfVqRhxYal6wXMGjGokXlGDHWYFcv6bLlH+BFVGASL91bEfeuF7zVaUUQ/wcfAwV wAAi2nuCQCTpUqWJFDr9Uhz4pyX4UU63xUuzZlDhaPV2Uu2jTTnV4ZUJGtD0ANVwIif+ 7Gaw== 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:message-id :reply-to; bh=i3d+gOAD88oLabVtrIfzPXu7o2OZ8RNw65o7EHr8oIk=; b=ZuSKoezdMZ7bEgejKlKZvkAV8oKP80lErPLEcj5HniKNnq9GnvXrdDScU/HVI3RINH dliXBc0F/qI7dpsIEB6vyoIucnDtUBHKU1+ILcn/HVPi+xWPjglPrjsgeDyVaxRtDX9M lX802nme6Thf/2IYiHQi4gQ6PQ6q/g4ln/hZE9IBzdbCDcqcACbO/2ER6CV3syvN5bDI GpxQ+XGY0Rmrns9Uhdk8xD9bSPb2noRADI+yWF2it2mEiGh3LmxDWjthXAF1931bonfH l4OqaE4C+TQNmv/pHy+IyY4+q4irUHg3ZSrCy1vmWyrB2DAd5lvwH3CvuWoB/8MA+/+r Cykg== X-Gm-Message-State: AFqh2kq4go7exAzAJK5lzYIiZR+Aor4LqDrIPlBPrwjeeQ448aui7lz8 O7MxcLIMjE2tm534ageI+Xg= X-Google-Smtp-Source: AMrXdXtjuk2eHtVbZ1/GbAcJYWTE31oco3Z7HMqTj3sRkYbZPzE34OyKpSR6LybAX/MszgSNQ7h53Q== X-Received: by 2002:a1c:7410:0:b0:3cf:8957:806e with SMTP id p16-20020a1c7410000000b003cf8957806emr42935386wmc.5.1673102603226; Sat, 07 Jan 2023 06:43:23 -0800 (PST) Received: from mars.. ([2a02:168:6806:0:40f6:41b6:8914:e80b]) by smtp.gmail.com with ESMTPSA id h19-20020a05600c351300b003d9a86a13bfsm6056106wmq.28.2023.01.07.06.43.22 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 07 Jan 2023 06:43:22 -0800 (PST) From: Klaus Kudielka To: "Andrew Lunn" , "Gregory Clement" , "Sebastian Hesselbarth" , "Rob Herring" , "Krzysztof Kozlowski" , =?utf-8?q?Pali_R?= =?utf-8?q?oh=C3=A1r?= , =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= Cc: Thomas Petazzoni , Chris Packham , linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, Klaus Kudielka Subject: [PATCH v2 1/2] Revert "ARM: dts: armada-38x: Fix compatible string for gpios" Date: Sat, 7 Jan 2023 15:41:48 +0100 Message-Id: <20230107144149.5743-1-klaus.kudielka@gmail.com> X-Mailer: git-send-email 2.39.0 MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org This reverts commit c4de4667f15d04ef5920bacf41e514ec7d1ef03d, which causes a regression on Turris Omnia (Armada 385): GPIO interrupts cease to work, ending up in the DSA switch being non-functional. The blamed commit is incorrect in the first place: If compatible = "marvell,armadaxp-gpio", the second (address, size) pair of the reg property must to point to the per-CPU interrupt registers <0x18800 0x30> / <0x18840 0x30>, and not to the blink enable registers <0x181c0 0x08> / <0x181c8 0x08>. But even fixing that leaves the GPIO interrupts broken on the Omnia. Furthermore: Commit 5f79c651e81e explains very well, why the gpio-mvebu driver does not work reliably with per-CPU interrupts. Commit 988c8c0cd04d deprecates compatible = marvell,armadaxp-gpio for this reason. Fixes: c4de4667f15d ("ARM: dts: armada-38x: Fix compatible string for gpios") Reported-by: Klaus Kudielka Link: https://lore.kernel.org/r/f24474e70c1a4e9692bd596ef6d97ceda9511245.camel@gmail.com/ Signed-off-by: Klaus Kudielka --- v1->v2: Be more explicit about the regression, and about the reg property. arch/arm/boot/dts/armada-38x.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/boot/dts/armada-38x.dtsi b/arch/arm/boot/dts/armada-38x.dtsi index 12933eff41..446861b6b1 100644 --- a/arch/arm/boot/dts/armada-38x.dtsi +++ b/arch/arm/boot/dts/armada-38x.dtsi @@ -304,7 +304,7 @@ spdif_pins: spdif-pins { }; gpio0: gpio@18100 { - compatible = "marvell,armadaxp-gpio", + compatible = "marvell,armada-370-gpio", "marvell,orion-gpio"; reg = <0x18100 0x40>, <0x181c0 0x08>; reg-names = "gpio", "pwm"; @@ -323,7 +323,7 @@ gpio0: gpio@18100 { }; gpio1: gpio@18140 { - compatible = "marvell,armadaxp-gpio", + compatible = "marvell,armada-370-gpio", "marvell,orion-gpio"; reg = <0x18140 0x40>, <0x181c8 0x08>; reg-names = "gpio", "pwm"; From patchwork Sat Jan 7 14:41:49 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Klaus Kudielka X-Patchwork-Id: 640208 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id B3B27C46467 for ; Sat, 7 Jan 2023 14:43:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231723AbjAGOn3 (ORCPT ); Sat, 7 Jan 2023 09:43:29 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:53078 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231859AbjAGOn2 (ORCPT ); Sat, 7 Jan 2023 09:43:28 -0500 Received: from mail-wm1-x32d.google.com (mail-wm1-x32d.google.com [IPv6:2a00:1450:4864:20::32d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 711F758F99; Sat, 7 Jan 2023 06:43:27 -0800 (PST) Received: by mail-wm1-x32d.google.com with SMTP id c4-20020a1c3504000000b003d9e2f72093so679165wma.1; Sat, 07 Jan 2023 06:43:27 -0800 (PST) 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 :message-id:reply-to; bh=KflpauUnWgC57RkikrRwZ2S6zi1pavAFyzypxpmWhoY=; b=Tqv56ClWmcwHVhAUExXSWB5Pp3P0Zu7LJIe/Bl+SGUESQ/WQIHSuKzg0Y3jwA2+IIs QKJknyep1mSJ3Z0JDDEyCYB9+fdRAnBJAiz1t43ArrxDA6AcMDGlkgyVfV74tHt1KciO EwWyxR2hAXrAaG+1EkG1yWvv8R9YxCShXQADAMcPTzms3xTr5S7Us2mmyO0P6BHx8eBH eYgEZ+JXQ5tQvNr4xzuCPuVQIPSo87Zf6XL47R11boJZw/PAKNoLNwyi34NISpNqwQOH W8/shlStEn+YnhUgCerNn/lYkf16RtZC2sIit3L9cSJLGft1fBwCp8ZdK47vLIR5f3KA EDOQ== 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:message-id:reply-to; bh=KflpauUnWgC57RkikrRwZ2S6zi1pavAFyzypxpmWhoY=; b=Hkf8vewL6UW2KwlesxT/ePueDO9yMQ1jMMQxiBdzSYV6hDItD6zvsX986zBDkwJBTM V7GTsbq2TAENVdBN/Pr/MvZxZ8IG9pVQa0XfpKydQyUYUZlbKhsCyaelDKPbCnZVHoKD hV7fBI8ic0qJ+15pkFw6ac3zD4YbCclirBagDIQCtVJf2w3I9gglcdXlWXVNKapyTZ6P GmwactD8uKmxuPdyIBPm0OZkVRFDYQSWAtVR/Exe918ptIa5C1z9a039P7se21WHwovL +xInBd/FoqB/pRa/+20ascNgRyTSO0GyQQbgJnacCcY0ZLpiw5x5dbI7RX87ZLD2vaJK xGFQ== X-Gm-Message-State: AFqh2kq/JGekBoB/Doi0Trm4+fXX0BeLX7m5lYGiRg4Ed2GCC59pdu8O Bk3QjoNoiEkg/trRP/Z8QW4= X-Google-Smtp-Source: AMrXdXugbobdJRCM/3Fbu5r/3k2S8rpVOY4LyMoUQ1NuYbYL5zwd0A/ZbX0xojfBzW3C4wk+iHiWtQ== X-Received: by 2002:a05:600c:42c7:b0:3d2:3ae8:885b with SMTP id j7-20020a05600c42c700b003d23ae8885bmr41848980wme.28.1673102605972; Sat, 07 Jan 2023 06:43:25 -0800 (PST) Received: from mars.. ([2a02:168:6806:0:40f6:41b6:8914:e80b]) by smtp.gmail.com with ESMTPSA id h19-20020a05600c351300b003d9a86a13bfsm6056106wmq.28.2023.01.07.06.43.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 07 Jan 2023 06:43:25 -0800 (PST) From: Klaus Kudielka To: "Andrew Lunn" , "Gregory Clement" , "Sebastian Hesselbarth" , "Rob Herring" , "Krzysztof Kozlowski" , =?utf-8?q?Pali_R?= =?utf-8?q?oh=C3=A1r?= , =?utf-8?q?Uwe_Kleine-K=C3=B6nig?= Cc: Thomas Petazzoni , Chris Packham , linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-gpio@vger.kernel.org, linux-kernel@vger.kernel.org, Klaus Kudielka Subject: [PATCH v2 2/2] Revert "ARM: dts: armada-39x: Fix compatible string for gpios" Date: Sat, 7 Jan 2023 15:41:49 +0100 Message-Id: <20230107144149.5743-2-klaus.kudielka@gmail.com> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230107144149.5743-1-klaus.kudielka@gmail.com> References: <20230107144149.5743-1-klaus.kudielka@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org This reverts commit d10886a4e6f85ee18d47a1066a52168461370ded. If compatible = "marvell,armadaxp-gpio", the reg property requires a second (address, size) pair, which points to the per-CPU interrupt registers <0x18800 0x30> / <0x18840 0x30>. Furthermore: Commit 5f79c651e81e explains very well, why the gpio-mvebu driver does not work reliably with per-CPU interrupts. Commit 988c8c0cd04d deprecates compatible = marvell,armadaxp-gpio for this reason. Signed-off-by: Klaus Kudielka Reviewed-by: Andrew Lunn --- v1->v2: Be more explicit about the reg property. arch/arm/boot/dts/armada-39x.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/boot/dts/armada-39x.dtsi b/arch/arm/boot/dts/armada-39x.dtsi index 1e05208d9f..9d1cac49c0 100644 --- a/arch/arm/boot/dts/armada-39x.dtsi +++ b/arch/arm/boot/dts/armada-39x.dtsi @@ -213,7 +213,7 @@ nand_pins: nand-pins { }; gpio0: gpio@18100 { - compatible = "marvell,armadaxp-gpio", "marvell,orion-gpio"; + compatible = "marvell,orion-gpio"; reg = <0x18100 0x40>; ngpios = <32>; gpio-controller; @@ -227,7 +227,7 @@ gpio0: gpio@18100 { }; gpio1: gpio@18140 { - compatible = "marvell,armadaxp-gpio", "marvell,orion-gpio"; + compatible = "marvell,orion-gpio"; reg = <0x18140 0x40>; ngpios = <28>; gpio-controller;