From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wr0-f195.google.com (mail-wr0-f195.google.com [209.85.128.195]) by dpdk.org (Postfix) with ESMTP id 756D51B7A9 for ; Tue, 15 May 2018 15:47:41 +0200 (CEST) Received: by mail-wr0-f195.google.com with SMTP id v15-v6so199693wrm.10 for ; Tue, 15 May 2018 06:47:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=l/4eAWrRdR2cvNFmOBmgK+5VaXF7wWgYUUst86eIzAg=; b=uXoVErhM13fzWirbcIUv+1IB5Wr/+ZN88MSDZQNLhy++gH9QUzr2miCPSigPSvBRlJ f4dgs1qbr1Ye5NTbyuu+s6KFVDRUHHEwzWpfLiY8xkj4GzoB+1/pGjU7U6R1jGAaESG6 tM8idIV6JvBJhVpzswtdeJFMLEPoX7QSPgczDsh4FAttdRb36QDT1mnkAWqIO52lQidy jn+Hwe8PiFIQaQpJ3mgbHiZ1jx5PwNO3y+43VvsAl+w/u+oHr+aXJTlacuFWoLhfkFMe A9l3YLKlKy5pGU6KT2VNEIniJnOC7YK89OAOcDfvReHXsEq+pUSCXqIZaWbCKBU2Elv4 GnKA== 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=l/4eAWrRdR2cvNFmOBmgK+5VaXF7wWgYUUst86eIzAg=; b=SAJqgS3twF/lfLhPXv5rCLu8k4mxurzz+r7F/lCceJHi3G3jnKHn1Bzc6QLXYXldBv LXwjd8W+i4SlxQDL5+Oo6oiiVsjdfo5Fwjs6r24olpRwh46wS87AHakvbXKoQYFygVNX jCUZW/efMyM4+YDXx/C1yM0/f0j32okv7DPnyzzMYQ9PVX8mv2G3Rj6ruiDhx0HQ2VAZ D0IqgAPMRMEZONnOcucZVkCgmwbFVPO01KadVDYG4tiJhd3xNBW2QeKYwlaQvVFvfAop 3DtWxaIHKlkSgByRbNtSsTf9GZQRjG8W1TKW2cJKJzzd4wtxjqcYHSpp92edbpoOEX1p fGpg== X-Gm-Message-State: ALKqPwfxorF0A+ATguHOB0joqUxN/a31hpdZjylWrKbqwa+Fc9Q1kDrw jSfjWnuqKQsOFYZ3VD7WVz3P1tFr X-Google-Smtp-Source: AB8JxZoDRy+NVzC3a1ihNQbw9s6qPHfxqjOZZZ8FCzTVusMbfhd1nw34VHSO/A7UbX9gjsOzJL6vDA== X-Received: by 2002:adf:a925:: with SMTP id u34-v6mr11700995wrc.248.1526392061141; Tue, 15 May 2018 06:47:41 -0700 (PDT) Received: from localhost (slip139-92-244-193.lon.uk.prserv.net. [139.92.244.193]) by smtp.gmail.com with ESMTPSA id j18-v6sm76290wrd.92.2018.05.15.06.47.39 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Tue, 15 May 2018 06:47:39 -0700 (PDT) From: luca.boccassi@gmail.com To: Qi Zhang Cc: dpdk stable Date: Tue, 15 May 2018 14:46:12 +0100 Message-Id: <20180515134731.9337-1-luca.boccassi@gmail.com> X-Mailer: git-send-email 2.14.2 In-Reply-To: <20180503110612.12146-2-luca.boccassi@gmail.com> References: <20180503110612.12146-2-luca.boccassi@gmail.com> Subject: [dpdk-stable] patch 'app/testpmd: fix copy of raw flow item' has been queued to stable release 18.02.2 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, 15 May 2018 13:47:41 -0000 Hi, FYI, your patch has been queued to stable release 18.02.2 Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet. It will be pushed if I get no objections before 05/16/18. So please shout if anyone has objections. Thanks. Luca Boccassi --- >>From 2671260c07e98cb089ec4aef4de90029cabfd1a1 Mon Sep 17 00:00:00 2001 From: Qi Zhang Date: Mon, 7 May 2018 17:50:44 +0800 Subject: [PATCH] app/testpmd: fix copy of raw flow item [ upstream commit 67af7ecc52ec0abdec3e9d5b35dcd4dc78b595ce ] When calculate memory size of an RTE_FLOW_ITEM_TYPE_RAW 's mask mask->length is not the real size of binary pattern, it should take spec->length, or memory size will be over counted (0xffff) and invalid memory be access during following memcpy. Fixes: d0ad8648b1c5 ("app/testpmd: fix RSS flow action configuration") Signed-off-by: Qi Zhang --- app/test-pmd/config.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/test-pmd/config.c b/app/test-pmd/config.c index 2058e6ec8..a8e511f5f 100644 --- a/app/test-pmd/config.c +++ b/app/test-pmd/config.c @@ -1015,7 +1015,8 @@ flow_item_spec_copy(void *buf, const struct rte_flow_item *item, src.raw = item_spec; dst.raw = buf; size = offsetof(struct rte_flow_item_raw, pattern) + - src.raw->length * sizeof(*src.raw->pattern); + ((const struct rte_flow_item_raw *)item->spec)-> + length * sizeof(*src.raw->pattern); if (dst.raw) memcpy(dst.raw, src.raw, size); break; -- 2.14.2