#define PORTAL_VMALLOC_SIZE 16384
+#ifndef GFP_MEMALLOC
+#define GFP_MEMALLOC 0
+#endif
+
#define PORTAL_ALLOC(ptr, size) \
do { \
LASSERT (!in_interrupt()); \
s, (ptr), atomic_read(&portal_kmemory)); \
} while (0)
+#ifndef SLAB_MEMALLOC
+#define SLAB_MEMALLOC 0
+#endif
+
#define PORTAL_SLAB_ALLOC(ptr, slab, size) \
do { \
LASSERT(!in_interrupt()); \
#define SLAB_KERNEL GFP_KERNEL
#define SLAB_NFS GFP_NFS
#define SLAB_DMA GFP_DMA
-+#define SLAB_MEMALLOC GFP_MEMALLOC
++#define SLAB_MEMALLOC GFP_MEMALLOC
#define SLAB_LEVEL_MASK (__GFP_WAIT|__GFP_HIGH|__GFP_IO|__GFP_HIGHIO|__GFP_FS)
#define SLAB_NO_GROW 0x00001000UL /* don't grow a cache */
#define SLAB_KERNEL GFP_KERNEL
#define SLAB_NFS GFP_NFS
#define SLAB_DMA GFP_DMA
-+#define SLAB_MEMALLOC GFP_MEMALLOC
++#define SLAB_MEMALLOC GFP_MEMALLOC
#define SLAB_LEVEL_MASK (__GFP_WAIT|__GFP_HIGH|__GFP_IO|__GFP_HIGHIO|__GFP_FS)
#define SLAB_NO_GROW 0x00001000UL /* don't grow a cache */
#define SLAB_KERNEL GFP_KERNEL
#define SLAB_NFS GFP_NFS
#define SLAB_DMA GFP_DMA
-+#define SLAB_MEMALLOC GFP_MEMALLOC
++#define SLAB_MEMALLOC GFP_MEMALLOC
#define SLAB_LEVEL_MASK (__GFP_WAIT|__GFP_HIGH|__GFP_IO|__GFP_HIGHIO|__GFP_FS)
#define SLAB_NO_GROW 0x00001000UL /* don't grow a cache */
/* AKPM: buglet - add `i' to tmp! */
for (i = 0; i < jh2bh(descriptor)->b_size; i += 512) {
journal_header_t *tmp =
-@@ -600,6 +603,7 @@
- }
-
- unlock_journal(journal);
-+ unlocked = 1;
- JBUFFER_TRACE(descriptor, "write commit block");
- {
- struct buffer_head *bh = jh2bh(descriptor);
@@ -610,14 +614,32 @@
put_bh(bh); /* One for getblk() */
journal_unlock_journal_head(descriptor);
#define PORTAL_VMALLOC_SIZE 16384
+#ifndef GFP_MEMALLOC
+#define GFP_MEMALLOC 0
+#endif
+
#define PORTAL_ALLOC(ptr, size) \
do { \
LASSERT (!in_interrupt()); \
s, (ptr), atomic_read(&portal_kmemory)); \
} while (0)
+#ifndef SLAB_MEMALLOC
+#define SLAB_MEMALLOC 0
+#endif
+
#define PORTAL_SLAB_ALLOC(ptr, slab, size) \
do { \
LASSERT(!in_interrupt()); \