├── README.md ├── accent ├── acc_errors.h ├── acc_ipc.h ├── acc_macro.h ├── acc_proc.h ├── acc_seg.h ├── acc_vm.h ├── accent.c ├── accent.h ├── accentint.c ├── accentint.h ├── accenttype.h ├── accint.c ├── c_types.h ├── kern_ipc.h ├── perq_compat.h ├── vax │ ├── acc_impl.h │ ├── acc_part.h │ ├── acc_traps.h │ ├── impl_macros.h │ ├── impl_proc.h │ └── machdep.h ├── vmdata.c └── vmipc.c ├── bin ├── changes ├── ckd ├── ckf ├── diffsys ├── hinstall ├── installback ├── installsys ├── rdiffsys ├── savesys └── updates ├── ca ├── aed_tty.h ├── aed_tty_mcode.h ├── aedtty.c ├── asydefs.h ├── async.h ├── autoconf.c ├── blt.s ├── cache.c ├── cache.h ├── clock.c ├── clock.h ├── conf.c ├── cons.c ├── cpu.h ├── debug.h ├── dkdata.h ├── fp.h ├── fpa.c ├── fpa.h ├── fpfp.h ├── frame.h ├── genassym.c ├── hddisk.h ├── in_cksum.c ├── io.h ├── ioctl.h ├── kern_return.h ├── led.h ├── locore.c ├── locore.h ├── lohatipt.s ├── lointpsw.s ├── lointr.s ├── lokprof.s ├── lopckrt0.s ├── lopckvtl.s ├── loslih.h ├── loswap.s ├── loutil.s ├── machdep.c ├── machparam.h ├── machtypes.h ├── mem.c ├── mmu.h ├── mono.c ├── mono_tcap.h ├── monocons.h ├── packet.h ├── param.h ├── pcb.c ├── pcb.h ├── pcb.m ├── pmap.c ├── pmap.h ├── proc.h ├── pte.h ├── reg.h ├── romp_init.c ├── rosetta.h ├── rpb.h ├── scr.h ├── screen_conf.c ├── sed.c ├── softint.h ├── swapconf.c ├── swapgeneric.c ├── symbols.raw ├── symbols.sort ├── sys_machdep.c ├── syscall.h ├── trap.c ├── ufs_machdep.c ├── undefine.c ├── vm_machdep.c ├── vm_param.h ├── vm_types.h ├── vmaccess.c ├── vmparam.h └── xFPexception.c ├── caio ├── adunload.c ├── adunload.sh ├── adunload.sh.NCS ├── aed.c ├── aeddefs.h ├── apa16.c ├── apa8.c ├── apdefs.h ├── apio.h ├── apvar.h ├── asy.c ├── asyregs.h ├── dma.c ├── dmareg.h ├── fd.c ├── fdio.h ├── fdreg.h ├── fdvar.h ├── hd.c ├── hdconfig.h ├── ioccvar.h ├── lp.c ├── mouse.c ├── mouseio.h ├── mousereg.h ├── psp.c ├── pspreg.h ├── st.c ├── streg.h ├── tty_apldisc.c ├── tty_approto.c ├── tty_mouse.c └── ud.c ├── cassette ├── Makefile ├── anyboo.cmd ├── cassette.out ├── cassette.out1 ├── defboo.cmd ├── defboo.hk ├── defboo.ra ├── defboo.rb ├── defboo.rl ├── defboo.up ├── hkmboo.cmd ├── hksboo.cmd ├── ramboo.cmd ├── rasboo.cmd ├── rbmboo.cmd ├── rbsboo.cmd ├── restar.cmd ├── rlsboo.cmd ├── update.out ├── upmboo.cmd └── upsboo.cmd ├── conf ├── ANSEL ├── FLOPPY ├── FOO ├── GENERIC ├── LINT ├── MACHRT ├── MASTER ├── MICROVAXII ├── Makefile ├── Makefile.ca ├── Makefile.vax ├── NOVM ├── SINGLE_CPU ├── TT ├── UCB730 ├── UCB750 ├── UCB750IMP ├── UCB780 ├── UCB8600 ├── UCB8600.PROF ├── UCBGENERIC ├── XMACH ├── defines ├── devices.vax ├── files ├── files.ca ├── files.vax ├── make.ws ├── newvers.sh ├── param.c ├── sed │ ├── GENERIC.sed │ ├── GENERIC.sed.BAK │ ├── MACH.sed │ ├── MACHRT.sed │ └── SINGLE_CPU.sed └── touch.c ├── consolerl ├── Makefile ├── anyboo.com ├── defboo.hk ├── defboo.hp ├── defboo.ra ├── defboo.up ├── hkmboo.com ├── hksboo.com ├── hpmboo.com ├── hpsboo.com ├── ramboo.com ├── rasboo.com ├── upmboo.com └── upsboo.com ├── defunct ├── accent │ ├── ipc_print.c │ └── kern_print.c ├── h │ └── sem.h └── mp │ ├── mp_shmem.c │ ├── sem_error.h │ ├── sem_proc.c │ ├── sem_sem.c │ ├── sem_sem.h │ ├── sem_user.c │ └── shmem.h ├── dist ├── MAKEDEV ├── MAKEHOSTS ├── README ├── buildmini ├── disktab ├── fstab.hp ├── fstab.hp400m ├── fstab.ra60 ├── fstab.ra80 ├── fstab.ra81 ├── fstab.rb80 ├── fstab.rk07 ├── fstab.rm03 ├── fstab.rm05 ├── fstab.rm80 ├── fstab.rp06 ├── fstab.rp07 ├── fstab.up ├── fstab.up160m ├── fstab.up300m ├── get ├── group ├── inetd.conf ├── maketape ├── motd ├── passwd ├── printcap ├── rc ├── rc.local ├── services ├── shells ├── syslog.conf └── ttys ├── emul ├── vaxarith.s ├── vaxashp.s ├── vaxbegin.s ├── vaxconvrt.s ├── vaxcvtlp.s ├── vaxcvtpl.s ├── vaxdeciml.s ├── vaxeditpc.s ├── vaxemul.h ├── vaxemulat.s ├── vaxend.s ├── vaxexception.s ├── vaxfloat.awk ├── vaxfloat.s ├── vaxfloat.sa ├── vaxhandlr.s ├── vaxregdef.h └── vaxstring.s ├── floppy ├── Makefile ├── anyboo.cmd ├── defboo.MS780C-interleaved ├── defboo.hk ├── defboo.hp ├── defboo.ra ├── defboo.up ├── hkmboo.cmd ├── hksboo.cmd ├── hpmboo.cmd ├── hpsboo.cmd ├── ramboo.cmd ├── rasboo.cmd ├── restar.cmd ├── upmboo.cmd ├── upsboo.cmd └── utboot.cmd ├── h ├── acct.h ├── bkmac.h ├── buf.h ├── callout.h ├── clist.h ├── cmap.h ├── cmupty.h ├── conf.h ├── dir.h ├── dk.h ├── dkbad.h ├── dmap.h ├── domain.h ├── enet.h ├── errno.6.2 ├── errno.h ├── exec.h ├── fe.h ├── features.h ├── file.h ├── filsys.h ├── fpsconf.h ├── fpsreg.h ├── fs.h ├── gprof.h ├── ild.h ├── inode.h ├── ioctl.h ├── ipc.h ├── ipcmacros.h ├── jioctl.h ├── kern_return.h ├── kernel.h ├── mach_param.h ├── machine.h ├── map.h ├── mbuf.h ├── mman.h ├── mount.h ├── msgbuf.h ├── mtio.h ├── mx.h ├── namei.h ├── param.h ├── port.h ├── proc.h ├── protosw.h ├── ptrace.h ├── queue.h ├── quota.h ├── reboot.h ├── resource.h ├── rfs.h ├── sched.h ├── seg.h ├── shared_memory.h ├── signal.h ├── socket.h ├── socketvar.h ├── stat.h ├── syslog.h ├── systm.h ├── table.h ├── tablet.h ├── tags ├── task.h ├── text.h ├── thread.h ├── time.h ├── timeb.h ├── times.h ├── trace.h ├── tty.h ├── ttychars.h ├── ttydev.h ├── ttyloc.h ├── types.h ├── uio.h ├── un.h ├── unpcb.h ├── uproc.h ├── user.h ├── utime.h ├── vadvise.h ├── vcmd.h ├── vlimit.h ├── vm.h ├── vmmac.h ├── vmmeter.h ├── vmparam.h ├── vmsystm.h ├── vsio.h ├── vtimes.h ├── wait.h └── zalloc.h ├── kern ├── Mach.h ├── MachServer.c ├── MachUser.c ├── Makefile ├── Pager.h ├── PagerServer.c ├── PagerUser.c ├── iprintf.c ├── kalloc.c ├── mach.defs ├── mach.h ├── mach_factor.c ├── mach_if.c ├── mach_if.h ├── mach_server.c ├── mach_server.sed ├── mach_user.c ├── mach_user.sed ├── mpq_alloc.c ├── pager.defs ├── pager.h ├── pager_server.c ├── pager_server.sed ├── pager_user.c ├── pager_user.sed ├── ports.c ├── request.defs ├── sched_prim.c ├── task.c ├── thread.c └── zalloc.c ├── lib ├── check.awk └── ckd.awk ├── machine ├── mdec ├── Makefile ├── hkboot.s ├── hpboot.s ├── htboot.s ├── httoggle.s ├── installboot.c ├── mtboot.s ├── mttoggle.s ├── raboot.s ├── rlboot.s ├── tmboot.s ├── tmtoggle.s ├── tsboot.s ├── tstoggle.s ├── tuboot.s ├── upboot.s ├── utboot.s └── uttoggle.s ├── mp ├── imc.h ├── imc_subr.c ├── kern_smalloc.c ├── kern_smalloc.h ├── mach_stat.h ├── makefile ├── mp_galloc.c ├── mp_galloc.h ├── mp_param.h ├── mp_proc.h ├── mp_queue.c ├── mp_queuedb.c ├── queuescan.c ├── remote_prim.c ├── remote_prim.h ├── remote_subr.c ├── remote_sw.c ├── remote_sw.h ├── slave.c ├── syscall_nm.h ├── syscall_subr.c ├── syscall_sw.c └── syscall_sw.h ├── net ├── af.c ├── af.h ├── if.c ├── if.h ├── if_arp.h ├── if_loop.c ├── if_sl.c ├── netisr.h ├── raw_cb.c ├── raw_cb.h ├── raw_usrreq.c ├── route.c ├── route.h └── tags ├── netimp ├── if_imp.c ├── if_imp.h ├── if_imphost.c ├── if_imphost.h ├── raw_imp.c └── tags ├── netinet ├── bbn.c ├── bbn.h ├── icmp_var.h ├── if_ether.c ├── if_ether.h ├── if_loop.c ├── in.c ├── in.h ├── in_pcb.c ├── in_pcb.h ├── in_proto.c ├── in_systm.h ├── in_var.h ├── ip.h ├── ip_icmp.c ├── ip_icmp.h ├── ip_input.c ├── ip_output.c ├── ip_var.h ├── raw_ip.c ├── tags ├── tcp.h ├── tcp_debug.c ├── tcp_debug.h ├── tcp_fsm.h ├── tcp_input.c ├── tcp_output.c ├── tcp_seq.h ├── tcp_subr.c ├── tcp_timer.c ├── tcp_timer.h ├── tcp_usrreq.c ├── tcp_var.h ├── tcpip.h ├── udp.h ├── udp_usrreq.c └── udp_var.h ├── netns ├── idp.h ├── idp_usrreq.c ├── idp_var.h ├── ns.c ├── ns.h ├── ns_error.c ├── ns_error.h ├── ns_if.h ├── ns_input.c ├── ns_ip.c ├── ns_output.c ├── ns_pcb.c ├── ns_pcb.h ├── ns_proto.c ├── r ├── sp.h ├── spidp.h ├── spp_debug.c ├── spp_debug.h ├── spp_usrreq.c ├── spp_var.h └── tags ├── oaccent ├── acc_debug.h ├── acc_errors.h ├── acc_errorstrs.h ├── acc_ipc.h ├── acc_macro.h ├── acc_proc.h ├── acc_seg.h ├── acc_vm.h ├── accent.c ├── accent.h ├── accentint.c ├── accentint.h ├── accenttype.h ├── accint.c ├── perq_compat.h └── systype.h ├── sensor ├── fork_sensor.h ├── init_sens.c ├── kern_sensors.h ├── mondefs.h ├── monerrcds.h ├── monops.h ├── monsennames.h ├── montypes.h ├── sens_syscalls.c ├── sys_sensors.h ├── syslocal.h └── ufs_sensors.h ├── src ├── config │ ├── Makefile │ ├── config.h │ ├── config.l │ ├── config.y │ ├── lex.yy.c │ ├── main.c │ ├── mkheaders.c │ ├── mkioconf.c │ ├── mkmakefile.c │ ├── mkswapconf.c │ ├── mkubglue.c │ ├── newvers.sh │ ├── y.tab.c │ └── y.tab.h └── kdb │ ├── Makefile │ ├── access.c │ ├── asnumber.h │ ├── assizetab.c │ ├── assizetab.c.ol │ ├── chksym │ ├── command.c │ ├── defs.h │ ├── expr.c │ ├── format.c │ ├── fp.h │ ├── head.h │ ├── input.c │ ├── instrs │ ├── instrs.adb │ ├── instrs.h │ ├── kdb.c │ ├── kdbdefine.h │ ├── mac.h │ ├── machine.h │ ├── machine │ ├── foo.901 │ ├── psl.h │ └── pte.h │ ├── main.c │ ├── message.c │ ├── mode.h │ ├── opset.c │ ├── optab.c │ ├── output.c │ ├── pcs.c │ ├── pcs.h │ ├── print.c │ ├── r1 │ ├── runpcs.c │ ├── setup.c │ ├── stack.c │ ├── sym.c │ └── symchk ├── stand.4.2 ├── Makefile ├── autoconf.c ├── boot.c ├── bootxx.c ├── cat.c ├── conf.c ├── confhpup.c ├── confxx.c ├── copy.c ├── drtest.c ├── format.c ├── hp.c ├── hp.old.c ├── hpmaptype.c ├── ht.c ├── idc.c ├── imptst.c ├── ls.c ├── machdep.c ├── mba.c ├── mt.c ├── prf.c ├── qvcons.c ├── rk.c ├── rl.c ├── saio.h ├── savax.h ├── srt0.c ├── sys.c ├── tm.c ├── ts.c ├── uba.c ├── uda.c ├── up.c ├── up.old.c ├── up.old.s ├── up.s ├── upmaptype.c └── ut.c ├── stand.old ├── Makefile ├── autoconf.c ├── boot.c ├── bootxx.c ├── cat.c ├── conf.c ├── confhpup.c ├── confxx.c ├── copy.c ├── drtest.c ├── format.c ├── hp.c ├── hp.old.c ├── hpmaptype.c ├── ht.c ├── idc.c ├── imptst.c ├── ls.c ├── machdep.c ├── mba.c ├── mt.c ├── prf.c ├── qvcons.c ├── rk.c ├── rl.c ├── saio.h ├── savax.h ├── save │ ├── boothk.c │ ├── confrk.c │ └── rk.c ├── srt0.c ├── sys.c ├── t.c ├── tm.c ├── ts.c ├── uba.c ├── uda.c ├── up.c ├── up.old.c ├── upmaptype.c └── ut.c ├── stand ├── Makefile ├── autoconf.c ├── boot.c ├── bootavie.c ├── boothk.c ├── boothp.c ├── bootra.c ├── bootrl.c ├── bootup.c ├── bootxx.c ├── cat.c ├── conf.c ├── confhp.c ├── confhpup.c ├── confra.c ├── confrk.c ├── confrl.c ├── confup.c ├── confxx.c ├── copy.c ├── cs_vaxm.h ├── drtest.c ├── format.c ├── hp.c ├── hp.old.c ├── hpmaptype.c ├── ht.c ├── idc.c ├── imptst.c ├── ls.c ├── machdep.c ├── mba.c ├── mt.c ├── prf.c ├── qvcons.c ├── rk.c ├── rl.c ├── saio.h ├── savax.h ├── srt0.c ├── sys.c ├── tm.c ├── tmscp.c ├── ts.c ├── uba.c ├── uda.c ├── uda.c.4.3 ├── up.c ├── up.old.c ├── upmaptype.c └── ut.c ├── sync ├── lock.c ├── lock.h ├── mp_queue.h └── sync_prim.c ├── sys ├── Makefile ├── cmu_syscalls.c ├── foo.csh ├── init_main.c ├── init_sysent.c ├── ipc_1.c ├── ipc_2.c ├── ipc_3.c ├── kern_acct.c ├── kern_clock.c ├── kern_descrip.c ├── kern_exec.c ├── kern_exit.c ├── kern_fork.c ├── kern_mman.c ├── kern_proc.c ├── kern_prot.c ├── kern_resource.c ├── kern_sig.c ├── kern_subr.c ├── kern_synch.c ├── kern_time.c ├── kern_xxx.c ├── mpx_dev.c ├── mpx_sys.c ├── quota_kern.c ├── quota_subr.c ├── quota_sys.c ├── quota_ufs.c ├── rfs_descrip.c ├── rfs_init.c ├── rfs_kern.c ├── rfs_socket.c ├── rfs_subr.c ├── rfs_syscalls.c ├── subr_log.c ├── subr_mcount.c ├── subr_prf.c ├── subr_rmap.c ├── subr_xxx.c ├── sys_generic.c ├── sys_ild.c ├── sys_inode.c ├── sys_process.c ├── sys_socket.c ├── syscalls.c ├── tags ├── tty.c ├── tty_bk.c ├── tty_cmupty.c ├── tty_conf.c ├── tty_fe.c ├── tty_pty.c ├── tty_subr.c ├── tty_tb.c ├── tty_tty.c ├── ufs_alloc.c ├── ufs_bio.c ├── ufs_bmap.c ├── ufs_dsort.c ├── ufs_fio.c ├── ufs_inode.c ├── ufs_mount.c ├── ufs_namei.c ├── ufs_subr.c ├── ufs_syscalls.c ├── ufs_tables.c ├── ufs_xxx.c ├── uipc_domain.c ├── uipc_mbuf.c ├── uipc_proto.c ├── uipc_socket.c ├── uipc_socket2.c ├── uipc_syscalls.c ├── uipc_usrreq.c ├── vm_drum.c ├── vm_mem.c ├── vm_mon.c ├── vm_page.c ├── vm_proc.c ├── vm_pt.c ├── vm_sched.c ├── vm_subr.c ├── vm_sw.c ├── vm_swap.c ├── vm_swp.c └── vm_text.c ├── vax ├── Locore.c ├── astags ├── autoconf.c ├── clock.c ├── clock.h ├── conf.c ├── cons.c ├── cons.h ├── cpu.h ├── cpudata.c ├── crl.c ├── crl.h ├── crt0.ex ├── dkbad.c ├── dkio.h ├── emulate.s ├── flp.c ├── flp.h ├── frame.h ├── genassym.c ├── in_cksum.c ├── inline │ ├── Makefile │ ├── inline.h │ ├── langpats.c │ ├── libcpats.c │ ├── machdep.c │ ├── machpats.c │ └── main.c ├── ioa.h ├── ka630.c ├── ka630.h ├── locore.s ├── machdep.c ├── machparam.h ├── mem.c ├── mem.h ├── mscp.h ├── mtpr.h ├── nexus.h ├── ns_cksum.c ├── pcb.h ├── pcb.m ├── psl.h ├── pte.h ├── reg.h ├── rpb.h ├── rpb.s ├── rsp.h ├── scb.h ├── scb.s ├── swapgeneric.c ├── symbols.raw ├── symbols.sort ├── sys_machdep.c ├── tags ├── tmscp.h ├── trap.c ├── trap.h ├── tu.c ├── udiv.s ├── ufs_machdep.c ├── urem.s ├── vm_machdep.c └── vmparam.h ├── vaxif ├── enet.c ├── enetdefs.h ├── if_acc.c ├── if_accreg.h ├── if_css.c ├── if_cssreg.h ├── if_ddn.c ├── if_ddnreg.h ├── if_ddnvar.h ├── if_de.c ├── if_dereg.h ├── if_dmc.c ├── if_dmc.h ├── if_ec.c ├── if_ecreg.h ├── if_en.c ├── if_en.h ├── if_enreg.h ├── if_ex.c ├── if_exreg.h ├── if_hdh.c ├── if_hdhreg.h ├── if_hy.c ├── if_hy.h ├── if_hyreg.h ├── if_il.c ├── if_il.h ├── if_ilreg.h ├── if_ix.h ├── if_ml.c ├── if_ml.h ├── if_mlreg.h ├── if_pcl.c ├── if_pclreg.h ├── if_qe.c ├── if_qereg.h ├── if_ub.c ├── if_ub.h ├── if_uba.c ├── if_uba.h ├── if_ubreg.h ├── if_vv.c ├── if_vv.h ├── raw_hy.c └── tags ├── vaxmba ├── hp.c ├── hpreg.h ├── ht.c ├── htreg.h ├── mba.c ├── mbareg.h ├── mbavar.h ├── mt.c ├── mtreg.h └── tags ├── vaxuba ├── ad.c ├── adreg.h ├── ct.c ├── dh.c ├── dhreg.h ├── dhu.c ├── dhureg.h ├── dmf.c ├── dmfreg.h ├── dmreg.h ├── dmz.c ├── dmzreg.h ├── dn.c ├── dz.c ├── dzreg.h ├── idc.c ├── idcreg.h ├── ik.c ├── ikreg.h ├── kgclock.c ├── lp.c ├── lpa.c ├── npreg.h ├── pdma.h ├── ps.c ├── psreg.h ├── rk.c ├── rkreg.h ├── rl.c ├── rlreg.h ├── rx.c ├── rxreg.h ├── tags ├── tm.c ├── tmreg.h ├── tmscp.c ├── tmscpreg.h ├── ts.c ├── tsreg.h ├── uba.c ├── ubareg.h ├── ubavar.h ├── uda.c ├── udareg.h ├── up.c ├── upreg.h ├── ut.c ├── utreg.h ├── uu.c ├── uureg.h ├── va.c ├── vp.c ├── vpreg.h ├── vs.c └── vsreg.h └── vm ├── inode_pager.c ├── inode_pager.h ├── pmap.h ├── vm_fault.c ├── vm_inherit.h ├── vm_init.c ├── vm_kern.c ├── vm_kern.h ├── vm_map.c ├── vm_map.c.old ├── vm_map.h ├── vm_object.c ├── vm_object.h ├── vm_page.h ├── vm_pageout.c ├── vm_pageout.h ├── vm_pager.c ├── vm_pager.h ├── vm_param.h ├── vm_prot.h ├── vm_resident.c ├── vm_statistics.h ├── vm_unix.c ├── vm_user.c └── vm_user.h /README.md: -------------------------------------------------------------------------------- 1 | # Mach86 2 | 3 | This is the kernel source I found on the CSRG DVD update. 4 | 5 | This kernel is apparently based on the 4.3BSD kernel. 6 | 7 | 8 | -------------------------------------------------------------------------------- /accent/vax/acc_traps.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * acc_traps.h -- Vax version 30 | * 31 | * Types used by kernel traps exported by Accent. 32 | * 33 | * Michael B. Jones 34 | * 35 | * Copyright (C) 1981, 1982, 1983, 1984, 1985 36 | * Richard F. Rashid, Michael B. Jones, and Carnegie-Mellon University 37 | * 38 | * History: 39 | * 40 | * 20-Jul-84 Michael B. Jones 41 | * Created Vax version. Currently, the Vax uses no trap types. 42 | */ 43 | 44 | #ifndef _Acc_Traps 45 | #define _Acc_Traps 46 | 47 | #if ! VAX 48 | Wrong version of acc_traps.h! 49 | #endif 50 | 51 | /* Nothing at all... */ 52 | 53 | #endif _Acc_Traps 54 | -------------------------------------------------------------------------------- /bin/changes: -------------------------------------------------------------------------------- 1 | #! /bin/csh -f 2 | 3 | set prog=$0 4 | set prog=$prog:t 5 | set dirs=(.) 6 | 7 | while ($#argv > 0) 8 | if ("$argv[1]" !~ -*) break 9 | switch ("$argv[1]") 10 | case "-r": 11 | case "-retry": 12 | set retry 13 | breaksw 14 | default: 15 | echo "${prog}: unknown switch $argv[1]" 16 | exit 17 | endsw 18 | shift 19 | end 20 | 21 | if ($#argv != 1) then 22 | echo "Usage: $prog " 23 | exit 1 24 | endif 25 | 26 | set sys=$1 27 | set update=.${sys}update 28 | 29 | cd 30 | if (! $?retry) then 31 | tar cvf $sys.tar .empty `find $dirs -newer $update -type f ! -name "*.[ao]" ! -name "*.bak" ! -name "LOG*" ! -name "*.tar" -print` 32 | endif 33 | 34 | ls -l $sys.tar 35 | ftp $sys -log newsys -type l -stor $sys.tar $sys.tar <~/.${sys}_passwd 36 | 37 | echo -n "OK to update $update? [ no ] " 38 | set ans="$<" 39 | if ("$ans" =~ [Yy] || "$ans" =~ [Yy][Ee][Ss]) then 40 | touch $update 41 | ls -l $update 42 | endif 43 | 44 | rm -i $sys.tar 45 | -------------------------------------------------------------------------------- /bin/ckd: -------------------------------------------------------------------------------- 1 | #!/bin/csh -f 2 | 3 | cd 4 | set ORIG=(/4.2bsd/sys /4.2bsd/sysU /ultrix/sys) 5 | set LASTCKD=.lastckd 6 | set EXRC=ckd.exrc 7 | set DIRS=() files=() 8 | set CKDERR="ckd.err" 9 | set CKDOUT="ckd.out" 10 | set TMP="vi$$.tmp" 11 | 12 | if ($#argv == 0) then 13 | set DIRS=(conf emul h net netimp netinet netpup sys vax vaxif vaxmba vaxuba) 14 | endif 15 | 16 | foreach file ($argv) 17 | if (-d $file) then 18 | set DIRS=($DIRS $file) 19 | else 20 | set files=($files $file) 21 | endif 22 | end 23 | 24 | if ($#DIRS > 0) then 25 | set files=($files `find $DIRS -name "*.[csh]" -newer $LASTCKD -print`) 26 | endif 27 | 28 | foreach file ($files) 29 | unset orig 30 | foreach odir ($ORIG) 31 | set ofile=$file 32 | if ($odir:r =~ *U && $file:r =~ *U) then 33 | set ofile=`expr "$file:r" : '^\(.*\)U$'`.$file:e 34 | endif 35 | if (-f $odir/$ofile) then 36 | set orig=$odir/$ofile 37 | break 38 | endif 39 | end 40 | if (! $?orig) then 41 | echo "[ ${file}: no original for comparison ]" 42 | continue 43 | endif 44 | echo "[ ${file}: against $orig ]" 45 | while (1) 46 | rm -f ${CKDERR} ${CKDOUT} 47 | (echo "-output=${CKDOUT} -error=${CKDERR}"; diff $orig $file) | awk -f lib/ckd.awk 48 | if (! -f ${CKDERR}) break; 49 | tail ${CKDOUT} 50 | set extra="" errors=(`cat $CKDERR`) 51 | stty echo 52 | sleep 3 53 | if ($errors[1] <= 2) set extra=$orig 54 | onintr - 55 | echo $errors[2] >$TMP 56 | if (-f $EXRC) echo "source $EXRC" >>$TMP 57 | $EDITOR +"source $TMP" $file $extra 58 | rm -f $TMP 59 | onintr 60 | end 61 | rm -f ${CKDOUT} 62 | end 63 | 64 | if ($#DIRS > 0) then 65 | echo -n "Update $LASTCKD? [ yes ] " 66 | set ans="$<" 67 | if ("$ans" == "" || "$ans" =~ [Yy] || "$ans" =~ [Yy][Ee][Ss]) then 68 | mv $LASTCKD $LASTCKD.old 69 | touch $LASTCKD 70 | ls -l ${LASTCKD}* 71 | endif 72 | endif 73 | -------------------------------------------------------------------------------- /bin/ckf: -------------------------------------------------------------------------------- 1 | #! /bin/csh -f 2 | foreach f ($*) 3 | echo $f 4 | awk -f lib/check.awk $f 5 | end 6 | -------------------------------------------------------------------------------- /bin/diffsys: -------------------------------------------------------------------------------- 1 | # 2 | # HISTORY 3 | # 11-Sep-85 Avadis Tevanian (avie) at Carnegie-Mellon University 4 | # Added extra functionality for detecting new or deleted files. 5 | # Does not detect new directories, so when new directories are 6 | # created, dummy directories should be created in /usr/sys before 7 | # running diffsys. 8 | # 9 | rm -f diffs 10 | if ($#argv == 0) then 11 | set target = /usr/sys 12 | else 13 | set target = $1 14 | endif 15 | 16 | foreach dir ( accent bbnnet bin ca caif caio conf emul h kern lib mp \ 17 | net netimp netinet netns oaccent sensor src stand stand.4.2 standca \ 18 | sync sys vax vaxif vaxmba vaxuba vm) 19 | diff -r $dir $target/$dir >>& diffs 20 | end 21 | sed '/^Common/d\ 22 | /^Binary/d' diffs >Diffs 23 | grep "^diff -r" Diffs | sed "s?^.*$target/*??" > ChangedFiles 24 | grep "^Only" Diffs > t1 25 | grep "$target" t1 > t2 26 | sed -e "s?^.*$target/*??" -e 's?: ?/?' t2 > DeletedFiles 27 | grep -v "$target" t1 > t2 28 | sed -e 's?Only in ??' -e 's?: ?/?' t2 > NewFiles 29 | rm diffs t1 t2 30 | -------------------------------------------------------------------------------- /bin/installback: -------------------------------------------------------------------------------- 1 | #! /bin/csh -f 2 | 3 | set CSYS=`sysname -official` 4 | set MSYS=`cat /etc/masterhost` 5 | unset master 6 | if ($CSYS == $MSYS) set master 7 | 8 | # Generate list of files to install 9 | set files=`cd .back; find . -type f -print` 10 | foreach file ($files) 11 | echo "" 12 | echo "[ $file ]" 13 | unset ignore 14 | set rmflags="-f" 15 | 16 | # Loop until file matches .back version or no installation 17 | while (! $?ignore) 18 | 19 | # Loop until no more history messages added 20 | while (1) 21 | # File currently exists 22 | if (-f $file) then 23 | echo "[ comparing $file and .back/$file ]" 24 | diff $file .back/$file | more 25 | if ($status == 0) then 26 | echo "[ $file and .back/$file are (now) identical ]" 27 | set ignore 28 | break 29 | endif 30 | else 31 | echo "[ $file does not currently exist ]" 32 | endif 33 | echo -n "Add history message for $file? [ no ] " 34 | set ans="$<" 35 | if ("$ans" =~ [yY] || "$ans" =~ [yY][eE][sS]) then 36 | chmod +w .back/$file 37 | whist .back/$file 38 | else 39 | break 40 | endif 41 | end 42 | if (! $?ignore) then 43 | echo -n "Install $file? [ yes ] " 44 | set ans="$<" 45 | if ("$ans" == "" || "$ans" =~ [yY] || "$ans" =~ [yY][eE][sS]) then 46 | set ok 47 | if ($?master && -f $file) then 48 | (cd $file:h; ci -k -m" " -t/dev/null $file:t) 49 | if ($status != 0) then 50 | unset ok 51 | else 52 | chmod +w $file 53 | endif 54 | else 55 | if (-f $file) chmod +w $file 56 | endif 57 | if ($?ok) then 58 | cp .back/$file $file 59 | chmod -w $file 60 | else 61 | echo "[ problem checking in previous version of $file ]" 62 | set rmflags="-i" 63 | endif 64 | else 65 | set ignore 66 | set rmflags="-i" 67 | endif 68 | endif 69 | end 70 | rm $rmflags .back/$file 71 | end 72 | -------------------------------------------------------------------------------- /bin/installsys: -------------------------------------------------------------------------------- 1 | # 2 | @ ver = `cat /usr/sys/Melange/version` 3 | echo -n changing from version $ver to 4 | 5 | @ ver = $ver + 1 6 | echo " " version $ver 7 | 8 | mv ChangedFiles NewFiles DeletedFiles Diffs /usr/sys 9 | 10 | rm -f /usr/sys/Tar 11 | tar crf /usr/sys/Tar `cat /usr/sys/ChangedFiles` `cat /usr/sys/NewFiles` 12 | cd /usr/sys 13 | tar xvf /usr/sys/Tar 14 | rm -rf `cat /usr/sys/DeletedFiles` 15 | 16 | echo Don\'t forget to update the CHANGELOG 17 | 18 | unset base 19 | unset ver 20 | -------------------------------------------------------------------------------- /bin/rdiffsys: -------------------------------------------------------------------------------- 1 | # 2 | # HISTORY 3 | # 11-Sep-85 Avadis Tevanian (avie) at Carnegie-Mellon University 4 | # Added extra functionality for detecting new or deleted files. 5 | # Does not detect new directories, so when new directories are 6 | # created, dummy directories should be created in /usr/sys before 7 | # running diffsys. 8 | # 9 | rm -f diffs 10 | foreach dir (accent bin conf emul h lib mp net netimp netinet netpup stand \ 11 | stand.avie src sync sys vax vaxif vaxmba vaxuba) 12 | diff -r $dir /usr/sys/$dir >>& diffs 13 | end 14 | sed '/^Common/d\ 15 | /^Binary/d' diffs >Diffs 16 | grep "^diff -r" Diffs | sed 's/^.*\/..\/wb1\/usr\/sys\///' > ChangedFiles 17 | grep "^Only" Diffs > t1 18 | grep "/usr/sys" t1 > t2 19 | sed -e 's?^.*/usr/sys/??' -e 's?: ?/?' t2 > DeletedFiles 20 | grep -v "/usr/sys" t1 > t2 21 | sed -e 's?Only in ??' -e 's?: ?/?' t2 > NewFiles 22 | rm diffs t1 t2 23 | -------------------------------------------------------------------------------- /bin/savesys: -------------------------------------------------------------------------------- 1 | # 2 | # HISTORY 3 | # 11-Sep-85 Avadis Tevanian (avie) at Carnegie-Mellon University 4 | # Updated to handle new and/or deleted files. 5 | # 6 | set ver = `cat /usr/sys/Melange/version` 7 | 8 | echo Saving files in version $ver that are to be changed. 9 | 10 | set dest = /usr/Melange-Archives/Melange-$ver 11 | mkdir $dest 12 | cp /vmunix $dest 13 | cp /usr/sys/{CHANGELOG,ChangedFiles,NewFiles,DeletedFiles,Diffs,Tar} $dest 14 | 15 | set base = $cwd 16 | 17 | cd /usr/sys 18 | 19 | # 20 | echo save files which are changing 21 | # 22 | tar crf - `cat $base/ChangedFiles` | \ 23 | (cd $dest; tar xvf -) 24 | # 25 | echo save files which were new in this version 26 | # 27 | tar crf - `cat /usr/sys/NewFiles` | \ 28 | (cd $dest; tar xvf -) 29 | 30 | echo Don\'t forget to update the CHANGELOG 31 | 32 | unset $dest 33 | unset base 34 | unset ver 35 | -------------------------------------------------------------------------------- /bin/updates: -------------------------------------------------------------------------------- 1 | #! /bin/csh -f 2 | 3 | cd 4 | set prog="$0" 5 | set prog="$prog:t" 6 | 7 | set BASEDATE=.$USER.date 8 | set DATE=$BASEDATE 9 | 10 | set print names 11 | 12 | while ($#argv > 0) 13 | if ("$argv[1]" =~ -*) then 14 | switch ("$argv[1]") 15 | case "-o": 16 | case "-old": 17 | set DATE=$BASEDATE.old 18 | breaksw 19 | case "-n": 20 | case "-noprint": 21 | unset print 22 | breaksw 23 | case "-q": 24 | case "-quiet": 25 | unset names 26 | breaksw 27 | default: 28 | echo "${prog}: unknown switch $argv[1]" 29 | exit 1 30 | endsw 31 | shift 32 | else 33 | break 34 | endif 35 | end 36 | 37 | set dirs=(conf emul h net netimp netinet netpup sys vax vaxif vaxmba vaxuba) 38 | set f=`find $dirs -newer $DATE \( -name "*.[cshm]" -o -name "*.sed" \) -type f -print | sed -e "/\/RCS\//d"` 39 | 40 | if ($#f <= 0) then 41 | exit 0 42 | endif 43 | 44 | if ($?names) then 45 | ls $f | pr -t -l1 -3 46 | endif 47 | 48 | if ($?print) then 49 | wh -q czp >& /dev/null 50 | if ($status != 0) then 51 | set f=`ls $f | sort | split -5 - .upf` 52 | foreach f (.upf*) 53 | cat $f 54 | cz `cat $f` 55 | end 56 | rm -f .upf?? 57 | else 58 | czp -label "SYS changes" `ls $f` 59 | endif 60 | if ("$DATE" == "$BASEDATE") then 61 | mv $DATE $DATE.old 62 | touch $DATE 63 | endif 64 | endif 65 | 66 | ls -l $BASEDATE* 67 | -------------------------------------------------------------------------------- /ca/cache.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * File: ca/cache.h 30 | * Author: William J. Bolosky 31 | * 32 | * Copyright (C) 1986, William J. Bolosky 33 | * 34 | * HISTORY 35 | * 23-Apr-86 Bill Bolosky (bolosky) at Carnegie-Mellon University 36 | * Created. 37 | * 38 | */ 39 | 40 | /* WARNING: Assembly code in lopckrt0 depends on this being an 8 byte 41 | * record. If this changes, you should fix ca/lopckrt0.s 42 | */ 43 | struct {long addrtag; /* (12-bit)seg no and vpage */ 44 | int phys_page; 45 | } cache_entry; 46 | 47 | #define CACHE_FREE 0x10000000 /* Free bit in phys_page field */ 48 | -------------------------------------------------------------------------------- /ca/kern_return.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | # 29 | 30 | /* 31 | * File: h/kern_error.h 32 | * Author: Avadis Tevanian, Jr., Michael Wayne Young 33 | * 34 | * Copyright (C) 1985, Avadis Tevanian, Jr., Michael Wayne Young 35 | * 36 | * Machine-dependent kernel return definitions. 37 | * 38 | * HISTORY 39 | * 14-Oct-85 Michael Wayne Young (mwyoung) at Carnegie-Mellon University 40 | * Created. 41 | */ 42 | 43 | #ifndef _KERN_RETURN_MACHINE_ 44 | #define _KERN_RETURN_MACHINE_ 45 | 46 | typedef int kern_return_t; 47 | 48 | #endif _KERN_RETURN_MACHINE_ 49 | -------------------------------------------------------------------------------- /ca/lopckvtl.s: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* $Header: lopckvtl.s,v 4.0 85/07/15 00:44:50 ibmacis GAMMA $ */ 29 | /* $Source: /ibm/acis/usr/sys_ca/ca/RCS/lopckvtl.s,v $ */ 30 | 31 | .data 32 | rcsidpckvtl: .asciz "$Header: lopckvtl.s,v 4.0 85/07/15 00:44:50 ibmacis GAMMA $" 33 | .text 34 | 35 | -------------------------------------------------------------------------------- /ca/machparam.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | #include "../ca/param.h" 29 | -------------------------------------------------------------------------------- /ca/machtypes.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * File: vax/machtypes.h 30 | * 31 | * Basic system types for VAX. 32 | * 33 | * HISTORY 34 | * 11-Mar-85 Avadis Tevanian (avie) at Carnegie-Mellon University 35 | * Created. 36 | */ 37 | 38 | typedef int boolean_t; 39 | 40 | /* 41 | * Dare I define these here? 42 | */ 43 | 44 | #if defined(KERNEL) && !defined(NOBOOL) && !defined(TRUE) 45 | #define TRUE ((boolean_t) 1) 46 | #define FALSE ((boolean_t) 0) 47 | typedef enum { false = 0, true = 1 } bool; 48 | #endif defined(KERNEL) && !defined(NOBOOL) && !defined(TRUE) 49 | 50 | #define NULL 0 51 | -------------------------------------------------------------------------------- /ca/pcb.m: -------------------------------------------------------------------------------- 1 | /* $Header: pcb.m,v 4.1 85/08/22 11:37:28 webb Exp $ */ 2 | /* $Source: /ibm/acis/usr/sys_ca/ca/RCS/pcb.m,v $ */ 3 | 4 | .data 5 | rcsidpcb: .asciz "$Header: pcb.m,v 4.1 85/08/22 11:37:28 webb Exp $" 6 | .text 7 | 8 | /* pcb.m 6.1 83/07/29 */ 9 | 10 | /* 11 | * VAX process control block 12 | */ 13 | #define PCB_KSP 0 14 | #define PCB_ESP 4 15 | #define PCB_SSP 8 16 | #define PCB_USP 16 17 | #define PCB_R0 12 18 | #define PCB_R1 16 19 | #define PCB_R2 20 20 | #define PCB_R3 24 21 | #define PCB_R4 28 22 | #define PCB_R5 32 23 | #define PCB_R6 36 24 | #define PCB_R7 40 25 | #define PCB_R8 44 26 | #define PCB_R9 48 27 | #define PCB_R10 52 28 | #define PCB_R11 56 29 | #define PCB_R12 60 30 | #define PCB_R13 64 31 | #define PCB_R14 68 32 | #define PCB_R15 72 33 | #define PCB_IAR 76 34 | #define PCB_ICSCS 80 35 | #define PCB_P0BR 84 36 | #define PCB_P0LR 88 37 | #define PCB_P1BR 92 38 | #define PCB_P1LR 96 39 | /* 40 | * Software pcb extension 41 | */ 42 | #define PCB_SZPT 100 /* number of user page table pages */ 43 | #define PCB_CMAP2 104 /* saved cmap2 across cswitch (ick) */ 44 | #define PCB_SSWAP 108 /* flag for non-local goto */ 45 | #define PCB_SIGC 112 /* signal trampoline code */ 46 | #define PCB_CCR 124 /* CCR value */ 47 | 48 | #define AST_USER 0x80000000 /* VAX AST simulation for user mode in ics*/ 49 | #define AST_USER_BIT 0 /* VAX AST simulation for user mode in ics*/ 50 | -------------------------------------------------------------------------------- /ca/proc.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* $Header: proc.h,v 4.0 85/07/15 00:47:07 ibmacis GAMMA $ */ 29 | /* $Source: /ibm/acis/usr/sys_ca/ca/RCS/proc.h,v $ */ 30 | 31 | #if !defined(lint) && !defined(LOCORE) && defined(RCS_HDRS) 32 | static char *rcsidproc = "$Header: proc.h,v 4.0 85/07/15 00:47:07 ibmacis GAMMA $"; 33 | #endif 34 | 35 | /* process table offsets for kernel assembler code */ 36 | #ifdef LOCORE 37 | P_ADDR = 12 38 | P_CPU = 18 39 | P_LINK = 0 40 | P_PRI = 17 41 | P_P0BR = 100 42 | P_RLINK = 4 43 | P_SID0 = 8 44 | P_SID1 = 10 45 | P_STAT = 19 46 | P_SZPT = 62 47 | P_USRPRI = 16 48 | P_PID = 48 49 | SRUN=3 50 | SZOMB=5 51 | U_PROCP = 128 52 | USIZE = 0x784 53 | #endif 54 | -------------------------------------------------------------------------------- /ca/symbols.raw: -------------------------------------------------------------------------------- 1 | #$Header: symbols.raw,v 4.1 85/08/01 18:14:38 webb Exp $ 2 | #$Source: /ibm/acis/usr/sys_ca/ca/RCS/symbols.raw,v $ 3 | # symbols.raw 4.8 83/05/03 4 | _version 5 | #dmesg 6 | _msgbuf 7 | #iostat 8 | _dk_busy 9 | _dk_time 10 | _dk_xfer 11 | _dk_wds 12 | _tk_nin 13 | _tk_nout 14 | _dk_seek 15 | _cp_time 16 | _dk_mspw 17 | # _io_info 18 | #ps 19 | _proc 20 | # _Usrptmap 21 | # _usrpt 22 | _text 23 | _nswap 24 | _maxslp 25 | _ccpu 26 | _ecmx 27 | _nproc 28 | _ntext 29 | _dmmin 30 | _dmmax 31 | #pstat 32 | _inode 33 | _text 34 | _proc 35 | # _dz_tty 36 | # _dz_cnt 37 | _cons 38 | _file 39 | _Usrptmap 40 | _usrpt 41 | _nswap 42 | _swapmap 43 | # _dh11 44 | # _ndh11 45 | #vmstat 46 | _cp_time 47 | _rate 48 | _total 49 | _deficit 50 | _forkstat 51 | _sum 52 | _firstfree 53 | _maxfree 54 | # _rectime 55 | # _pgintime 56 | _dk_xfer 57 | _boottime 58 | #w 59 | _proc 60 | _swapdev 61 | _Usrptmap 62 | _usrpt 63 | _nswap 64 | _avenrun 65 | _boottime 66 | #netstat 67 | _mbstat 68 | _ipstat 69 | _tcb 70 | _tcpstat 71 | _udb 72 | _udpstat 73 | _rawcb 74 | # _Sysmap 75 | # _Syssize 76 | _ifnet 77 | _rthost 78 | _rtnet 79 | _icmpstat 80 | #routed 81 | _ifnet 82 | #rwho 83 | _avenrun 84 | _boottime 85 | -------------------------------------------------------------------------------- /ca/symbols.sort: -------------------------------------------------------------------------------- 1 | _avenrun 2 | _boottime 3 | _ccpu 4 | _cons 5 | _cp_time 6 | _deficit 7 | _dk_busy 8 | _dk_mspw 9 | _dk_seek 10 | _dk_time 11 | _dk_wds 12 | _dk_xfer 13 | _dmmax 14 | _dmmin 15 | _ecmx 16 | _file 17 | _firstfree 18 | _forkstat 19 | _icmpstat 20 | _ifnet 21 | _inode 22 | _ipstat 23 | _maxfree 24 | _maxslp 25 | _mbstat 26 | _msgbuf 27 | _nproc 28 | _nswap 29 | _ntext 30 | _proc 31 | _rate 32 | _rawcb 33 | _rthost 34 | _rtnet 35 | _sum 36 | _swapdev 37 | _swapmap 38 | _tcb 39 | _tcpstat 40 | _text 41 | _tk_nin 42 | _tk_nout 43 | _total 44 | _udb 45 | _udpstat 46 | _version 47 | -------------------------------------------------------------------------------- /ca/undefine.c: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* $Header: undefine.c,v 4.0 85/07/15 00:49:52 ibmacis GAMMA $ */ 29 | /* $Source: /ibm/acis/usr/sys_ca/ca/RCS/undefine.c,v $ */ 30 | 31 | #ifndef lint 32 | static char *rcsid = "$Header: undefine.c,v 4.0 85/07/15 00:49:52 ibmacis GAMMA $"; 33 | #endif 34 | 35 | /* Unidefined procs in the 4.2 kernel */ 36 | #ifndef INET 37 | setsoftnet() 38 | { 39 | panic("setsoftnet called"); 40 | } 41 | 42 | 43 | in_cksum() 44 | { 45 | panic("in_cksum called"); 46 | } 47 | 48 | 49 | #endif INET 50 | -------------------------------------------------------------------------------- /ca/vm_types.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * File: vm_types.h 30 | * Author: Avadis Tevanian, Jr. 31 | * 32 | * Copyright (C) 1985, Avadis Tevanian, Jr. 33 | * 34 | * Header file for VM data types. Romp version. 35 | * 36 | * HISTORY 37 | * 13-Jun-85 Avadis Tevanian (avie) at Carnegie-Mellon University 38 | * Created. 39 | */ 40 | 41 | #ifndef _VM_TYPES_MACHINE_ 42 | #define _VM_TYPES_MACHINE_ 1 43 | 44 | typedef unsigned long vm_offset_t; 45 | typedef unsigned long vm_size_t; 46 | 47 | #endif _VM_TYPES_MACHINE_ 48 | -------------------------------------------------------------------------------- /ca/xFPexception.c: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* $Header: xFPexception.c,v 4.0 85/07/15 00:50:46 ibmacis GAMMA $ */ 29 | /* $Source: /ibm/acis/usr/sys_ca/ca/RCS/xFPexception.c,v $ */ 30 | 31 | #ifndef lint 32 | static char *rcsid = "$Header: xFPexception.c,v 4.0 85/07/15 00:50:46 ibmacis GAMMA $"; 33 | #endif 34 | 35 | #include "../machine/fp.h" 36 | 37 | xFPexception() 38 | { 39 | 40 | printf("Kernel floating point exception raised: status=%b\n", 41 | machine.status, 42 | "\020\36INV_OPER\32OVERFLOW\30UNDERFLOW\34DIVIDE\7INEXACT"); 43 | } 44 | 45 | 46 | ; 47 | -------------------------------------------------------------------------------- /caio/adunload.sh: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | # 3 | # 5799-CGZ (C) COPYRIGHT IBM CORPORATION 1986 4 | # LICENSED MATERIALS - PROPERTY OF IBM 5 | # REFER TO COPYRIGHT INSTRUCTIONS FORM NUMBER G120-2083 6 | # 7 | #$Header: adunload.sh,v 5.0 86/01/31 18:05:36 ibmacis ibm42a $ 8 | #$Source: /ibm/acis/usr/sys_ca/caio/RCS/adunload.sh,v $ 9 | # produced an optimized (with hand ex script) 10 | # of adunload.c 11 | # 12 | # this is done basically by replacing 12 get/puts with a lm and 12 puts 13 | # or 12 gets and a stm 14 | # 15 | umask 2 16 | ASSOURCE=${1-adunload.s} 17 | ex $ASSOURCE <<'+' 18 | 1 19 | " following removes unneeded prolog 20 | /cal/+1ka 21 | 'a,/r10,r4/s;^;|; 22 | g/r11/s//r2/g 23 | " following puts profile code back in! 24 | g/^|.*profil/s/|// 25 | g/r9/s//r3/g 26 | g/r10/s//r0/g 27 | /cas.r0,r4/s;|;; 28 | " following replaces get/put's with ls ... stm 29 | 1 30 | /get r3,0(r3)/ka 31 | /put.*,44(r2)/kb 32 | 'a,'bv/^|/s;^;|; 33 | 'ba 34 | ls r4,0(r3) 35 | ls r5,0(r3) 36 | ls r6,0(r3) 37 | ls r7,0(r3) 38 | ls r8,0(r3) 39 | ls r9,0(r3) 40 | ls r10,0(r3) 41 | ls r11,0(r3) 42 | ls r12,0(r3) 43 | ls r13,0(r3) 44 | ls r14,0(r3) 45 | ls r15,0(r3) 46 | stm r4,0(r2) 47 | . 48 | /ai r2,r2,48/ka 49 | 'a 50 | / b /kb 51 | 'bs; b ; bx ; 52 | 'am'b 53 | /get r.,0(r2)/ka 54 | 'a 55 | /get r.,44(r2)/+1kb 56 | 'b 57 | 'a,'bv/^|/s;^;|; 58 | 'ba 59 | lm r4,0(r2) 60 | sts r4,0(r3) 61 | sts r5,0(r3) 62 | sts r6,0(r3) 63 | sts r7,0(r3) 64 | sts r8,0(r3) 65 | sts r9,0(r3) 66 | sts r10,0(r3) 67 | sts r11,0(r3) 68 | sts r12,0(r3) 69 | sts r13,0(r3) 70 | sts r14,0(r3) 71 | sts r15,0(r3) 72 | . 73 | /ai r2,r2,48/ka 74 | 'a 75 | / b /kb 76 | 'bs; b ; bx ; 77 | 'am'b 78 | wq 79 | + 80 | -------------------------------------------------------------------------------- /caio/adunload.sh.NCS: -------------------------------------------------------------------------------- 1 | #! /bin/sh 2 | # 3 | # 5799-CGZ (C) COPYRIGHT IBM CORPORATION 1986 4 | # LICENSED MATERIALS - PROPERTY OF IBM 5 | # REFER TO COPYRIGHT INSTRUCTIONS FORM NUMBER G120-2083 6 | # 7 | #$Header: adunload.sh.NCS,v 5.0 86/01/31 18:05:45 ibmacis ibm42a $ 8 | #$Source: /ibm/acis/usr/sys_ca/caio/RCS/adunload.sh.NCS,v $ 9 | # produced an optimized (with hand ex script) 10 | # of adunload.c 11 | # 12 | # this is done basically by replacing 12 get/puts with a lm and 12 puts 13 | # or 12 gets and a stm 14 | # 15 | umask 2 16 | ASSOURCE=${1-adunload.s} 17 | ex $ASSOURCE <<'+' 18 | 1 19 | /ai sp,sp/s/L103-LREGSPACE103/LREGSPACE103-64/ 20 | /ai sp,sp/+1ka 21 | 'a,/cas.r6,r5/s;^;|; 22 | g/r9/s//r2/g 23 | g/r7/s//r3/g 24 | g/r8/s//r0/g 25 | g/r6/s//r5/g 26 | g/^|.*profil/s/|// 27 | /cas.r0,r4/s;|;; 28 | g/mr.r4/s;^;|; 29 | g/cal.sp,/s/(r4)// 30 | g/cal.sp,/s//ai sp,sp,/ 31 | g/r13/s//sp/g 32 | g/LOWREG103,/s/r5/r6/ 33 | 1 34 | /get r12,0(r3)/ 35 | /get r12,0(r3)/ka 36 | /put.*,44(r2)/kb 37 | 'a,'bv/^|/s;^;|; 38 | 'ba 39 | ls r4,0(r3) 40 | ls r5,0(r3) 41 | ls r6,0(r3) 42 | ls r7,0(r3) 43 | ls r8,0(r3) 44 | ls r9,0(r3) 45 | ls r10,0(r3) 46 | ls r11,0(r3) 47 | ls r12,0(r3) 48 | ls r13,0(r3) 49 | ls r14,0(r3) 50 | ls r15,0(r3) 51 | stm r4,0(r2) 52 | . 53 | /ai r2,r2,48/ka 54 | 'a 55 | / b /kb 56 | 'bs; b ; bx ; 57 | 'am'b 58 | /get r12,0(r2)/ka 59 | 'a 60 | /get r12,44(r2)/+1kb 61 | 'b 62 | 'a,'bv/^|/s;^;|; 63 | 'ba 64 | lm r4,0(r2) 65 | sts r4,0(r3) 66 | sts r5,0(r3) 67 | sts r6,0(r3) 68 | sts r7,0(r3) 69 | sts r8,0(r3) 70 | sts r9,0(r3) 71 | sts r10,0(r3) 72 | sts r11,0(r3) 73 | sts r12,0(r3) 74 | sts r13,0(r3) 75 | sts r14,0(r3) 76 | sts r15,0(r3) 77 | . 78 | /ai r2,r2,48/ka 79 | 'a 80 | / b /kb 81 | 'bs; b ; bx ; 82 | 'am'b 83 | wq 84 | + 85 | -------------------------------------------------------------------------------- /caio/apa16.c: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * 5799-CGZ (C) COPYRIGHT IBM CORPORATION 1986 30 | * LICENSED MATERIALS - PROPERTY OF IBM 31 | * REFER TO COPYRIGHT INSTRUCTIONS FORM NUMBER G120-2083 32 | */ 33 | /* $Header: apa16.c,v 5.0 86/01/31 18:06:17 ibmacis ibm42a $ */ 34 | /* $Source: /ibm/acis/usr/sys_ca/caio/RCS/apa16.c,v $ */ 35 | 36 | 37 | /* 38 | * these are called from screendev via screen_sw. Flesh out as needed. 39 | */ 40 | 41 | apa16open() 42 | { 43 | return(0); 44 | } 45 | 46 | apa16close() 47 | { 48 | return(0); 49 | } 50 | 51 | -------------------------------------------------------------------------------- /caio/apa8.c: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * 5799-CGZ (C) COPYRIGHT IBM CORPORATION 1986 30 | * LICENSED MATERIALS - PROPERTY OF IBM 31 | * REFER TO COPYRIGHT INSTRUCTIONS FORM NUMBER G120-2083 32 | */ 33 | /* $Header: apa8.c,v 5.0 86/01/31 18:06:25 ibmacis ibm42a $ */ 34 | /* $Source: /ibm/acis/usr/sys_ca/caio/RCS/apa8.c,v $ */ 35 | 36 | 37 | /* 38 | * these are called from screendev via screen_sw. Flesh out as needed. 39 | */ 40 | 41 | apa8open() 42 | { 43 | return(0); 44 | } 45 | 46 | apa8close() 47 | { 48 | return(0); 49 | } 50 | 51 | -------------------------------------------------------------------------------- /cassette/anyboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ANY DEVICE TO A SINGLE USER SHELL 3 | ! R11 = 3 = ASKNAME | SINGLE 4 | ! R10 = DON'T CARE 5 | ! 6 | I 7 | L BOOT 8 | D RB 3 9 | S 2 10 | -------------------------------------------------------------------------------- /cassette/cassette.out: -------------------------------------------------------------------------------- 1 | dd if=cassette of=/dev/uu0 bs=2k conv=sync 2 | 44+1 records in 3 | 45+0 records out 4 | dd if=../mdec/tuboot of=/dev/uu0 bs=512 count=2 5 | 2+0 records in 6 | 2+0 records out 7 | -------------------------------------------------------------------------------- /cassette/cassette.out1: -------------------------------------------------------------------------------- 1 | dd if=cassette of=/dev/uu1 bs=2k conv=sync 2 | 44+1 records in 3 | 45+0 records out 4 | dd if=../mdec/tuboot of=/dev/uu1 bs=512 count=2 5 | 2+0 records in 6 | 2+0 records out 7 | -------------------------------------------------------------------------------- /cassette/defboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP BY BOOT() SYSCALL 3 | ! GO MULTI-USER AFTER CHECKING; BOOT FROM DEFAULT DEVICE 4 | ! R11 = 0 5 | ! R10 = 11 = RB 6 | ! 7 | I 8 | L BOOT 9 | D RB 0 10 | D RA B 11 | S 2 12 | -------------------------------------------------------------------------------- /cassette/defboo.hk: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP BY BOOT() SYSCALL 3 | ! GO MULTI-USER AFTER CHECKING; BOOT FROM DEFAULT DEVICE 4 | ! R11 = 0 5 | ! R10 = 3 = HK 6 | ! 7 | I 8 | L BOOT 9 | D RB 0 10 | D RA 3 11 | S 2 12 | -------------------------------------------------------------------------------- /cassette/defboo.ra: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP BY BOOT() SYSCALL 3 | ! GO MULTI-USER AFTER CHECKING; BOOT FROM DEFAULT DEVICE 4 | ! R11 = 0 5 | ! R10 = 9 = RA 6 | ! 7 | I 8 | L BOOT 9 | D RB 0 10 | D RA 9 11 | S 2 12 | -------------------------------------------------------------------------------- /cassette/defboo.rb: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP BY BOOT() SYSCALL 3 | ! GO MULTI-USER AFTER CHECKING; BOOT FROM DEFAULT DEVICE 4 | ! R11 = 0 5 | ! R10 = 11 = RB 6 | ! 7 | I 8 | L BOOT 9 | D RB 0 10 | D RA B 11 | S 2 12 | -------------------------------------------------------------------------------- /cassette/defboo.rl: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP BY BOOT() SYSCALL 3 | ! GO MULTI-USER AFTER CHECKING; BOOT FROM DEFAULT DEVICE 4 | ! R11 = 0 5 | ! R10 = 14 = RA 6 | ! 7 | I 8 | L BOOT 9 | D RB 0 10 | D RA 14 11 | S 2 12 | -------------------------------------------------------------------------------- /cassette/defboo.up: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP BY BOOT() SYSCALL 3 | ! GO MULTI-USER AFTER CHECKING; BOOT FROM DEFAULT DEVICE 4 | ! R11 = 0 5 | ! R10 = 2 = UP 6 | ! 7 | I 8 | L BOOT 9 | D RB 0 10 | D RA 2 11 | S 2 12 | -------------------------------------------------------------------------------- /cassette/hkmboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON HK, GOING MULTI USER 3 | ! R11 = 0 4 | ! R10 = 3 = HK 5 | ! 6 | I 7 | L BOOT 8 | D RB 0 9 | D RA 3 10 | S 2 11 | -------------------------------------------------------------------------------- /cassette/hksboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON HK, LEAVING SINGLE USER 3 | ! R11 = 2 = SINGLE 4 | ! R10 = 3 = HK 5 | ! 6 | I 7 | L BOOT 8 | D RB 2 9 | D RA 3 10 | S 2 11 | -------------------------------------------------------------------------------- /cassette/ramboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON UP, GOING MULTI USER 3 | ! R11 = 0 4 | ! R10 = 9 = RA 5 | ! 6 | I 7 | L BOOT 8 | D RB 0 9 | D RA 9 10 | S 2 11 | -------------------------------------------------------------------------------- /cassette/rasboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON UP, LEAVING SINGLE USER 3 | ! R11 = 2 = SINGLE 4 | ! R10 = 9 = RA 5 | ! 6 | I 7 | L BOOT 8 | D RB 2 9 | D RA 9 10 | S 2 11 | -------------------------------------------------------------------------------- /cassette/rbmboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON UP, GOING MULTI USER 3 | ! R11 = 0 4 | ! R10 = 11 = RB 5 | ! 6 | I 7 | L BOOT 8 | D RB 0 9 | D RA B 10 | S 2 11 | -------------------------------------------------------------------------------- /cassette/rbsboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON UP, LEAVING SINGLE USER 3 | ! R11 = 2 = SINGLE 4 | ! R10 = 11 = RB 5 | ! 6 | I 7 | L BOOT 8 | D RB 2 9 | D RA B 10 | S 2 11 | -------------------------------------------------------------------------------- /cassette/restar.cmd: -------------------------------------------------------------------------------- 1 | ! RESTART COMMMAND FILE 2 | I 3 | D PC C00 4 | D PSL 0 5 | C 6 | -------------------------------------------------------------------------------- /cassette/rlsboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON UP, LEAVING SINGLE USER 3 | ! R11 = 2 = SINGLE 4 | ! R10 = 14 = RA 5 | ! 6 | I 7 | L BOOT 8 | D RB 2 9 | D RA E 10 | S 2 11 | -------------------------------------------------------------------------------- /cassette/upmboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON UP, GOING MULTI USER 3 | ! R11 = 0 4 | ! R10 = 2 = UP 5 | ! 6 | I 7 | L BOOT 8 | D RB 0 9 | D RA 2 10 | S 2 11 | -------------------------------------------------------------------------------- /cassette/upsboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON UP, LEAVING SINGLE USER 3 | ! R11 = 2 = SINGLE 4 | ! R10 = 2 = UP 5 | ! 6 | I 7 | L BOOT 8 | D RB 2 9 | D RA 2 10 | S 2 11 | -------------------------------------------------------------------------------- /conf/ANSEL: -------------------------------------------------------------------------------- 1 | # 2 | # ANSEL (ADAMS) COMET 3 | # 4 | machine vax 5 | cpu "VAX780" 6 | cpu "VAX750" 7 | cpu "VAX730" 8 | ident ANSEL 9 | timezone 7 dst 10 | maxusers 16 11 | 12 | config vmunix root on hk 13 | config hpvmunix root on hp 14 | 15 | controller uba0 at nexus ? 16 | controller mba0 at nexus ? 17 | disk hp0 at mba? drive 0 18 | disk hp1 at mba? drive 1 19 | controller hk0 at uba? csr 0177440 vector rkintr 20 | disk rk0 at hk0 drive 0 21 | disk rk1 at hk0 drive 1 22 | disk rk2 at hk0 drive 2 23 | controller uda0 at uba? csr 0160374 vector udintr 24 | disk ra0 at uda0 drive 0 25 | disk ra1 at uda0 drive 1 26 | device dz0 at uba? csr 0160120 flags 0xff vector dzrint dzxint 27 | controller zs0 at uba? csr 0172520 vector tsintr 28 | device ts0 at zs0 drive 0 29 | -------------------------------------------------------------------------------- /conf/Makefile: -------------------------------------------------------------------------------- 1 | all: MACH SINGLE_CPU GENERIC MACHRT 2 | 3 | MACH: sed/MACH.sed MASTER 4 | sed -f sed/MACH.sed < MASTER > MACH 5 | 6 | SINGLE_CPU: sed/SINGLE_CPU.sed MASTER 7 | sed -f sed/SINGLE_CPU.sed < MASTER > SINGLE_CPU 8 | 9 | GENERIC: sed/GENERIC.sed MASTER 10 | sed -f sed/GENERIC.sed < MASTER > GENERIC 11 | 12 | MACHRT: sed/MACHRT.sed MASTER 13 | sed -f sed/MACHRT.sed < MASTER > MACHRT 14 | -------------------------------------------------------------------------------- /conf/UCB730: -------------------------------------------------------------------------------- 1 | # 2 | # ETHERNET MIRO 3 | # 4 | machine vax 5 | cpu "VAX730" 6 | ident MIRO 7 | timezone 8 dst 8 | maxusers 8 9 | options INET 10 | options NS 11 | options QUOTA 12 | 13 | config vmunix root on rb0 14 | config rlvmunix root on rb1 15 | 16 | controller uba0 at nexus ? 17 | controller idc0 at uba0 csr 0175606 vector idcintr 18 | disk rb0 at idc0 drive 0 19 | disk rb1 at idc0 drive 1 20 | controller zs0 at uba? csr 0172520 vector tsintr 21 | device ts0 at zs0 drive 0 22 | device dmf0 at uba? csr 0160340 flags 0xfc 23 | vector dmfsrint dmfsxint dmfdaint dmfdbint dmfrint dmfxint dmflint 24 | pseudo-device pty 25 | pseudo-device loop 26 | device en0 at uba? csr 0161000 vector enxint enrint encollide 27 | -------------------------------------------------------------------------------- /conf/UCB750: -------------------------------------------------------------------------------- 1 | # 2 | # ETHERNET MATISSE 3 | # 4 | machine vax 5 | #cpu "VAX780" 6 | cpu "VAX750" 7 | #cpu "VAX730" 8 | ident MATISSE 9 | timezone 8 dst 10 | maxusers 16 11 | options INET 12 | options NS 13 | #options MRSP 14 | #options QUOTA 15 | 16 | config vmunix root on hp swap on hp0 and hp1 17 | config hkvmunix root on hk 18 | 19 | controller mba0 at nexus ? 20 | controller uba0 at nexus ? 21 | disk hp0 at mba? drive 0 22 | disk hp1 at mba? drive ? 23 | disk hp2 at mba? drive ? 24 | disk hp3 at mba? drive ? 25 | controller sc0 at uba? csr 0176700 vector upintr 26 | disk up0 at sc0 drive 0 27 | disk up1 at sc0 drive 1 28 | disk up2 at sc0 drive 2 29 | controller hk0 at uba? csr 0177440 vector rkintr 30 | disk rk0 at hk0 drive 0 31 | disk rk1 at hk0 drive 1 32 | device dz0 at uba? csr 0160100 flags 0xff vector dzrint dzxint 33 | device kg0 at uba? csr 0175620 vector kgclock 34 | pseudo-device pty 35 | pseudo-device loop 36 | pseudo-device ether 37 | device en0 at uba0 csr 0161000 vector enxint enrint encollide 38 | device ec0 at uba? csr 0164330 flags 0 39 | vector ecrint eccollide ecxint 40 | device il0 at uba? csr 0164000 vector ilrint ilcint 41 | device de0 at uba? csr 0174510 vector deintr 42 | device ex0 at uba? csr 0164344 vector excdint 43 | -------------------------------------------------------------------------------- /conf/UCB750IMP: -------------------------------------------------------------------------------- 1 | # 2 | # UCBVAX - Gateway to the world 3 | # 4 | machine vax 5 | cpu "VAX780" 6 | cpu "VAX750" 7 | cpu "VAX750" 8 | ident UCBVAX 9 | timezone 8 dst 10 | maxusers 32 11 | options INET 12 | options GATEWAY 13 | options QUOTA 14 | options NS 15 | 16 | config vmunix root on hp 17 | config hkvmunix root on hk 18 | 19 | controller mba0 at nexus ? 20 | controller uba0 at nexus ? 21 | disk hp0 at mba? drive 0 22 | disk hp1 at mba? drive 1 23 | controller hk0 at uba? csr 0177440 vector rkintr 24 | disk rk0 at hk0 drive 0 25 | disk rk1 at hk0 drive 1 26 | device dz0 at uba? csr 0160100 flags 0xff vector dzrint dzxint 27 | device dz1 at uba? csr 0160110 flags 0x0f vector dzrint dzxint 28 | pseudo-device loop 29 | pseudo-device ether 30 | pseudo-device imp 31 | device acc0 at uba? csr 0167600 vector accrint accxint 32 | device en0 at uba0 csr 0161000 vector enxint enrint encollide 33 | device il0 at uba? csr 0164000 vector ilrint ilcint 34 | device dmc0 at uba? csr 0167000 vector dmcrint dmcxint 35 | pseudo-device pty 36 | device lp0 at uba? csr 0164014 vector lpintr 37 | device kg0 at uba? csr 0175620 vector kgclock 38 | -------------------------------------------------------------------------------- /conf/UCB780: -------------------------------------------------------------------------------- 1 | # 2 | # ETHERNET ARPA 3 | # 4 | machine vax 5 | cpu "VAX780" 6 | cpu "VAX750" 7 | cpu "VAX730" 8 | ident ARPA 9 | timezone 8 dst 10 | maxusers 40 11 | options INET 12 | options GATEWAY # bigger route table 13 | options NS 14 | 15 | config vmunix root on hp0 swap on hp0 and hp1 and hp2 16 | config hpvmunix root on hp1 swap on hp1 17 | 18 | controller mba0 at nexus ? 19 | disk hp0 at mba? drive 0 20 | controller mba1 at nexus ? 21 | disk hp1 at mba? drive ? 22 | disk hp2 at mba? drive ? 23 | disk hp3 at mba? drive ? 24 | disk hp4 at mba? drive ? 25 | controller uba0 at nexus ? 26 | controller hk0 at uba? csr 0177440 vector rkintr 27 | disk rk0 at hk0 drive 0 28 | disk rk1 at hk0 drive 1 29 | controller tm0 at uba? csr 0172520 vector tmintr 30 | tape te0 at tm0 drive 0 31 | tape te1 at tm0 drive 1 32 | controller sc0 at uba? csr 0176700 vector upintr 33 | disk up0 at sc0 drive 0 34 | disk up1 at sc0 drive 1 35 | disk up2 at sc0 drive 2 36 | disk up3 at sc0 drive 3 37 | device dh0 at uba? csr 0160020 vector dhrint dhxint 38 | device dm0 at uba? csr 0170500 vector dmintr 39 | device dh1 at uba? csr 0160040 vector dhrint dhxint 40 | device dh2 at uba? csr 0160060 vector dhrint dhxint 41 | device dz0 at uba? csr 0160100 flags 0xc0 vector dzrint dzxint 42 | device dz1 at uba? csr 0160110 flags 0xff vector dzrint dzxint 43 | device kg0 at uba? csr 0176500 vector kgclock 44 | pseudo-device loop 45 | pseudo-device pty 46 | pseudo-device imp 47 | device acc0 at uba? csr 0167600 vector accrint accxint 48 | device en0 at uba? csr 0161000 vector enxint enrint encollide 49 | device dmc0 at uba? csr 0170000 vector dmcrint dmcxint 50 | -------------------------------------------------------------------------------- /conf/UCB8600: -------------------------------------------------------------------------------- 1 | # 2 | # VANGOGH 3 | # 4 | machine vax 5 | cpu "VAX8600" 6 | cpu "VAX780" 7 | ident VANGOGH 8 | timezone 8 dst 9 | maxusers 256 10 | options QUOTA 11 | options INET 12 | options NS 13 | options NSIP 14 | options MAXDSIZ="(64*1024*1024)" 15 | options BUFPAGES="3200" 16 | 17 | config vmunix root on ra0 swap on ra0 and ra1 and ra3 18 | config vmunix_usr root on ra0g swap on ra0b 19 | 20 | controller uba0 at nexus ? 21 | controller uba1 at nexus ? 22 | controller uba2 at nexus ? 23 | controller uda0 at uba? csr 0172150 vector udintr 24 | disk ra0 at uda0 drive 0 25 | disk ra1 at uda0 drive 1 26 | disk ra2 at uda0 drive 2 27 | disk ra3 at uda0 drive 3 28 | controller mba0 at nexus ? 29 | disk hp0 at mba0 drive ? 30 | disk hp1 at mba0 drive ? 31 | master ht0 at mba0 drive ? 32 | tape tu0 at ht0 slave 0 33 | device dmf0 at uba? csr 0160340 flags 0xff 34 | vector dmfsrint dmfsxint dmfdaint dmfdbint dmfrint dmfxint dmflint 35 | pseudo-device pty 36 | pseudo-device loop 37 | pseudo-device ether 38 | device de0 at uba? csr 0174510 vector deintr 39 | -------------------------------------------------------------------------------- /conf/UCB8600.PROF: -------------------------------------------------------------------------------- 1 | UCB8600 -------------------------------------------------------------------------------- /conf/defines: -------------------------------------------------------------------------------- 1 | /:#if.*[ \t]*KPROF/d 2 | /:#if.*[ \t]*PGINPROF/d 3 | /:#if.*[ \t]*UNFAST/d 4 | /:#if.*[ \t]*INSECURE/d 5 | /:#if.*[ \t]*TRACE/d 6 | /:#if.*[ \t]*DISKMON/d 7 | /:#if.*[ \t]*INTRLVE/d 8 | /:#if.*[ \t]*lint/d 9 | /:#if.*[ \t]*notdef/d 10 | /:#if.*[ \t]*unneeded/d 11 | /:#if.*[ \t]*vax/d 12 | /:#if.*[ \t]*TCPTRUEOOB/d 13 | /:#if.*[ \t]*irele/d 14 | /:#if.*[ \t]*ilock/d 15 | /:#if.*[ \t]*notyet/d 16 | -------------------------------------------------------------------------------- /conf/devices.vax: -------------------------------------------------------------------------------- 1 | hp 0 2 | up 2 3 | hk 3 4 | rk 3 5 | ra 9 6 | rb 11 7 | rx 12 8 | rl 14 9 | -------------------------------------------------------------------------------- /conf/files.ca: -------------------------------------------------------------------------------- 1 | ca/aedtty.c optional aed device-driver 2 | ca/apa8_scroll.c optional apaetty 3 | ca/apa8tty.c optional apaetty 4 | ca/autoconf.c standard 5 | ca/blt.s standard 6 | ca/clock.c standard 7 | ca/conf.c standard 8 | ca/cons.c standard 9 | ca/in_cksum.c optional inet 10 | ca/machdep.c standard config-dependent 11 | ca/mem.c standard 12 | ca/mono.c optional mono 13 | ca/pcb.c optional mach_vm 14 | ca/pup_cksum.c optional pup 15 | ca/romp_init.c optional mach_vm 16 | ca/screen_conf.c standard 17 | ca/sed.c standard 18 | ca/sys_machdep.c standard 19 | ca/trap.c standard 20 | ca/ufs_machdep.c standard 21 | ca/undefine.c standard 22 | ca/vm_machdep.c standard 23 | ca/vmaccess.c standard 24 | ca/xFPexception.c standard 25 | caif/if_ec.c optional ec device-driver 26 | caif/if_un.c optional un device-driver 27 | caio/adunload.s optional hd device-driver 28 | caio/aed.c optional aed device-driver 29 | caio/asy.c optional asy device-driver 30 | caio/dk.c optional dk device-driver 31 | caio/dma.c optional fd device-driver 32 | caio/fd.c optional fd device-driver 33 | caio/hd.c optional hd device-driver 34 | caio/lp.c optional lp device-driver 35 | caio/mouse.c optional ms device-driver 36 | caio/psp.c optional psp device-driver 37 | caio/st.c optional st device-driver 38 | caio/tty_mouse.c optional ms 39 | caio/ud.c optional ud device-driver 40 | mp/mp_queue.c optional mach_mp 41 | /dev/null optional mach_mpm 42 | /dev/null optional en 43 | /dev/null optional hy 44 | /dev/null optional wb_ml 45 | /dev/null optional ds 46 | /dev/null optional tms 47 | -------------------------------------------------------------------------------- /conf/newvers.sh: -------------------------------------------------------------------------------- 1 | #/* newvers.sh 6.1 84/05/25 */ 2 | if [ ! -r version ]; then echo 0 > version; fi 3 | touch version 4 | awk ' { version = $1 + 1; }\ 5 | END { 6 | printf "char version[] = \"Mach/4.3/2/1 WB#%d: ", version > "vers.c";\ 7 | printf "%d\n", version > "version"; }' < version; 8 | echo "`date`"'\n";' >> vers.c 9 | -------------------------------------------------------------------------------- /conf/sed/GENERIC.sed: -------------------------------------------------------------------------------- 1 | s/Master configuration file/DO NOT EDIT THIS FILE - EDIT MASTER/ 2 | s/MACHINE/vax/ 3 | s/CPU-TYPES/cpu "VAX8600"\ 4 | cpu "VAX780"\ 5 | cpu "VAXM"\ 6 | cpu "KA820"/ 7 | s/TIMEZONE/5 dst/ 8 | s/MAXUSERS/50/ 9 | s/MAXCPUS/16/ 10 | /^options MACH_TIME/d 11 | s/# PSEUDO-DEVICES/pseudo-device mach_mpm 4\ 12 | pseudo-device cmupty\ 13 | pseudo-device fe 3\ 14 | pseudo-device ild/ 15 | -------------------------------------------------------------------------------- /conf/sed/GENERIC.sed.BAK: -------------------------------------------------------------------------------- 1 | s/Master configuration file/DO NOT EDIT THIS FILE - EDIT MASTER/ 2 | s/MACHINE/vax/ 3 | s/CPU-TYPES/cpu "VAX8600"\ 4 | cpu "VAX780"\ 5 | cpu "VAXM"\ 6 | cpu "KA820"/ 7 | s/TIMEZONE/5 dst/ 8 | s/MAXUSERS/16/ 9 | s/MAXCPUS/16/ 10 | /^options MACH_VM/d 11 | /^options MACH_TIME/d 12 | s/# PSEUDO-DEVICES/pseudo-device mach_mpm 4\ 13 | pseudo-device cmupty\ 14 | pseudo-device fe 3\ 15 | pseudo-device ild/ 16 | -------------------------------------------------------------------------------- /conf/sed/MACH.sed: -------------------------------------------------------------------------------- 1 | s/Master configuration file/DO NOT EDIT THIS FILE - EDIT MASTER/ 2 | s/MACHINE/vax/ 3 | s/CPU-TYPES/cpu "VAX8600"\ 4 | cpu "VAX780"\ 5 | cpu "VAXM"\ 6 | cpu "KA820"/ 7 | s/TIMEZONE/5 dst/ 8 | s/MAXUSERS/16/ 9 | s/MAXCPUS/16/ 10 | s/# PSEUDO-DEVICES/pseudo-device mach_mpm 4/ 11 | -------------------------------------------------------------------------------- /conf/sed/MACHRT.sed: -------------------------------------------------------------------------------- 1 | s/Master configuration file/DO NOT EDIT THIS FILE - EDIT MASTER/ 2 | s/MACHINE/ca/ 3 | s/CPU-TYPES/cpu "SBMODEL"/ 4 | s/TIMEZONE/5 dst/ 5 | s/MAXUSERS/16/ 6 | s/MAXCPUS/1/ 7 | -------------------------------------------------------------------------------- /conf/sed/SINGLE_CPU.sed: -------------------------------------------------------------------------------- 1 | s/Master configuration file/DO NOT EDIT THIS FILE - EDIT MASTER/ 2 | s/MACHINE/vax/ 3 | s/CPU-TYPES/cpu "VAX8600"\ 4 | cpu "VAX780"\ 5 | cpu "VAXM"\ 6 | cpu "KA820"/ 7 | s/TIMEZONE/5 dst/ 8 | s/MAXUSERS/16/ 9 | s/MAXCPUS/1/ 10 | s/# PSEUDO-DEVICES/pseudo-device mach_mpm 4/ 11 | -------------------------------------------------------------------------------- /conf/touch.c: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | main(argc, argv) 4 | int argc; 5 | char **argv; 6 | { 7 | 8 | argc--, argv++; 9 | while (argc > 0) { 10 | struct stat stb; int c, f; 11 | if (stat(*argv, &stb) < 0) 12 | goto bad; 13 | if (chmod(*argv, stb.st_mode | 0200) < 0) 14 | goto bad; 15 | f = open(*argv, 2); 16 | if (f < 0) 17 | goto bad; 18 | lseek(f, 0, 0); 19 | read(f, &c, 1); 20 | lseek(f, 0, 0); 21 | write(f, &c, 1); 22 | close(f); 23 | chmod(*argv, stb.st_mode); 24 | argc--, argv++; 25 | continue; 26 | bad: 27 | perror(*argv); 28 | argc--, argv++; 29 | continue; 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /consolerl/Makefile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 1985, 1986 Regents of the University of California. 3 | # All rights reserved. The Berkeley software License Agreement 4 | # specifies the terms and conditions for redistribution. 5 | # 6 | # @(#)Makefile 7.1 (Berkeley) 6/5/86 7 | # 8 | BOOTS= boot 9 | STDBOOS= defboo.com anyboo.com 10 | DEFBOOS= defboo.hk defboo.hp defboo.ra defboo.up 11 | DEVBOOS= hkmboo.com hksboo.com hpmboo.com hpsboo.com \ 12 | ramboo.com rasboo.com upmboo.com upsboo.com 13 | UTILS= format copy drtest 14 | # order is NOT random... 15 | OBJS= ${BOOTS} ${STDBOOS} ${DEVBOOS} ${UTILS} 16 | DRIVE= /dev/crl 17 | 18 | # build a boot console rl02 from a DEC console rl02 pack 19 | update: ${OBJS} 20 | arff rmf ${DRIVE} ${OBJS} 21 | -rm -f defboo.com 22 | 23 | defboo.com: 24 | @echo You must copy one of ${DEFBOOS} to defboo.com. 25 | @echo See installing and operating guide for details. 26 | @/bin/false #force exits 27 | 28 | clean: 29 | rm -f ${BOOTS} ${UTILS} defboo.com 30 | -------------------------------------------------------------------------------- /consolerl/anyboo.com: -------------------------------------------------------------------------------- 1 | ! 2 | ! Load 'boot.' and boot 4.3BSD. 3 | ! 4 | ! Conversational boot to single user mode 5 | ! 6 | ! 7 | SET SNAP ON ! Enable ERROR_HALT snapshots 8 | SET FBOX OFF ! System will turn on Fbox 9 | INIT ! SRM processor init 10 | UNJAM ! UNJAM SBIA's and enable master sbia interrupts 11 | INIT/PAMM ! INIT physical address memory map 12 | DEPOSIT CSWP 8 ! Turn off the cache - System will enable cache 13 | 14 | DEPOSIT R10 0 ! Not used for conversational boot 15 | DEPOSIT R11 3 ! Software boot flags (conversational and single) 16 | 17 | LOAD/START:0 BOOT. ! Load 'boot.' at memory location 0 18 | START 2 ! Start 'boot.' at the address 2 19 | -------------------------------------------------------------------------------- /consolerl/defboo.hk: -------------------------------------------------------------------------------- 1 | ! 2 | ! Load 'boot.' and boot 4.3BSD. 3 | ! 4 | ! rk07 drive type boot to multi user mode 5 | ! 6 | ! 7 | SET SNAP ON ! Enable ERROR_HALT snapshots 8 | SET FBOX OFF ! System will turn on Fbox 9 | INIT ! SRM processor init 10 | UNJAM ! UNJAM SBIA's and enable master sbia interrupts 11 | INIT/PAMM ! INIT physical address memory map 12 | DEPOSIT CSWP 8 ! Turn off the cache - System will enable cache 13 | 14 | DEPOSIT R10 3 ! rk07 drive type - uba0 - drive 0 15 | DEPOSIT R11 0 ! Software boot flags (multi user mode) 16 | 17 | LOAD/START:0 BOOT. ! Load 'boot.' at memory location 0 18 | START 2 ! Start 'boot.' at the address 2 19 | -------------------------------------------------------------------------------- /consolerl/defboo.hp: -------------------------------------------------------------------------------- 1 | ! 2 | ! Load 'boot.' and boot 4.3BSD. 3 | ! 4 | ! 'hp' drive type boot to multi user mode 5 | ! 6 | ! 7 | SET SNAP ON ! Enable ERROR_HALT snapshots 8 | SET FBOX OFF ! System will turn on Fbox 9 | INIT ! SRM processor init 10 | UNJAM ! UNJAM SBIA's and enable master sbia interrupts 11 | INIT/PAMM ! INIT physical address memory map 12 | DEPOSIT CSWP 8 ! Turn off the cache - System will enable cache 13 | 14 | DEPOSIT R10 0 ! 'hp' drive type - mba0 - drive 0 15 | DEPOSIT R11 0 ! Software boot flags (multi user mode) 16 | 17 | LOAD/START:0 BOOT. ! Load 'boot.' at memory location 0 18 | START 2 ! Start 'boot.' at the address 2 19 | -------------------------------------------------------------------------------- /consolerl/defboo.ra: -------------------------------------------------------------------------------- 1 | ! 2 | ! Load 'boot.' and boot 4.3BSD. 3 | ! 4 | ! 'ra' MSCP drive type boot to multi user mode 5 | ! 6 | ! 7 | SET SNAP ON ! Enable ERROR_HALT snapshots 8 | SET FBOX OFF ! System will turn on Fbox 9 | INIT ! SRM processor init 10 | UNJAM ! UNJAM SBIA's and enable master sbia interrupts 11 | INIT/PAMM ! INIT physical address memory map 12 | DEPOSIT CSWP 8 ! Turn off the cache - System will enable cache 13 | 14 | DEPOSIT R10 9 ! 'ra' MSCP drive type - uba0 - drive 0 15 | DEPOSIT R11 0 ! Software boot flags (multi user mode) 16 | 17 | LOAD/START:0 BOOT. ! Load 'boot.' at memory location 0 18 | START 2 ! Start 'boot.' at the address 2 19 | -------------------------------------------------------------------------------- /consolerl/defboo.up: -------------------------------------------------------------------------------- 1 | ! 2 | ! Load 'boot.' and boot 4.3BSD. 3 | ! 4 | ! 'up' drive type boot to multi user mode 5 | ! 6 | ! 7 | SET SNAP ON ! Enable ERROR_HALT snapshots 8 | SET FBOX OFF ! System will turn on Fbox 9 | INIT ! SRM processor init 10 | UNJAM ! UNJAM SBIA's and enable master sbia interrupts 11 | INIT/PAMM ! INIT physical address memory map 12 | DEPOSIT CSWP 8 ! Turn off the cache - System will enable cache 13 | 14 | DEPOSIT R10 2 ! 'up' drive type - uba0 - drive 0 15 | DEPOSIT R11 0 ! Software boot flags (multi user mode) 16 | 17 | LOAD/START:0 BOOT. ! Load 'boot.' at memory location 0 18 | START 2 ! Start 'boot.' at the address 2 19 | -------------------------------------------------------------------------------- /consolerl/hkmboo.com: -------------------------------------------------------------------------------- 1 | ! 2 | ! Load 'boot.' and boot 4.3BSD. 3 | ! 4 | ! rk07 drive type boot to multi user mode 5 | ! 6 | ! 7 | SET SNAP ON ! Enable ERROR_HALT snapshots 8 | SET FBOX OFF ! System will turn on Fbox 9 | INIT ! SRM processor init 10 | UNJAM ! UNJAM SBIA's and enable master sbia interrupts 11 | INIT/PAMM ! INIT physical address memory map 12 | DEPOSIT CSWP 8 ! Turn off the cache - System will enable cache 13 | 14 | DEPOSIT R10 3 ! rk07 drive type - uba0 - drive 0 15 | DEPOSIT R11 0 ! Software boot flags (multi user mode) 16 | 17 | LOAD/START:0 BOOT. ! Load 'boot.' at memory location 0 18 | START 2 ! Start 'boot.' at the address 2 19 | -------------------------------------------------------------------------------- /consolerl/hksboo.com: -------------------------------------------------------------------------------- 1 | ! 2 | ! Load 'boot.' and boot 4.3BSD. 3 | ! 4 | ! rk07 drive type boot to single user mode 5 | ! 6 | ! 7 | SET SNAP ON ! Enable ERROR_HALT snapshots 8 | SET FBOX OFF ! System will turn on Fbox 9 | INIT ! SRM processor init 10 | UNJAM ! UNJAM SBIA's and enable master sbia interrupts 11 | INIT/PAMM ! INIT physical address memory map 12 | DEPOSIT CSWP 8 ! Turn off the cache - System will enable cache 13 | 14 | DEPOSIT R10 3 ! rk07 drive type - uba0 - drive 0 15 | DEPOSIT R11 2 ! Software boot flags (single user mode) 16 | 17 | LOAD/START:0 BOOT. ! Load 'boot.' at memory location 0 18 | START 2 ! Start 'boot.' at the address 2 19 | -------------------------------------------------------------------------------- /consolerl/hpmboo.com: -------------------------------------------------------------------------------- 1 | ! 2 | ! Load 'boot.' and boot 4.3BSD. 3 | ! 4 | ! 'hp' drive type boot to multi user mode 5 | ! 6 | ! 7 | SET SNAP ON ! Enable ERROR_HALT snapshots 8 | SET FBOX OFF ! System will turn on Fbox 9 | INIT ! SRM processor init 10 | UNJAM ! UNJAM SBIA's and enable master sbia interrupts 11 | INIT/PAMM ! INIT physical address memory map 12 | DEPOSIT CSWP 8 ! Turn off the cache - System will enable cache 13 | 14 | DEPOSIT R10 0 ! 'hp' drive type - mba0 - drive 0 15 | DEPOSIT R11 0 ! Software boot flags (multi user mode) 16 | 17 | LOAD/START:0 BOOT. ! Load 'boot.' at memory location 0 18 | START 2 ! Start 'boot.' at the address 2 19 | -------------------------------------------------------------------------------- /consolerl/hpsboo.com: -------------------------------------------------------------------------------- 1 | ! 2 | ! Load 'boot.' and boot 4.3BSD. 3 | ! 4 | ! 'hp' drive type boot to single user mode 5 | ! 6 | ! 7 | SET SNAP ON ! Enable ERROR_HALT snapshots 8 | SET FBOX OFF ! System will turn on Fbox 9 | INIT ! SRM processor init 10 | UNJAM ! UNJAM SBIA's and enable master sbia interrupts 11 | INIT/PAMM ! INIT physical address memory map 12 | DEPOSIT CSWP 8 ! Turn off the cache - System will enable cache 13 | 14 | DEPOSIT R10 0 ! 'hp' drive type - mba0 - drive 0 15 | DEPOSIT R11 2 ! Software boot flags (single user mode) 16 | 17 | LOAD/START:0 BOOT. ! Load 'boot.' at memory location 0 18 | START 2 ! Start 'boot.' at the address 2 19 | -------------------------------------------------------------------------------- /consolerl/ramboo.com: -------------------------------------------------------------------------------- 1 | ! 2 | ! Load 'boot.' and boot 4.3BSD. 3 | ! 4 | ! 'ra' MSCP drive type boot to multi user mode 5 | ! 6 | ! 7 | SET SNAP ON ! Enable ERROR_HALT snapshots 8 | SET FBOX OFF ! System will turn on Fbox 9 | INIT ! SRM processor init 10 | UNJAM ! UNJAM SBIA's and enable master sbia interrupts 11 | INIT/PAMM ! INIT physical address memory map 12 | DEPOSIT CSWP 8 ! Turn off the cache - System will enable cache 13 | 14 | DEPOSIT R10 9 ! 'ra' MSCP drive type - uba0 - drive 0 15 | DEPOSIT R11 0 ! Software boot flags (multi user mode) 16 | 17 | LOAD/START:0 BOOT. ! Load 'boot.' at memory location 0 18 | START 2 ! Start 'boot.' at the address 2 19 | -------------------------------------------------------------------------------- /consolerl/rasboo.com: -------------------------------------------------------------------------------- 1 | ! 2 | ! Load 'boot.' and boot 4.3BSD. 3 | ! 4 | ! 'ra' MSCP drive type boot to single user mode 5 | ! 6 | ! 7 | SET SNAP ON ! Enable ERROR_HALT snapshots 8 | SET FBOX OFF ! System will turn on Fbox 9 | INIT ! SRM processor init 10 | UNJAM ! UNJAM SBIA's and enable master sbia interrupts 11 | INIT/PAMM ! INIT physical address memory map 12 | DEPOSIT CSWP 8 ! Turn off the cache - System will enable cache 13 | 14 | DEPOSIT R10 9 ! 'ra' MSCP drive type - uba0 - drive 0 15 | DEPOSIT R11 2 ! Software boot flags (single user mode) 16 | 17 | LOAD/START:0 BOOT. ! Load 'boot.' at memory location 0 18 | START 2 ! Start 'boot.' at the address 2 19 | -------------------------------------------------------------------------------- /consolerl/upmboo.com: -------------------------------------------------------------------------------- 1 | ! 2 | ! Load 'boot.' and boot 4.3BSD. 3 | ! 4 | ! 'up' drive type boot to multi user mode 5 | ! 6 | ! 7 | SET SNAP ON ! Enable ERROR_HALT snapshots 8 | SET FBOX OFF ! System will turn on Fbox 9 | INIT ! SRM processor init 10 | UNJAM ! UNJAM SBIA's and enable master sbia interrupts 11 | INIT/PAMM ! INIT physical address memory map 12 | DEPOSIT CSWP 8 ! Turn off the cache - System will enable cache 13 | 14 | DEPOSIT R10 2 ! 'up' drive type - uba0 - drive 0 15 | DEPOSIT R11 0 ! Software boot flags (multi user mode) 16 | 17 | LOAD/START:0 BOOT. ! Load 'boot.' at memory location 0 18 | START 2 ! Start 'boot.' at the address 2 19 | -------------------------------------------------------------------------------- /consolerl/upsboo.com: -------------------------------------------------------------------------------- 1 | ! 2 | ! Load 'boot.' and boot 4.3BSD. 3 | ! 4 | ! 'up' drive type boot to single user mode 5 | ! 6 | ! 7 | SET SNAP ON ! Enable ERROR_HALT snapshots 8 | SET FBOX OFF ! System will turn on Fbox 9 | INIT ! SRM processor init 10 | UNJAM ! UNJAM SBIA's and enable master sbia interrupts 11 | INIT/PAMM ! INIT physical address memory map 12 | DEPOSIT CSWP 8 ! Turn off the cache - System will enable cache 13 | 14 | DEPOSIT R10 2 ! 'up' drive type - uba0 - drive 0 15 | DEPOSIT R11 2 ! Software boot flags (single user mode) 16 | 17 | LOAD/START:0 BOOT. ! Load 'boot.' at memory location 0 18 | START 2 ! Start 'boot.' at the address 2 19 | -------------------------------------------------------------------------------- /defunct/mp/sem_error.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * File: sem_error.h 30 | * Author: Avadis Tevanian, Jr. 31 | * 32 | * Semaphore error codes. 33 | * 34 | * HISTORY 35 | * 10-Nov-84 Avadis Tevanian (avie) at Carnegie-Mellon University 36 | * Created. 37 | * 38 | */ 39 | 40 | #define SEM_INVALID -1000 /* invalid semaphore */ 41 | #define SEM_TOOMANY -1001 /* too many semaphores */ 42 | #define SEM_INTR -1002 /* call interrupted */ 43 | -------------------------------------------------------------------------------- /dist/MAKEHOSTS: -------------------------------------------------------------------------------- 1 | #! /bin/sh -x 2 | 3 | # address search pattern to recognize local hosts 4 | LOCALADDR='^128\.32' 5 | 6 | # awk pattern for uninteresting (eg, long form) alias 7 | SKIP='/^ucb|\.berkeley\.edu$|^$/' 8 | 9 | # Special entries that don't get generated normally 10 | SPECIAL='ucbvax ucbarpa' 11 | 12 | 13 | cd ${DESTDIR}/usr/hosts 14 | # 15 | # We want to save ourselves while cleaning up. The funny sequence is to 16 | # minimize the window where the machine could crash and leave MAKEHOSTS 17 | # misplaced. 18 | # 19 | mv MAKEHOSTS .MAKEHOSTS 20 | rm -f M* 21 | mv .MAKEHOSTS MAKEHOSTS 22 | rm -f [A-LN-Za-z]* 23 | 24 | for i in `egrep "$LOCALADDR" ${DESTDIR}/etc/hosts | awk "\\$2 !~ $SKIP {print \\$2} \\$3 !~ $SKIP {print \\$3} \\$4 !~ $SKIP {print \\$4}"`; 25 | do 26 | ln -s /usr/ucb/rsh $i 27 | done 28 | 29 | for i in $SPECIAL 30 | do 31 | ln -s /usr/ucb/rsh $i 32 | done 33 | -------------------------------------------------------------------------------- /dist/README: -------------------------------------------------------------------------------- 1 | Sun Jun 23 16:31:26 PDT 1985 2 | 3 | The scripts needed to build a boot tape for 4.2 and beyond 4 | live here. Before trying anything look at the scripts 5 | 6 | buildmini 7 | get 8 | maketape 9 | 10 | To construct a tape suitable for bootstrapping a system 11 | first find a spare file system for a ``mini root'' and 12 | patch the buildmini shell script to reflect its location. 13 | Second, decide where your ``distribution'' source is located 14 | and patch the get and maketape scripts. Then do the following: 15 | % buildmini 16 | % maketape [ 6250 | 1600 [ tapename [ remotetapemachine ] ] ] 17 | This builds a distribution on one tape at 6250bpi, two tapes at 1600bpi. 18 | The tape drive may be on a remote machine if the last optional arg is given. 19 | For 1600bpi, be sure and check whether /usr/src will fit on one tape. 20 | The current distribution is about 80+ megabytes and easily fits on one tape 21 | at 6250bpi with a blocking factor of 20. 22 | -------------------------------------------------------------------------------- /dist/buildmini: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | # 3 | # Copyright (c) 1983 Regents of the University of California. 4 | # All rights reserved. The Berkeley software License Agreement 5 | # specifies the terms and conditions for redistribution. 6 | # 7 | # @(#)buildmini 4.8 (Berkeley) 6/6/86 8 | # 9 | miniroot=hp0d 10 | minitype=rm80 11 | # 12 | date 13 | umount /dev/${miniroot} 14 | newfs -s 4096 ${miniroot} ${minitype} 15 | fsck /dev/r${miniroot} 16 | mount /dev/${miniroot} /mnt 17 | cd /mnt; sh /sys/dist/get 18 | cd /sys/dist; sync 19 | umount /dev/${miniroot} 20 | fsck /dev/${miniroot} 21 | date 22 | -------------------------------------------------------------------------------- /dist/fstab.hp: -------------------------------------------------------------------------------- 1 | /dev/hp0a:/:rw:1:1 2 | /dev/hp0g:/usr:rw:1:3 3 | /dev/hp0h:/mnt:rw:1:2 4 | -------------------------------------------------------------------------------- /dist/fstab.hp400m: -------------------------------------------------------------------------------- 1 | /dev/hp0a:/:rw:1:1 2 | /dev/hp0g:/mnt:rw:1:3 3 | /dev/hp0h:/usr:rw:1:2 4 | -------------------------------------------------------------------------------- /dist/fstab.ra60: -------------------------------------------------------------------------------- 1 | /dev/ra0a:/:rw:1:1 2 | /dev/ra0g:/mnt:rw:1:3 3 | /dev/ra0h:/usr:rw:1:2 4 | -------------------------------------------------------------------------------- /dist/fstab.ra80: -------------------------------------------------------------------------------- 1 | /dev/ra0a:/:rw:1:1 2 | /dev/ra0g:/mnt:rw:1:3 3 | /dev/ra0h:/usr:rw:1:2 4 | -------------------------------------------------------------------------------- /dist/fstab.ra81: -------------------------------------------------------------------------------- 1 | /dev/ra0a:/:rw:1:1 2 | /dev/ra0g:/mnt:rw:1:3 3 | /dev/ra0h:/usr:rw:1:2 4 | -------------------------------------------------------------------------------- /dist/fstab.rb80: -------------------------------------------------------------------------------- 1 | /dev/rb0a:/:rw:1:1 2 | /dev/rb0g:/mnt:rw:1:3 3 | /dev/rb0h:/usr:rw:1:2 4 | -------------------------------------------------------------------------------- /dist/fstab.rk07: -------------------------------------------------------------------------------- 1 | /dev/hk0a:/:rw:1:1 2 | /dev/hk0g:/usr:rw:1:3 3 | /dev/hk1a:/mnt:rw:1:2 4 | /dev/hk1g:/usr/src:rw:1:3 5 | /dev/hk1a:/tmp:xx:1:2 6 | -------------------------------------------------------------------------------- /dist/fstab.rm03: -------------------------------------------------------------------------------- 1 | /dev/hp0a:/:rw:1:1 2 | /dev/hp0g:/usr:rw:1:2 3 | -------------------------------------------------------------------------------- /dist/fstab.rm05: -------------------------------------------------------------------------------- 1 | /dev/hp0a:/:rw:1:1 2 | /dev/hp0g:/usr:rw:1:3 3 | /dev/hp0h:/mnt:rw:1:2 4 | -------------------------------------------------------------------------------- /dist/fstab.rm80: -------------------------------------------------------------------------------- 1 | /dev/hp0a:/:rw:1:1 2 | /dev/hp0g:/usr:rw:1:2 3 | -------------------------------------------------------------------------------- /dist/fstab.rp06: -------------------------------------------------------------------------------- 1 | /dev/hp0a:/:rw:1:1 2 | /dev/hp0g:/usr:rw:1:2 3 | -------------------------------------------------------------------------------- /dist/fstab.rp07: -------------------------------------------------------------------------------- 1 | /dev/hp0a:/:rw:1:1 2 | /dev/hp0g:/mnt:rw:1:3 3 | /dev/hp0h:/usr:rw:1:2 4 | -------------------------------------------------------------------------------- /dist/fstab.up: -------------------------------------------------------------------------------- 1 | /dev/up0a:/:rw:1:1 2 | /dev/up0g:/usr:rw:1:3 3 | /dev/up0h:/mnt:rw:1:2 4 | -------------------------------------------------------------------------------- /dist/fstab.up160m: -------------------------------------------------------------------------------- 1 | /dev/up0a:/:rw:1:1 2 | /dev/up0g:/usr:rw:1:2 3 | -------------------------------------------------------------------------------- /dist/fstab.up300m: -------------------------------------------------------------------------------- 1 | /dev/up0a:/:rw:1:1 2 | /dev/up0g:/usr:rw:1:3 3 | /dev/up0h:/mnt:rw:1:2 4 | -------------------------------------------------------------------------------- /dist/group: -------------------------------------------------------------------------------- 1 | wheel:*:0:root 2 | daemon:*:1:daemon 3 | kmem:*:2:root 4 | sys:*:3:root 5 | tty:*:4:root 6 | operator:*:5:root 7 | staff:*:10:root 8 | guest:*:31:root 9 | ingres:*:74:ingres 10 | -------------------------------------------------------------------------------- /dist/inetd.conf: -------------------------------------------------------------------------------- 1 | # 2 | # Internet server configuration database 3 | # 4 | ftp stream tcp nowait root /etc/ftpd ftpd 5 | telnet stream tcp nowait root /etc/telnetd telnetd 6 | shell stream tcp nowait root /etc/rshd rshd 7 | login stream tcp nowait root /etc/rlogind rlogind 8 | exec stream tcp nowait root /etc/rexecd rexecd 9 | # Run as user "uucp" if you don't want uucpd's wtmp entries. 10 | #uucp stream tcp nowait root /etc/uucpd uucpd 11 | finger stream tcp nowait nobody /etc/fingerd fingerd 12 | #tftp dgram udp wait nobody /etc/tftpd tftpd 13 | comsat dgram udp wait root /etc/comsat comsat 14 | talk dgram udp wait root /etc/talkd talkd 15 | ntalk dgram udp wait root /etc/ntalkd ntalkd 16 | echo stream tcp nowait root internal 17 | discard stream tcp nowait root internal 18 | chargen stream tcp nowait root internal 19 | daytime stream tcp nowait root internal 20 | time stream tcp nowait root internal 21 | echo dgram udp wait root internal 22 | discard dgram udp wait root internal 23 | chargen dgram udp wait root internal 24 | daytime dgram udp wait root internal 25 | time dgram udp wait root internal 26 | -------------------------------------------------------------------------------- /dist/motd: -------------------------------------------------------------------------------- 1 | 4.3 BSD UNIX #1: Fri Jun 6 19:55:29 PDT 1986 2 | 3 | Would you like to play a game? 4 | 5 | -------------------------------------------------------------------------------- /dist/printcap: -------------------------------------------------------------------------------- 1 | lp|local line printer:\ 2 | :lp=/dev/lp:sd=/usr/spool/lpd:lf=/usr/adm/lpd-errs: 3 | -------------------------------------------------------------------------------- /dist/rc.local: -------------------------------------------------------------------------------- 1 | PATH=/etc:/bin:/usr/ucb:/usr/bin 2 | 3 | # myname is my symbolic name 4 | # myhostid is my internet address in #.#.#.# format 5 | # my-netmask is specified in /etc/networks 6 | # 7 | hostname myname.my.domain 8 | ifconfig imp0 netmask my-netmask `hostname` 9 | ifconfig en0 netmask my-netmask `hostname` 10 | ifconfig lo0 localhost 11 | route add `hostname` localhost 0 12 | hostid `hostname` 13 | 14 | strings /vmunix | grep UNIX >/tmp/t1 15 | tail +2 /etc/motd >>/tmp/t1 16 | mv /tmp/t1 /etc/motd 17 | chmod 666 /etc/motd 18 | 19 | # syslogd doesn't belong here, but needs to be started before the others. 20 | if [ -f /etc/syslogd ]; then 21 | echo 'starting system logger' >/dev/console 22 | rm -f /dev/log 23 | /etc/syslogd 24 | fi 25 | 26 | echo -n 'checking for core dump... ' >/dev/console 27 | savecore /a/crash >/dev/console 2>&1 28 | echo '' >/dev/console 29 | 30 | echo -n starting local daemons: >/dev/console 31 | #if [ -f /etc/routed ]; then 32 | # /etc/routed; echo -n ' routed' >/dev/console 33 | #fi 34 | if [ -f /etc/named ]; then 35 | /etc/named /etc/named.boot; echo -n ' named' >/dev/console 36 | fi 37 | #if [ -f /etc/timed ]; then 38 | # /etc/timed -M; echo -n ' timed' >/dev/console 39 | #fi 40 | if [ -f /usr/lib/sendmail ]; then 41 | (cd /usr/spool/mqueue; rm -f lf*) 42 | /usr/lib/sendmail -bd -q30m; echo -n ' sendmail'>/dev/console 43 | fi 44 | echo '.' >/dev/console 45 | -------------------------------------------------------------------------------- /dist/services: -------------------------------------------------------------------------------- 1 | # @(#)services 1.16 (Berkeley) 86/04/20 2 | # 3 | # Network services, Internet style 4 | # 5 | echo 7/tcp 6 | echo 7/udp 7 | discard 9/tcp sink null 8 | discard 9/udp sink null 9 | systat 11/tcp users 10 | daytime 13/tcp 11 | daytime 13/udp 12 | netstat 15/tcp 13 | qotd 17/tcp quote 14 | chargen 19/tcp ttytst source 15 | chargen 19/udp ttytst source 16 | ftp 21/tcp 17 | telnet 23/tcp 18 | smtp 25/tcp mail 19 | time 37/tcp timserver 20 | time 37/udp timserver 21 | rlp 39/udp resource # resource location 22 | nameserver 42/tcp name # IEN 116 23 | whois 43/tcp nicname 24 | domain 53/tcp nameserver # name-domain server 25 | domain 53/udp nameserver 26 | mtp 57/tcp # deprecated 27 | tftp 69/udp 28 | rje 77/tcp netrjs 29 | finger 79/tcp 30 | link 87/tcp ttylink 31 | supdup 95/tcp 32 | hostnames 101/tcp hostname # usually from sri-nic 33 | #csnet-cs 105/? 34 | pop 109/tcp postoffice 35 | sunrpc 111/tcp 36 | sunrpc 111/udp 37 | auth 113/tcp authentication 38 | sftp 115/tcp 39 | uucp-path 117/tcp 40 | nntp 119/tcp readnews untp # USENET News Transfer Protocol 41 | # 42 | # UNIX specific services 43 | # 44 | exec 512/tcp 45 | biff 512/udp comsat 46 | login 513/tcp 47 | who 513/udp whod 48 | shell 514/tcp cmd # no passwords used 49 | syslog 514/udp 50 | printer 515/tcp spooler # line printer spooler 51 | talk 517/udp 52 | ntalk 518/udp 53 | efs 520/tcp # for LucasFilm 54 | route 520/udp router routed 55 | timed 525/udp timeserver 56 | tempo 526/tcp newdate 57 | courier 530/tcp rpc 58 | conference 531/tcp chat 59 | netnews 532/tcp readnews 60 | netwall 533/udp # -for emergency broadcasts 61 | uucp 540/tcp uucpd # uucp daemon 62 | remotefs 556/tcp rfs_server rfs # Brunhoff remote filesystem 63 | 64 | ingreslock 1524/tcp 65 | -------------------------------------------------------------------------------- /dist/shells: -------------------------------------------------------------------------------- 1 | # List of acceptable shells for chsh/passwd -s 2 | # Ftpd will not allow users to connect who do not have one of these shells 3 | # 4 | /bin/sh 5 | /bin/csh 6 | -------------------------------------------------------------------------------- /dist/syslog.conf: -------------------------------------------------------------------------------- 1 | *.err;kern.debug;auth.notice /dev/console 2 | kern.debug;daemon,auth.notice;*.err;mail.crit /usr/adm/messages 3 | lpr.debug /usr/adm/lpd-errs 4 | mail.debug /usr/spool/mqueue/syslog 5 | 6 | *.alert;kern.err;daemon.err operator 7 | *.alert root 8 | 9 | *.emerg * 10 | -------------------------------------------------------------------------------- /dist/ttys: -------------------------------------------------------------------------------- 1 | # 2 | # name getty type status comments 3 | # 4 | console "/etc/getty Console-1200" unknown on secure 5 | tty00 "/etc/getty std.9600" unknown on secure 6 | tty01 "/etc/getty std.9600" unknown on secure 7 | tty02 "/etc/getty std.9600" unknown on secure 8 | tty03 "/etc/getty std.9600" unknown on secure 9 | tty04 "/etc/getty std.9600" unknown on secure 10 | tty05 "/etc/getty std.9600" unknown on secure 11 | tty06 "/etc/getty std.9600" unknown on secure 12 | tty07 "/etc/getty std.9600" unknown on secure 13 | ttyp0 none network 14 | ttyp1 none network 15 | ttyp2 none network 16 | ttyp3 none network 17 | ttyp4 none network 18 | ttyp5 none network 19 | ttyp6 none network 20 | ttyp7 none network 21 | ttyp8 none network 22 | ttyp9 none network 23 | ttypa none network 24 | ttypb none network 25 | ttypc none network 26 | ttypd none network 27 | ttype none network 28 | ttypf none network 29 | ttyq0 none network 30 | ttyq1 none network 31 | ttyq2 none network 32 | ttyq3 none network 33 | ttyq4 none network 34 | ttyq5 none network 35 | ttyq6 none network 36 | ttyq7 none network 37 | ttyq8 none network 38 | ttyq9 none network 39 | ttyqa none network 40 | ttyqb none network 41 | ttyqc none network 42 | ttyqd none network 43 | ttyqe none network 44 | ttyqf none network 45 | -------------------------------------------------------------------------------- /emul/vaxfloat.awk: -------------------------------------------------------------------------------- 1 | $1 ~ /^set_op_types$/{ 2 | for (i = 6; i < 7; i++) 3 | arg[i] = F 4 | 5 | n = split($2,arg,",") 6 | if ( n == 6 ) 7 | printf "movw $(typ_%s+(typ_%s<<8)),op_types4(fp)\n",arg[5],arg[6] 8 | 9 | if ( n == 5 ) 10 | printf "movb $(typ_%s),op_types4(fp)\n",arg[5] 11 | 12 | if ( n > 2) 13 | { 14 | printf "movl $(typ_%s+(typ_%s<<8)+(typ_%s<<16)+(typ_%s<<24))",arg[1],arg[2],arg[3],arg[4] 15 | printf ",op_types(fp)\n" 16 | } 17 | 18 | if ( n == 2 ) 19 | printf "movw $(typ_%s+(typ_%s<<8)),op_types(fp)\n",arg[1],arg[2] 20 | 21 | if ( n == 1) 22 | printf "movb $typ_%s,op_types(fp)\n",arg[1] 23 | } 24 | 25 | $1 ~ /^inst_type$/ { 26 | 27 | print "# define xxx 0" 28 | split($2,opcode,",") 29 | for ( i =1 ; i <= length(opcode[2]); i++ ) 30 | { 31 | printf "# define xxx xxx+it_%s\n",substr(opcode[2],i,1) 32 | } 33 | 34 | print "# define xxx xxx<<4" 35 | 36 | for ( i =1 ; i <= length(opcode[1]); i++ ) 37 | { 38 | printf "# define xxx xxx+it_%s\n",substr(opcode[1],i,1) 39 | } 40 | 41 | print ".byte xxx" 42 | 43 | } 44 | 45 | $1 !~ /^set_op_types$|^inst_type$/ 46 | -------------------------------------------------------------------------------- /floppy/Makefile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 1980, 1986 Regents of the University of California. 3 | # All rights reserved. The Berkeley software License Agreement 4 | # specifies the terms and conditions for redistribution. 5 | # 6 | # Makefile 7.1 86/06/05 7 | # 8 | # Make a 780 rx01 floppy 9 | # 10 | BOOTS= boot 11 | STDBOO= defboo.cmd anyboo.cmd restar.cmd 12 | DEFBOO= defboo.hk defboo.hp defboo.ra defboo.up 13 | DEVBOO= hkmboo.cmd hksboo.cmd hpmboo.cmd hpsboo.cmd \ 14 | ramboo.cmd rasboo.cmd upmboo.cmd upsboo.cmd 15 | UTILS= format copy drtest 16 | 17 | # order is NOT random... 18 | OBJS= ${BOOTS} ${STDBOO} ${DEVBOO} ${UTILS} 19 | FROMDEC=du* dm* db* s[mbr]* *boo.* vmb.exe *.hlp cs* ci* 20 | 21 | FLOPPY= /dev/floppy 22 | #FLOPPY= /dev/rrx0b # for using RX device 23 | 24 | all: floppy 25 | 26 | floppy: 3tracks ${OBJS} 27 | cp 3tracks floppy 28 | arff crf floppy ${OBJS} 29 | 30 | install: floppy 31 | dd if=floppy of=${FLOPPY} 32 | 33 | # build a boot floppy from a DEC console floppy 34 | update: ${OBJS} 35 | -mkdir fromdec 36 | cd fromdec; arff xf ${FLOPPY}; rm -f ${FROMDEC} ${OBJS} ${DEFBOO}; \ 37 | flcopy -t3 -f ${FLOPPY}; rm -f floppy; arff crf ${FLOPPY} * 38 | rm -rf fromdec 39 | arff rf ${FLOPPY} ${OBJS} 40 | -rm -f defboo.cmd 41 | 42 | defboo.cmd: 43 | @echo You must copy one of \{${DEFBOO}\} to defboo.cmd. 44 | @echo See installing and operating guide for details. 45 | @/bin/false #force exits 46 | 47 | clean: 48 | rm -f ${BOOTS} ${UTILS} floppy defboo.cmd 49 | rm -rf fromdec 50 | -------------------------------------------------------------------------------- /floppy/anyboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ANY DEVICE TO A SINGLE USER SHELL 3 | ! 4 | SET DEF HEX 5 | SET DEF LONG 6 | SET REL:0 7 | HALT 8 | UNJAM 9 | INIT 10 | LOAD BOOT 11 | D R11 3 ! 3=RB_ASKNAME+RB_SINGLE 12 | ! R10 NICHTS ! DEVICE CHOICE ISNT APPLICABLE 13 | START 2 14 | -------------------------------------------------------------------------------- /floppy/defboo.MS780C-interleaved: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP BY BOOT() SYSCALL 3 | ! GO MULTI-USER AFTER CHECKING; BOOT FROM DEFAULT DEVICE 4 | ! 5 | SET DEF HEX 6 | SET DEF LONG 7 | SET REL:0 8 | HALT 9 | UNJAM 10 | INIT 11 | D 20002000 101 12 | D 20004000 101 13 | D 20004004 4000 14 | LOAD BOOT 15 | D/G B 0 ! BOOT PARAMETERS: MULTI USER AFTER CHECK 16 | D/G A 0 ! DEV TO BOOT FROM (0=HP, 2=UP, 3=HK) 17 | START 2 18 | -------------------------------------------------------------------------------- /floppy/defboo.hk: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP BY BOOT() SYSCALL 3 | ! GO MULTI-USER AFTER CHECKING; BOOT FROM DEFAULT DEVICE 4 | ! 5 | SET DEF HEX 6 | SET DEF LONG 7 | SET REL:0 8 | HALT 9 | UNJAM 10 | INIT 11 | LOAD BOOT 12 | D/G B 0 ! BOOT PARAMETERS: MULTI USER AFTER CHECK 13 | D/G A 3 ! DEV TO BOOT FROM (0=HP, 2=UP, 3=HK, 9=RA) 14 | START 2 15 | -------------------------------------------------------------------------------- /floppy/defboo.hp: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP BY BOOT() SYSCALL 3 | ! GO MULTI-USER AFTER CHECKING; BOOT FROM DEFAULT DEVICE 4 | ! 5 | SET DEF HEX 6 | SET DEF LONG 7 | SET REL:0 8 | HALT 9 | UNJAM 10 | INIT 11 | LOAD BOOT 12 | D/G B 0 ! BOOT PARAMETERS: MULTI USER AFTER CHECK 13 | D/G A 0 ! DEV TO BOOT FROM (0=HP, 2=UP, 3=HK, 9=RA) 14 | START 2 15 | -------------------------------------------------------------------------------- /floppy/defboo.ra: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP BY BOOT() SYSCALL 3 | ! GO MULTI-USER AFTER CHECKING; BOOT FROM DEFAULT DEVICE 4 | ! 5 | SET DEF HEX 6 | SET DEF LONG 7 | SET REL:0 8 | HALT 9 | UNJAM 10 | INIT 11 | LOAD BOOT 12 | D/G B 0 ! BOOT PARAMETERS: MULTI USER AFTER CHECK 13 | D/G A 9 ! DEV TO BOOT FROM (0=HP, 2=UP, 3=HK, 9=RA) 14 | START 2 15 | -------------------------------------------------------------------------------- /floppy/defboo.up: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP BY BOOT() SYSCALL 3 | ! GO MULTI-USER AFTER CHECKING; BOOT FROM DEFAULT DEVICE 4 | ! 5 | SET DEF HEX 6 | SET DEF LONG 7 | SET REL:0 8 | HALT 9 | UNJAM 10 | INIT 11 | LOAD BOOT 12 | D/G B 0 ! BOOT PARAMETERS: MULTI USER AFTER CHECK 13 | D/G A 2 ! DEV TO BOOT FROM (0=HP, 2=UP, 3=HK, 9=RA) 14 | START 2 15 | -------------------------------------------------------------------------------- /floppy/hkmboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON HK, GOING MULTI USER 3 | ! 4 | SET DEF HEX 5 | SET DEF LONG 6 | SET REL:0 7 | HALT 8 | UNJAM 9 | INIT 10 | LOAD BOOT 11 | D R10 3 ! DEVICE CHOICE 3=HK 12 | D R11 0 ! 0= AUTOBOOT 13 | START 2 14 | -------------------------------------------------------------------------------- /floppy/hksboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON HK, LEAVING SINGLE USER 3 | ! 4 | SET DEF HEX 5 | SET DEF LONG 6 | SET REL:0 7 | HALT 8 | UNJAM 9 | INIT 10 | LOAD BOOT 11 | D R10 3 ! DEVICE CHOICE 3=HK 12 | D R11 2 ! 2= RB_SINGLE 13 | START 2 14 | -------------------------------------------------------------------------------- /floppy/hpmboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON RP, GOING MULTI USER 3 | ! 4 | SET DEF HEX 5 | SET DEF LONG 6 | SET REL:0 7 | HALT 8 | UNJAM 9 | INIT 10 | LOAD BOOT 11 | D R10 0 ! DEVICE CHOICE 0=HP 12 | D R11 0 ! 0= AUTOBOOT 13 | START 2 14 | -------------------------------------------------------------------------------- /floppy/hpsboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON RP, LEAVING SINGLE USER 3 | ! 4 | SET DEF HEX 5 | SET DEF LONG 6 | SET REL:0 7 | HALT 8 | UNJAM 9 | INIT 10 | LOAD BOOT 11 | D R10 0 ! DEVICE CHOICE 0=HP 12 | D R11 2 ! 2= RB_SINGLE 13 | START 2 14 | -------------------------------------------------------------------------------- /floppy/ramboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON UP, GOING MULTI USER 3 | ! 4 | SET DEF HEX 5 | SET DEF LONG 6 | SET REL:0 7 | HALT 8 | UNJAM 9 | INIT 10 | LOAD BOOT 11 | D R10 9 ! DEVICE CHOICE 9=RA 12 | D R11 0 ! 0= AUTOBOOT 13 | START 2 14 | -------------------------------------------------------------------------------- /floppy/rasboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON UP, LEAVING SINGLE USER 3 | ! 4 | SET DEF HEX 5 | SET DEF LONG 6 | SET REL:0 7 | HALT 8 | UNJAM 9 | INIT 10 | LOAD BOOT 11 | D R10 9 ! DEVICE CHOICE 9=RA 12 | D R11 2 ! 2= RB_SINGLE 13 | START 2 14 | -------------------------------------------------------------------------------- /floppy/restar.cmd: -------------------------------------------------------------------------------- 1 | ! RESTART COMMMAND FILE 2 | SET DEF HEX 3 | SET DEF LONG 4 | SET REL:0 5 | HALT ! HALT PROCESSOR 6 | UNJAM ! UNJAM SBI 7 | INIT ! INITIALIZE PROCESSOR 8 | D/I 11 20003800 ! SET SCBB TO ROM 9 | D/G 0 0 10 | D/G 1 3 ! UBA TR NUMBER 11 | D/G 2 0 12 | D/G 3 0 13 | D/G 4 0 14 | D/G 5 0 15 | D/G FP 0 16 | S 20003004 17 | -------------------------------------------------------------------------------- /floppy/upmboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON UP, GOING MULTI USER 3 | ! 4 | SET DEF HEX 5 | SET DEF LONG 6 | SET REL:0 7 | HALT 8 | UNJAM 9 | INIT 10 | LOAD BOOT 11 | D R10 2 ! DEVICE CHOICE 2=UP 12 | D R11 0 ! 0= AUTOBOOT 13 | START 2 14 | -------------------------------------------------------------------------------- /floppy/upsboo.cmd: -------------------------------------------------------------------------------- 1 | ! 2 | ! BOOTSTRAP ON UP, LEAVING SINGLE USER 3 | ! 4 | SET DEF HEX 5 | SET DEF LONG 6 | SET REL:0 7 | HALT 8 | UNJAM 9 | INIT 10 | LOAD BOOT 11 | D R10 2 ! DEVICE CHOICE 2=UP 12 | D R11 2 ! 2= RB_SINGLE 13 | START 2 14 | -------------------------------------------------------------------------------- /floppy/utboot.cmd: -------------------------------------------------------------------------------- 1 | SET DEF HEX 2 | SET DEF LONG 3 | SET REL:0 4 | HALT 5 | UNJAM 6 | INIT 7 | D/P 200 0036EFD0 8 | D + D0510000 9 | D + 2000008F 10 | D + 0800C180 11 | D + 0804C1D4 12 | D + 0026EFD0 13 | D + C8520000 14 | D + 00F5208F 15 | D + 8FB05200 16 | D + 1AA204C0 17 | 02008fae 8fae06a2 18 | 0000060 02a20100 b004a2b4 00006239 20006000 19 | 0000100 2013e000 20 | 0000104 21 | -------------------------------------------------------------------------------- /h/clist.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * Copyright (c) 1982 Regents of the University of California. 30 | * All rights reserved. The Berkeley software License Agreement 31 | * specifies the terms and conditions for redistribution. 32 | * 33 | * @(#)clist.h 6.2 (Berkeley) 6/8/85 34 | */ 35 | 36 | /* 37 | * Raw structures for the character list routines. 38 | */ 39 | struct cblock { 40 | struct cblock *c_next; 41 | char c_info[CBSIZE]; 42 | }; 43 | #ifdef KERNEL 44 | struct cblock *cfree; 45 | int nclist; 46 | struct cblock *cfreelist; 47 | int cfreecount; 48 | #endif 49 | -------------------------------------------------------------------------------- /h/mach_param.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * File: h/mach_param.h 30 | * Author: Avadis Tevanian, Jr., Michael Wayne Young 31 | * 32 | * Copyright (C) 1986, Avadis Tevanian, Jr., Michael Wayne Young 33 | * 34 | * Mach system sizing parameters 35 | * 36 | * HISTORY 37 | * 29-Jan-86 Michael Young (mwyoung) at Carnegie-Mellon University 38 | * Created 39 | * 40 | */ 41 | 42 | #ifndef _MACH_PARAM_ 43 | #define _MACH_PARAM_ 44 | 45 | #define THREAD_MAX 500 /* Max number of threads */ 46 | #define THREAD_CHUNK 10 /* Allocation chunk */ 47 | 48 | #define TASK_MAX 500 /* Max number of tasks */ 49 | #define TASK_CHUNK 10 /* Allocation chunk */ 50 | 51 | #endif _MACH_PARAM_ 52 | -------------------------------------------------------------------------------- /h/port.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | 29 | /* 30 | * Kernel definition of a port. 31 | * 32 | * HISTORY 33 | * 8-May-86 Michael Young (mwyoung) at Carnegie-Mellon University 34 | * Created 35 | * 36 | */ 37 | 38 | #ifndef _PORT_ 39 | #define _PORT_ 40 | 41 | typedef int port_t; 42 | typedef port_t *port_array_t; 43 | 44 | #define PORT_NULL ((port_t) 0) 45 | 46 | #endif _PORT_ 47 | -------------------------------------------------------------------------------- /h/shared_memory.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /*CMU: %M% %I% %G% */ 29 | 30 | /* ************************************************************************ * 31 | * stripped version of mp/mp_shmem.h that needs no other include files 32 | * ************************************************************************ */ 33 | 34 | struct shm_stat { 35 | int sh_shm_init; 36 | int sh_acc_init; 37 | int sh_reboot; 38 | int sh_sem_init; 39 | int sh_time_keeper; 40 | int sh_tick; 41 | int fill[4]; 42 | 43 | int *sh_map; 44 | unsigned long sh_phys; 45 | char *sh_utl; 46 | char *sh_utlst; 47 | int sh_memrm_busy; 48 | }; 49 | -------------------------------------------------------------------------------- /h/table.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* table.h CMU 03/30/83 */ 29 | 30 | /* 31 | ********************************************************************** 32 | * HISTORY 33 | * 30-Aug-85 Mike Accetta (mja) at Carnegie-Mellon University 34 | * Added TBL_U_TTYD. 35 | * [V1(1)] 36 | * 37 | * 30-Mar-83 Mike Accetta (mja) at Carnegie-Mellon University 38 | * Created (V3.06h). 39 | * 40 | ********************************************************************** 41 | */ 42 | 43 | #define TBL_TTYLOC 0 /* index by device number */ 44 | #define TBL_U_TTYD 1 /* index by process ID */ 45 | -------------------------------------------------------------------------------- /h/tags: -------------------------------------------------------------------------------- 1 | ../sys/tags -------------------------------------------------------------------------------- /h/timeb.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * Copyright (c) 1982 Regents of the University of California. 30 | * All rights reserved. The Berkeley software License Agreement 31 | * specifies the terms and conditions for redistribution. 32 | * 33 | * @(#)timeb.h 6.2 (Berkeley) 6/8/85 34 | */ 35 | 36 | /* 37 | * Structure returned by ftime system call 38 | */ 39 | struct timeb 40 | { 41 | time_t time; 42 | unsigned short millitm; 43 | short timezone; 44 | short dstflag; 45 | }; 46 | -------------------------------------------------------------------------------- /h/times.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * Copyright (c) 1982 Regents of the University of California. 30 | * All rights reserved. The Berkeley software License Agreement 31 | * specifies the terms and conditions for redistribution. 32 | * 33 | * @(#)times.h 6.2 (Berkeley) 6/8/85 34 | */ 35 | 36 | /* 37 | * Structure returned by times() 38 | */ 39 | struct tms { 40 | time_t tms_utime; /* user time */ 41 | time_t tms_stime; /* system time */ 42 | time_t tms_cutime; /* user time, children */ 43 | time_t tms_cstime; /* system time, children */ 44 | }; 45 | -------------------------------------------------------------------------------- /h/un.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * Copyright (c) 1982 Regents of the University of California. 30 | * All rights reserved. The Berkeley software License Agreement 31 | * specifies the terms and conditions for redistribution. 32 | * 33 | * @(#)un.h 6.3 (Berkeley) 6/8/85 34 | */ 35 | 36 | /* 37 | * Definitions for UNIX IPC domain. 38 | */ 39 | struct sockaddr_un { 40 | short sun_family; /* AF_UNIX */ 41 | char sun_path[108]; /* path name (gag) */ 42 | }; 43 | 44 | #ifdef KERNEL 45 | int unp_discard(); 46 | #endif 47 | -------------------------------------------------------------------------------- /h/uproc.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* header file for parallel proc table structure */ 29 | 30 | /* timerec contains a timestamp and a timevalue */ 31 | struct timerec { 32 | long tr_timestamp; /* last timestamp -- routines in locore.s 33 | know this comes first */ 34 | struct timeval tr_elapsed; /* elapsed user time */ 35 | }; 36 | 37 | 38 | struct uproc { 39 | struct timerec up_utime; /* user time holder */ 40 | short up_pid; /* unique pid */ 41 | }; 42 | 43 | #ifdef KERNEL 44 | struct uproc *uproc,*uprocNPROC; 45 | #endif 46 | -------------------------------------------------------------------------------- /h/utime.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * File: h/utime.h 30 | * Author: Avadis Tevanian, Jr. 31 | * 32 | * Header file for user timing facility. 33 | * 34 | * HISTORY 35 | * 8-Jan-86 Avadis Tevanian (avie) at Carnegie-Mellon University 36 | * Created. 37 | */ 38 | 39 | /* 40 | * Possible modes for timing. 41 | */ 42 | 43 | #define STATISTICAL 0 44 | #define TIMESTAMP 1 45 | #define TIMESTAMP_UNAVAILABLE 2 46 | -------------------------------------------------------------------------------- /h/vcmd.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * Copyright (c) 1982 Regents of the University of California. 30 | * All rights reserved. The Berkeley software License Agreement 31 | * specifies the terms and conditions for redistribution. 32 | * 33 | * @(#)vcmd.h 6.3 (Berkeley) 6/8/85 34 | */ 35 | 36 | #ifndef _IOCTL_ 37 | #ifdef KERNEL 38 | #include "ioctl.h" 39 | #else 40 | #include 41 | #endif 42 | #endif 43 | 44 | #define VPRINT 0100 45 | #define VPLOT 0200 46 | #define VPRINTPLOT 0400 47 | 48 | #define VGETSTATE _IOR(v, 0, int) 49 | #define VSETSTATE _IOW(v, 1, int) 50 | -------------------------------------------------------------------------------- /h/vmparam.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * Copyright (c) 1982 Regents of the University of California. 30 | * All rights reserved. The Berkeley software License Agreement 31 | * specifies the terms and conditions for redistribution. 32 | * 33 | * @(#)vmparam.h 6.3 (Berkeley) 6/8/85 34 | */ 35 | 36 | /* 37 | * Machine dependent constants 38 | */ 39 | #ifdef KERNEL 40 | #include "../machine/vmparam.h" 41 | #else 42 | #include 43 | #endif 44 | 45 | #if defined(KERNEL) && !defined(LOCORE) 46 | int klseql; 47 | int klsdist; 48 | int klin; 49 | int kltxt; 50 | int klout; 51 | #endif 52 | -------------------------------------------------------------------------------- /kern/Mach.h: -------------------------------------------------------------------------------- 1 | #ifndef _Mach 2 | #define _Mach 1 3 | 4 | /* Module Mach */ 5 | /* 6 | * WARNING FROM MATCHMAKER 7 | */ 8 | #include "AccentType.h" 9 | 10 | extern void InitMach () ; 11 | 12 | #include "mach_types.h" 13 | 14 | extern kern_return_t port_allocate ( ); 15 | 16 | extern kern_return_t port_deallocate ( ); 17 | 18 | extern kern_return_t port_enable ( ); 19 | 20 | extern kern_return_t port_disable ( ); 21 | 22 | extern kern_return_t port_select ( ); 23 | 24 | extern kern_return_t port_set_backlog ( ); 25 | 26 | extern kern_return_t port_status ( ); 27 | 28 | extern kern_return_t task_create ( ); 29 | 30 | extern kern_return_t task_terminate ( ); 31 | 32 | extern kern_return_t task_suspend ( ); 33 | 34 | extern kern_return_t task_resume ( ); 35 | 36 | extern kern_return_t task_threads ( ); 37 | 38 | extern kern_return_t task_ports ( ); 39 | 40 | extern kern_return_t task_status ( ); 41 | 42 | extern kern_return_t task_set_notify ( ); 43 | 44 | extern kern_return_t thread_create ( ); 45 | 46 | extern kern_return_t thread_terminate ( ); 47 | 48 | extern kern_return_t thread_suspend ( ); 49 | 50 | extern kern_return_t thread_resume ( ); 51 | 52 | extern kern_return_t thread_status ( ); 53 | 54 | extern kern_return_t thread_mutate ( ); 55 | 56 | extern kern_return_t vm_allocate ( ); 57 | 58 | extern kern_return_t vm_allocate_with_pager ( ); 59 | 60 | extern kern_return_t vm_deallocate ( ); 61 | 62 | extern kern_return_t vm_protect ( ); 63 | 64 | extern kern_return_t vm_inherit ( ); 65 | 66 | extern kern_return_t vm_read ( ); 67 | 68 | extern kern_return_t vm_write ( ); 69 | 70 | extern kern_return_t vm_copy ( ); 71 | 72 | extern kern_return_t vm_regions ( ); 73 | 74 | extern kern_return_t vm_statistics ( ); 75 | 76 | extern kern_return_t pager_clean ( ); 77 | 78 | extern kern_return_t pager_fetch ( ); 79 | 80 | #endif _Mach 81 | -------------------------------------------------------------------------------- /kern/Makefile: -------------------------------------------------------------------------------- 1 | MACH_INTERFACE = mach.h mach_server.c mach_user.c 2 | 3 | PAGER_INTERFACE = pager.h pager_server.c pager_user.c 4 | 5 | all: ${MACH_INTERFACE} ${PAGER_INTERFACE} 6 | 7 | mach.h: Mach.h 8 | cp Mach.h mach.h 9 | 10 | mach_server.c: MachServer.c mach_server.sed 11 | sed -f mach_server.sed < MachServer.c > mach_server.c 12 | 13 | mach_user.c: MachUser.c mach_user.sed 14 | sed -f mach_user.sed < MachUser.c > mach_user.c 15 | 16 | Mach.h MachServer.c MachUser.c: mach.defs 17 | mm mach.defs c c 18 | 19 | pager.h: Pager.h 20 | cp Pager.h pager.h 21 | 22 | pager_server.c: PagerServer.c pager_server.sed 23 | sed -f pager_server.sed < PagerServer.c > pager_server.c 24 | 25 | pager_user.c: PagerUser.c pager_user.sed 26 | sed -f pager_user.sed < PagerUser.c > pager_user.c 27 | 28 | Pager.h PagerServer.c PagerUser.c: pager.defs 29 | mm pager.defs c c 30 | -------------------------------------------------------------------------------- /kern/Pager.h: -------------------------------------------------------------------------------- 1 | #ifndef _Pager 2 | #define _Pager 1 3 | 4 | /* Module Pager */ 5 | /* 6 | * WARNING FROM MATCHMAKER 7 | */ 8 | #include "AccentType.h" 9 | 10 | extern void InitPager () ; 11 | 12 | #include "mach_types.h" 13 | 14 | extern void pager_init ( ); 15 | 16 | extern boolean_t pager_read ( ); 17 | 18 | extern boolean_t pager_write ( ); 19 | 20 | #endif _Pager 21 | -------------------------------------------------------------------------------- /kern/iprintf.c: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | # 29 | int indent = 0; 30 | 31 | /*VARARGS*/ 32 | iprintf(a, b, c, d, e, f, g, h) 33 | { 34 | register int i; 35 | 36 | for (i = indent; i > 0;){ 37 | if (i >= 8) { 38 | putchar('\t'); 39 | i -= 8; 40 | } 41 | else { 42 | putchar(' '); 43 | i--; 44 | } 45 | } 46 | 47 | printf(a, b, c, d, e, f, g, h); 48 | } 49 | -------------------------------------------------------------------------------- /kern/mach.h: -------------------------------------------------------------------------------- 1 | #ifndef _Mach 2 | #define _Mach 1 3 | 4 | /* Module Mach */ 5 | /* 6 | * WARNING FROM MATCHMAKER 7 | */ 8 | #include "AccentType.h" 9 | 10 | extern void InitMach () ; 11 | 12 | #include "mach_types.h" 13 | 14 | extern kern_return_t port_allocate ( ); 15 | 16 | extern kern_return_t port_deallocate ( ); 17 | 18 | extern kern_return_t port_enable ( ); 19 | 20 | extern kern_return_t port_disable ( ); 21 | 22 | extern kern_return_t port_select ( ); 23 | 24 | extern kern_return_t port_set_backlog ( ); 25 | 26 | extern kern_return_t port_status ( ); 27 | 28 | extern kern_return_t task_create ( ); 29 | 30 | extern kern_return_t task_terminate ( ); 31 | 32 | extern kern_return_t task_suspend ( ); 33 | 34 | extern kern_return_t task_resume ( ); 35 | 36 | extern kern_return_t task_threads ( ); 37 | 38 | extern kern_return_t task_ports ( ); 39 | 40 | extern kern_return_t task_status ( ); 41 | 42 | extern kern_return_t task_set_notify ( ); 43 | 44 | extern kern_return_t thread_create ( ); 45 | 46 | extern kern_return_t thread_terminate ( ); 47 | 48 | extern kern_return_t thread_suspend ( ); 49 | 50 | extern kern_return_t thread_resume ( ); 51 | 52 | extern kern_return_t thread_status ( ); 53 | 54 | extern kern_return_t thread_mutate ( ); 55 | 56 | extern kern_return_t vm_allocate ( ); 57 | 58 | extern kern_return_t vm_allocate_with_pager ( ); 59 | 60 | extern kern_return_t vm_deallocate ( ); 61 | 62 | extern kern_return_t vm_protect ( ); 63 | 64 | extern kern_return_t vm_inherit ( ); 65 | 66 | extern kern_return_t vm_read ( ); 67 | 68 | extern kern_return_t vm_write ( ); 69 | 70 | extern kern_return_t vm_copy ( ); 71 | 72 | extern kern_return_t vm_regions ( ); 73 | 74 | extern kern_return_t vm_statistics ( ); 75 | 76 | extern kern_return_t pager_clean ( ); 77 | 78 | extern kern_return_t pager_fetch ( ); 79 | 80 | #endif _Mach 81 | -------------------------------------------------------------------------------- /kern/mach_server.sed: -------------------------------------------------------------------------------- 1 | s/task_t Arg/port_t Arg/ 2 | s/thread_t Arg/port_t Arg/ 3 | s/convert_port\(.*\)LocalPort/convert_port\1RemotePort/ 4 | s/AccentType/..\/accent\/accenttype/ 5 | s/mach_if\.h/..\/kern\/mach_if.h/ 6 | s/accent\.h/..\/accent\/accent.h/ 7 | s/MachServer/mach_server/ 8 | / /d 9 | -------------------------------------------------------------------------------- /kern/mach_user.sed: -------------------------------------------------------------------------------- 1 | 1,/ServPort/c\ 2 | #include "mach.h"\ 3 | #include "mach_msg.h"\ 4 | \ 5 | #define FastAssign 1\ 6 | #define TypeCheck 1\ 7 | \ 8 | static port_t mach_reply_port;\ 9 | static GeneralReturn GR;\ 10 | \ 11 | \ 12 | void InitMach (reply_port)\ 13 | port_t reply_port;\ 14 | {\ 15 | port_t tmp_reply_port;\ 16 | kern_return_t result;\ 17 | \ 18 | if (reply_port != PORT_NULL)\ 19 | mach_reply_port = reply_port;\ 20 | else if ((result = port_allocate(task_self(), &tmp_reply_port)) == KERN_SUCCESS)\ 21 | mach_reply_port = tmp_reply_port;\ 22 | }\ 23 | \ 24 | kern_return_t port_allocate ( ServPort,my_port) 25 | s/ReplyPort/mach_reply_port/ 26 | s/TRUE/1/ 27 | s/FALSE/0/ 28 | -------------------------------------------------------------------------------- /kern/pager.h: -------------------------------------------------------------------------------- 1 | #ifndef _Pager 2 | #define _Pager 1 3 | 4 | /* Module Pager */ 5 | /* 6 | * WARNING FROM MATCHMAKER 7 | */ 8 | #include "AccentType.h" 9 | 10 | extern void InitPager () ; 11 | 12 | #include "mach_types.h" 13 | 14 | extern void pager_init ( ); 15 | 16 | extern boolean_t pager_read ( ); 17 | 18 | extern boolean_t pager_write ( ); 19 | 20 | #endif _Pager 21 | -------------------------------------------------------------------------------- /kern/pager_server.sed: -------------------------------------------------------------------------------- 1 | s/AccentType/..\/accent\/accenttype/ 2 | s/mach_if\.h/..\/kern\/mach_if.h/ 3 | s/accent\.h/..\/accent\/accent.h/ 4 | s/PagerServer/pager_server/ 5 | / /d 6 | -------------------------------------------------------------------------------- /kern/pager_user.sed: -------------------------------------------------------------------------------- 1 | s/InitPager/init_pager/ 2 | s/Send/KSend/ 3 | s/Receive/KReceive/ 4 | s/MsgError(GR)/return(FALSE)/ 5 | s/MsgError(BadReply)/return(FALSE)/ 6 | / /d 7 | -------------------------------------------------------------------------------- /kern/request.defs: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/neozeed/Mach86/2b3d13a2f662d651b29856789336f38bf6756a00/kern/request.defs -------------------------------------------------------------------------------- /machine: -------------------------------------------------------------------------------- 1 | vax -------------------------------------------------------------------------------- /mdec/httoggle.s: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1980, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | */ 6 | 7 | #ifndef lint 8 | _sccsid:.asciz "@(#)httoggle.s 7.1 (Berkeley) 6/5/86" 9 | #endif not lint 10 | 11 | 12 | /* 13 | * Prototype toggle in bootstrap code for ht type tapes. 14 | * If on anything but a 780 with a tape at slave 1 of mba 1 15 | * this will have to be repaired by patching mba and ht. 16 | */ 17 | movl mba,r10 18 | mull3 ht,$0x80,r11 19 | addl3 r11,r10,r11 20 | addl2 $0x400,r11 21 | movl $1,4(r10) 22 | movl $9,(r11) 23 | cvtwl $012300,0x24(r11) 24 | clrl 12(r10) 25 | movl $0x80000000,0x800(r10) 26 | cvtwl $-512,16(r10) 27 | movl $0x39,(r11) 28 | halt 29 | .align 2 30 | mba: .long 0x20012000 31 | ht: .long 0 32 | -------------------------------------------------------------------------------- /mdec/installboot.c: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1980, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | */ 6 | 7 | #ifndef lint 8 | char copyright[] = 9 | "@(#) Copyright (c) 1980, 1986 Regents of the University of California.\n\ 10 | All rights reserved.\n"; 11 | #endif not lint 12 | 13 | #ifndef lint 14 | static char sccsid[] = "@(#)installboot.c 7.1 (Berkeley) 6/5/86"; 15 | #endif not lint 16 | 17 | #include "../h/param.h" 18 | #include "../h/fs.h" 19 | 20 | char bootimage[BBSIZE]; 21 | 22 | main(argc, argv) 23 | int argc; 24 | char *argv[]; 25 | { 26 | int fd; 27 | 28 | if (argc != 4) { 29 | printf("Usage: installboot bootblock bootprog device\n"); 30 | exit(1); 31 | } 32 | fd = open(argv[1], 0); 33 | if (fd < 0) { 34 | perror(argv[1]); 35 | exit(1); 36 | } 37 | read(fd, bootimage, DEV_BSIZE); 38 | close(fd); 39 | fd = open(argv[2], 0); 40 | if (fd < 0) { 41 | perror(argv[2]); 42 | exit(1); 43 | } 44 | read(fd, &bootimage[DEV_BSIZE], BBSIZE - DEV_BSIZE); 45 | close(fd); 46 | fd = open(argv[3], 1); 47 | if (fd < 0) { 48 | perror(argv[3]); 49 | exit(1); 50 | } 51 | write(fd, bootimage, BBSIZE); 52 | close(fd); 53 | } 54 | -------------------------------------------------------------------------------- /mdec/mttoggle.s: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1980, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | */ 6 | 7 | #ifndef lint 8 | _sccsid:.asciz "@(#)mttoggle.s 7.1 (Berkeley) 6/5/86" 9 | #endif not lint 10 | 11 | /* 12 | * Prototype toggle in bootstrap code for mt type tapes. 13 | * If on anything but a 780 with a tape at drive 0 of mba 1 14 | * this will have to be repaired by patching mba and mt. 15 | */ 16 | movl mba,r10 17 | mull3 mt,$0x80,r11 18 | addl3 r11,r10,r11 19 | addl2 $0x400,r11 20 | movzbl $1,4(r10) 21 | movzbl $4,8(r11) /* drive zero, one record */ 22 | clrl 12(r10) /* set address to zero */ 23 | movl $0x80000000,0x800(r10) /* validate map register */ 24 | cvtwl $-512,16(r10) /* set byte count */ 25 | movzwl $512,20(r11) /* set byte count */ 26 | 0: 27 | movl 0x44(r11),r0 28 | bbc $15,r0,0b 29 | movzbl $071,(r11) /* read forward, go */ 30 | halt 31 | .align 2 32 | mba: .long 0x20012000 33 | mt: .long 0 34 | -------------------------------------------------------------------------------- /mdec/tmtoggle.s: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1980, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | */ 6 | 7 | #ifndef lint 8 | _sccsid:.asciz "@(#)tmtoggle.s 7.1 (Berkeley) 6/5/86" 9 | #endif not lint 10 | 11 | /* 12 | * Prototype toggle in bootstrap code for tm type tapes. 13 | * If on anything but a 780 with the drive on uba0 14 | * this will have to be repaired by patching uba and umem. 15 | */ 16 | begin: 17 | movl uba,r1 18 | movl $0x80200000,0x800(r1) 19 | clrl 0x804(r1) 20 | movl umem,r2 21 | bisl2 $0172520,r2 22 | mnegw $512,4(r2) 23 | clrw 6(r2) 24 | movw $03,2(r2) 25 | halt 26 | .align 2 27 | uba: .long 0x20006000 28 | umem: .long 0x2013e000 29 | -------------------------------------------------------------------------------- /mdec/tstoggle.s: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1980, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | */ 6 | 7 | #ifndef lint 8 | _sccsid:.asciz "@(#)tstoggle.s 7.1 (Berkeley) 6/5/86" 9 | #endif not lint 10 | 11 | /* 12 | * Prototype toggle in bootstrap code for ts type tapes. 13 | * If on anything but a 780 with the drive on uba0 14 | * this will have to be repaired by patching uba and umem. 15 | */ 16 | .set UBA0,0x20006000 17 | .set UMEM0,0x2013e000 18 | .set UBA_MAP,0x800 19 | .set TSADDR,0772520-0760000 20 | 21 | start: 22 | movl uba,r10 23 | movl mrv,UBA_MAP(r10) 24 | addl3 mrv,$1,UBA_MAP+4(r10) 25 | addl3 umem,$TSADDR,r11 26 | clrw 2(r11) 27 | 1: tstb 2(r11) 28 | bgeq 1b 29 | movw $0x200+setchr,(r11) 30 | 1: tstb 2(r11) 31 | bgeq 1b 32 | movw $0x200+read,(r11) 33 | halt 34 | .align 2 35 | uba: .long UBA0 36 | umem: .long UMEM0 37 | mrv: .long 0x80000000 38 | setchr: .word 0xc004,0x200+char,0,0x8 # set characteristics command 39 | char: .word 0x200+status,0,0xe,0 # characteristics 40 | read: .word 0xc001,0,0,0x200 # read command 41 | status: 42 | -------------------------------------------------------------------------------- /mdec/uttoggle.s: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1980, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | */ 6 | 7 | #ifndef lint 8 | _sccsid:.asciz "@(#)uttoggle.s 7.1 (Berkeley) 6/5/86" 9 | #endif not lint 10 | 11 | /* 12 | * Prototype toggle in bootstrap code for ut type tapes. 13 | * If on anything but a 780 with the drive on uba0 14 | * this will have to be repaired by patching uba and umem. 15 | */ 16 | begin: 17 | movl uba,r1 18 | movl $0x80200000,0x800(r1) 19 | clrl 0x804(r1) 20 | movl umem,r2 21 | bisl2 $0172440,r2 22 | movw $0x04c0,26(r2) /* set tape density & format */ 23 | mnegw $512,6(r2) /* set frame count */ 24 | mnegw $256,2(r2) /* set word count */ 25 | clrw 4(r2) /* set bus address */ 26 | movw $0x39,(r2) /* set command and go */ 27 | halt 28 | .align 2 29 | uba: .long 0x20006000 30 | umem: .long 0x2013e000 31 | -------------------------------------------------------------------------------- /mp/imc.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * File: imc.h 30 | * Author: Avadis Tevanian, Jr. 31 | * 32 | * Copyright (C) 1985, Avadis Tevanian, Jr. 33 | * 34 | * InterMachine Communication (IMC) header file. 35 | * 36 | * HISTORY 37 | * 16-Jan-85 Avadis Tevanian (avie) at Carnegie-Mellon University 38 | * Created 39 | * 40 | */ 41 | 42 | #define IMC_PORTS 20 /* number of IMC ports */ 43 | 44 | #define IMC_BUFFERSIZE 512 /* buffer size for packets */ 45 | -------------------------------------------------------------------------------- /mp/makefile: -------------------------------------------------------------------------------- 1 | .c.o : 2 | cc -c -DKERNEL -I. -I../WB $< 3 | 4 | all : kern_smalloc.o mp_sys.o remote_subr.o syscall_subr.o\ 5 | mp_queue.o mp_sysent.o remote_sw.o syscall_sw.o\ 6 | mp_shmem.o remote_prim.o sem_sem.o 7 | -------------------------------------------------------------------------------- /net/tags: -------------------------------------------------------------------------------- 1 | ../sys/tags -------------------------------------------------------------------------------- /netimp/tags: -------------------------------------------------------------------------------- 1 | ../sys/tags -------------------------------------------------------------------------------- /netinet/tags: -------------------------------------------------------------------------------- 1 | ../sys/tags -------------------------------------------------------------------------------- /netinet/udp.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * Copyright (c) 1982 Regents of the University of California. 30 | * All rights reserved. The Berkeley software License Agreement 31 | * specifies the terms and conditions for redistribution. 32 | * 33 | * @(#)udp.h 6.2 (Berkeley) 6/8/85 34 | */ 35 | 36 | /* 37 | * Udp protocol header. 38 | * Per RFC 768, September, 1981. 39 | */ 40 | struct udphdr { 41 | u_short uh_sport; /* source port */ 42 | u_short uh_dport; /* destination port */ 43 | short uh_ulen; /* udp length */ 44 | u_short uh_sum; /* udp checksum */ 45 | }; 46 | -------------------------------------------------------------------------------- /netns/r: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/neozeed/Mach86/2b3d13a2f662d651b29856789336f38bf6756a00/netns/r -------------------------------------------------------------------------------- /netns/tags: -------------------------------------------------------------------------------- 1 | ../sys/tags -------------------------------------------------------------------------------- /oaccent/systype.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * Module SysType 30 | * 31 | * Author: Michael Wayne Young 32 | * Purpose: Define system type 33 | * 34 | * History: 35 | * 36 | * 24-Oct-85 Michael B. Jones 37 | * Removed machine name #defines since they are in machdep.h. 38 | * 39 | * Michael W. Young 40 | * Created. 41 | * 42 | */ 43 | 44 | #ifndef _SysType 45 | #define _SysType 46 | 47 | #define NATIVE_ACCENT 1 48 | #define SPOONIX 0 49 | #endif _SysType 50 | 51 | -------------------------------------------------------------------------------- /sensor/fork_sensor.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | #ifdef KERNEL 29 | #include "../sensor/mondefs.h" 30 | #include "../sensor/montypes.h" 31 | #endif 32 | #ifndef ntohs 33 | #include "../netinet/in.h" 34 | #endif 35 | 36 | #if NWB_SENS > 0 37 | #define kern_fork_sensor \ 38 | if (*(mon_enablevector + 0) & (1 << 11)) { \ 39 | mon_printf (("doing fork\n")); \ 40 | } 41 | #else NWB_SENS > 0 42 | #define kern_fork_sensor 43 | #endif NWB_SENS > 0 44 | -------------------------------------------------------------------------------- /sensor/monerrcds.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | #define MON_ALRDY_INIT -1 29 | #define MON_NOT_INIT -2 30 | #define MON_BUFF_FULL -3 31 | #define MON_REQ_NOT_FND -4 32 | #define MON_NOT_ACCTNT -5 33 | #define MON_REQ_OFLOW -6 34 | #define MON_INV_CMD -7 35 | #define MON_SYS_ERR -8 36 | #define MON_CONCURRENCY_ERR -9 37 | -------------------------------------------------------------------------------- /sensor/monops.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | #define MONOP_INIT 1 29 | #define MONOP_PUTEVENT_INT 2 30 | #define MONOP_PUTEVENT_EXT 3 31 | #define MONOP_GETEVENTS 4 32 | #define MONOP_PUTREQ 5 33 | #define MONOP_GETREQ 6 34 | #define MONOP_SHUTDOWN 7 35 | #define MONOP_OFLOW 8 36 | #define MONOP_NO_REQ 9 37 | 38 | #define MONOP(o, l) ((short) (o | (l << 8))) 39 | -------------------------------------------------------------------------------- /sensor/syslocal.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | -------------------------------------------------------------------------------- /src/config/Makefile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 1980 Regents of the University of California. 3 | # All rights reserved. The Berkeley software License Agreement 4 | # specifies the terms and conditions for redistribution. 5 | # 6 | # @(#)Makefile 5.1 (Berkeley) 5/8/85 7 | # 8 | # 9 | CFILES= y.tab.c main.c lex.yy.c mkioconf.c mkmakefile.c \ 10 | mkubglue.c mkheaders.c mkswapconf.c 11 | OBJS= y.tab.o main.o lex.yy.o mkioconf.o mkmakefile.o \ 12 | mkubglue.o mkheaders.o mkswapconf.o 13 | 14 | CFLAGS=-O 15 | LDFLAGS=-ll 16 | 17 | config: ${OBJS} 18 | ${CC} ${OBJS} -o config ${LDFLAGS} 19 | 20 | lex.yy.c: config.l 21 | lex config.l 22 | 23 | y.tab.h: 24 | yacc -d config.y 25 | 26 | y.tab.c: config.y 27 | yacc config.y 28 | 29 | clean: 30 | rm -f ${OBJS} lex.yy.c y.tab.c y.tab.h config 31 | 32 | install: 33 | install -s config ../../conf/config 34 | 35 | lint: ${CFILES} 36 | lint ${CFILES} 37 | 38 | depend: 39 | grep '^#include' ${CFILES} | grep -v '<' | \ 40 | sed -e 's/:[^"]*"\([^"]*\)".*/: \1/' \ 41 | -e 's/\.c/.o/' \ 42 | -e 's,../[a-zA-Z]*/,,' | \ 43 | awk ' { if ($$1 != prev) { print rec; rec = $$0; prev = $$1; } \ 44 | else { if (length(rec $$2) > 78) { print rec; rec = $$0; } \ 45 | else rec = rec " " $$2 } } \ 46 | END { print rec } ' > makedep 47 | echo '$$r makedep' >>eddep 48 | echo '/^# DO NOT DELETE THIS LINE/+1,$$d' >eddep 49 | echo '$$r makedep' >>eddep 50 | echo 'w' >>eddep 51 | cp Makefile Makefile.bak 52 | ed - Makefile < eddep 53 | rm eddep makedep 54 | 55 | # DO NOT DELETE THIS LINE -- make depend uses it 56 | 57 | y.tab.o: config.h 58 | main.o: y.tab.h config.h 59 | lex.yy.o: y.tab.h config.h 60 | mkioconf.o: y.tab.h config.h 61 | mkmakefile.o: y.tab.h config.h 62 | mkubglue.o: config.h y.tab.h 63 | mkheaders.o: config.h y.tab.h 64 | mkswapconf.o: config.h 65 | -------------------------------------------------------------------------------- /src/config/newvers.sh: -------------------------------------------------------------------------------- 1 | #!/bin/sh - 2 | # 3 | # Copyright (c) 1980 Regents of the University of California. 4 | # All rights reserved. The Berkeley software License Agreement 5 | # specifies the terms and conditions for redistribution. 6 | # 7 | # @(#)newvers.sh 5.1 (Berkeley) 5/8/85 8 | # 9 | touch version 10 | awk ' { version = $1 + 1; }\ 11 | END { printf "char *version = \"Berkeley VAX/UNIX Version 4.%d ", version > "vers.c";\ 12 | printf "%d\n", version > "version"; }' < version 13 | echo `date`'\n";' >> vers.c 14 | -------------------------------------------------------------------------------- /src/kdb/chksym: -------------------------------------------------------------------------------- 1 | #!/bin/csh -fx 2 | set OBJS=(access.o command.o expr.o format.o input.o main.o message.o opset.o optab.o output.o pcs.o print.o reset.o runpcs.o setup.o sym.o) 3 | 4 | set COMMON=c.tmp 5 | set USED=u.tmp 6 | nm -pg message.o | sed -n -e 's;^.........C ;;p' | sort >${COMMON} 7 | ld $OBJS 8 | nm -pg | sed -n -e 's;^.......... ;;p' | sort >${USED} 9 | sed <${USED} -e '/^_kdb/d' | comm -23 - ${COMMON} 10 | -------------------------------------------------------------------------------- /src/kdb/head.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* head.h 4.1 81/05/14 */ 29 | 30 | ADDR maxoff; 31 | ADDR localval; 32 | 33 | struct nlist *symtab, *esymtab; 34 | struct nlist *cursym; 35 | struct nlist *lookup(); 36 | 37 | struct exec filhdr; 38 | 39 | long var[36]; 40 | 41 | int xargc; 42 | 43 | MAP txtmap; 44 | MAP datmap; 45 | INT wtflag; 46 | INT fcor; 47 | INT fsym; 48 | L_INT maxfile; 49 | L_INT maxstor; 50 | INT signo; 51 | 52 | union { 53 | struct user U; 54 | char UU[ctob(UPAGES)]; 55 | } udot; 56 | #define u udot.U 57 | 58 | char *corfil, *symfil; 59 | 60 | -------------------------------------------------------------------------------- /src/kdb/machine/foo.901: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/neozeed/Mach86/2b3d13a2f662d651b29856789336f38bf6756a00/src/kdb/machine/foo.901 -------------------------------------------------------------------------------- /src/kdb/pcs.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * 6-jan-86 David Golub (dbg) 30 | * declarations for new single-step features 31 | * 32 | */ 33 | 34 | int sstepmode; 35 | int icount; 36 | 37 | #define STEP_NONE 0 38 | #define STEP_NORM 1 39 | #define STEP_PRINT 2 40 | #define STEP_CALLT 3 41 | 42 | #define I_CALLG 0xfa 43 | #define I_CALLS 0xfb 44 | #define I_RET 0x04 45 | -------------------------------------------------------------------------------- /src/kdb/r1: -------------------------------------------------------------------------------- 1 | p1lr 1ffff2 2 | p1br 7f970a00 3 | p0lr 3000054 4 | p0br 80170600 5 | ksp 7ffffe34 6 | esp -1 7 | ssp -1 8 | psl 3c00001 9 | pc 6b80 10 | usp 7fffea4c 11 | fp 7fffea4c 12 | ap 7fffea60 13 | r11 11111111 14 | r10 10101010 15 | r9 7fffeb70 16 | r8 8080808 17 | r7 7fffeae0 18 | r6 6060606 19 | r5 0 20 | r4 0 21 | r3 91c4 22 | r2 0 23 | r1 7fffeb5c 24 | r0 4 25 | 6b80: 26 | -------------------------------------------------------------------------------- /src/kdb/symchk: -------------------------------------------------------------------------------- 1 | #!/bin/csh -fx 2 | set OBJS=(access.o command.o expr.o format.o input.o main.o message.o opset.o optab.o output.o pcs.o print.o reset.o runpcs.o setup.o sym.o) 3 | 4 | nm -pg message.o | sed -n -e 's;^.........C ;;p' 5 | -------------------------------------------------------------------------------- /stand.4.2/cat.c: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* cat.c 6.1 83/07/29 */ 29 | 30 | main() 31 | { 32 | int c, i; 33 | char buf[50]; 34 | 35 | do { 36 | printf("File: "); 37 | gets(buf); 38 | i = open(buf, 0); 39 | } while (i <= 0); 40 | 41 | while ((c = getc(i)) > 0) 42 | putchar(c); 43 | exit(0); 44 | } 45 | -------------------------------------------------------------------------------- /stand.4.2/machdep.c: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* machdep.c 6.1 83/07/29 */ 29 | 30 | #include "../h/param.h" 31 | 32 | #include "../vax/mtpr.h" 33 | 34 | /*ARGSUSED*/ 35 | /*VARARGS1*/ 36 | mtpr(regno, value) 37 | { 38 | 39 | asm(" mtpr 8(ap),4(ap)"); 40 | } 41 | 42 | /*ARGSUSED*/ 43 | mfpr(regno) 44 | { 45 | 46 | asm(" mfpr 4(ap),r0"); 47 | #ifdef lint 48 | return (0); 49 | #endif 50 | } 51 | 52 | /* 53 | * Copy bytes within kernel 54 | */ 55 | /*ARGSUSED*/ 56 | bcopy(from, to, count) 57 | caddr_t from, to; 58 | unsigned count; 59 | { 60 | 61 | asm(" movc3 12(ap),*4(ap),*8(ap)"); 62 | } 63 | -------------------------------------------------------------------------------- /stand.old/bootxx.c: -------------------------------------------------------------------------------- 1 | /* bootxx.c 6.1 83/07/29 */ 2 | 3 | #include "../h/param.h" 4 | #include "../h/inode.h" 5 | #include "../h/fs.h" 6 | #include "../h/vm.h" 7 | #include 8 | #include "saio.h" 9 | #include "../h/reboot.h" 10 | 11 | char bootprog[] = "xx(0,0)boot"; 12 | 13 | /* 14 | * Boot program... arguments passed in r10 and r11 15 | * are passed through to the full boot program. 16 | */ 17 | 18 | main() 19 | { 20 | register howto, devtype; /* howto=r11, devtype=r10 */ 21 | int io; 22 | 23 | #ifdef lint 24 | howto = 0; devtype = 0; 25 | #endif 26 | #ifdef CMU 27 | /* CS_BOOT */ 28 | bootprog[3] += ((devtype>>8)&0x7); 29 | bootprog[5] += ((howto>>28)&0x7); 30 | /* CS_BOOT */ 31 | #endif CMU 32 | printf("loading %s", bootprog); 33 | io = open(bootprog, 0); 34 | if (io >= 0) 35 | copyunix(howto, devtype, io); 36 | printf("boot failed"); 37 | _exit(); 38 | } 39 | 40 | /*ARGSUSED*/ 41 | copyunix(howto, devtype, io) 42 | register howto, devtype, io; /* howto=r11, devtype=r10 */ 43 | { 44 | struct exec x; 45 | register int i; 46 | char *addr; 47 | 48 | i = read(io, (char *)&x, sizeof x); 49 | if (i != sizeof x || 50 | (x.a_magic != 0407 && x.a_magic != 0413 && x.a_magic != 0410)) 51 | _stop("Bad format\n"); 52 | if ((x.a_magic == 0413 || x.a_magic == 0410) && 53 | lseek(io, 0x400, 0) == -1) 54 | goto shread; 55 | if (read(io, (char *)0, x.a_text) != x.a_text) 56 | goto shread; 57 | addr = (char *)x.a_text; 58 | if (x.a_magic == 0413 || x.a_magic == 0410) 59 | while ((int)addr & CLOFSET) 60 | *addr++ = 0; 61 | if (read(io, addr, x.a_data) != x.a_data) 62 | goto shread; 63 | addr += x.a_data; 64 | x.a_bss += 128*512; /* slop */ 65 | for (i = 0; i < x.a_bss; i++) 66 | *addr++ = 0; 67 | x.a_entry &= 0x7fffffff; 68 | (*((int (*)()) x.a_entry))(); 69 | _exit(); 70 | shread: 71 | _stop("Short read\n"); 72 | } 73 | -------------------------------------------------------------------------------- /stand.old/cat.c: -------------------------------------------------------------------------------- 1 | /* cat.c 6.1 83/07/29 */ 2 | 3 | main() 4 | { 5 | int c, i; 6 | char buf[50]; 7 | 8 | do { 9 | printf("File: "); 10 | gets(buf); 11 | i = open(buf, 0); 12 | } while (i <= 0); 13 | 14 | while ((c = getc(i)) > 0) 15 | putchar(c); 16 | exit(0); 17 | } 18 | -------------------------------------------------------------------------------- /stand.old/confhpup.c: -------------------------------------------------------------------------------- 1 | /* confhpup.c 6.1 83/07/29 */ 2 | 3 | #include "../machine/pte.h" 4 | 5 | #include "../h/param.h" 6 | #include "../h/inode.h" 7 | #include "../h/fs.h" 8 | #include "saio.h" 9 | 10 | devread(io) 11 | register struct iob *io; 12 | { 13 | int cc; 14 | 15 | io->i_flgs |= F_RDDATA; 16 | io->i_error = 0; 17 | cc = (*devsw[io->i_ino.i_dev].dv_strategy)(io, READ); 18 | io->i_flgs &= ~F_TYPEMASK; 19 | return (cc); 20 | } 21 | 22 | devwrite(io) 23 | register struct iob *io; 24 | { 25 | int cc; 26 | 27 | io->i_flgs |= F_WRDATA; 28 | io->i_error = 0; 29 | cc = (*devsw[io->i_ino.i_dev].dv_strategy)(io, WRITE); 30 | io->i_flgs &= ~F_TYPEMASK; 31 | return (cc); 32 | } 33 | 34 | devopen(io) 35 | register struct iob *io; 36 | { 37 | 38 | (*devsw[io->i_ino.i_dev].dv_open)(io); 39 | } 40 | 41 | devclose(io) 42 | register struct iob *io; 43 | { 44 | 45 | (*devsw[io->i_ino.i_dev].dv_close)(io); 46 | } 47 | 48 | devioctl(io, cmd, arg) 49 | register struct iob *io; 50 | int cmd; 51 | caddr_t arg; 52 | { 53 | 54 | return ((*devsw[io->i_ino.i_dev].dv_ioctl)(io, cmd, arg)); 55 | } 56 | 57 | /*ARGSUSED*/ 58 | nullsys(io) 59 | struct iob *io; 60 | { 61 | 62 | ; 63 | } 64 | 65 | /*ARGSUSED*/ 66 | nullioctl(io, cmd, arg) 67 | struct iob *io; 68 | int cmd; 69 | caddr_t arg; 70 | { 71 | 72 | return (ECMD); 73 | } 74 | 75 | int nullsys(), nullioctl(); 76 | int hpstrategy(), hpopen(), hpioctl(); 77 | int upstrategy(), upopen(), upioctl(); 78 | 79 | struct devsw devsw[] = { 80 | { "hp", hpstrategy, hpopen, nullsys, hpioctl }, 81 | { "up", upstrategy, upopen, nullsys, upioctl }, 82 | { 0, 0, 0, 0, 0 } 83 | }; 84 | -------------------------------------------------------------------------------- /stand.old/confxx.c: -------------------------------------------------------------------------------- 1 | /* confxx.c 6.1 83/07/29 */ 2 | 3 | #include "../machine/pte.h" 4 | 5 | #include "../h/param.h" 6 | #include "../h/inode.h" 7 | #include "../h/fs.h" 8 | #include "saio.h" 9 | 10 | devread(io) 11 | register struct iob *io; 12 | { 13 | int cc; 14 | 15 | io->i_flgs |= F_RDDATA; 16 | io->i_error = 0; 17 | cc = (*devsw[io->i_ino.i_dev].dv_strategy)(io, READ); 18 | io->i_flgs &= ~F_TYPEMASK; 19 | return (cc); 20 | } 21 | 22 | devwrite(io) 23 | register struct iob *io; 24 | { 25 | int cc; 26 | 27 | io->i_flgs |= F_WRDATA; 28 | io->i_error = 0; 29 | cc = (*devsw[io->i_ino.i_dev].dv_strategy)(io, WRITE); 30 | io->i_flgs &= ~F_TYPEMASK; 31 | return (cc); 32 | } 33 | 34 | devopen(io) 35 | register struct iob *io; 36 | { 37 | 38 | (*devsw[io->i_ino.i_dev].dv_open)(io); 39 | } 40 | 41 | devclose(io) 42 | register struct iob *io; 43 | { 44 | 45 | (*devsw[io->i_ino.i_dev].dv_close)(io); 46 | } 47 | 48 | devioctl(io, cmd, arg) 49 | register struct iob *io; 50 | int cmd; 51 | caddr_t arg; 52 | { 53 | 54 | return ((*devsw[io->i_ino.i_dev].dv_ioctl)(io, cmd, arg)); 55 | } 56 | 57 | /*ARGSUSED*/ 58 | nullsys(io) 59 | struct iob *io; 60 | { 61 | 62 | ; 63 | } 64 | 65 | /*ARGSUSED*/ 66 | nullioctl(io, cmd, arg) 67 | struct iob *io; 68 | int cmd; 69 | caddr_t arg; 70 | { 71 | 72 | return (ECMD); 73 | } 74 | 75 | int nullsys(), nullioctl(); 76 | int xxstrategy(), xxopen(), xxioctl(); 77 | 78 | struct devsw devsw[] = { 79 | { "XX", xxstrategy, xxopen, nullsys, xxioctl }, 80 | { 0, 0, 0, 0, 0 } 81 | }; 82 | -------------------------------------------------------------------------------- /stand.old/copy.c: -------------------------------------------------------------------------------- 1 | /* copy.c 6.1 83/07/29 */ 2 | 3 | /* 4 | * Copy from to in 10K units. 5 | * Intended for use in system 6 | * installation. 7 | */ 8 | main() 9 | { 10 | int from, to; 11 | char fbuf[50], tbuf[50]; 12 | char buffer[10240]; 13 | register int record; 14 | extern int errno; 15 | 16 | from = getdev("From", fbuf, 0); 17 | to = getdev("To", tbuf, 1); 18 | for (record = 0; ; record++) { 19 | int rcc, wcc; 20 | 21 | rcc = read(from, buffer, sizeof (buffer)); 22 | if (rcc == 0) 23 | break; 24 | if (rcc < 0) { 25 | printf("Record %d: read error, errno=%d\n", 26 | record, errno); 27 | break; 28 | } 29 | if (rcc < sizeof (buffer)) 30 | printf("Record %d: read short; expected %d, got %d\n", 31 | record, sizeof (buffer), rcc); 32 | /* 33 | * For bug in ht driver. 34 | */ 35 | if (rcc > sizeof (buffer)) 36 | rcc = sizeof (buffer); 37 | wcc = write(to, buffer, rcc); 38 | if (wcc < 0) { 39 | printf("Record %d: write error: errno=%d\n", 40 | record, errno); 41 | break; 42 | } 43 | if (wcc < rcc) { 44 | printf("Record %d: write short; expected %d, got %d\n", 45 | record, rcc, wcc); 46 | break; 47 | } 48 | } 49 | printf("Copy completed: %d records copied\n", record); 50 | /* can't call exit here */ 51 | } 52 | 53 | getdev(prompt, buf, mode) 54 | char *prompt, *buf; 55 | int mode; 56 | { 57 | register int i; 58 | 59 | do { 60 | printf("%s: ", prompt); 61 | gets(buf); 62 | i = open(buf, mode); 63 | } while (i <= 0); 64 | return (i); 65 | } 66 | -------------------------------------------------------------------------------- /stand.old/ls.c: -------------------------------------------------------------------------------- 1 | /* ls.c 6.1 83/07/29 */ 2 | 3 | #include "../h/param.h" 4 | #include "../h/inode.h" 5 | #include "../h/ino.h" 6 | #include "../h/dir.h" 7 | #include "saio.h" 8 | 9 | char line[100]; 10 | 11 | main() 12 | { 13 | int i; 14 | 15 | printf("ls\n"); 16 | do { 17 | printf(": "); gets(line); 18 | i = open(line, 0); 19 | } while (i < 0); 20 | 21 | ls(i); 22 | } 23 | 24 | ls(io) 25 | register io; 26 | { 27 | struct direct d; 28 | register i; 29 | 30 | while (read(io, (char *)&d, sizeof d) == sizeof d) { 31 | if (d.d_ino == 0) 32 | continue; 33 | printf("%d\t", d.d_ino); 34 | for (i=0; i */ 20 | 21 | #define MAXNMBA 4 22 | struct mba_regs **mbaddr; 23 | int mbaact; 24 | caddr_t *umaddr; 25 | struct uba_regs **ubaddr; 26 | 27 | #define UNITTOMBA(unit) ((unit)>>3) 28 | #define UNITTODRIVE(unit) ((unit)&07) 29 | 30 | #define mbamba(unit) (mbaddr[UNITTOMBA(unit)]) 31 | #define mbadrv(unit) (&mbamba(unit)->mba_drv[UNITTODRIVE(unit)]) 32 | 33 | #define UNITTOUBA(unit) ((unit)>>3) 34 | #define ubauba(unit) (ubaddr[UNITTOUBA(unit)]) 35 | #define ubamem(unit, off) ((umaddr[UNITTOUBA(unit)]+ubdevreg(off))) 36 | 37 | #define PHYSUBA0 0x20006000 38 | #define PHYSMBA0 0x20010000 39 | #define PHYSMBA1 0x20012000 40 | #define PHYSUMEM 0x2013e000 41 | -------------------------------------------------------------------------------- /stand.old/save/boothk.c: -------------------------------------------------------------------------------- 1 | /* boothk.c 6.1 83/07/29 */ 2 | 3 | #include "../h/param.h" 4 | #include "../h/inode.h" 5 | #include "../h/fs.h" 6 | #include "../h/vm.h" 7 | #include 8 | #include "saio.h" 9 | #include "../h/reboot.h" 10 | 11 | char bootprog[] = "hk(0,0)boot"; 12 | 13 | /* 14 | * Boot program... arguments passed in r10 and r11 15 | * are passed through to the full boot program. 16 | */ 17 | 18 | main() 19 | { 20 | register howto, devtype; /* howto=r11, devtype=r10 */ 21 | int io; 22 | 23 | #ifdef lint 24 | howto = 0; devtype = 0; 25 | #endif 26 | printf("loading %s", bootprog); 27 | io = open(bootprog, 0); 28 | if (io >= 0) 29 | copyunix(howto, devtype, io); 30 | printf("boot failed"); 31 | _exit(); 32 | } 33 | 34 | /*ARGSUSED*/ 35 | copyunix(howto, devtype, io) 36 | register howto, devtype, io; /* howto=r11, devtype=r10 */ 37 | { 38 | struct exec x; 39 | register int i; 40 | char *addr; 41 | 42 | i = read(io, (char *)&x, sizeof x); 43 | if (i != sizeof x || 44 | (x.a_magic != 0407 && x.a_magic != 0413 && x.a_magic != 0410)) 45 | _stop("Bad format\n"); 46 | if ((x.a_magic == 0413 || x.a_magic == 0410) && 47 | lseek(io, 0x400, 0) == -1) 48 | goto shread; 49 | if (read(io, (char *)0, x.a_text) != x.a_text) 50 | goto shread; 51 | addr = (char *)x.a_text; 52 | if (x.a_magic == 0413 || x.a_magic == 0410) 53 | while ((int)addr & CLOFSET) 54 | *addr++ = 0; 55 | if (read(io, addr, x.a_data) != x.a_data) 56 | goto shread; 57 | addr += x.a_data; 58 | x.a_bss += 128*512; /* slop */ 59 | for (i = 0; i < x.a_bss; i++) 60 | *addr++ = 0; 61 | x.a_entry &= 0x7fffffff; 62 | (*((int (*)()) x.a_entry))(); 63 | _exit(); 64 | shread: 65 | _stop("Short read\n"); 66 | } 67 | -------------------------------------------------------------------------------- /stand.old/save/confrk.c: -------------------------------------------------------------------------------- 1 | /* confrk.c 6.1 83/07/29 */ 2 | 3 | #include "../machine/pte.h" 4 | 5 | #include "../h/param.h" 6 | #include "../h/inode.h" 7 | #include "../h/fs.h" 8 | #include "saio.h" 9 | 10 | devread(io) 11 | register struct iob *io; 12 | { 13 | int cc; 14 | 15 | io->i_flgs |= F_RDDATA; 16 | io->i_error = 0; 17 | cc = (*devsw[io->i_ino.i_dev].dv_strategy)(io, READ); 18 | io->i_flgs &= ~F_TYPEMASK; 19 | return (cc); 20 | } 21 | 22 | devwrite(io) 23 | register struct iob *io; 24 | { 25 | int cc; 26 | 27 | io->i_flgs |= F_WRDATA; 28 | io->i_error = 0; 29 | cc = (*devsw[io->i_ino.i_dev].dv_strategy)(io, WRITE); 30 | io->i_flgs &= ~F_TYPEMASK; 31 | return (cc); 32 | } 33 | 34 | devopen(io) 35 | register struct iob *io; 36 | { 37 | 38 | (*devsw[io->i_ino.i_dev].dv_open)(io); 39 | } 40 | 41 | devclose(io) 42 | register struct iob *io; 43 | { 44 | 45 | (*devsw[io->i_ino.i_dev].dv_close)(io); 46 | } 47 | 48 | devioctl(io, cmd, arg) 49 | register struct iob *io; 50 | int cmd; 51 | caddr_t arg; 52 | { 53 | 54 | return ((*devsw[io->i_ino.i_dev].dv_ioctl)(io, cmd, arg)); 55 | } 56 | 57 | /*ARGSUSED*/ 58 | nullsys(io) 59 | struct iob *io; 60 | { 61 | 62 | ; 63 | } 64 | 65 | /*ARGSUSED*/ 66 | nullioctl(io, cmd, arg) 67 | struct iob *io; 68 | int cmd; 69 | caddr_t arg; 70 | { 71 | 72 | return (ECMD); 73 | } 74 | 75 | int nullsys(), nullioctl(); 76 | int rkstrategy(), rkopen(), rkioctl(); 77 | 78 | struct devsw devsw[] = { 79 | { "hk", rkstrategy, rkopen, nullsys, rkioctl }, 80 | { 0, 0, 0, 0, 0 } 81 | }; 82 | -------------------------------------------------------------------------------- /stand.old/t.c: -------------------------------------------------------------------------------- 1 | CMU 2 | -------------------------------------------------------------------------------- /stand.old/upmaptype.c: -------------------------------------------------------------------------------- 1 | /* upmaptype.c 6.1 83/07/29 */ 2 | 3 | /* 4 | * UNIBUS peripheral standalone 5 | * driver: drive type mapping routine. 6 | */ 7 | 8 | #include "../h/param.h" 9 | #include "../h/inode.h" 10 | #include "../h/fs.h" 11 | #include "../h/dkbad.h" 12 | #include "../h/vmmac.h" 13 | 14 | #include "../vax/pte.h" 15 | #include "../vaxuba/upreg.h" 16 | #include "../vaxuba/ubareg.h" 17 | 18 | #include "saio.h" 19 | #include "savax.h" 20 | 21 | short up9300_off[] = { 0, 27, 0, -1, -1, -1, 562, 82 }; 22 | short fj_off[] = { 0, 50, 0, -1, -1, -1, 155, -1 }; 23 | short upam_off[] = { 0, 32, 0, 668, 723, 778, 668, 98 }; 24 | short up980_off[] = { 0, 100, 0, -1, -1 , -1, 309, -1}; 25 | 26 | struct st upst[] = { 27 | 32, 19, 32*19, 815, up9300_off, /* 9300 */ 28 | 32, 19, 32*19, 823, up9300_off, /* 9766 */ 29 | 32, 10, 32*10, 823, fj_off, /* Fuji 160 */ 30 | 32, 16, 32*16, 1024, upam_off, /* Capricorn */ 31 | 32, 5, 32*5, 823, up980_off, /* DM980 */ 32 | 0, 0, 0, 0, 0, 33 | }; 34 | 35 | upmaptype(unit, upaddr) 36 | int unit; 37 | register struct updevice *upaddr; 38 | { 39 | register struct st *st; 40 | int type = -1; 41 | 42 | upaddr->upcs1 = 0; 43 | upaddr->upcs2 = unit % 8; 44 | upaddr->uphr = UPHR_MAXTRAK; 45 | for (st = upst; st->ntrak != 0; st++) 46 | if (upaddr->uphr == st->ntrak - 1) { 47 | type = st - upst; 48 | break; 49 | } 50 | if (st->ntrak == 0) 51 | printf("up%d: uphr=%x\n", unit, upaddr->uphr); 52 | if (type == 0) { 53 | upaddr->uphr = UPHR_MAXCYL; 54 | if (upaddr->uphr == 822) /* CDC 9766 */ 55 | type++; 56 | } 57 | upaddr->upcs2 = UPCS2_CLR; 58 | return (type); 59 | } 60 | -------------------------------------------------------------------------------- /stand/cat.c: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * Copyright (c) 1982 Regents of the University of California. 30 | * All rights reserved. The Berkeley software License Agreement 31 | * specifies the terms and conditions for redistribution. 32 | * 33 | * @(#)cat.c 6.2 (Berkeley) 6/8/85 34 | */ 35 | 36 | main() 37 | { 38 | int c, i; 39 | char buf[50]; 40 | 41 | do { 42 | printf("File: "); 43 | gets(buf); 44 | i = open(buf, 0); 45 | } while (i <= 0); 46 | 47 | while ((c = getc(i)) > 0) 48 | putchar(c); 49 | exit(0); 50 | } 51 | -------------------------------------------------------------------------------- /stand/cs_vaxm.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | #define CS_VAXM 1 29 | -------------------------------------------------------------------------------- /sys/Makefile: -------------------------------------------------------------------------------- 1 | # %M% %I% %E% 2 | # 3 | # Put the ../h stuff near the end so that subroutine definitions win when 4 | # there is a struct tag with the same name (eg., vmmeter). The real 5 | # solution would probably be for ctags to generate "struct vmmeter" tags. 6 | CTAGS= ./ctags 7 | SRCS = ../net/*.[ch] ../netimp/*.[ch] ../netinet/*.[ch] \ 8 | ../netns/*.[ch] ../sys/*.[ch] ../vaxif/*.[ch] ../vaxmba/*.[ch] \ 9 | ../vaxuba/*.[ch] \ 10 | ../vax/autoconf.c ../vax/clock.c ../vax/clock.h ../vax/conf.c \ 11 | ../vax/cons.c ../vax/cons.h ../vax/cpu.h ../vax/cpudata.c \ 12 | ../vax/dkbad.c ../vax/dkio.h ../vax/flp.c ../vax/flp.h \ 13 | ../vax/frame.h \ 14 | ../vax/genassym.c ../vax/in_cksum.c ../vax/machdep.c \ 15 | ../vax/machparam.h ../vax/mem.c \ 16 | ../vax/mem.h ../vax/mscp.h ../vax/mtpr.h ../vax/nexus.h \ 17 | ../vax/pcb.h ../vax/psl.h ../vax/pte.h ../vax/pup_cksum.c \ 18 | ../vax/reg.h \ 19 | ../vax/rpb.h ../vax/rpb.s ../vax/rsp.h ../vax/scb.h \ 20 | ../vax/scb.s \ 21 | ../vax/swapgeneric.c ../vax/sys_machdep.c ../vax/trap.c \ 22 | ../vax/trap.h \ 23 | ../vax/tu.c ../vax/ufs_machdep.c ../vax/vm_machdep.c \ 24 | ../vax/vmparam.h \ 25 | ../h/*.h 26 | 27 | DIRS = h net netimp netinet netns vax vaxif vaxmba vaxuba 28 | 29 | all: 30 | @echo "make tags or links only" 31 | 32 | tags: FRC 33 | mv tags tags.old 34 | -cp ../machine/astags tags 35 | ${CTAGS} -a ${SRCS} 36 | sort -o tags tags 37 | # rm tags.old 38 | 39 | links: 40 | -for i in ${DIRS}; do rm -f ../$$i/tags; \ 41 | ln -s ../sys/tags ../$$i/tags; done 42 | 43 | FRC: 44 | -------------------------------------------------------------------------------- /sys/foo.csh: -------------------------------------------------------------------------------- 1 | foreach file (*.c) 2 | echo $file >> LOG 3 | diff $file /uvax/usr/src/sys/sys/$file >> LOG 4 | end 5 | -------------------------------------------------------------------------------- /vax/astags: -------------------------------------------------------------------------------- 1 | doadump ../vax/locore.s /^_doadump:$/ 2 | dzdma ../vax/locore.s /^dzdma:$/ 3 | uudma ../vax/locore.s /^uudma:$/ 4 | tudma ../vax/locore.s /^tudma:$/ 5 | catcher ../vax/locore.s /^_catcher:$/ 6 | start ../vax/locore.s /^start:$/ 7 | badaddr ../vax/locore.s /^_badaddr:$/ 8 | addupc ../vax/locore.s /^ENTRY(addupc, 0)$/ 9 | copyinstr ../vax/locore.s /^ENTRY(copyinstr, R6)$/ 10 | copyoutstr ../vax/locore.s /^ENTRY(copyoutstr, R6)$/ 11 | copystr ../vax/locore.s /^ENTRY(copystr, R6)$/ 12 | Copyin ../vax/locore.s /^JSBENTRY(Copyin)$/ 13 | copyin ../vax/locore.s /^JSBENTRY(Copyin)$/ 14 | Copyout ../vax/locore.s /^JSBENTRY(Copyout)$/ 15 | copyout ../vax/locore.s /^JSBENTRY(Copyout)$/ 16 | Setjmp ../vax/locore.s /^JSBENTRY(Setjmp)$/ 17 | setjmp ../vax/locore.s /^JSBENTRY(Setjmp)$/ 18 | Longjmp ../vax/locore.s /^JSBENTRY(Longjmp)$/ 19 | longjmp ../vax/locore.s /^JSBENTRY(Longjmp)$/ 20 | Setrq ../vax/locore.s /^ JSBENTRY(Setrq)$/ 21 | setrq ../vax/locore.s /^ JSBENTRY(Setrq)$/ 22 | Remrq ../vax/locore.s /^ JSBENTRY(Remrq)$/ 23 | remrq ../vax/locore.s /^ JSBENTRY(Remrq)$/ 24 | Idle: ../vax/locore.s /^idle Idle: idle:$/ 25 | Swtch ../vax/locore.s /^JSBENTRY(Swtch)$/ 26 | swtch ../vax/locore.s /^JSBENTRY(Swtch)$/ 27 | Resume ../vax/locore.s /^JSBENTRY(Resume)$/ 28 | resume ../vax/locore.s /^JSBENTRY(Resume)$/ 29 | Fuword ../vax/locore.s /^JSBENTRY(Fuword)$/ 30 | fuword ../vax/locore.s /^JSBENTRY(Fuword)$/ 31 | Fubyte ../vax/locore.s /^JSBENTRY(Fubyte)$/ 32 | fubyte ../vax/locore.s /^JSBENTRY(Fubyte)$/ 33 | Suword ../vax/locore.s /^JSBENTRY(Suword)$/ 34 | suword ../vax/locore.s /^JSBENTRY(Suword)$/ 35 | Subyte ../vax/locore.s /^JSBENTRY(Subyte)$/ 36 | subyte ../vax/locore.s /^JSBENTRY(Subyte)$/ 37 | copyseg ../vax/locore.s /^ENTRY(copyseg, 0)$/ 38 | clearseg ../vax/locore.s /^ENTRY(clearseg, 0)$/ 39 | useracc ../vax/locore.s /^ENTRY(useracc, 0)$/ 40 | kernacc ../vax/locore.s /^ ENTRY(kernacc, 0)$/ 41 | Fastreclaim ../vax/locore.s /^Fastreclaim:$/ 42 | -------------------------------------------------------------------------------- /vax/clock.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)clock.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * VAX clock registers 11 | */ 12 | 13 | #define ICCS_RUN 0x00000001 14 | #define ICCS_TRANS 0x00000010 15 | #define ICCS_SS 0x00000020 16 | #define ICCS_IE 0x00000040 17 | #define ICCS_INT 0x00000080 18 | #define ICCS_ERR 0x80000000 19 | 20 | #define SECDAY ((unsigned)(24*60*60)) /* seconds per day */ 21 | #define SECYR ((unsigned)(365*SECDAY)) /* per common year */ 22 | /* 23 | * TODRZERO is the what the TODR should contain when the ``year'' begins. 24 | * The TODR should always contain a number between 0 and SECYR+SECDAY. 25 | */ 26 | #define TODRZERO ((unsigned)(1<<28)) 27 | 28 | #define YRREF 1970 29 | #define LEAPYEAR(year) ((year)%4==0) /* good till time becomes negative */ 30 | 31 | /* 32 | * Has the time-of-day clock wrapped around? 33 | */ 34 | #define clkwrap() (((unsigned)mfpr(TODR) - TODRZERO)/100 > SECYR+SECDAY) 35 | 36 | /* 37 | * Software clock is software interrupt level 8, 38 | * implemented as mtpr(SIRR, 0x8) in asm.sed. 39 | */ 40 | -------------------------------------------------------------------------------- /vax/cons.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)cons.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * VAX console interface registers 11 | */ 12 | 13 | #define RXCS_IE 0x00000040 /* receiver interrupt enable */ 14 | #define RXCS_DONE 0x00000080 /* receiver done */ 15 | 16 | #define RXDB_DATA 0x000000ff /* received character */ 17 | #define RXDB_ID 0x00000f00 /* channel id */ 18 | #define RXDB_ERR 0x80000000 /* receiver error */ 19 | 20 | #define TXCS_IE 0x00000040 /* transmitter interrupt enable */ 21 | #define TXCS_RDY 0x00000080 /* transmitter ready for next char */ 22 | #if VAX8600 23 | #define TXCS_ID 0x00000300 /* interrupt ID field */ 24 | #define TXCS_WMASK 0x00008000 /* enable mask write */ 25 | #define TXCS_TXMASK 0x00ff0000 /* transmit enable channel mask: */ 26 | #define TXCS_CTERM 0x00010000 /* console terminal */ 27 | #define TXCS_RTERM 0x00020000 /* remote diagnostic port */ 28 | #define TXCS_EMM 0x00040000 /* Environmental Monitor Module */ 29 | #define TXCS_LCONS 0x00080000 /* Logical console */ 30 | #endif 31 | 32 | #define TXDB_DATA 0x000000ff /* transmitter byte */ 33 | #define TXDB_ID 0x00000f00 /* channel id- not on 8600 */ 34 | #define TXDB_CONS 0x00000f00 /* channel id for console subsystem */ 35 | 36 | #define TXDB_DONE 0x01 /* software done */ 37 | #define TXDB_BOOT 0x02 /* reboot */ 38 | #define TXDB_CWSI 0x03 /* clear warm start inhibit */ 39 | #define TXDB_CCSI 0x04 /* clear cold-start inhibit */ 40 | -------------------------------------------------------------------------------- /vax/crt0.ex: -------------------------------------------------------------------------------- 1 | / forgot to run ex script on gcrt0.s/d 2 | ? .word ?d 3 | w 4 | q 5 | " @(#)crt0.ex 7.1 (Berkeley) 6/5/86 " 6 | -------------------------------------------------------------------------------- /vax/dkbad.c: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)dkbad.c 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | #ifndef NOBADSECT 10 | #include "param.h" 11 | #include "buf.h" 12 | #include "dkbad.h" 13 | 14 | /* 15 | * Search the bad sector table looking for 16 | * the specified sector. Return index if found. 17 | * Return -1 if not found. 18 | */ 19 | 20 | isbad(bt, cyl, trk, sec) 21 | register struct dkbad *bt; 22 | { 23 | register int i; 24 | register long blk, bblk; 25 | 26 | blk = ((long)cyl << 16) + (trk << 8) + sec; 27 | for (i = 0; i < 126; i++) { 28 | bblk = ((long)bt->bt_bad[i].bt_cyl << 16) + bt->bt_bad[i].bt_trksec; 29 | if (blk == bblk) 30 | return (i); 31 | if (blk < bblk || bblk < 0) 32 | break; 33 | } 34 | return (-1); 35 | } 36 | #endif 37 | -------------------------------------------------------------------------------- /vax/dkio.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)dkio.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * Structures and definitions for disk io control commands 11 | * 12 | * THIS WHOLE AREA NEEDS MORE THOUGHT. FOR NOW JUST IMPLEMENT 13 | * ENOUGH TO READ AND WRITE HEADERS ON MASSBUS DISKS. EVENTUALLY 14 | * SHOULD BE ABLE TO DETERMINE DRIVE TYPE AND DO OTHER GOOD STUFF. 15 | */ 16 | 17 | /* disk io control commands */ 18 | #define DKIOCHDR _IO(d, 1) /* next I/O will read/write header */ 19 | -------------------------------------------------------------------------------- /vax/flp.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)flp.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | #if VAX780 10 | /* 11 | * Console floppy command/status and sectoring information. 12 | */ 13 | #define FL_FFC 0x200 /* floppy function complete */ 14 | #define FL_ERR 0x80 /* error bit in floppy status byte */ 15 | #define FL_PERR 0x905 /* floppy protocol error */ 16 | #define FL_DATA 0x100 /* floppy data select code */ 17 | #define FL_RS 0x900 /* floppy read sector command */ 18 | #define FL_WS 0x901 /* floppy write sector command*/ 19 | #define FL_STAT 0x902 /* floppy get status command*/ 20 | #define FL_CANCEL 0x904 /* cancel floppy function */ 21 | 22 | #define RXFTRK 77 /* tracks/floppy */ 23 | #define RXSTRK 26 /* sectors/track */ 24 | #define RXBYSEC 128 /* bytes/sector */ 25 | #define MAXSEC (RXFTRK*RXSTRK) /* sectors/floppy */ 26 | 27 | /* 28 | * In the floppy driver routines, the device active byte is used 29 | * not as a boolean, but as an indicator of the state we are in. 30 | * That is, it contains what to do on the next interrupt. 31 | */ 32 | 33 | #define FL_IDLE 0 /* floppy idle */ 34 | #define FL_MAND 1 /* about to send read/write command */ 35 | #define FL_SEC 2 /* about to send sector # to LSI */ 36 | #define FL_TRACK 3 /* about to send track # to LSI */ 37 | #define FL_DAX 4 /* transmitting data */ 38 | #define FL_DAR 5 /* receiving data */ 39 | #define FL_COM 6 /* completing transmission */ 40 | #define FL_CAN 7 /* give cancel order - we had an error, 41 | and are to restart */ 42 | 43 | #define FLERRS 5 /* number of retries before quitting */ 44 | 45 | /* 46 | * The state byte is used to retain exclusivity, 47 | * and contains the busy flag. 48 | */ 49 | #define FL_OPEN 1 50 | #define FL_BUSY 2 51 | #endif 52 | -------------------------------------------------------------------------------- /vax/frame.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)frame.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * Definition of the vax calls/callg frame. 11 | */ 12 | struct frame { 13 | int fr_handler; 14 | u_int fr_psw:16, /* saved psw */ 15 | fr_mask:12, /* register save mask */ 16 | :1, 17 | fr_s:1, /* call was a calls, not callg */ 18 | fr_spa:2; /* stack pointer alignment */ 19 | int fr_savap; /* saved arg pointer */ 20 | int fr_savfp; /* saved frame pointer */ 21 | int fr_savpc; /* saved program counter */ 22 | }; 23 | -------------------------------------------------------------------------------- /vax/inline/Makefile: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 1982, 1986 Regents of the University of California. 3 | # All rights reserved. The Berkeley software License Agreement 4 | # specifies the terms and conditions for redistribution. 5 | # 6 | # @(#)Makefile 7.1 (Berkeley) 6/5/86 7 | # 8 | DESTDIR= 9 | CFLAGS= -O 10 | INCPATH=-I. 11 | LFLAGS= 12 | 13 | # The program itself 14 | # 15 | PROG= inline 16 | 17 | # Sources 18 | # 19 | SRCS= main.c machdep.c machpats.c libcpats.c langpats.c 20 | 21 | # Objects 22 | # 23 | OBJS= main.o machdep.o machpats.o libcpats.o langpats.o 24 | 25 | # Header files 26 | # 27 | HDRS= inline.h 28 | 29 | ${PROG}: ${OBJS} ${HDRS} 30 | cc ${LFLAGS} -o ${PROG} ${OBJS} 31 | 32 | ${OBJS}: 33 | cc ${CFLAGS} ${INCPATH} -c $*.c 34 | 35 | install: ${PROG} 36 | install ${PROG} ../inline 37 | 38 | clean: 39 | rm -f a.out core ${OBJS} ${PROG} 40 | 41 | print: 42 | @pr ${HDRS} ${SRCS} 43 | 44 | lint: 45 | lint ${SRCS} 46 | 47 | depend: 48 | cc -M ${INCPATH} ${SRCS} | \ 49 | awk ' { if ($$1 != prev) { print rec; rec = $$0; prev = $$1; } \ 50 | else { if (length(rec $$2) > 78) { print rec; rec = $$0; } \ 51 | else rec = rec " " $$2 } } \ 52 | END { print rec } ' > makedep 53 | echo '/^# DO NOT DELETE THIS LINE/+2,$$d' >eddep 54 | echo '$$r makedep' >>eddep 55 | echo 'w' >>eddep 56 | cp Makefile Makefile.bak 57 | ed - Makefile < eddep 58 | rm eddep makedep 59 | echo '# DEPENDENCIES MUST END AT END OF FILE' >> Makefile 60 | echo '# IF YOU PUT STUFF HERE IT WILL GO AWAY' >> Makefile 61 | echo '# see make depend above' >> Makefile 62 | 63 | # DO NOT DELETE THIS LINE -- make depend uses it 64 | 65 | 66 | main.o: main.c /usr/include/stdio.h /usr/include/ctype.h ./inline.h 67 | machdep.o: machdep.c /usr/include/stdio.h /usr/include/ctype.h 68 | machpats.o: machpats.c ./inline.h 69 | libcpats.o: libcpats.c ./inline.h 70 | langpats.o: langpats.c ./inline.h 71 | # DEPENDENCIES MUST END AT END OF FILE 72 | # IF YOU PUT STUFF HERE IT WILL GO AWAY 73 | # see make depend above 74 | -------------------------------------------------------------------------------- /vax/inline/libcpats.c: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1984, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | */ 6 | 7 | #ifndef lint 8 | static char sccsid[] = "@(#)libcpats.c 7.1 (Berkeley) 6/5/86"; 9 | #endif not lint 10 | 11 | #include "inline.h" 12 | 13 | /* 14 | * Pattern table for the C library. 15 | */ 16 | struct pats libc_ptab[] = { 17 | 18 | #ifdef vax 19 | { 1, "_fgetc\n", 20 | " sobgeq *(sp),1f\n\ 21 | calls $1,__filbuf\n\ 22 | jbr 2f\n\ 23 | 1:\n\ 24 | addl3 $4,(sp)+,r1\n\ 25 | movzbl *(r1),r0\n\ 26 | incl (r1)\n\ 27 | 2:\n" }, 28 | 29 | { 2, "_fputc\n", 30 | " sobgeq *4(sp),1f\n\ 31 | calls $2,__flsbuf\n\ 32 | jbr 2f\n\ 33 | 1:\n\ 34 | movq (sp)+,r0\n\ 35 | movb r0,*4(r1)\n\ 36 | incl 4(r1)\n\ 37 | 2:\n" }, 38 | #endif vax 39 | 40 | #ifdef mc68000 41 | /* someday... */ 42 | #endif mc68000 43 | 44 | { 0, "", "" } 45 | }; 46 | 47 | struct pats vaxsubset_libc_ptab[] = { 48 | 49 | { 1, "_strlen\n", 50 | " movl (sp)+,r5\n\ 51 | movl r5,r1\n\ 52 | 1:\n\ 53 | tstb (r1)+\n\ 54 | jneq 1b\n\ 55 | decl r1\n\ 56 | subl3 r5,r1,r0\n" }, 57 | 58 | { 0, "", "" } 59 | }; 60 | 61 | struct pats vax_libc_ptab[] = { 62 | 63 | { 1, "_strlen\n", 64 | " movl (sp)+,r5\n\ 65 | movl r5,r1\n\ 66 | 1:\n\ 67 | locc $0,$65535,(r1)\n\ 68 | jeql 1b\n\ 69 | subl3 r5,r1,r0\n" }, 70 | 71 | { 0, "", "" } 72 | }; 73 | -------------------------------------------------------------------------------- /vax/machparam.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)machparam.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * Machine dependent constants for vax. 11 | */ 12 | #define NBPG 512 /* bytes/page */ 13 | #define PGOFSET (NBPG-1) /* byte offset into page */ 14 | #define PGSHIFT 9 /* LOG2(NBPG) */ 15 | 16 | #define CLSIZE 2 17 | #define CLSIZELOG2 1 18 | 19 | #define SSIZE 4 /* initial stack size/NBPG */ 20 | #define SINCR 4 /* increment of stack/NBPG */ 21 | 22 | #define UPAGES 10 /* pages of u-area */ 23 | 24 | /* 25 | * Some macros for units conversion 26 | */ 27 | /* Core clicks (512 bytes) to segments and vice versa */ 28 | #define ctos(x) (x) 29 | #define stoc(x) (x) 30 | 31 | /* Core clicks (512 bytes) to disk blocks */ 32 | #define ctod(x) (x) 33 | #define dtoc(x) (x) 34 | #define dtob(x) ((x)<<9) 35 | 36 | /* clicks to bytes */ 37 | #define ctob(x) ((x)<<9) 38 | 39 | /* bytes to clicks */ 40 | #define btoc(x) ((((unsigned)(x)+511)>>9)) 41 | 42 | /* 43 | * Macros to decode processor status word. 44 | */ 45 | #define USERMODE(ps) (((ps) & PSL_CURMOD) == PSL_CURMOD) 46 | #define BASEPRI(ps) (((ps) & PSL_IPL) == 0) 47 | 48 | #ifdef KERNEL 49 | #ifndef LOCORE 50 | int cpuspeed; 51 | #endif 52 | #define DELAY(n) { register int N = cpuspeed * (n); while (--N > 0); } 53 | 54 | #else KERNEL 55 | #define DELAY(n) { register int N = (n); while (--N > 0); } 56 | #endif KERNEL 57 | -------------------------------------------------------------------------------- /vax/pcb.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)pcb.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * VAX process control block 11 | */ 12 | 13 | struct pcb 14 | { 15 | int pcb_ksp; /* kernel stack pointer */ 16 | int pcb_esp; /* exec stack pointer */ 17 | int pcb_ssp; /* supervisor stack pointer */ 18 | int pcb_usp; /* user stack pointer */ 19 | int pcb_r0; 20 | int pcb_r1; 21 | int pcb_r2; 22 | int pcb_r3; 23 | int pcb_r4; 24 | int pcb_r5; 25 | int pcb_r6; 26 | int pcb_r7; 27 | int pcb_r8; 28 | int pcb_r9; 29 | int pcb_r10; 30 | int pcb_r11; 31 | int pcb_r12; 32 | #define pcb_ap pcb_r12 33 | int pcb_r13; 34 | #define pcb_fp pcb_r13 35 | int pcb_pc; /* program counter */ 36 | int pcb_psl; /* program status longword */ 37 | struct pte *pcb_p0br; /* seg 0 base register */ 38 | int pcb_p0lr; /* seg 0 length register and astlevel */ 39 | struct pte *pcb_p1br; /* seg 1 base register */ 40 | int pcb_p1lr; /* seg 1 length register and pme */ 41 | /* 42 | * Software pcb (extension) 43 | */ 44 | int pcb_szpt; /* number of pages of user page table */ 45 | int pcb_cmap2; 46 | int *pcb_sswap; 47 | int pcb_sigc[5]; 48 | }; 49 | 50 | #define AST_NONE 0x04000000 /* ast level */ 51 | #define AST_USER 0x03000000 /* ast for user mode */ 52 | 53 | #define ASTLVL_NONE 4 54 | #define ASTLVL_USER 3 55 | 56 | #define AST_CLR 0x07000000 57 | #define PME_CLR 0x80000000 58 | 59 | #define aston() \ 60 | { \ 61 | mtpr(ASTLVL, ASTLVL_USER); \ 62 | } 63 | 64 | #define astoff() \ 65 | { \ 66 | mtpr(ASTLVL, ASTLVL_NONE); \ 67 | } 68 | -------------------------------------------------------------------------------- /vax/pcb.m: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)pcb.m 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * VAX process control block 11 | */ 12 | .set PCB_KSP, 0 13 | .set PCB_ESP, 4 14 | .set PCB_SSP, 8 15 | .set PCB_USP, 12 16 | .set PCB_R0, 16 17 | .set PCB_R1, 20 18 | .set PCB_R2, 24 19 | .set PCB_R3, 28 20 | .set PCB_R4, 32 21 | .set PCB_R5, 36 22 | .set PCB_R6, 40 23 | .set PCB_R7, 44 24 | .set PCB_R8, 48 25 | .set PCB_R9, 52 26 | .set PCB_R10, 56 27 | .set PCB_R11, 60 28 | .set PCB_R12, 64 29 | .set PCB_R13, 68 30 | .set PCB_PC, 72 31 | .set PCB_PSL, 76 32 | .set PCB_P0BR, 80 33 | .set PCB_P0LR, 84 34 | .set PCB_P1BR, 88 35 | .set PCB_P1LR, 92 36 | /* 37 | * Software pcb extension 38 | */ 39 | .set PCB_SZPT, 96 /* number of user page table pages */ 40 | .set PCB_CMAP2, 100 /* saved cmap2 across cswitch (ick) */ 41 | .set PCB_SSWAP, 104 /* flag for non-local goto */ 42 | .set PCB_SIGC, 108 /* signal trampoline code */ 43 | -------------------------------------------------------------------------------- /vax/psl.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)psl.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * VAX program status longword 11 | */ 12 | 13 | #define PSL_C 0x00000001 /* carry bit */ 14 | #define PSL_V 0x00000002 /* overflow bit */ 15 | #define PSL_Z 0x00000004 /* zero bit */ 16 | #define PSL_N 0x00000008 /* negative bit */ 17 | #define PSL_ALLCC 0x0000000f /* all cc bits - unlikely */ 18 | #define PSL_T 0x00000010 /* trace enable bit */ 19 | #define PSL_IV 0x00000020 /* integer overflow enable bit */ 20 | #define PSL_FU 0x00000040 /* floating point underflow enable */ 21 | #define PSL_DV 0x00000080 /* decimal overflow enable bit */ 22 | #define PSL_IPL 0x001f0000 /* interrupt priority level */ 23 | #define PSL_PRVMOD 0x00c00000 /* previous mode (all on is user) */ 24 | #define PSL_CURMOD 0x03000000 /* current mode (all on is user) */ 25 | #define PSL_IS 0x04000000 /* interrupt stack */ 26 | #define PSL_FPD 0x08000000 /* first part done */ 27 | #define PSL_TP 0x40000000 /* trace pending */ 28 | #define PSL_CM 0x80000000 /* compatibility mode */ 29 | 30 | #define PSL_MBZ 0x3020ff00 /* must be zero bits */ 31 | 32 | #define PSL_USERSET (PSL_PRVMOD|PSL_CURMOD) 33 | #define PSL_USERCLR (PSL_IS|PSL_IPL|PSL_MBZ) 34 | -------------------------------------------------------------------------------- /vax/reg.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)reg.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * Location of the users' stored 11 | * registers relative to R0. 12 | * Usage is u.u_ar0[XX]. 13 | */ 14 | #define R0 (-18) 15 | #define R1 (-17) 16 | #define R2 (-16) 17 | #define R3 (-15) 18 | #define R4 (-14) 19 | #define R5 (-13) 20 | #define R6 (-12) 21 | #define R7 (-11) 22 | #define R8 (-10) 23 | #define R9 (-9) 24 | #define R10 (-8) 25 | #define R11 (-7) 26 | #define R12 (-21) 27 | #define R13 (-20) 28 | 29 | #define AP (-21) 30 | #define FP (-20) 31 | #define SP (-5) 32 | #define PS (-1) 33 | #define PC (-2) 34 | -------------------------------------------------------------------------------- /vax/rpb.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)rpb.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * The restart parameter block, which is a page in (very) low 11 | * core which runs after a crash. Currently, the restart 12 | * procedure takes a dump. 13 | */ 14 | struct rpb { 15 | struct rpb *rp_selfref; /* self-reference */ 16 | int (*rp_dumprout)(); /* routine to be called */ 17 | long rp_checksum; /* checksum of 31 words of dumprout */ 18 | long rp_flag; /* set to 1 when dumprout runs */ 19 | /* the dump stack grows from the end of the rpb page not to reach here */ 20 | }; 21 | #ifdef KERNEL 22 | extern struct rpb rpb; 23 | #endif 24 | -------------------------------------------------------------------------------- /vax/rpb.s: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)rpb.s 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * This has to get loaded first (physical 0) as 780 memory restart rom 11 | * only looks for rpb on a 64K page boundary (doc isn't wrong, 12 | * it never says what size "page boundary" rpb has to be on). 13 | */ 14 | .globl _rpb 15 | _rpb: 16 | .space 508 17 | erpb: 18 | .space 4 19 | -------------------------------------------------------------------------------- /vax/symbols.raw: -------------------------------------------------------------------------------- 1 | # 2 | # Copyright (c) 1980, 1986 Regents of the University of California. 3 | # All rights reserved. The Berkeley software License Agreement 4 | # specifies the terms and conditions for redistribution. 5 | # 6 | # @(#)symbols.raw 7.1 (Berkeley) 6/5/86 7 | # 8 | _version 9 | #dmesg 10 | _msgbuf 11 | #iostat 12 | _dk_busy 13 | _dk_time 14 | _dk_xfer 15 | _dk_wds 16 | _tk_nin 17 | _tk_nout 18 | _dk_seek 19 | _cp_time 20 | _dk_mspw 21 | # _io_info 22 | #ps 23 | _proc 24 | _Usrptmap 25 | _usrpt 26 | _text 27 | _nswap 28 | _maxslp 29 | _ccpu 30 | _ecmx 31 | _nproc 32 | _ntext 33 | #pstat 34 | _inode 35 | _text 36 | _proc 37 | # _dz_tty 38 | # _dz_cnt 39 | _cons 40 | _file 41 | _Usrptmap 42 | _usrpt 43 | _nswap 44 | _swapmap 45 | # _dh11 46 | # _ndh11 47 | #vmstat 48 | _cp_time 49 | _rate 50 | _total 51 | _deficit 52 | _forkstat 53 | _sum 54 | _firstfree 55 | _maxfree 56 | # _rectime 57 | # _pgintime 58 | _dk_xfer 59 | _boottime 60 | #w 61 | _proc 62 | _swapdev 63 | _Usrptmap 64 | _usrpt 65 | _nswap 66 | _avenrun 67 | _boottime 68 | #netstat 69 | _mbstat 70 | _ipstat 71 | _tcb 72 | _tcpstat 73 | _udb 74 | _udpstat 75 | _rawcb 76 | _Sysmap 77 | _Syssize 78 | _ifnet 79 | _rthost 80 | _rtnet 81 | _icmpstat 82 | #routed 83 | _ifnet 84 | #rwho 85 | _avenrun 86 | _boottime 87 | -------------------------------------------------------------------------------- /vax/symbols.sort: -------------------------------------------------------------------------------- 1 | _Sysmap 2 | _Syssize 3 | _Usrptmap 4 | _avenrun 5 | _boottime 6 | _ccpu 7 | _cons 8 | _cp_time 9 | _deficit 10 | _dk_busy 11 | _dk_mspw 12 | _dk_seek 13 | _dk_time 14 | _dk_wds 15 | _dk_xfer 16 | _ecmx 17 | _file 18 | _firstfree 19 | _forkstat 20 | _icmpstat 21 | _ifnet 22 | _inode 23 | _ipstat 24 | _maxfree 25 | _maxslp 26 | _mbstat 27 | _msgbuf 28 | _nproc 29 | _nswap 30 | _ntext 31 | _proc 32 | _rate 33 | _rawcb 34 | _rthost 35 | _rtnet 36 | _sum 37 | _swapdev 38 | _swapmap 39 | _tcb 40 | _tcpstat 41 | _text 42 | _tk_nin 43 | _tk_nout 44 | _total 45 | _udb 46 | _udpstat 47 | _usrpt 48 | _version 49 | -------------------------------------------------------------------------------- /vax/tags: -------------------------------------------------------------------------------- 1 | ../sys/tags -------------------------------------------------------------------------------- /vax/trap.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)trap.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * Trap type values 11 | */ 12 | 13 | /* The first three constant values are known to the real world */ 14 | #define T_RESADFLT 0 /* reserved addressing fault */ 15 | #define T_PRIVINFLT 1 /* privileged instruction fault */ 16 | #define T_RESOPFLT 2 /* reserved operand fault */ 17 | /* End of known constants */ 18 | #define T_BPTFLT 3 /* bpt instruction fault */ 19 | #define T_XFCFLT 4 /* xfc instruction fault */ 20 | #define T_SYSCALL 5 /* chmk instruction (syscall trap) */ 21 | #define T_ARITHTRAP 6 /* arithmetic trap */ 22 | #define T_ASTFLT 7 /* software level 2 trap (ast deliv) */ 23 | #define T_SEGFLT 8 /* segmentation fault */ 24 | #define T_PROTFLT 9 /* protection fault */ 25 | #define T_TRCTRAP 10 /* trace trap */ 26 | #define T_COMPATFLT 11 /* compatibility mode fault */ 27 | #define T_PAGEFLT 12 /* page fault */ 28 | #define T_TABLEFLT 13 /* page table fault */ 29 | -------------------------------------------------------------------------------- /vax/udiv.s: -------------------------------------------------------------------------------- 1 | /* 2 | * @(#)udiv.s 7.1 (Berkeley) 6/5/86 3 | * 4 | * udiv - unsigned division for vax-11 5 | * 6 | * arguments: dividend, divisor. 7 | * result: quotient. 8 | * uses r0-r2 9 | * 10 | * If 1 < divisor <= 2147483647, zero-extend the dividend 11 | * to 64 bits and let ediv do the work. If the divisor is 1, 12 | * ediv will overflow if bit 31 of the dividend is on, so 13 | * just return the dividend unchanged. If the divisor is 0, 14 | * do the ediv also, so it will generate the proper exception. 15 | * All other values of the divisor have bit 31 on: in this case 16 | * the quotient must be 0 if divisor > dividend, and 1 otherwise, 17 | * provided that the comparison is made as unsigned. 18 | */ 19 | .text 20 | .align 1 21 | .globl udiv 22 | udiv: .word 0x0000 23 | #ifdef GPROF 24 | jsb mcount 25 | #endif GPROF 26 | movl 4(ap),r0 # Dividend 27 | movl 8(ap),r2 # Divisor 28 | jeql div # If divisor=0, force exception 29 | cmpl r2,$1 # If divisor <= 1 (signed), 30 | jleq nodiv # no division is necessary 31 | div: clrl r1 # Zero-extend the dividend 32 | ediv r2,r0,r0,r2 # Divide. q->r0, r->r2 (discarded) 33 | ret 34 | nodiv: jeql retn # If divisor=1, return dividend 35 | cmpl r0,r2 # Unsigned comparison between 36 | jgequ one # dividend and divisor 37 | clrl r0 # Dividend < divisor, return 0 38 | ret 39 | one: movl $1,r0 # Dividend >= divisor, return 1 40 | retn: ret 41 | -------------------------------------------------------------------------------- /vax/urem.s: -------------------------------------------------------------------------------- 1 | /* 2 | * @(#)urem.s 7.1 (Berkeley) 6/5/86 3 | * 4 | * urem - unsigned remainder for vax-11 5 | * 6 | * arguments: dividend, divisor 7 | * result: remainder 8 | * uses r0-r2 9 | * 10 | * if 1 < divisor <= 2147483647, zero-extend the dividend 11 | * to 64 bits and let ediv do the work. If the divisor is 1, 12 | * ediv will overflow if bit 31 of the dividend is on, so 13 | * just return 0. If the divisor is 0, do the ediv also, 14 | * so it will generate the proper exception. All other values 15 | * of the divisor have bit 31 on: in this case the remainder 16 | * must be the dividend if divisor > dividend, and the dividend 17 | * minus the divisor otherwise. The comparison must be unsigned. 18 | */ 19 | .text 20 | .align 1 21 | .globl urem 22 | urem: .word 0x0000 23 | #ifdef GPROF 24 | jsb mcount 25 | #endif GPROF 26 | movl 4(ap),r0 # Dividend 27 | movl 8(ap),r2 # Divisor 28 | jeql div # If divisor=0, force exception 29 | cmpl r2,$1 # If divisor <= 1 (signed), 30 | jleq nodiv # no division is necessary 31 | div: clrl r1 # Zero-extend the dividend 32 | ediv r2,r0,r2,r0 # Divide. q->r2 (discarded), r->r0 33 | ret 34 | nodiv: jneq nzero # If divisor=1, return 0 35 | clrl r0 # (because doing the divide will overflow 36 | ret # if the dividend has its high bit on) 37 | nzero: cmpl r0,r2 # If dividend < divisor (unsigned) 38 | jlssu retn # remainder is dividend 39 | subl2 r2,r0 # else remainder is dividend - divisor 40 | retn: ret 41 | -------------------------------------------------------------------------------- /vaxif/if_mlreg.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /*CMU: if_mlreg.h 7.1 5/29/84 */ 29 | 30 | /* 31 | * File: if_mlreg.h 32 | */ 33 | -------------------------------------------------------------------------------- /vaxif/tags: -------------------------------------------------------------------------------- 1 | ../sys/tags -------------------------------------------------------------------------------- /vaxmba/tags: -------------------------------------------------------------------------------- 1 | ../sys/tags -------------------------------------------------------------------------------- /vaxuba/adreg.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)adreg.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | struct addevice { 10 | short int ad_csr; /* Control status register */ 11 | short int ad_data; /* Data buffer */ 12 | }; 13 | 14 | #define AD_CHAN ADIOSCHAN 15 | #define AD_READ ADIOGETW 16 | #define ADIOSCHAN _IOW(a, 0, int) /* set channel */ 17 | #define ADIOGETW _IOR(a, 1, int) /* read one word */ 18 | 19 | /* 20 | * Unibus CSR register bits 21 | */ 22 | 23 | #define AD_START 01 24 | #define AD_SCHMITT 020 25 | #define AD_CLOCK 040 26 | #define AD_IENABLE 0100 27 | #define AD_DONE 0200 28 | #define AD_INCENABLE 040000 29 | #define AD_ERROR 0100000 30 | -------------------------------------------------------------------------------- /vaxuba/dhreg.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)dhreg.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * DH-11 device register definitions. 11 | */ 12 | struct dhdevice { 13 | union { 14 | short dhcsr; /* control-status register */ 15 | char dhcsrl; /* low byte for line select */ 16 | } un; 17 | short dhrcr; /* receive character register */ 18 | short dhlpr; /* line parameter register */ 19 | u_short dhcar; /* current address register */ 20 | short dhbcr; /* byte count register */ 21 | u_short dhbar; /* buffer active register */ 22 | short dhbreak; /* break control register */ 23 | short dhsilo; /* silo status register */ 24 | }; 25 | 26 | /* Bits in dhcsr */ 27 | #define DH_TI 0100000 /* transmit interrupt */ 28 | #define DH_SI 0040000 /* storage interrupt */ 29 | #define DH_TIE 0020000 /* transmit interrupt enable */ 30 | #define DH_SIE 0010000 /* storage interrupt enable */ 31 | #define DH_MC 0004000 /* master clear */ 32 | #define DH_NXM 0002000 /* non-existant memory */ 33 | #define DH_MM 0001000 /* maintenance mode */ 34 | #define DH_CNI 0000400 /* clear non-existant memory interrupt */ 35 | #define DH_RI 0000200 /* receiver interrupt */ 36 | #define DH_RIE 0000100 /* receiver interrupt enable */ 37 | 38 | /* Bits in dhlpr */ 39 | #define BITS6 01 40 | #define BITS7 02 41 | #define BITS8 03 42 | #define TWOSB 04 43 | #define PENABLE 020 44 | /* DEC manuals incorrectly say this bit causes generation of even parity. */ 45 | #define OPAR 040 46 | #define HDUPLX 040000 47 | 48 | #define DH_IE (DH_TIE|DH_SIE|DH_RIE) 49 | 50 | /* Bits in dhrcr */ 51 | #define DH_PE 0010000 /* parity error */ 52 | #define DH_FE 0020000 /* framing error */ 53 | #define DH_DO 0040000 /* data overrun */ 54 | -------------------------------------------------------------------------------- /vaxuba/dmreg.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)dmreg.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * DM-11 device register definitions. 11 | */ 12 | struct dmdevice { 13 | short dmcsr; /* control status register */ 14 | short dmlstat; /* line status register */ 15 | short dmpad1[2]; 16 | }; 17 | 18 | /* bits in dm csr */ 19 | #define DM_RF 0100000 /* ring flag */ 20 | #define DM_CF 0040000 /* carrier flag */ 21 | #define DM_CTS 0020000 /* clear to send */ 22 | #define DM_SRF 0010000 /* secondary receive flag */ 23 | #define DM_CS 0004000 /* clear scan */ 24 | #define DM_CM 0002000 /* clear multiplexor */ 25 | #define DM_MM 0001000 /* maintenance mode */ 26 | #define DM_STP 0000400 /* step */ 27 | #define DM_DONE 0000200 /* scanner is done */ 28 | #define DM_IE 0000100 /* interrupt enable */ 29 | #define DM_SE 0000040 /* scan enable */ 30 | #define DM_BUSY 0000020 /* scan busy */ 31 | 32 | /* bits in dm lsr */ 33 | #define DML_RNG 0000200 /* ring */ 34 | #define DML_CAR 0000100 /* carrier detect */ 35 | #define DML_CTS 0000040 /* clear to send */ 36 | #define DML_SR 0000020 /* secondary receive */ 37 | #define DML_ST 0000010 /* secondary transmit */ 38 | #define DML_RTS 0000004 /* request to send */ 39 | #define DML_DTR 0000002 /* data terminal ready */ 40 | #define DML_LE 0000001 /* line enable */ 41 | 42 | #define DML_ON (DML_DTR|DML_RTS|DML_LE) 43 | #define DML_OFF (DML_LE) 44 | -------------------------------------------------------------------------------- /vaxuba/pdma.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)pdma.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | struct pdma { 10 | struct dzdevice *p_addr; 11 | char *p_mem; 12 | char *p_end; 13 | int p_arg; 14 | int (*p_fcn)(); 15 | }; 16 | -------------------------------------------------------------------------------- /vaxuba/tags: -------------------------------------------------------------------------------- 1 | ../sys/tags -------------------------------------------------------------------------------- /vaxuba/udareg.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)udareg.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | /* 10 | * UDA-50 registers and structures 11 | */ 12 | 13 | struct udadevice { 14 | short udaip; /* initialization and polling */ 15 | short udasa; /* status and address */ 16 | }; 17 | 18 | #define UDA_ERR 0100000 /* error bit */ 19 | #define UDA_STEP4 0040000 /* step 4 has started */ 20 | #define UDA_STEP3 0020000 /* step 3 has started */ 21 | #define UDA_STEP2 0010000 /* step 2 has started */ 22 | #define UDA_STEP1 0004000 /* step 1 has started */ 23 | #define UDA_NV 0002000 /* no host settable interrupt vector */ 24 | #define UDA_QB 0001000 /* controller supports Q22 bus */ 25 | #define UDA_DI 0000400 /* controller implements diagnostics */ 26 | #define UDA_IE 0000200 /* interrupt enable */ 27 | #define UDA_PI 0000001 /* host requests adapter purge interrupts */ 28 | #define UDA_GO 0000001 /* start operation, after init */ 29 | 30 | 31 | /* 32 | * UDA Communications Area 33 | */ 34 | 35 | struct udaca { 36 | short ca_xxx1; /* unused */ 37 | char ca_xxx2; /* unused */ 38 | char ca_bdp; /* BDP to purge */ 39 | short ca_cmdint; /* command queue transition interrupt flag */ 40 | short ca_rspint; /* response queue transition interrupt flag */ 41 | long ca_rspdsc[NRSP];/* response descriptors */ 42 | long ca_cmddsc[NCMD];/* command descriptors */ 43 | }; 44 | 45 | #define ca_ringbase ca_rspdsc[0] 46 | 47 | #define UDA_OWN 0x80000000 /* UDA owns this descriptor */ 48 | #define UDA_INT 0x40000000 /* allow interrupt on ring transition */ 49 | 50 | /* 51 | * MSCP packet info 52 | */ 53 | struct mscp_header { 54 | short uda_msglen; /* length of MSCP packet */ 55 | char uda_credits; /* low 4 bits: credits, high 4 bits: msgtype */ 56 | char uda_vcid; /* virtual circuit id */ 57 | }; 58 | -------------------------------------------------------------------------------- /vaxuba/uureg.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)uureg.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | 10 | /* 11 | * DL11-E/DL11-W UNIBUS (for TU58) controller registers 12 | */ 13 | struct uudevice { 14 | short rcs; /* receiver status register */ 15 | short rdb; /* receiver data buffer register */ 16 | short tcs; /* transmitter status register */ 17 | short tdb; /* transmitter data buffer register */ 18 | }; 19 | 20 | /* 21 | * Receiver/transmitter status register status/command bits 22 | */ 23 | #define UUCS_DONE 0x80 /* done/ready */ 24 | #define UUCS_READY 0x80 25 | #define UUCS_INTR 0x40 /* interrupt enable */ 26 | #define UUCS_MAINT 0x02 /* maintenance check (xmitter only) */ 27 | #define UUCS_BREAK 0x01 /* send break (xmitter only) */ 28 | 29 | /* 30 | * Receiver data buffer register status bits 31 | */ 32 | #define UURDB_ERROR 0x8000 /* Error (overrun or break) */ 33 | #define UURDB_ORUN 0x4000 /* Data overrun error */ 34 | #define UURDB_BREAK 0x2000 /* TU58 break */ 35 | 36 | #define UUDB_DMASK 0x00ff /* data mask (send and receive data) */ 37 | 38 | -------------------------------------------------------------------------------- /vaxuba/vpreg.h: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright (c) 1982, 1986 Regents of the University of California. 3 | * All rights reserved. The Berkeley software License Agreement 4 | * specifies the terms and conditions for redistribution. 5 | * 6 | * @(#)vpreg.h 7.1 (Berkeley) 6/5/86 7 | */ 8 | 9 | #define VPPRI (PZERO-1) 10 | 11 | struct vpdevice { 12 | short plbcr; 13 | short pbxaddr; 14 | short prbcr; 15 | u_short pbaddr; 16 | short plcsr; 17 | short plbuf; 18 | short prcsr; 19 | u_short prbuf; 20 | }; 21 | 22 | #define VP_ERROR 0100000 23 | #define VP_DTCINTR 0040000 24 | #define VP_DMAACT 0020000 25 | #define VP_READY 0000200 26 | #define VP_IENABLE 0000100 27 | #define VP_TERMCOM 0000040 28 | #define VP_FFCOM 0000020 29 | #define VP_EOTCOM 0000010 30 | #define VP_CLRCOM 0000004 31 | #define VP_RESET 0000002 32 | #define VP_SPP 0000001 33 | -------------------------------------------------------------------------------- /vm/vm_pageout.h: -------------------------------------------------------------------------------- 1 | /* 2 | **************************************************************** 3 | * Mach Operating System 4 | * Copyright (c) 1986 Carnegie-Mellon University 5 | * 6 | * This software was developed by the Mach operating system 7 | * project at Carnegie-Mellon University's Department of Computer 8 | * Science. Software contributors as of May 1986 include Mike Accetta, 9 | * Robert Baron, William Bolosky, Jonathan Chew, David Golub, 10 | * Glenn Marcy, Richard Rashid, Avie Tevanian and Michael Young. 11 | * 12 | * Some software in these files are derived from sources other 13 | * than CMU. Previous copyright and other source notices are 14 | * preserved below and permission to use such software is 15 | * dependent on licenses from those institutions. 16 | * 17 | * Permission to use the CMU portion of this software for 18 | * any non-commercial research and development purpose is 19 | * granted with the understanding that appropriate credit 20 | * will be given to CMU, the Mach project and its authors. 21 | * The Mach project would appreciate being notified of any 22 | * modifications and of redistribution of this software so that 23 | * bug fixes and enhancements may be distributed to users. 24 | * 25 | * All other rights are reserved to Carnegie-Mellon University. 26 | **************************************************************** 27 | */ 28 | /* 29 | * File: vm/vm_pageout.h 30 | * Author: Avadis Tevanian, Jr. 31 | * 32 | * Copyright (C) 1986, Avadis Tevanian, Jr. 33 | * 34 | * Header file for pageout daemon. 35 | * 36 | ************************************************************************ 37 | * HISTORY 38 | * 9-Mar-86 Avadis Tevanian (avie) at Carnegie-Mellon University 39 | * Created. 40 | ************************************************************************ 41 | */ 42 | 43 | /* 44 | * Exported data structures. 45 | */ 46 | 47 | extern int vm_pages_needed; /* should be some "event" structure XXX */ 48 | --------------------------------------------------------------------------------