From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932475AbbBBCzW (ORCPT ); Sun, 1 Feb 2015 21:55:22 -0500 Received: from linuxhacker.ru ([217.76.32.60]:59845 "EHLO fiona.linuxhacker.ru" rhost-flags-OK-FAIL-OK-OK) by vger.kernel.org with ESMTP id S1755312AbbBBCx0 (ORCPT ); Sun, 1 Feb 2015 21:53:26 -0500 From: green@linuxhacker.ru To: Greg Kroah-Hartman , devel@driverdev.osuosl.org, Andreas Dilger Cc: Linux Kernel Mailing List , Yang Sheng , Oleg Drokin Subject: [PATCH 17/20] staging/lustre/llite: Add exception entry check after radix_tree Date: Sun, 1 Feb 2015 21:52:16 -0500 Message-Id: <1422845539-26742-18-git-send-email-green@linuxhacker.ru> X-Mailer: git-send-email 2.1.0 In-Reply-To: <1422845539-26742-1-git-send-email-green@linuxhacker.ru> References: <1422845539-26742-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: Yang Sheng We need to check for an exception entry after radix_tree lookup. Signed-off-by: Yang Sheng Signed-off-by: Oleg Drokin Reviewed-on: http://review.whamcloud.com/10709 Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-5162 Reviewed-by: Bob Glossman Reviewed-by: James Simmons --- drivers/staging/lustre/lustre/llite/dir.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/staging/lustre/lustre/llite/dir.c b/drivers/staging/lustre/lustre/llite/dir.c index babba60..69a4a63 100644 --- a/drivers/staging/lustre/lustre/llite/dir.c +++ b/drivers/staging/lustre/lustre/llite/dir.c @@ -278,7 +278,7 @@ static struct page *ll_dir_page_locate(struct inode *dir, __u64 *hash, spin_lock_irq(&mapping->tree_lock); found = radix_tree_gang_lookup(&mapping->page_tree, (void **)&page, offset, 1); - if (found > 0) { + if (found > 0 && !radix_tree_exceptional_entry(page)) { struct lu_dirpage *dp; page_cache_get(page); -- 2.1.0