Page MenuHomeFreeBSD

Fix pmap_change_attr() on arm64 to allow KV addresses
ClosedPublic

Authored by mk_semihalf.com on Oct 16 2019, 11:22 AM.
Tags
Referenced Files
Unknown Object (File)
Mon, Apr 22, 6:02 PM
Unknown Object (File)
Fri, Apr 19, 9:25 AM
Unknown Object (File)
Sat, Apr 6, 3:26 PM
Unknown Object (File)
Feb 19 2024, 4:17 AM
Unknown Object (File)
Feb 11 2024, 8:50 AM
Unknown Object (File)
Dec 20 2023, 1:09 PM
Unknown Object (File)
Dec 20 2023, 12:46 AM
Unknown Object (File)
Dec 9 2023, 6:46 AM

Details

Summary

Altough in the comment above the pmap_change_attr() it was mentioned
that VA could be in KV or DMAP memory space. However,
pmap_change_attr_locked() was accepting only the values inside the DMAP
memory range.

To fix that, the condition check was changed so also the va inside the
KV memory range would be accepted.

The sample use case that wasn't supported is the PCI Device that has the
BAR which should me mapped with the Write Combine attribute - for
example BAR2 of the ENA network controller on the A1 instances on AWS.

Submitted by: Michal Krawczyk <mk@semihalf.com>
Obtained from: Semihalf
Sponsored by: Amazon, Inc.

Test Plan

Tested on A1 AWS instance and changed ENA BAR2 mapped resource to be write combined memory region

Diff Detail

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