[BACK]Return to wdc.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / sys / dev / ic

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/sys/dev/ic/wdc.c between version 1.74.6.1 and 1.75

version 1.74.6.1, 1999/12/27 18:34:53 version 1.75, 1999/10/20 15:22:26
Line 312  wdcattach(chp)
Line 312  wdcattach(chp)
                         continue;                          continue;
   
                 /* Issue a IDENTIFY command, to try to detect slave ghost */                  /* Issue a IDENTIFY command, to try to detect slave ghost */
                 error = ata_get_params(&chp->ch_drive[i], AT_POLL, &params);                  if (ata_get_params(&chp->ch_drive[i], AT_POLL, &params) ==
                 if (error == CMD_OK) {                      CMD_OK) {
                         /* If IDENTIFY succeded, this is not an OLD ctrl */                          /* If IDENTIFY succeded, this is not an OLD ctrl */
                         chp->ch_drive[0].drive_flags &= ~DRIVE_OLD;                          chp->ch_drive[0].drive_flags &= ~DRIVE_OLD;
                         chp->ch_drive[1].drive_flags &= ~DRIVE_OLD;                          chp->ch_drive[1].drive_flags &= ~DRIVE_OLD;
                 } else {                  } else {
                         chp->ch_drive[i].drive_flags &=                          chp->ch_drive[i].drive_flags &=
                             ~(DRIVE_ATA | DRIVE_ATAPI);                              ~(DRIVE_ATA | DRIVE_ATAPI);
                         WDCDEBUG_PRINT(("%s:%d:%d: IDENTIFY failed (%d)\n",                          WDCDEBUG_PRINT(("%s:%d:%d: IDENTIFY failed\n",
                             chp->wdc->sc_dev.dv_xname,                              chp->wdc->sc_dev.dv_xname,
                             chp->channel, i, error), DEBUG_PROBE);                              chp->channel, i), DEBUG_PROBE);
                         if ((chp->ch_drive[i].drive_flags & DRIVE_OLD) == 0)                          if ((chp->ch_drive[i].drive_flags & DRIVE_OLD) == 0)
                                 continue;                                  continue;
                         /*                          /*
Line 652  wdcintr(arg)
Line 652  wdcintr(arg)
 {  {
         struct channel_softc *chp = arg;          struct channel_softc *chp = arg;
         struct wdc_xfer *xfer;          struct wdc_xfer *xfer;
         int ret;  
   
         if ((chp->ch_flags & WDCF_IRQ_WAIT) == 0) {          if ((chp->ch_flags & WDCF_IRQ_WAIT) == 0) {
                 WDCDEBUG_PRINT(("wdcintr: inactive controller\n"), DEBUG_INTR);                  WDCDEBUG_PRINT(("wdcintr: inactive controller\n"), DEBUG_INTR);
Line 662  wdcintr(arg)
Line 661  wdcintr(arg)
         WDCDEBUG_PRINT(("wdcintr\n"), DEBUG_INTR);          WDCDEBUG_PRINT(("wdcintr\n"), DEBUG_INTR);
         chp->ch_flags &= ~WDCF_IRQ_WAIT;          chp->ch_flags &= ~WDCF_IRQ_WAIT;
         xfer = chp->ch_queue->sc_xfer.tqh_first;          xfer = chp->ch_queue->sc_xfer.tqh_first;
         ret = xfer->c_intr(chp, xfer, 1);          return xfer->c_intr(chp, xfer, 1);
         if (ret == 0) /* irq was not for us, still waiting for irq */  
                 chp->ch_flags |= WDCF_IRQ_WAIT;  
         return (ret);  
 }  }
   
 /* Put all disk in RESET state */  /* Put all disk in RESET state */
Line 821  wdcwait(chp, mask, bits, timeout)
Line 817  wdcwait(chp, mask, bits, timeout)
                         break;                          break;
                 if (++time > timeout) {                  if (++time > timeout) {
                         WDCDEBUG_PRINT(("wdcwait: timeout, status %x "                          WDCDEBUG_PRINT(("wdcwait: timeout, status %x "
                             "error %x (mask 0x%x bits 0x%x)\n", status,                              "error %x\n", status,
                             bus_space_read_1(chp->cmd_iot, chp->cmd_ioh,                              bus_space_read_1(chp->cmd_iot, chp->cmd_ioh,
                                 wd_error), mask, bits),                                  wd_error)),
                             DEBUG_STATUS | DEBUG_PROBE);                              DEBUG_STATUS);
                         return -1;                          return -1;
                 }                  }
                 delay(WDCDELAY);                  delay(WDCDELAY);

Legend:
Removed from v.1.74.6.1  
changed lines
  Added in v.1.75

CVSweb <webmaster@jp.NetBSD.org>