bouyer
4849b82163
Make the xxstart() functions reentrant again, as some drivers HBA can call
scsipi_done() from their scsipi_request(). For this, add a struct scsipi_xfer * argument to scsipi_command(). If not NULL scsipi_command() will use this to enqueue this xfer, otherwise it'll try to allocate a new one. This scsipi_xfer has to be allocated and initialised by scsipi_make_xs() or equivalent. In xxstart(), allocate a scsipi_xfer using scsipi_make_xs(), and if not NULL, dequeue the buffer before calling scsipi_command(). This makes sure that scsipi_command() will not fail, and also makes sure that xxstart() won't be called again between the BUFQ_PEEK() and BUFQ_GET(). Fix "dequeued wrong buf" panics reported by Juergen Hannken-Illjes in private mail and Andreas Wrede on current-users@. Thanks to Jason Thorpe and Chuck Silver for review, and Andreas Wrede for testing the patch.
…
…
…
…
…
…
…
…
…
…
Description
No description provided
Languages
C
85.3%
Roff
7.2%
Assembly
3.1%
Shell
1.7%
Makefile
1.2%
Other
0.9%