Skip to content

Bug: KernelPtConfig::item_from_raw does not restore an exacly same MappedItem #625

Description

@rikosellic

@hiroki-chen @Marsman1996 @SNoAnd According to the documentation, PageTableConfig::item_from_raw should restore the exact item that item_into_raw consumed. Unfortunately, KernelPtConfig failed to clear the AVAIL1 bit, which is used to indicate trackedness, violating the documented constraint and complicating verification.

As the PageTableConfig has been refactored in newer Asterinas versions, I propose changing this code to deal with AVAIL1 only in our codebase in #622 to make our verification smoother.

/// - if the provided raw form matches the item that was consumed by
/// `item_into_raw`, `item_from_raw` restores the exact item that was
/// consumed by `item_into_raw`.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions