]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
fs/: remove caller signal_pending branch predictions
authorDavidlohr Bueso <dave@stgolabs.net>
Thu, 3 Jan 2019 23:28:58 +0000 (15:28 -0800)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 4 Jan 2019 21:13:48 +0000 (13:13 -0800)
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: Davidlohr Bueso <dave@stgolabs.net>
Reviewed-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/afs/fs_probe.c
fs/afs/vl_probe.c
fs/buffer.c
fs/exec.c
fs/orangefs/orangefs-bufmap.c

index fde6b4d4121e38532ea9ade21feb40b0a2bd09c6..3a9eaec06756998875f94a474bd6a75cb1ef5cf3 100644 (file)
@@ -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;
                schedule();
        }
index f0b032976487cd5bde632b171ebaf858eb11a52c..f402ee8171a1d7cda8b8da05253408003c7f29f7 100644 (file)
@@ -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;
                schedule();
        }
index d60d61e8ed7de495bddd0bc799f16c2606a4c68b..52d024bfdbc12142a97ff8ec204ce4b658df6fe6 100644 (file)
@@ -2366,7 +2366,7 @@ static int cont_expand_zero(struct file *file, struct address_space *mapping,
 
                balance_dirty_pages_ratelimited(mapping);
 
-               if (unlikely(fatal_signal_pending(current))) {
+               if (fatal_signal_pending(current)) {
                        err = -EINTR;
                        goto out;
                }
index ea7d439cf79efe95b9132185ae417b1b9d08efe9..44320d893f1a38db0a37364a997c81b714cbebe6 100644 (file)
--- a/fs/exec.c
+++ b/fs/exec.c
@@ -1087,7 +1087,7 @@ static int de_thread(struct task_struct *tsk)
                __set_current_state(TASK_KILLABLE);
                spin_unlock_irq(lock);
                schedule();
-               if (unlikely(__fatal_signal_pending(tsk)))
+               if (__fatal_signal_pending(tsk))
                        goto killed;
                spin_lock_irq(lock);
        }
@@ -1115,7 +1115,7 @@ static int de_thread(struct task_struct *tsk)
                        write_unlock_irq(&tasklist_lock);
                        cgroup_threadgroup_change_end(tsk);
                        schedule();
-                       if (unlikely(__fatal_signal_pending(tsk)))
+                       if (__fatal_signal_pending(tsk))
                                goto killed;
                }
 
index c4e98c9c16217b85c6b97afc8e829130205cfede..443bcd8c3c1991d2d9160ef3a94622b283e8b349 100644 (file)
@@ -105,7 +105,7 @@ static int wait_for_free(struct slot_map *m)
                        left = t;
                else
                        left = t + (left - n);
-               if (unlikely(signal_pending(current)))
+               if (signal_pending(current))
                        left = -EINTR;
        } while (left > 0);