pidfs: move O_RDWR into pidfs_alloc_file()
authorChristian Brauner <brauner@kernel.org>
Mon, 14 Apr 2025 13:55:05 +0000 (15:55 +0200)
committerChristian Brauner <brauner@kernel.org>
Fri, 2 May 2025 12:28:45 +0000 (14:28 +0200)
commitc57f07b235871c9e5bffaccd458dca2d9a62b164
treecad23436a546b8fd565b6ca260769dce18813bfe
parente1b477c21300a928a7765a03cb96ca36c4dcf5ed
pidfs: move O_RDWR into pidfs_alloc_file()

Since all pidfds must be O_RDWR currently enfore that directly in the
file allocation function itself instead of letting callers specify it.

Link: https://lore.kernel.org/20250414-work-coredump-v2-1-685bf231f828@kernel.org
Tested-by: Luca Boccassi <luca.boccassi@gmail.com>
Reviewed-by: Oleg Nesterov <oleg@redhat.com>
Signed-off-by: Christian Brauner <brauner@kernel.org>
fs/pidfs.c