Bruce mentioned to me that Paul Traina had noticed that the ppp_tty

interrupt mask hackery wasn't happening when being modloaded via the
if_ppp lkm.  It seems that the lkm system doesn't particularly like having
two sets of load/unload/etc routines. :-]  This really should be fixed
by having a seperate if_ppp and ppp_tty lkm, but that requires that ppp_tty
is loaded after if_ppp, and needs to be able to link with symbols in
if_ppp.  This gets messy, it is a better task for the in-kernel linker.
(if_ppp is generic, ppp_tty is a tty-specific bottom end for if_ppp, it's
 not _too_ hard to have another "provider" (such as a hdlc sync card)
 connected to if_ppp)
This commit is contained in:
Peter Wemm 1997-05-31 10:13:46 +00:00
parent 69defe0533
commit a353ca89cd
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=26314
2 changed files with 13 additions and 5 deletions

View file

@ -69,7 +69,7 @@
* Paul Mackerras (paulus@cs.anu.edu.au).
*/
/* $Id: if_ppp.c,v 1.39 1997/02/22 09:41:03 peter Exp $ */
/* $Id: if_ppp.c,v 1.40 1997/03/24 11:52:29 bde Exp $ */
/* from if_ppp.c,v 1.5 1995/08/16 01:36:38 paulus Exp */
/* from if_sl.c,v 1.11 84/10/04 12:54:47 rick Exp */
@ -126,6 +126,9 @@
struct ppp_softc ppp_softc[NPPP];
/* XXX layering violation */
extern void pppasyncattach __P((void *));
static void pppattach __P((void *));
PSEUDO_SET(pppattach, if_ppp);
@ -206,6 +209,11 @@ pppattach(dummy)
#endif
}
register_netisr(NETISR_PPP, pppintr);
/*
* XXX layering violation - if_ppp can work over any lower level
* transport that cares to attach to it.
*/
pppasyncattach(dummy);
}
/*

View file

@ -70,7 +70,7 @@
* Paul Mackerras (paulus@cs.anu.edu.au).
*/
/* $Id: ppp_tty.c,v 1.15 1997/03/24 11:24:46 bde Exp $ */
/* $Id: ppp_tty.c,v 1.16 1997/05/31 09:49:35 peter Exp $ */
/* from Id: ppp_tty.c,v 1.3 1995/08/16 01:36:40 paulus Exp */
/* from if_sl.c,v 1.11 84/10/04 12:54:47 rick Exp */
@ -113,9 +113,6 @@
#include <net/if_ppp.h>
#include <net/if_pppvar.h>
static void pppasyncattach __P((void *));
PSEUDO_SET(pppasyncattach, ppp_tty);
static int pppopen __P((dev_t dev, struct tty *tp));
static int pppclose __P((struct tty *tp, int flag));
static int pppread __P((struct tty *tp, struct uio *uio, int flag));
@ -134,6 +131,9 @@ static void ppp_timeout __P((void *));
static void pppgetm __P((struct ppp_softc *sc));
static void ppplogchar __P((struct ppp_softc *, int));
/* XXX called from if_ppp.c - layering violation */
void pppasyncattach __P((void *));
/*
* Some useful mbuf macros not in mbuf.h.
*/