Messages in this thread | | | Subject | Re: [PATCH -mm] kmemleak: Fix section mismatch in kmemleak.c | From | Catalin Marinas <> | Date | Wed, 18 Feb 2009 10:06:03 +0000 |
| |
On Sat, 2009-02-14 at 09:42 +0600, Rakib Mullick wrote: > Impact: Section mismatch > > The function kmemleak_alloc() is called from kernel allocators. > kmemleak_alloc() calls log_early() but being log_early() marked as > __init it causes following section mismatches. Being called from > kernel allocators, kmemleak_allock() will be called after freeing up > the init memory and log_early() will also called. So, unmarking __init > from log_early() fixes the warning. If anything else please notice.
Thanks for the patch. There's nothing dangerous as kmemleak takes care of not using the __init functions after it was initialised but I couldn't find a way to free these functions/data and also avoid the warning.
Anyway, that's fine as an interim patch but I think I'll just allocate some pages dynamically for the early logging buffer so that we can free them once initialised. I'll update the kmemleak branch sometime this week.
Thanks.
-- Catalin
| |