Lines Matching defs:provider

231 static dtrace_provider_t *dtrace_provider;	/* provider list */
232 static dtrace_meta_t *dtrace_meta_pid; /* user-land meta provider */
268 * (2) dtrace_provider_lock is required when manipulating provider state, or
269 * when provider state must be held constant.
271 * (3) dtrace_meta_lock is required when manipulating meta provider state, or
272 * when meta provider state must be held constant.
289 static kmutex_t dtrace_provider_lock; /* provider state lock */
290 static kmutex_t dtrace_meta_lock; /* meta-provider state lock */
295 * These are the variables relating to DTrace as a provider (that is, the
296 * provider of the BEGIN, END, and ERROR probes).
5564 * print the provider name, module name, function name and name of
5845 * is the function called by the provider to fire a probe -- from which all
5947 * If dtrace itself is the provider of this probe,
5959 * We're not currently active. If our provider isn't
5960 * the dtrace pseudo provider, we're not interested.
5984 * of this probe, call the provider's dtps_usermode()
7221 * Register the calling provider with the DTrace framework. This should
7228 dtrace_provider_t *provider;
7231 cmn_err(CE_WARN, "failed to register provider '%s': invalid "
7237 cmn_err(CE_WARN, "failed to register provider '%s': invalid "
7238 "provider name", name);
7246 cmn_err(CE_WARN, "failed to register provider '%s': invalid "
7247 "provider ops", name);
7256 cmn_err(CE_WARN, "failed to register provider '%s': invalid "
7257 "provider attributes", name);
7262 cmn_err(CE_WARN, "failed to register provider '%s': invalid "
7270 cmn_err(CE_WARN, "failed to register provider '%s': need "
7275 provider = kmem_zalloc(sizeof (dtrace_provider_t), KM_SLEEP);
7276 provider->dtpv_name = kmem_alloc(strlen(name) + 1, KM_SLEEP);
7277 (void) strcpy(provider->dtpv_name, name);
7279 provider->dtpv_attr = *pap;
7280 provider->dtpv_priv.dtpp_flags = priv;
7282 provider->dtpv_priv.dtpp_uid = crgetuid(cr);
7283 provider->dtpv_priv.dtpp_zoneid = crgetzoneid(cr);
7285 provider->dtpv_pops = *pops;
7289 provider->dtpv_pops.dtps_provide =
7295 provider->dtpv_pops.dtps_provide_module =
7301 provider->dtpv_pops.dtps_suspend =
7303 provider->dtpv_pops.dtps_resume =
7307 provider->dtpv_arg = arg;
7308 *idp = (dtrace_provider_id_t)provider;
7316 * We make sure that the DTrace provider is at the head of
7317 * the provider chain.
7319 provider->dtpv_next = dtrace_provider;
7320 dtrace_provider = provider;
7328 * If there is at least one provider registered, we'll add this
7329 * provider after the first provider.
7332 provider->dtpv_next = dtrace_provider->dtpv_next;
7333 dtrace_provider->dtpv_next = provider;
7335 dtrace_provider = provider;
7339 dtrace_enabling_provide(provider);
7360 * Unregister the specified provider from the DTrace framework. This should
7374 * If DTrace itself is the provider, we're called with locks
7387 * There's another provider here; return failure.
7400 * provider has already been explicitly invalidated.
7414 * Attempt to destroy the probes associated with this provider.
7427 * We have at least one ECB; we can't remove this provider.
7438 * All of the probes for this provider are disabled; we can safely
7464 * The provider's probes have been removed from the hash chains and
7494 "dtrace provider %p\n", (void *)id);
7513 * Invalidate the specified provider. All subsequent probe lookups for the
7514 * specified provider will fail, but its probes will not be removed.
7542 * provider.)
7548 * Remove all the unenabled probes for the given provider. This function is
7549 * not unlike dtrace_unregister(), except that it doesn't remove the provider
7560 * Make sure this isn't the dtrace provider itself.
7569 * Attempt to destroy the probes associated with this provider.
7620 dtrace_provider_t *provider = (dtrace_provider_t *)prov;
7623 if (provider == dtrace_provider) {
7640 probe->dtpr_provider = provider;
7685 if (provider != dtrace_provider)
7711 * Look up a probe based on provider and one or more of module name, function
7780 * specfied provider. If the specified description is NULL, the provider will
7783 * the specified description is non-NULL, the provider is given the
7786 * probes.) If the provider is NULL, the operations will be applied to all
7787 * providers; if the provider is non-NULL the operations will only be applied
7788 * to the specified provider. The dtrace_provider_lock must be held, and the
7789 * dtrace_lock must _not_ be held -- the provider's dtps_provide() operation
7940 dof_provider_t *provider;
7952 provider = (dof_provider_t *)(uintptr_t)(daddr + sec->dofs_offset);
7954 provider->dofpv_strtab * dof->dofh_secsize);
7956 provider->dofpv_probes * dof->dofh_secsize);
7958 provider->dofpv_prargs * dof->dofh_secsize);
7960 provider->dofpv_proffs * dof->dofh_secsize);
7971 provider->dofpv_prenoffs != DOF_SECT_NONE) {
7973 provider->dofpv_prenoffs * dof->dofh_secsize);
7980 * Create the provider.
7982 dtrace_dofprov2hprov(&dhpv, provider, strtab);
8054 dof_provider_t *provider;
8060 provider = (dof_provider_t *)(uintptr_t)(daddr + sec->dofs_offset);
8062 provider->dofpv_strtab * dof->dofh_secsize);
8067 * Create the provider.
8069 dtrace_dofprov2hprov(&dhpv, provider, strtab);
8117 cmn_err(CE_WARN, "failed to register meta-provider: "
8144 "user-land meta-provider exists", name);
8155 * off to the new meta provider now.
8193 "dtrace meta-provider %p\n", (void *)old);
10292 * If the provider shows more leg than the consumer is old
10312 * If the provider shows us kernel innards and the user
11238 * If a provider failed to enable a probe then get out and
11641 dtrace_dof_error(dof, "corrupt probe provider");
13798 * Look for a helper provider with the right generation. We
13817 * Move the last helper provider into this slot.
13826 * If we have a meta provider, remove this helper provider.
13948 * there aren't isn't a meta provider registered to deal with
13949 * these provider descriptions, we need to postpone creating
13969 * helper provider description, pass that off to the
13970 * meta provider.
13979 * Otherwise, just pass all the helper provider descriptions
13980 * off to the meta provider.
14082 dof_provider_t *provider;
14098 * The section needs to be large enough to contain the DOF provider
14105 dtrace_dof_error(dof, "provider section too small");
14109 provider = (dof_provider_t *)(uintptr_t)(daddr + sec->dofs_offset);
14110 str_sec = dtrace_dof_sect(dof, DOF_SECT_STRTAB, provider->dofpv_strtab);
14111 prb_sec = dtrace_dof_sect(dof, DOF_SECT_PROBES, provider->dofpv_probes);
14112 arg_sec = dtrace_dof_sect(dof, DOF_SECT_PRARGS, provider->dofpv_prargs);
14113 off_sec = dtrace_dof_sect(dof, DOF_SECT_PROFFS, provider->dofpv_proffs);
14122 provider->dofpv_prenoffs != DOF_SECT_NONE &&
14124 provider->dofpv_prenoffs)) == NULL)
14129 if (provider->dofpv_name >= str_sec->dofs_size ||
14130 strlen(strtab + provider->dofpv_name) >= DTRACE_PROVNAMELEN) {
14131 dtrace_dof_error(dof, "invalid provider name");
14668 * (It's normally up to the provider to make sure that
14973 * Before we register ourselves as a provider to our own framework,
14975 * not true if we were loaded as a dependency of a DTrace provider.
14977 * pseudo provider.
16070 * If there were ECBs on this state, the provider should