Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp822003pxb; Tue, 3 Nov 2020 13:31:27 -0800 (PST) X-Google-Smtp-Source: ABdhPJyvbDW6bMM4BXRmg33pLGROZXF94Q8mm9OsoMb2FHl0r9bYV3lTfro2r6CaYu8F3gbLrtWO X-Received: by 2002:a17:906:3553:: with SMTP id s19mr22804329eja.195.1604439087531; Tue, 03 Nov 2020 13:31:27 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1604439087; cv=none; d=google.com; s=arc-20160816; b=p0gZXiosNQcvQ+BaZjSSmT2/DQG0lwcGaJK70bt+4bYicdNjQt1a/v0wX7QI3Nc/vS SJmlorcrwxTJ3Jhed4PY9UGmewDWeYdOBKrcVCL9sncw7FlAJT2RFgUQTJqnL5T7rkUH SFmljjRmX6/uTp+UNGdjCV7tI3KY2nnSKZ7SLMPV0qZpZW8Cunh5ZB9TIokDmTpWIs5h 1v3ayUBKSbzeolJZrf7+ryZ0P4KUBoZHKKmQscm+dIR+GjKXxskUHWANWV6qS8e8dYxi SKSUsMgF3JPcIpInHeSVsjeFTVGJn4zZK2+3xVVWsdBH10Mad9Gqn8N9e+SD+bTzM0pw Ac2g== 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 :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=XRnUavava9L5oAKGDQCN8ZbUx//rMZ98kjV7qv7dhes=; b=pI/ai/yn83rhzNaWVfCcdKmycYUvWkImHJq//q/YSl3PoJrwqWL2nNcsn5TlqXZxQ3 ssNS0Jd9M+hhWqjjOH+vzgHaMGmz6usVRPKWzZr4sxzxeeLiv+NqggLEW5rBsr5SDyqL HCFPahQq8QcL7RWqRoSNmOqEQMeqtQCE9QMSD1MEPA5EWogewBfjlZLeBKC5DtLTxgFh kcqKFRjanGNidZ+Hqdkqu3+Zq4zzvu97l1nQkqehZ9q2drvl0QPITzk9yWuIqXbhG9hR U4yVh6VH9ll4e3wbFf+jrqKw1BDS/0QvpzW3JTWQuiNO3Fl1wsnyBXz0IeKrFBv1TC4J sTyA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=CYEuFqgo; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a15si16768637edr.134.2020.11.03.13.31.03; Tue, 03 Nov 2020 13:31:27 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=CYEuFqgo; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2387487AbgKCV0h (ORCPT + 99 others); Tue, 3 Nov 2020 16:26:37 -0500 Received: from mail.kernel.org ([198.145.29.99]:38290 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2387489AbgKCVBh (ORCPT ); Tue, 3 Nov 2020 16:01:37 -0500 Received: from localhost (83-86-74-64.cable.dynamic.v4.ziggo.nl [83.86.74.64]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id C90BD205ED; Tue, 3 Nov 2020 21:01:35 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1604437296; bh=cBv7bCa5DN5GL0FC9D07roe0em+cEVL62V6/umXO+GM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=CYEuFqgoOZsmOidhlHCOw/PQNIHkd2Cp3uNZx/bpqJ/58DXlwGke464bp0WdoAnSL TLNqo/mM8mXz8YkJv1LBsNHbicze2t1XM/9dr/ZDwI3nh0HYg3DB0jZbyB4d5UN2i2 uCnLXbbY9/4PrhiLW1M4Ff/ouhTEzRTDz9zHttHQ= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Serge Belyshev , Heiner Kallweit , Jakub Kicinski Subject: [PATCH 4.19 016/191] r8169: fix issue with forced threading in combination with shared interrupts Date: Tue, 3 Nov 2020 21:35:08 +0100 Message-Id: <20201103203234.799035924@linuxfoundation.org> X-Mailer: git-send-email 2.29.2 In-Reply-To: <20201103203232.656475008@linuxfoundation.org> References: <20201103203232.656475008@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Heiner Kallweit [ Upstream commit 2734a24e6e5d18522fbf599135c59b82ec9b2c9e ] As reported by Serge flag IRQF_NO_THREAD causes an error if the interrupt is actually shared and the other driver(s) don't have this flag set. This situation can occur if a PCI(e) legacy interrupt is used in combination with forced threading. There's no good way to deal with this properly, therefore we have to remove flag IRQF_NO_THREAD. For fixing the original forced threading issue switch to napi_schedule(). Fixes: 424a646e072a ("r8169: fix operation under forced interrupt threading") Link: https://www.spinics.net/lists/netdev/msg694960.html Reported-by: Serge Belyshev Signed-off-by: Heiner Kallweit Tested-by: Serge Belyshev Link: https://lore.kernel.org/r/b5b53bfe-35ac-3768-85bf-74d1290cf394@gmail.com Signed-off-by: Jakub Kicinski Signed-off-by: Greg Kroah-Hartman --- drivers/net/ethernet/realtek/r8169.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- a/drivers/net/ethernet/realtek/r8169.c +++ b/drivers/net/ethernet/realtek/r8169.c @@ -6630,7 +6630,7 @@ static irqreturn_t rtl8169_interrupt(int return IRQ_NONE; rtl_irq_disable(tp); - napi_schedule_irqoff(&tp->napi); + napi_schedule(&tp->napi); return IRQ_HANDLED; } @@ -6886,7 +6886,7 @@ static int rtl_open(struct net_device *d rtl_request_firmware(tp); retval = request_irq(pci_irq_vector(pdev, 0), rtl8169_interrupt, - IRQF_NO_THREAD | IRQF_SHARED, dev->name, tp); + IRQF_SHARED, dev->name, tp); if (retval < 0) goto err_release_fw_2;