From patchwork Fri Oct 6 22:15:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Doug Anderson X-Patchwork-Id: 13412063 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 69C8DE94136 for ; Fri, 6 Oct 2023 22:16:29 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-ID:Date:Subject:Cc:To:From: Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=mKHn8MHAksMieZVNplmzQ9td3WQY/zTB+/6WLDFqzoc=; b=rW0Uh3Y5+XIc1PB3eeRefrsGYn yaDvAFncD36P3/NK+Ou4A8UeTRdBK5wYGfrsMJFtwg09e2ZOkZ4wrdRRne/lcjMLjm537Xu9BjT3q oE4k5xTKIjScf7Btb2rGyVD4yo5jlQOHCX2DoEM5vyPRqo4QLvQo3AxP0SFUnb64S7BbOEAqhmJ5S axGw9611l9o8HjqME0Ohw+Z57SoFVbs1xCgUedr7T+8cxxZ23eeJpTi7n1GnDWub19Pk3eEpxeuiV nO5zikiEjP8iRLuhsT/DeveoPjCx0kkPoZmh39Fdrqo0htfVjo+etDQ/lpnxTDrw/YqDeXdWm86Hl vVbZ7Z1Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.96 #2 (Red Hat Linux)) id 1qot7V-006Zpt-0X; Fri, 06 Oct 2023 22:16:29 +0000 Received: from mail-pg1-x52f.google.com ([2607:f8b0:4864:20::52f]) by bombadil.infradead.org with esmtps (Exim 4.96 #2 (Red Hat Linux)) id 1qot7S-006Zmp-2P for linux-mediatek@lists.infradead.org; Fri, 06 Oct 2023 22:16:28 +0000 Received: by mail-pg1-x52f.google.com with SMTP id 41be03b00d2f7-5892832f8daso2949009a12.0 for ; Fri, 06 Oct 2023 15:16:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1696630582; x=1697235382; darn=lists.infradead.org; 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=mKHn8MHAksMieZVNplmzQ9td3WQY/zTB+/6WLDFqzoc=; b=fscSDqqyAZgY6b/zgMJgeqovbMbynHUuPe68fS3HGoqIHM1c/QWgYxFNdb5R1Dx+jH U4H8BVj/gtZybWxYhCvFGXkJxYTWA+mh8qvnqRFR7uwqNXvwQBK+vEbkVHgal7jFi5pA rkGOKn4sMwLAMAciAkVV7Mb56TiZYMa82+BQQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1696630582; x=1697235382; 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=mKHn8MHAksMieZVNplmzQ9td3WQY/zTB+/6WLDFqzoc=; b=Ul33oC841oxvNsGDzFgxpcVer+F9JNDPbwvbN/T13m/0j1qd4tGoepuSz2LhYGdbZa VRT4XMUJNyKYxhplrDdISX27kDcEnWXqhA8E/ECA7u4DK4Vff2poTAHGBm0P9yQ42mTi pwJF/g2T0JYYnEAMLtFyYqWmLv6G+XpLTJL7/YWrjihXaJ2LQfuc/xwu7TsGL9kRKMeQ B2wxDkuygK/GdpNGdfUN+V8NjqJN9UDdmEd2tBw6inXqUNWgSaEgAugEsUg5TQq3Vmp3 HY3+9wysp+HL0h678/ugJ2TyzBHwAYv2hbgeSKVhGbUiyPwIzmVgyHx0RmzbeB2CJD21 eCKQ== X-Gm-Message-State: AOJu0YxKe8AsRNLKZdOxk9Nw0qR/Rbd67bmaFrnGBP1kUOwDzafDwr9C 89w2dBR6datD/ZRRmNZgMjxNNw== X-Google-Smtp-Source: AGHT+IFtVb4aW+OND3UEg2HZFIAKdVlqCxraW/RlbV8GK+Xlw6U93GKGB3E+X4qacvY9EjVOr1BC8g== X-Received: by 2002:a17:90b:3907:b0:276:5512:13ab with SMTP id ob7-20020a17090b390700b00276551213abmr8650294pjb.10.1696630582413; Fri, 06 Oct 2023 15:16:22 -0700 (PDT) Received: from tictac2.mtv.corp.google.com ([2620:15c:9d:2:1f37:5459:32bf:faf9]) by smtp.gmail.com with ESMTPSA id rj6-20020a17090b3e8600b00276e8e4f1fbsm5946523pjb.1.2023.10.06.15.16.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 06 Oct 2023 15:16:21 -0700 (PDT) From: Douglas Anderson To: Marc Zyngier , Mark Rutland , Catalin Marinas , Will Deacon , Chen-Yu Tsai Cc: Douglas Anderson , AngeloGioacchino Del Regno , Matthias Brugger , Thomas Gleixner , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org Subject: [PATCH 3/3] irqchip/gic-v3: Remove Mediatek pseudo-NMI firmware quirk handling Date: Fri, 6 Oct 2023 15:15:53 -0700 Message-ID: <20231006151547.3.Ie582d33cfe46f9ec2248e7f2dabdd6bbd66486a6@changeid> X-Mailer: git-send-email 2.42.0.609.gbb76f46606-goog In-Reply-To: <20231006151547.1.Ide945748593cffd8ff0feb9ae22b795935b944d6@changeid> References: <20231006151547.1.Ide945748593cffd8ff0feb9ae22b795935b944d6@changeid> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20231006_151626_844192_DE6FB1E4 X-CRM114-Status: GOOD ( 13.19 ) X-BeenThere: linux-mediatek@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-mediatek" Errors-To: linux-mediatek-bounces+linux-mediatek=archiver.kernel.org@lists.infradead.org This is a partial revert of commit 44bd78dd2b88 ("irqchip/gic-v3: Disable pseudo NMIs on Mediatek devices w/ firmware issues"). In the patch ("arm64: Disable GiC priorities on Mediatek devices w/ firmware issues") we've moved the quirk handling to another place and so it's not needed in the GiC driver. NOTE: this isn't a full revert because it leaves some of the changes to the "quirks" structure around in case future code needs it. Signed-off-by: Douglas Anderson Acked-by: Mark Rutland --- drivers/irqchip/irq-gic-v3.c | 22 +--------------------- 1 file changed, 1 insertion(+), 21 deletions(-) diff --git a/drivers/irqchip/irq-gic-v3.c b/drivers/irqchip/irq-gic-v3.c index 787ccc880b22..9ff776709ae6 100644 --- a/drivers/irqchip/irq-gic-v3.c +++ b/drivers/irqchip/irq-gic-v3.c @@ -39,8 +39,7 @@ #define FLAGS_WORKAROUND_GICR_WAKER_MSM8996 (1ULL << 0) #define FLAGS_WORKAROUND_CAVIUM_ERRATUM_38539 (1ULL << 1) -#define FLAGS_WORKAROUND_MTK_GICR_SAVE (1ULL << 2) -#define FLAGS_WORKAROUND_ASR_ERRATUM_8601001 (1ULL << 3) +#define FLAGS_WORKAROUND_ASR_ERRATUM_8601001 (1ULL << 2) #define GIC_IRQ_TYPE_PARTITION (GIC_IRQ_TYPE_LPI + 1) @@ -1790,15 +1789,6 @@ static bool gic_enable_quirk_msm8996(void *data) return true; } -static bool gic_enable_quirk_mtk_gicr(void *data) -{ - struct gic_chip_data *d = data; - - d->flags |= FLAGS_WORKAROUND_MTK_GICR_SAVE; - - return true; -} - static bool gic_enable_quirk_cavium_38539(void *data) { struct gic_chip_data *d = data; @@ -1891,11 +1881,6 @@ static const struct gic_quirk gic_quirks[] = { .compatible = "asr,asr8601-gic-v3", .init = gic_enable_quirk_asr8601, }, - { - .desc = "GICv3: Mediatek Chromebook GICR save problem", - .property = "mediatek,broken-save-restore-fw", - .init = gic_enable_quirk_mtk_gicr, - }, { .desc = "GICv3: HIP06 erratum 161010803", .iidr = 0x0204043b, @@ -1957,11 +1942,6 @@ static void gic_enable_nmi_support(void) if (!gic_prio_masking_enabled()) return; - if (gic_data.flags & FLAGS_WORKAROUND_MTK_GICR_SAVE) { - pr_warn("Skipping NMI enable due to firmware issues\n"); - return; - } - rdist_nmi_refs = kcalloc(gic_data.ppi_nr + SGI_NR, sizeof(*rdist_nmi_refs), GFP_KERNEL); if (!rdist_nmi_refs)