# $NetBSD: GENERIC,v 1.207 2023/02/12 14:50:41 abs Exp $
#
# GENERIC machine description file
#
# This machine description file is used to generate the default NetBSD
# kernel.  The generic kernel does not include all options, subsystems
# and device drivers, but should be useful for most applications.
#
# The machine description file can be customised for your specific
# machine to reduce the kernel size and improve its performance.
#
# For further information on compiling NetBSD kernels, see the config(8)
# man page.
#
# For further information on hardware support for this architecture, see
# the intro(4) man page.  For further information about kernel options
# for this architecture, see the options(4) man page.  For an explanation
# of each device driver in this file see the section 4 man page for the
# device.

include         "arch/pmax/conf/std.pmax"

options         INCLUDE_CONFIG_FILE     # embed config file in kernel binary

#ident          "GENERIC-$Revision: 1.207 $"

maxusers        64

options         MIPS1           # R2000/R3000 CPUs
options         MIPS3           # R4000/R4400 CPUs


# Support for specific models of DECstation
options         DEC_3100        # DECstation 2100, 3100 (kn01)
options         DEC_5100        # DECsystem 5100 (kn230)
options         DEC_3MAX        # DECstation 5000/200 (kn02)
options         DEC_3MIN        # DECstation 5000/1xx (kn02ba), 5000/150 (kn04)
options         DEC_MAXINE      # Personal DECstation 5000/xx (kn02ca)
options         DEC_3MAXPLUS    # DECstation 5000/240 (kn03), 5000/260 (kn05)

#options        DEC_5400        # DECsystem 5400 (kn210)
#options        DEC_5500        # DECsystem 5500 (kn220)
#options        DEC_5800        # DECsystem 58x0 (kn5800)

makeoptions     DEBUG="-g"
# Standard system options
options         DDB                     # in-kernel debugger
options         DDB_HISTORY_SIZE=512    # enable history editing in DDB
options         DDB_ONPANIC=1           # don't enter debugger on panic
options         DDB_COMMANDONENTER="trace;show registers"
options         DIAGNOSTIC              # extra kernel debugging checks
options         DEBUG                   # extra kernel debugging support
#options        LOCKDEBUG
#options        VMFAULT_TRACE
#options        PMAP_FAULTINFO
options         KTRACE                  # system call tracing support

options         SYSVMSG         # System V-like message queues
options         SYSVSEM         # System V-like semaphores
options         SYSVSHM         # System V-like memory sharing

options         USERCONF        # userconf(4) support
#options        PIPE_SOCKETPAIR # smaller, but slower pipe(2)
options         SYSCTL_INCLUDE_DESCR    # Include sysctl descriptions in kernel

# Alternate buffer queue strategies for better responsiveness under high
# disk I/O load.
#options        BUFQ_READPRIO
options         BUFQ_PRIOCSCAN

#options        SCSIVERBOSE             # Verbose SCSI errors
#options        TCVERBOSE               # recognize "unknown" TC devices

# Old 4.4BSD/pmax kgdb options
#options        KGDB                    # support for kernel gdb
#options        KGDB_DEVRATE=19200      # kernel gdb port rate (default 9600)
#options        KGDB_DEV="15*256+0"     # device for kernel gdb

options         NTP                     # network time protocol


# File systems
file-system     FFS             # fast filesystem with user and group quotas
file-system     MFS             # memory-based filesystem
file-system     NFS             # Sun NFS-compatible filesystem (client)
file-system     LFS             # Log-based filesystem (still experimental)
file-system     CD9660          # ISO 9660 + Rock Ridge file system
file-system     FDESC           # /dev/fd
file-system     KERNFS          # /kern (kernel informational filesystem)
file-system     NULLFS          # loopback file system
file-system     OVERLAY         # overlay file system
file-system     PUFFS           # Userspace file systems (e.g. ntfs-3g & sshfs)
file-system     PROCFS          # /proc
file-system     UMAPFS          # NULLFS + uid and gid remapping
file-system     UNION
file-system     PTYFS           # /dev/pts/N support
file-system     TMPFS           # Efficient memory file-system
#file-system    UDF             # experimental - OSTA UDF CD/DVD file-system

# File system options
#options        FFS_EI          # FFS Endian Independent support
#options        FFS_NO_SNAPSHOT # No FFS snapshot support
options         QUOTA           # legacy UFS quotas
options         QUOTA2          # new, in-filesystem UFS quotas
options         UFS_DIRHASH     # UFS Large Directory Hashing
options         UFS_EXTATTR     # Extended attribute support for UFS1
options         WAPBL           # File system journaling support
options         LFS_DIRHASH     # LFS version of UFS_DIRHASH - experimental
options         NFSSERVER       # Network File System server

# Networking options
options         INET            # Internet protocols
options         INET6           # IPV6
#options        IPSEC           # IP security
#options        IPSEC_DEBUG     # debug for IP security
options         GATEWAY         # IP packet forwarding
#options        MROUTING        # Multicast routing support
#options        PIM             # Protocol Independent Multicast
options         NETATALK        # AppleTalk networking protocols
options         PPP_BSDCOMP     # BSD-Compress compression support for PPP
options         PPP_DEFLATE     # Deflate compression support for PPP
options         PPP_FILTER      # Active filter support for PPP (requires bpf)
#options        TCP_DEBUG       # Record last TCP_NDEBUG packets with SO_DEBUG

#options        ALTQ            # Manipulate network interfaces' output queues
#options        ALTQ_BLUE       # Stochastic Fair Blue
#options        ALTQ_CBQ        # Class-Based Queueing
#options        ALTQ_CDNR       # Diffserv Traffic Conditioner
#options        ALTQ_FIFOQ      # First-In First-Out Queue
#options        ALTQ_FLOWVALVE  # RED/flow-valve (red-penalty-box)
#options        ALTQ_HFSC       # Hierarchical Fair Service Curve
#options        ALTQ_LOCALQ     # Local queueing discipline
#options        ALTQ_PRIQ       # Priority Queueing
#options        ALTQ_RED        # Random Early Detection
#options        ALTQ_RIO        # RED with IN/OUT
#options        ALTQ_WFQ        # Weighted Fair Queueing

# JIT compiler for bpfilter
#options        SLJIT
#options        BPFJIT

# NetBSD backwards compatibility
include         "conf/compat_netbsd12.config"

# Workstation console options
options         FONT_BOLD8x16
options         FONT_GALLANT12x22

options         WSEMUL_VT100
options         WSDISPLAY_COMPAT_USL            # wsconscfg VT handling
options         WS_KERNEL_FG=WSCOL_GREEN
options         WS_KERNEL_BG=WSCOL_BLACK

# Disable kernel security levels.  Needed for X with a PX or PXG.
#options        INSECURE

# pmax specific
options         COMPAT_ULTRIX   # Ultrix compatibility
#options        EXEC_AOUT       # Old NetBSD/pmax a.out compatibility
options         EXEC_ECOFF      # Ultrix RISC binaries are ECOFF format
options         HZ=256          # RTC rate required

options         NFS_BOOT_DHCP   # superset of BOOTP

config          netbsd          root on ? type ?
#config         nfsnetbsd       root on ? type nfs


mainbus0        at root
cpu*            at mainbus0

## Peripheral Bus Support (for devices to attach to)
## ----------------------------------------------------------------------------

# TURBOchannel bus support
tc*     at      mainbus0

# 3MIN, 3MAX+ and MAXINE have IOASIC in system slot
ioasic0 at      tc?
mcclock* at     ioasic? offset ?        # DS1287 RTC
le*     at      ioasic? offset ?        # LANCE
dt*     at      ioasic? offset ?        # MAXINE kbd and mouse
bba*    at      ioasic? offset ?        # MAXINE baseboard audio
#fdc    at      ioasic? offset ?        # MAXINE floppy disk (not supported)
zsc0    at      ioasic? offset 0x100000 # Z85C30
zsc1    at      ioasic? offset 0x180000 # Z85C30
asc*    at      ioasic? offset ?        # NCR53C94 SCSI with IOASIC

zstty*  at      zsc? channel ?          # serial ports on B/A channels
lkkbd*  at      zsc1 channel ?          # keyboard port on A channels
vsms*   at      zsc0 channel ?          # mouse port on A channels

audio*  at      bba?

spkr*   at      audio?                  # PC speaker (synthesized)

dtkbd*  at      dt? addr ?
dtms*   at      dt? addr ?

# 3MAX has TURBOchannel but no IOASIC
ibus0   at      tc? slot ? offset ?     # 3MAX system slot

# PMAX, 3MAX and MIPSMATE common devices
mcclock* at     ibus0 addr ?            # DS1287 RTC
dz*     at      ibus0 addr ?            # DC7085 quad line serial device

lkkbd*  at      dz? line 0              # Keyboard
vsms*   at      dz? line 1              # Mouse

# TURBOchannel devices
mfb*    at      tc? slot ? offset ?     # PMAG-A MX Monochrome Framebuffer
cfb*    at      tc? slot ? offset ?     # PMAG-B CX Color Framebuffer
tfb*    at      tc? slot ? offset ?     # PMAG-RO TX True Color Framebuffer
sfb*    at      tc? slot ? offset ?     # PMAGB-B HX Smart Framebuffer
px*     at      tc? slot ? offset ?     # PMAG-C 2D accelerator
pxg*    at      tc? slot ? offset ?     # PMAG-D,E,F 3D accelerator
#sfbp*  at      tc? slot ? offset ?     # PMAGD HX+ Smart Framebuffer
xcfb*   at      tc? slot ? offset ?     # PMAG-DV Color Framebuffer at MAXINE
asc*    at      tc? slot ? offset ?     # PMAZ-A single channel SCSI
le*     at      tc? slot ? offset ?     # PMAD-A LANCE
tcds*   at      tc? slot ? offset ?     # PMAZB/PMAZC dual channel SCSI
asc*    at      tcds? chip ?

# PMAX and MIPSMATE
ibus0   at      mainbus0
pm*     at      ibus0 addr ?            # 3100 onboard fb
le*     at      ibus0 addr ?            # 3100, 5100 onboard LANCE
sii*    at      ibus0 addr ?            # DC7061 onboard SCSI

# Workstation console

wskbd*          at      lkkbd? console ?
wskbd*          at      dtkbd? console ?
wsmouse*        at      vsms?
wsmouse*        at      dtms?

wsdisplay*      at      mfb?
wsdisplay*      at      cfb?
wsdisplay*      at      px?
wsdisplay*      at      pxg?
wsdisplay*      at      sfb?
#wsdisplay*     at      sfbp?
wsdisplay*      at      tfb?
wsdisplay*      at      xcfb?
wsdisplay*      at      pm?


#########################################################################
# SCSI configuration                                                    #
#########################################################################

scsibus* at sii?
scsibus* at asc?

sd*     at scsibus? target ? lun ?      # SCSI disks
st*     at scsibus? target ? lun ?      # SCSI tapes
cd*     at scsibus? target ? lun ?      # SCSI CD-ROMs
ch*     at scsibus? target ? lun ?      # SCSI changer devices
ss*     at scsibus? target ? lun ?      # SCSI scanners
uk*     at scsibus? target ? lun ?      # unknown SCSI

#########################################################################
# Pseudo-devices                                                        #
#########################################################################

#
# accept filters
pseudo-device   accf_data               # "dataready" accept filter
pseudo-device   accf_http               # "httpready" accept filter

pseudo-device   loop                    # network loopback
pseudo-device   sl                      # serial-line IP ports
pseudo-device   ppp                     # serial-line IP ports
pseudo-device   pppoe                   # PPP over Ethernet (RFC 2516)
pseudo-device   pty                     # pseudo-terminals
pseudo-device   bpfilter                # packet filter ports
pseudo-device   carp                    # Common Address Redundancy Protocol
pseudo-device   npf                     # NPF packet filter
#pseudo-device  gre                     # generic L3 over IP tunnel
pseudo-device   gif                     # IPv[46] over IPv[46] tunnel (RFC1933)
#pseudo-device  faith                   # IPv[46] tcp relay translation i/f
pseudo-device   stf                     # 6to4 IPv6 over IPv4 encapsulation
pseudo-device   vlan                    # IEEE 802.1q encapsulation
pseudo-device   bridge                  # simple inter-network bridging
#pseudo-device  vether                  # Virtual Ethernet for bridge
pseudo-device   agr                     # IEEE 802.3ad link aggregation

pseudo-device   vnd                     # virtual disk ick
#options        VND_COMPRESSION         # compressed vnd(4)
pseudo-device   ccd                     # concatenated disks
#pseudo-device  cgd                     # cryptographic disk devices
pseudo-device   raid                    # RAIDframe disk driver
options         RAID_AUTOCONFIG         # auto-configuration of RAID components
# Options to enable various other RAIDframe RAID types.
#options        RF_INCLUDE_EVENODD=1
#options        RF_INCLUDE_RAID5_RS=1
#options        RF_INCLUDE_PARITYLOGGING=1
#options        RF_INCLUDE_CHAINDECLUSTER=1
#options        RF_INCLUDE_INTERDECLUSTER=1
#options        RF_INCLUDE_PARITY_DECLUSTERING=1
#options        RF_INCLUDE_PARITY_DECLUSTERING_DS=1
pseudo-device   fss                     # file system snapshot device
pseudo-device   putter                  # for puffs and pud

pseudo-device   clockctl                # user control of clock subsystem
pseudo-device   drvctl                  # user control of drive subsystem
pseudo-device   ksyms                   # /dev/ksyms
pseudo-device   swwdog                  # software watchdog timer -- swwdog(4)
pseudo-device   wsfont                  # wsfont control device
pseudo-device   wsmux                   # wsmux control device

include "dev/veriexec.config"

options         PAX_ASLR_DEBUG=1        # PaX ASLR debug
options         PAX_SEGVGUARD=0         # PaX Segmentation fault guard
options         PAX_MPROTECT=1          # PaX mprotect(2) restrictions
options         PAX_MPROTECT_DEBUG=1    # PaX mprotect debug
options         PAX_ASLR=1              # PaX Address Space Layout Randomization

# Pull in optional local configuration - always at end
cinclude        "arch/pmax/conf/GENERIC.local"