xref: /freebsd/sys/riscv/conf/GENERIC (revision 1323ec571215a77ddd21294f0871979d5ad6b992)
1#
2# GENERIC -- Generic kernel configuration file for FreeBSD/RISC-V
3#
4# For more information on this file, please read the config(5) manual page,
5# and/or the handbook section on Kernel Configuration Files:
6#
7#    https://docs.freebsd.org/en/books/handbook/kernelconfig/#kernelconfig-config
8#
9# The handbook is also available locally in /usr/share/doc/handbook
10# if you've installed the doc distribution, otherwise always see the
11# FreeBSD World Wide Web server (https://www.FreeBSD.org/) for the
12# latest information.
13#
14# An exhaustive list of options and more detailed explanations of the
15# device lines is also present in the ../../conf/NOTES and NOTES files.
16# If you are in doubt as to the purpose or necessity of a line, check first
17# in NOTES.
18#
19# $FreeBSD$
20
21cpu		RISCV
22ident		GENERIC
23
24makeoptions	DEBUG=-g		# Build kernel with gdb(1) debug symbols
25makeoptions	WITH_CTF=1		# Run ctfconvert(1) for DTrace support
26
27options 	SCHED_ULE		# ULE scheduler
28options 	PREEMPTION		# Enable kernel thread preemption
29options 	VIMAGE			# Subsystem virtualization, e.g. VNET
30options 	INET			# InterNETworking
31options 	INET6			# IPv6 communications protocols
32options 	TCP_HHOOK		# hhook(9) framework for TCP
33options 	IPSEC_SUPPORT		# Allow kldload of ipsec and tcpmd5
34options		ROUTE_MPATH		# Multipath routing support
35options 	TCP_OFFLOAD		# TCP offload
36options 	SCTP_SUPPORT		# Allow kldload of SCTP
37options 	FFS			# Berkeley Fast Filesystem
38options 	SOFTUPDATES		# Enable FFS soft updates support
39options 	UFS_ACL			# Support for access control lists
40options 	UFS_DIRHASH		# Improve performance on big directories
41options 	UFS_GJOURNAL		# Enable gjournal-based UFS journaling
42options 	QUOTA			# Enable disk quotas for UFS
43options 	NFSCL			# Network Filesystem Client
44options 	NFSD			# Network Filesystem Server
45options 	NFSLOCKD		# Network Lock Manager
46options 	NFS_ROOT		# NFS usable as /, requires NFSCL
47options 	MSDOSFS			# MSDOS Filesystem
48options 	CD9660			# ISO 9660 Filesystem
49options 	PROCFS			# Process filesystem (requires PSEUDOFS)
50options 	PSEUDOFS		# Pseudo-filesystem framework
51options 	TMPFS			# Efficient memory filesystem
52options 	GEOM_PART_GPT		# GUID Partition Tables.
53options 	GEOM_RAID		# Soft RAID functionality.
54options 	GEOM_LABEL		# Provides labelization
55options 	COMPAT_FREEBSD12	# Compatible with FreeBSD12
56options 	COMPAT_FREEBSD13	# Compatible with FreeBSD13
57options 	SCSI_DELAY=5000		# Delay (in ms) before probing SCSI
58options 	KTRACE			# ktrace(1) support
59options 	STACK			# stack(9) support
60options 	SYSVSHM			# SYSV-style shared memory
61options 	SYSVMSG			# SYSV-style message queues
62options 	SYSVSEM			# SYSV-style semaphores
63options 	_KPOSIX_PRIORITY_SCHEDULING # POSIX P1003_1B real-time extensions
64options 	PRINTF_BUFR_SIZE=128	# Prevent printf output being interspersed.
65options 	KBD_INSTALL_CDEV	# install a CDEV entry in /dev
66# options 	HWPMC_HOOKS		# Necessary kernel hooks for hwpmc(4)
67options 	AUDIT			# Security event auditing
68options 	CAPABILITY_MODE		# Capsicum capability mode
69options 	CAPABILITIES		# Capsicum capabilities
70options 	MAC			# TrustedBSD MAC Framework
71options 	KDTRACE_FRAME		# Ensure frames are compiled in
72options 	KDTRACE_HOOKS		# Kernel DTrace hooks
73options 	DDB_CTF			# Kernel ELF linker loads CTF data
74options 	FPE			# Floating-point extension support
75options 	RACCT			# Resource accounting framework
76options 	RACCT_DEFAULT_TO_DISABLED # Set kern.racct.enable=0 by default
77options 	RCTL			# Resource limits
78options 	SMP
79options 	INTRNG
80
81# RISC-V SBI console
82device		rcons
83
84# pseudo devices
85device		clk
86device		hwreset
87device		syscon
88device		syscon_power
89device		riscv_syscon
90
91# Bus drivers
92device		pci
93
94# Block devices
95device		scbus
96device		da
97
98# VirtIO support
99device		virtio			# Generic VirtIO bus (required)
100device		virtio_pci		# VirtIO PCI device
101device		vtnet			# VirtIO Ethernet device
102device		virtio_blk		# VirtIO Block device
103device		virtio_mmio		# VirtIO MMIO bus
104
105# NVM Express (NVMe) support
106device		nvme		# base NVMe driver
107options 	NVME_USE_NVD=0	# prefer the cam(4) based nda(4) driver
108device		nvd		# expose NVMe namespaces as disks, depends on nvme
109
110# USB support
111options 	USB_DEBUG		# enable debug msgs
112device		ohci			# OHCI USB interface
113device		uhci			# UHCI USB interface
114device		ehci			# EHCI USB interface (USB 2.0)
115device		xhci			# XHCI USB interface (USB 3.0)
116device		usb			# USB Bus (required)
117device		ukbd			# Keyboard
118device		umass			# Disks/Mass storage - Requires scbus and da
119
120# HID support
121options 	HID_DEBUG	# enable debug msgs
122device		hid		# Generic HID support
123
124# DTrace support
125# device	dtrace
126# device	dtrace_profile
127# device	dtrace_sdt
128# device	dtrace_fbt
129# device	dtrace_systrace
130# device	dtrace_prototype
131# device	dtraceall
132
133# Serial (COM) ports
134device		uart		# Generic UART driver
135device		uart_lowrisc	# lowRISC UART driver
136device		uart_ns8250	# ns8250-type UART driver
137
138# Console
139device		vt
140device		kbdmux
141
142# RTC
143device		goldfish_rtc	# QEMU RTC
144
145# Ethernet drivers
146device		cgem		# Cadence GEM Gigabit Ethernet device
147device		miibus		# MII bus support
148device		xae		# Xilinx AXI Ethernet MAC
149
150# DMA support
151device		xdma		# DMA interface
152device		axidma		# Xilinx AXI DMA Controller
153
154# GPIO
155device		gpio
156
157# SPI
158device		spibus
159device		spigen
160
161# Uncomment for memory disk
162# options 	MD_ROOT
163# options 	MD_ROOT_SIZE=32768	# 32MB ram disk
164# makeoptions	MFS_IMAGE=/path/to/img
165# options 	ROOTDEVNAME=\"ufs:/dev/md0\"
166
167# Uncomment for virtio block device
168# options 	ROOTDEVNAME=\"ufs:/dev/vtbd0\"
169
170# Debugging support.  Always need this:
171options 	KDB			# Enable kernel debugger support.
172options 	KDB_TRACE		# Print a stack trace for a panic.
173# For full debugger support use (turn off in stable branch):
174options 	DDB			# Support DDB.
175options 	GDB			# Support remote GDB.
176options 	DEADLKRES		# Enable the deadlock resolver
177options 	INVARIANTS		# Enable calls of extra sanity checking
178options 	INVARIANT_SUPPORT	# Extra sanity checks of internal structures, required by INVARIANTS
179options 	WITNESS			# Enable checks to detect deadlocks and cycles
180options 	WITNESS_SKIPSPIN	# Don't run witness on spinlocks for speed
181options 	MALLOC_DEBUG_MAXZONES=8	# Separate malloc(9) zones
182options 	ALT_BREAK_TO_DEBUGGER	# Enter debugger on keyboard escape sequence
183# options 	EARLY_PRINTF
184options 	VERBOSE_SYSINIT=0	# Support debug.verbose_sysinit, off by default
185
186# Kernel dump features.
187options		ZSTDIO			# zstd-compressed kernel and user dumps
188
189# Pseudo devices.
190device		crypto		# core crypto support
191device		loop		# Network loopback
192device		ether		# Ethernet support
193device		vlan		# 802.1Q VLAN support
194device		tuntap		# Packet tunnel.
195device		md		# Memory "disks"
196device		gif		# IPv6 and IPv4 tunneling
197device		firmware	# firmware assist module
198
199# The `bpf' device enables the Berkeley Packet Filter.
200# Be aware of the administrative consequences of enabling this!
201# Note that 'bpf' is required for DHCP.
202device		bpf		# Berkeley packet filter
203
204# Flattened Device Tree
205options 	FDT
206makeoptions	MODULES_EXTRA+="dtb/sifive"
207
208# I2C support
209device		iicbus		# Bus support, required for iicoc below.
210device		iicoc		# OpenCores I2C controller support
211
212# Allwinner device drivers
213device		aw_wdog		# Allwinner Watchdog
214files		"../allwinner/files.allwinner"
215
216# SiFive device drivers
217device		fu740_pci_dw
218device		sifive_gpio
219device		sifive_spi
220include		"../sifive/std.sifive"
221