If we are not transfering any data, use a non S/G ccb type that doesn't
return residual information. It seems that some firmware revisions dislike
S/G ccbs with 0 length S/G lists.
Correct bt_cmd() so that we always honor command status that was latched
by our interrupt routine while polling for completion..
for possible buffer overflow problems. Replaced most sprintf()'s
with snprintf(); for others cases, added terminating NUL bytes where
appropriate, replaced constants like "16" with sizeof(), etc.
These changes include several bug fixes, but most changes are for
maintainability's sake. Any instance where it wasn't "immediately
obvious" that a buffer overflow could not occur was made safer.
Reviewed by: Bruce Evans <bde@zeta.org.au>
Reviewed by: Matthew Dillon <dillon@apollo.backplane.com>
Reviewed by: Mike Spengler <mks@networkcs.com>
If the next available mailbox is not in the free state, print a warning
and handle the condition as a temporary resource shortage. The condition
should never happen, but we shouldn't panic since recovery is possible.
hasseen_isadev so this will be less noisy when conflicts do exist.
Also eliminate redundant warnings about conflicts.
Requested by: bde
Reviewed by: gibbs
o For bt and aha only probe the one I/O range if a specific I/O is specified
in the config file.
o Don't even try to probe I/O ranges that have been seen already.
o If we conflict with an IRQ or DRQ, then fail the probe.
Requested by: bde, gibbs
Approved by: jkh