From patchwork Thu Aug 13 21:23:42 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Nicholas A. Bellinger" X-Patchwork-Id: 7011021 Return-Path: X-Original-To: patchwork-linux-fsdevel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id DB8AE9F373 for ; Thu, 13 Aug 2015 21:29:15 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id DD87B20544 for ; Thu, 13 Aug 2015 21:29:14 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 17A7C205C1 for ; Thu, 13 Aug 2015 21:29:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754244AbbHMV3J (ORCPT ); Thu, 13 Aug 2015 17:29:09 -0400 Received: from mail.linux-iscsi.org ([67.23.28.174]:36976 "EHLO linux-iscsi.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754222AbbHMV3H (ORCPT ); Thu, 13 Aug 2015 17:29:07 -0400 Received: from linux-iscsi.org (localhost [127.0.0.1]) by linux-iscsi.org (Postfix) with ESMTP id 0F9D522DA55; Thu, 13 Aug 2015 21:23:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=linux-iscsi.org; s=default.private; t=1439501035; bh=ljJKiRJP3R9lWaWGz96KP3/JcsgxXvf /joBFewdgbwU=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To: References; b=KtiDJZfwFQpPyfbBptbonq8gIY9ygOt07pKSGjmgrcXfT9QXihQ9 nw+j7xP0SilQLUoo1uvkZ383iCxg/HpIN/IWj8yCL+mN+frXgzj/71emhykFjgVZ+mt 2/RhelKs7lnjyzNl0Z6cxtvQleHHn5Q0UKNNaJ0bFsK+k67784wg= From: "Nicholas A. Bellinger" To: stable Cc: Greg-KH , Al Viro , Miklos Szeredi , linux-fsdevel Subject: [PATCH-v3.14.y 4/8] expand the call of dentry_lru_del() in dentry_kill() Date: Thu, 13 Aug 2015 21:23:42 +0000 Message-Id: <1439501026-19955-5-git-send-email-nab@linux-iscsi.org> X-Mailer: git-send-email 1.7.2.5 In-Reply-To: <1439501026-19955-1-git-send-email-nab@linux-iscsi.org> References: <1439501026-19955-1-git-send-email-nab@linux-iscsi.org> Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org X-Spam-Status: No, score=-6.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,RP_MATCHES_RCVD,T_DKIM_INVALID,UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Al Viro commit 01b6035190b024240a43ac1d8e9c6f964f5f1c63 upstream. Signed-off-by: Al Viro --- fs/dcache.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/fs/dcache.c b/fs/dcache.c index 3a0f252..16f9066 100644 --- a/fs/dcache.c +++ b/fs/dcache.c @@ -499,7 +499,12 @@ relock: if ((dentry->d_flags & DCACHE_OP_PRUNE) && !d_unhashed(dentry)) dentry->d_op->d_prune(dentry); - dentry_lru_del(dentry); + if (dentry->d_flags & DCACHE_LRU_LIST) { + if (!(dentry->d_flags & DCACHE_SHRINK_LIST)) + d_lru_del(dentry); + else + d_shrink_del(dentry); + } /* if it was on the hash then remove it */ __d_drop(dentry); __list_del_entry(&dentry->d_child);