aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFeng Tang <feng.tang@intel.com>2010-06-24 16:28:39 +0800
committerFeng Tang <feng.tang@intel.com>2010-07-20 11:10:04 +0800
commit1fa26a89fca3c7e6c72b1f2fdd960f356a9b0f12 (patch)
treed91a8a43ed15c9d955bd5975dcb023e8af927e7f
parent880f67714ec0f5187ff7c4dd2ec11879c18437e7 (diff)
downloadsyslinux-1fa26a89fca3c7e6c72b1f2fdd960f356a9b0f12.tar.gz
syslinux-1fa26a89fca3c7e6c72b1f2fdd960f356a9b0f12.tar.xz
syslinux-1fa26a89fca3c7e6c72b1f2fdd960f356a9b0f12.zip
elflink: remove hmalloc which is not needed after core/com32 malloc merged
-rw-r--r--core/fs/btrfs/btrfs.c2
-rw-r--r--core/fs/ext2/ext2.c2
-rw-r--r--core/fs/fat/fat.c2
-rw-r--r--core/fs/fs.c2
-rw-r--r--core/fs/iso9660/iso9660.c2
-rw-r--r--core/include/core.h1
-rw-r--r--core/mem/malloc.c5
7 files changed, 5 insertions, 11 deletions
diff --git a/core/fs/btrfs/btrfs.c b/core/fs/btrfs/btrfs.c
index f78bf477..72dcbe92 100644
--- a/core/fs/btrfs/btrfs.c
+++ b/core/fs/btrfs/btrfs.c
@@ -82,7 +82,7 @@ static void insert_map(struct btrfs_chunk_map_item *item)
if (chunk_map.map == NULL) { /* first item */
chunk_map.map_length = BTRFS_MAX_CHUNK_ENTRIES;
chunk_map.map = (struct btrfs_chunk_map_item *)
- hmalloc(chunk_map.map_length * sizeof(*chunk_map.map));
+ malloc(chunk_map.map_length * sizeof(*chunk_map.map));
chunk_map.map[0] = *item;
chunk_map.cur_length = 1;
return;
diff --git a/core/fs/ext2/ext2.c b/core/fs/ext2/ext2.c
index cf5aaa1d..716670c6 100644
--- a/core/fs/ext2/ext2.c
+++ b/core/fs/ext2/ext2.c
@@ -280,7 +280,7 @@ static int ext2_fs_init(struct fs_info *fs)
if (sb.s_magic != EXT2_SUPER_MAGIC)
return -1;
- sbi = hmalloc(sizeof(*sbi));
+ sbi = malloc(sizeof(*sbi));
if (!sbi) {
malloc_error("ext2_sb_info structure");
return -1;
diff --git a/core/fs/fat/fat.c b/core/fs/fat/fat.c
index cbcd051b..a21f4312 100644
--- a/core/fs/fat/fat.c
+++ b/core/fs/fat/fat.c
@@ -754,7 +754,7 @@ static int vfat_fs_init(struct fs_info *fs)
/* XXX: Find better sanity checks... */
if (!fat.bxResSectors || !fat.bxFATs)
return -1;
- sbi = hmalloc(sizeof(*sbi));
+ sbi = malloc(sizeof(*sbi));
if (!sbi)
malloc_error("fat_sb_info structure");
fs->fs_info = sbi;
diff --git a/core/fs/fs.c b/core/fs/fs.c
index cb2f2066..9b8e30f0 100644
--- a/core/fs/fs.c
+++ b/core/fs/fs.c
@@ -258,7 +258,7 @@ int searchdir(const char *name)
total_len > MAX_SYMLINK_BUF)
goto err;
- linkbuf = hmalloc(total_len);
+ linkbuf = malloc(total_len);
if (!linkbuf)
goto err;
diff --git a/core/fs/iso9660/iso9660.c b/core/fs/iso9660/iso9660.c
index 428e0cdb..d695e439 100644
--- a/core/fs/iso9660/iso9660.c
+++ b/core/fs/iso9660/iso9660.c
@@ -307,7 +307,7 @@ static int iso_fs_init(struct fs_info *fs)
struct disk *disk = fs->fs_dev->disk;
int blktosec;
- sbi = hmalloc(sizeof(*sbi));
+ sbi = malloc(sizeof(*sbi));
if (!sbi) {
malloc_error("iso_sb_info structure");
return 1;
diff --git a/core/include/core.h b/core/include/core.h
index f4c85862..3de2b4de 100644
--- a/core/include/core.h
+++ b/core/include/core.h
@@ -30,7 +30,6 @@ extern void __idle(void);
extern void reset_idle(void);
/* mem/malloc.c, mem/free.c, mem/init.c */
-extern void *hmalloc(size_t);
extern void *lmalloc(size_t);
extern void *pmapi_lmalloc(size_t);
extern void *zalloc(size_t);
diff --git a/core/mem/malloc.c b/core/mem/malloc.c
index adab9b6a..6704af2f 100644
--- a/core/mem/malloc.c
+++ b/core/mem/malloc.c
@@ -86,11 +86,6 @@ static void *_malloc(size_t size, enum heap heap, malloc_tag_t tag)
return p;
}
-void *hmalloc(size_t size)
-{
- return _malloc(size, HEAP_MAIN, MALLOC_CORE);
-}
-
void *malloc(size_t size)
{
return _malloc(size, HEAP_MAIN, MALLOC_CORE);