- Fixed timeouts while waiting for an IRQ. The daemon stopped ticking
as soon as any bus task was waiting during a tick. This was because
the daemon sent the internal medium-change-check command
(HD_SCSICMD+1) to every bus task on every tick, and waited for each
to finish. When this command was sent to the bus task that was
already waiting, a deadlock resulted. The deadlock could only be
resolved by the arrival of the IRQ that the bus task was waiting for.
But if the IRQ did not arrive, the driver locked up permanently; i.e.
there was no effective timeout mechanism. There were also no checks
for media changes while the daemon was deadlocked. To solve these
problems, timeouts are now implemented by the bus tasks themselves
rather than the daemon.
- Instead of using polling for Identify commands, use an IRQ as
normal but with a short timeout (1 second). This appears to be more
reliable (bearing in mind that Identify commands may be sent to
either real or phantom drives).
- Call interrupt handler "manually" if we timeout while waiting for it
(for real drives that don't produce an IRQ when their Identify
command is complete).
- Set an error if we were expecting to transfer data using PIO as a
result of an interrupt but none is available (ATAF_DATAREQ is unset).
- Removed check for empty Identify data (obsoleted by previous
change in this list: Identify command will now fail instead).
- Replaced a 100ns delay with the standard 400ns delay in the first
device selection.
- Set two obsolete bits in the DevHead register that may be needed for
very old drives.
- Added unit number to more interrupt handler debug messages.
- Changed confusing/misleading comments.
git-svn-id: https://svn.aros.org/svn/aros/trunk/AROS@48823 fb15a70f-31f2-0310-bbcc-cdcc74a49acc