https://github.com/torvalds/linux
Raw File
Tip revision: 98b1cc82c4affc16f5598d4fa14b1858671b2263 authored by Linus Torvalds on 19 November 2023, 23:02:14 UTC
Linux 6.7-rc2
Tip revision: 98b1cc8
hugetlb_inline.h
/* SPDX-License-Identifier: GPL-2.0 */
#ifndef _LINUX_HUGETLB_INLINE_H
#define _LINUX_HUGETLB_INLINE_H

#ifdef CONFIG_HUGETLB_PAGE

#include <linux/mm.h>

static inline bool is_vm_hugetlb_page(struct vm_area_struct *vma)
{
	return !!(vma->vm_flags & VM_HUGETLB);
}

#else

static inline bool is_vm_hugetlb_page(struct vm_area_struct *vma)
{
	return false;
}

#endif

#endif
back to top