Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 19 Mar 2000 13:34:36 +0100
From:      Gary Jennejohn <garyj@muc.de>
To:        freebsd-isdn@freebsd.org
Subject:   Re: isp0 up and running but not working
Message-ID:  <200003191234.NAA00568@peedub.muc.de>

next in thread | raw e-mail | index | archive | help
With this patch (against the latest developers release, but it should be
easy to apply it by hand against older releases) the first few queued
packets no longer get lost. This is obvious from the following tcpdump
info:

13:05:34.050082 ID-001 LCP: Configure-Request, Magic-Number=841061963
13:05:34.572739 ID-001 LCP: Configure-Request, Magic-Number=2792450335, Auth-Prot PAP
13:05:34.572753 ID-001 LCP: Configure-Ack, Magic-Number=2792450335, Auth-Prot PAP
13:05:34.574973 ID-001 LCP: Configure-Ack, Magic-Number=841061963
13:05:34.574983 ID-002 PAP: Authenticate-Request, Peer-Id=xxx, Passwd=yyy
13:05:34.599356 ID-002 PAP: Authenticate-Ack
13:05:34.599369 ID-003 IPCP: IP-Compression-Protocol
13:05:34.602480 ID-001 IPCP: IP-Compression-Protocol
13:05:34.602499 ID-001 IPCP: IP-Compression-Protocol
13:05:34.611607 ID-003 IPCP: IP-Compression-Protocol
13:05:46.192803 peedub.muc.de > router.muc.de: icmp: echo request
13:05:46.192807 peedub.muc.de > router.muc.de: icmp: echo request
13:05:46.192809 peedub.muc.de.1024 > laurin.munich.netsurf.de.pop3: S 40515486:40515486(0) win 16384 <mss 1460,nop,wscale 
0,nop,nop,timestamp 21243 0> (DF)
13:05:46.223567 router.muc.de > peedub.muc.de: icmp: echo reply
13:05:46.235325 router.muc.de > peedub.muc.de: icmp: echo reply

the pings make it out and the peer answers them. Prior to this patch
the first packets got lost.

Note this includes the ETIMEDOUT change from Andreas Haakh.

============================ Patch =============================
*** ./driver/i4b_ispppsubr.c.orig	Sun Mar 19 09:45:34 2000
--- ./driver/i4b_ispppsubr.c	Sun Mar 19 12:25:38 2000
***************
*** 741,747 ****
  			m_freem(m);
  			splx(s);
  			if(ip->ip_p == IPPROTO_TCP)
! 				return(EADDRNOTAVAIL);
  			else
  				return(0);
  		}
--- 741,747 ----
  			m_freem(m);
  			splx(s);
  			if(ip->ip_p == IPPROTO_TCP)
! 				return(ETIMEDOUT);
  			else
  				return(0);
  		}
***************
*** 1033,1039 ****
  	 */
  	IF_DEQUEUE(&sp->pp_cpq, m);
  	if (m == NULL &&
! 	    (sppp_ncp_check(sp) || sp->pp_mode == IFF_CISCO)) {
  		IF_DEQUEUE(&sp->pp_fastq, m);
  		if (m == NULL)
  			IF_DEQUEUE (&sp->pp_if.if_snd, m);
--- 1033,1040 ----
  	 */
  	IF_DEQUEUE(&sp->pp_cpq, m);
  	if (m == NULL &&
! 	    ((sppp_ncp_check(sp) && (sp->ipcp.flags & IPCP_UP))
! 	    || sp->pp_mode == IFF_CISCO)) {
  		IF_DEQUEUE(&sp->pp_fastq, m);
  		if (m == NULL)
  			IF_DEQUEUE (&sp->pp_if.if_snd, m);
***************
*** 3084,3089 ****
--- 3085,3091 ----
  static void
  sppp_ipcp_tlu(struct sppp *sp)
  {
+ 	sp->ipcp.flags |= IPCP_UP;
  	/* we are up - notify isdn daemon */
  	if (sp->pp_con)
  		sp->pp_con(sp);
***************
*** 3106,3111 ****
--- 3108,3114 ----
  {
  	/* we no longer need LCP */
  	sp->lcp.protos &= ~(1 << IDX_IPCP);
+ 	sp->ipcp.flags &= ~IPCP_UP;
  	sppp_lcp_check_and_close(sp);
  }
  
*** ./machine/i4b_isppp.h.orig	Sun Mar 19 12:24:13 2000
--- ./machine/i4b_isppp.h	Sun Mar 19 12:25:14 2000
***************
*** 51,56 ****
--- 51,57 ----
  #define IPCP_MYADDR_DYN   2	/* my address is dynamically assigned */
  #define IPCP_MYADDR_SEEN  4	/* have seen his address already */
  #define IPCP_VJ		  8	/* We can use VJ compression */
+ #define IPCP_UP		  16	/* IPCP layer is really up */
  	int	max_state;	/* Max-Slot-Id */
  	int	compress_cid;	/* Comp-Slot-Id */
  };

--------
Gary Jennejohn / garyj@muc.de garyj@fkr.cpqcorp.net gj@freebsd.org





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




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