]> pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/char/agp/generic.c
Merge master.kernel.org:/pub/scm/linux/kernel/git/jejb/scsi-rc-fixes-2.6
[linux-2.6-omap-h63xx.git] / drivers / char / agp / generic.c
index f902d71947ba9914507c6b900bffc17aa6915d53..3db4f4076ed4dae4292d8802b170efff796a036c 100644 (file)
@@ -37,6 +37,7 @@
 #include <linux/vmalloc.h>
 #include <linux/dma-mapping.h>
 #include <linux/mm.h>
+#include <linux/sched.h>
 #include <asm/io.h>
 #include <asm/cacheflush.h>
 #include <asm/pgtable.h>
@@ -51,28 +52,6 @@ int agp_memory_reserved;
  */
 EXPORT_SYMBOL_GPL(agp_memory_reserved);
 
-#if defined(CONFIG_X86)
-int map_page_into_agp(struct page *page)
-{
-       int i;
-       i = change_page_attr(page, 1, PAGE_KERNEL_NOCACHE);
-       /* Caller's responsibility to call global_flush_tlb() for
-        * performance reasons */
-       return i;
-}
-EXPORT_SYMBOL_GPL(map_page_into_agp);
-
-int unmap_page_from_agp(struct page *page)
-{
-       int i;
-       i = change_page_attr(page, 1, PAGE_KERNEL);
-       /* Caller's responsibility to call global_flush_tlb() for
-        * performance reasons */
-       return i;
-}
-EXPORT_SYMBOL_GPL(unmap_page_from_agp);
-#endif
-
 /*
  * Generic routines for handling agp_memory structures -
  * They use the basic page allocation routines to do the brunt of the work.
@@ -1191,7 +1170,6 @@ void *agp_generic_alloc_page(struct agp_bridge_data *bridge)
        map_page_into_agp(page);
 
        get_page(page);
-       SetPageLocked(page);
        atomic_inc(&agp_bridge->current_memory_agp);
        return page_address(page);
 }
@@ -1208,7 +1186,6 @@ void agp_generic_destroy_page(void *addr)
        page = virt_to_page(addr);
        unmap_page_from_agp(page);
        put_page(page);
-       unlock_page(page);
        free_page((unsigned long)addr);
        atomic_dec(&agp_bridge->current_memory_agp);
 }