On Mon, Apr 3, 2017 at 6:30 AM, Kyle Fortin <kyle.fortin@xxxxxxxxxx> wrote: > > for (i = 0; i < q->max; i++) > kfree(q->pool[i]); > - kfree(q->pool); > + if (q->is_pool_vmalloc) you could do something like: if (is_vmalloc_addr(q->pool)) vfree(...); else kfree(..); And then remove the bool. Chetan