sched/core: Fix a race between try_to_wake_up() and a woken up task
[GitHub/mt8127/android_kernel_alcatel_ttab.git] / kernel / ksysfs.c
index c01eac66c0cca6317689ba2a1f6095e2cacfb21e..6ada93c23a9ac55e0c5aaebe9fcd98c05f2c84dd 100644 (file)
@@ -140,6 +140,23 @@ static ssize_t fscaps_show(struct kobject *kobj,
 }
 KERNEL_ATTR_RO(fscaps);
 
+int rcu_expedited;
+static ssize_t rcu_expedited_show(struct kobject *kobj,
+                                 struct kobj_attribute *attr, char *buf)
+{
+       return sprintf(buf, "%d\n", rcu_expedited);
+}
+static ssize_t rcu_expedited_store(struct kobject *kobj,
+                                  struct kobj_attribute *attr,
+                                  const char *buf, size_t count)
+{
+       if (kstrtoint(buf, 0, &rcu_expedited))
+               return -EINVAL;
+
+       return count;
+}
+KERNEL_ATTR_RW(rcu_expedited);
+
 /*
  * Make /sys/kernel/notes give the raw contents of our kernel .notes section.
  */
@@ -179,6 +196,7 @@ static struct attribute * kernel_attrs[] = {
        &kexec_crash_size_attr.attr,
        &vmcoreinfo_attr.attr,
 #endif
+       &rcu_expedited_attr.attr,
        NULL
 };