From b48ed8a31a366b34874b2482d9a83736471f4cdb Mon Sep 17 00:00:00 2001 From: itojun Date: Sat, 30 Aug 1997 05:49:20 +0000 Subject: [PATCH] Scsi RESERVATION CONFLICT and BUSY support for Tekram scsi cards. Checked with DC390. Pls mail me if you have any trouble with this patch. --- sys/pci/scsiiom.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/sys/pci/scsiiom.c b/sys/pci/scsiiom.c index 29fdb2dc4109..c611518357b4 100644 --- a/sys/pci/scsiiom.c +++ b/sys/pci/scsiiom.c @@ -1176,6 +1176,20 @@ SRBdone( PACB pACB, PDCB pDCB, PSRB pSRB ) pSRB->TargetStatus = 0; pcmd->error = XS_TIMEOUT; } + else if (status == SCSI_STAT_BUSY) + { +#ifdef DC390_DEBUG0 + printf("DC390: target busy at %s %d\n", __FILE__, __LINE__); +#endif + pcmd->error = XS_BUSY; + } + else if (status == SCSI_STAT_RESCONFLICT) + { +#ifdef DC390_DEBUG0 + printf("DC390: target reserved at %s %d\n", __FILE__, __LINE__); +#endif + pcmd->error = XS_BUSY; /*XXX*/ + } else { pSRB->AdaptStatus = 0; @@ -1193,6 +1207,9 @@ SRBdone( PACB pACB, PDCB pDCB, PSRB pSRB ) } else { +#ifdef DC390_DEBUG0 + printf("DC390: driver stuffup at %s %d\n", __FILE__, __LINE__); +#endif pcmd->error = XS_DRIVER_STUFFUP; } } @@ -1207,6 +1224,9 @@ SRBdone( PACB pACB, PDCB pDCB, PSRB pSRB ) } else if( pSRB->SRBStatus & PARITY_ERROR) { +#ifdef DC390_DEBUG0 + printf("DC390: driver stuffup %s %d\n", __FILE__, __LINE__); +#endif pcmd->error = XS_DRIVER_STUFFUP; } else /* No error */