How to map device addresses into user space
Dr. Rolf Jansen
rj at cyclaero.com
Thu Jan 3 16:45:37 UTC 2013
I am building a loadable kernel module for FreeBSD 9.1-RELEASE x86_64 for a PCI Data Acquisition board from National Instruments.
I need to map the Base Address Registers into user space memory, in order to pass the BAR's to the National Instruments Drivers Development Kit (NI-DDK). The DDK is a complex set of C++ classes running in user space, that read/write directly from/into the BAR's.
The FreeBSD bus_space_* functions are useless in this respect, because the DDK isn't designed that way, I need the BAR addresses mapped into user space.
Having the measurement done by the kernel module is not an option either, because it is math intensive, and kernel modules are build without SSE and with soft float.
I got tiny kernel modules/extensions only providing the mapped addresses of the PCI BAR's running together with the Measurement Routines using the NI-DDK on Darwin (Mac OS X) and Linux.
So, how can I map device addresses into user space on FreeBSD?
Best regards
Rolf
More information about the freebsd-drivers
mailing list