I feel that the branch jepler/rtos-uspace is close to maturity.  I
solved the issue that a 1ms thread alone had worse latency than a 1ms
thread running with a 25ms thread (was not using /dev/cpu_dma_latency)
and the branch now passes buildbot tests for all supported
architectures.

I have started with the next step: building drivers that work with
uspace.  So far, serport, hostmot2 (the device-independent part), and
hm2-test work.  I've scoped a nice 500Hz waveform generated by serport,
with timing variations that seem to match the latency-test results.
This is on the branch "jepler-rtos-apis".  This branch, too, passes
muster on the buildbot.

RTAPI hardware drivers have storically used a wide range of APIs that
are linux kernel APIs.  My approach is to identify these APIs, write a
header which prefixes the APIs all with rtapi_, write an implementation
for uspace, and then convert the driver to use the rtapi_-prefixed APIs.

For example, the kernel provides "kmalloc".  In kernel space, I arrange
to have
    #define rtapi_kmalloc kmalloc
and in userspace I arrange to have
    #define rtapi_kmalloc(sz, flags) malloc(sz)
.. all in a header <rtapi_slab.h>, because the related kernel header is
<linux/slab.h>.

Sometimes, the uspace implementation is hopelessly dumb.  For instance,
rtapi_request_region always succeeds, and so there's no protection
against concurrent access to the same device's I/O ports by another
process or the kernel.

For me, the next milestone is userspace PCI support so that I can talk to my
5i20 card on the PCI bus.  I am optimistic that this work can be adapted from
the ubc3 branch.

Jeff

------------------------------------------------------------------------------
Open source business process management suite built on Java and Eclipse
Turn processes into business applications with Bonita BPM Community Edition
Quickly connect people, data, and systems into organized workflows
Winner of BOSSIE, CODIE, OW2 and Gartner awards
http://p.sf.net/sfu/Bonitasoft
_______________________________________________
Emc-developers mailing list
Emc-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/emc-developers

Reply via email to