Filesystem: Remove per file descriptor semaphore

The per file descriptor semaphore (field of rtems_libio_t) is unused in
RTEMS.  There is a considerable memory overhead due to that.  A
semaphore needs roughly 124 bytes which is huge compared to the
approximately 72 bytes for the file descriptor structure itself.  Device
drivers can create their own synchronization primitives in the open
handler on demand.
This commit is contained in:
Sebastian Huber
2012-05-04 10:53:51 +02:00
parent 27272db336
commit 5a4bb758c0
13 changed files with 14 additions and 47 deletions
+2 -4
View File
@@ -119,11 +119,9 @@ rtems_fs_init_functions_t rtems_fs_init_helper =
#endif
/**
* From the number of file descriptors, we can determine how many
* semaphores the implementation will require.
* Semaphore count used by the IO library.
*/
#define CONFIGURE_LIBIO_SEMAPHORES \
(CONFIGURE_LIBIO_MAXIMUM_FILE_DESCRIPTORS + 1)
#define CONFIGURE_LIBIO_SEMAPHORES 1
#ifdef CONFIGURE_INIT
/**