From mboxrd@z Thu Jan 1 00:00:00 1970 From: Thomas Monjalon Subject: Re: [PATCH 6/7] i40evf: fix for copying wrong size of link info, and remove an useless function Date: Fri, 20 Jun 2014 16:28:34 +0200 Message-ID: <2688891.cpSxDN6sGo@xps13> References: <1403244889-21358-1-git-send-email-helin.zhang@intel.com> <1403244889-21358-7-git-send-email-helin.zhang@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7Bit Cc: dev-VfR2kkLFssw@public.gmane.org To: Helin Zhang Return-path: In-Reply-To: <1403244889-21358-7-git-send-email-helin.zhang-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org> List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces-VfR2kkLFssw@public.gmane.org Sender: "dev" 2014-06-20 14:14, Helin Zhang: > Delete the inline function which is not used at this moment. > Fix the bug of copying wrong size of link info in function of > i40evf_get_link_status(). There are 2 patches here. Please split. > static inline int > -i40evf_dev_atomic_read_link_status(struct rte_eth_dev *dev, > - struct rte_eth_link *link) > -{ > - struct rte_eth_link *dst = link; > - struct rte_eth_link *src = &(dev->data->dev_link); > - > - if (rte_atomic64_cmpset((uint64_t *)dst, *(uint64_t *)dst, > - *(uint64_t *)src) == 0) > - return -1; > - > - return 0; > -} Not directly related to this patch, but it could be a good idea to start using rte_eth_dev_atomic_read_link_status() instead of copying this function in each PMD. -- Thomas