diff options
author | Jeff Dike <jdike@addtoit.com> | 2008-05-12 17:01:52 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-05-13 11:02:22 -0400 |
commit | 43f5b3085fdd27c4edf535d938b2cb0ccead4f75 (patch) | |
tree | 63eabda9f505ed0a07e0a12fd828674cde8f7861 /arch/um/os-Linux/sigio.c | |
parent | 484f1e2c1ea58c6a4352313f7ee4edd4b52deecd (diff) |
uml: fix build when SLOB is enabled
Reintroduce uml_kmalloc for the benefit of UML libc code. The
previous tactic of declaring __kmalloc so it could be called directly
from the libc side of the house turned out to be getting too intimate
with slab, and it doesn't work with slob.
So, the uml_kmalloc wrapper is back. It calls kmalloc or whatever
that translates into, and libc code calls it.
kfree is left alone since that still works, leaving a somewhat
inconsistent API.
Signed-off-by: Jeff Dike <jdike@linux.intel.com>
Cc: WANG Cong <xiyou.wangcong@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/um/os-Linux/sigio.c')
-rw-r--r-- | arch/um/os-Linux/sigio.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/arch/um/os-Linux/sigio.c b/arch/um/os-Linux/sigio.c index abf47a7c4abd..0578481983c4 100644 --- a/arch/um/os-Linux/sigio.c +++ b/arch/um/os-Linux/sigio.c | |||
@@ -109,7 +109,7 @@ static int need_poll(struct pollfds *polls, int n) | |||
109 | if (n <= polls->size) | 109 | if (n <= polls->size) |
110 | return 0; | 110 | return 0; |
111 | 111 | ||
112 | new = kmalloc(n * sizeof(struct pollfd), UM_GFP_ATOMIC); | 112 | new = uml_kmalloc(n * sizeof(struct pollfd), UM_GFP_ATOMIC); |
113 | if (new == NULL) { | 113 | if (new == NULL) { |
114 | printk(UM_KERN_ERR "need_poll : failed to allocate new " | 114 | printk(UM_KERN_ERR "need_poll : failed to allocate new " |
115 | "pollfds\n"); | 115 | "pollfds\n"); |
@@ -243,7 +243,7 @@ static struct pollfd *setup_initial_poll(int fd) | |||
243 | { | 243 | { |
244 | struct pollfd *p; | 244 | struct pollfd *p; |
245 | 245 | ||
246 | p = kmalloc(sizeof(struct pollfd), UM_GFP_KERNEL); | 246 | p = uml_kmalloc(sizeof(struct pollfd), UM_GFP_KERNEL); |
247 | if (p == NULL) { | 247 | if (p == NULL) { |
248 | printk(UM_KERN_ERR "setup_initial_poll : failed to allocate " | 248 | printk(UM_KERN_ERR "setup_initial_poll : failed to allocate " |
249 | "poll\n"); | 249 | "poll\n"); |