I found a possibly easier work around: after I disabled SMART support on the device, I can safely run devkit-disks-probe-ata-smart (or udisks-probe-ata-smart in lucid):
sudo smartctl --smart off /dev/sda
You can check if smart is disabled, with 'sudo smartctl -i /dev/sda', the output should include (note the last line):
SMART support is: Available - device has SMART capability.
SMART support is: Disabled
Note the following comment in the smartctl manual: "In principle the SMART feature settings are preserved over power-cycling, but it doesn´t hurt to be sure." I have not yet rebooted.
Looking at the strace of devkit-disks/udisks-probe-ata-smart, I see that the second (dangerous) ioctl is not executed when smart is disabled.
I found a possibly easier work around: after I disabled SMART support on the device, I can safely run devkit- disks-probe- ata-smart (or udisks- probe-ata- smart in lucid):
sudo smartctl --smart off /dev/sda
You can check if smart is disabled, with 'sudo smartctl -i /dev/sda', the output should include (note the last line):
SMART support is: Available - device has SMART capability.
SMART support is: Disabled
Note the following comment in the smartctl manual: "In principle the SMART feature settings are preserved over power-cycling, but it doesn´t hurt to be sure." I have not yet rebooted.
Looking at the strace of devkit- disks/udisks- probe-ata- smart, I see that the second (dangerous) ioctl is not executed when smart is disabled.