Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 14 Jan 2004 17:47:04 +0100 (CET)
From:      Harti Brandt <brandt@fokus.fraunhofer.de>
To:        Robert Watson <rwatson@freebsd.org>
Cc:        current@freebsd.org
Subject:   Re: simplifying linux_emul_convpath()
Message-ID:  <20040114174404.S14691@beagle.fokus.fraunhofer.de>
In-Reply-To: <Pine.NEB.3.96L.1040114102304.46433D-100000@fledge.watson.org>
References:  <Pine.NEB.3.96L.1040114102304.46433D-100000@fledge.watson.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 14 Jan 2004, Robert Watson wrote:

RW>
RW>On Wed, 14 Jan 2004, Don Lewis wrote:
RW>
RW>> I just stumbled across a vnode locking violation in
RW>> linux_emul_convpath().  Rather than locking and unlocking each vnode for
RW>> the VOP_GETATTR() calls, is there any reason that this code should not
RW>> be simplified to just compare the vnode pointers rather than fetching
RW>> the vnode attributes and comparing the attributes for equality.
RW>
RW>For some time, I've been thinking of adding samefile() and fsamefile()
RW>system calls to FreeBSD, which would allow userspace applications to
RW>determine if two names or file handles refer to the same object without
RW>playing games with inode numbers, device ids, etc.  The reason to do this
RW>would be that 32-bit inode numbers are subject to collision on large file
RW>systems.  My initial implementation simply compared vnode pointers, but

This is a seriouse violation of Posix and may make applications like tar,
mkisofs and friends do the wrong things. Are 32-bit inodes and UFS1
restriction?

harti
-- 
harti brandt,
http://www.fokus.fraunhofer.de/research/cc/cats/employees/hartmut.brandt/private
brandt@fokus.fraunhofer.de, harti@freebsd.org



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040114174404.S14691>