From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by dpdk.org (Postfix) with ESMTP id 1EB5E326C for ; Fri, 28 Oct 2016 13:05:23 +0200 (CEST) Received: from orsmga003.jf.intel.com ([10.7.209.27]) by orsmga102.jf.intel.com with ESMTP; 28 Oct 2016 04:05:05 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.31,557,1473145200"; d="scan'208";a="895055244" Received: from fyigit-mobl1.ger.corp.intel.com (HELO [10.237.220.146]) ([10.237.220.146]) by orsmga003.jf.intel.com with ESMTP; 28 Oct 2016 04:05:03 -0700 To: Qiming Yang , dev@dpdk.org References: <1477369146-63317-2-git-send-email-qiming.yang@intel.com> <1477628339-5816-1-git-send-email-qiming.yang@intel.com> <1477628339-5816-2-git-send-email-qiming.yang@intel.com> From: Ferruh Yigit Message-ID: <7b1cbf2e-99f1-95f9-a579-f88199153ad0@intel.com> Date: Fri, 28 Oct 2016 12:05:02 +0100 User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64; rv:45.0) Gecko/20100101 Thunderbird/45.4.0 MIME-Version: 1.0 In-Reply-To: <1477628339-5816-2-git-send-email-qiming.yang@intel.com> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Subject: Re: [dpdk-dev] [PATCH v3 2/2] net/i40e: fix VF bonded device link down X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 28 Oct 2016 11:05:24 -0000 Hi Qiming, On 10/28/2016 5:18 AM, Qiming Yang wrote: > If VF device is used as slave of a bond device, it will be polled > periodically through alarm. Interrupt is involved here. And then > VF will send I40E_VIRTCHNL_OP_GET_LINK_STAT message to > PF to query the status. The response is handled by interrupt > callback. Interrupt is involved here again. That's why bond > device cannot bring up. > > This patch removes I40E_VIRTCHNL_OP_GET_LINK_STAT > message. Link status in VF driver will be updated when PF driver > notify it, and VF stores this link status locally. VF driver just > returns the local status when being required. > > Fixes: 4861cde46116 ("i40e: new poll mode driver") > > Signed-off-by: Qiming Yang > --- <...> > static void > +i40e_notify_all_vfs_link_status(struct rte_eth_dev *dev) > +{ > + struct i40e_pf *pf = I40E_DEV_PRIVATE_TO_PF(dev->data->dev_private); > + struct i40e_virtchnl_pf_event event; > + int i; > + > + event.event = I40E_VIRTCHNL_EVENT_LINK_CHANGE; > + event.event_data.link_event.link_status = > + dev->data->dev_link.link_status; > + event.event_data.link_event.link_speed = > + dev->data->dev_link.link_speed; This gives a compilation error with icc [1], casting to enum will be enough to fix I guess. [1] .../drivers/net/i40e/i40e_ethdev.c(5453): error #188: enumerated type mixed with another type event.event_data.link_event.link_speed = ^ <...> > diff --git a/drivers/net/i40e/i40e_pf.c b/drivers/net/i40e/i40e_pf.c > index d5b2d45..350f6a0 100644 <...> > > +static void > +i40e_notify_vf_link_status(struct rte_eth_dev *dev, struct i40e_pf_vf *vf) > +{ > + struct i40e_virtchnl_pf_event event; > + > + event.event = I40E_VIRTCHNL_EVENT_LINK_CHANGE; > + event.event_data.link_event.link_status = > + dev->data->dev_link.link_status; > + event.event_data.link_event.link_speed = > + dev->data->dev_link.link_speed; Same error here: .../drivers/net/i40e/i40e_pf.c(908): error #188: enumerated type mixed with another type event.event_data.link_event.link_speed = ^ And while sending a new version of the patch, can you please: 1- CC the maintainers 2- Patchset already acked by Jingjing, keep the ack in the patches. Thanks, ferruh