diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-03-23 08:02:55 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2020-03-23 08:02:55 +0100 |
commit | cbf580ff093861f021b31b2f8d0f03173fb58520 (patch) | |
tree | 948a7b6424e580979763c8576fee0bb7c326b0db /fs/file.c | |
parent | db1032f7e485ea95b83ad66bb3d1675ad66de77f (diff) | |
parent | 16fbf79b0f83bc752cee8589279f1ebfe57b3b6e (diff) | |
download | linux-cbf580ff093861f021b31b2f8d0f03173fb58520.tar.bz2 |
Merge 5.6-rc7 into tty-next
We need the tty fixes in here as well.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'fs/file.c')
-rw-r--r-- | fs/file.c | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/fs/file.c b/fs/file.c index a364e1a9b7e8..c8a4e4c86e55 100644 --- a/fs/file.c +++ b/fs/file.c @@ -540,9 +540,14 @@ static int alloc_fd(unsigned start, unsigned flags) return __alloc_fd(current->files, start, rlimit(RLIMIT_NOFILE), flags); } +int __get_unused_fd_flags(unsigned flags, unsigned long nofile) +{ + return __alloc_fd(current->files, 0, nofile, flags); +} + int get_unused_fd_flags(unsigned flags) { - return __alloc_fd(current->files, 0, rlimit(RLIMIT_NOFILE), flags); + return __get_unused_fd_flags(flags, rlimit(RLIMIT_NOFILE)); } EXPORT_SYMBOL(get_unused_fd_flags); |