mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-29 19:21:31 -04:00
kmemleak: Fix the kmemleak tracking of the percpu areas with !SMP
Kmemleak tracks the percpu allocations via a specific API and the originally allocated areas must be removed from kmemleak (via kmemleak_free). The code was already doing this for SMP systems. Reported-by: Sami Liedes <[email protected]> Cc: Tejun Heo <[email protected]> Cc: Christoph Lameter <[email protected]> Signed-off-by: Catalin Marinas <[email protected]> Signed-off-by: Tejun Heo <[email protected]>
This commit is contained in:
parent
42b6428145
commit
100d13c3b5
1 changed files with 2 additions and 0 deletions
|
|
@ -1895,6 +1895,8 @@ void __init setup_per_cpu_areas(void)
|
|||
fc = __alloc_bootmem(unit_size, PAGE_SIZE, __pa(MAX_DMA_ADDRESS));
|
||||
if (!ai || !fc)
|
||||
panic("Failed to allocate memory for percpu areas.");
|
||||
/* kmemleak tracks the percpu allocations separately */
|
||||
kmemleak_free(fc);
|
||||
|
||||
ai->dyn_size = unit_size;
|
||||
ai->unit_size = unit_size;
|
||||
|
|
|
|||
Loading…
Reference in a new issue