From patchwork Fri Apr 7 00:33:30 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Jason A. Donenfeld" X-Patchwork-Id: 9668663 X-Patchwork-Delegate: herbert@gondor.apana.org.au Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 8DC3760146 for ; Fri, 7 Apr 2017 00:33:50 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A3FE3285E9 for ; Fri, 7 Apr 2017 00:33:50 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 87032285EB; Fri, 7 Apr 2017 00:33:50 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-7.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID, DKIM_VALID_AU, RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 0D7C1285E9 for ; Fri, 7 Apr 2017 00:33:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754743AbdDGAdq (ORCPT ); Thu, 6 Apr 2017 20:33:46 -0400 Received: from frisell.zx2c4.com ([192.95.5.64]:32921 "EHLO frisell.zx2c4.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752124AbdDGAdq (ORCPT ); Thu, 6 Apr 2017 20:33:46 -0400 Received: by frisell.zx2c4.com (ZX2C4 Mail Server) with ESMTP id de95ee1d; Fri, 7 Apr 2017 00:27:20 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=zx2c4.com; h=from:to:cc :subject:date:message-id; s=mail; bh=mRwv9Y10BLZ2uYabAJnlrhEsJJ0 =; b=usCkDMpKjrByuuhvhlPsPIudss+zYmAgnpGUuhhBL2bAfOj6XDFbZAs5m3e CkcV3/CERtaGzARy2wKk/6pxQhRW00nbcoxJ9yZ8wq1LbRx8JS5rdkASbg+3PdI6 x0Ko0gis2Ya73vl4aWQZQtT+hqm1svfgMX2+v/o1zosyNjyWErfj16ZFvm1lQypT 3bpIsjfNiSvv0ft17XaiYVzlcWewYwAsPtm/YiNVudluwcdx3SMUZRAFW1VM44Ry VvsMN+y1qDDIxvzr4X8TwwxdHpz4MaoTTrVRyCO2M5lxVdmE9K8wY1iDYaih+M4c yXpRHo1+VlQZLo0Rz04GhuaA/Ww== Received: by frisell.zx2c4.com (ZX2C4 Mail Server) with ESMTPSA id fbe8e1e1 (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO); Fri, 7 Apr 2017 00:27:20 +0000 (UTC) From: "Jason A. Donenfeld" To: linux-crypto@vger.kernel.org, steffen.klassert@secunet.com, linux-kernel@vger.kernel.org Cc: "Jason A. Donenfeld" , stable@vger.kernel.org Subject: [PATCH] padata: free correct variable Date: Fri, 7 Apr 2017 02:33:30 +0200 Message-Id: <20170407003330.6552-1-Jason@zx2c4.com> X-Mailer: git-send-email 2.12.2 Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The author meant to free the variable that was just allocated, instead of the one that failed to be allocated, but made a simple typo. This patch rectifies that. Signed-off-by: Jason A. Donenfeld Cc: stable@vger.kernel.org --- kernel/padata.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/padata.c b/kernel/padata.c index 05316c9f32da..1faa7d62d87d 100644 --- a/kernel/padata.c +++ b/kernel/padata.c @@ -353,7 +353,7 @@ static int padata_setup_cpumasks(struct parallel_data *pd, cpumask_and(pd->cpumask.pcpu, pcpumask, cpu_online_mask); if (!alloc_cpumask_var(&pd->cpumask.cbcpu, GFP_KERNEL)) { - free_cpumask_var(pd->cpumask.cbcpu); + free_cpumask_var(pd->cpumask.pcpu); return -ENOMEM; }