• Home
  • Raw
  • Download

Lines Matching refs:md

15 static bool region_is_misaligned(const efi_memory_desc_t *md)  in region_is_misaligned()  argument
19 return !PAGE_ALIGNED(md->phys_addr) || in region_is_misaligned()
20 !PAGE_ALIGNED(md->num_pages << EFI_PAGE_SHIFT); in region_is_misaligned()
28 static __init pteval_t create_mapping_protection(efi_memory_desc_t *md) in create_mapping_protection() argument
30 u64 attr = md->attribute; in create_mapping_protection()
31 u32 type = md->type; in create_mapping_protection()
36 if (region_is_misaligned(md)) { in create_mapping_protection()
76 int __init efi_create_mapping(struct mm_struct *mm, efi_memory_desc_t *md) in efi_create_mapping() argument
78 pteval_t prot_val = create_mapping_protection(md); in efi_create_mapping()
79 bool page_mappings_only = (md->type == EFI_RUNTIME_SERVICES_CODE || in efi_create_mapping()
80 md->type == EFI_RUNTIME_SERVICES_DATA); in efi_create_mapping()
90 if (region_is_misaligned(md)) in efi_create_mapping()
93 create_pgd_mapping(mm, md->phys_addr, md->virt_addr, in efi_create_mapping()
94 md->num_pages << EFI_PAGE_SHIFT, in efi_create_mapping()
101 efi_memory_desc_t *md = data; in set_permissions() local
104 if (md->attribute & EFI_MEMORY_RO) in set_permissions()
106 if (md->attribute & EFI_MEMORY_XP) in set_permissions()
113 efi_memory_desc_t *md) in efi_set_mapping_permissions() argument
115 BUG_ON(md->type != EFI_RUNTIME_SERVICES_CODE && in efi_set_mapping_permissions()
116 md->type != EFI_RUNTIME_SERVICES_DATA); in efi_set_mapping_permissions()
118 if (region_is_misaligned(md)) in efi_set_mapping_permissions()
128 return apply_to_page_range(mm, md->virt_addr, in efi_set_mapping_permissions()
129 md->num_pages << EFI_PAGE_SHIFT, in efi_set_mapping_permissions()
130 set_permissions, md); in efi_set_mapping_permissions()