KernelTestFramework / ktf

Kernel Test Framework
BSD 2-Clause "Simplified" License
140 stars 18 forks source link

[Feature] Allow specifying size of range to address mapping APIs #253

Closed cjams closed 11 months ago

cjams commented 2 years ago

Is your feature request related to a problem? Please describe. Some clients of the map/unmap APIs need to map a range of virtual address space. For example, mapping PCI MMIO bars that span multiple 4k pages. AcpiOsMapMemory also maps multiple 4k pages at a time. The current API only allows mapping at 4K/2M/1G granularity, but often the range is between those.

Describe the solution you'd like This feature would enable clients of the mapping APIs to specify a size of the range to map/unmap, reducing the pointer bookkeeping required by clients.

Describe alternatives you've considered Keeping the APIs as-is, and requiring each client to keep track of the pointers to each individual page in the range