From mboxrd@z Thu Jan 1 00:00:00 1970 From: Song Liu Subject: Re: pegged softirq and NAPI race (?) Date: Tue, 18 Sep 2018 21:21:54 +0000 Message-ID: <117A22DB-A4CF-4FFB-AD08-A187E9F6EEB3@fb.com> References: <0FD562CC-CDE9-43C8-9623-B42AC7A208C8@fb.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Cc: Alexei Starovoitov , netdev , "Jeff Kirsher" , Alexander Duyck , "michael.chan@broadcom.com" , Kernel Team To: Eric Dumazet Return-path: Received: from mx0a-00082601.pphosted.com ([67.231.145.42]:48376 "EHLO mx0a-00082601.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726821AbeISC4c (ORCPT ); Tue, 18 Sep 2018 22:56:32 -0400 In-Reply-To: Content-Language: en-US Content-ID: <50937DF3F02752429AAA1E2F8CE10FDF@namprd15.prod.outlook.com> Sender: netdev-owner@vger.kernel.org List-ID: > On Sep 18, 2018, at 2:13 PM, Eric Dumazet wrote: >=20 > On Tue, Sep 18, 2018 at 1:37 PM Song Liu wrote: >>=20 >=20 >> Looks like a patch like the following fixes the issue for ixgbe. But I >> cannot explain it yet. >>=20 >> Does this ring a bell? >=20 > I dunno, it looks like the NIC is generating an interrupt while it shoul= d not, > and constantly sets NAPI_STATE_MISSED. >=20 > Or maybe we need to properly check napi_complete_done() return value. >=20 > diff --git a/drivers/net/ethernet/intel/ixgb/ixgb_main.c > b/drivers/net/ethernet/intel/ixgb/ixgb_main.c > index d3e72d0f66ef428b08e4bd88508e05b734bc43a4..c4c565c982a98a5891603cedc= dcb72dc1c401813 > 100644 > --- a/drivers/net/ethernet/intel/ixgb/ixgb_main.c > +++ b/drivers/net/ethernet/intel/ixgb/ixgb_main.c > @@ -1773,8 +1773,8 @@ ixgb_clean(struct napi_struct *napi, int budget) > ixgb_clean_rx_irq(adapter, &work_done, budget); >=20 > /* If budget not fully consumed, exit the polling mode */ > - if (work_done < budget) { > - napi_complete_done(napi, work_done); > + if (work_done < budget && > + napi_complete_done(napi, work_done)) { > if (!test_bit(__IXGB_DOWN, &adapter->flags)) > ixgb_irq_enable(adapter); > } Thanks Eric! I was looking at exactly this part. :) And it seems working! I will run a bigger test and update shortly.=20 Best, Song=