I found this document which describes the use cases for UIO in Linux:
https://www.kernel.org/doc/html/v4.13/driver-api/uio-howto.html . They
use mmap() to addess device memory: "|/dev/uioX| is used to access the
address space of the card. Just use |mmap()| to access registers or RAM
locations of your card."
There is a paragraph with a little more info:
https://www.kernel.org/doc/html/v4.13/driver-api/uio-howto.html#mmap-device-memory
My only concerns here are: (1) We use POSIX/Linux compatibility in
interface definitions and (2) We assure security of kernel resources. I
am not sure how mmap() knows which kernel mappings are secure and which
are insecure. But we would need to address that. If secure, standard
interfaces are used, then I am supportive (and you can ignore many of my
other comments which were just me fumbling to understand the proposal).
On 3/28/2024 12:25 PM, Gregory Nutt wrote:
A more interesting task would be to port NxLib to run on top of the
existing NuttX NX Windows System:
* https://cwiki.apache.org/confluence/pages/viewpage.action?pageId=139629474
* https://cwiki.apache.org/confluence/display/NUTTX/NX+Graphics+Subsystem
That would not be particularly easier, however. The NX Window System
is purely a windowing system and does not provide any significant
graphics support. X11, by comparison, is a complete graphics system
and user libraries are really only needed to simplify the interfaces
and to extend the graphics capabilities.
You would have to come up with some way to provide the graphics
capability in Nano-X not included in NX Windows.
In the NX Windows world, graphics was intended to be provided by
NxWidgets. That, however, is a work that was never really completed
to production quality. There are also several window managers that
use NX Windows and NxWidgets: NX and Twm4Nx. The latter is a TWM
inspired window manager (but a unique C++ development).