From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756208AbbGFQyg (ORCPT ); Mon, 6 Jul 2015 12:54:36 -0400 Received: from linuxhacker.ru ([217.76.32.60]:53209 "EHLO fiona.linuxhacker.ru" rhost-flags-OK-FAIL-OK-OK) by vger.kernel.org with ESMTP id S1754699AbbGFQtV (ORCPT ); Mon, 6 Jul 2015 12:49:21 -0400 From: green@linuxhacker.ru To: Greg Kroah-Hartman , devel@driverdev.osuosl.org, Andreas Dilger Cc: Linux Kernel Mailing List , Oleg Drokin Subject: [PATCH 02/20] staging/lustre: make ldebugfs_remove recursive Date: Mon, 6 Jul 2015 12:48:40 -0400 Message-Id: <1436201338-14263-3-git-send-email-green@linuxhacker.ru> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1436201338-14263-1-git-send-email-green@linuxhacker.ru> References: <1436201338-14263-1-git-send-email-green@linuxhacker.ru> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Oleg Drokin ldebugfs_remove is usually called on directories with files passed in as attributes, so simple debugfs_remove failes on them as not empty Switch to debugfs_remove_recursive. This fixes a number of problems where a new filesystem is mounted after being unmounted first. Signed-off-by: Oleg Drokin --- drivers/staging/lustre/lustre/obdclass/lprocfs_status.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/lustre/lustre/obdclass/lprocfs_status.c b/drivers/staging/lustre/lustre/obdclass/lprocfs_status.c index 17e7c18..651dd9a 100644 --- a/drivers/staging/lustre/lustre/obdclass/lprocfs_status.c +++ b/drivers/staging/lustre/lustre/obdclass/lprocfs_status.c @@ -329,7 +329,7 @@ EXPORT_SYMBOL(ldebugfs_add_vars); void ldebugfs_remove(struct dentry **entryp) { - debugfs_remove(*entryp); + debugfs_remove_recursive(*entryp); *entryp = NULL; } EXPORT_SYMBOL(ldebugfs_remove); -- 2.1.0