Page MenuHomeFreeBSD

Fix MIPS pmap_align_superpage() function to use superpage rather than segment alignment
AcceptedPublic

Authored by rwatson on Mar 12 2016, 8:35 PM.
Tags
Referenced Files
F80207030: D5623.diff
Fri, Mar 29, 6:04 AM
Unknown Object (File)
Dec 23 2023, 7:45 PM
Unknown Object (File)
Dec 20 2023, 12:48 AM
Unknown Object (File)
Nov 17 2023, 12:57 PM
Unknown Object (File)
Nov 15 2023, 2:15 AM
Unknown Object (File)
Nov 11 2023, 2:32 AM
Unknown Object (File)
Nov 8 2023, 8:36 PM
Unknown Object (File)
Oct 25 2023, 10:02 AM

Details

Reviewers
adrian
sson
Group Reviewers
MIPS
Summary

When attempting to satisfy mmap() requests for superpage alignment on 64-bit MIPS, use superpage rather than physical-segment constants, or we may improperly fail to apply suitable alignment -- yet still allow mmap() to appear to succeed.

Test Plan

Tested on 64-bit MIPS BERI, but not on 32-bit MIPS. This patch includes the change required for the new 64-bit MIPS pmap, but if committed now would be applied only to the current pmap.

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

rwatson retitled this revision from to Fix MIPS pmap_align_superpage() function to use superpage rather than segment alignment.
rwatson updated this object.
rwatson edited the test plan for this revision. (Show Details)
rwatson added reviewers: MIPS, sson.
rwatson set the repository for this revision to rS FreeBSD src repository - subversion.
rwatson added a project: MIPS.

Yes, the superpage size should be 2M (PDRSIZE) for mips64. This looks correct. I am not sure it matters for mips32 given there is no superpage support for it yet. The way it is done for mips64 (see https://reviews.freebsd.org/D2535 ) may not work for mips32 given the limited number of available PTE bits. Of course, the mips64 superpage implementation was designed to support multiple superpage sizes (more than just 2M) although only one superpage size is currently implemented. I imagine with mips32 only one superpage size would be supported.

adrian added a reviewer: adrian.
adrian added a subscriber: adrian.

looks good then!

This revision is now accepted and ready to land.Sep 20 2016, 4:12 PM

MIPS has been removed from the tree