From mboxrd@z Thu Jan 1 00:00:00 1970 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) Received: from pps.filterd (m0053301.ppops.net [127.0.0.1]) by mx0a-00191d01.pphosted.com (8.16.0.17/8.16.0.17) with SMTP id u9JMJ4pa015904; Wed, 19 Oct 2016 18:23:42 -0400 Received: from alpi155.enaf.aldc.att.com (sbcsmtp7.sbc.com [144.160.229.24]) by mx0a-00191d01.pphosted.com with ESMTP id 266hh484mn-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Wed, 19 Oct 2016 18:23:42 -0400 Received: from enaf.aldc.att.com (localhost [127.0.0.1]) by alpi155.enaf.aldc.att.com (8.14.5/8.14.5) with ESMTP id u9JMNees030049; Wed, 19 Oct 2016 18:23:41 -0400 Received: from mlpi407.sfdc.sbc.com (mlpi407.sfdc.sbc.com [130.9.128.239]) by alpi155.enaf.aldc.att.com (8.14.5/8.14.5) with ESMTP id u9JMNUoK029879 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NO); Wed, 19 Oct 2016 18:23:34 -0400 Received: from clpi183.sldc.sbc.com (clpi183.sldc.sbc.com [135.41.1.46]) by mlpi407.sfdc.sbc.com (RSA Interceptor); Wed, 19 Oct 2016 22:23:16 GMT Received: from sldc.sbc.com (localhost [127.0.0.1]) by clpi183.sldc.sbc.com (8.14.5/8.14.5) with ESMTP id u9JMNFeE011713; Wed, 19 Oct 2016 17:23:15 -0500 Received: from mail-green.research.att.com (mail-green.research.att.com [135.207.255.15]) by clpi183.sldc.sbc.com (8.14.5/8.14.5) with ESMTP id u9JMN87d011413; Wed, 19 Oct 2016 17:23:09 -0500 Received: from cheetah.research.att.com (mt-230-10.research.att.com [135.207.230.10]) by mail-green.research.att.com (Postfix) with ESMTP id 8C38EE07C3; Wed, 19 Oct 2016 18:22:58 -0400 (EDT) From: "E. Scott Daniels" To: helin.zhang@intel.com, bernard.iremonger@intel.com Cc: dev@dpdk.org, az5157@att.com, "E. Scott Daniels" Date: Wed, 19 Oct 2016 18:23:06 -0400 Message-Id: <1476915787-28205-1-git-send-email-daniels@research.att.com> X-Mailer: git-send-email 2.1.4 X-RSA-Inspected: yes X-RSA-Classifications: public X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:, , definitions=2016-10-19_18:, , signatures=0 X-Proofpoint-Spam-Details: rule=outbound_policy_notspam policy=outbound_policy score=0 priorityscore=1501 malwarescore=0 suspectscore=2 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 impostorscore=0 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1609300000 definitions=main-1610190395 Subject: [dpdk-dev] [PATCH] net/ixgbe: prevent duplicate callback on list 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: Wed, 19 Oct 2016 22:23:43 -0000 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