diff mbox series

[OpenWrt-Devel,netifd] interface-ip: transfer prefix route ownership to kernel when IPv6 address becomes deprecated

Message ID 1580743613-29482-1-git-send-email-alin.nastac@technicolor.com
State Superseded
Delegated to: Hans Dedecker
Headers show
Series [OpenWrt-Devel,netifd] interface-ip: transfer prefix route ownership to kernel when IPv6 address becomes deprecated | expand

Commit Message

Alin Năstac Feb. 3, 2020, 3:26 p.m. UTC
From: Alin Nastac <alin.nastac@gmail.com>

When netifd manages the prefix route directly, it will remove it
the moment prefix gets deprecated. This will make it impossible
for the target to send ICMPv6 errors back to LAN devices still
using the deprecated prefix, thus breaking the L-14 requirement
of RFC 7084.

Signed-off-by: Alin Nastac <alin.nastac@gmail.com>
---
 interface-ip.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Hans Dedecker Feb. 4, 2020, 9:49 p.m. UTC | #1
Hi Alin,
On Mon, Feb 3, 2020 at 4:27 PM Alin Nastac <alin.nastac@gmail.com> wrote:
>
> From: Alin Nastac <alin.nastac@gmail.com>
>
> When netifd manages the prefix route directly, it will remove it
> the moment prefix gets deprecated. This will make it impossible
> for the target to send ICMPv6 errors back to LAN devices still
> using the deprecated prefix, thus breaking the L-14 requirement
> of RFC 7084.
>
> Signed-off-by: Alin Nastac <alin.nastac@gmail.com>
The patch fails to apply with the following error message :

Applying: interface-ip: transfer prefix route ownership to kernel when
IPv6 address becomes deprecated
error: sha1 information is lacking or useless (interface-ip.c).
error: could not build fake ancestor
Patch failed at 0001 interface-ip: transfer prefix route ownership to
kernel when IPv6 address becomes deprecated

Hans
> ---
>  interface-ip.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/interface-ip.c b/interface-ip.c
> index 91c305b..ff8f219 100644
> --- a/interface-ip.c
> +++ b/interface-ip.c
> @@ -913,7 +913,7 @@ interface_set_prefix_address(struct device_prefix_assignment *assignment,
>
>         addr.addr.in6 = assignment->addr;
>         addr.mask = assignment->length;
> -       addr.flags = DEVADDR_INET6 | DEVADDR_OFFLINK;
> +       addr.flags = DEVADDR_INET6;
>         addr.preferred_until = prefix->preferred_until;
>         addr.valid_until = prefix->valid_until;
>
> @@ -960,6 +960,7 @@ interface_set_prefix_address(struct device_prefix_assignment *assignment,
>                         route.addr = addr.addr;
>                 }
>
> +               addr.flags |= DEVADDR_OFFLINK;
>                 if (system_add_address(l3_downlink, &addr))
>                         return;
>
> --
> 2.7.4
>
Alin Năstac Feb. 5, 2020, 8:33 a.m. UTC | #2
Hi Hans,

On Tue, Feb 4, 2020 at 10:49 PM Hans Dedecker <dedeckeh@gmail.com> wrote:
>
> Hi Alin,
> On Mon, Feb 3, 2020 at 4:27 PM Alin Nastac <alin.nastac@gmail.com> wrote:
> >
> > From: Alin Nastac <alin.nastac@gmail.com>
> >
> > When netifd manages the prefix route directly, it will remove it
> > the moment prefix gets deprecated. This will make it impossible
> > for the target to send ICMPv6 errors back to LAN devices still
> > using the deprecated prefix, thus breaking the L-14 requirement
> > of RFC 7084.
> >
> > Signed-off-by: Alin Nastac <alin.nastac@gmail.com>
> The patch fails to apply with the following error message :
>
> Applying: interface-ip: transfer prefix route ownership to kernel when
> IPv6 address becomes deprecated
> error: sha1 information is lacking or useless (interface-ip.c).
> error: could not build fake ancestor
> Patch failed at 0001 interface-ip: transfer prefix route ownership to
> kernel when IPv6 address becomes deprecated
>
> >                         route.addr = addr.addr;
> >                 }
> >
> > +               addr.flags |= DEVADDR_OFFLINK;
> >                 if (system_add_address(l3_downlink, &addr))
> >                         return;
> >
> > --
> > 2.7.4
> >

I've downloaded the patch from
https://patchwork.ozlabs.org/patch/1232885/ and applied it
successfully with a git am command line:

nastaca@cplx1037:/usr/localdisk/openwrt/netifd$ git am
~/Downloads/OpenWrt-Devel-netifd-interface-ip-transfer-prefix-route-ownership-to-kernel-when-IPv6-address-becomes
-deprecated.patch
Applying: interface-ip: transfer prefix route ownership to kernel when
IPv6 address becomes deprecated

Alin
Adrian Schmutzler Feb. 5, 2020, 12:56 p.m. UTC | #3
Hi,

works for me as well.

However, I'd prefer a shorter commit title, e.g.

interface-ip: transfer prefix route ownership for deprecated ipv6addr to kernel

Best

Adrian

> -----Original Message-----
> From: openwrt-devel [mailto:openwrt-devel-bounces@lists.openwrt.org] On
> Behalf Of Alin Nastac
> Sent: Mittwoch, 5. Februar 2020 09:34
> To: Hans Dedecker <dedeckeh@gmail.com>
> Cc: openwrt-devel <openwrt-devel@lists.openwrt.org>
> Subject: Re: [OpenWrt-Devel] [netifd][PATCH] interface-ip: transfer prefix
route
> ownership to kernel when IPv6 address becomes deprecated
> 
> Hi Hans,
> 
> On Tue, Feb 4, 2020 at 10:49 PM Hans Dedecker <dedeckeh@gmail.com> wrote:
> >
> > Hi Alin,
> > On Mon, Feb 3, 2020 at 4:27 PM Alin Nastac <alin.nastac@gmail.com> wrote:
> > >
> > > From: Alin Nastac <alin.nastac@gmail.com>
> > >
> > > When netifd manages the prefix route directly, it will remove it
> > > the moment prefix gets deprecated. This will make it impossible
> > > for the target to send ICMPv6 errors back to LAN devices still
> > > using the deprecated prefix, thus breaking the L-14 requirement
> > > of RFC 7084.
> > >
> > > Signed-off-by: Alin Nastac <alin.nastac@gmail.com>
> > The patch fails to apply with the following error message :
> >
> > Applying: interface-ip: transfer prefix route ownership to kernel when
> > IPv6 address becomes deprecated
> > error: sha1 information is lacking or useless (interface-ip.c).
> > error: could not build fake ancestor
> > Patch failed at 0001 interface-ip: transfer prefix route ownership to
> > kernel when IPv6 address becomes deprecated
> >
> > >                         route.addr = addr.addr;
> > >                 }
> > >
> > > +               addr.flags |= DEVADDR_OFFLINK;
> > >                 if (system_add_address(l3_downlink, &addr))
> > >                         return;
> > >
> > > --
> > > 2.7.4
> > >
> 
> I've downloaded the patch from
> https://patchwork.ozlabs.org/patch/1232885/ and applied it
> successfully with a git am command line:
> 
> nastaca@cplx1037:/usr/localdisk/openwrt/netifd$ git am
> ~/Downloads/OpenWrt-Devel-netifd-interface-ip-transfer-prefix-route-
> ownership-to-kernel-when-IPv6-address-becomes
> -deprecated.patch
> Applying: interface-ip: transfer prefix route ownership to kernel when
> IPv6 address becomes deprecated
> 
> Alin
> 
> _______________________________________________
> openwrt-devel mailing list
> openwrt-devel@lists.openwrt.org
> https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Alin Năstac Feb. 5, 2020, 1:37 p.m. UTC | #4
Hi Adrian,

This patch has been superseded by https://patchwork.ozlabs.org/patch/1233845/

Alin

On Wed, Feb 5, 2020 at 1:56 PM Adrian Schmutzler
<mail@adrianschmutzler.de> wrote:
>
> Hi,
>
> works for me as well.
>
> However, I'd prefer a shorter commit title, e.g.
>
> interface-ip: transfer prefix route ownership for deprecated ipv6addr to kernel
>
> Best
>
> Adrian
>
> > -----Original Message-----
> > From: openwrt-devel [mailto:openwrt-devel-bounces@lists.openwrt.org] On
> > Behalf Of Alin Nastac
> > Sent: Mittwoch, 5. Februar 2020 09:34
> > To: Hans Dedecker <dedeckeh@gmail.com>
> > Cc: openwrt-devel <openwrt-devel@lists.openwrt.org>
> > Subject: Re: [OpenWrt-Devel] [netifd][PATCH] interface-ip: transfer prefix
> route
> > ownership to kernel when IPv6 address becomes deprecated
> >
> > Hi Hans,
> >
> > On Tue, Feb 4, 2020 at 10:49 PM Hans Dedecker <dedeckeh@gmail.com> wrote:
> > >
> > > Hi Alin,
> > > On Mon, Feb 3, 2020 at 4:27 PM Alin Nastac <alin.nastac@gmail.com> wrote:
> > > >
> > > > From: Alin Nastac <alin.nastac@gmail.com>
> > > >
> > > > When netifd manages the prefix route directly, it will remove it
> > > > the moment prefix gets deprecated. This will make it impossible
> > > > for the target to send ICMPv6 errors back to LAN devices still
> > > > using the deprecated prefix, thus breaking the L-14 requirement
> > > > of RFC 7084.
> > > >
> > > > Signed-off-by: Alin Nastac <alin.nastac@gmail.com>
> > > The patch fails to apply with the following error message :
> > >
> > > Applying: interface-ip: transfer prefix route ownership to kernel when
> > > IPv6 address becomes deprecated
> > > error: sha1 information is lacking or useless (interface-ip.c).
> > > error: could not build fake ancestor
> > > Patch failed at 0001 interface-ip: transfer prefix route ownership to
> > > kernel when IPv6 address becomes deprecated
> > >
> > > >                         route.addr = addr.addr;
> > > >                 }
> > > >
> > > > +               addr.flags |= DEVADDR_OFFLINK;
> > > >                 if (system_add_address(l3_downlink, &addr))
> > > >                         return;
> > > >
> > > > --
> > > > 2.7.4
> > > >
> >
> > I've downloaded the patch from
> > https://patchwork.ozlabs.org/patch/1232885/ and applied it
> > successfully with a git am command line:
> >
> > nastaca@cplx1037:/usr/localdisk/openwrt/netifd$ git am
> > ~/Downloads/OpenWrt-Devel-netifd-interface-ip-transfer-prefix-route-
> > ownership-to-kernel-when-IPv6-address-becomes
> > -deprecated.patch
> > Applying: interface-ip: transfer prefix route ownership to kernel when
> > IPv6 address becomes deprecated
> >
> > Alin
> >
> > _______________________________________________
> > openwrt-devel mailing list
> > openwrt-devel@lists.openwrt.org
> > https://lists.openwrt.org/mailman/listinfo/openwrt-devel
>
Adrian Schmutzler Feb. 5, 2020, 1:39 p.m. UTC | #5
Hi,

please use a "v2" next time.

Best

Adrian

> -----Original Message-----
> From: Alin Năstac [mailto:alin.nastac@gmail.com]
> Sent: Mittwoch, 5. Februar 2020 14:38
> To: Adrian Schmutzler <mail@adrianschmutzler.de>
> Cc: Hans Dedecker <dedeckeh@gmail.com>; openwrt-devel <openwrt-
> devel@lists.openwrt.org>
> Subject: Re: [OpenWrt-Devel] [netifd][PATCH] interface-ip: transfer prefix route
> ownership to kernel when IPv6 address becomes deprecated
> 
> Hi Adrian,
> 
> This patch has been superseded by
> https://patchwork.ozlabs.org/patch/1233845/
> 
> Alin
> 
> On Wed, Feb 5, 2020 at 1:56 PM Adrian Schmutzler
> <mail@adrianschmutzler.de> wrote:
> >
> > Hi,
> >
> > works for me as well.
> >
> > However, I'd prefer a shorter commit title, e.g.
> >
> > interface-ip: transfer prefix route ownership for deprecated ipv6addr to kernel
> >
> > Best
> >
> > Adrian
> >
> > > -----Original Message-----
> > > From: openwrt-devel [mailto:openwrt-devel-bounces@lists.openwrt.org] On
> > > Behalf Of Alin Nastac
> > > Sent: Mittwoch, 5. Februar 2020 09:34
> > > To: Hans Dedecker <dedeckeh@gmail.com>
> > > Cc: openwrt-devel <openwrt-devel@lists.openwrt.org>
> > > Subject: Re: [OpenWrt-Devel] [netifd][PATCH] interface-ip: transfer prefix
> > route
> > > ownership to kernel when IPv6 address becomes deprecated
> > >
> > > Hi Hans,
> > >
> > > On Tue, Feb 4, 2020 at 10:49 PM Hans Dedecker <dedeckeh@gmail.com>
> wrote:
> > > >
> > > > Hi Alin,
> > > > On Mon, Feb 3, 2020 at 4:27 PM Alin Nastac <alin.nastac@gmail.com>
> wrote:
> > > > >
> > > > > From: Alin Nastac <alin.nastac@gmail.com>
> > > > >
> > > > > When netifd manages the prefix route directly, it will remove it
> > > > > the moment prefix gets deprecated. This will make it impossible
> > > > > for the target to send ICMPv6 errors back to LAN devices still
> > > > > using the deprecated prefix, thus breaking the L-14 requirement
> > > > > of RFC 7084.
> > > > >
> > > > > Signed-off-by: Alin Nastac <alin.nastac@gmail.com>
> > > > The patch fails to apply with the following error message :
> > > >
> > > > Applying: interface-ip: transfer prefix route ownership to kernel when
> > > > IPv6 address becomes deprecated
> > > > error: sha1 information is lacking or useless (interface-ip.c).
> > > > error: could not build fake ancestor
> > > > Patch failed at 0001 interface-ip: transfer prefix route ownership to
> > > > kernel when IPv6 address becomes deprecated
> > > >
> > > > >                         route.addr = addr.addr;
> > > > >                 }
> > > > >
> > > > > +               addr.flags |= DEVADDR_OFFLINK;
> > > > >                 if (system_add_address(l3_downlink, &addr))
> > > > >                         return;
> > > > >
> > > > > --
> > > > > 2.7.4
> > > > >
> > >
> > > I've downloaded the patch from
> > > https://patchwork.ozlabs.org/patch/1232885/ and applied it
> > > successfully with a git am command line:
> > >
> > > nastaca@cplx1037:/usr/localdisk/openwrt/netifd$ git am
> > > ~/Downloads/OpenWrt-Devel-netifd-interface-ip-transfer-prefix-route-
> > > ownership-to-kernel-when-IPv6-address-becomes
> > > -deprecated.patch
> > > Applying: interface-ip: transfer prefix route ownership to kernel when
> > > IPv6 address becomes deprecated
> > >
> > > Alin
> > >
> > > _______________________________________________
> > > openwrt-devel mailing list
> > > openwrt-devel@lists.openwrt.org
> > > https://lists.openwrt.org/mailman/listinfo/openwrt-devel
> >
Alin Năstac Feb. 5, 2020, 1:42 p.m. UTC | #6
Since it has a different title, I presumed patchwork site will not
understand is the 2nd version of previous patch.

On Wed, Feb 5, 2020 at 2:39 PM Adrian Schmutzler
<mail@adrianschmutzler.de> wrote:
>
> Hi,
>
> please use a "v2" next time.
>
> Best
>
> Adrian
>
> > -----Original Message-----
> > From: Alin Năstac [mailto:alin.nastac@gmail.com]
> > Sent: Mittwoch, 5. Februar 2020 14:38
> > To: Adrian Schmutzler <mail@adrianschmutzler.de>
> > Cc: Hans Dedecker <dedeckeh@gmail.com>; openwrt-devel <openwrt-
> > devel@lists.openwrt.org>
> > Subject: Re: [OpenWrt-Devel] [netifd][PATCH] interface-ip: transfer prefix route
> > ownership to kernel when IPv6 address becomes deprecated
> >
> > Hi Adrian,
> >
> > This patch has been superseded by
> > https://patchwork.ozlabs.org/patch/1233845/
> >
> > Alin
> >
> > On Wed, Feb 5, 2020 at 1:56 PM Adrian Schmutzler
> > <mail@adrianschmutzler.de> wrote:
> > >
> > > Hi,
> > >
> > > works for me as well.
> > >
> > > However, I'd prefer a shorter commit title, e.g.
> > >
> > > interface-ip: transfer prefix route ownership for deprecated ipv6addr to kernel
> > >
> > > Best
> > >
> > > Adrian
> > >
> > > > -----Original Message-----
> > > > From: openwrt-devel [mailto:openwrt-devel-bounces@lists.openwrt.org] On
> > > > Behalf Of Alin Nastac
> > > > Sent: Mittwoch, 5. Februar 2020 09:34
> > > > To: Hans Dedecker <dedeckeh@gmail.com>
> > > > Cc: openwrt-devel <openwrt-devel@lists.openwrt.org>
> > > > Subject: Re: [OpenWrt-Devel] [netifd][PATCH] interface-ip: transfer prefix
> > > route
> > > > ownership to kernel when IPv6 address becomes deprecated
> > > >
> > > > Hi Hans,
> > > >
> > > > On Tue, Feb 4, 2020 at 10:49 PM Hans Dedecker <dedeckeh@gmail.com>
> > wrote:
> > > > >
> > > > > Hi Alin,
> > > > > On Mon, Feb 3, 2020 at 4:27 PM Alin Nastac <alin.nastac@gmail.com>
> > wrote:
> > > > > >
> > > > > > From: Alin Nastac <alin.nastac@gmail.com>
> > > > > >
> > > > > > When netifd manages the prefix route directly, it will remove it
> > > > > > the moment prefix gets deprecated. This will make it impossible
> > > > > > for the target to send ICMPv6 errors back to LAN devices still
> > > > > > using the deprecated prefix, thus breaking the L-14 requirement
> > > > > > of RFC 7084.
> > > > > >
> > > > > > Signed-off-by: Alin Nastac <alin.nastac@gmail.com>
> > > > > The patch fails to apply with the following error message :
> > > > >
> > > > > Applying: interface-ip: transfer prefix route ownership to kernel when
> > > > > IPv6 address becomes deprecated
> > > > > error: sha1 information is lacking or useless (interface-ip.c).
> > > > > error: could not build fake ancestor
> > > > > Patch failed at 0001 interface-ip: transfer prefix route ownership to
> > > > > kernel when IPv6 address becomes deprecated
> > > > >
> > > > > >                         route.addr = addr.addr;
> > > > > >                 }
> > > > > >
> > > > > > +               addr.flags |= DEVADDR_OFFLINK;
> > > > > >                 if (system_add_address(l3_downlink, &addr))
> > > > > >                         return;
> > > > > >
> > > > > > --
> > > > > > 2.7.4
> > > > > >
> > > >
> > > > I've downloaded the patch from
> > > > https://patchwork.ozlabs.org/patch/1232885/ and applied it
> > > > successfully with a git am command line:
> > > >
> > > > nastaca@cplx1037:/usr/localdisk/openwrt/netifd$ git am
> > > > ~/Downloads/OpenWrt-Devel-netifd-interface-ip-transfer-prefix-route-
> > > > ownership-to-kernel-when-IPv6-address-becomes
> > > > -deprecated.patch
> > > > Applying: interface-ip: transfer prefix route ownership to kernel when
> > > > IPv6 address becomes deprecated
> > > >
> > > > Alin
> > > >
> > > > _______________________________________________
> > > > openwrt-devel mailing list
> > > > openwrt-devel@lists.openwrt.org
> > > > https://lists.openwrt.org/mailman/listinfo/openwrt-devel
> > >
>
Adrian Schmutzler Feb. 5, 2020, 3:07 p.m. UTC | #7
> -----Original Message-----
> From: Alin Năstac [mailto:alin.nastac@gmail.com]
> Sent: Mittwoch, 5. Februar 2020 14:43
> To: Adrian Schmutzler <mail@adrianschmutzler.de>
> Cc: openwrt-devel <openwrt-devel@lists.openwrt.org>
> Subject: Re: [OpenWrt-Devel] [netifd][PATCH] interface-ip: transfer prefix route
> ownership to kernel when IPv6 address becomes deprecated
> 
> Since it has a different title, I presumed patchwork site will not
> understand is the 2nd version of previous patch.

Patchwork won't care. It only makes problems if you send the exact same title without version bump.

But for people looking at it version might help, unless you really do something completely different in the new patch.

Best

Adrian

> 
> On Wed, Feb 5, 2020 at 2:39 PM Adrian Schmutzler
> <mail@adrianschmutzler.de> wrote:
> >
> > Hi,
> >
> > please use a "v2" next time.
> >
> > Best
> >
> > Adrian
> >
> > > -----Original Message-----
> > > From: Alin Năstac [mailto:alin.nastac@gmail.com]
> > > Sent: Mittwoch, 5. Februar 2020 14:38
> > > To: Adrian Schmutzler <mail@adrianschmutzler.de>
> > > Cc: Hans Dedecker <dedeckeh@gmail.com>; openwrt-devel <openwrt-
> > > devel@lists.openwrt.org>
> > > Subject: Re: [OpenWrt-Devel] [netifd][PATCH] interface-ip: transfer prefix
> route
> > > ownership to kernel when IPv6 address becomes deprecated
> > >
> > > Hi Adrian,
> > >
> > > This patch has been superseded by
> > > https://patchwork.ozlabs.org/patch/1233845/
> > >
> > > Alin
> > >
> > > On Wed, Feb 5, 2020 at 1:56 PM Adrian Schmutzler
> > > <mail@adrianschmutzler.de> wrote:
> > > >
> > > > Hi,
> > > >
> > > > works for me as well.
> > > >
> > > > However, I'd prefer a shorter commit title, e.g.
> > > >
> > > > interface-ip: transfer prefix route ownership for deprecated ipv6addr to
> kernel
> > > >
> > > > Best
> > > >
> > > > Adrian
> > > >
> > > > > -----Original Message-----
> > > > > From: openwrt-devel [mailto:openwrt-devel-bounces@lists.openwrt.org]
> On
> > > > > Behalf Of Alin Nastac
> > > > > Sent: Mittwoch, 5. Februar 2020 09:34
> > > > > To: Hans Dedecker <dedeckeh@gmail.com>
> > > > > Cc: openwrt-devel <openwrt-devel@lists.openwrt.org>
> > > > > Subject: Re: [OpenWrt-Devel] [netifd][PATCH] interface-ip: transfer
> prefix
> > > > route
> > > > > ownership to kernel when IPv6 address becomes deprecated
> > > > >
> > > > > Hi Hans,
> > > > >
> > > > > On Tue, Feb 4, 2020 at 10:49 PM Hans Dedecker <dedeckeh@gmail.com>
> > > wrote:
> > > > > >
> > > > > > Hi Alin,
> > > > > > On Mon, Feb 3, 2020 at 4:27 PM Alin Nastac <alin.nastac@gmail.com>
> > > wrote:
> > > > > > >
> > > > > > > From: Alin Nastac <alin.nastac@gmail.com>
> > > > > > >
> > > > > > > When netifd manages the prefix route directly, it will remove it
> > > > > > > the moment prefix gets deprecated. This will make it impossible
> > > > > > > for the target to send ICMPv6 errors back to LAN devices still
> > > > > > > using the deprecated prefix, thus breaking the L-14 requirement
> > > > > > > of RFC 7084.
> > > > > > >
> > > > > > > Signed-off-by: Alin Nastac <alin.nastac@gmail.com>
> > > > > > The patch fails to apply with the following error message :
> > > > > >
> > > > > > Applying: interface-ip: transfer prefix route ownership to kernel when
> > > > > > IPv6 address becomes deprecated
> > > > > > error: sha1 information is lacking or useless (interface-ip.c).
> > > > > > error: could not build fake ancestor
> > > > > > Patch failed at 0001 interface-ip: transfer prefix route ownership to
> > > > > > kernel when IPv6 address becomes deprecated
> > > > > >
> > > > > > >                         route.addr = addr.addr;
> > > > > > >                 }
> > > > > > >
> > > > > > > +               addr.flags |= DEVADDR_OFFLINK;
> > > > > > >                 if (system_add_address(l3_downlink, &addr))
> > > > > > >                         return;
> > > > > > >
> > > > > > > --
> > > > > > > 2.7.4
> > > > > > >
> > > > >
> > > > > I've downloaded the patch from
> > > > > https://patchwork.ozlabs.org/patch/1232885/ and applied it
> > > > > successfully with a git am command line:
> > > > >
> > > > > nastaca@cplx1037:/usr/localdisk/openwrt/netifd$ git am
> > > > > ~/Downloads/OpenWrt-Devel-netifd-interface-ip-transfer-prefix-route-
> > > > > ownership-to-kernel-when-IPv6-address-becomes
> > > > > -deprecated.patch
> > > > > Applying: interface-ip: transfer prefix route ownership to kernel when
> > > > > IPv6 address becomes deprecated
> > > > >
> > > > > Alin
> > > > >
> > > > > _______________________________________________
> > > > > openwrt-devel mailing list
> > > > > openwrt-devel@lists.openwrt.org
> > > > > https://lists.openwrt.org/mailman/listinfo/openwrt-devel
> > > >
> >
diff mbox series

Patch

diff --git a/interface-ip.c b/interface-ip.c
index 91c305b..ff8f219 100644
--- a/interface-ip.c
+++ b/interface-ip.c
@@ -913,7 +913,7 @@  interface_set_prefix_address(struct device_prefix_assignment *assignment,
 
 	addr.addr.in6 = assignment->addr;
 	addr.mask = assignment->length;
-	addr.flags = DEVADDR_INET6 | DEVADDR_OFFLINK;
+	addr.flags = DEVADDR_INET6;
 	addr.preferred_until = prefix->preferred_until;
 	addr.valid_until = prefix->valid_until;
 
@@ -960,6 +960,7 @@  interface_set_prefix_address(struct device_prefix_assignment *assignment,
 			route.addr = addr.addr;
 		}
 
+		addr.flags |= DEVADDR_OFFLINK;
 		if (system_add_address(l3_downlink, &addr))
 			return;