lkml.org 
[lkml]   [1999]   [Nov]   [16]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: Ext2 defragmentation
On Tue, Nov 16, 1999 at 05:54:57PM +0000, Stephen C. Tweedie wrote:
> Hi,
>
> On Mon, 15 Nov 1999 22:11:59 +0100, Jamie Lokier
> <lkd@tantalophile.demon.co.uk> said:
> > I have a dirent->d_type patch which I really should get on with
> > submitting... Is anyone actually interested in it?
>
> Definitely --- ext2 is already maintaining the information, we might as
> well use it.

However instead of having kwazillion new readdir()/getdents()
syscalls, lets merge that into LFS patch contained getdents64().

ftp://mea.tmt.tele.fi/linux/LFS/
lfs-patches-v0.21-base-2.3.27-pre1-G-readdir64.diff

struct linux_dirent64 {
__u64 d_ino; /* 64 bits *should* be enough */
__u32 d_off; /* position within directory */
__u32 d_flags; /* what is stored in d_data[] */
__u32 d_data[8]; /* for future extensions */
__u16 d_reclen;
char d_name[1]; /* We must not include limits.h! */
};


asmlinkage long sys_getdents64( unsigned int fd, struct linux_dirent64 *dirent,
unsigned int count, long flags )
{
...
}

Unlike sys_getdents(), original behaviour happens only when 'flags'
is zero, d_flags, and d_data[] can be filled in guidance of what
'flags' tells.


> --Stephen

/Matti Aarnio

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:55    [W:0.037 / U:0.404 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site