Page MenuHomeFreeBSD

arm64: Add CCA guest support
AbandonedPublic

Authored by sarah.walker2_arm.com on Mon, Apr 20, 1:17 PM.
Tags
None
Referenced Files
F153976313: D56520.id176092.diff
Sat, Apr 25, 5:26 AM
F153969465: D56520.id175986.diff
Sat, Apr 25, 4:29 AM
F153890104: D56520.diff
Fri, Apr 24, 1:47 PM
F153853042: D56520.diff
Fri, Apr 24, 6:38 AM
Unknown Object (File)
Thu, Apr 23, 12:51 PM
Unknown Object (File)
Wed, Apr 22, 6:57 PM
Unknown Object (File)
Mon, Apr 20, 8:07 PM
Subscribers

Details

Reviewers
andrew
manu
Summary

Realm status is determined early in bootup. PSCI initialisation has been moved
to initarm() to faciliate this.

When in a realm:

  • Mappings with mode VM_MEMATTR_DEVICE and VM_MEMATTR_DEVICE_NP are unprotected
  • Imported busdma buffers in protected memory are always bounced
  • If EARLY_PRINTK is in use, the UART physical address must be in the unprotected address space

Sponsored by: Arm Ltd

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 72434
Build 69317: arc lint + arc unit

Event Timeline

I think we can split out the pmap and busdma parts into 2 new revisions (i.e. one for pmap, one for busdma)

sys/arm64/arm64/rsi.c
57

This should live in pmap.c, and be marked as __read_mostly, e.g. like pmap_sh_attr. It would be useful to have pa in the name to make it obvious it's to be applied to the physical address. If FEAT_LPA2 is enabled it may not work with a page table as bits 51:50 of the output address are in bits 9:8 of the page table.

175

To get all physical memory we will need a new function that doesn't exclude EXFLAG_NOALLOC memory (e.g. the kernel image). Something like the following:

size_t
physmem_all(vm_paddr_t *avail, size_t maxavail) 
{
        return (regions_to_avail(avail, 0, maxavail, 0, NULL, NULL));
}

physmem_avail builds the array of physical memory we can allocate from so will not be complete.

177

We could drop these printf calls, or put them behind bootverbose