History log of /freebsd-10.1-release/sys/dev/mfi/mfi_pci.c
Revision Date Author Comments
(<<< Hide modified files)
(Show modified files >>>)
# 272461 02-Oct-2014 gjb

Copy stable/10@r272459 to releng/10.1 as part of
the 10.1-RELEASE process.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation

# 270732 27-Aug-2014 markj

MFC r261491 (by ambrisko):
Add a tunable "hw.mfi.mrsas_enable" to allow mfi(4) to drop priority and
allow mrsas(4) from LSI to attach to newer LSI cards that are support by
mrsas(4). If mrsas(4) is not loaded into the system at boot then mfi(4)
will always attach. If a modified mrsas(4) is loaded in the system. That
modification is return "-30" in it's probe since that is between
BUS_PROBE_DEFAULT and BUS_PROBE_LOW_PRIORITY.

This option is controller by a new probe flag "MFI_FLAGS_MRSAS" in mfi_ident
that denotes cards that should work with mrsas(4). New entries that should
have this option.

This is the first step to get mrsas(4) checked into FreeBSD and to avoid
collision with people that use mrsas(4) from LSI. Since mfi(4) takes
priority, then mrsas(4) users need to rebuild GENERIC. Using the
.disabled="1" method doesn't work since that blocks attaching and the
probe gave it to mfi(4).

MFC r267451 (by delphij):
Correct variable for loader tunable variable hw.mfi.mrsas_enable.


# 262967 10-Mar-2014 markj

MFC r261535:
Add support for MegaRAID Fury cards. The main change needed to boot from a
9341-4i controller was to ensure that scatter/gather lists are ended with
an end-of-list marker. Both the mrsas and Linux megaraid_sas drivers use
this marker with Invader cards as well, so we do the same thing, though
it is apparently not strictly necessary.

PR: 187312


# 256281 10-Oct-2013 gjb

Copy head (r256279) to stable/10 as part of the 10.0-RELEASE cycle.

Approved by: re (implicit)
Sponsored by: The FreeBSD Foundation


# 255869 25-Sep-2013 ambrisko

Add PCI device ID for MegaRAID Invader cards. This was the only
change needed to make it work on my card.

Approved by: re (glebius)


# 254263 12-Aug-2013 scottl

Update PCI drivers to no longer look at the MEMIO-enabled bit in the PCI
command register. The lazy BAR allocation code in FreeBSD sometimes
disables this bit when it detects a range conflict, and will re-enable
it on demand when a driver allocates the BAR. Thus, the bit is no longer
a reliable indication of capability, and should not be checked. This
results in the elimination of a lot of code from drivers, and also gives
the opportunity to simplify a lot of drivers to use a helper API to set
the busmaster enable bit.

This changes fixes some recent reports of disk controllers and their
associated drives/enclosures disappearing during boot.

Submitted by: jhb
Reviewed by: jfv, marius, achadd, achim
MFC after: 1 day


# 233711 30-Mar-2012 ambrisko

MFhead_mfi r227068
First cut of new HW support from LSI and merge into FreeBSD.
Supports Drake Skinny and ThunderBolt cards.
MFhead_mfi r227574
Style
MFhead_mfi r227579
Use bus_addr_t instead of uintXX_t.
MFhead_mfi r227580
MSI support
MFhead_mfi r227612
More bus_addr_t and remove "#ifdef __amd64__".
MFhead_mfi r227905
Improved timeout support from Scott.
MFhead_mfi r228108
Make file.
MFhead_mfi r228208
Fixed botched merge of Skinny support and enhanced handling
in call back routine.
MFhead_mfi r228279
Remove superfluous !TAILQ_EMPTY() checks before TAILQ_FOREACH().
MFhead_mfi r228310
Move mfi_decode_evt() to taskqueue.
MFhead_mfi r228320
Implement MFI_DEBUG for 64bit S/G lists.
MFhead_mfi r231988
Restore structure layout by reverting the array header to
use [0] instead of [1].
MFhead_mfi r232412
Put wildcard pattern later in the match table.
MFhead_mfi r232413
Use lower case for hexadecimal numbers to match surrounding
style.
MFhead_mfi r232414
Add more Thunderbolt variants.
MFhead_mfi r232888
Don't act on events prior to boot or when shutting down.
Add hw.mfi.detect_jbod_change to enable or disable acting
on JBOD type of disks being added on insert and removed on
removing. Switch hw.mfi.msi to 1 by default since it works
better on newer cards.
MFhead_mfi r233016
Release driver lock before taking Giant when deleting children.
Use TAILQ_FOREACH_SAFE when items can be deleted. Make code a
little simplier to follow. Fix a couple more style issues.
MFhead_mfi r233620
Update mfi_spare/mfi_array with the actual number of elements
for array_ref and pd. Change these max. #define names to avoid
name space collisions. This will require an update to mfiutil
It avoids mfiutil having to do a magic calculation.

Add a note and #define to state that a "SYSTEM" disk is really
what the firmware calls a "JBOD" drive.

Thanks to the many that helped, LSI for the initial code drop,
mav, delphij, jhb, sbruno that all helped with code and testing.


# 232854 12-Mar-2012 scottl

Convert a number of drivers to obtaining their parent DMA tag from their
PCI device attachment.


# 227843 22-Nov-2011 marius

- There's no need to overwrite the default device method with the default
one. Interestingly, these are actually the default for quite some time
(bus_generic_driver_added(9) since r52045 and bus_generic_print_child(9)
since r52045) but even recently added device drivers do this unnecessarily.
Discussed with: jhb, marcel
- While at it, use DEVMETHOD_END.
Discussed with: jhb
- Also while at it, use __FBSDID.


# 227562 16-Nov-2011 jhb

Add single-message MSI support to mfi(4). It is disabled by default but
can be enabled via the hw.mfi.msi tunable. Many mfi(4) controllers also
support MSI-X, but in testing it seems that many adapters do not work with
MSI-X but do work with MSI.

MFC after: 2 weeks


# 204590 02-Mar-2010 kib

Correct mfip module dependency on mfi. This allows mfip to be loaded as
module when mfi is a module itself.

Reviewed by: jhb, scottl
MFC after: 1 week


# 186132 15-Dec-2008 ambrisko

Change Dell's gen2 catch-all from Dell PERC H700/H800 to Dell PERC Gen2
and bump the driver version from 2 to 3 and fix the related style problem.

Suggested by: LSI


# 185999 12-Dec-2008 ambrisko

Sort the PCI device's and make the catch-all for new Dell
cards only apply to Dell. This gets rid of the duplicate
catch-all that I introduced that jkim caught.

Prompted by: jkim
Reviewed by: jkim


# 185994 12-Dec-2008 ambrisko

Add in some more device ID's and a generic catch-all.

Submitted by: LSI


# 185584 03-Dec-2008 ambrisko

Change new card identification names.

Submitted by: LSI
MFC after: 3 days


# 184897 12-Nov-2008 ambrisko

- Fix from jhb for failing I/O request when bus_dmamap_load fails.
- Fix to ioctl path in which the length could be 0 which means
no data in/out from LSI.
- Fix to ioctl path in which the data in the sense data space
of the ioctl packet is a really a pointer to some location in
user-space. From LSI re-worked a bit by me.
- Add HW support for next gen cards from LSI.

Thanks to LSI for their support!

Submitted by: jhb, LSI
MFC after: 3 days


# 174780 19-Dec-2007 ambrisko

Add Dell's sub-vendor id to identify PERC6 RAID controller which has LSI
vendor id's.


# 171980 25-Aug-2007 scottl

Update the MFI driver to support new "1078" series of hardware. This
includes the upcoming Dell PERC6 series. Many thanks to LSI for
contributing this code.

Submitted by: LSI
Approved by: re


# 171822 13-Aug-2007 jhb

Fix a few nits relative to the previous changes:
- Don't leak the config lock if detach() fails due to the controller char
dev being open.
- Close a race between detach() and a process opening the controller char
dev.

MFC after: 1 week
Approved by: re (bmah)


# 171821 13-Aug-2007 jhb

Teach the mfi(4) driver to handle requests from userland management
applications to add and remove volumes.

MFC after: 1 week
Approved by: re (bmah)
Reviewed by: ambrisko, scottl


# 169451 10-May-2007 scottl

Collapse the mfi_ld object. Add an ioctl to help management apps map
array Id's to FreeBSD device names.


# 166181 23-Jan-2007 scottl

Remove a PCI ID entry that conflicts with the AMR driver.


# 166067 17-Jan-2007 scottl

Add PCI Id's for upcoming controllers.

Obtained from: LSI Corp.
MFC After: 3 days


# 159811 20-Jun-2006 ps

Instead of using scsi probes to do device discovery, use the firmware
commands to grab the device listing. This resolves issues using
multiple volumes, where each volume was actually internally pointing
to target 0.


# 158737 18-May-2006 ambrisko

Add in a bunch of things to the mfi driver:
- Linux ioctl support, with the other Linux changes MegaCli
will run if you mount linprocfs & linsysfs then set
sysctl compat.linux.osrelease=2.6.12 or similar. This works
on i386. It should work on amd64 but not well tested yet.
StoreLib may or may not work. Remember to kldload mfi_linux.
- Add in AEN (Async Event Notification) support so we can
get messages from the firmware when something happens.
Not all messages are in defined in event detail. Use
event_log to try to figure out what happened.
- Try to implement something like SIGIO for StoreLib. Since
mrmonitor doesn't work right I can't fully test it. StoreLib
works best with the rh9 base. In theory mrmonitor isn't
needed due to native driver support of AEN :-)
Now we can configure and monitor the RAID better.

Submitted by: IronPort Systems.


# 157114 25-Mar-2006 scottl

Add a driver for the new LSI MegaRAID SAS controller family. The 'MFI' name
is derived from the phrase 'MegaRAID Firmware Interface' used by LSI. This
driver provides a block interface to logical disks on the card and a minimal
management device. It is MPSAFE, INTR_FAST, and 64-bit capable.

Thanks to Dell for providing hardware to test with and IronPort for
sponsoring the work.

Sponsored by: Dell, Ironport
MFC After: 3 days