Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp4171668pxu; Tue, 20 Oct 2020 09:52:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzU1lDep01Xlk70QEFXhR3q3yG70XlMAmjbhiJMsl5dRCP/Ba4Visc0vGq3+nNj7XK7jFIV X-Received: by 2002:a17:906:7e53:: with SMTP id z19mr4059713ejr.334.1603212772650; Tue, 20 Oct 2020 09:52:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1603212772; cv=none; d=google.com; s=arc-20160816; b=RJEBPZ9gUMPHzEuAKr3qEKyYuah63WFZlVwdzeGxWkwCi/sjR5Cpv9paL4nKzJvsas Sa6xvhOi8gmHfQMHrcIZLX9/RteiX9adCH8MvtpZK9GPw3ilRuWaa62/JIXpymhCdvKx T+MdOotfyRtnqcqJjZ5ewlJpNg0naZY9pIWpHvIbyzv0XT7IEty+APYRpJI8rIevmSS5 V6tf3SUIsbz6vcIbrthNCJpBP2adbdeR/X0FLTz0PCrcPdIbbPEbJaEt+Mip7XO3EozZ i0urqK8am3TGb14IRYkR5K+PQlz6gHMPoxCXZmBqT/Q928cveXqpYZVgwiCgnUT38LwH fiww== 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 :references:in-reply-to:date:cc:to:from:subject:message-id; bh=pzB9yYyl+PNgnxZJAiwr3FSf4IPQyAmM7B374xhaA9c=; b=Y/NbIockc/oQGq0N8Y7rtaNFX54UEkTBPOVLvsWElUR0jteveOrw4G8ahvG6ni285y aF5CQTqmqFtLt1udiSv+9O5HFMqMBNQO4R7f53sAUrzwTgyl7/rbPm0ow+ZJiCqxg4ps kKGIxTvuzeAFc+sNPPGeGPg0UEb4Jpgh0ltE7A6XigxLJNgHpehnqENNYMkrgtG7/BX+ FKRi1vRQwIRUNhxw6BtdUXUpy/4j2mBGvERgkc1+Hc+Un2m0B2e44Zoq42p3bZP1fWlz reYhTadnO4FkQZdidmEfSF4t+Plxe6w0H9oBug+Cb/69PVkb2B1xp/rY3ZF1Ud+v+70H dzBg== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id y1si1428005edp.57.2020.10.20.09.52.30; Tue, 20 Oct 2020 09:52:52 -0700 (PDT) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388994AbgJSX0q (ORCPT + 99 others); Mon, 19 Oct 2020 19:26:46 -0400 Received: from kernel.crashing.org ([76.164.61.194]:42628 "EHLO kernel.crashing.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729385AbgJSX0q (ORCPT ); Mon, 19 Oct 2020 19:26:46 -0400 Received: from localhost (gate.crashing.org [63.228.1.57]) (authenticated bits=0) by kernel.crashing.org (8.14.7/8.14.7) with ESMTP id 09JNQHHe024378 (version=TLSv1/SSLv3 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Mon, 19 Oct 2020 18:26:20 -0500 Message-ID: Subject: Re: [PATCH 4/4] ftgmac100: Restart MAC HW once From: Benjamin Herrenschmidt To: Dylan Hung , davem@davemloft.net, kuba@kernel.org, netdev@vger.kernel.org, linux-kernel@vger.kernel.org, ratbert@faraday-tech.com, linux-aspeed@lists.ozlabs.org, openbmc@lists.ozlabs.org Cc: BMC-SW@aspeedtech.com, Joel Stanley Date: Tue, 20 Oct 2020 10:26:17 +1100 In-Reply-To: <20201019085717.32413-5-dylan_hung@aspeedtech.com> References: <20201019085717.32413-1-dylan_hung@aspeedtech.com> <20201019085717.32413-5-dylan_hung@aspeedtech.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.2 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 2020-10-19 at 16:57 +0800, Dylan Hung wrote: > The interrupt handler may set the flag to reset the mac in the > future, > but that flag is not cleared once the reset has occured. > > Fixes: 10cbd6407609 ("ftgmac100: Rework NAPI & interrupts handling") > Signed-off-by: Dylan Hung > Signed-off-by: Joel Stanley Acked-by: Benjamin Herrenschmidt > --- > drivers/net/ethernet/faraday/ftgmac100.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/net/ethernet/faraday/ftgmac100.c > b/drivers/net/ethernet/faraday/ftgmac100.c > index 0c67fc3e27df..57736b049de3 100644 > --- a/drivers/net/ethernet/faraday/ftgmac100.c > +++ b/drivers/net/ethernet/faraday/ftgmac100.c > @@ -1326,6 +1326,7 @@ static int ftgmac100_poll(struct napi_struct > *napi, int budget) > */ > if (unlikely(priv->need_mac_restart)) { > ftgmac100_start_hw(priv); > + priv->need_mac_restart = false; > > /* Re-enable "bad" interrupts */ > ftgmac100_write(FTGMAC100_INT_BAD, priv->base + > FTGMAC100_OFFSET_IER);