]> git.proxmox.com Git - mirror_ubuntu-eoan-kernel.git/blobdiff - net/sched/act_bpf.c
sched: align nlattr properly when needed
[mirror_ubuntu-eoan-kernel.git] / net / sched / act_bpf.c
index 8c9f1f0459ab773139112c453fd1540af3a1b94f..4fd703362563e99eba8a6a60aceb0c9bcccb5a74 100644 (file)
@@ -156,7 +156,8 @@ static int tcf_bpf_dump(struct sk_buff *skb, struct tc_action *act,
        tm.lastuse = jiffies_to_clock_t(jiffies - prog->tcf_tm.lastuse);
        tm.expires = jiffies_to_clock_t(prog->tcf_tm.expires);
 
-       if (nla_put(skb, TCA_ACT_BPF_TM, sizeof(tm), &tm))
+       if (nla_put_64bit(skb, TCA_ACT_BPF_TM, sizeof(tm), &tm,
+                         TCA_ACT_BPF_PAD))
                goto nla_put_failure;
 
        return skb->len;