diff options
author | Andrea Righi <righi.andrea@gmail.com> | 2008-07-26 15:22:27 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2008-07-26 20:16:47 -0700 |
commit | 510a35d4a47802f4a0028aa6bd2ca2170da5e32f (patch) | |
tree | 8eb0d6091fe89f013436c5080dc4cbaf825172cf /include/linux/hugetlb.h | |
parent | b2d002dba5a8a4c0c3ec96fd1ff3c9def6bd71a1 (diff) | |
download | lwn-510a35d4a47802f4a0028aa6bd2ca2170da5e32f.tar.gz lwn-510a35d4a47802f4a0028aa6bd2ca2170da5e32f.zip |
hugetlb: remove unused variable warning
Remove the following warning when CONFIG_HUGETLB_PAGE is not set:
ipc/shm.c: In function `shm_get_stat':
ipc/shm.c:565: warning: unused variable `h'
[akpm@linux-foundation.org: use tabs, not spaces]
Signed-off-by: Andrea Righi <righi.andrea@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/hugetlb.h')
-rw-r--r-- | include/linux/hugetlb.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/include/linux/hugetlb.h b/include/linux/hugetlb.h index 9a71d4cc88c8..32e0ef0f6e1f 100644 --- a/include/linux/hugetlb.h +++ b/include/linux/hugetlb.h @@ -273,7 +273,10 @@ struct hstate {}; #define huge_page_mask(h) PAGE_MASK #define huge_page_order(h) 0 #define huge_page_shift(h) PAGE_SHIFT -#define pages_per_huge_page(h) 1 +static inline unsigned int pages_per_huge_page(struct hstate *h) +{ + return 1; +} #endif #endif /* _LINUX_HUGETLB_H */ |