mirror of
https://gitlab.rtems.org/rtems/rtos/rtems.git
synced 2026-09-26 19:05:02 +08:00
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:
@@ -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
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user