The existing code in init_tmpfs() in mm/tiny-shmem.c does not handle the cases when the calls to register_filesystem() and kern_mount() fail. This patch adds those checks. Signed-off-by: Hareesh Nagarajan