MRSAS(4)

πŸ“¦
version 15.1 Β· 3 versions
, in freebsd 15.1

πŸ’– MRSAS(4) πŸ’–

okay bestie, welcome to mrsas(4) β€” that's section 4 of the Kernel Interfaces Manual, and it's literally the driver page for the Broadcom/LSI MegaRAID 6/12Gb/s SAS+SATA RAID controller driver. grab a boba, we're getting into it 🧚


✨ NAME ✨

mrsas β€” the Broadcom/LSI MegaRAID 6/12Gb/s SAS+SATA RAID controller driver. that's the whole vibe πŸ’…


✨ SYNOPSIS ✨

device pci
device mrsas

and in loader.conf(5):

mrsas_load="YES"

and in sysctl.conf(5):

dev.mrsas.X.disable_ocr
dev.mrsas.X.fw_outstanding
dev.mrsas.X.mrsas_fw_fault_check_delay
dev.mrsas.X.mrsas_io_timeout
hw.mrsas.X.debug_level

✨ DESCRIPTION ✨

so the mrsas driver literally detects Broadcom/LSI's 6Gb/s and 12Gb/s PCI Express SAS/SATA/NVMe RAID controllers 🫢. a disk (virtual disk or physical disk) that's attached to the mrsas driver shows up for you through camcontrol(8) as /dev/da? device nodes. there's also a cute little simple management interface provided per-controller via the /dev/mrsas? device node πŸ‘‘

the name mrsas comes from the phrase "MegaRAID SAS HBA" β€” and bestie, that's substantially different from the old "MegaRAID" driver mfi(4), which doesn't connect targets to the cam(4) layer. so yeah, that's why we needed a whole new driver that does attach targets to cam(4) 🌈

older MegaRAID controllers are supported by mfi(4) and will not work with mrsas. but plot twist: both mfi(4) and mrsas can detect and manage the Broadcom/LSI MegaRAID SAS 2208/2308/3008/3108 series of controllers πŸ‘€

the device.hints(5) option exists so you can tune the mrsas driver's behavior for LSI MegaRAID SAS 2208/2308/3008/3108 controllers. by default, the mfi(4) driver will detect these controllers. wanna know more about driver priority for MR-Fusion devices? scroll to the "PRIORITY" section, it's giving main character energy πŸ”₯

mrsas provides a priority of (-30) (between BUS_PROBE_DEFAULT and BUS_PROBE_LOW_PRIORITY) at the probe call for device id's 0x005B, 0x005D, and 0x005F β€” so mrsas does not take control of these devices without user intervention. no cap, it's polite like that πŸ™ˆ

solid-state drives (SSD) get ATA TRIM support with mrsas if the underlying adapter allows it. heads up though: this may require configuring the SSD as a Non-RAID drive rather then JBOD virtual mode ⭐


✨ HARDWARE ✨

the mrsas driver supports the following LSI/Broadcom SATA/SAS RAID controllers (controller β†’ chip β†’ speed, because we love a trio):

  • Broadcom SAS3916 β€” Aero β€” 12Gb/s
  • Broadcom SAS3908 β€” Aero β€” 12Gb/s
  • LSI MegaRAID SAS 9380 β€” Invader/Fury β€” 12Gb/s
  • LSI MegaRAID SAS 9361 β€” Invader/Fury β€” 12Gb/s
  • LSI MegaRAID SAS 9341 β€” Invader/Fury β€” 12Gb/s
  • LSI MegaRAID SAS 9286 β€” Thunderbolt β€” 6Gb/s
  • LSI MegaRAID SAS 9285 β€” Thunderbolt β€” 6Gb/s
  • LSI MegaRAID SAS 9272 β€” Thunderbolt β€” 6Gb/s
  • LSI MegaRAID SAS 9271 β€” Thunderbolt β€” 6Gb/s
  • LSI MegaRAID SAS 9270 β€” Thunderbolt β€” 6Gb/s
  • LSI MegaRAID SAS 9267 β€” Thunderbolt β€” 6Gb/s
  • LSI MegaRAID SAS 9266 β€” Thunderbolt β€” 6Gb/s
  • LSI MegaRAID SAS 9265 β€” Thunderbolt β€” 6Gb/s
  • LSI SAS 3108 β€” 12Gb/s
  • LSI SAS 3008 β€” 12Gb/s
  • LSI SAS 2308 β€” 6Gb/s
  • LSI SAS 2208 β€” 6Gb/s
  • DELL PERC H830 β€” Invader/Fury β€” 12Gb/s
  • DELL PERC H810 β€” Thunderbolt β€” 6Gb/s
  • DELL PERC H730/P β€” Invader/Fury β€” 12Gb/s
  • DELL PERC H710/P β€” Thunderbolt β€” 6Gb/s
  • DELL PERC H330 β€” Invader/Fury β€” 12Gb/s
  • Fujitsu D3116 β€” Thunderbolt β€” 6Gb/s

✨ CONFIGURATION ✨

wanna disable Online Controller Reset (OCR) for one specific mrsas driver instance? iconic move, set this tunable value in loader.conf(5):

dev.mrsas.X.disable_ocr=1

where X is the adapter number πŸ’…

wanna change the I/O timeout value for a specific mrsas driver instance? set this tunable value in loader.conf(5):

dev.mrsas.X.mrsas_io_timeout=NNNNNN

where NNNNNN is the timeout value in milli-seconds ⏱️

wanna change the firmware fault check timer value for a specific mrsas driver instance? set this tunable value in loader.conf(5):

dev.mrsas.X.mrsas_fw_fault_check_delay=NN

where NN is the fault check delay value in seconds 🌸

and if you ever wonder how much is going on right now β€” the current number of active I/O commands is shown in the dev.mrsas.X.fw_outstanding sysctl(8) variable πŸ¦‹


✨ DEBUGGING ✨

wanna see debugging prints from the mrsas driver? set the hw.mrsas.X.debug_level variable β€” where X is the adapter number β€” either in loader.conf(5) or via sysctl(8) πŸ‘‘. here's what each bit does, no gatekeeping:

  • 0x01 β€” Enable informational prints.
  • 0x02 β€” Enable tracing prints.
  • 0x04 β€” Enable prints for driver faults.
  • 0x08 β€” Enable prints for OCR and I/O timeout.
  • 0x10 β€” Enable prints for AEN events.

✨ PRIORITY ✨

the mrsas driver will always set a default (-30) priority in the PCI subsystem for selection of MR-Fusion cards. (it's between BUS_PROBE_DEFAULT and BUS_PROBE_LOW_PRIORITY, remember?) MR-Fusion Controllers include all cards with the Device IDs β€” 0x005B, 0x005D, 0x005F πŸ”₯

meanwhile the mfi(4) driver sets a priority of either BUS_PROBE_DEFAULT or BUS_PROBE_LOW_PRIORITY (depending on the device.hints setting) in the PCI subsystem for selection of MR-Fusion cards. so with that design in place, the mfi(4) driver will attach to a MR-Fusion card, given that it has a higher priority than mrsas πŸ’€

using /boot/device.hints (as mentioned below), you can give a preference for the mrsas driver to detect a MR-Fusion card instead of the mfi(4) driver:

hw.mfi.mrsas_enable="1"

at boot time, the mfi(4) driver gets priority to detect MR-Fusion controllers by default. and bestie, LSI advises users to understand how the driver selection policy works before changing this default. LSI's policy is to give priority to the mfi(4) driver to detect MR-Fusion cards, but allow for the ability to choose the mrsas driver to detect MR-Fusion cards πŸŽ€

LSI recommends setting hw.mfi.mrsas_enable="0" for customers who are using the older mfi(4) driver and do not want to switch to mrsas. for those using a MR-Fusion controller for the first time, LSI recommends using the mrsas driver and setting hw.mfi.mrsas_enable="1" ✨

ngl, changing the default behavior is well tested under most conditions β€” but unexpected behavior may pop up if more complex and unrealistic operations are executed by switching between the mfi(4) and mrsas drivers for MR-Fusion. switching drivers is designed to happen only one time. although multiple switching is possible, it is not recommended. the user should decide from boot which driver they want to use for the MR-Fusion card πŸ™ˆ

also β€” you may see different device names when switching from mfi(4) to mrsas. that behavior works as intended, and you need to change the fstab(5) entry manually if you're doing any experiments with mfi(4) and mrsas interoperability. just so you know πŸ’œ


✨ FILES ✨

  • /dev/da? β€” array/logical disk interface
  • /dev/mrsas? β€” management interface

✨ SEE ALSO ✨

cam(4), mfi(4), pci(4), device.hints(5), camcontrol(8)


✨ HISTORY ✨

the mrsas driver first appeared in FreeBSD 10.1 🌱

mfi Driver: mfi(4) is the old FreeBSD driver which started with support for Gen-1 Controllers and was extended to support up to MR-Fusion (Device ID = 0x005B, 0x005D, 0x005F).

mrsas Driver: mrsas is the new driver reworked by LSI which supports Thunderbolt and onward products. the SAS+SATA RAID controller with device id 0x005B is referred to as the Thunderbolt controller throughout this man page πŸ‘‘

cam aware HBA drivers: FreeBSD has a cam(4) layer which attaches storage devices and provides a common access mechanism to storage controllers and attached devices. the mrsas driver is cam(4) aware and devices associated with mrsas can be seen using camcontrol(8). the mfi(4) driver does not understand the cam(4) layer and it directly associates storage disks to the block layer πŸ¦‹

Thunderbolt Controller: this is the 6Gb/s MegaRAID HBA card which has device id 0x005B.

Invader Controller: this is the 12Gb/s MegaRAID HBA card which has device id 0x005D.

Fury Controller: this is the 12Gb/s MegaRAID HBA card which has device id 0x005F πŸ”₯


✨ AUTHORS ✨

the mrsas driver and this manual page were written by Kashyap Desai <Kashyap.Desai@lsi.com> β€” ty for your service 🫢


✨ CAVEATS ✨

okay listen, a couple of things that are not giving:

  • the mrsas driver exposes devices as /dev/da?, whereas mfi(4) exposes devices as /dev/mfid? β€” different names, don't get it twisted πŸ’€
  • mrsas does not support the Linux Emulator Interface, mfiutil(8), or device name aliases for switching drivers without editing fstab(5). yeah. you're editing fstab(5). sorry bestie 😭

that's the whole page, you ate it πŸ’…βœ¨

cute lil sign-off: this beauty comes from Debian, dated January 6, 2026 β€” go forth and RAID responsibly πŸŽ€πŸ’–πŸŒΈ

πŸ“¦ where this page comes from