MPS(4)
π MPS(4) π
okay bestie, pull up a chair, we're talking about mps β the LSI Fusion-MPT 2 IT/IR 6Gb/s Serial Attached SCSI/SATA driver. That's the whole vibe. Kernel interfaces manual, section 4. Let's get into it. π¦
β¨ SYNOPSIS β¨
So you wanna bake this driver into your kernel? Slip these little lines into your kernel configuration file:
device pci
device scbus
device mps
Orrrr if you'd rather just load it as a module at boot time (which, honestly, so valid), pop this line into loader.conf(5):
mps_load="YES"
πΈ DESCRIPTION πΈ
The mps driver literally provides support for Broadcom Ltd./Avago Tech (LSI) Fusion-MPT 2 IT/IR SAS controllers and WarpDrive solid state storage cards. two for one, we love to see it π
π HARDWARE π
These controllers are supported by the mps driver, no cap:
- Broadcom Ltd./Avago Tech (LSI) SAS 2004 (4 Port SAS)
- Broadcom Ltd./Avago Tech (LSI) SAS 2008 (8 Port SAS)
- Broadcom Ltd./Avago Tech (LSI) SAS 2108 (8 Port SAS)
- Broadcom Ltd./Avago Tech (LSI) SAS 2116 (16 Port SAS)
- Broadcom Ltd./Avago Tech (LSI) SAS 2208 (8 Port SAS)
- Broadcom Ltd./Avago Tech (LSI) SAS 2308 (8 Port SAS)
- Broadcom Ltd./Avago Tech (LSI) SSS6200 Solid State Storage
- Intel Integrated RAID Module RMS25JB040
- Intel Integrated RAID Module RMS25JB080
- Intel Integrated RAID Module RMS25KB040
- Intel Integrated RAID Module RMS25KB080
look at that lineup. iconic behavior fr fr β
π CONFIGURATION π
Quick glossary bestie: in every single tunable description down below, X represents the adapter number. Remember it. Live it. Love it.
π§ Interrupts (MSI / MSI-X)
Want MSI interrupts OFF for all the mps instances? Set this tunable in loader.conf(5):
hw.mps.disable_msi=1
Want MSI interrupts off for just one specific instance? Set this in loader.conf(5):
dev.mps.X.disable_msi=1
Now the MSI-X version β all instances:
hw.mps.disable_msix=1
And MSI-X for one specific instance:
dev.mps.X.disable_msix=1
π DMA Chains
To set the max number of DMA chains allocated for all adapters:
hw.mps.max_chains=NNNN
For one specific adapter:
dev.mps.X.max_chains=NNNN
The default max_chains value is 16384.
And here's your little sysctl(8) dashboard, bestie:
- The current number of free chain frames lives in the
dev.mps.X.chain_freesysctl(8)variable. - The lowest number of free chain frames seen since boot lives in the
dev.mps.X.chain_free_lowwatersysctl(8)variable. - The number of times that chain frame allocations have failed since boot lives in the
dev.mps.X.chain_alloc_failsysctl(8)variable. Use this one to figure out whether you should bump themax_chainstunable up to help performance. - The current number of active I/O commands is shown in the
dev.mps.X.io_cmds_activesysctl(8)variable.
π I/O Pages
Max number of pages used per I/O, all adapters:
hw.mps.max_io_pages=NNNN
For one specific adapter:
dev.mps.X.max_io_pages=NNNN
The default max_io_pages value is -1, which means the maximum I/O size used per I/O gets calculated using the IOCFacts values stored in the controller. The lowest value the driver will use for max_io_pages is 1 β otherwise IOCFacts gets used to calculate the max I/O size. And whichever I/O size is smaller, the one from max_io_pages or the one from IOCFacts, that's the max I/O size the driver uses. the smaller one wins. periodt.
Oh and also β the highest number of active I/O commands seen since boot is stored in the dev.mps.X.io_cmds_highwater sysctl(8) variable. π
π Excluding Devices
Devices can be excluded from mps control for all adapters by setting this tunable in loader.conf(5):
hw.mps.exclude_ids=Y
Y represents the target ID of the device. If you're excluding more than one device, separate the target IDs with commas.
Same thing, but for one specific adapter:
dev.mps.X.exclude_ids=Y
Again, Y is the target ID of the device, and multiple target IDs get separated by commas. π
π StartStopUnit (SSU) on Shutdown
Okay so here's the deal: the adapter can issue the StartStopUnit SCSI command to SATA direct-access devices during shutdown, which lets the device quiesce while powering down. π¦
To control this feature for all adapters, set the
hw.mps.enable_ssu
tunable in loader.conf(5) to one of these values:
0β Do not send SSU to either HDDs or SSDs.1β Send SSU to SSDs, but not to HDDs. This is the default value.2β Send SSU to HDDs, but not to SSDs.3β Send SSU to both HDDs and SSDs.
To control this feature for one specific adapter, set this tunable value in loader.conf(5):
dev.mps.X.enable_ssu
The same set of values are valid as when setting this tunable for all adapters. same menu, smaller table.
β³ Spinup Wait Time
Real talk: SATA disks that take several seconds to spin up and then fail the SATA Identify command might not get discovered by the driver. π Sometimes you can overcome this by increasing the value of the spinup wait time in loader.conf(5) with the
hw.mps.spinup_wait_time=NNNN
tunable. Here, NNNN represents the number of seconds to wait for SATA devices to spin up when the device fails the initial SATA Identify command.
Spinup wait times can be set for specific adapters in loader.conf(5) with the
dev.mps.X.spinup_wait_time=NNNN
tunable. NNNN is the number of seconds to wait for SATA devices to spin up when they fail the initial SATA Identify command. π«Ά
πΊοΈ Phy Number Device Mapping
Okay this one's a whole saga, stay with me bestie.
The driver can map devices discovered by the adapter so that target IDs corresponding to a specific device persist across resets and reboots. β¨ But in some cases, it's possible for devices to lose their mapped IDs due to unexpected behavior from certain hardware β like some types of enclosures.
To overcome this problem, a tunable is provided that will force the driver to map devices using the Phy number associated with the device.
β οΈ This feature is not recommended if the topology includes multiple enclosures/expanders. If multiple enclosures/expanders are present in the topology, Phy numbers are repeated, causing all devices at these Phy numbers except the first device to fail enumeration. no cap, that's bad. π
To control this feature for all adapters, set the
hw.mps.use_phy_num
tunable in loader.conf(5) to one of these values:
-1β Only use Phy numbers to map devices and bypass the driver's mapping logic.0β Never use Phy numbers to map devices.1β Use Phy numbers to map devices, but only if the driver's mapping logic fails to map the device that is being enumerated. This is the default value.
To control this feature for one specific adapter, set this tunable value in loader.conf(5):
dev.mps.X.use_phy_num
The same set of values are valid as when setting this tunable for all adapters. π
π DEBUGGING π
Driver diagnostic printing is controlled in loader.conf(5) by using the global hw.mps.debug_level and per-device dev.mps.X.debug_level tunables. And you can alter the debug level for any adapter at run-time using the sysctl(8) variable dev.mps.X.debug_level. π₯
Now, all debug_level variables can be named by either an integer value or a text string. Multiple values can be specified together by either ORing the integer values or by providing a comma-separated list of names.
And here's the cute part: a text string prefixed by + adds the specified debug levels to the existing set, while the prefix - removes them from the existing set. The current debug_level status is reported in both formats for convenience. π
The following levels are available:
0x0001βinfoβ Basic information (enabled by default)0x0002βfaultβ Driver faults (enabled by default)0x0004βeventβ Controller events0x0008βlogβ Logging data from controller0x0010βrecoveryβ Tracing of recovery operations0x0020βerrorβ Parameter errors and programming bugs0x0040βinitβ System initialization operations0x0080βxinfoβ More detailed information0x0100βuserβ Tracing of user-generated commands (IOCTL)0x0200βmappingβ Tracing of device mapping0x0400βtraceβ Tracing through driver functions
eleven whole levels. we are SO spoiled. π
π SEE ALSO π
cam(4), cd(4), ch(4), da(4), mpr(4), mpt(4), pci(4), sa(4), scsi(4), targ(4), loader.conf(5), sysctl(8)
go read them. for me. π«Ά
π HISTORY π
The mps driver first appeared in FreeBSD 9.0. β
π AUTHORS π
The mps driver was originally written by Scott Long <scottl@FreeBSD.org>. It has been improved and tested by LSI Corporation, Avago Technologies (formally LSI), and Broadcom Ltd. (formally Avago).
This man page was written by Ken Merry <ken@FreeBSD.org> with additional input from Stephen McConnell <slm@FreeBSD.org>.
shoutout to the whole team, we appreciate you. π
and that's the whole page, bestie!! this one came from the Debian crew, dated June 1, 2019, and it's the MPS(4) page through and through. go forth and slay your SAS controllers. π
β¨π¦π
π¦ where this page comes from
- debian bookworm: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- debian trixie: freebsd-manpages 12.2-2 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu jammy: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu noble: freebsd-manpages 12.2-1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu questing: freebsd-manpages 12.2-2
- ubuntu resolute: freebsd-manpages 12.2-2build1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- ubuntu stonking: freebsd-manpages 12.2-2build1 Β· BSD-2-Clause-FreeBSD AND BSD-4-Clause
- Copyright (c) 2010 Spectra Logic Corporation
- Copyright (c) 2014 LSI Corp
- Copyright (c) 2015-2017 Avago Technologies
- Copyright (c) 2015-2017 Broadcom Ltd
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms