Lines Matching refs:errcode

62 	int errcode;  in pt_mk_section()  local
64 errcode = pt_section_mk_status(&status, &fsize, filename); in pt_mk_section()
65 if (errcode < 0) in pt_mk_section()
91 errcode = mtx_init(&section->lock, mtx_plain); in pt_mk_section()
92 if (errcode != thrd_success) { in pt_mk_section()
98 errcode = mtx_init(&section->alock, mtx_plain); in pt_mk_section()
99 if (errcode != thrd_success) { in pt_mk_section()
122 int errcode; in pt_section_lock() local
124 errcode = mtx_lock(&section->lock); in pt_section_lock()
125 if (errcode != thrd_success) in pt_section_lock()
140 int errcode; in pt_section_unlock() local
142 errcode = mtx_unlock(&section->lock); in pt_section_unlock()
143 if (errcode != thrd_success) in pt_section_unlock()
171 int errcode; in pt_section_get() local
176 errcode = pt_section_lock(section); in pt_section_get()
177 if (errcode < 0) in pt_section_get()
178 return errcode; in pt_section_get()
194 int errcode; in pt_section_put() local
199 errcode = pt_section_lock(section); in pt_section_put()
200 if (errcode < 0) in pt_section_put()
201 return errcode; in pt_section_put()
210 errcode = pt_section_unlock(section); in pt_section_put()
211 if (errcode < 0) in pt_section_put()
212 return errcode; in pt_section_put()
228 int errcode; in pt_section_lock_attach() local
230 errcode = mtx_lock(&section->alock); in pt_section_lock_attach()
231 if (errcode != thrd_success) in pt_section_lock_attach()
246 int errcode; in pt_section_unlock_attach() local
248 errcode = mtx_unlock(&section->alock); in pt_section_unlock_attach()
249 if (errcode != thrd_success) in pt_section_unlock_attach()
261 int errcode; in pt_section_attach() local
266 errcode = pt_section_lock_attach(section); in pt_section_attach()
267 if (errcode < 0) in pt_section_attach()
268 return errcode; in pt_section_attach()
307 int errcode; in pt_section_detach() local
312 errcode = pt_section_lock_attach(section); in pt_section_detach()
313 if (errcode < 0) in pt_section_detach()
314 return errcode; in pt_section_detach()
380 int errcode; in pt_section_memsize_locked() local
394 errcode = memsize(section, &msize); in pt_section_memsize_locked()
395 if (errcode < 0) in pt_section_memsize_locked()
396 return errcode; in pt_section_memsize_locked()
398 errcode = pt_section_bcache_memsize(section, &bcsize); in pt_section_memsize_locked()
399 if (errcode < 0) in pt_section_memsize_locked()
400 return errcode; in pt_section_memsize_locked()
409 int errcode, status; in pt_section_memsize() local
411 errcode = pt_section_lock(section); in pt_section_memsize()
412 if (errcode < 0) in pt_section_memsize()
413 return errcode; in pt_section_memsize()
417 errcode = pt_section_unlock(section); in pt_section_memsize()
418 if (errcode < 0) in pt_section_memsize()
419 return errcode; in pt_section_memsize()
438 int errcode; in pt_section_alloc_bcache() local
462 errcode = pt_section_lock_attach(section); in pt_section_alloc_bcache()
463 if (errcode < 0) in pt_section_alloc_bcache()
464 return errcode; in pt_section_alloc_bcache()
466 errcode = pt_section_lock(section); in pt_section_alloc_bcache()
467 if (errcode < 0) in pt_section_alloc_bcache()
472 errcode = 0; in pt_section_alloc_bcache()
478 errcode = -pte_nomem; in pt_section_alloc_bcache()
490 errcode = pt_section_memsize_locked(section, &memsize); in pt_section_alloc_bcache()
491 if (errcode < 0) in pt_section_alloc_bcache()
494 errcode = pt_section_unlock(section); in pt_section_alloc_bcache()
495 if (errcode < 0) in pt_section_alloc_bcache()
501 errcode = pt_iscache_notify_resize(iscache, section, in pt_section_alloc_bcache()
503 if (errcode < 0) in pt_section_alloc_bcache()
516 return errcode; in pt_section_alloc_bcache()
522 int errcode, status; in pt_section_on_map_lock() local
527 errcode = pt_section_lock_attach(section); in pt_section_on_map_lock()
528 if (errcode < 0) in pt_section_on_map_lock()
529 return errcode; in pt_section_on_map_lock()
544 errcode = pt_section_unlock_attach(section); in pt_section_on_map_lock()
545 if (errcode < 0) in pt_section_on_map_lock()
546 return errcode; in pt_section_on_map_lock()
554 int errcode; in pt_section_map_share() local
559 errcode = pt_section_lock(section); in pt_section_map_share()
560 if (errcode < 0) in pt_section_map_share()
561 return errcode; in pt_section_map_share()
583 int errcode, status; in pt_section_unmap() local
588 errcode = pt_section_lock(section); in pt_section_unmap()
589 if (errcode < 0) in pt_section_unmap()
590 return errcode; in pt_section_unmap()
594 errcode = -pte_nomap; in pt_section_unmap()
602 errcode = -pte_internal; in pt_section_unmap()
611 errcode = pt_section_unlock(section); in pt_section_unmap()
612 if (errcode < 0) in pt_section_unmap()
613 return errcode; in pt_section_unmap()
619 return errcode; in pt_section_unmap()