From 5386e735897afd8bcd332caf21a5f68d9e0e81c6 Mon Sep 17 00:00:00 2001 From: Chris Metcalf Date: Mon, 2 May 2011 16:21:12 -0400 Subject: arch/tile: kernel-related cleanups from removing static page size User space code has been able to discover the static page size by including a special file. In the current release, that file is now gone, and doesn't rely on it. The getpagesize() API is now the only way for userspace to get the page size. Signed-off-by: Chris Metcalf --- arch/tile/include/hv/hypervisor.h | 12 ++++++++++-- arch/tile/include/hv/pagesize.h | 32 -------------------------------- 2 files changed, 10 insertions(+), 34 deletions(-) delete mode 100644 arch/tile/include/hv/pagesize.h (limited to 'arch/tile/include/hv') diff --git a/arch/tile/include/hv/hypervisor.h b/arch/tile/include/hv/hypervisor.h index ee41bca4c8c..72ec1e972f1 100644 --- a/arch/tile/include/hv/hypervisor.h +++ b/arch/tile/include/hv/hypervisor.h @@ -22,8 +22,6 @@ #include -#include - /* Linux builds want unsigned long constants, but assembler wants numbers */ #ifdef __ASSEMBLER__ /** One, for assembler */ @@ -44,11 +42,21 @@ */ #define HV_L1_SPAN (__HV_SIZE_ONE << HV_LOG2_L1_SPAN) +/** The log2 of the size of small pages, in bytes. This value should + * be verified at runtime by calling hv_sysconf(HV_SYSCONF_PAGE_SIZE_SMALL). + */ +#define HV_LOG2_PAGE_SIZE_SMALL 16 + /** The size of small pages, in bytes. This value should be verified * at runtime by calling hv_sysconf(HV_SYSCONF_PAGE_SIZE_SMALL). */ #define HV_PAGE_SIZE_SMALL (__HV_SIZE_ONE << HV_LOG2_PAGE_SIZE_SMALL) +/** The log2 of the size of large pages, in bytes. This value should be + * verified at runtime by calling hv_sysconf(HV_SYSCONF_PAGE_SIZE_LARGE). + */ +#define HV_LOG2_PAGE_SIZE_LARGE 24 + /** The size of large pages, in bytes. This value should be verified * at runtime by calling hv_sysconf(HV_SYSCONF_PAGE_SIZE_LARGE). */ diff --git a/arch/tile/include/hv/pagesize.h b/arch/tile/include/hv/pagesize.h deleted file mode 100644 index 58bed114fed..00000000000 --- a/arch/tile/include/hv/pagesize.h +++ /dev/null @@ -1,32 +0,0 @@ -/* - * Copyright 2010 Tilera Corporation. All Rights Reserved. - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation, version 2. - * - * This program is distributed in the hope that it will be useful, but - * WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE, GOOD TITLE or - * NON INFRINGEMENT. See the GNU General Public License for - * more details. - */ - -/** - * @file pagesize.h - */ - -#ifndef _HV_PAGESIZE_H -#define _HV_PAGESIZE_H - -/** The log2 of the size of small pages, in bytes. This value should - * be verified at runtime by calling hv_sysconf(HV_SYSCONF_PAGE_SIZE_SMALL). - */ -#define HV_LOG2_PAGE_SIZE_SMALL 16 - -/** The log2 of the size of large pages, in bytes. This value should be - * verified at runtime by calling hv_sysconf(HV_SYSCONF_PAGE_SIZE_LARGE). - */ -#define HV_LOG2_PAGE_SIZE_LARGE 24 - -#endif /* _HV_PAGESIZE_H */ -- cgit v1.2.3-70-g09d2