aboutsummaryrefslogtreecommitdiff
path: root/sys/dev/mfi
Commit message (Collapse)AuthorAgeFilesLines
* Play better with CAM so that there aren't so many spurious warnings at boot.Scott Long2007-10-121-17/+14
| | | | Notes: svn path=/head/; revision=172588
* Update the MFI driver to support new "1078" series of hardware. ThisScott Long2007-08-254-24/+221
| | | | | | | | | | | includes the upcoming Dell PERC6 series. Many thanks to LSI for contributing this code. Submitted by: LSI Approved by: re Notes: svn path=/head/; revision=171980
* Fix a few nits relative to the previous changes:John Baldwin2007-08-132-2/+9
| | | | | | | | | | | | | - 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) Notes: svn path=/head/; revision=171822
* Teach the mfi(4) driver to handle requests from userland managementJohn Baldwin2007-08-135-29/+217
| | | | | | | | | | | applications to add and remove volumes. MFC after: 1 week Approved by: re (bmah) Reviewed by: ambrisko, scottl Notes: svn path=/head/; revision=171821
* Prepare for future integration between CAM and newbus. xpt_bus_registerScott Long2007-06-171-1/+1
| | | | | | | | | | now takes a device_t to be the parent of the bus that is being created. Most SIMs have been updated with a reasonable argument, but a few exceptions just pass NULL for now. This argument isn't used yet and the newbus integration likely won't be ready until after 7.0-RELEASE. Notes: svn path=/head/; revision=170872
* Add in a couple of things:Doug Ambrisko2007-06-042-19/+33
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - In the ioctl path let command get queued up and return when complete _without_ blocking the driving waiting for the response. This way the driver doesn't "lock up" for ~30s during a flash command. Submitted by scottl. - Add a guard so that if a DCMD of 0 is sent down the ioctl path don't send it to the controller. Return with a status of OK. This is a little strange since MegaCli doesn't seem to like something and will issue some DCMD of 0. This doesn't happen under Linux. So the emulation needs to be improved but I'm not sure what. Another strange thing is that when a DCMD of 0 gets issued under i386 the controller returns OK but in amd64 the context is messed up. - Add a guard so the context has to be with-in the legal limit so we get a reasonable error assertion versus random panic. It's going to be a challenge to figure out why MegaCli is not totally happy and then sends some bogus commands. This means that flashing firmware via the Linux tool won't work since it generates a DCMD of 0 when it should be opening the firmware for a flash update. Without this problem flashing works fine. This means there is no publicly available tool to upgrade the RAID firmware under FreeBSD right now. I plan to MFC all of the mfi changes to 6.X shortly. This might not include the SCSI pass-through changes. Submitted by: scottl Reviewed by: scottl MFC after: 3 days Notes: svn path=/head/; revision=170284
* Catch up to driver changes required for the mfip sub-driver.Scott Long2007-05-163-4/+27
| | | | Notes: svn path=/head/; revision=169611
* Add the 'mfip' sub-driver for gaining SCSI-passthrough access to devicesScott Long2007-05-161-0/+389
| | | | | | | on an MFI controller. Notes: svn path=/head/; revision=169609
* Collapse the mfi_ld object. Add an ioctl to help management apps mapScott Long2007-05-105-44/+79
| | | | | | | array Id's to FreeBSD device names. Notes: svn path=/head/; revision=169451
* o break newbus api: add a new argument of type driver_filter_t toPaolo Pisati2007-02-231-1/+1
| | | | | | | | | | | | | | | | bus_setup_intr() o add an int return code to all fast handlers o retire INTR_FAST/IH_FAST For more info: http://docs.freebsd.org/cgi/getmsg.cgi?fetch=465712+0+current/freebsd-current Reviewed by: many Approved by: re@ Notes: svn path=/head/; revision=166901
* Remove a PCI ID entry that conflicts with the AMR driver.Scott Long2007-01-231-1/+0
| | | | Notes: svn path=/head/; revision=166181
* Add PCI Id's for upcoming controllers.Scott Long2007-01-171-1/+3
| | | | | | | | Obtained from: LSI Corp. MFC After: 3 days Notes: svn path=/head/; revision=166067
* Up the event class reporting from 10 (basically, nothing) to EVT_CLASS_INFO.Scott Long2007-01-071-1/+1
| | | | | | | Submitted by: Doug Ambrisko Notes: svn path=/head/; revision=165852
* Make sure that all of the fields in the header are clean. It was possible forScott Long2007-01-021-5/+9
| | | | | | | unsafe flags to leak from one command to another. Notes: svn path=/head/; revision=165727
* Some relatively minor changes and bug fixes:Doug Ambrisko2006-12-143-65/+54
| | | | | | | | | | | | | | | | | | | | 1) s/mi/mfi/ in FreeBSD ioctl path 2) add in "\n" on various failure messages 3) cap the length of time to abort an AEN command 4) fix passing sense data back to user to make Dell's Linux firmware upgrade tool happy. 5) bump the MFI_POLL_TIMEOUT_SECS from 10s to 50s since the firmware flash command can take ~40s to return. This is some clean-up and enables RAID firmware to updated via Dell's tool. Note Dell's tool requires the updates to the Linux emulator that has been done in -current with TLS etc. I need to discuss with scottl how to better submit mfi commands to the firmware via the ioctl path so we don't do it in polled mode. Notes: svn path=/head/; revision=165225
* Change the internal API for polled commands. Calling mfi_polled_commandScott Long2006-11-181-83/+39
| | | | | | | | | | | | after calling mfi_mapcmd is no longer needed, so long as the MFI_CMD_POLLED flag is set. This change eliminates the possibility of a polled command getting posted twice to the driver. This is turn fixes panics on shutdown when INVARIANTS is set. Sponsored by: Ironport Notes: svn path=/head/; revision=164375
* - Add in FreeBSD native ioctl that models the Linux version.Doug Ambrisko2006-11-143-7/+206
| | | | | | | | | | | - Add a translation so the Linux ioctl's don't conflict with the FreeBSD definition. - Assume Linux 32bit emulation on amd64. This was tested on i386 and amd64 with the 32bit Linux MegaCli. Eventually we should do a 32bit native FreeBSD translation app. Notes: svn path=/head/; revision=164281
* Remove some debugging code that accidentally crept in.Scott Long2006-10-161-3/+1
| | | | Notes: svn path=/head/; revision=163399
* - Add a command validator for use in debugging.Scott Long2006-10-165-53/+425
| | | | | | | | | | | - Fix the locking protocol to eliminate races between normal I/O and AENs. - Various small improvements and usability tweaks. Sponsored by: IronPort Portions Submitted by: Doug Ambrisko Notes: svn path=/head/; revision=163398
* Skip the AEN event command that is always hanging out on the card.Scott Long2006-09-271-0/+2
| | | | | | | Submitted by: Doug Ambrisko Notes: svn path=/head/; revision=162688
* Fix a bad #include statmentScott Long2006-09-271-1/+1
| | | | Notes: svn path=/head/; revision=162687
* Add a command debugging module and a periodic watchdog timer.Scott Long2006-09-253-0/+287
| | | | | | | Sponsored by: IronPort Notes: svn path=/head/; revision=162619
* Allow hw.mfi.event_locale/hw.mfi.event_class to be set via loader.Doug Ambrisko2006-09-201-2/+8
| | | | | | | | If an event doesn't match the criteria then don't print it. Some events are not saved in the log (<0 class events). Notes: svn path=/head/; revision=162473
* Change some variable names and update some comments to help clarify someScott Long2006-09-202-36/+33
| | | | | | | confusing issues. Notes: svn path=/head/; revision=162458
* Change the class from uint8_t to int8_t so people can filter on >0Doug Ambrisko2006-09-071-1/+1
| | | | | | | events. Notes: svn path=/head/; revision=162122
* Change the event log dump on initial boot to use get_event versusDoug Ambrisko2006-09-072-68/+117
| | | | | | | | | | | | AEN. This makes the boot messages cleaner. I now know how this structure works so I can implement it versus guessing. Remove the not ready type code since it is ready now. I added the time stamp/locale/class so people can parse messages better. Create a sysctl so that we can set the locale/class level. Notes: svn path=/head/; revision=162118
* Remove old debugging code from the interrupt handler.Scott Long2006-09-071-11/+4
| | | | Notes: svn path=/head/; revision=162099
* Change mfi_add_ld to "immediate command" mode since we need to enumerateDoug Ambrisko2006-06-301-4/+7
| | | | | | | | | potential boot disks during the probe so they are read for mount root. Reviewed by: ps, scottl Notes: svn path=/head/; revision=160052
* Fix a potential problem when mfi_get_log_state and onlyPaul Saab2006-06-201-2/+4
| | | | | | | | release a command if one was allocated. Also release the command in mfi_shutdown. Notes: svn path=/head/; revision=159812
* Instead of using scsi probes to do device discovery, use the firmwarePaul Saab2006-06-205-214/+178
| | | | | | | | | commands to grab the device listing. This resolves issues using multiple volumes, where each volume was actually internally pointing to target 0. Notes: svn path=/head/; revision=159811
* Fix a typo when getting the log_state and set the flags on thePaul Saab2006-06-201-1/+1
| | | | | | | | command to signify it is being polled and expecting data to be dma'd from the card. Notes: svn path=/head/; revision=159810
* Cleanup dcmd firmware processing into a single function, mfi_dcmd_commandPaul Saab2006-06-201-85/+95
| | | | | | | | | | to avoid duplication and mistakes when setting up firmware commands for submission. Reviewed by: scottl Notes: svn path=/head/; revision=159806
* Clean up some comments and device printf failures in mfi_get_log_statePaul Saab2006-06-201-6/+3
| | | | | | | and mfi_get_controller_info. Notes: svn path=/head/; revision=159802
* Remove two debugging printfsPaul Saab2006-06-191-2/+0
| | | | Notes: svn path=/head/; revision=159762
* Fix missing \n and when there are no arg's that means just print outDoug Ambrisko2006-06-131-8/+11
| | | | | | | | | the description so we don't have to do any more queries. Disable the event query code until it figured out since but it is similar to the AEN detail so we should be able to get that working. Notes: svn path=/head/; revision=159574
* Add in a bunch of things to the mfi driver:Doug Ambrisko2006-05-187-32/+1132
| | | | | | | | | | | | | | | | | | | | | | - 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. Notes: svn path=/head/; revision=158737
* Fix some small bugs.Scott Long2006-04-101-2/+7
| | | | | | | | Submitted by: pjd Found by: Coverity Prevent (tm) Notes: svn path=/head/; revision=157624
* Fix 64-bit DMA. The problem was an incorrect flag check. Thanks to PaulScott Long2006-03-281-10/+14
| | | | | | | | | Saab for helping to track this down. Fix a error with 32bit DMA size calculation that seemed to be harmless. Add a few micro-optimizations while I'm here. Notes: svn path=/head/; revision=157237
* Handle invalid capacity parameters from the firmware.Scott Long2006-03-282-1/+7
| | | | Notes: svn path=/head/; revision=157197
* Add a driver for the new LSI MegaRAID SAS controller family. The 'MFI' nameScott Long2006-03-256-0/+2672
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 Notes: svn path=/head/; revision=157114