]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - kernel/irq/proc.c
sparse irq_desc[] array: core kernel and x86 changes
[karo-tx-linux.git] / kernel / irq / proc.c
index fac014a81b244f232409e5c717a2e1c76f7ac1ba..f6b3440f05bc50dbe68cdb7026e4e287e227b934 100644 (file)
@@ -62,7 +62,7 @@ static ssize_t irq_affinity_proc_write(struct file *file,
        if (!cpus_intersects(new_value, cpu_online_map))
                /* Special case for empty set - allow the architecture
                   code to set default SMP affinity. */
-               return irq_select_affinity(irq) ? -EINVAL : count;
+               return irq_select_affinity_usr(irq) ? -EINVAL : count;
 
        irq_set_affinity(irq, new_value);
 
@@ -220,7 +220,7 @@ void unregister_handler_proc(unsigned int irq, struct irqaction *action)
        }
 }
 
-void register_default_affinity_proc(void)
+static void register_default_affinity_proc(void)
 {
 #ifdef CONFIG_SMP
        proc_create("irq/default_smp_affinity", 0600, NULL,
@@ -243,7 +243,11 @@ void init_irq_proc(void)
        /*
         * Create entries for all existing IRQs.
         */
-       for_each_irq_desc(irq, desc)
+       for_each_irq_desc(irq, desc) {
+               if (!desc)
+                       continue;
+
                register_irq_proc(irq, desc);
+       }
 }