Subject: Re: problem with tmpfs and linux emulation?
To: None <>
From: Christos Zoulas <>
List: current-users
Date: 11/12/2005 19:23:40
In article <>,
Matt Thomas  <> wrote:
>Steven M. Bellovin wrote:
>> In message <>, Matt Thomas writes:
>>>Bill Studenmund wrote:
>>>I don't see the problem.  Instead of using sys_read, linux would have its
>>>linux_sys_read.  It would look up the fd, see if it's a DTYPE_VNODE, and if so
>>>check to see if it's a directory.  It's only a problem is you are relying on t
>>>he standard sys_read routine.
>> Presumably, though, the behavior of linux_sys_read would have to depend 
>> on the underlying file system type -- it does the right thing for, say, 
>> ffs and ext2fs, but not for tmpfs.
>But it only work by "accident", not intention.  This method should be used for
>all filesystems, not just tmpfs.  It's a bit more inefficient, but more correct.

I don't think that linux uses read to read directories. I think it always
uses getdents. Something else must be going on. Can someone verify by using