[PATCH] Add retain_initrd boot option
[powerpc.git] / kernel / sysctl.c
index 600b333..41bbba1 100644 (file)
@@ -1961,7 +1961,7 @@ int proc_dointvec_bset(ctl_table *table, int write, struct file *filp,
 {
        int op;
 
-       if (!capable(CAP_SYS_MODULE)) {
+       if (write && !capable(CAP_SYS_MODULE)) {
                return -EPERM;
        }