From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-ob0-f174.google.com (mail-ob0-f174.google.com [209.85.214.174]) by dpdk.org (Postfix) with ESMTP id D3A88BDC2 for ; Wed, 3 Jun 2015 21:08:18 +0200 (CEST) Received: by obew15 with SMTP id w15so15835062obe.1 for ; Wed, 03 Jun 2015 12:08:18 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=WppOcdz3VCwVce1zqOAJ4pyVp+DT35hZakw8491hUXc=; b=Y0Ba4/gcfPRNNeKmyQG439VbF7Sc6yPwB3AavUDxEPN2q1+UHTat/ingLLiDwhci1S grdCkmmkKx7oyVUVmxbAxO7j171YvvoFYF7kUE8K3OYfN4x/wC2anEKAqB9sPcHa1A5E K6HuPZp9MSVnSQNdeaMxXnEaJ4Dz/iCGb6ovoDVPtc84JUwRUPiVjUwURABoIxvWg7uz yJGOtxKTLmumLwVqRsjnz8KfOc2kol0y2g3ezdgut6q19wg4dplIsd+qtqRwSGMwPYZn SuIg0Td1Or4iW1bhIeAPkDvI7jDoGs320nq5DSyWwyXvl/U6ANCSgXK0nh+R7PG0ytc+ 9c2w== X-Gm-Message-State: ALoCoQmME5DWlcCV+CIqLpvGuF1OGXpThEnqWjveYhZPXsB/fOga+cH31teeOnQ7pGtTCpo30T9j X-Received: by 10.202.102.227 with SMTP id m96mr825640oik.98.1433358498257; Wed, 03 Jun 2015 12:08:18 -0700 (PDT) Received: from localhost.localdomain (rrcs-97-77-120-78.sw.biz.rr.com. [97.77.120.78]) by mx.google.com with ESMTPSA id yo9sm11959271obc.3.2015.06.03.12.08.16 (version=TLSv1 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 03 Jun 2015 12:08:16 -0700 (PDT) From: Jay Rolette To: dev@dpdk.org Date: Wed, 3 Jun 2015 14:07:56 -0500 Message-Id: <1433358478-12668-1-git-send-email-rolette@infiniteio.com> X-Mailer: git-send-email 2.3.2 (Apple Git-55) Subject: [dpdk-dev] [PATCH 1/3] kni: minor opto 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, 03 Jun 2015 19:08:19 -0000 Don't need the 'safe' version of list_for_each_entry() if you aren't deleting from the list as you iterate over it Signed-off-by: Jay Rolette --- lib/librte_eal/linuxapp/kni/kni_misc.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/lib/librte_eal/linuxapp/kni/kni_misc.c b/lib/librte_eal/linuxapp/kni/kni_misc.c index 1935d32..312f196 100644 --- a/lib/librte_eal/linuxapp/kni/kni_misc.c +++ b/lib/librte_eal/linuxapp/kni/kni_misc.c @@ -213,13 +213,12 @@ static int kni_thread_single(void *unused) { int j; - struct kni_dev *dev, *n; + struct kni_dev *dev; while (!kthread_should_stop()) { down_read(&kni_list_lock); for (j = 0; j < KNI_RX_LOOP_NUM; j++) { - list_for_each_entry_safe(dev, n, - &kni_list_head, list) { + list_for_each_entry(dev, &kni_list_head, list) { #ifdef RTE_KNI_VHOST kni_chk_vhost_rx(dev); #else -- 2.3.2 (Apple Git-55)