[PATCH] selftests/memfd: move common code into common.c