blob: 4315f31dd71ce980ed46d0cf1caaca13e732e72a [file]
// Copyright 2026 The Fuchsia Authors
//
// Use of this source code is governed by a MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT
#ifndef ZIRCON_KERNEL_PHYS_MEMORY_IDENTITY_MAP_H_
#define ZIRCON_KERNEL_PHYS_MEMORY_IDENTITY_MAP_H_
class AddressSpace;
// Identity maps in all RAM as RWX.
void IdentityMapRam(AddressSpace& aspace);
// Identity maps in the global UART's registers (assuming that they fit within
// a single page).
void IdentityMapUart(AddressSpace& aspace);
// Perform architecture-specific identity-mapped address space set-up. This
// assumes that only the boot conditions hold and is expected to be called
// before "normal work" can proceed. The AddressSpace object must not go out
// of scope while installed. It's usually on the stack of PhysMain.
void ArchSetUpIdentityMap(AddressSpace& aspace);
#endif // ZIRCON_KERNEL_PHYS_MEMORY_IDENTITY_MAP_H_