Hello Paul E. McKenney,

Commit 1e07186d7377 ("refscale: Add srcu_read_lock_lite() support
using "srcu-lite"") from Oct 15, 2024 (linux-next), leads to the
following Smatch static checker warning:

        kernel/rcu/refscale.c:1151 ref_scale_init()
        warn: inconsistent indenting

kernel/rcu/refscale.c
    1141         for (i = 0; i < ARRAY_SIZE(scale_ops); i++) {
    1142                 cur_ops = scale_ops[i]; if (strcmp(scale_type,
    1143                 cur_ops->name) == 0)
    1144                         break;
    1145         }
    1146         if (i == ARRAY_SIZE(scale_ops)) {
    1147                 pr_alert("rcu-scale: invalid scale type: \"%s\"\n",
    1148                 scale_type); pr_alert("rcu-scale types:"); for (i = 0;
    1149                 i < ARRAY_SIZE(scale_ops); i++)
    1150                         pr_cont(" %s", scale_ops[i]->name);
--> 1151                 pr_cont("\n"); firsterr = -EINVAL; cur_ops = NULL;
    1152                 goto unwind;

This looks like you pressed the wrong button in vim and it accidentally jumbled
the code?

    1153         }
    1154         if (cur_ops->init)
    1155                 if (!cur_ops->init()) {
    1156                         firsterr = -EUCLEAN;
    1157                         goto unwind;
    1158                 }

regards,
dan carpenter

Reply via email to