]> git.hungrycats.org Git - linux/commitdiff
[PATCH] Move vmalloc wrappers out of include/linux/vmalloc.h
authorTom Rini <trini@kernel.crashing.org>
Sat, 8 Jun 2002 09:12:09 +0000 (02:12 -0700)
committerLinus Torvalds <torvalds@home.transmeta.com>
Sat, 8 Jun 2002 09:12:09 +0000 (02:12 -0700)
This moves the vmalloc wrappers from <linux/vmalloc.h> into mm/vmalloc.c.

Doing this will later allow us to remove <linux/mm.h> from <linux/vmalloc.h>,
along with some other #include fixups.

include/linux/vmalloc.h
mm/vmalloc.c

index e08fcf85c24fbdddcaf22f73671137db3c19a23e..a40c2064832b822ca311adfe12dadfccdab4a42a 100644 (file)
@@ -24,33 +24,13 @@ extern long vread(char *buf, char *addr, unsigned long count);
 extern void vmfree_area_pages(unsigned long address, unsigned long size);
 extern int vmalloc_area_pages(unsigned long address, unsigned long size,
                               int gfp_mask, pgprot_t prot);
-
-/*
- *     Allocate any pages
- */
-static inline void * vmalloc (unsigned long size)
-{
-       return __vmalloc(size, GFP_KERNEL | __GFP_HIGHMEM, PAGE_KERNEL);
-}
-
 /*
- *     Allocate ISA addressable pages for broke crap
+ * Various ways to allocate pages.
  */
 
-static inline void * vmalloc_dma (unsigned long size)
-{
-       return __vmalloc(size, GFP_KERNEL|GFP_DMA, PAGE_KERNEL);
-}
-
-/*
- *     vmalloc 32bit PA addressable pages - eg for PCI 32bit devices
- */
-static inline void * vmalloc_32(unsigned long size)
-{
-       return __vmalloc(size, GFP_KERNEL, PAGE_KERNEL);
-}
+extern void * vmalloc(unsigned long size);
+extern void * vmalloc_dma(unsigned long size);
+extern void * vmalloc_32(unsigned long size);
 
 /*
  * vmlist_lock is a read-write spinlock that protects vmlist
index 5e269765466a20fb39eecfb3fb6542b2a5bd2552..a3082fa949ce54de0f8322851e352f2235111725 100644 (file)
@@ -232,6 +232,33 @@ void vfree(void * addr)
        printk(KERN_ERR "Trying to vfree() nonexistent vm area (%p)\n", addr);
 }
 
+/*
+ *     Allocate any pages
+ */
+
+void * vmalloc (unsigned long size)
+{
+       return __vmalloc(size, GFP_KERNEL | __GFP_HIGHMEM, PAGE_KERNEL);
+}
+
+/*
+ *     Allocate ISA addressable pages for broke crap
+ */
+
+void * vmalloc_dma (unsigned long size)
+{
+       return __vmalloc(size, GFP_KERNEL|GFP_DMA, PAGE_KERNEL);
+}
+
+/*
+ *     vmalloc 32bit PA addressable pages - eg for PCI 32bit devices
+ */
+
+void * vmalloc_32(unsigned long size)
+{
+       return __vmalloc(size, GFP_KERNEL, PAGE_KERNEL);
+}
+
 void * __vmalloc (unsigned long size, int gfp_mask, pgprot_t prot)
 {
        void * addr;