Skip to content

Commit

Permalink
mm/hwpoison-inject.c: remove unnecessary null test before debugfs_rem…
Browse files Browse the repository at this point in the history
…ove_recursive

Fix checkpatch warning:
  "WARNING: debugfs_remove_recursive(NULL) is safe this check is probably not required"

Signed-off-by: Fabian Frederick <fabf@skynet.be>
Acked-by: Naoya Horiguchi <n-horiguchi@ah.jp.nec.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
  • Loading branch information
Fabian Frederick authored and torvalds committed Aug 7, 2014
1 parent cc7452b commit c2ea218
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions mm/hwpoison-inject.c
Original file line number Diff line number Diff line change
Expand Up @@ -72,8 +72,7 @@ DEFINE_SIMPLE_ATTRIBUTE(unpoison_fops, NULL, hwpoison_unpoison, "%lli\n");

static void pfn_inject_exit(void)
{
if (hwpoison_dir)
debugfs_remove_recursive(hwpoison_dir);
debugfs_remove_recursive(hwpoison_dir);
}

static int pfn_inject_init(void)
Expand Down

0 comments on commit c2ea218

Please sign in to comment.