Changeset cd0a38e in mainline


Ignore:
Timestamp:
2022-02-10T23:37:51Z (2 years ago)
Author:
Jakub Jermář <jakub@…>
Branches:
master, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
917324b
Parents:
6ddd7f8
git-author:
Jakub Jermář <jakub@…> (2022-02-10 23:37:48)
git-committer:
Jakub Jermář <jakub@…> (2022-02-10 23:37:51)
Message:

Make km_unmap() right also on the other CPUs

The TLB shootdown sequence must not invalidate the entire kernel ASID
either on the non-current CPUs.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • kernel/generic/src/mm/km.c

    r6ddd7f8 rcd0a38e  
    166166        page_table_lock(AS_KERNEL, true);
    167167
    168         ipl = tlb_shootdown_start(TLB_INVL_ASID, ASID_KERNEL, 0, 0);
     168        size_t pages = size >> PAGE_WIDTH;
     169        ipl = tlb_shootdown_start(TLB_INVL_PAGES, ASID_KERNEL, vaddr, pages);
    169170
    170171        for (offs = 0; offs < size; offs += PAGE_SIZE)
    171172                page_mapping_remove(AS_KERNEL, vaddr + offs);
    172173
    173         tlb_invalidate_pages(ASID_KERNEL, vaddr, size >> PAGE_WIDTH);
     174        tlb_invalidate_pages(ASID_KERNEL, vaddr, pages);
    174175
    175176        as_invalidate_translation_cache(AS_KERNEL, 0, -1);
Note: See TracChangeset for help on using the changeset viewer.