Fix ATA SMART and CHECK POWER MODE
commitb93af93d2bbacf034af1888c96291850aa849b59
authorBrian Wheeler <bdwheele@indiana.edu>
Tue, 1 Mar 2011 13:30:23 +0000 (1 08:30 -0500)
committerKevin Wolf <kwolf@redhat.com>
Tue, 15 Mar 2011 12:21:14 +0000 (15 13:21 +0100)
tree84dd4164d0a080a528cde44d39d53ae0d142f994
parent301db7c2dd769d48e97c9a766520f8affff76cd7
Fix ATA SMART and CHECK POWER MODE

This patch fixes two things:

 1) CHECK POWER MODE

The error return value wasn't always zero, so it would show up as
offline.  Error is now explicitly set to zero.

 2) SMART

The smart values that were returned were invalid and tools like skdump
would not recognize that the smart data was actually valid and would
dump weird output.  The data has been fixed up and raw value support
was added.  Tools like skdump and palimpsest work as expected.

Signed-off-by: Brian Wheeler <bdwheele@indiana.edu>
Acked-by: Ryan Harper <ryanh@us.ibm.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
hw/ide/core.c