# Difference between 'device' and 'options'



## Chris Zhu (Jul 6, 2020)

According to config(5) manual, 'devices' are defined in sys/conf/files and 'options' are defined in sys/conf/options, but it seems to me both keywords would make the feature built into kernel, so I am not sure which one I should use in a kernel config file? Can anyone help explain the exact difference between them?  Thanks!


----------



## Mjölnir (Jul 6, 2020)

Chris Zhu said:


> According to config(5) manual, 'devices' are defined in sys/conf/files and 'options' are defined in sys/conf/options, but it seems to me both keywords would make the feature built into kernel, so I am not sure which one I should use in a kernel config file? Can anyone help explain the exact difference between them?  Thanks!



_device & devices_ includes the _driver_ for that device into the kernel.
These do not necessarily have to be physical devices, they can be virtual devices like e.g. a wlan(4) or gif(4) network interface.
_option(s)_ enables a specific _feature_ in the kernel.
some _devices_ have additional _options_, e.g. the vga(4) driver has the option VESA
E.g.: there is no _driver_ for the scheduler. Either the kernel has the option SCHED_ULE or SCHED_4BSD - there's no default & FreeBSD kernel is not Mach microkernel, i.e. you can not change the scheduler at runtime.
EDIT: Resources for Newbies 2nd EDIT: I'd suggest you stick to the precompiled GENERIC kernel and explore & learn FreeBSD for a while. Once you start to feel comfortable (you play with the system and not the other way around ), you can start to build your own kernel & world.


----------



## George (Jul 6, 2020)

> A device is a term used mostly for hardware-related activities in a system [...].











						Chapter 3. FreeBSD Basics
					

Basic commands and functionality of the FreeBSD operating system




					www.freebsd.org


----------

