Added (untested) support for ATA devices. This code should be generic