lkml.org 
[lkml]   [2017]   [Jan]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 1/2] sched/core: Fix &rd->rto_mask memory leak
Date
If function cpudl_init() fails the memory allocated for &rd->rto_mask
needs to be freed, something this patch is addressing.

Signed-off-by: Mathieu Poirier <mathieu.poirier@linaro.org>
---
kernel/sched/core.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index c56fb57f2991..5c01ac0f915a 100644
--- a/kernel/sched/core.c
+++ b/kernel/sched/core.c
@@ -5881,7 +5881,7 @@ static int init_rootdomain(struct root_domain *rd)

init_dl_bw(&rd->dl_bw);
if (cpudl_init(&rd->cpudl) != 0)
- goto free_dlo_mask;
+ goto free_rto_mask;

if (cpupri_init(&rd->cpupri) != 0)
goto free_rto_mask;
--
2.7.4
\
 
 \ /
  Last update: 2017-01-24 22:12    [W:0.054 / U:1.968 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site