Lines Matching defs:sh_p

473 ph_lock_sh(const td_synchandle_t *sh_p, td_err_e *err)
475 if (sh_p == NULL || sh_p->sh_unique == NULL) {
479 return (ph_lock_ta(sh_p->sh_ta_p, err));
702 __td_ta_map_addr2sync(td_thragent_t *ta_p, psaddr_t addr, td_synchandle_t *sh_p)
708 if (sh_p == NULL)
730 sh_p->sh_ta_p = (td_thragent_t *)ta_p;
731 sh_p->sh_unique = addr;
2350 lowner_cb(const td_synchandle_t *sh_p, void *arg)
2359 if (ps_pdread(sh_p->sh_ta_p->ph_p, sh_p->sh_unique,
2362 if (ps_pdread(sh_p->sh_ta_p->ph_p, sh_p->sh_unique,
2368 return ((ocb->owner_cb)(sh_p, ocb->owner_cb_arg));
2372 return ((ocb->owner_cb)(sh_p, ocb->owner_cb_arg));
2410 __td_thr_sleepinfo(const td_thrhandle_t *th_p, td_synchandle_t *sh_p)
2416 if (sh_p == NULL)
2445 sh_p->sh_ta_p = NULL;
2446 sh_p->sh_unique = NULL;
2450 sh_p->sh_ta_p = th_p->th_ta_p;
2451 sh_p->sh_unique = (psaddr_t)wchan;
2473 sync_get_info_common(const td_synchandle_t *sh_p, struct ps_prochandle *ph_p,
2484 if (ps_pdread(ph_p, sh_p->sh_unique,
2487 if (ps_pdread(ph_p, sh_p->sh_unique, &generic_so.condition,
2494 if (trunc && ps_pdread(ph_p, sh_p->sh_unique,
2512 si_p->si_owner.th_ta_p = sh_p->sh_ta_p;
2528 if (trunc && ps_pdread(ph_p, sh_p->sh_unique,
2546 if (trunc && ps_pdread(ph_p, sh_p->sh_unique,
2558 si_p->si_owner.th_ta_p = sh_p->sh_ta_p;
2577 si_p->si_ta_p = sh_p->sh_ta_p;
2578 si_p->si_sv_addr = sh_p->sh_unique;
2588 __td_sync_get_info(const td_synchandle_t *sh_p, td_syncinfo_t *si_p)
2596 if ((ph_p = ph_lock_sh(sh_p, &return_val)) == NULL)
2599 ph_unlock(sh_p->sh_ta_p);
2603 return_val = sync_get_info_common(sh_p, ph_p, si_p);
2606 ph_unlock(sh_p->sh_ta_p);
2670 __td_sync_get_stats(const td_synchandle_t *sh_p, td_syncstats_t *ss_p)
2683 if ((ph_p = ph_lock_sh(sh_p, &return_val)) == NULL)
2685 ta_p = sh_p->sh_ta_p;
2691 if ((return_val = sync_get_info_common(sh_p, ph_p, &ss_p->ss_info))
2697 ss_p->ss_info.si_ta_p = sh_p->sh_ta_p;
2698 ss_p->ss_info.si_sv_addr = sh_p->sh_unique;
2741 sh_p->sh_unique, &sync_stats);
2869 __td_sync_setstate(const td_synchandle_t *sh_p, long lvalue)
2878 if ((ph_p = ph_lock_sh(sh_p, &return_val)) == NULL)
2881 ph_unlock(sh_p->sh_ta_p);
2890 if (ps_pdread(ph_p, sh_p->sh_unique, &generic_so,
2893 if (ps_pdread(ph_p, sh_p->sh_unique, &generic_so.condition,
2896 ph_unlock(sh_p->sh_ta_p);
2907 if (trunc && ps_pdread(ph_p, sh_p->sh_unique,
2913 if (ps_pdwrite(ph_p, sh_p->sh_unique, &generic_so.lock,
2918 if (trunc && ps_pdread(ph_p, sh_p->sh_unique,
2925 if (ps_pdwrite(ph_p, sh_p->sh_unique, &generic_so.semaphore,
2934 if (trunc && ps_pdread(ph_p, sh_p->sh_unique,
2945 if (ps_pdwrite(ph_p, sh_p->sh_unique, &generic_so.rwlock,
2956 ph_unlock(sh_p->sh_ta_p);
3018 __td_sync_waiters(const td_synchandle_t *sh_p, td_thr_iter_f *cb, void *cb_data)
3024 if ((ph_p = ph_lock_sh(sh_p, &return_val)) == NULL)
3027 (psaddr_t)&((mutex_t *)sh_p->sh_unique)->mutex_magic,
3029 ph_unlock(sh_p->sh_ta_p);
3032 ph_unlock(sh_p->sh_ta_p);
3045 wcb.sync_obj_addr = sh_p->sh_unique;
3048 return_val = __td_ta_thr_iter(sh_p->sh_ta_p, waiters_cb, &wcb,