From c725c69d77fba9466cada018db8673136c6868e9 Mon Sep 17 00:00:00 2001 From: Leah Neukirchen Date: Fri, 9 Feb 2018 22:21:46 +0100 Subject: [PATCH] include/linux/log2.h: define PAGE_SHIFT when needed --- include/linux/log2.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/include/linux/log2.h b/include/linux/log2.h index 1f977d60..96f62458 100644 --- a/include/linux/log2.h +++ b/include/linux/log2.h @@ -12,7 +12,13 @@ #ifndef _TOOLS_LINUX_LOG2_H #define _TOOLS_LINUX_LOG2_H +#include +#ifndef PAGE_SHIFT +#define PAGE_SHIFT ilog2(PAGE_SIZE) +#endif + #include +#include /* * deal with unrepresentable constant logarithms