diff options
author | Thomas Gleixner <tglx@linutronix.de> | 2011-02-04 11:33:49 -0500 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2011-02-08 13:37:13 -0500 |
commit | 44951a60ff888add9e84f509ffce20052e45af94 (patch) | |
tree | 7c1c6fb7009ef43fa76d6bb7c73c0d8b7d9a3699 /kernel/irq/irqdesc.c | |
parent | c305d524e5dd3c3c7a6035083e30950bea1b52dc (diff) |
genirq: Remove dead code
CONFIG_KSTAT_IRQS_ONDEMAND does not exist. It's not worth to implement
it. Use sparse irqs if you care about memory consumption of the
interrupt layer.
Found by undertaker: http://vamos.informatik.uni-erlangen.de/trac/undertaker
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Diffstat (limited to 'kernel/irq/irqdesc.c')
-rw-r--r-- | kernel/irq/irqdesc.c | 17 |
1 files changed, 0 insertions, 17 deletions
diff --git a/kernel/irq/irqdesc.c b/kernel/irq/irqdesc.c index 282f20230e67..a7ac6e1e7074 100644 --- a/kernel/irq/irqdesc.c +++ b/kernel/irq/irqdesc.c | |||
@@ -251,7 +251,6 @@ int __init early_irq_init(void) | |||
251 | for (i = 0; i < count; i++) { | 251 | for (i = 0; i < count; i++) { |
252 | desc[i].irq_data.irq = i; | 252 | desc[i].irq_data.irq = i; |
253 | desc[i].irq_data.chip = &no_irq_chip; | 253 | desc[i].irq_data.chip = &no_irq_chip; |
254 | /* TODO : do this allocation on-demand ... */ | ||
255 | desc[i].kstat_irqs = alloc_percpu(unsigned int); | 254 | desc[i].kstat_irqs = alloc_percpu(unsigned int); |
256 | alloc_masks(desc + i, GFP_KERNEL, node); | 255 | alloc_masks(desc + i, GFP_KERNEL, node); |
257 | desc_smp_init(desc + i, node); | 256 | desc_smp_init(desc + i, node); |
@@ -277,22 +276,6 @@ static void free_desc(unsigned int irq) | |||
277 | 276 | ||
278 | static inline int alloc_descs(unsigned int start, unsigned int cnt, int node) | 277 | static inline int alloc_descs(unsigned int start, unsigned int cnt, int node) |
279 | { | 278 | { |
280 | #if defined(CONFIG_KSTAT_IRQS_ONDEMAND) | ||
281 | struct irq_desc *desc; | ||
282 | unsigned int i; | ||
283 | |||
284 | for (i = 0; i < cnt; i++) { | ||
285 | desc = irq_to_desc(start + i); | ||
286 | if (desc && !desc->kstat_irqs) { | ||
287 | unsigned int __percpu *stats = alloc_percpu(unsigned int); | ||
288 | |||
289 | if (!stats) | ||
290 | return -1; | ||
291 | if (cmpxchg(&desc->kstat_irqs, NULL, stats) != NULL) | ||
292 | free_percpu(stats); | ||
293 | } | ||
294 | } | ||
295 | #endif | ||
296 | return start; | 279 | return start; |
297 | } | 280 | } |
298 | #endif /* !CONFIG_SPARSE_IRQ */ | 281 | #endif /* !CONFIG_SPARSE_IRQ */ |