]> git.ipfire.org Git - thirdparty/kernel/stable.git/blobdiff - fs/select.c
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-next
[thirdparty/kernel/stable.git] / fs / select.c
index dd70937ddb60a6ece08de1b761b23908335c4578..bd4b2ccfd34680b1648570e7b20db235cb31a89c 100644 (file)
@@ -456,7 +456,7 @@ static int do_select(int n, fd_set_bits *fds, struct timespec64 *end_time)
        int retval, i, timed_out = 0;
        u64 slack = 0;
        unsigned int busy_flag = net_busy_loop_on() ? POLL_BUSY_LOOP : 0;
-       unsigned long busy_end = 0;
+       unsigned long busy_start = 0;
 
        rcu_read_lock();
        retval = max_select_fd(n, fds);
@@ -559,11 +559,11 @@ static int do_select(int n, fd_set_bits *fds, struct timespec64 *end_time)
 
                /* only if found POLL_BUSY_LOOP sockets && not out of time */
                if (can_busy_loop && !need_resched()) {
-                       if (!busy_end) {
-                               busy_end = busy_loop_end_time();
+                       if (!busy_start) {
+                               busy_start = busy_loop_current_time();
                                continue;
                        }
-                       if (!busy_loop_timeout(busy_end))
+                       if (!busy_loop_timeout(busy_start))
                                continue;
                }
                busy_flag = 0;
@@ -847,7 +847,7 @@ static int do_poll(struct poll_list *list, struct poll_wqueues *wait,
        int timed_out = 0, count = 0;
        u64 slack = 0;
        unsigned int busy_flag = net_busy_loop_on() ? POLL_BUSY_LOOP : 0;
-       unsigned long busy_end = 0;
+       unsigned long busy_start = 0;
 
        /* Optimise the no-wait case */
        if (end_time && !end_time->tv_sec && !end_time->tv_nsec) {
@@ -900,11 +900,11 @@ static int do_poll(struct poll_list *list, struct poll_wqueues *wait,
 
                /* only if found POLL_BUSY_LOOP sockets && not out of time */
                if (can_busy_loop && !need_resched()) {
-                       if (!busy_end) {
-                               busy_end = busy_loop_end_time();
+                       if (!busy_start) {
+                               busy_start = busy_loop_current_time();
                                continue;
                        }
-                       if (!busy_loop_timeout(busy_end))
+                       if (!busy_loop_timeout(busy_start))
                                continue;
                }
                busy_flag = 0;