summaryrefslogtreecommitdiffstats
path: root/drivers/char/ftape/lowlevel
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2000-02-24 00:12:35 +0000
committerRalf Baechle <ralf@linux-mips.org>2000-02-24 00:12:35 +0000
commit482368b1a8e45430672c58c9a42e7d2004367126 (patch)
treece2a1a567d4d62dee7c2e71a46a99cf72cf1d606 /drivers/char/ftape/lowlevel
parente4d0251c6f56ab2e191afb70f80f382793e23f74 (diff)
Merge with 2.3.47. Guys, this is buggy as shit. You've been warned.
Diffstat (limited to 'drivers/char/ftape/lowlevel')
-rw-r--r--drivers/char/ftape/lowlevel/ftape-buffer.c18
1 files changed, 2 insertions, 16 deletions
diff --git a/drivers/char/ftape/lowlevel/ftape-buffer.c b/drivers/char/ftape/lowlevel/ftape-buffer.c
index 8de980562..d7d31dbbb 100644
--- a/drivers/char/ftape/lowlevel/ftape-buffer.c
+++ b/drivers/char/ftape/lowlevel/ftape-buffer.c
@@ -39,20 +39,6 @@
/* DMA'able memory allocation stuff.
*/
-/* Pure 2^n version of get_order */
-static inline int __get_order(size_t size)
-{
- unsigned long order;
-
- size = (size-1) >> (PAGE_SHIFT-1);
- order = -1;
- do {
- size >>= 1;
- order++;
- } while (size);
- return order;
-}
-
static inline void *dmaalloc(size_t size)
{
unsigned long addr;
@@ -60,7 +46,7 @@ static inline void *dmaalloc(size_t size)
if (size == 0) {
return NULL;
}
- addr = __get_dma_pages(GFP_KERNEL, __get_order(size));
+ addr = __get_dma_pages(GFP_KERNEL, get_order(size));
if (addr) {
int i;
@@ -80,7 +66,7 @@ static inline void dmafree(void *addr, size_t size)
i < MAP_NR((unsigned long)addr+size); i++) {
mem_map_unreserve (i);
}
- free_pages((unsigned long) addr, __get_order(size));
+ free_pages((unsigned long) addr, get_order(size));
}
}