lkml.org 
[lkml]   [2014]   [Sep]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: [HPDD-discuss] [PATCH] staging: lustre: llite: Use kzalloc and rewrite null tests
Date

On Sep 18, 2014, at 10:57 PM, Drokin, Oleg wrote:

> would not be easy to do. Perhaps registered callbacks for pools that could be called on alloc and on free - though such pools would also need to allow to allocate different sized chunks too).

Come think of it - we don't even need callbacks here. If a pool would allow to allocate different sized chunks of memory. Then on module unmount there's already a warning for freeing
not yet empty pool, and we can even see all the leaked bits if we really want to (in like a crash dump).
So a module would just need to register such a general pool and use it for all allocations.

Bye,
Oleg

\
 
 \ /
  Last update: 2014-09-19 05:21    [W:0.082 / U:0.100 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site