Page MenuHomeFreeBSD

Generalise the arm64 ASID allocator
ClosedPublic

Authored by andrew on Feb 25 2020, 12:04 PM.
Tags
None
Referenced Files
F171890249: D23831.diff
Mon, Sep 14, 9:15 AM
Unknown Object (File)
Sat, Sep 12, 4:08 AM
Unknown Object (File)
Thu, Sep 10, 4:05 AM
Unknown Object (File)
Sun, Sep 6, 3:26 PM
Unknown Object (File)
Sun, Sep 6, 3:24 PM
Unknown Object (File)
Sun, Sep 6, 2:54 PM
Unknown Object (File)
Sun, Sep 6, 12:25 PM
Unknown Object (File)
Sun, Sep 6, 1:58 AM
Subscribers

Details

Summary

The requirements of an Address Space ID allocator and a Virtual Machine ID
allocator are similar. Generalise the former code so it can be used with
the latter.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Remove an unused variable

Is your overall strategy to incrementally replace PMAP_ASSERT_STAGE1(pmap)'s by correct handling of stage 2 PTE?

sys/arm64/arm64/pmap.c
998 ↗(On Diff #68800)

I would suggest moving the second sentence inside pmap_init_asids() and change the wording to: "We may be too early in ..."

5882 ↗(On Diff #68800)

if (pmap->pm_stage == PM_STAGE1) ... else ...?

This revision is now accepted and ready to land.Feb 25 2020, 4:50 PM
In D23831#523873, @alc wrote:

Is your overall strategy to incrementally replace PMAP_ASSERT_STAGE1(pmap)'s by correct handling of stage 2 PTE?

Yes. I'm currently working on pmap_enter and just need to implement cache and tlb handling for it.

sys/arm64/arm64/pmap.c
5882 ↗(On Diff #68800)

I'll add PMAP_ASSERT_STAGE1(pmap); for now as the process for VMID reset looks like it will be more complex, e.g. may need to call into the hypervisor.

  • Move a comment to follow code into pmap_init_asids
  • Assert we have a Stage 1 pmap in pmap_reset_asid_set and remove extra whitespace
This revision now requires review to proceed.Feb 25 2020, 7:06 PM
This revision was not accepted when it landed; it landed in state Needs Review.Feb 26 2020, 11:50 AM
This revision was automatically updated to reflect the committed changes.