summaryrefslogtreecommitdiffstats
path: root/usr.sbin/mfiutil/mfi_show.c
Commit message (Collapse)AuthorAgeFilesLines
* MFC 264765,264766:jhb2014-05-181-1/+1
| | | | | | | | - Don't claim the adapter is idle if it is clearing a drive. - Fix an off by one error when checking for the stop event. This resulted in not showing the most recent event by default. - When the stop even is hit, break out of the outer loop to stop fetching more events.
* MFC r258901:sbruno2014-01-051-1/+1
| | | | | | | | svn r251516 resized the buf argument a bit too much. Pass a hardcoded size of 6 to humanize_number() to resolve this. PR: bin/184405 Submitted by: jhb
* Implement foreign volume handling. Allows admins to view foreign metadatasbruno2013-06-081-7/+23
| | | | | | | | | and clear or import it for use. PR: kern/172091 Submitted by: smh@freebsd.org Reviewed by: jhb@freebsd.org MFC after: 2 weeks
* Add support for getting and setting BBU properties related to batterymarkj2013-04-081-1/+28
| | | | | | | | | | | | relearning. Specifically, add subcommands to mfiutil(8) which allow the user to set the BBU and autolearn modes when the firmware supports it, and add a subcommand which kicks off a battery relearn. Reviewed by: sbruno, rstone Tested by: sbruno Approved by: rstone (co-mentor) MFC after: 2 weeks Sponsored by: Sandvine Incorporated
* Remove redundant code.ed2012-10-201-28/+0
| | | | | | | Both mfi_flash.c and mfi_show.c contain very similar functions to print a list of firmwares. Move these routines into mfiutil.c. Reported by: jhb
* More -Wmissing-variable-declarations fixes.ed2012-10-191-2/+0
| | | | | | | | | | | | | | | | In addition to adding `static' where possible: - bin/date: Move `retval' into extern.h to make it visible to date.c. - bin/ed: Move globally used variables into ed.h. - sbin/camcontrol: Move `verbose' into camcontrol.h and fix shadow warnings. - usr.bin/calendar: Remove unneeded variables. - usr.bin/chat: Make `line' local instead of global. - usr.bin/elfdump: Comment out unneeded function. - usr.bin/rlogin: Use _Noreturn instead of __dead2. - usr.bin/tset: Pull `Ospeed' into extern.h. - usr.sbin/mfiutil: Put global variables in mfiutil.h. - usr.sbin/pkg: Remove unused `os_corres'. - usr.sbin/quotaon, usr.sbin/repquota: Remove unused `qfname'.
* Add __unused macros to appropriate places in order to allow buildingeadler2012-06-191-7/+7
| | | | | | | with WARNS=6 on base gcc, gcc46, and clang Approved by: cperciva MFC after: 1 week
* Allow users with RO privilege to the device to read the RO attributes.eadler2012-06-191-7/+8
| | | | | | | | PR: bin/167302 Submitted by: markham breitbach <markham@ssimicro.com> Discussed with: pjd (briefly) Approved by: cperciva MFC after: 1 week
* Decode new battery status indications.sbruno2012-05-181-0/+22
| | | | | | | Requires r235634 Reviewed by: ambrisko@ MFC after: 3 days
* Improve battery capacity reportingemaste2011-09-271-10/+15
| | | | | | | | | | | | | | | | | | When a status pointer is passed in mfi_dcmd_command does not return an errno (if the ioctl is successful), so move the test for NO_HW_PRESENT outside of the error case. This should fix incorrect reporting for systems with a dead or no battery. Additionally, handle error codes other than NO_HW_PRESENT by omitting the battery capacity display. LSI's supercap-based parts (CV series) report their data using the same interface as battery-based parts, except that they do not include the capacity stats (state of charge, cumulative charge cycles, etc.) Reviewd by: jhb, bz Tested by: pluknet@, Garrett Cooper PR: bin/160581 MFC after: 1 week
* If a drive is not part of the array (i.e. missing) we need to print thebz2011-08-251-1/+1
| | | | | | | | | new line after the pd state information as well, so move it to the outside of the block. Submitted by: Mark Johnston at Sandvine Inc MFC atfer: 3 days Approved by: re (kib)
* Properly initialize an error variable to avoid returning uninitializedjhb2011-07-291-0/+1
| | | | | | | | | data when 'show drives' succeeds, often resulting in a failing exit code even though the command worked fine. Reviewed by: bz Approved by: re (kib) MFC after: 3 days
* Add global -d and -e options to either print device numbersbz2011-06-201-22/+21
| | | | | | | | | | (usually default) or enclosure:slot information as (Exx:Sxx) or both. Discussed with: jhb Reviewed by: jhb Sponsored by: Sandvine Incorporated MFC after: 1 week
* Contrary to when returning in all-good cases at the end of functions webz2011-06-091-6/+25
| | | | | | | | | | did not free memory (1) or close the file descriptor (2) in error cases. Reported by: Mark Johnston (1) Reported by: attilio (2) Reviewed by: jhb Sponsored by: Sandvine Incorporated MFC after: 1 week
* Add a 'show progress' command that shows a summary of all in-progressjhb2011-04-291-1/+110
| | | | | | | | | commands for a given adapter. Specifically, it shows the status of any drive or volume activities currently in progress similar to the 'drive process' and 'volume progress' commands. Reviewed by: emaste MFC after: 1 week
* Preserve errno in an error case.jhb2011-03-171-1/+2
| | | | Submitted by: gcooper
* Add more details to the 'show battery' command including more rawjhb2011-03-171-9/+51
| | | | | | | | capacity values, charge cycle count, temperature, and more detailed status. Reviewed by: bz, emaste (older version) MFC after: 1 week
* - Save errno values before calling warn(3) so that errors are correctlyjhb2010-10-261-22/+38
| | | | | | | | reported. - Use powerof2() from <sys/param.h> rather than a copy and paste version. Submitted by: gcooper MFC after: 1 week
* ntroduce mfiutil, a basic utility for managing LSI SAS-RAID & Dell PERC5/6scottl2009-08-131-0/+560
controllers. Controller, array, and drive status can be checked, basic attributes can be changed, and arrays and spares can be created and deleted. Controller firmware can also be flashed. This does not replace MegaCLI, found in ports, as that is officially sanctioned and supported by LSI and includes vastly more functionality. However, mfiutil is open source and guaranteed to provide basic functionality, which can be especially useful if you have a problem and can't get MegaCLI to work. Approved by: re Obtained from: Yahoo! Inc.
OpenPOWER on IntegriCloud