Lines Matching refs:pid

173 static uint64_t			fasttrap_pid_count;	/* pid ref count */
192 #define FASTTRAP_PROVS_INDEX(pid, name) \
193 ((fasttrap_hash_str(name) + (pid)) & fasttrap_provs.fth_mask)
195 #define FASTTRAP_PROCS_INDEX(pid) ((pid) & fasttrap_procs.fth_mask)
531 * is set on the proc structure to indicate that there is a pid provider
555 * We clean up the pid provider for this process here; user-land
587 * There are no "default" pid probes.
597 pid_t pid;
602 pid = probe->ftp_pid;
606 ASSERT(probe->ftp_tps[index].fit_tp->ftt_pid == pid);
616 bucket = &fasttrap_tpoints.fth_table[FASTTRAP_TPOINTS_INDEX(pid, pc)];
636 if (tp->ftt_pid != pid || tp->ftt_pc != pc ||
727 ASSERT(new_tp->ftt_pid == pid);
771 pid_t pid;
776 pid = probe->ftp_pid;
780 ASSERT(probe->ftp_tps[index].fit_tp->ftt_pid == pid);
786 bucket = &fasttrap_tpoints.fth_table[FASTTRAP_TPOINTS_INDEX(pid, pc)];
789 if (tp->ftt_pid == pid && tp->ftt_pc == pc &&
1059 * Solaris uses its ulwp_t struct for scratch space to support the pid provider.
1310 fasttrap_proc_lookup(pid_t pid)
1315 bucket = &fasttrap_procs.fth_table[FASTTRAP_PROCS_INDEX(pid)];
1319 if (fprc->ftpc_pid == pid && fprc->ftpc_acount != 0) {
1339 new_fprc->ftpc_pid = pid;
1347 * been created for this pid while we weren't under the bucket lock.
1350 if (fprc->ftpc_pid == pid && fprc->ftpc_acount != 0) {
1384 pid_t pid = proc->ftpc_pid;
1404 bucket = &fasttrap_procs.fth_table[FASTTRAP_PROCS_INDEX(pid)];
1436 * Lookup a fasttrap-managed provider based on its name and associated pid.
1443 fasttrap_provider_lookup(pid_t pid, fasttrap_provider_type_t provider_type, const char *name,
1456 bucket = &fasttrap_provs.fth_table[FASTTRAP_PROVS_INDEX(pid, name)];
1463 if (fp->ftp_pid == pid &&
1485 if ((p = proc_find(pid)) == NULL) {
1524 new_fp->ftp_pid = pid;
1525 new_fp->ftp_proc = fasttrap_proc_lookup(pid);
1542 * been created for this pid while we weren't under the bucket lock.
1545 if (fp->ftp_pid == pid && strncmp(fp->ftp_name, name, sizeof(fp->ftp_name)) == 0 &&
1564 if (snprintf(provname, sizeof (provname), "%s%u", name, (uint_t)pid) >=
1589 pid_t pid = provider->ftp_pid;
1630 if ((p = proc_find(pid)) == NULL) {
1642 fasttrap_provider_retire(pid_t pid, const char *name, int mprov)
1650 bucket = &fasttrap_provs.fth_table[FASTTRAP_PROVS_INDEX(pid, name)];
1654 if (fp->ftp_pid == pid && strncmp(fp->ftp_name, name, sizeof(fp->ftp_name)) == 0 &&
1951 fasttrap_meta_provide(void *arg, dtrace_helper_provdesc_t *dhpv, pid_t pid)
1957 * A 32-bit unsigned integer (like a pid for example) can be
1964 "name too long to accomodate pid", dhpv->dthpv_provname);
1969 * Don't let folks spoof the true pid provider.
1979 * We also need to check the other pid provider types
2011 if ((provider = fasttrap_provider_lookup(pid, DTFTP_PROVIDER_USDT, dhpv->dthpv_provname,
2014 "process %u", dhpv->dthpv_provname, (uint_t)pid);
2237 fasttrap_meta_remove(void *arg, dtrace_helper_provdesc_t *dhpv, pid_t pid)
2246 fasttrap_provider_retire(pid, dhpv->dthpv_provname, 1);
2326 pid_t pid = probe->ftps_pid;
2332 if ((p = proc_find(pid)) == PROC_NULL || p->p_stat == SIDL) {
2366 pid_t pid = instr.ftiq_pid;
2372 if ((p = proc_find(pid)) == NULL || p->p_stat == SIDL) {