From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752015Ab1AUGjY (ORCPT ); Fri, 21 Jan 2011 01:39:24 -0500 Received: from mtoichi12.ns.itscom.net ([219.110.2.182]:46174 "EHLO mtoichi12.ns.itscom.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751209Ab1AUGjW (ORCPT ); Fri, 21 Jan 2011 01:39:22 -0500 From: "J. R. Okajima" Subject: Re: vfs-scale, general questions To: Miklos Szeredi Cc: npiggin@gmail.com, npiggin@kernel.dk, linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org In-Reply-To: References: <20110113120626.GB30351@opensource.wolfsonmicro.com> <8138.1294924927@jrobl> <676f5c24375e1cc2aa14fe6630ef1324@mail.gmail.com> <8482.1294926315@jrobl> <909.1295419383@jrobl> <13379.1295514315@jrobl> Date: Fri, 21 Jan 2011 15:38:59 +0900 Message-ID: <19352.1295591939@jrobl> Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Miklos Szeredi: > No it doesn't. dentry_unhash() doesn't drop the dentry from the hash > unless it has no other references, cwd being one such ref. I see. When chdir() completets before vfs_rename_dir(), the dir will not be unhashed. It is OK. Even if the dir is unhashed temporary before chdir(), then the lookup fallback to ref-walk and i_mutex protects. It is OK too. Thank you. J. R. Okajima