mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Eric Dumazet <dada1@cosmosbay.com>
To: Jeff Layton <jlayton@redhat.com>
Cc: Kirill Korotaev <dev@openvz.org>,
	linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH 3/3] have pipefs ensure i_ino uniqueness by calling iunique and hashing the inode
Date: Fri, 26 Jan 2007 16:12:52 +0100	[thread overview]
Message-ID: <200701261612.52414.dada1@cosmosbay.com> (raw)
In-Reply-To: <45BA1359.7020200@redhat.com>

On Friday 26 January 2007 15:42, Jeff Layton wrote:
> Kirill Korotaev wrote:
>  > Jeff,
>  >
>  > is 100% uniqeness is so much required for pipe inode numbers?
>  > AFAIU, it is not that critical for pipefs (unlike smb, nfs etc.)
>  >
>  > Thanks,
>  > Kirill
>
> There is no in-kernel reason why i_ino uniqueness is important for
> pipefs. Where it might matter is userspace. The i_ino value is used for:
>
> 1) the st_ino value returned in stat calls
>
> 2) the dentry name (generated as "[inode_number]")
>
> So while it's certainly not "correct" to have multiple inodes with the same
> number on any filesystem, it is probably more important in some places is
> others. For pipefs, maybe it isn't, especially given a potential 6%
> performance impact to fix it. Anyone else have thoughts?

For dentry name, we certainly could use "[address of inode]" instead 
of "[inode number]" to get unicity, but do we care ?

For st_ino values on pipefs and sockets, I doubt any user application would 
care. I never had to fstat() a socket fd. Of course it's a file descriptor, 
but all we really want to do with this kind of file descriptor is to call 
socket API.

And for some heavy loaded internet servers , the additional cost of 
insert/delete a node in a machine shared tree could be a problem.

Some weeks ago I suggested to not hash pipe/socket dentries in order to save 
some locked ops (see commits 304e61e6fbadec586dfe002b535f169a04248e49 & 
b3423415fbc2e5461605826317da1c8dbbf21f97 ), so obviously I prefer not adding 
another tree ops. However, pipe/sockets creation/destroy are probably not 
that frequent, so the 6% perf impact is not that big :)

Eric

  reply	other threads:[~2007-01-26 15:12 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-12-29 19:11 Jeff Layton
2007-01-26 12:51 ` Kirill Korotaev
2007-01-26 14:42   ` Jeff Layton
2007-01-26 15:12     ` Eric Dumazet [this message]
2007-01-30 15:04       ` Jeff Layton
2007-01-08 20:47 Jeff Layton
2007-01-10 21:24 ` Christoph Hellwig
2007-01-16 18:57 Jeff Layton

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200701261612.52414.dada1@cosmosbay.com \
    --to=dada1@cosmosbay.com \
    --cc=dev@openvz.org \
    --cc=jlayton@redhat.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome