Linux cryptographic layer development
 help / color / mirror / Atom feed
* [PATCH] padata: free correct variable
@ 2017-04-07  0:33 Jason A. Donenfeld
  2017-04-10 11:25 ` Herbert Xu
  0 siblings, 1 reply; 2+ messages in thread
From: Jason A. Donenfeld @ 2017-04-07  0:33 UTC (permalink / raw)
  To: linux-crypto, steffen.klassert, linux-kernel; +Cc: Jason A. Donenfeld, stable

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 <Jason@zx2c4.com>
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;
 	}
 
-- 
2.12.2

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-04-10 11:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-04-07  0:33 [PATCH] padata: free correct variable Jason A. Donenfeld
2017-04-10 11:25 ` Herbert Xu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox