Skip to content

Commit

Permalink
kmemleak: remove redundant code
Browse files Browse the repository at this point in the history
Remove kmemleak_padding() and kmemleak_release().

Signed-off-by: Li Zefan <[email protected]>
Acked-by: Catalin Marinas <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
lizf-os authored and torvalds committed Apr 3, 2014
1 parent c89da70 commit 5f3bf19
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 8 deletions.
2 changes: 0 additions & 2 deletions include/linux/kmemleak.h
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,6 @@ extern void kmemleak_alloc_percpu(const void __percpu *ptr, size_t size) __ref;
extern void kmemleak_free(const void *ptr) __ref;
extern void kmemleak_free_part(const void *ptr, size_t size) __ref;
extern void kmemleak_free_percpu(const void __percpu *ptr) __ref;
extern void kmemleak_padding(const void *ptr, unsigned long offset,
size_t size) __ref;
extern void kmemleak_not_leak(const void *ptr) __ref;
extern void kmemleak_ignore(const void *ptr) __ref;
extern void kmemleak_scan_area(const void *ptr, size_t size, gfp_t gfp) __ref;
Expand Down
7 changes: 1 addition & 6 deletions mm/kmemleak.c
Original file line number Diff line number Diff line change
Expand Up @@ -1549,11 +1549,6 @@ static int kmemleak_open(struct inode *inode, struct file *file)
return seq_open(file, &kmemleak_seq_ops);
}

static int kmemleak_release(struct inode *inode, struct file *file)
{
return seq_release(inode, file);
}

static int dump_str_object_info(const char *str)
{
unsigned long flags;
Expand Down Expand Up @@ -1691,7 +1686,7 @@ static const struct file_operations kmemleak_fops = {
.read = seq_read,
.write = kmemleak_write,
.llseek = seq_lseek,
.release = kmemleak_release,
.release = seq_release,
};

static void __kmemleak_do_cleanup(void)
Expand Down

0 comments on commit 5f3bf19

Please sign in to comment.