Virtual DMA Services (VDS)

DOS API Virtual DMA Services (VDS) Ver 1.00  
PW0519 Virtual DMA Services (VDS) App Note PW0519 September 1992
PS/2 BIOS Int 4BH—Adv Svcs, AH=81H - Op System DMA Svcs
Int 4B Section of Ralf Brown's Interrupt List HTML Version - Release 61

Writing Windows VxDs and Device Drivers, (2nd ed) by Karen Hazzah

App Note 011 DMA Fundamentals on Various PC Platforms  National Semi
DMA Fundamentals PC/XT, PC/AT, and MCA [extract of NS App Note 011]
8237A DMA Controller Errata from Michal Necasek

IBM DMA  
DMA Function [from IBM Seminar, May 1991]
DMA Type 1 PIO Interface   HTML
DMA Controller Architecture, Type 1 [PIO]   PDF
    HITR - Common Interfaces, DMA Controller (Jul 1992) (98 pages)
ABIOS Device ID 0FH - DMA (pgs 103-116 physical) 1st Ed (Sep 1991)
Direct Memory Access Bus Control from MCAH, pgs 169-171

Ultimedia7-6_24.IMA   Ultimedia 7-6 W95 Driver with DMA Support

Ryan Alswede was able to finally get the 7-6 Ultimedia to support DMA on W95.

The VDMAD.VXD is and forever will be ISA land.  There is no universal fix for that.  If you want a card to work that is DMA slave controller dependent then you have to write the driver to do the work. Rather than telling VDMAD.VXD to do the operation which it would try to do using ISA logic, you have to get the data from it and move it yourself and then call back to VDMAD.VXD to get it to tell the OS what you did. I still do 8 bit transfers as that's what the CS4231A is designed to consume. If you try to do 16 bit the CS4231A will drop half the wav sound bits.

Original Brainstorm Session  

8237A ISA Emulation vs. MCA Extended DMA. Windows 95's VDMAD.VXD virtualizes the legacy ISA-style Intel 8237A DMA controller (ports 00h–0Fh, C0h–DFh, and 8-bit page registers 80h–8Fh). While IBM PS/2 Micro Channel systems maintain partial backward compatibility with 8237A ports, their actual DMA controller supports extended MCA DMA registers (ports 18h and 1Ah) that handle 24-bit/32-bit addressing, 16-bit transfers on any channel (including channels 0–3), and programmable arbitration levels.

Bus-Master & Arbitration Logic. The SMC MCI94C18ALJ acts as an interface bridge between the Micro Channel bus (handling POS registers, MCA arbitration, and card-level DMA routing) and an ISA-style peripheral (like the Crystal CS4231A audio codec on the IBM Ultimedia 7-6). VDMAD.VXD only intercepts and translates standard 8237A I/O traps and does not natively manage MCA arbitration levels or bridge-specific DMA routing registers.

24-Bit Linear Addressing vs. 64KB Page Boundaries. Standard 8237A DMA managed by VDMAD splits transfers across 64KB (or 128KB for 16-bit channels) page boundaries using separate page registers. MCA DMA hardware and bridge chips like the MCI94C18ALJ use contiguous 24-bit physical address registers via the MCA DMA controller, causing address/count mismatches if VDMAD attempts to split or virtualize the transfer buffers using ISA rules.

Auto-Initialize & Channel Masking Behavior. Standard VDMAD buffers rely on 8237A mode and mask registers to track buffer wrap-around and physical-to-linear page translation (VDS—Virtual DMA Services). Because the MCI94C18ALJ relies on the MCA subsystem and its own bridge control registers to route DMA requests (DRQ/DACK), VDMAD cannot transparently trap or double-buffer transfers when memory pages are non-contiguous. [1]

How Drivers Work Around This  

To use DMA with the SMC MCI94C18ALJ in Windows 95, a custom VxD cannot rely on VDMAD's standard 8237A trapping:

Direct VDS / Contiguous Physical Buffers. The driver must allocate physically contiguous, locked memory below 16MB (via _PageAllocate with PageContig and PageFixed flags) so VDMAD does not need to perform scatter/gather page remapping. [1]

Bypassing VDMAD Port Trapping. Instead of letting VDMAD virtualize the channel via standard 8237A I/O ports, the VxD must explicitly disable VDMAD translation on that channel (VDMAD_Disable_Translation) and program both the MCA extended DMA registers (18h/1Ah) and the MCI94C18ALJ bridge registers directly.

1: https://www.os2museum.com/wp/vds-borne-out-of-necessity/