static inline void disable_bridge_irq(struct irq_data *d) { cpuid_t cpu; int swlevel; swlevel = find_level(&cpu, d->irq); /* Criminal offence */ intr_disconnect_level(cpu, swlevel); }
/* * Disassociate handler with the specified interrupt. */ void hub_intr_disconnect(hub_intr_t intr_hdl) { /*REFERENCED*/ int rv; cpuid_t cpu = intr_hdl->i_cpuid; int bit = intr_hdl->i_bit; xtalk_intr_setfunc_t setfunc; setfunc = intr_hdl->i_xtalk_info.xi_setfunc; /* TBD: send disconnected interrupts somewhere harmless */ if (setfunc) (*setfunc)((xtalk_intr_t)intr_hdl); rv = intr_disconnect_level(cpu, bit); ASSERT(rv == 0); intr_hdl->i_flags &= ~HUB_INTR_IS_CONNECTED; }
/* Shutdown one of the (PCI ...) IRQs routes over a bridge. */ static void shutdown_bridge_irq(struct irq_data *d) { struct bridge_controller *bc = IRQ_TO_BRIDGE(d->irq); bridge_t *bridge = bc->base; int pin, swlevel; cpuid_t cpu; pr_debug("bridge_shutdown: irq 0x%x\n", d->irq); pin = SLOT_FROM_PCI_IRQ(d->irq); /* * map irq to a swlevel greater than 6 since the first 6 bits * of INT_PEND0 are taken */ swlevel = find_level(&cpu, d->irq); intr_disconnect_level(cpu, swlevel); bridge->b_int_enable &= ~(1 << pin); bridge->b_wid_tflush; }