This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

RTFS File Descriptors > 17 open at a time?

Alan,

 

We talked a while back about the number of open files available in RTFS. I believe that the #define _NSTREAM in file.h specifies the available number of file descriptors available to PSP/SATA. That #define evaluates to a numerical value of 20. The system uses 3 of those descriptors for stdin, stdout and stderr, so the maximum number of open files that PSP/SATA and RTFS support is 17. This is what I've been using for several months now. If I attempt to ask for more (i.e > 17) DSP/BIOS falls into UTL_halt, not returning from the open() caller. Note that I am using the POSIX/syscall form of file system calls (i.e. open(), not fopen()).

 

Now my boss wants to up the number of open files, from 17 to 250! I open all my files at once to avoid file open overhead during my disk write operations, so I can't close one file descriptor, and re-open it assigned to another file.

 

I think I can rebuild the PSP SATA library to support this, but I don't have the source for RTFS to rebuild all of its libraries.

 

I did receive a file from EBS named rtfsPosix.c and have built the library ti.rtfs.config.lib however it doesn't seem to be sufficient. My understanding was that rebuilding this library was sufficient to up the number of file descriptors. Now I'm wondering if the llv_fd value needs to be changed to 250 also (mirroring _NSTREAM) and maybe additional RTFS libraries need to be rebuilt?

 

Any information you can provide would be greatly appreciated.

 

Thanks,

Kevin