Message ID | 1553700739-11387-6-git-send-email-gvrose8192@gmail.com |
---|---|
State | Accepted |
Headers | show |
Series | Linux datapath upstream fixes | expand |
Bleep bloop. Greetings Gregory Rose, I am a robot and I have tried out your patch. Thanks for your contribution. I encountered some error that I wasn't expecting. See the details below. checkpatch: ERROR: Author Alan Maguire <alan.maguire@oracle.com> needs to sign off. WARNING: Unexpected sign-offs from developers who are not authors or co-authors or committers: Greg Rose <gvrose8192@gmail.com> Lines checked: 235, Warnings: 1, Errors: 1 Please check this out. If you feel there has been an error, please email aconole@bytheb.org Thanks, 0-day Robot
On 3/27/2019 9:16 AM, 0-day Robot wrote: > Bleep bloop. Greetings Gregory Rose, I am a robot and I have tried out your patch. > Thanks for your contribution. > > I encountered some error that I wasn't expecting. See the details below. > > > checkpatch: > ERROR: Author Alan Maguire <alan.maguire@oracle.com> needs to sign off. > WARNING: Unexpected sign-offs from developers who are not authors or co-authors or committers: Greg Rose <gvrose8192@gmail.com> > Lines checked: 235, Warnings: 1, Errors: 1 > > > Please check this out. If you feel there has been an error, please email aconole@bytheb.org > > Thanks, > 0-day Robot I think the format of these upstream patches conforms to the documented method. The author's sign-off is in the body of the commit message. - Greg
This patch series look good to me. Thanks Greg for the work. Reviewed-by: Yifeng Sun <pkusunyifeng@gmail.com> On Wed, Mar 27, 2019 at 10:45 AM Gregory Rose <gvrose8192@gmail.com> wrote: > > On 3/27/2019 9:16 AM, 0-day Robot wrote: > > Bleep bloop. Greetings Gregory Rose, I am a robot and I have tried out your patch. > > Thanks for your contribution. > > > > I encountered some error that I wasn't expecting. See the details below. > > > > > > checkpatch: > > ERROR: Author Alan Maguire <alan.maguire@oracle.com> needs to sign off. > > WARNING: Unexpected sign-offs from developers who are not authors or co-authors or committers: Greg Rose <gvrose8192@gmail.com> > > Lines checked: 235, Warnings: 1, Errors: 1 > > > > > > Please check this out. If you feel there has been an error, please email aconole@bytheb.org > > > > Thanks, > > 0-day Robot > I think the format of these upstream patches conforms to the documented > method. The author's sign-off > is in the body of the commit message. > > - Greg > > _______________________________________________ > dev mailing list > dev@openvswitch.org > https://mail.openvswitch.org/mailman/listinfo/ovs-dev
diff --git a/datapath/linux/compat/include/net/dst_metadata.h b/datapath/linux/compat/include/net/dst_metadata.h index 36f3f39..9a82b3c 100644 --- a/datapath/linux/compat/include/net/dst_metadata.h +++ b/datapath/linux/compat/include/net/dst_metadata.h @@ -127,4 +127,16 @@ rpl_metadata_dst_alloc(u8 optslen, enum metadata_type type, gfp_t flags) } #define metadata_dst_alloc rpl_metadata_dst_alloc +#ifndef DST_METADATA +#define DST_METADATA 0x0200 +#endif + +static inline bool rpl_skb_valid_dst(const struct sk_buff *skb) +{ + struct dst_entry *dst = skb_dst(skb); + + return dst && !(dst->flags & DST_METADATA); +} +#define skb_valid_dst rpl_skb_valid_dst + #endif /* __NET_DST_METADATA_WRAPPER_H */ diff --git a/datapath/linux/compat/ip_tunnel.c b/datapath/linux/compat/ip_tunnel.c index d16e60f..7dd57fe 100644 --- a/datapath/linux/compat/ip_tunnel.c +++ b/datapath/linux/compat/ip_tunnel.c @@ -51,6 +51,7 @@ #include <net/net_namespace.h> #include <net/netns/generic.h> #include <net/rtnetlink.h> +#include <net/dst_metadata.h> #if IS_ENABLED(CONFIG_IPV6) #include <net/ipv6.h> @@ -263,9 +264,9 @@ static int rpl_tnl_update_pmtu(struct net_device *dev, struct sk_buff *skb, mtu = dst_mtu(&rt->dst) - dev->hard_header_len - sizeof(struct iphdr) - tunnel->hlen; else - mtu = skb_dst(skb) ? dst_mtu(skb_dst(skb)) : dev->mtu; + mtu = skb_valid_dst(skb) ? dst_mtu(skb_dst(skb)) : dev->mtu; - if (skb_dst(skb)) + if (skb_valid_dst(skb)) skb_dst(skb)->ops->update_pmtu(skb_dst(skb), NULL, skb, mtu); if (skb->protocol == htons(ETH_P_IP)) { @@ -279,7 +280,10 @@ static int rpl_tnl_update_pmtu(struct net_device *dev, struct sk_buff *skb, } #if IS_ENABLED(CONFIG_IPV6) else if (skb->protocol == htons(ETH_P_IPV6)) { - struct rt6_info *rt6 = (struct rt6_info *)skb_dst(skb); + struct rt6_info *rt6; + + rt6 = skb_valid_dst(skb) ? (struct rt6_info *)skb_dst(skb) : + NULL; if (rt6 && mtu < dst_mtu(skb_dst(skb)) && mtu >= IPV6_MIN_MTU) {