From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-pf0-f193.google.com (mail-pf0-f193.google.com [209.85.192.193]) by dpdk.org (Postfix) with ESMTP id 3B7A92C8 for ; Tue, 20 Jun 2017 13:37:07 +0200 (CEST) Received: by mail-pf0-f193.google.com with SMTP id w12so22252849pfk.0 for ; Tue, 20 Jun 2017 04:37:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=fridaylinux-org.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=c+Ww3Oikedvla+HGWcjfNo6MMqN37nx6n6ryMrd19LA=; b=HnIBrA6mmn6NSlBF8DT/4zoMN+3jAZKkN5TTGCe66S3gop/Y3RY1PXkH2B2mqDw+cm X9E7syR8GrDuJifS+raxLS5tRPbGhGgMzMSGXiJwjYZkpRvSQqgRpjKCMlQ7t1lNXsrn Jocr3sdP4JNVOlnC9YidjAsvEzSBXA55Lq+uI5AQ+kkzdcPqQud2DHfVXvLl+odv2/Mu jS6oCx3QpPL5Ni6GPUGT6ilA0jz3k8+PIAzpAVftNnvO4BR6vJDxTeQACw4PhUaZIXri EXIPy4m+Hm+s6IvLT/0laDmLLaw5P/3FJ252HAZ8TVsQ8D0YT9iPpkegfLaVrzp4jsRc A1JQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=c+Ww3Oikedvla+HGWcjfNo6MMqN37nx6n6ryMrd19LA=; b=T1w5/7he0k3t57VszbxbYX4+M9nMKtWpVerk9gQyahojOGHS4uos9ERnIK1ReLMjHI kskEvMpgGsclQTXxfnng7sBwMzzI/fOHtUr0pKQVyeP541wo4qdVzo2XZGpCO1VTz6Nh 9nOQPAozsG6a9Nqr3RlIHb9IOQ7HDX4pdfX3/QhGs1kVkZnBkMJt16nWfaZUDcAvQhVC Zf5UlIkzKB2DOkMcTfLXl0kKH+t5xBPfCDhyBeAfml3vwRSOnUkebewVZL6YAa0qZMz+ 2Wk/6qr7GYV4q+hCFyCxsFaoytHQO9JIn/WKgizv6guD02q2sYc9QkTewh3UyUdLrQAU ykCA== X-Gm-Message-State: AKS2vOxATh7Y/1icvDuSZk/NVz7sY+EGqgMOggTnSWw3RSUnmRlB+dWS lwfJhLQaltEZQmo2 X-Received: by 10.99.104.199 with SMTP id d190mr31418946pgc.185.1497958626845; Tue, 20 Jun 2017 04:37:06 -0700 (PDT) Received: from yliu-home.localdomain ([45.63.61.64]) by smtp.gmail.com with ESMTPSA id 25sm6104783pfj.59.2017.06.20.04.37.03 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Tue, 20 Jun 2017 04:37:05 -0700 (PDT) From: Yuanhan Liu To: Markus Theil Cc: Wenzhuo Lu , dpdk stable Date: Tue, 20 Jun 2017 19:35:26 +0800 Message-Id: <1497958550-13600-14-git-send-email-yliu@fridaylinux.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1497958550-13600-1-git-send-email-yliu@fridaylinux.org> References: <1497958550-13600-1-git-send-email-yliu@fridaylinux.org> Subject: [dpdk-stable] patch 'net/igb: fix add/delete of flex filters' has been queued to stable release 17.05.1 X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for DPDK stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 Jun 2017 11:37:08 -0000 Hi, FYI, your patch has been queued to stable release 17.05.1 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 06/22/17. So please shout if anyone has objections. Thanks. --yliu --- >>From 4318c5f6057a9ba328d80e2662b94af3492f6391 Mon Sep 17 00:00:00 2001 From: Markus Theil Date: Mon, 22 May 2017 12:17:50 +0200 Subject: [PATCH] net/igb: fix add/delete of flex filters [ upstream commit 167e7b9ae531491f10f495587cb59ae271430abb ] Before this patch, flex_filter->index was always zero when it was read and used after rte_zmalloc. The corresponding code was therefore moved into the add and delete parts of the if/else statement. Fixes: 231d43909a31 ("igb: migrate flex filter to new API") Signed-off-by: Markus Theil Acked-by: Wenzhuo Lu --- drivers/net/e1000/igb_ethdev.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) diff --git a/drivers/net/e1000/igb_ethdev.c b/drivers/net/e1000/igb_ethdev.c index 5af3ac8..d18dd48 100644 --- a/drivers/net/e1000/igb_ethdev.c +++ b/drivers/net/e1000/igb_ethdev.c @@ -3912,10 +3912,6 @@ eth_igb_add_del_flex_filter(struct rte_eth_dev *dev, } wufc = E1000_READ_REG(hw, E1000_WUFC); - if (flex_filter->index < E1000_MAX_FHFT) - reg_off = E1000_FHFT(flex_filter->index); - else - reg_off = E1000_FHFT_EXT(flex_filter->index - E1000_MAX_FHFT); if (add) { if (eth_igb_flex_filter_lookup(&filter_info->flex_list, @@ -3945,6 +3941,11 @@ eth_igb_add_del_flex_filter(struct rte_eth_dev *dev, return -ENOSYS; } + if (flex_filter->index < E1000_MAX_FHFT) + reg_off = E1000_FHFT(flex_filter->index); + else + reg_off = E1000_FHFT_EXT(flex_filter->index - E1000_MAX_FHFT); + E1000_WRITE_REG(hw, E1000_WUFC, wufc | E1000_WUFC_FLEX_HQ | (E1000_WUFC_FLX0 << flex_filter->index)); queueing = filter->len | @@ -3973,6 +3974,11 @@ eth_igb_add_del_flex_filter(struct rte_eth_dev *dev, return -ENOENT; } + if (it->index < E1000_MAX_FHFT) + reg_off = E1000_FHFT(it->index); + else + reg_off = E1000_FHFT_EXT(it->index - E1000_MAX_FHFT); + for (i = 0; i < E1000_FHFT_SIZE_IN_DWD; i++) E1000_WRITE_REG(hw, reg_off + i * sizeof(uint32_t), 0); E1000_WRITE_REG(hw, E1000_WUFC, wufc & -- 2.7.4