Back to index

numactl  2.0.8~rc4
Defines | Enumerations | Functions
numaint.h File Reference
#include "bitops.h"
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Defines

#define SHM_HUGETLB   04000 /* segment will use huge TLB pages */
#define CPU_BYTES(x)   (round_up(x, BITS_PER_LONG)/8)
#define CPU_LONGS(x)   (CPU_BYTES(x) / sizeof(long))
#define make_internal_alias(x)   extern __typeof (x) x##_int __attribute((alias(#x), visibility("hidden")))
#define hidden   __attribute__((visibility("hidden")))
#define howmany(x, y)   (((x)+((y)-1))/(y))
#define bitsperlong   (8 * sizeof(unsigned long))
#define bitsperint   (8 * sizeof(unsigned int))
#define longsperbits(n)   howmany(n, bitsperlong)
#define bytesperbits(x)   ((x+7)/8)

Enumerations

enum  numa_warn {
  W_nosysfs, W_noproc, W_badmeminfo, W_nosysfs2,
  W_cpumap, W_numcpus, W_noderunmask, W_distance,
  W_memory, W_cpuparse, W_nodeparse, W_blockdev1,
  W_blockdev2, W_blockdev3, W_blockdev4, W_blockdev5,
  W_netlink1, W_netlink2, W_netlink3, W_net1,
  W_net2, W_class1, W_class2, W_pci1,
  W_pci2, W_node_parse1, W_node_parse2, W_nonode,
  W_badchar
}

Functions

int numa_sched_setaffinity_v1 (pid_t pid, unsigned len, const unsigned long *mask)
int numa_sched_getaffinity_v1 (pid_t pid, unsigned len, const unsigned long *mask)
int numa_sched_setaffinity_v1_int (pid_t pid, unsigned len, const unsigned long *mask)
int numa_sched_getaffinity_v1_int (pid_t pid, unsigned len, const unsigned long *mask)
int numa_sched_setaffinity_v2 (pid_t pid, struct bitmask *mask)
int numa_sched_getaffinity_v2 (pid_t pid, struct bitmask *mask)
int numa_sched_setaffinity_v2_int (pid_t pid, struct bitmask *mask)
int numa_sched_getaffinity_v2_int (pid_t pid, struct bitmask *mask)

Define Documentation

#define bitsperint   (8 * sizeof(unsigned int))

Definition at line 55 of file numaint.h.

#define bitsperlong   (8 * sizeof(unsigned long))

Definition at line 54 of file numaint.h.

#define bytesperbits (   x)    ((x+7)/8)

Definition at line 57 of file numaint.h.

#define CPU_BYTES (   x)    (round_up(x, BITS_PER_LONG)/8)

Definition at line 15 of file numaint.h.

#define CPU_LONGS (   x)    (CPU_BYTES(x) / sizeof(long))

Definition at line 16 of file numaint.h.

#define hidden   __attribute__((visibility("hidden")))

Definition at line 19 of file numaint.h.

#define howmany (   x,
 
)    (((x)+((y)-1))/(y))

Definition at line 53 of file numaint.h.

#define longsperbits (   n)    howmany(n, bitsperlong)

Definition at line 56 of file numaint.h.

#define make_internal_alias (   x)    extern __typeof (x) x##_int __attribute((alias(#x), visibility("hidden")))

Definition at line 18 of file numaint.h.

#define SHM_HUGETLB   04000 /* segment will use huge TLB pages */

Definition at line 13 of file numaint.h.


Enumeration Type Documentation

enum numa_warn
Enumerator:
W_nosysfs 
W_noproc 
W_badmeminfo 
W_nosysfs2 
W_cpumap 
W_numcpus 
W_noderunmask 
W_distance 
W_memory 
W_cpuparse 
W_nodeparse 
W_blockdev1 
W_blockdev2 
W_blockdev3 
W_blockdev4 
W_blockdev5 
W_netlink1 
W_netlink2 
W_netlink3 
W_net1 
W_net2 
W_class1 
W_class2 
W_pci1 
W_pci2 
W_node_parse1 
W_node_parse2 
W_nonode 
W_badchar 

Definition at line 21 of file numaint.h.


Function Documentation

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_v1_int ( pid_t  pid,
unsigned  len,
const unsigned long *  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_getaffinity_v2_int ( pid_t  pid,
struct bitmask mask 
)

Here is the caller 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_v1_int ( pid_t  pid,
unsigned  len,
const unsigned long *  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:

int numa_sched_setaffinity_v2_int ( pid_t  pid,
struct bitmask mask 
)

Here is the caller graph for this function: