Home
last modified time | relevance | path

Searched refs:attr (Results 1 – 23 of 23) sorted by relevance

/bionic/libc/bionic/
Dpthread_attr.cpp35 int pthread_attr_init(pthread_attr_t* attr) { in pthread_attr_init() argument
36 attr->flags = 0; in pthread_attr_init()
37 attr->stack_base = NULL; in pthread_attr_init()
38 attr->stack_size = DEFAULT_STACK_SIZE; in pthread_attr_init()
39 attr->guard_size = PAGE_SIZE; in pthread_attr_init()
40 attr->sched_policy = SCHED_NORMAL; in pthread_attr_init()
41 attr->sched_priority = 0; in pthread_attr_init()
45 int pthread_attr_destroy(pthread_attr_t* attr) { in pthread_attr_destroy() argument
46 memset(attr, 0x42, sizeof(pthread_attr_t)); in pthread_attr_destroy()
50 int pthread_attr_setdetachstate(pthread_attr_t* attr, int state) { in pthread_attr_setdetachstate() argument
[all …]
Dpthread_create.cpp101 if (thread->attr.sched_policy != SCHED_NORMAL) { in _init_thread()
103 param.sched_priority = thread->attr.sched_priority; in _init_thread()
104 if (sched_setscheduler(thread->tid, thread->attr.sched_policy, &param) == -1) { in _init_thread()
143 int pthread_create(pthread_t* thread_out, pthread_attr_t const* attr, in pthread_create() argument
161 if (attr == NULL) { in pthread_create()
162 pthread_attr_init(&thread->attr); in pthread_create()
164 thread->attr = *attr; in pthread_create()
165 attr = NULL; // Prevent misuse below. in pthread_create()
169 size_t stack_size = (thread->attr.stack_size + (PAGE_SIZE-1)) & ~(PAGE_SIZE-1); in pthread_create()
171 if (thread->attr.stack_base == NULL) { in pthread_create()
[all …]
Dpthread-rwlocks.c64 int pthread_rwlockattr_init(pthread_rwlockattr_t *attr) in pthread_rwlockattr_init() argument
66 if (!attr) in pthread_rwlockattr_init()
69 *attr = PTHREAD_PROCESS_PRIVATE; in pthread_rwlockattr_init()
73 int pthread_rwlockattr_destroy(pthread_rwlockattr_t *attr) in pthread_rwlockattr_destroy() argument
75 if (!attr) in pthread_rwlockattr_destroy()
78 *attr = -1; in pthread_rwlockattr_destroy()
82 int pthread_rwlockattr_setpshared(pthread_rwlockattr_t *attr, int pshared) in pthread_rwlockattr_setpshared() argument
84 if (!attr) in pthread_rwlockattr_setpshared()
90 *attr = pshared; in pthread_rwlockattr_setpshared()
97 int pthread_rwlockattr_getpshared(pthread_rwlockattr_t *attr, int *pshared) in pthread_rwlockattr_getpshared() argument
[all …]
Dpthread.c67 *p_stack_size = thread->attr.stack_size; in __get_stack_base()
68 return thread->attr.stack_base; in __get_stack_base()
100 void* stack_base = thread->attr.stack_base; in pthread_exit()
101 int stack_size = thread->attr.stack_size; in pthread_exit()
102 int user_stack = (thread->attr.flags & PTHREAD_ATTR_FLAG_USER_STACK) != 0; in pthread_exit()
121 if (thread->attr.flags & PTHREAD_ATTR_FLAG_DETACHED) { in pthread_exit()
128 thread->attr.stack_base = NULL; in pthread_exit()
129 thread->attr.stack_size = 0; in pthread_exit()
326 int pthread_mutexattr_init(pthread_mutexattr_t *attr) in pthread_mutexattr_init() argument
328 if (attr) { in pthread_mutexattr_init()
[all …]
Dpthread_detach.cpp39 if (thread->attr.flags & PTHREAD_ATTR_FLAG_DETACHED) { in pthread_detach()
47 thread->attr.flags |= PTHREAD_ATTR_FLAG_DETACHED; in pthread_detach()
Dpthread-atfork.c77 pthread_mutexattr_t attr; in __bionic_atfork_run_child() local
88 pthread_mutexattr_init(&attr); in __bionic_atfork_run_child()
89 pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE); in __bionic_atfork_run_child()
90 pthread_mutex_init(&handler_mutex, &attr); in __bionic_atfork_run_child()
Dlibc_init_common.cpp87 pthread_attr_init(&thread.attr); in __libc_init_tls()
88 pthread_attr_setstack(&thread.attr, (void*) stack_bottom, stack_size); in __libc_init_tls()
Dpthread_join.cpp43 if (thread->attr.flags & PTHREAD_ATTR_FLAG_DETACHED) { in pthread_join()
Dpthread_internal.h40 pthread_attr_t attr; member
/bionic/libc/include/
Dpthread.h114 int pthread_attr_init(pthread_attr_t * attr);
115 int pthread_attr_destroy(pthread_attr_t * attr);
117 int pthread_attr_setdetachstate(pthread_attr_t * attr, int state);
118 int pthread_attr_getdetachstate(pthread_attr_t const * attr, int * state);
120 int pthread_attr_setschedpolicy(pthread_attr_t * attr, int policy);
121 int pthread_attr_getschedpolicy(pthread_attr_t const * attr, int * policy);
123 int pthread_attr_setschedparam(pthread_attr_t * attr, struct sched_param const * param);
124 int pthread_attr_getschedparam(pthread_attr_t const * attr, struct sched_param * param);
126 int pthread_attr_setstacksize(pthread_attr_t * attr, size_t stack_size);
127 int pthread_attr_getstacksize(pthread_attr_t const * attr, size_t * stack_size);
[all …]
/bionic/libc/kernel/common/linux/
Dsysfs.h36 #define __ATTR(_name,_mode,_show,_store) { .attr = {.name = __stringify(_name), .mode = _mode, .o…
37 #define __ATTR_RO(_name) { .attr = { .name = __stringify(_name), .mode = 0444, .owner = THIS_MODU…
39 #define __ATTR_NULL { .attr = { .name = NULL } }
40 #define attr_name(_attr) (_attr).attr.name
44 struct attribute attr; member
50 int (*mmap)(struct kobject *, struct bin_attribute *attr,
Dsysdev.h35 struct attribute attr; member
40 …me,_mode,_show,_store) struct sysdev_class_attribute attr_##_name = { .attr = {.name = __string…
59 struct attribute attr; member
64 #define SYSDEV_ATTR(_name,_mode,_show,_store) struct sysdev_attribute attr_##_name = { .attr = {…
Ddevice.h70 struct attribute attr; member
95 struct attribute attr; member
125 struct attribute attr; member
132 struct attribute attr; member
167 struct attribute attr; member
169 ssize_t (*show)(struct device *dev, struct device_attribute *attr,
171 ssize_t (*store)(struct device *dev, struct device_attribute *attr,
Dcoda.h321 struct coda_vattr attr; member
327 struct coda_vattr attr; member
364 struct coda_vattr attr; member
374 struct coda_vattr attr; member
414 struct coda_vattr attr; member
421 struct coda_vattr attr; member
439 struct coda_vattr attr; member
Dmsdos_fs.h156 __u8 attr; member
172 __u8 attr; member
Delevator.h69 struct attribute attr; member
Dmodule.h59 struct attribute attr; member
/bionic/libc/kernel/common/linux/netfilter/
Dnfnetlink.h60 #define NFA_TYPE(attr) ((attr)->nfa_type & 0x7fff) argument
/bionic/tests/
Dpthread_test.cpp74 pthread_attr_t attr; in AssertDetached() local
75 ASSERT_EQ(0, pthread_getattr_np(t, &attr)); in AssertDetached()
77 ASSERT_EQ(0, pthread_attr_getdetachstate(&attr, &detach_state)); in AssertDetached()
78 pthread_attr_destroy(&attr); in AssertDetached()
/bionic/libc/kernel/arch-mips/asm/
Dsgiarcs.h150 unsigned char attr; member
185 unsigned char attr; member
/bionic/libc/kernel/common/linux/raid/
Dmd_k.h194 struct attribute attr; member
/bionic/libc/kernel/arch-mips/asm/pci/
Dbridge.h659 #define mkate(xaddr, xid, attr) ((xaddr) & 0x0000fffffffff000ULL) | ((xid)<<ATE_TIDSHIFT) | (at… argument
/bionic/libc/upstream-dlmalloc/
Dmalloc.c2022 pthread_mutexattr_t attr; in pthread_init_lock() local
2023 if (pthread_mutexattr_init(&attr)) return 1; in pthread_init_lock()
2025 if (pthread_mutexattr_settype(&attr, PTHREAD_MUTEX_RECURSIVE)) return 1; in pthread_init_lock()
2027 if (pthread_mutex_init(lk, &attr)) return 1; in pthread_init_lock()
2028 if (pthread_mutexattr_destroy(&attr)) return 1; in pthread_init_lock()