Library Calls for QnX Rtos 6.2 for DMA

I would like to get info re library calls for reserving and controlling DMA channel for a PC-104 bus controller. The controller uses DMA channels 0, 1 2 and 3. I have used Linux/SCO Unix, etc, and the library for these OS’s provides functions to reserve (i.e. is the channel available), set up, enable and disable DMA channels. I can’t find equivalent library calls in the Rtos 6.2 Library API.

There is no such API in QNX6, DMA channel is not a resource managed by the OS.

I understand. Just one more question. How can I safely determine programmatically if a given DMA channel is already being used by some other driver or application ? (This is the real problem for me. Controlling the DMA channels is very simple.)

There is no safe way that I know of. You could maybe probe the resisters of the DMA controller to check which one are set or not (just a guess). This comes down to hardware issue and had little to do with the OS, just like if you’d be under DOS ;-( Tthe problem is the same with IRQ and io port when you are talking ISA bus !

That is one of the things an API is for, and what better place to have an API to the general hardware than with the OS itself.

That said, since the legacy spaces are not used by new devices and even by Intels standards are badly implemented, I can see why they are not being supported.

PS: Interrupts are very much a supported feature. And very important to an event driven OS :slight_smile:

Thanks for correcting my mistake ;-) I meant allocation of Interrupt on ISA is not manage by OS. With PCI it`s managed by BIOS and OS.

Ah, we are talking two different things. Allocating vs detecting.