Loading net/mpls/af_mpls.c +4 −4 Original line number Diff line number Diff line Loading @@ -230,7 +230,7 @@ static struct mpls_nh *mpls_get_nexthop(struct mpls_route *rt, u8 index) * Since those fields can change at any moment, use READ_ONCE to * access both. */ static struct mpls_nh *mpls_select_multipath(struct mpls_route *rt, static const struct mpls_nh *mpls_select_multipath(struct mpls_route *rt, struct sk_buff *skb) { u32 hash = 0; Loading Loading @@ -343,8 +343,8 @@ static int mpls_forward(struct sk_buff *skb, struct net_device *dev, { struct net *net = dev_net(dev); struct mpls_shim_hdr *hdr; const struct mpls_nh *nh; struct mpls_route *rt; struct mpls_nh *nh; struct mpls_entry_decoded dec; struct net_device *out_dev; struct mpls_dev *out_mdev; Loading Loading @@ -2333,12 +2333,12 @@ static int mpls_getroute(struct sk_buff *in_skb, struct nlmsghdr *in_nlh, u32 labels[MAX_NEW_LABELS]; struct mpls_shim_hdr *hdr; unsigned int hdr_size = 0; const struct mpls_nh *nh; struct net_device *dev; struct mpls_route *rt; struct rtmsg *rtm, *r; struct nlmsghdr *nlh; struct sk_buff *skb; struct mpls_nh *nh; u8 n_labels; int err; Loading net/mpls/internal.h +1 −1 Original line number Diff line number Diff line Loading @@ -158,7 +158,7 @@ struct mpls_route { /* next hop label forwarding entry */ }; #define for_nexthops(rt) { \ int nhsel; struct mpls_nh *nh; \ int nhsel; const struct mpls_nh *nh; \ for (nhsel = 0, nh = (rt)->rt_nh; \ nhsel < (rt)->rt_nhn; \ nh = (void *)nh + (rt)->rt_nh_size, nhsel++) Loading Loading
net/mpls/af_mpls.c +4 −4 Original line number Diff line number Diff line Loading @@ -230,7 +230,7 @@ static struct mpls_nh *mpls_get_nexthop(struct mpls_route *rt, u8 index) * Since those fields can change at any moment, use READ_ONCE to * access both. */ static struct mpls_nh *mpls_select_multipath(struct mpls_route *rt, static const struct mpls_nh *mpls_select_multipath(struct mpls_route *rt, struct sk_buff *skb) { u32 hash = 0; Loading Loading @@ -343,8 +343,8 @@ static int mpls_forward(struct sk_buff *skb, struct net_device *dev, { struct net *net = dev_net(dev); struct mpls_shim_hdr *hdr; const struct mpls_nh *nh; struct mpls_route *rt; struct mpls_nh *nh; struct mpls_entry_decoded dec; struct net_device *out_dev; struct mpls_dev *out_mdev; Loading Loading @@ -2333,12 +2333,12 @@ static int mpls_getroute(struct sk_buff *in_skb, struct nlmsghdr *in_nlh, u32 labels[MAX_NEW_LABELS]; struct mpls_shim_hdr *hdr; unsigned int hdr_size = 0; const struct mpls_nh *nh; struct net_device *dev; struct mpls_route *rt; struct rtmsg *rtm, *r; struct nlmsghdr *nlh; struct sk_buff *skb; struct mpls_nh *nh; u8 n_labels; int err; Loading
net/mpls/internal.h +1 −1 Original line number Diff line number Diff line Loading @@ -158,7 +158,7 @@ struct mpls_route { /* next hop label forwarding entry */ }; #define for_nexthops(rt) { \ int nhsel; struct mpls_nh *nh; \ int nhsel; const struct mpls_nh *nh; \ for (nhsel = 0, nh = (rt)->rt_nh; \ nhsel < (rt)->rt_nhn; \ nh = (void *)nh + (rt)->rt_nh_size, nhsel++) Loading