CAM fixes - queue empty tests, sim refcount, add XPORT_AHCI enum.
* CAMQ_GET_HEAD assumes the head entry in the devq array is NULL to
indicate an empty queue. Fix allocations and removal code to ensure
that no bogus pointers are left in the array, cleaning it up and fixing
a bug where CAMQ_GET_HEAD() could return non-NULL even when the queue
was empty.
This fixes numerous reports on detachment of non-empty device queues
that are, in fact, empty, and also fixes a memory leak.
* xpt_bus_register() bumps the sim's refcount, but xpt_bus_deregister()
did not properly release it. This fixes a memory leak.
* Add XPORT_AHCI to the cam_xport enum for AHCI attachments.