Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Memory mapping issues in ARM64 #351

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Commits on Sep 14, 2022

  1. kernel: vm: Fix incorrect argument passing in 'vm map' test

    vm map takes arg 3 as virtual address. And same needs
    to be passed to retrieve aspace. Fix this by passing
    right arg.
    
    Test: Ran 'vm map' test
            ] vm map 0xc0000000 0xffff000ff0000000 1 0x0
            arch_mmu_map returns 0
    
    Signed-off-by: Chintan Pandya <[email protected]>
    Chintan Pandya committed Sep 14, 2022
    Configuration menu
    Copy the full SHA
    a4a0da2 View commit details
    Browse the repository at this point in the history
  2. kernel: vm: Don't let mismatch attribute alias mapping be created

    Alias mapping with different mapping attributes creates
    unknown behavior with either of the mappings. This was
    specially observed when previously mapped cached region
    is re-mapped at other virtual address as uncached region
    creating stability issues as mentioned in b/240659444.
    Do proper error checking for new mappings against
    mmu_initial_mapping.
    
    Test: Created alias mapping with mismatch attribute and
          tested on gem5
            ] vmm alloc_physical 0xc0000000 4096 10
            Mismatch attributes, device mapping failed
            vmm_alloc_physical: arch_mmu_map returns -17
            vmm_alloc_physical returns -5, ptr 0xffff000000000000
    
            ] vmm alloc_physical 0x2A000000 4096 10
            vmm_alloc_physical returns 0, ptr 0xffff000000000000
    
    Signed-off-by: Chintan Pandya <[email protected]>
    Chintan Pandya committed Sep 14, 2022
    Configuration menu
    Copy the full SHA
    b2a8e31 View commit details
    Browse the repository at this point in the history