mirror of
https://github.com/Fishwaldo/Star64_linux.git
synced 2025-04-01 12:04:08 +00:00
[PATCH] close_files(): add scheduling point
close_files() can sometimes take long enough to trigger the soft lockup detector. Cc: Eric Dumazet <dada1@cosmosbay.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
92ba0ee277
commit
944be0b224
1 changed files with 3 additions and 1 deletions
|
@ -430,8 +430,10 @@ static void close_files(struct files_struct * files)
|
||||||
while (set) {
|
while (set) {
|
||||||
if (set & 1) {
|
if (set & 1) {
|
||||||
struct file * file = xchg(&fdt->fd[i], NULL);
|
struct file * file = xchg(&fdt->fd[i], NULL);
|
||||||
if (file)
|
if (file) {
|
||||||
filp_close(file, files);
|
filp_close(file, files);
|
||||||
|
cond_resched();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
i++;
|
i++;
|
||||||
set >>= 1;
|
set >>= 1;
|
||||||
|
|
Loading…
Add table
Reference in a new issue