mirror of
https://github.com/opnsense/src.git
synced 2026-06-07 15:52:40 -04:00
LinuxKPI: Add vm_flags_(clear|set) functions
Sponsored by: Serenity Cyber Security, LLC Reviewed by: emaste MFC after: 1 week
This commit is contained in:
parent
61fb195e8d
commit
06902a4479
1 changed files with 12 additions and 0 deletions
|
|
@ -324,6 +324,18 @@ vm_get_page_prot(unsigned long vm_flags)
|
|||
return (vm_flags & VM_PROT_ALL);
|
||||
}
|
||||
|
||||
static inline void
|
||||
vm_flags_set(struct vm_area_struct *vma, unsigned long flags)
|
||||
{
|
||||
vma->vm_flags |= flags;
|
||||
}
|
||||
|
||||
static inline void
|
||||
vm_flags_clear(struct vm_area_struct *vma, unsigned long flags)
|
||||
{
|
||||
vma->vm_flags &= ~flags;
|
||||
}
|
||||
|
||||
static inline struct page *
|
||||
vmalloc_to_page(const void *addr)
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in a new issue