[BACK]Return to eisa_machdep.c CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / sys / arch / i386 / eisa

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

Diff for /src/sys/arch/i386/eisa/eisa_machdep.c between version 1.37 and 1.37.2.1

version 1.37, 2011/09/01 15:10:31 version 1.37.2.1, 2014/05/22 11:39:51
Line 106  void
Line 106  void
 eisa_attach_hook(device_t parent, device_t self,  eisa_attach_hook(device_t parent, device_t self,
     struct eisabus_attach_args *eba)      struct eisabus_attach_args *eba)
 {  {
         extern int eisa_has_been_seen;          extern int eisa_has_been_seen;
   
         /*          /*
          * Notify others that might need to know that the EISA bus           * Notify others that might need to know that the EISA bus
Line 157  eisa_intr_map(eisa_chipset_tag_t ec, u_i
Line 157  eisa_intr_map(eisa_chipset_tag_t ec, u_i
 }  }
   
 const char *  const char *
 eisa_intr_string(eisa_chipset_tag_t ec, eisa_intr_handle_t ih)  eisa_intr_string(eisa_chipset_tag_t ec, eisa_intr_handle_t ih, char *buf,
       size_t len)
 {  {
         static char irqstr[8];          /* 4 + 2 + NULL + sanity */  
   
         if (ih == 0 || (ih & 0xff) >= NUM_LEGACY_IRQS || ih == 2)          if (ih == 0 || (ih & 0xff) >= NUM_LEGACY_IRQS || ih == 2)
                 panic("eisa_intr_string: bogus handle 0x%x", ih);                  panic("eisa_intr_string: bogus handle 0x%x", ih);
   
 #if NIOAPIC > 0  #if NIOAPIC > 0
         if (ih & APIC_INT_VIA_APIC)          if (ih & APIC_INT_VIA_APIC)
                 snprintf(irqstr, sizeof(irqstr), "apic %d int %d (irq %d)",                  snprintf(buf, len, "apic %d int %d (irq %d)",
                     APIC_IRQ_APIC(ih),                      APIC_IRQ_APIC(ih),
                     APIC_IRQ_PIN(ih),                      APIC_IRQ_PIN(ih),
                     ih&0xff);                      ih&0xff);
         else          else
                 snprintf(irqstr, sizeof(irqstr), "irq %d", ih&0xff);                  snprintf(buf, len, "irq %d", ih&0xff);
 #else  #else
         snprintf(irqstr, sizeof(irqstr), "irq %d", ih);          snprintf(buf, len, "irq %d", ih);
 #endif  #endif
         return (irqstr);          return buf;
   
 }  }
   
 const struct evcnt *  const struct evcnt *
Line 199  eisa_intr_establish(eisa_chipset_tag_t e
Line 197  eisa_intr_establish(eisa_chipset_tag_t e
   
 #if NIOAPIC > 0  #if NIOAPIC > 0
         if (ih & APIC_INT_VIA_APIC) {          if (ih & APIC_INT_VIA_APIC) {
                 pic = (struct pic *)ioapic_find(APIC_IRQ_APIC(ih));                  struct ioapic_softc * const ioapic = ioapic_find(APIC_IRQ_APIC(ih));
                 if (pic == NULL) {                  if (ioapic == NULL) {
                         aprint_error("eisa_intr_establish: bad ioapic %d\n",                          aprint_normal("eisa_intr_establish: bad ioapic %d\n",
                             APIC_IRQ_APIC(ih));                              APIC_IRQ_APIC(ih));
                         return NULL;                          return NULL;
                 }                  }
                   pic = &ioapic->sc_pic;
                 pin = APIC_IRQ_PIN(ih);                  pin = APIC_IRQ_PIN(ih);
                 irq = APIC_IRQ_LEGACY_IRQ(ih);                  irq = APIC_IRQ_LEGACY_IRQ(ih);
                 if (irq < 0 || irq >= NUM_LEGACY_IRQS)                  if (irq < 0 || irq >= NUM_LEGACY_IRQS)

Legend:
Removed from v.1.37  
changed lines
  Added in v.1.37.2.1

CVSweb <webmaster@jp.NetBSD.org>