This is an example of documentation generated by ZigDoc, an alternative to Zig's built-in Auto Doc feature. See also examples in other modes/formats. The project being documented here (as the example) is the Zig standard library. Public Function
This function scans the memory map to locate free pages. When it finds a physically contiguous block of pages that is large enough and also satisfies the allocation requirements of alloc_type, it changes the memory map to indicate that the pages are now of type mem_type.
In general, UEFI OS loaders and UEFI applications should allocate memory (and pool) of type .loader_data. UEFI boot service drivers must allocate memory (and pool) of type .boot_services_data. UREFI runtime drivers should allocate memory (and pool) of type .runtime_services_data (although such allocation can only be made during boot services time).
Allocation requests of .allocate_any_pages allocate any available range of pages that satisfies the request.
Allocation requests of .allocate_max_address allocate any available range of pages whose uppermost address is less than or equal to the address pointed to by the input.
Allocation requests of .allocate_address allocate pages at the address pointed to by the input.
Allocates pages of memory.
This function scans the memory map to locate free pages. When it finds a physically contiguous block of pages that is large enough and also satisfies the allocation requirements of
alloc_type, it changes the memory map to indicate that the pages are now of typemem_type.In general, UEFI OS loaders and UEFI applications should allocate memory (and pool) of type
.loader_data. UEFI boot service drivers must allocate memory (and pool) of type.boot_services_data. UREFI runtime drivers should allocate memory (and pool) of type.runtime_services_data(although such allocation can only be made during boot services time).Allocation requests of
.allocate_any_pagesallocate any available range of pages that satisfies the request.Allocation requests of
.allocate_max_addressallocate any available range of pages whose uppermost address is less than or equal to the address pointed to by the input.Allocation requests of
.allocate_addressallocate pages at the address pointed to by the input.