Patchwork gre: fix copy and paste error

login
register
mail settings
Submitter Patrick McHardy
Date Oct. 10, 2008, 3:54 p.m.
Message ID <48EF7AC0.6080104@trash.net>
Download mbox | patch
Permalink /patch/3822/
State Accepted
Delegated to: David Miller
Headers show

Comments

Patrick McHardy - Oct. 10, 2008, 3:54 p.m.

Herbert Xu - Oct. 10, 2008, 3:57 p.m.
On Fri, Oct 10, 2008 at 05:54:40PM +0200, Patrick McHardy wrote:

> commit c7d32967f53c4d3ded69f0e645b7c0848ac8cb1b
> Author: Patrick McHardy <kaber@trash.net>
> Date:   Fri Oct 10 17:53:36 2008 +0200
> 
>     gre: fix copy and paste error
>     
>     The flags are dumped twice, the keys not at all.
>     
>     Signed-off-by: Patrick McHardy <kaber@trash.net>

Good catch.

Thanks Patrick!
David Miller - Oct. 10, 2008, 7:10 p.m.
From: Herbert Xu <herbert@gondor.apana.org.au>
Date: Fri, 10 Oct 2008 23:57:32 +0800

> On Fri, Oct 10, 2008 at 05:54:40PM +0200, Patrick McHardy wrote:
> 
> > commit c7d32967f53c4d3ded69f0e645b7c0848ac8cb1b
> > Author: Patrick McHardy <kaber@trash.net>
> > Date:   Fri Oct 10 17:53:36 2008 +0200
> > 
> >     gre: fix copy and paste error
> >     
> >     The flags are dumped twice, the keys not at all.
> >     
> >     Signed-off-by: Patrick McHardy <kaber@trash.net>
> 
> Good catch.
> 
> Thanks Patrick!

Applied, thanks everyone.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Patch

commit c7d32967f53c4d3ded69f0e645b7c0848ac8cb1b
Author: Patrick McHardy <kaber@trash.net>
Date:   Fri Oct 10 17:53:36 2008 +0200

    gre: fix copy and paste error
    
    The flags are dumped twice, the keys not at all.
    
    Signed-off-by: Patrick McHardy <kaber@trash.net>

diff --git a/net/ipv4/ip_gre.c b/net/ipv4/ip_gre.c
index 0d5e35b..c0755e9 100644
--- a/net/ipv4/ip_gre.c
+++ b/net/ipv4/ip_gre.c
@@ -1539,8 +1539,8 @@  static int ipgre_fill_info(struct sk_buff *skb, const struct net_device *dev)
 	NLA_PUT_U32(skb, IFLA_GRE_LINK, p->link);
 	NLA_PUT_BE16(skb, IFLA_GRE_IFLAGS, p->i_flags);
 	NLA_PUT_BE16(skb, IFLA_GRE_OFLAGS, p->o_flags);
-	NLA_PUT_BE32(skb, IFLA_GRE_IFLAGS, p->i_flags);
-	NLA_PUT_BE32(skb, IFLA_GRE_OFLAGS, p->o_flags);
+	NLA_PUT_BE32(skb, IFLA_GRE_IKEY, p->i_key);
+	NLA_PUT_BE32(skb, IFLA_GRE_OKEY, p->o_key);
 	NLA_PUT(skb, IFLA_GRE_LOCAL, 4, &p->iph.saddr);
 	NLA_PUT(skb, IFLA_GRE_REMOTE, 4, &p->iph.daddr);
 	NLA_PUT_U8(skb, IFLA_GRE_TTL, p->iph.ttl);