[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20070428075240.GA8256@flint.arm.linux.org.uk>
Date: Sat, 28 Apr 2007 08:52:41 +0100
From: Russell King <rmk+lkml@....linux.org.uk>
To: Giridhar Pemmasani <pgiri@...oo.com>
Cc: Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] Allow __vmalloc with GFP_ATOMIC
On Fri, Apr 27, 2007 at 09:03:33PM -0700, Giridhar Pemmasani wrote:
> Until 2.6.19, __vmalloc with GFP_ATOMIC was possible, but __get_vm_area_node
> would allocate the node itself with GFP_KERNEL, causing a warning. In 2.6.19,
> this was "fixed" by using the same flags that were passed to __vmalloc also
> in __get_vm_area_node. However, __get_vm_area_node does
> BUG_ON(in_interrupt()) now, since vmlist_lock is obtained without disabling
> bottom-half's. The patch below uses bh disabled lock for vmlist_lock, so that
> __vmalloc can be used in interrupt context.
It's worse than that. If vmalloc has to allocate a page table, the
allocation will be done as a non-atomic allocation. So, even if you
do fix __get_vm_area_node and all the other cases, if you hit a page
table allocation you'll still get a warning.
Folk need to accept that using vmalloc from atomic contexts is a
complete nono.
--
Russell King
Linux kernel 2.6 ARM Linux - http://www.arm.linux.org.uk/
maintainer of:
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists