IceWalkers.com - Linux Software downloads and news
Name : Password :
Linux SoftwareLinux RPMLinux HowtosLink UsAboutAdvertise

free_hugepages (2)

ALLOC_HUGEPAGES(2)         Linux Programmer's Manual        ALLOC_HUGEPAGES(2)



NAME
       alloc_hugepages, free_hugepages - allocate or free huge pages

SYNOPSIS
       void*alloc_hugepages(int  key,void*addr,size_t len,int prot,int
       flag);

       intfree_hugepages(void*addr);

DESCRIPTION
       The system calls alloc_hugepages and free_hugepages were introduced  in
       Linux  2.5.36  and  removed again in 2.5.54.  They existed only on i386
       and ia64 (when built with CONFIG_HUGETLB_PAGE).  In  Linux  2.4.20  the
       syscall numbers exist, but the calls return ENOSYS.

       On  i386  the  memory management hardware knows about ordinary pages (4
       KiB) and huge pages (2 or 4 MiB). Similarly ia64 knows about huge pages
       of  several  sizes. These system calls serve to map huge pages into the
       process' memory or to free them again.  Huge pages are locked into mem-
       ory, and are not swapped.

       The  key  parameter  is an identifier. When zero the pages are private,
       and not inherited by children.  When positive the pages are shared with
       other  applications  using  the  same  key, and inherited by child pro-
       cesses.

       The addr parameter of free_hugepages() tells which page is being  freed
       -  it was the return value of a call to alloc_hugepages().  (The memory
       is first actually freed when all users have  released  it.)   The  addr
       parameter  of  alloc_hugepages()  is a hint, that the kernel may or may
       not follow.  Addresses must be properly aligned.

       The len parameter is the length of the required segment. It must  be  a
       multiple of the huge page size.

       The  prot parameter specifies the memory protection of the segment.  It
       is one of PROT_READ, PROT_WRITE, PROT_EXEC.

       The flag parameter is ignored, unless key is positive. In that case, if
       flag  is  IPC_CREAT,  then a new huge page segment is created when none
       with the given key existed. If this flag is not  set,  then  ENOENT  is
       returned when no segment with the given key exists.

RETURNVALUE
       On  success, alloc_hugepages returns the allocated virtual address, and
       free_hugepages returns zero. On error, -1 is returned, and errno is set
       appropriately.

ERRORS
       ENOSYS The system call is not supported on this kernel.

CONFORMINGTO
       These  calls  existed  only  in Linux 2.5.36 - 2.5.54.  These calls are
       specific to Linux on Intel processors, and should not be used  in  pro-
       grams  intended  to  be  portable.  Indeed, the system call numbers are
       marked for reuse, so programs using these may do something random on  a
       future kernel.

FILES
       /proc/sys/vm/nr_hugepages Number of configured hugetlb pages.  This can
       be read and written.

       /proc/meminfo Gives info on the number of configured hugetlb pages  and
       on  their  size in the three variables HugePages_Total, HugePages_Free,
       Hugepagesize.

NOTES
       The system calls are gone. Now the hugetlbfs  filesystem  can  be  used
       instead.   Memory  backed  by  huge pages (if the CPU supports them) is
       obtained by mmap'ing files in this virtual filesystem.

       The maximal number of huge pages can be specified using the  hugepages=
       boot parameter.





Linux 2.5.36                      2003-02-02                ALLOC_HUGEPAGES(2)

_Exitgetsockoptoutwshmat
_exitgettidoutw_pshmctl
_llseekgettimeofdaypauseshmdt
_newselectgetuidpersonalityshmget
_sysctlgttypipeshmop
acceptidlepivot_rootshutdown
accessinbpollsigaction
acctinb_pprctlsigaltstack
adjtimexinlpreadsigblock
afs_syscallinl_pprofsiggetmask
alarminsbpselectsigmask
alloc_hugepagesinslptracesignal
arch_prctlinswpwritesigpause
bdflushintroquotactlsigpending
bindinwreadsigprocmask
breakinw_preaddirsigqueue
brkioctlreadlinksigreturn
cacheflushioctl_listreadvsigsetmask
capgetiopermrebootsigsuspend
capsetioplrecvsigtimedwait
chdiripcrecvfromsigvec
chmodkillrecvmsgsigwaitinfo
chownkillpgrenamesocket
chrootlchownrmdirsocketcall
clonelinksbrksocketpair
closelistensched_get_priority_maxssetmask
connectllseeksched_get_priority_minstat
creatlocksched_getaffinitystatfs
duplseeksched_getparamstime
dup2lstatsched_getschedulerstty
execvemadvisesched_rr_get_intervalswapoff
exitmincoresched_setaffinityswapon
fchdirmkdirsched_setparamsymlink
fchmodmknodsched_setschedulersync
fchownmlocksched_yieldsyscall
fcntlmlockallselectsyscalls
fdatasyncmmapselect_tutsysctl
flockmmap2semctlsysfs
forkmodify_ldtsemgetsysinfo
free_hugepagesmountsemopsyslog
fstatmprotectsendtime
fstatfsmpxsendfiletimes
fsyncmremapsendmsgtkill
ftruncatemsgctlsendtotruncate
futexmsggetsetcontextumask
getcontextmsgopsetdomainnameumount
getdentsmsgrcvsetegidumount2
getdomainnamemsgsndseteuiduname
getdtablesizemsyncsetfsgidundocumented
getegidmunlocksetfsuidunimplemented
geteuidmunlockallsetgidunlink
getgidmunmapsetgroupsuselib
getgroupsnanosleepsethostidustat
gethostidnfsservctlsethostnameutime
gethostnamenicesetitimerutimes
getitimerobsoletesetpgidvfork
getpagesizeoldfstatsetpgrpvhangup
getpeernameoldlstatsetpriorityvm86
getpgidoldoldunamesetregidwait
getpgrpoldstatsetresgidwait3
getpidoldunamesetresuidwait4
getppidopensetreuidwaitpid
getpriorityoutbsetrlimitwrite
getresgidoutb_psetsidwritev
getresuidoutlsetsockopt 
getrlimitoutl_psettimeofday 
getrusageoutsbsetuid 
getsidoutslsetup 


My Money 2.0.49
Personal financial software
Linux Kernel 2.6 2.6.32-rc8
Linux Kernel
GCstar 1.5.0
Personal collections manager
ImageMagick 6.5.7.9
ImageMagick image processing studio
BibleTime 2.4
Bible study software for Linux / KDE
PHP 5.3.1
Server-side, cross-platform, HTML embedded scripting language.
LFTP 4.0.4
Shell-like command line ftp client.
GNOME 2.29.2
GNOME desktop environment
Midgard 9.09.0
Web application development and publishing platform
Totem 2.28.4
Movie player for Gnome
Free IT Magazines, White Papers, eBooks, and more !
Oracle Magazine

Contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more.

Vulnerability Management for Dummies

Get all the Facts and See How to Implement a Successful Vulnerability Management Program.

Website Magazine

Has tapped premier talent in the Internet industry for our content and each and every issue will contain practical advice and insights for website owners.

Linux Software Map
Find Linux RPM
Best Rated Linux Software
Most Rated Linux Software
Linux Distributions
Linux Howtos
Quick Survey

Please take our survey and help us improve our website to serve you better.

Thank you.
Linux Software
Linux / IT Resources
Site Resources
Google
Privacy Policy
Contact Us
Submit Software
Advertising info