diff --git a/classify.c b/classify.c index 6a20480..bb34f04 100644 --- a/classify.c +++ b/classify.c @@ -281,7 +281,7 @@ struct irq_info *add_misc_irq(int irq) new->irq = irq; new->type = IRQ_TYPE_LEGACY; new->class = IRQ_OTHER; - new->numa_node = get_numa_node(0); + new->numa_node = get_numa_node(-1); interrupts_db = g_list_append(interrupts_db, new); return new; } diff --git a/irqbalance.h b/irqbalance.h index a1b1e8a..73a0864 100644 --- a/irqbalance.h +++ b/irqbalance.h @@ -49,6 +49,7 @@ extern GList *numa_nodes; extern GList *packages; extern GList *cache_domains; extern GList *cpus; +extern int numa_avail; enum hp_e { HINT_POLICY_IGNORE, diff --git a/numa.c b/numa.c index 0d93091..9cbbfc0 100644 --- a/numa.c +++ b/numa.c @@ -162,6 +162,9 @@ struct topo_obj *get_numa_node(int nodeid) struct topo_obj find; GList *entry; + if (!numa_avail) + return &unspecified_node; + if (nodeid == -1) return &unspecified_node;