Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 24 Mar 2001 09:21:56 +0100
From:      J Wunsch <j@uriah.heep.sax.de>
To:        cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org
Cc:        Brian Somers <brian@Awfulhak.org>
Subject:   Re: cvs commit: src/sys/net if_spppsubr.c
Message-ID:  <20010324092156.G1370@uriah.heep.sax.de>
In-Reply-To: <200103240010.f2O0AQ717066@hak.lan.Awfulhak.org>; from brian@Awfulhak.org on Sat, Mar 24, 2001 at 12:10:26AM %2B0000
References:  <joerg@FreeBSD.org> <200103240010.f2O0AQ717066@hak.lan.Awfulhak.org>

next in thread | previous in thread | raw e-mail | index | archive | help
As Brian Somers wrote:

> I don't think I understand what ``missing a previous Down event'' 
> means :-)

My guess after a quick review of the state diagram was that we somehow
must have missed a `Down' which would have brought us back into
Starting state.

> I suspect that the problem here may be related to the unbalanced TLS 
> calls in the state diagram in rfc1661.  If for example a RCR occurs 
> in Stopped state, a TLS isn't required according to the rfc, but this 
> means that it's possible to bring the link (back) up without a TLS.

Here, it was an `Open' event, caused by the successful negotiation of
LCP, with IPCP being requested in LCP.  However, somehow the IPCP
layer hasn't been brought down correctly last time on that interface,
so it was not in Initial state but rather in Stopped state.

My opinion is that i should rather attempt to force all top layers
into Initial state (how?  a Close, followed by a Down?) once LCP goes
down.

> FWIW, ppp(8) (purposefully) violates the rfc here and does a TLS when 
> it gets an RCR in Stopped or Closed state.

Rev 1.65 of if_spppsubr.c does effectively the same, but it does it
when it gets the Open event (which is caused by LCP).  The patch is
(modulo comments):

        case STATE_STOPPED:
+               sppp_cp_change_state(cp, sp, STATE_STARTING);
+               (cp->tls)(sp);
+               break;

> FWIW(2), ppp(8) also ``hacks'' it's way into Stopped when it's 
> ``openmode'' value has been set to anything but the default of active.

That's probably the same idea i was outlining above.

> >   For this, i'd even like to see it MFC'd if possible.
> 
> I prefer the extra TLS idea :-)

Does the above seem reasonable to you? :)

-- 
cheers, J"org               .-.-.   --... ...--   -.. .  DL8DTL

http://www.sax.de/~joerg/                        NIC: JW11-RIPE
Never trust an operating system you don't have sources for. ;-)

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20010324092156.G1370>