fs: move kmem_cache_zalloc() into alloc_empty_file*() helpers
authorAmir Goldstein <amir73il@gmail.com>
Thu, 15 Jun 2023 11:22:27 +0000 (14:22 +0300)
committerChristian Brauner <brauner@kernel.org>
Mon, 19 Jun 2023 16:12:04 +0000 (18:12 +0200)
commit8a05a8c31d06c5d0d67b273a4a00f87269adde82
tree752752f524143b6cf74ac7f99acf95b3605ecab2
parentcbb0b9d4bbcfa96e7872808a63be03202536f1bc
fs: move kmem_cache_zalloc() into alloc_empty_file*() helpers

Use a common helper init_file() instead of __alloc_file() for
alloc_empty_file*() helpers and improrve the documentation.

This is needed for a follow up patch that allocates a backing_file
container.

Suggested-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Amir Goldstein <amir73il@gmail.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Message-Id: <20230615112229.2143178-4-amir73il@gmail.com>
Signed-off-by: Christian Brauner <brauner@kernel.org>
fs/file_table.c