mirror of
https://github.com/opnsense/src.git
synced 2026-06-09 08:43:19 -04:00
Style and comment tweaks, no functional changes.
This commit is contained in:
parent
b4df095c2e
commit
0f7191e8ad
2 changed files with 11 additions and 10 deletions
|
|
@ -62,7 +62,7 @@ vm_offset_t
|
|||
arm_devmap_lastaddr()
|
||||
{
|
||||
const struct arm_devmap_entry *pd;
|
||||
vm_offset_t lowaddr = ARM_VECTORS_HIGH;
|
||||
vm_offset_t lowaddr;
|
||||
|
||||
if (akva_devmap_idx > 0)
|
||||
return (akva_devmap_vaddr);
|
||||
|
|
@ -70,6 +70,7 @@ arm_devmap_lastaddr()
|
|||
if (devmap_table == NULL)
|
||||
panic("arm_devmap_lastaddr(): No devmap table registered.");
|
||||
|
||||
lowaddr = ARM_VECTORS_HIGH;
|
||||
for (pd = devmap_table; pd->pd_size != 0; ++pd) {
|
||||
if (lowaddr > pd->pd_va)
|
||||
lowaddr = pd->pd_va;
|
||||
|
|
@ -95,7 +96,7 @@ arm_devmap_add_entry(vm_paddr_t pa, vm_size_t sz)
|
|||
panic("arm_devmap_add_entry() after arm_devmap_bootstrap()");
|
||||
|
||||
if (akva_devmap_idx == (AKVA_DEVMAP_MAX_ENTRIES - 1))
|
||||
panic("AKVA_DEVMAP_MAX_ENTRIES is too small!\n");
|
||||
panic("AKVA_DEVMAP_MAX_ENTRIES is too small");
|
||||
|
||||
if (akva_devmap_idx == 0)
|
||||
arm_devmap_register_table(akva_devmap_entries);
|
||||
|
|
@ -152,7 +153,7 @@ arm_devmap_bootstrap(vm_offset_t l1pt, const struct arm_devmap_entry *table)
|
|||
if (table != NULL)
|
||||
devmap_table = table;
|
||||
else if (devmap_table == NULL)
|
||||
panic("arm_devmap_bootstrap(): No devmap table registered.");
|
||||
panic("arm_devmap_bootstrap(): No devmap table registered");
|
||||
|
||||
for (pd = devmap_table; pd->pd_size != 0; ++pd) {
|
||||
pmap_map_chunk(l1pt, pd->pd_va, pd->pd_pa, pd->pd_size,
|
||||
|
|
|
|||
|
|
@ -42,18 +42,18 @@ struct arm_devmap_entry {
|
|||
};
|
||||
|
||||
/*
|
||||
* Returns the lowest KVA address used in any entry in the registered devmap
|
||||
* Return the lowest KVA address used in any entry in the registered devmap
|
||||
* table. This works with whatever table is registered, including the internal
|
||||
* table used by arm_devmap_add_entry() if that routinue was used. Platforms can
|
||||
* table used by arm_devmap_add_entry() if that routine was used. Platforms can
|
||||
* implement initarm_lastaddr() by calling this if static device mappings are
|
||||
* their only use of high KVA space.
|
||||
*/
|
||||
vm_offset_t arm_devmap_lastaddr(void);
|
||||
|
||||
/*
|
||||
* Routine to automatically allocate KVA (from the top of the address space
|
||||
* downwards) and make static device mapping entries in an internal table. The
|
||||
* internal table is automatically registered on the first call to this.
|
||||
* Automatically allocate KVA (from the top of the address space downwards) and
|
||||
* make static device mapping entries in an internal table. The internal table
|
||||
* is automatically registered on the first call to this.
|
||||
*/
|
||||
void arm_devmap_add_entry(vm_paddr_t pa, vm_size_t sz);
|
||||
|
||||
|
|
@ -74,8 +74,8 @@ void arm_devmap_bootstrap(vm_offset_t _l1pt,
|
|||
const struct arm_devmap_entry *_table);
|
||||
|
||||
/*
|
||||
* Routines to translate between virtual and physical addresses within a region
|
||||
* that is static-mapped by the devmap code. If the given address range isn't
|
||||
* Translate between virtual and physical addresses within a region that is
|
||||
* static-mapped by the devmap code. If the given address range isn't
|
||||
* static-mapped, then ptov returns NULL and vtop returns DEVMAP_PADDR_NOTFOUND.
|
||||
* The latter implies that you can't vtop just the last byte of physical address
|
||||
* space. This is not as limiting as it might sound, because even if a device
|
||||
|
|
|
|||
Loading…
Reference in a new issue