From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr1-f65.google.com (mail-wr1-f65.google.com [209.85.221.65]) by dpdk.org (Postfix) with ESMTP id BF2CD1B466 for ; Tue, 9 Oct 2018 12:32:33 +0200 (CEST) Received: by mail-wr1-f65.google.com with SMTP id w5-v6so1238919wrt.2 for ; Tue, 09 Oct 2018 03:32:33 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:subject:from:to:cc:date:in-reply-to :references:content-transfer-encoding:mime-version; bh=epflJgUjRZ9ZboYvqEFdKAngquXw63qExGWcJRG7Nt8=; b=qp5JGA2uoPiTwfz7tkND4VeWf7EjMfKCY4OQdHXUOIVmPlu4FZeRtye6EryvfHdshi nQM8Z3FIpKA6If+u8HVcYpB7BDHI3vqvVYKe5mbN5E9yBeFKTfrRkRx3M31Oz0EC4JFa b8kd4FfvQNCNaAWbiFkg37UeuftwKrejDaTAlvtgHSAwAQ9ILzw/Y5bsj7NmaYbZcEKS vjXVRhcXs/e9JiJLEhrlv26mHbtR14trYaEC8wEzH7dpa6G09PF5L8pYAeoYJktINsAN mH0g0X0stqwaZ+iAqvia11H3yNdcC2n2X8GUkWp0xrXGHxxXcQNKQgOh79QpQ016trKK 8r0w== X-Gm-Message-State: ABuFfoj9FGOgC+kmdcS8oCaUkWDQpg66QOegqt2lW9lcoTZZDgHHNRkq E2AmReJlDMavtRUyvYEcJwPRVW5f X-Google-Smtp-Source: ACcGV60RjE9s0KF2V2iCC1qTU/64wYREphmojxActN/CdkrexZ9cS/25iI0PkwXE0kyHFTm2oj+m5g== X-Received: by 2002:adf:e7cb:: with SMTP id e11-v6mr20017552wrn.27.1539081153214; Tue, 09 Oct 2018 03:32:33 -0700 (PDT) Received: from localhost ([2a01:4b00:f419:6f00:8361:8946:ba2b:d556]) by smtp.gmail.com with ESMTPSA id 12-v6sm16862439wms.11.2018.10.09.03.32.31 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 09 Oct 2018 03:32:32 -0700 (PDT) Message-ID: <1539081151.8721.24.camel@debian.org> From: Luca Boccassi To: "Zhao1, Wei" , "dev@dpdk.org" Cc: "Lu, Wenzhuo" , "Zhang, Qi Z" Date: Tue, 09 Oct 2018 11:32:31 +0100 In-Reply-To: References: <20180727181317.7374-1-bluca@debian.org> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Mailer: Evolution 3.22.6-1+deb9u1 Mime-Version: 1.0 Subject: Re: [dpdk-dev] [PATCH] net/e1000: enable MSI-x for linkup and other events in 82574 X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 09 Oct 2018 10:32:33 -0000 On Tue, 2018-10-09 at 10:16 +0000, Zhao1, Wei wrote: > Hi,=C2=A0=C2=A0Luca Boccassi >=20 > =C2=A0=C2=A0=C2=A0A question for this feature, in em code, function > eth_em_interrupt_handler() we have no process for handle other cause > interrupt. > So, why do we enable this OTHER cause interrupt in DPDK? > You mean some application may take advance of this interrupt for some > unknown purpose when using DPDK? Hi, This MSI-x interrupt is for link state change, which is already handled by the driver. As mentioned, without this link state change for the 82574 NIC does not work. >=20 > =C2=A0 > > -----Original Message----- > > From: dev [mailto:dev-bounces@dpdk.org] On Behalf Of Luca Boccassi > > Sent: Saturday, July 28, 2018 2:13 AM > > To: dev@dpdk.org > > Cc: Lu, Wenzhuo ; Luca Boccassi > > > > Subject: [dpdk-dev] [PATCH] net/e1000: enable MSI-x for linkup and > > other > > events in 82574 > >=20 > > Linux supports 82574 MSI-x interrupt for linkup and other link > > conditions. > > Enable the same feature in the e1000 PMD in order to allow this > > card to work > > properly, as it requires interrupt handling for link negotiations > > among other > > things. > >=20 > > Signed-off-by: Luca Boccassi > > --- > >=20 > > Hi Wenzhuo - just to make it clear, this patch and the previous are > > not > > targeted for 18.08, just clearing my queue. > >=20 > > =C2=A0drivers/net/e1000/base/e1000_82571.c | 5 +++++ > > =C2=A0drivers/net/e1000/em_ethdev.c=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0=C2=A0= =C2=A0=C2=A0| 5 +++-- > > =C2=A02 files changed, 8 insertions(+), 2 deletions(-) > >=20 > > diff --git a/drivers/net/e1000/base/e1000_82571.c > > b/drivers/net/e1000/base/e1000_82571.c > > index 7c279dbb3..397dd9482 100644 > > --- a/drivers/net/e1000/base/e1000_82571.c > > +++ b/drivers/net/e1000/base/e1000_82571.c > > @@ -1257,6 +1257,11 @@ STATIC s32 e1000_init_hw_82571(struct > > e1000_hw > > *hw) > > =C2=A0 =C2=A0*/ > > =C2=A0 e1000_clear_hw_cntrs_82571(hw); > >=20 > > + /* MSI-X configure for 82574 */ > > + if (mac->type =3D=3D e1000_82574) > > + E1000_WRITE_REG(hw, E1000_IVAR, > > + (E1000_IVAR_INT_ALLOC_VALID << > > 16)); > > + > > =C2=A0 return ret_val; > > =C2=A0} > >=20 > > diff --git a/drivers/net/e1000/em_ethdev.c > > b/drivers/net/e1000/em_ethdev.c index 7039dc100..bd05e4de0 100644 > > --- a/drivers/net/e1000/em_ethdev.c > > +++ b/drivers/net/e1000/em_ethdev.c > > @@ -1444,7 +1444,8 @@ eth_em_interrupt_setup(struct rte_eth_dev > > *dev) > > =C2=A0 /* clear interrupt */ > > =C2=A0 E1000_READ_REG(hw, E1000_ICR); > > =C2=A0 regval =3D E1000_READ_REG(hw, E1000_IMS); > > - E1000_WRITE_REG(hw, E1000_IMS, regval | E1000_ICR_LSC); > > + E1000_WRITE_REG(hw, E1000_IMS, > > + regval | E1000_ICR_LSC | E1000_ICR_OTHER); > > =C2=A0 return 0; > > =C2=A0} > >=20 > > @@ -1494,7 +1495,7 @@ em_rxq_intr_enable(struct e1000_hw > > *hw)=C2=A0=C2=A0static > > void=C2=A0=C2=A0em_lsc_intr_disable(struct e1000_hw *hw)=C2=A0=C2=A0{ > > - E1000_WRITE_REG(hw, E1000_IMC, E1000_IMS_LSC); > > + E1000_WRITE_REG(hw, E1000_IMC, E1000_IMS_LSC | > > E1000_IMS_OTHER); > > =C2=A0 E1000_WRITE_FLUSH(hw); > > =C2=A0} > >=20 > > -- > > 2.18.0 >=20 >=20 --=20 Kind regards, Luca Boccassi