Back to index

numactl  2.0.8~rc4
Defines | Functions
syscall.c File Reference
#include <unistd.h>
#include <sys/types.h>
#include <asm/unistd.h>
#include <errno.h>
#include "numa.h"
#include "numaif.h"
#include "numaint.h"

Go to the source code of this file.

Defines

#define WEAK   __attribute__((weak))
#define syscall6   syscall

Functions

long WEAK get_mempolicy (int *policy, const unsigned long *nmask, unsigned long maxnode, void *addr, int flags)
long WEAK mbind (void *start, unsigned long len, int mode, const unsigned long *nmask, unsigned long maxnode, unsigned flags)
long WEAK set_mempolicy (int mode, const unsigned long *nmask, unsigned long maxnode)
long WEAK migrate_pages (int pid, unsigned long maxnode, const unsigned long *frommask, const unsigned long *tomask)
long WEAK move_pages (int pid, unsigned long count, void **pages, const int *nodes, int *status, int flags)
int numa_sched_setaffinity_v1 (pid_t pid, unsigned len, const unsigned long *mask)
 __asm__ (".symver numa_sched_setaffinity_v1,numa_sched_setaffinity@libnuma_1.1")
int numa_sched_setaffinity_v2 (pid_t pid, struct bitmask *mask)
 __asm__ (".symver numa_sched_setaffinity_v2,numa_sched_setaffinity@@libnuma_1.2")
int numa_sched_getaffinity_v1 (pid_t pid, unsigned len, const unsigned long *mask)
 __asm__ (".symver numa_sched_getaffinity_v1,numa_sched_getaffinity@libnuma_1.1")
int numa_sched_getaffinity_v2 (pid_t pid, struct bitmask *mask)
 __asm__ (".symver numa_sched_getaffinity_v2,numa_sched_getaffinity@@libnuma_1.2")
 make_internal_alias (numa_sched_getaffinity_v1)
 make_internal_alias (numa_sched_getaffinity_v2)
 make_internal_alias (numa_sched_setaffinity_v1)
 make_internal_alias (numa_sched_setaffinity_v2)

Define Documentation

#define syscall6   syscall

Definition at line 181 of file syscall.c.

#define WEAK   __attribute__((weak))

Definition at line 24 of file syscall.c.


Function Documentation

__asm__ ( ".symver  numa_sched_setaffinity_v1,
numa_sched_setaffinity @libnuma_1.1"   
)
__asm__ ( ".symver  numa_sched_setaffinity_v2,
numa_sched_setaffinity @@libnuma_1.2"   
)
__asm__ ( ".symver  numa_sched_getaffinity_v1,
numa_sched_getaffinity @libnuma_1.1"   
)
__asm__ ( ".symver  numa_sched_getaffinity_v2,
numa_sched_getaffinity @@libnuma_1.2"   
)
long WEAK get_mempolicy ( int *  policy,
const unsigned long *  nmask,
unsigned long  maxnode,
void *  addr,
int  flags 
)

Definition at line 184 of file syscall.c.

{
       return syscall(__NR_get_mempolicy, policy, nmask,
                                   maxnode, addr, flags);
}

Here is the caller graph for this function:

long WEAK mbind ( void *  start,
unsigned long  len,
int  mode,
const unsigned long *  nmask,
unsigned long  maxnode,
unsigned  flags 
)

Definition at line 191 of file syscall.c.

{
       return syscall6(__NR_mbind, (long)start, len, mode, (long)nmask,
                            maxnode, flags);
}

Here is the caller graph for this function:

long WEAK migrate_pages ( int  pid,
unsigned long  maxnode,
const unsigned long *  frommask,
const unsigned long *  tomask 
)

Definition at line 206 of file syscall.c.

{
       return syscall(__NR_migrate_pages, pid, maxnode, frommask, tomask);
}

Here is the caller graph for this function:

long WEAK move_pages ( int  pid,
unsigned long  count,
void **  pages,
const int *  nodes,
int *  status,
int  flags 
)

Definition at line 212 of file syscall.c.

{
       return syscall(__NR_move_pages, pid, count, pages, nodes, status, flags);
}

Here is the caller graph for this function:

int numa_sched_getaffinity_v1 ( pid_t  pid,
unsigned  len,
const unsigned long *  mask 
)

Definition at line 232 of file syscall.c.

{
       return syscall(__NR_sched_getaffinity,pid,len,mask);

}
int numa_sched_getaffinity_v2 ( pid_t  pid,
struct bitmask mask 
)

Definition at line 239 of file syscall.c.

{
       /* len is length in bytes */
       return syscall(__NR_sched_getaffinity, pid, numa_bitmask_nbytes(mask),
                                                        mask->maskp);
       /* sched_getaffinity returns sizeof(cpumask_t) */

}

Here is the call graph for this function:

int numa_sched_setaffinity_v1 ( pid_t  pid,
unsigned  len,
const unsigned long *  mask 
)

Definition at line 219 of file syscall.c.

{
       return syscall(__NR_sched_setaffinity,pid,len,mask);
}

Here is the caller graph for this function:

int numa_sched_setaffinity_v2 ( pid_t  pid,
struct bitmask mask 
)

Definition at line 225 of file syscall.c.

{
       return syscall(__NR_sched_setaffinity, pid, numa_bitmask_nbytes(mask),
                                                        mask->maskp);
}

Here is the call graph for this function:

long WEAK set_mempolicy ( int  mode,
const unsigned long *  nmask,
unsigned long  maxnode 
)

Definition at line 198 of file syscall.c.

{
       long i;
       i = syscall(__NR_set_mempolicy,mode,nmask,maxnode);
       return i;
}

Here is the caller graph for this function: