https://github.com/torvalds/linux
Raw File
Tip revision: d07f6ca923ea0927a1024dfccafc5b53b61cfecc authored by Linus Torvalds on 16 May 2021, 22:27:44 UTC
Linux 5.13-rc2
Tip revision: d07f6ca
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