From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f50.google.com (mail-wm0-f50.google.com [74.125.82.50]) by dpdk.org (Postfix) with ESMTP id 47E4A8E95 for ; Mon, 23 Nov 2015 15:45:17 +0100 (CET) Received: by wmuu63 with SMTP id u63so57111142wmu.0 for ; Mon, 23 Nov 2015 06:45:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:subject:date:message-id:in-reply-to:references; bh=3KY/WicD332OWoCgfOPS0mLnEdCSieP7RjTAySVsnh8=; b=T8S1NlTpKbjG/gUUBFdaktcfSX3O/TRwnpp86R8L6hw9rWveNVkL9bZTf9deyT8+6d kxjlrdGmy9RdH+JkHSW9vyGcUiCjB2TVJQQANzQrv1TW6xf7ASDGgiFiU5fk6poMETs/ 2KbG2+RzZ0b7AzTCpanMmxaGj3x4ttNRbkJJqUjpOCTOwWxmP23TxNJ6gJMuVQZLAwh3 NR9EKeBVIMaVSKEFCNeZZRlCUb2gW+zREk/8EMG/5A2tQ6bsdqSA7byKEBA4+llLv6Tj BnOC8eM9d7TbwsvrUYI5uqfInIQB2m87pH5o/chaCf4VT6/47F+I+ysqelS/miqJ8GdE PjyA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references; bh=3KY/WicD332OWoCgfOPS0mLnEdCSieP7RjTAySVsnh8=; b=cMC98c54YWwfuPWsXaUL0cRjE/stwQgxUrP87UeIstcNX2IjftpMNpqF/vxk2kqK+9 cZkOd5s7SWntEuDJgCRTT39CNwx1SotywQCKpf/lufY+/7Q1I8OsRLaj5UmMlpNAY/gT ZBHWuXgj/06iTLYZeKD5R5GBuexF4l5Q3JoRwnk1t4C348gUcugla+VY2fzLXD3oV1aJ CoktragmvfRy+fbVgZfiUryeEkXj0s6e8uN5UhDihcE7bwAP/AtVKWMLw+vllJ1PJPTY S2ad5EsPZEZoj06DSjZzPpXWSWqjgrN+E8XWfu1z4vuS385bCmq3cd6LY83mUGQE/Ckm Olig== X-Gm-Message-State: ALoCoQl46ujbJt2/mdg1Gq6r0jkNGPDtotbvbREEetEM9zPoteoADGEo7YGPUZ5kixupKEk3wcG2 X-Received: by 10.28.21.196 with SMTP id 187mr17454831wmv.82.1448289917153; Mon, 23 Nov 2015 06:45:17 -0800 (PST) Received: from 6wind.com (guy78-3-82-239-227-177.fbx.proxad.net. [82.239.227.177]) by smtp.gmail.com with ESMTPSA id t5sm13466884wmt.1.2015.11.23.06.45.15 for (version=TLSv1/SSLv3 cipher=OTHER); Mon, 23 Nov 2015 06:45:16 -0800 (PST) From: Adrien Mazarguil To: dev@dpdk.org Date: Mon, 23 Nov 2015 15:44:36 +0100 Message-Id: <1448289889-9590-2-git-send-email-adrien.mazarguil@6wind.com> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1448289889-9590-1-git-send-email-adrien.mazarguil@6wind.com> References: <1448289889-9590-1-git-send-email-adrien.mazarguil@6wind.com> Subject: [dpdk-dev] [PATCH 01/14] mlx4: fix possible crash when clearing device statistics 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: Mon, 23 Nov 2015 14:45:17 -0000 A typo causes TX stats indices to be retrieved from RX queues. Fixes: 7fae69eeff13 ("mlx4: new poll mode driver") Reported-by: Nicolas Harnois Signed-off-by: Adrien Mazarguil --- drivers/net/mlx4/mlx4.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/net/mlx4/mlx4.c b/drivers/net/mlx4/mlx4.c index 4198c04..d961a8a 100644 --- a/drivers/net/mlx4/mlx4.c +++ b/drivers/net/mlx4/mlx4.c @@ -3958,7 +3958,7 @@ mlx4_stats_reset(struct rte_eth_dev *dev) for (i = 0; (i != priv->txqs_n); ++i) { if ((*priv->txqs)[i] == NULL) continue; - idx = (*priv->rxqs)[i]->stats.idx; + idx = (*priv->txqs)[i]->stats.idx; (*priv->txqs)[i]->stats = (struct mlx4_txq_stats){ .idx = idx }; } -- 2.1.0