Fixed bug in ata caching code.