public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* kernel -2.6.35.13 longterm
@ 2011-07-05 14:35 Stephen Clark
  2011-07-05 15:05 ` Greg KH
  0 siblings, 1 reply; 5+ messages in thread
From: Stephen Clark @ 2011-07-05 14:35 UTC (permalink / raw)
  To: linux-kernel, Greg KH

Hello,

Is it possible to get the following patches included in the longterm kernel
2.6.35.13?

They let linux behave according to:

"Basic Requirements for IPv6 Customer Edge Routers
    draft-ietf-v6ops-ipv6-cpe-router-09"

From: Thomas Graf
Subject: [PATCH] ipv6: add special mode accept_ra=2 to accept RA while 
configured as router
Date: Friday, September 3, 2010 - 5:59 am

The current IPv6 behavior is to not accept router advertisements while
forwarding, i.e. configured as router.

This does make sense, a router is typically not supposed to be auto
configured. However there are exceptions and we should allow the
current behavior to be overwritten.

Therefore this patch enables the user to overrule the "if forwarding
enabled then don't listen to RAs" rule by setting accept_ra to the
special value of 2.

An alternative would be to ignore the forwarding switch alltogether
and solely accept RAs based on the value of accept_ra. However, I
found that if not intended, accepting RAs as a router can lead to
strange unwanted behavior therefore we it seems wise to only do so
if the user explicitely asks for this behavior.

Signed-off-by: Thomas Graf <tgraf at infradead.org>

Index: net-2.6/net/ipv6/ndisc.c
===================================================================
--- net-2.6.orig/net/ipv6/ndisc.c
+++ net-2.6/net/ipv6/ndisc.c
@@ -1105,6 +1105,18 @@ errout:
       rtnl_set_sk_err(net, RTNLGRP_ND_USEROPT, err);
   }

+static inline int accept_ra(struct inet6_dev *in6_dev)
+{
+    /*
+     * If forwarding is enabled, RA are not accepted unless the special
+     * hybrid mode (accept_ra=2) is enabled.
+     */
+    if (in6_dev->cnf.forwarding && in6_dev->cnf.accept_ra < 2)
+        return 0;
+
+    return in6_dev->cnf.accept_ra;
+}
+
   static void ndisc_router_discovery(struct sk_buff *skb)
   {
       struct ra_msg *ra_msg = (struct ra_msg *)skb_transport_header(skb);
@@ -1158,8 +1170,7 @@ static void ndisc_router_discovery(struc
           return;
       }

-    /* skip route and link configuration on routers */
-    if (in6_dev->cnf.forwarding || !in6_dev->cnf.accept_ra)
+    if (!accept_ra(in6_dev))
           goto skip_linkparms;

   #ifdef CONFIG_IPV6_NDISC_NODETYPE
@@ -1309,8 +1320,7 @@ skip_linkparms:
                    NEIGH_UPDATE_F_ISROUTER);
       }

-    /* skip route and link configuration on routers */
-    if (in6_dev->cnf.forwarding || !in6_dev->cnf.accept_ra)
+    if (!accept_ra(in6_dev))
           goto out;

   #ifdef CONFIG_IPV6_ROUTE_INFO

Similar to accepting router advertisement, the IPv6 stack does not send router
solicitations if forwarding is enabled.

This patch enables this behavior to be overruled by setting forwarding to the
special value 2.

Signed-off-by: Thomas Graf <tgraf at xxxxxxxxxxxxx>

Index: net-2.6/net/ipv6/addrconf.c
===================================================================
--- net-2.6.orig/net/ipv6/addrconf.c
+++ net-2.6/net/ipv6/addrconf.c
@@ -2964,7 +2964,8 @@ static void addrconf_dad_completed(struc
          start sending router solicitations.
        */

-    if (ifp->idev->cnf.forwarding == 0 &&
+    if ((ifp->idev->cnf.forwarding == 0 ||
+         ifp->idev->cnf.forwarding == 2) &&
           ifp->idev->cnf.rtr_solicits > 0 &&
           (dev->flags&IFF_LOOPBACK) == 0 &&
           (ipv6_addr_type(&ifp->addr) & IPV6_ADDR_LINKLOCAL)) {





Thanks for your consideration,
Steve Clark

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: kernel -2.6.35.13 longterm
  2011-07-05 14:35 kernel -2.6.35.13 longterm Stephen Clark
@ 2011-07-05 15:05 ` Greg KH
  2011-07-05 17:32   ` Stephen Clark
  0 siblings, 1 reply; 5+ messages in thread
From: Greg KH @ 2011-07-05 15:05 UTC (permalink / raw)
  To: Stephen Clark; +Cc: linux-kernel

On Tue, Jul 05, 2011 at 10:35:25AM -0400, Stephen Clark wrote:
> Hello,
> 
> Is it possible to get the following patches included in the longterm kernel
> 2.6.35.13?

Possibly, but you need to email the correct person and email address,
none of which you did :)

Try stable@kernel.org, and the .35-longterm maintainer (hint, it's not
me.)

> They let linux behave according to:
> 
> "Basic Requirements for IPv6 Customer Edge Routers
>    draft-ietf-v6ops-ipv6-cpe-router-09"

That looks like a new feature, not a regression or bugfix, right?

Did you read Documentation/stable_kernel_rules.txt?

> From: Thomas Graf
> Subject: [PATCH] ipv6: add special mode accept_ra=2 to accept RA
> while configured as router
> Date: Friday, September 3, 2010 - 5:59 am
>

You forgot to mention what the git commit id this is upstream in Linus's
branch, and to copy the people involved in the original patch (author,
subsystem maintainer, etc.) to see if they agree it should go in.

greg k-h

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: kernel -2.6.35.13 longterm
  2011-07-05 15:05 ` Greg KH
@ 2011-07-05 17:32   ` Stephen Clark
  2011-07-05 17:38     ` Greg KH
  0 siblings, 1 reply; 5+ messages in thread
From: Stephen Clark @ 2011-07-05 17:32 UTC (permalink / raw)
  To: Greg KH, linux-kernel

On 07/05/2011 11:05 AM, Greg KH wrote:
> On Tue, Jul 05, 2011 at 10:35:25AM -0400, Stephen Clark wrote:
>
>> Hello,
>>
>> Is it possible to get the following patches included in the longterm kernel
>> 2.6.35.13?
>>
> Possibly, but you need to email the correct person and email address,
> none of which you did :)
>
> Try stable@kernel.org, and the .35-longterm maintainer (hint, it's not
> me.)
>
>
Ok - hmmm maintainers in 2.6.35.13 still lists you - but I'll look at a later 
kernel maintainers file.
>> They let linux behave according to:
>>
>> "Basic Requirements for IPv6 Customer Edge Routers
>>     draft-ietf-v6ops-ipv6-cpe-router-09"
>>
> That looks like a new feature, not a regression or bugfix, right?
>
> Did you read Documentation/stable_kernel_rules.txt?
>
>
Not til just now. Yes it is a new feature, but with IPV6 it is seems that it 
would be of use.
I know that my company needs it as we are moving off of FreeBSD to Linux for our
fw/vpn/router appliance. The alternative is to just keep applying the patch myself.

>> From: Thomas Graf
>> Subject: [PATCH] ipv6: add special mode accept_ra=2 to accept RA
>> while configured as router
>> Date: Friday, September 3, 2010 - 5:59 am
>>
>>
> You forgot to mention what the git commit id this is upstream in Linus's
> branch, and to copy the people involved in the original patch (author,
> subsystem maintainer, etc.) to see if they agree it should go in.
>
>
How in the world do you get the commit info?
> greg k-h
>
>
Thanks for the response - I'll see if I can get all the info and do a proper 
submission.

Regards,
Steve

-- 

"They that give up essential liberty to obtain temporary safety,
deserve neither liberty nor safety."  (Ben Franklin)

"The course of history shows that as a government grows, liberty
decreases."  (Thomas Jefferson)




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: kernel -2.6.35.13 longterm
  2011-07-05 17:32   ` Stephen Clark
@ 2011-07-05 17:38     ` Greg KH
  2011-07-06 18:11       ` Andi Kleen
  0 siblings, 1 reply; 5+ messages in thread
From: Greg KH @ 2011-07-05 17:38 UTC (permalink / raw)
  To: Stephen Clark; +Cc: linux-kernel

On Tue, Jul 05, 2011 at 01:32:59PM -0400, Stephen Clark wrote:
> On 07/05/2011 11:05 AM, Greg KH wrote:
> >On Tue, Jul 05, 2011 at 10:35:25AM -0400, Stephen Clark wrote:
> >
> >>Hello,
> >>
> >>Is it possible to get the following patches included in the longterm kernel
> >>2.6.35.13?
> >>
> >Possibly, but you need to email the correct person and email address,
> >none of which you did :)
> >
> >Try stable@kernel.org, and the .35-longterm maintainer (hint, it's not
> >me.)
> >
> >
> Ok - hmmm maintainers in 2.6.35.13 still lists you - but I'll look
> at a later kernel maintainers file.

It's not really obvious who is in charge, the -longterm maintainer
really should put their name there.  I think for .35 it's Andi Kleen.

> >>They let linux behave according to:
> >>
> >>"Basic Requirements for IPv6 Customer Edge Routers
> >>    draft-ietf-v6ops-ipv6-cpe-router-09"
> >>
> >That looks like a new feature, not a regression or bugfix, right?
> >
> >Did you read Documentation/stable_kernel_rules.txt?
> >
> >
> Not til just now. Yes it is a new feature, but with IPV6 it is seems
> that it would be of use.
> I know that my company needs it as we are moving off of FreeBSD to Linux for our
> fw/vpn/router appliance. The alternative is to just keep applying the patch myself.

As described above, new features are not for stable or longterm kernels,
sorry.  I recommend just applying it yourself if you really are stuck
with the .35 kernel.

> >>From: Thomas Graf
> >>Subject: [PATCH] ipv6: add special mode accept_ra=2 to accept RA
> >>while configured as router
> >>Date: Friday, September 3, 2010 - 5:59 am
> >>
> >>
> >You forgot to mention what the git commit id this is upstream in Linus's
> >branch, and to copy the people involved in the original patch (author,
> >subsystem maintainer, etc.) to see if they agree it should go in.
> >
> >
> How in the world do you get the commit info?

>From the original patch and Linus's git tree?  Also, look at
scripts/get_maintainer.pl it will show you who to send stuff to.

Hope this helps,

greg k-h

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: kernel -2.6.35.13 longterm
  2011-07-05 17:38     ` Greg KH
@ 2011-07-06 18:11       ` Andi Kleen
  0 siblings, 0 replies; 5+ messages in thread
From: Andi Kleen @ 2011-07-06 18:11 UTC (permalink / raw)
  To: Greg KH; +Cc: Stephen Clark, linux-kernel

Greg KH <greg@kroah.com> writes:
>
> It's not really obvious who is in charge, the -longterm maintainer
> really should put their name there.  I think for .35 it's Andi Kleen.

I'll add myself there, thanks.

-Andi

-- 
ak@linux.intel.com -- Speaking for myself only

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2011-07-06 18:13 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-07-05 14:35 kernel -2.6.35.13 longterm Stephen Clark
2011-07-05 15:05 ` Greg KH
2011-07-05 17:32   ` Stephen Clark
2011-07-05 17:38     ` Greg KH
2011-07-06 18:11       ` Andi Kleen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox