Hello,
being fully aware of security issues for this method I need to develop a driver which allows an application to directly access one bar of PCI device memory.
The reason for this odd technique is beyond the scope of my question.
From within a kernel mode driver I can do this using a sequence like:
IoAllocateMdl
MmBuildMdlForNonPagedPool
MmMapLockedPagesSpecifyCache (specifying non-cached for the physical device)
However, since the driver does not use DMA I thought of creating an UMDF driver.
Mapping of IO space within the driver can be simply done using
WdfDeviceMapIoSpace()
and since the driver runs in user space it returns a user space pointer which I assume is only valid in the context of the driver process i.e. the UMDF driver host process.
My question is if there is an analog method to MmMapLockedPagesSpecifyCache to make this pointer valid in the process which calls the driver?
Are named sections available in UMDF? ZwCreateSection etc.?
Thanks in advance for any hint