All of lore.kernel.org
 help / color / mirror / Atom feed
From: Stephen Hemminger <stephen.hemminger@vyatta.com>
To: Jiri Bohac <jbohac@suse.cz>, netdev@vger.kernel.org
Cc: Herbert Xu <herbert@gondor.apana.org.au>,
	" David S. Miller" <davem@davemloft.net>,
	stephen hemminger <shemminger@vyatta.com>
Subject: Re: IPv6: autoconfiguration and suspend/resume or link down/up
Date: Tue, 19 Jul 2011 12:42:09 -0700	[thread overview]
Message-ID: <79ahktw3gy268nl9yyk76cxe.1311104529189@email.android.com> (raw)

bridge forwarding table; route cache; and neighbor table could have same problem. I thought carrier is supposed to toggle on suspend or hibernate

Jiri Bohac <jbohac@suse.cz> wrote:

>Hi,
>
>I came over a surprising behaviour with IPv6 autoconfiguration,
>which I think is a bug, but I would first like to hear other
>people's opinions before trying to fix this:
>
>Problem 1: all the address/route lifetimes are kept in jiffies
>and jiffies don't get incremented on resume. So when a
>route/address lifetime is 30 minutes and the system resumes after
>1 hour, the route/address should be considered expired, but it is
>not.
>
>Problem 2: when a system is moved to a new network a RS is not
>sent. Thus, IPv6 does not autoconfigure until the router sends a
>periodic RA. This can occur both while the system is alive and
>while it is suspended. I think the autoconfigured state should be
>discarded when the kernel suspects the system could have been
>moved to a different network.
>
>When the cable is unplugged and plugged in again, we already get
>notified through linkwatch -> netdev_state_change ->
>  -> call_netdevice_notifiers(NETDEV_CHANGE, ...)
>However, if the device has already been autoconfigured,
>addrconf_notify() only handles this event by printing a
>message.
>
>So my idea was to:
>- handle link up/down in addrconf_notify() similarly to
>  NETDEV_UP/NETDEV_DOWN
>
>- on suspend, faking a link down event; on resume, faking a link up event
>  (or better, having a special event type for suspend/resume)
>
>This would cause autoconfiguration to be restarted on resume as
>well as cable plug/unplug, solving both the above problems.
>
>Or do we want to completely rely on userspace tools
>(networkmanager/ifplug) and expect them to do NETDEV_DOWN on
>unplug/suspend and NETDEV_UP on plug/resume?
>
>Any thoughts?
>
>-- 
>Jiri Bohac <jbohac@suse.cz>
>SUSE Labs, SUSE CZ
>

             reply	other threads:[~2011-07-25 16:55 UTC|newest]

Thread overview: 21+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-07-19 19:42 Stephen Hemminger [this message]
2011-07-26  5:16 ` IPv6: autoconfiguration and suspend/resume or link down/up Anirban Chakraborty
  -- strict thread matches above, loose matches on Subject: below --
2011-07-25 16:55 Stephen Hemminger
2011-07-19 18:02 Jiri Bohac
2011-07-20 16:15 ` Stephen Hemminger
2011-07-20 16:29   ` Jiri Bohac
2011-07-20 16:21 ` Dan Williams
2011-07-20 16:36   ` Jiri Bohac
2011-07-21  5:30     ` Dan Williams
2011-07-21 16:35       ` Dan Williams
2011-07-21 19:44         ` Stephen Hemminger
2011-07-22  8:06 ` David Miller
2011-07-22  9:21   ` Herbert Xu
2011-07-23 14:31     ` Nicolas de Pesloüan
2011-07-23 15:27       ` Herbert Xu
2011-07-23 16:37         ` Stephen Hemminger
2011-07-24  0:18           ` Herbert Xu
2011-07-24  8:35             ` Nicolas de Pesloüan
2011-07-25  3:26               ` Stephen Hemminger
2011-07-25  3:46                 ` Herbert Xu
2011-07-27 19:48   ` Dan Williams

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=79ahktw3gy268nl9yyk76cxe.1311104529189@email.android.com \
    --to=stephen.hemminger@vyatta.com \
    --cc=davem@davemloft.net \
    --cc=herbert@gondor.apana.org.au \
    --cc=jbohac@suse.cz \
    --cc=netdev@vger.kernel.org \
    --cc=shemminger@vyatta.com \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.