Merge tag 'sched-urgent-2021-07-11' of git://git.kernel.org/pub/scm/linux/kernel...
[linux-2.6-microblaze.git] / kernel / sysctl.c
index e1aa24e..272f4a2 100644 (file)
@@ -27,6 +27,7 @@
 #include <linux/sysctl.h>
 #include <linux/bitmap.h>
 #include <linux/signal.h>
+#include <linux/panic.h>
 #include <linux/printk.h>
 #include <linux/proc_fs.h>
 #include <linux/security.h>
@@ -1495,7 +1496,6 @@ int proc_do_large_bitmap(struct ctl_table *table, int write,
                         void *buffer, size_t *lenp, loff_t *ppos)
 {
        int err = 0;
-       bool first = 1;
        size_t left = *lenp;
        unsigned long bitmap_len = table->maxlen;
        unsigned long *bitmap = *(unsigned long **) table->data;
@@ -1580,12 +1580,12 @@ int proc_do_large_bitmap(struct ctl_table *table, int write,
                        }
 
                        bitmap_set(tmp_bitmap, val_a, val_b - val_a + 1);
-                       first = 0;
                        proc_skip_char(&p, &left, '\n');
                }
                left += skipped;
        } else {
                unsigned long bit_a, bit_b = 0;
+               bool first = 1;
 
                while (left) {
                        bit_a = find_next_bit(bitmap, bitmap_len, bit_b);