This is the mail archive of the
ecos-discuss@sourceware.cygnus.com
mailing list for the eCos project.
[ECOS] Linux Filesystem Access
- To: Jonathan Larmour <jlarmour@cygnus.co.uk>
- Subject: [ECOS] Linux Filesystem Access
- From: Jamie Guinan <guinan@bluebutton.com>
- Date: Wed, 30 Jun 1999 13:48:24 -0400 (EDT)
- cc: ecos-discuss@sourceware.cygnus.com
- Reply-To: guinan@bluebutton.com
On 28 Jun 1999, Jonathan Larmour wrote:
> Jamie Guinan <guinan@bluebutton.com> wrote:
>
> >If not, would a simple "linux filesystem driver" be worth spending
> >some time on?
>
> We do have plans for an all-singing all-dancing configurable pluggable
> virtual file system infrastructure :-), but it'll take some time to sort
> out. Expect an RFC in the not-too-distant future.
Looking forward to that! So right now the only things I can fopen()
are /dev entries like "/dev/haldiag", correct?
> But if you want to hack
> something quick and dirty up, feel free!
Actually, I found that the stuff from syscall-i386-linux-1.0.S
works well enough for me. I am able to open and write files
with code such as,
#define O_WRONLY 01
#define O_CREAT 0100
int fd;
char *buff = "Boogie down!\n";
fd=cyg_hal_sys_open("/tmp/ecos.out", O_CREAT|O_WRONLY, 00777);
cyg_hal_sys_write(fd, buff, strlen(buff));
cyg_hal_sys_close(fd);
I have yet to try reading, though.
-Jamie