Opened on 03/16/24 at 17:12:07
Last modified on 03/18/24 at 15:51:01
#5000 new enhancement
Implement POSIX Asynchronous IO
Reported by: | Joel Sherrill | Owned by: | |
---|---|---|---|
Priority: | normal | Milestone: | |
Component: | posix | Version: | |
Severity: | normal | Keywords: | SoC, POSIX |
Cc: | Blocked By: | ||
Blocking: |
Description (last modified by Joel Sherrill)
RTEMS does not currently support POSIX Asynchronous IO as defined by The Open Group. These methods and associated constants are prototyped by the [http://www.opengroup.org/onlinepubs/009695399/basedefs/aio.h.html <aio.h>] header file which is cpukit/posix/include/aio.h in the RTEMS source tree. The following methods have already been implemented but should be reviewed against the POSIX specification to ensure they are as complete as possible:
- aio_read()
- aio_write()
- aio_cancel()
- aio_error()
- aio_return()
The implementation of the above AIO methods includes a server thread which performs the user's AIO requests. These AIO methods request a SINGLE operation.
The method lio_listio() is not implemented currently in RTEMS. The current implementation between the aio_ methods and the server thread will need to grow to support a list. The straightforward way to accomplish this is to modify the current aio_ infrastructure to treat a single aio_ request as a list of one. Then the lio_listio() should be a simple modification.
The current implementation leans to a long-ish function to process AIO requests. This processing should be refactored so while iterating the list, the server thread calls a helper method for each request type.
The implementation has a single server thread. The server thread characteristics such as stack size and priority should be application configurable.
There will need to be tests added for the new functionality. Coverage will need to be reviewed for the AIO functionality.
Possible Mentors: Joel Sherrill, Gedare Bloom, Chris Johns, Kinsey Moore
Change History (1)
comment:1 Changed on 03/18/24 at 15:51:01 by Joel Sherrill
Description: | modified (diff) |
---|
My thoughts on an implementation plan. The functionality of lio_listio() can be implemented by a series of incremental changes. Much of the functionality is already present in the existing aio_* methods. Some of these can happen in parallel. Ensure all AIO tests pass as modifications are made and new tests are added as needed.