[syslinux:elflink] elflink: remove hmalloc which is not needed after core/com32 malloc merged
syslinux-bot for Feng Tang
feng.tang at intel.com
Thu Aug 12 21:03:27 PDT 2010
Commit-ID: 1fa26a89fca3c7e6c72b1f2fdd960f356a9b0f12
Gitweb: http://syslinux.zytor.com/commit/1fa26a89fca3c7e6c72b1f2fdd960f356a9b0f12
Author: Feng Tang <feng.tang at intel.com>
AuthorDate: Thu, 24 Jun 2010 16:28:39 +0800
Committer: Feng Tang <feng.tang at intel.com>
CommitDate: Tue, 20 Jul 2010 11:10:04 +0800
elflink: remove hmalloc which is not needed after core/com32 malloc merged
---
core/fs/btrfs/btrfs.c | 2 +-
core/fs/ext2/ext2.c | 2 +-
core/fs/fat/fat.c | 2 +-
core/fs/fs.c | 2 +-
core/fs/iso9660/iso9660.c | 2 +-
core/include/core.h | 1 -
core/mem/malloc.c | 5 -----
7 files changed, 5 insertions(+), 11 deletions(-)
diff --git a/core/fs/btrfs/btrfs.c b/core/fs/btrfs/btrfs.c
index f78bf47..72dcbe9 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 cf5aaa1..716670c 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 cbcd051..a21f431 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 cb2f206..9b8e30f 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 428e0cd..d695e43 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 f4c8586..3de2b4d 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 adab9b6..6704af2 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);
More information about the Syslinux-commits
mailing list