Exemplo n.º 1
0
void *
jensenio_eisa_intr_establish(void *v, int irq, int type, int level,
    int (*fn)(void *), void *arg)
{
	void *cookie;

	if (irq >= JENSEN_MAX_IRQ || type == IST_NONE)
		panic("jensenio_eisa_intr_establish: bogus irq or type");

	if (jensenio_intr_deftype[irq] == IST_UNUSABLE) {
		printf("jensenio_eisa_intr_establish: IRQ %d not usable\n",
		    irq);
		return (NULL);
	}

	cookie = alpha_shared_intr_establish(jensenio_eisa_intr, irq,
	    type, level, fn, arg, "eisa irq");

	if (cookie != NULL &&
	    alpha_shared_intr_firstactive(jensenio_eisa_intr, irq)) {
		scb_set(0x800 + SCB_IDXTOVEC(irq), jensenio_iointr, NULL,
		    level);
		jensenio_setlevel(irq,
		    alpha_shared_intr_get_sharetype(jensenio_eisa_intr,
						    irq) == IST_LEVEL);
		jensenio_enable_intr(irq, 1);
	}

	return (cookie);
}
Exemplo n.º 2
0
void *
dec_550_intr_establish(void *ccv, pci_intr_handle_t ih, int level, int (*func)(void *), void *arg)
{
#if 0
	struct cia_config *ccp = ccv;
#endif
	void *cookie;

#if NSIO
	if (DEC_550_LINE_IS_ISA(ih))
		return (sio_intr_establish(NULL /*XXX*/,
		    DEC_550_LINE_ISA_IRQ(ih), IST_LEVEL, level, func, arg));
#endif

	if (ih >= DEC_550_MAX_IRQ)
		panic("dec_550_intr_establish: bogus dec 550 IRQ 0x%lx", ih);

	cookie = alpha_shared_intr_establish(dec_550_pci_intr, ih, IST_LEVEL,
	    level, func, arg, "dec 550 irq");

	if (cookie != NULL &&
	    alpha_shared_intr_firstactive(dec_550_pci_intr, ih)) {
		scb_set(0x900 + SCB_IDXTOVEC(ih), dec_550_iointr, NULL,
		    level);
		dec_550_intr_enable(ih);
	}
	return (cookie);
}
Exemplo n.º 3
0
void *
dec_eb66_intr_establish(void *lcv, pci_intr_handle_t ih, int level, int (*func)(void *), void *arg)
{
	void *cookie;

	if (ih >= EB66_MAX_IRQ)
		panic("dec_eb66_intr_establish: bogus eb66 IRQ 0x%lx", ih);

	cookie = alpha_shared_intr_establish(eb66_pci_intr, ih, IST_LEVEL,
	    level, func, arg, "eb66 irq");

	if (cookie != NULL &&
	    alpha_shared_intr_firstactive(eb66_pci_intr, ih)) {
		scb_set(0x900 + SCB_IDXTOVEC(ih), eb66_iointr, NULL,
		    level);
		eb66_intr_enable(ih);
	}
	return (cookie);
}
Exemplo n.º 4
0
void *
sio_intr_establish(void *v, int irq, int type, int level, int (*fn)(void *), void *arg)
{
	void *cookie;

	if (irq > ICU_LEN || type == IST_NONE)
		panic("sio_intr_establish: bogus irq or type");

	cookie = alpha_shared_intr_establish(sio_intr, irq, type, level, fn,
	    arg, "isa irq");

	if (cookie != NULL &&
	    alpha_shared_intr_firstactive(sio_intr, irq)) {
		scb_set(0x800 + SCB_IDXTOVEC(irq), sio_iointr, NULL,
		    level);
		sio_setirqstat(irq, 1,
		    alpha_shared_intr_get_sharetype(sio_intr, irq));
	}

	return (cookie);
}
void *
dec_eb164_intr_establish(void *ccv, pci_intr_handle_t ih, int level, int (*func)(void *), void *arg)
{
#if 0
	struct cia_config *ccp = ccv;
#endif
	void *cookie;

	if (ih > EB164_MAX_IRQ)
		panic("dec_eb164_intr_establish: bogus eb164 IRQ 0x%lx", ih);

	cookie = alpha_shared_intr_establish(eb164_pci_intr, ih, IST_LEVEL,
	    level, func, arg, "eb164 irq");

	if (cookie != NULL &&
	    alpha_shared_intr_firstactive(eb164_pci_intr, ih)) {
		scb_set(0x900 + SCB_IDXTOVEC(ih), eb164_iointr, NULL,
		   level);
		eb164_intr_enable(ih);
	}
	return (cookie);
}
Exemplo n.º 6
0
void *
dec_1000a_intr_establish(
	void *ccv,
	pci_intr_handle_t ih,
	int level,
	int (*func)(void *),
	void *arg)
{
	void *cookie;

	if (ih >= PCI_NIRQ)
	        panic("dec_1000a_intr_establish: IRQ too high, 0x%lx", ih);

	cookie = alpha_shared_intr_establish(dec_1000a_pci_intr, ih, IST_LEVEL,
	    level, func, arg, "dec_1000a irq");

	if (cookie != NULL &&
	    alpha_shared_intr_firstactive(dec_1000a_pci_intr, ih)) {
		scb_set(0x900 + SCB_IDXTOVEC(ih), dec_1000a_iointr, NULL,
		    level);
		dec_1000a_enable_intr(ih);
	}
	return (cookie);
}