Skip to content

Commit 18129a2

Browse files
Jeff Barnhilldavem330
authored andcommitted
net: vrf: correct FRA_L3MDEV encode type
FRA_L3MDEV is defined as U8, but is being added as a U32 attribute. On big endian architecture, this results in the l3mdev entry not being added to the FIB rules. Fixes: 1aa6c4f ("net: vrf: Add l3mdev rules on first device create") Signed-off-by: Jeff Barnhill <0xeffeff@gmail.com> Acked-by: David Ahern <dsahern@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
1 parent 4eebff2 commit 18129a2

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/net/vrf.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1165,7 +1165,7 @@ static int vrf_fib_rule(const struct net_device *dev, __u8 family, bool add_it)
11651165
frh->family = family;
11661166
frh->action = FR_ACT_TO_TBL;
11671167

1168-
if (nla_put_u32(skb, FRA_L3MDEV, 1))
1168+
if (nla_put_u8(skb, FRA_L3MDEV, 1))
11691169
goto nla_put_failure;
11701170

11711171
if (nla_put_u32(skb, FRA_PRIORITY, FIB_RULE_PREF))

0 commit comments

Comments
 (0)