raid/hpssacli: check for cable errors/no batteries
We had a case in the wild where the following "show status" resulted in an OK:
Controller Status: OK
Cache Status: Permanently Disabled
We already fixed the check to emit a WARNING when Cache Status is not
"OK" or "Not Configured" in a previous commit, but it seems there's
another thing we could check: "controller slot=N show detail". This had
a few more values we could check, and specifically:
Cache Status Details: Cable Error
Battery/Capacitor Count: 0
Emit CRITICAL for the former, and CRITICAL for the latter if the count
is 0 and the argument --no-battery hasn't been passed to us.
This is untested on systems that have no battery by design -- hopefully,
Cable Error won't be reported on these.
Signed-off-by: Faidon Liambotis <paravoid@debian.org>