[syslinux] [RFC] COMBOOT: readdir: st_mode or d_type

Gene Cumm gene.cumm at gmail.com
Sat Feb 28 16:08:38 PST 2009


I'm looking for comments on what to return from readdir in DL or DX.
Currently, the data in DL is misaligned (patch coming soon, along with
at least two more) but it also got me thinking about the fact that
some filesystems, I believe, actually store st_mode directly in the
filesystem.  I'm thinking that using DX to return st_mode may prove
more useful in the long run than just returning d_type.

Looking at com32/lib/sys/fstat.c, a regular file has an access mode of
0444 (Read for all).  I would think that that should probably be the
return value for any filesystem that does not implement Unix-style
access modes.  Additionally, the access mode of a file from a
filesystem implementing ACMs should be examined also.  Ideas include
OR with 0444, replace with 0444, AND with 0444 or just as is.

Thoughts?

-- 
-Gene

"No one ever says, 'I can't read that ASCII E-mail you sent me.'"




More information about the Syslinux mailing list