From mboxrd@z Thu Jan 1 00:00:00 1970 From: "E. Scott Daniels" Subject: [PATCH] net/ixgbe: prevent duplicate callback on list Date: Wed, 19 Oct 2016 18:23:06 -0400 Message-ID: <1476915787-28205-1-git-send-email-daniels@research.att.com> Cc: dev@dpdk.org, az5157@att.com, "E. Scott Daniels" To: helin.zhang@intel.com, bernard.iremonger@intel.com Return-path: Received: from mx0a-00191d01.pphosted.com (mx0a-00191d01.pphosted.com [67.231.149.140]) by dpdk.org (Postfix) with ESMTP id 1186B6CD1 for ; Thu, 20 Oct 2016 00:23:42 +0200 (CEST) List-Id: patches and discussions about DPDK List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" If rte_eth_dev_callback_register() is invoked with parameters which match a callback struct that is already on the list, an attempt is made to add that same struct onto the tail of the list. Adding a struct which is already on the list will have undesired results. This is an edge case, but I think it should be corrected; patch prevents the attempt to add a struct which is already on the list. E. Scott Daniels (1): net/ixgbe: prevent duplicate callback on list lib/librte_ether/rte_ethdev.c | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) -- 1.9.1