May the worker function free its struct_work (plus container)?

From: Leon Woestenberg
Date: Sun May 09 2010 - 18:47:36 EST


Hello,

may the worker function kfree() it's own work data structure?

/* worker function */
static void engine_service_work(struct work_struct *work)
{
struct foobar_container_struct *foobar;
foobar = container_of(work, struct foobar, work);
/* ...perform some work... */
kfree(foobar);
}

Thanks,
--
Leon
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/