Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 08d405c8 authored by Davidlohr Bueso's avatar Davidlohr Bueso Committed by Linus Torvalds
Browse files

fs/: remove caller signal_pending branch predictions

This is already done for us internally by the signal machinery.

[akpm@linux-foundation.org: fix fs/buffer.c]
Link: http://lkml.kernel.org/r/20181116002713.8474-7-dave@stgolabs.net


Signed-off-by: default avatarDavidlohr Bueso <dave@stgolabs.net>
Reviewed-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent fa45f116
Loading
Loading
Loading
Loading
+1 −1
Original line number Original line Diff line number Diff line
@@ -247,7 +247,7 @@ int afs_wait_for_fs_probes(struct afs_server_list *slist, unsigned long untried)
			}
			}
		}
		}


		if (!still_probing || unlikely(signal_pending(current)))
		if (!still_probing || signal_pending(current))
			goto stop;
			goto stop;
		schedule();
		schedule();
	}
	}
+1 −1
Original line number Original line Diff line number Diff line
@@ -248,7 +248,7 @@ int afs_wait_for_vl_probes(struct afs_vlserver_list *vllist,
			}
			}
		}
		}


		if (!still_probing || unlikely(signal_pending(current)))
		if (!still_probing || signal_pending(current))
			goto stop;
			goto stop;
		schedule();
		schedule();
	}
	}
+1 −1
Original line number Original line Diff line number Diff line
@@ -2366,7 +2366,7 @@ static int cont_expand_zero(struct file *file, struct address_space *mapping,


		balance_dirty_pages_ratelimited(mapping);
		balance_dirty_pages_ratelimited(mapping);


		if (unlikely(fatal_signal_pending(current))) {
		if (fatal_signal_pending(current)) {
			err = -EINTR;
			err = -EINTR;
			goto out;
			goto out;
		}
		}
+2 −2
Original line number Original line Diff line number Diff line
@@ -1087,7 +1087,7 @@ static int de_thread(struct task_struct *tsk)
		__set_current_state(TASK_KILLABLE);
		__set_current_state(TASK_KILLABLE);
		spin_unlock_irq(lock);
		spin_unlock_irq(lock);
		schedule();
		schedule();
		if (unlikely(__fatal_signal_pending(tsk)))
		if (__fatal_signal_pending(tsk))
			goto killed;
			goto killed;
		spin_lock_irq(lock);
		spin_lock_irq(lock);
	}
	}
@@ -1115,7 +1115,7 @@ static int de_thread(struct task_struct *tsk)
			write_unlock_irq(&tasklist_lock);
			write_unlock_irq(&tasklist_lock);
			cgroup_threadgroup_change_end(tsk);
			cgroup_threadgroup_change_end(tsk);
			schedule();
			schedule();
			if (unlikely(__fatal_signal_pending(tsk)))
			if (__fatal_signal_pending(tsk))
				goto killed;
				goto killed;
		}
		}


+1 −1
Original line number Original line Diff line number Diff line
@@ -105,7 +105,7 @@ static int wait_for_free(struct slot_map *m)
			left = t;
			left = t;
		else
		else
			left = t + (left - n);
			left = t + (left - n);
		if (unlikely(signal_pending(current)))
		if (signal_pending(current))
			left = -EINTR;
			left = -EINTR;
	} while (left > 0);
	} while (left > 0);