aboutsummaryrefslogtreecommitdiffstats
path: root/arch/um/kernel/irq.c
diff options
context:
space:
mode:
authorJeff Dike <jdike@addtoit.com>2007-02-10 04:44:23 -0500
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-02-11 13:51:23 -0500
commitf2e62992a232544d612b7b95e932fbf3592944e1 (patch)
tree2c845c925ed522453f69d5e8c772fc9153124c2d /arch/um/kernel/irq.c
parentf688144b827749879279c3ad272b8d874fc17231 (diff)
[PATCH] uml: IRQ handler tidying
Tidying the irq code - make a variable static activate_fd can call kmalloc directly since it's now kernel code added a no-locking comment fixed a style violation Signed-off-by: Jeff Dike <jdike@addtoit.com> Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/um/kernel/irq.c')
-rw-r--r--arch/um/kernel/irq.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/arch/um/kernel/irq.c b/arch/um/kernel/irq.c
index 5c1e611f628d..50a288bb875a 100644
--- a/arch/um/kernel/irq.c
+++ b/arch/um/kernel/irq.c
@@ -79,7 +79,7 @@ skip:
79 return 0; 79 return 0;
80} 80}
81 81
82struct irq_fd *active_fds = NULL; 82static struct irq_fd *active_fds = NULL;
83static struct irq_fd **last_irq_ptr = &active_fds; 83static struct irq_fd **last_irq_ptr = &active_fds;
84 84
85extern void free_irqs(void); 85extern void free_irqs(void);
@@ -124,8 +124,8 @@ int activate_fd(int irq, int fd, int type, void *dev_id)
124 if (err < 0) 124 if (err < 0)
125 goto out; 125 goto out;
126 126
127 new_fd = um_kmalloc(sizeof(*new_fd));
128 err = -ENOMEM; 127 err = -ENOMEM;
128 new_fd = kmalloc(sizeof(struct irq_fd), GFP_KERNEL);
129 if (new_fd == NULL) 129 if (new_fd == NULL)
130 goto out; 130 goto out;
131 131
@@ -176,9 +176,8 @@ int activate_fd(int irq, int fd, int type, void *dev_id)
176 */ 176 */
177 spin_unlock_irqrestore(&irq_lock, flags); 177 spin_unlock_irqrestore(&irq_lock, flags);
178 kfree(tmp_pfd); 178 kfree(tmp_pfd);
179 tmp_pfd = NULL;
180 179
181 tmp_pfd = um_kmalloc(n); 180 tmp_pfd = kmalloc(n, GFP_KERNEL);
182 if (tmp_pfd == NULL) 181 if (tmp_pfd == NULL)
183 goto out_kfree; 182 goto out_kfree;
184 183