Attach interrupt handlers during attach instead of during the first time
the interface is brought up. Without this, the boot time interrupt round-robin assignment does not think the allocated interrupt resources are active and leaves them assigned to CPU 0. While here, add descriptive tags to each interrupt handler when MSI-X is used. Reviewed by: np MFC after: 1 week
This commit is contained in:
parent
28435fb7f6
commit
ec9a9cf1e0
@ -675,6 +675,9 @@ cxgb_controller_attach(device_t dev)
|
||||
for (i = 0; i < NUM_CPL_HANDLERS; i++)
|
||||
sc->cpl_handler[i] = cpl_not_handled;
|
||||
#endif
|
||||
|
||||
t3_intr_clear(sc);
|
||||
error = cxgb_setup_interrupts(sc);
|
||||
out:
|
||||
if (error)
|
||||
cxgb_free(sc);
|
||||
@ -922,6 +925,7 @@ cxgb_setup_interrupts(adapter_t *sc)
|
||||
if (!(intr_flag & USING_MSIX) || err)
|
||||
return (err);
|
||||
|
||||
bus_describe_intr(sc->dev, sc->irq_res, sc->intr_tag, "err");
|
||||
for (i = 0; i < sc->msi_count - 1; i++) {
|
||||
rid = i + 2;
|
||||
res = bus_alloc_resource_any(sc->dev, SYS_RES_IRQ, &rid,
|
||||
@ -945,6 +949,7 @@ cxgb_setup_interrupts(adapter_t *sc)
|
||||
sc->msix_irq_rid[i] = rid;
|
||||
sc->msix_irq_res[i] = res;
|
||||
sc->msix_intr_tag[i] = tag;
|
||||
bus_describe_intr(sc->dev, res, tag, "qs%d", i);
|
||||
}
|
||||
|
||||
if (err)
|
||||
@ -1611,11 +1616,6 @@ cxgb_up(struct adapter *sc)
|
||||
alloc_filters(sc);
|
||||
setup_rss(sc);
|
||||
|
||||
t3_intr_clear(sc);
|
||||
err = cxgb_setup_interrupts(sc);
|
||||
if (err)
|
||||
goto out;
|
||||
|
||||
t3_add_configured_sysctls(sc);
|
||||
sc->flags |= FULL_INIT_DONE;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user