if_spppsubr.c (129734) | if_spppsubr.c (130416) |
---|---|
1/* 2 * Synchronous PPP/Cisco link level subroutines. 3 * Keepalive protocol implemented in both Cisco and PPP modes. 4 * 5 * Copyright (C) 1994-1996 Cronyx Engineering Ltd. 6 * Author: Serge Vakulenko, <vak@cronyx.ru> 7 * 8 * Heavily revamped to conform to RFC 1661. 9 * Copyright (C) 1997, 2001 Joerg Wunsch. 10 * 11 * This software is distributed with NO WARRANTIES, not even the implied 12 * warranties for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 13 * 14 * Authors grant any other persons or organisations permission to use 15 * or modify this software as long as this message is kept with the software, 16 * all derivative works or modified versions. 17 * 18 * From: Version 2.4, Thu Apr 30 17:17:21 MSD 1997 19 * | 1/* 2 * Synchronous PPP/Cisco link level subroutines. 3 * Keepalive protocol implemented in both Cisco and PPP modes. 4 * 5 * Copyright (C) 1994-1996 Cronyx Engineering Ltd. 6 * Author: Serge Vakulenko, <vak@cronyx.ru> 7 * 8 * Heavily revamped to conform to RFC 1661. 9 * Copyright (C) 1997, 2001 Joerg Wunsch. 10 * 11 * This software is distributed with NO WARRANTIES, not even the implied 12 * warranties for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. 13 * 14 * Authors grant any other persons or organisations permission to use 15 * or modify this software as long as this message is kept with the software, 16 * all derivative works or modified versions. 17 * 18 * From: Version 2.4, Thu Apr 30 17:17:21 MSD 1997 19 * |
20 * $FreeBSD: head/sys/net/if_spppsubr.c 129734 2004-05-25 21:54:07Z rik $ | 20 * $FreeBSD: head/sys/net/if_spppsubr.c 130416 2004-06-13 17:29:10Z mlaier $ |
21 */ 22 23#include <sys/param.h> 24 25#if defined(__FreeBSD__) && __FreeBSD__ >= 3 26#include "opt_inet.h" 27#include "opt_inet6.h" 28#include "opt_ipx.h" --- 747 unchanged lines hidden (view full) --- 776 * to start LCP for it. 777 */ 778 ifp->if_flags |= IFF_RUNNING; 779 splx(s); 780 lcp.Open(sp); 781 s = splimp(); 782 } 783 | 21 */ 22 23#include <sys/param.h> 24 25#if defined(__FreeBSD__) && __FreeBSD__ >= 3 26#include "opt_inet.h" 27#include "opt_inet6.h" 28#include "opt_ipx.h" --- 747 unchanged lines hidden (view full) --- 776 * to start LCP for it. 777 */ 778 ifp->if_flags |= IFF_RUNNING; 779 splx(s); 780 lcp.Open(sp); 781 s = splimp(); 782 } 783 |
784 ifq = &ifp->if_snd; | 784 ifq = (struct ifqueue *)&ifp->if_snd; |
785#ifdef INET 786 if (dst->sa_family == AF_INET) { 787 /* XXX Check mbuf length here? */ 788 struct ip *ip = mtod (m, struct ip*); 789 struct tcphdr *tcp = (struct tcphdr*) ((long*)ip + ip->ip_hl); 790 791 /* 792 * When using dynamic local IP address assignment by using --- 240 unchanged lines hidden (view full) --- 1033/* 1034 * Flush the interface output queue. 1035 */ 1036void 1037sppp_flush(struct ifnet *ifp) 1038{ 1039 struct sppp *sp = (struct sppp*) ifp; 1040 | 785#ifdef INET 786 if (dst->sa_family == AF_INET) { 787 /* XXX Check mbuf length here? */ 788 struct ip *ip = mtod (m, struct ip*); 789 struct tcphdr *tcp = (struct tcphdr*) ((long*)ip + ip->ip_hl); 790 791 /* 792 * When using dynamic local IP address assignment by using --- 240 unchanged lines hidden (view full) --- 1033/* 1034 * Flush the interface output queue. 1035 */ 1036void 1037sppp_flush(struct ifnet *ifp) 1038{ 1039 struct sppp *sp = (struct sppp*) ifp; 1040 |
1041 sppp_qflush (&sp->pp_if.if_snd); | 1041 sppp_qflush ((struct ifqueue *)&sp->pp_if.if_snd); |
1042 sppp_qflush (&sp->pp_fastq); 1043 sppp_qflush (&sp->pp_cpq); 1044} 1045 1046/* 1047 * Check if the output queue is empty. 1048 */ 1049int --- 4277 unchanged lines hidden --- | 1042 sppp_qflush (&sp->pp_fastq); 1043 sppp_qflush (&sp->pp_cpq); 1044} 1045 1046/* 1047 * Check if the output queue is empty. 1048 */ 1049int --- 4277 unchanged lines hidden --- |