[Ocfs2-commits] jlbec commits r1193 - trunk/src
svn-commits at oss.oracle.com
svn-commits at oss.oracle.com
Tue Jun 22 20:34:06 CDT 2004
Author: jlbec
Date: 2004-06-22 19:34:04 -0500 (Tue, 22 Jun 2004)
New Revision: 1193
Modified:
trunk/src/extmap.c
trunk/src/ocfs.h
trunk/src/util.c
trunk/src/util.h
Log:
o Remove ocfs_allocate/free_extent_entry()
Modified: trunk/src/extmap.c
===================================================================
--- trunk/src/extmap.c 2004-06-22 23:28:19 UTC (rev 1192)
+++ trunk/src/extmap.c 2004-06-23 00:34:04 UTC (rev 1193)
@@ -83,7 +83,8 @@
list_for_each_safe(tmp, tmp2, &map->head) {
ext = list_entry (tmp, ocfs_extent, list);
list_del(&ext->list);
- ocfs_free_extent_entry(ext);
+ kmem_cache_free(OcfsGlobalCtxt.extent_cache,
+ ext);
map->count--;
}
if (map->count!=0) {
@@ -242,7 +243,8 @@
victim = tmp;
} else {
list_del(&tmp->list);
- ocfs_free_extent_entry(tmp);
+ kmem_cache_free(OcfsGlobalCtxt.extent_cache,
+ tmp);
map->count--;
}
}
@@ -287,7 +289,7 @@
goto release_spinlock;
}
- ext = ocfs_allocate_extent_entry();
+ ext = kmem_cache_alloc(OcfsGlobalCtxt.extent_cache, GFP_NOFS);
if (ext==NULL) {
LOG_ERROR_STR ("failed to allocate extent entry");
goto release_spinlock;
@@ -347,7 +349,8 @@
continue;
if (virtual == lo && sectors == sec) {
list_del(&tmp->list);
- ocfs_free_extent_entry(tmp);
+ kmem_cache_free(OcfsGlobalCtxt.extent_cache,
+ tmp);
map->count--;
break;
}
Modified: trunk/src/ocfs.h
===================================================================
--- trunk/src/ocfs.h 2004-06-22 23:28:19 UTC (rev 1192)
+++ trunk/src/ocfs.h 2004-06-23 00:34:04 UTC (rev 1193)
@@ -293,11 +293,6 @@
-#define ocfs_allocate_extent_entry() (ocfs_extent *)kmem_cache_alloc ( \
- OcfsGlobalCtxt.extent_cache, GFP_NOFS)
-#define ocfs_free_extent_entry(ext) kmem_cache_free(OcfsGlobalCtxt.extent_cache, ext)
-
-
#define OCFS_NAME "OCFS2"
/* ioctl commands */
Modified: trunk/src/util.c
===================================================================
--- trunk/src/util.c 2004-06-22 23:28:19 UTC (rev 1192)
+++ trunk/src/util.c 2004-06-23 00:34:04 UTC (rev 1193)
@@ -124,31 +124,6 @@
return 0;
} /* ocfs_sleep */
-/*
- * ocfs_dbg_slab_alloc()
- *
- */
-void *ocfs_dbg_slab_alloc (kmem_cache_t *slab, char *file, int line)
-{
- void *m;
- m = kmem_cache_alloc(slab, GFP_NOFS);
-#if 0 /* FIXME: Should we check? */
- if (m == NULL)
- LOG_ERROR_ARGS("failed to alloc from slab = %p", slab);
-#endif
- return m;
-} /* ocfs_dbg_slab_alloc */
-
-/*
- * ocfs_dbg_slab_free()
- *
- */
-void ocfs_dbg_slab_free (kmem_cache_t *slab, void *m)
-{
- kmem_cache_free(slab, m);
-} /* ocfs_dbg_slab_free */
-
-
/* prefetch has been declared to allow to build in debug mode */
#ifdef DEBUG
#ifndef ARCH_HAS_PREFETCH
Modified: trunk/src/util.h
===================================================================
--- trunk/src/util.h 2004-06-22 23:28:19 UTC (rev 1192)
+++ trunk/src/util.h 2004-06-23 00:34:04 UTC (rev 1193)
@@ -32,11 +32,7 @@
int ocfs_compare_qstr(struct qstr *s1, struct qstr *s2);
void ocfs_clear_timeout(ocfs_timeout *to);
void ocfs_daemonize(char *name, int len);
-void *ocfs_dbg_slab_alloc(kmem_cache_t *slab, char *file, int line);
-void ocfs_dbg_slab_free(kmem_cache_t *slab, void *m);
void ocfs_init_timeout(ocfs_timeout *to);
-void *ocfs_linux_dbg_alloc(int Size, char *file, int line);
-void ocfs_linux_dbg_free(const void *Buffer);
void ocfs_set_timeout(ocfs_timeout *to, __u32 timeout);
void ocfs_show_stack(unsigned long *esp);
void ocfs_show_trace(unsigned long *stack);
More information about the Ocfs2-commits
mailing list