[MERGE] kernel snapshot fixes

Signed-off-by: David Goulet <dgoulet@efficios.com>
cleanup and tests

Signed-off-by: Julien Desfossez <jdesfossez@efficios.com>