Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754565Ab0ALApK (ORCPT ); Mon, 11 Jan 2010 19:45:10 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1754445Ab0ALApJ (ORCPT ); Mon, 11 Jan 2010 19:45:09 -0500 Received: from hera.kernel.org ([140.211.167.34]:32881 "EHLO hera.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753932Ab0ALApI (ORCPT ); Mon, 11 Jan 2010 19:45:08 -0500 Message-ID: <4B4BC683.7060508@kernel.org> Date: Tue, 12 Jan 2010 09:46:59 +0900 From: Tejun Heo User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.5) Gecko/20091130 SUSE/3.0.0-1.1.1 Thunderbird/3.0 MIME-Version: 1.0 To: "Eric W. Biederman" CC: Greg Kroah-Hartman , Kay Sievers , linux-kernel@vger.kernel.org, Cornelia Huck , linux-fsdevel@vger.kernel.org, Eric Dumazet , Benjamin LaHaise , Serge Hallyn , "Eric W. Biederman" Subject: Re: [PATCH 3/7] sysfs: Keep an nlink count on sysfs directories. References: <1263241315-19499-3-git-send-email-ebiederm@xmission.com> In-Reply-To: <1263241315-19499-3-git-send-email-ebiederm@xmission.com> X-Enigmail-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.2.3 (hera.kernel.org [127.0.0.1]); Tue, 12 Jan 2010 00:44:49 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 980 Lines: 27 Hello, On 01/12/2010 05:21 AM, Eric W. Biederman wrote: > On large directories sysfs_count_nlinks can be a significant > bottleneck, so keep a count in sysfs_dirent. I was about to suggest changing s_flags to ushort too. Hmmm... adding a new field to sysfs_dirent somewhat worries me but this doesn't add to the size of the structure. How significant bottlenect are we talking about? > If we exceed the maximum number of directory entries we can store > return nlink of 1. An nlink of 1 matches what reiserfs does in this > case, and it let's find and similar utlities know that we have a the > directory nlink can not be used for optimization purposes. Hmmm... what's the limit on reiserfs? Is it 64k too? Thanks. -- tejun -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/