There is a kernel patch (under review) that rejects 0-shifts from
control plane. Remove zero-shifts at eval stage: they are
a no-op in any case.
Signed-off-by: Florian Westphal <fw@strlen.de>
Reviewed-by: Fernando Fernandez Mancera <fmancera@suse.de>
"shifts exceeding %u bits are not supported", UINT_MAX);
shift = mpz_get_uint32(right->value);
+ if (shift == 0) {
+ *expr = expr_get(left);
+ expr_free(op);
+ return 0;
+ }
+
if (ctx->stmt_len > left->len)
max_shift_len = ctx->stmt_len;
else