netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Hemminger <shemminger@vyatta.com>
To: Brian Haley <brian.haley@hp.com>
Cc: Jens Rosenboom <me@jayr.de>, david Miller <davem@davemloft.net>,
	"netdev@vger.kernel.org" <netdev@vger.kernel.org>,
	YOSHIFUJI Hideaki <yoshfuji@linux-ipv6.org>
Subject: Re: [PATCH] ipv6: Add IFA_F_DADFAILED flag
Date: Tue, 1 Dec 2009 16:01:00 -0800	[thread overview]
Message-ID: <20091201160100.2f53857c@nehalam> (raw)
In-Reply-To: <4AA9500E.8020309@hp.com>

On Thu, 10 Sep 2009 15:14:22 -0400
Brian Haley <brian.haley@hp.com> wrote:

> Hi Jens,
> 
> Jens Rosenboom wrote:
> >> Ok, how does this look?  I changed it to set the tentative flag as it did
> >> before, plus clear the dad_failed flag if the device got restarted,
> >> triggering DAD to happen again for any tentative address, that was an
> >> oversight on my part.
> > 
> > Looks fine to me so far, can you also send the patch for userspace? That
> > would making testing this a bit easier. ;-)
> 
> Iproute2 patch below, I'll re-post both once you have a chance to test.
> 
> >> I'd still like to know if using this last ifa_flag is going to be an issue,
> >> I actually finished a similar patch that uses a new IFA_ADDRFLAGS structure
> >> to pass in/out this additional info.
> > 
> > IMHO you should stick to this version, if any future feature needs
> > another bit, it may happen also to need two of them and so will need a
> > new structure then anyway, but why not keep it simple for now?
> 
> I'll leave it for now, I might just post as an RFC to get some feedback on it.
> 
> Thanks,
> 
> -Brian
> 
> 
> diff --git a/include/linux/if_addr.h b/include/linux/if_addr.h
> index a60c821..fd97404 100644
> --- a/include/linux/if_addr.h
> +++ b/include/linux/if_addr.h
> @@ -41,6 +41,7 @@ enum
>  
>  #define	IFA_F_NODAD		0x02
>  #define IFA_F_OPTIMISTIC	0x04
> +#define IFA_F_DADFAILED		0x08
>  #define	IFA_F_HOMEADDRESS	0x10
>  #define IFA_F_DEPRECATED	0x20
>  #define IFA_F_TENTATIVE		0x40
> diff --git a/ip/ipaddress.c b/ip/ipaddress.c
> index 267ecb3..97c7a8b 100644
> --- a/ip/ipaddress.c
> +++ b/ip/ipaddress.c
> @@ -508,6 +508,10 @@ int print_addrinfo(const struct sockaddr_nl *who, struct nlmsghdr *n,
>  		fprintf(fp, "dynamic ");
>  	} else
>  		ifa->ifa_flags &= ~IFA_F_PERMANENT;
> +	if (ifa->ifa_flags&IFA_F_DADFAILED) {
> +		ifa->ifa_flags &= ~IFA_F_DADFAILED;
> +		fprintf(fp, "dadfailed ");
> +	}
>  	if (ifa->ifa_flags)
>  		fprintf(fp, "flags %02x ", ifa->ifa_flags);
>  	if (rta_tb[IFA_LABEL])

Applied to iproute (for 2.6.32) with original message changelog

  reply	other threads:[~2009-12-02  0:01 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-05  1:38 [PATCH] ipv6: Add IFA_F_DADFAILED flag Brian Haley
2009-09-08 13:57 ` Jens Rosenboom
2009-09-08 15:18   ` Brian Haley
2009-09-08 15:43     ` Jens Rosenboom
2009-09-10  0:41       ` Brian Haley
2009-09-10 16:11         ` Jens Rosenboom
2009-09-10 19:14           ` Brian Haley
2009-12-02  0:01             ` Stephen Hemminger [this message]
2009-09-11 19:38 ` David Miller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20091201160100.2f53857c@nehalam \
    --to=shemminger@vyatta.com \
    --cc=brian.haley@hp.com \
    --cc=davem@davemloft.net \
    --cc=me@jayr.de \
    --cc=netdev@vger.kernel.org \
    --cc=yoshfuji@linux-ipv6.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).