From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-wm0-f53.google.com (mail-wm0-f53.google.com [74.125.82.53]) by dpdk.org (Postfix) with ESMTP id DADFA6CC8 for ; Fri, 16 Sep 2016 16:19:40 +0200 (CEST) Received: by mail-wm0-f53.google.com with SMTP id k186so44407722wmd.0 for ; Fri, 16 Sep 2016 07:19:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:user-agent:in-reply-to :references:mime-version:content-transfer-encoding; bh=QfSURUROR9WOjKpWAoKTF+rVadx7SNJq9n3RuJTd/so=; b=FAre2ySq/BdrtmmByscCyoeE9sap1cC4DE+ObRD9RUkV2kJAWM5S33R1bTuJdGMG/T VQG3D7Q1zYMFDHxVt8Ss4SGUlikV9XGuqeIqe7JZvYhhjWVICd3DkNY1Bb46SqE0LWya 9dVisMr1NYFDMdqUWuZf6Uh7V10cHsMqSSUI8/CgElB0fWj49VGD4bzOkwk5EhYUS2or jgahUQhf8QQxqFUWQUxpHI+oDxE2nUmjZQpouU8UaCDzke30zgzWZTwaWW6QmHA81u9Q +RVSQxChr3u+uWa23L5szv4y4fKPXNmmv4lPL5zs067dAWedoJ/Hs0wzUInHCgTqzChZ uo9w== 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:user-agent :in-reply-to:references:mime-version:content-transfer-encoding; bh=QfSURUROR9WOjKpWAoKTF+rVadx7SNJq9n3RuJTd/so=; b=IRJ8TDaxOOdsAAm55FaXhKZzrN7oDPjbJi5r9a1xtuwBGNHPiArzjZllEkKwcc0xz9 35eqKjgzP9EOzoDP+3HitocsxEwa/gI83jwfTKJhKsvUHUrY8ANVvOD9cCIwHBY41+fq 06iTxTQ5mo1Pib5zP3O2dWuLRLgGqxRKan+ou7k8VMTQyNd0XoebLnIPyGtDMy9tHDXm S2s4xmOJEvaPW4WXghs8Hc3QGnY6Uwi5bt1BB2fhTv2xat+OvY4UPLhHa2dSo/w8x6IF REUQ+aSlsOqQRrN4a8PR5FXGeUz5niI2oWz7YI6DiiEVTK76ipnUmnV9cgxkPlzBYc39 A0mg== X-Gm-Message-State: AE9vXwOolqv8GGAZwDDps8S4Ipy3J6VqyTAVJ/KBhh/OigmnUTYToYCKgkj8Y//jkgmx54mf X-Received: by 10.194.96.136 with SMTP id ds8mr12896881wjb.3.1474035580412; Fri, 16 Sep 2016 07:19:40 -0700 (PDT) Received: from xps13.localnet (184.203.134.77.rev.sfr.net. [77.134.203.184]) by smtp.gmail.com with ESMTPSA id 123sm7626293wmj.5.2016.09.16.07.19.39 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Sep 2016 07:19:39 -0700 (PDT) From: Thomas Monjalon To: Weiliang Luo Cc: dev@dpdk.org, stable@dpdk.org, olivier.matz@6wind.com Date: Fri, 16 Sep 2016 16:19:38 +0200 Message-ID: <43354735.jbAHAiVkRh@xps13> User-Agent: KMail/4.14.10 (Linux/4.5.4-1-ARCH; KDE/4.14.11; x86_64; ; ) In-Reply-To: <1473348597-11904-1-git-send-email-droidluo@gmail.com> References: <1473348597-11904-1-git-send-email-droidluo@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Subject: Re: [dpdk-stable] [dpdk-dev] [PATCH] mempool: fix corruption due to invalid handler X-BeenThere: stable@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches for stable branches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 16 Sep 2016 14:19:41 -0000 CC stable@dpdk.org 2016-09-08 10:29, Weiliang Luo: > When using rte_mempool_create(), the mempool handler is selected > depending on the flags given by the user: > - multi-consumer / multi-producer > - multi-consumer / single-producer > - single-consumer / multi-producer > - single-consumer / single-producer > > The flags were not properly tested, resulting in the selection of sc/sp > handler if sc/mp or mc/sp was asked. This can lead to corruption or > crashes because the get/put operations are not atomic. > > Fixes: 449c49b93a6b ("mempool: support handler operations") > > Signed-off-by: Weiliang Luo > Acked-by: Olivier Matz Applied, thanks