* - uml-irq-handler-tidying.patch removed from -mm tree
@ 2007-02-11 22:49 akpm
0 siblings, 0 replies; only message in thread
From: akpm @ 2007-02-11 22:49 UTC (permalink / raw)
To: jdike, blaisorblade, mm-commits
The patch titled
uml: IRQ handler tidying
has been removed from the -mm tree. Its filename was
uml-irq-handler-tidying.patch
This patch was dropped because it was merged into mainline or a subsystem tree
------------------------------------------------------
Subject: uml: IRQ handler tidying
From: Jeff Dike <jdike@addtoit.com>
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>
---
arch/um/kernel/irq.c | 7 +++----
arch/um/os-Linux/irq.c | 6 +++++-
2 files changed, 8 insertions(+), 5 deletions(-)
diff -puN arch/um/kernel/irq.c~uml-irq-handler-tidying arch/um/kernel/irq.c
--- a/arch/um/kernel/irq.c~uml-irq-handler-tidying
+++ a/arch/um/kernel/irq.c
@@ -79,7 +79,7 @@ skip:
return 0;
}
-struct irq_fd *active_fds = NULL;
+static struct irq_fd *active_fds = NULL;
static struct irq_fd **last_irq_ptr = &active_fds;
extern void free_irqs(void);
@@ -124,8 +124,8 @@ int activate_fd(int irq, int fd, int typ
if (err < 0)
goto out;
- new_fd = um_kmalloc(sizeof(*new_fd));
err = -ENOMEM;
+ new_fd = kmalloc(sizeof(struct irq_fd), GFP_KERNEL);
if (new_fd == NULL)
goto out;
@@ -176,9 +176,8 @@ int activate_fd(int irq, int fd, int typ
*/
spin_unlock_irqrestore(&irq_lock, flags);
kfree(tmp_pfd);
- tmp_pfd = NULL;
- tmp_pfd = um_kmalloc(n);
+ tmp_pfd = kmalloc(n, GFP_KERNEL);
if (tmp_pfd == NULL)
goto out_kfree;
diff -puN arch/um/os-Linux/irq.c~uml-irq-handler-tidying arch/um/os-Linux/irq.c
--- a/arch/um/os-Linux/irq.c~uml-irq-handler-tidying
+++ a/arch/um/os-Linux/irq.c
@@ -20,6 +20,10 @@
#include "os.h"
#include "um_malloc.h"
+/*
+ * Locked by irq_lock in arch/um/kernel/irq.c. Changed by os_create_pollfd
+ * and os_free_irq_by_cb, which are called under irq_lock.
+ */
static struct pollfd *pollfds = NULL;
static int pollfds_num = 0;
static int pollfds_size = 0;
@@ -58,7 +62,7 @@ int os_create_pollfd(int fd, int events,
if (pollfds_num == pollfds_size) {
if (size_tmpfds <= pollfds_size * sizeof(pollfds[0])) {
/* return min size needed for new pollfds area */
- return((pollfds_size + 1) * sizeof(pollfds[0]));
+ return (pollfds_size + 1) * sizeof(pollfds[0]);
}
if (pollfds != NULL) {
_
Patches currently in -mm which might be from jdike@addtoit.com are
origin.patch
uml-fix-prototypes.patch
dynamic-kernel-command-line-common.patch
dynamic-kernel-command-line-um.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2007-02-11 22:49 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-02-11 22:49 - uml-irq-handler-tidying.patch removed from -mm tree akpm
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.