SCCS-vsn: sys/kern/init_main.c 7.58
*
* %sccs.include.redist.c%
*
*
* %sccs.include.redist.c%
*
- * @(#)init_main.c 7.57 (Berkeley) %G%
+ * @(#)init_main.c 7.58 (Berkeley) %G%
*/
#include <sys/param.h>
*/
#include <sys/param.h>
#include <sys/conf.h>
#include <sys/buf.h>
#include <sys/clist.h>
#include <sys/conf.h>
#include <sys/buf.h>
#include <sys/clist.h>
#include <sys/protosw.h>
#include <sys/reboot.h>
#include <sys/user.h>
#include <sys/protosw.h>
#include <sys/reboot.h>
#include <sys/user.h>
register int i;
register struct proc *p;
register struct filedesc0 *fdp;
register int i;
register struct proc *p;
register struct filedesc0 *fdp;
+ register struct pdevinit *pdev;
+ extern struct pdevinit pdevinit[];
extern void roundrobin __P((void *));
extern void schedcpu __P((void *));
extern void roundrobin __P((void *));
extern void schedcpu __P((void *));
- /*
- * configure virtual memory system,
- * set vm rlimits
- */
+ /* Configure virtual memory system, set vm rlimits. */
- /*
- * Initialize the file systems.
- */
+ /* Initialize the file systems. */
- /*
- * Start real time and statistics clocks.
- */
+ /* Start real time and statistics clocks. */
- /*
- * Initialize tables, protocols, and set up well-known inodes.
- */
+ /* Initialize tables. */
mbinit();
cinit();
#ifdef SYSVSHM
shminit();
#endif
mbinit();
cinit();
#ifdef SYSVSHM
shminit();
#endif
-#include "sl.h"
-#if NSL > 0
- slattach(); /* XXX */
-#endif
-#include "loop.h"
-#if NLOOP > 0
- loattach(); /* XXX */
-#endif
+
+ /* Attach pseudo-devices. */
+ for (pdev = pdevinit; pdev->pdev_attach != NULL; pdev++)
+ (*pdev->pdev_attach)(pdev->pdev_count);
+
- * Block reception of incoming packets
- * until protocols have been initialized.
+ * Initialize protocols. Block reception of incoming packets
+ * until everything is ready.
*/
s = splimp();
ifinit();
*/
s = splimp();
ifinit();