Zou Nan hai wrote:
> Introduce 2 prctl option to set/get hugepage size.
> --- a/kernel/sys.c 2006-04-13 08:41:37.000000000 +0800
> +++ b/kernel/sys.c 2006-04-13 08:47:41.000000000 +0800
> +#ifndef GET_HUGEPAGESIZE
> +# define GET_HUGEPAGESIZE(a,b) (-EINVAL)
> +#endif
> +#ifndef SET_HUGEPAGESIZE
> +# define SET_HUGEPAGESIZE(a,b) (-EINVAL)
> +#endif
>
> @@ -2057,6 +2063,12 @@ asmlinkage long sys_prctl(int option, un
> return -EFAULT;
> return 0;
> }
> + case PR_SET_HUGEPAGE_SIZE:
> + error = SET_HUGEPAGESIZE(current, arg2);
> + break;
> + case PR_GET_HUGEPAGE_SIZE:
> + error = GET_HUGEPAGESIZE(current, arg2);
> + break;
> default:
> error = -EINVAL;
> break;
for architectures which do not support variable hugepage sizes I would
prefer, that
- prctl(PR_SET_HUGEPAGE_SIZE, DEFAULT_HPAGE_SIZE) returns OK instead of
FAIL.
- prctl(PR_GET_HUGEPAGE_SIZE) returns the DEFAULT_HPAGE_SIZE instead of
FAIL.
Helge
--
"Feel free" - 10 GB Mailbox, 100 FreeSMS/Monat ...
Jetzt GMX TopMail testen: http://www.gmx.net/de/go/topmail
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
[Index of Archives]
[Kernel Newbies]
[Netfilter]
[Bugtraq]
[Photo]
[Stuff]
[Gimp]
[Yosemite News]
[MIPS Linux]
[ARM Linux]
[Linux Security]
[Linux RAID]
[Video 4 Linux]
[Linux for the blind]
[Linux Resources]