Lines Matching refs:dtp
36 int dt_prov_kprobe_alloc(struct dt_probe *dtp, struct dt_softc *sc,
39 int dt_prov_kprobe_dealloc(struct dt_probe *dtp, struct dt_softc *sc,
46 struct dt_probe* dtp;
120 struct dt_probe *dtp;
190 dtp = dt_dev_alloc_probe(name, KPROBE_ENTRY, &dt_prov_kprobe);
191 if (dtp == NULL)
197 kprobe_dtp->dtp = dtp;
199 dtp->dtp_addr = inst;
200 dtp->dtp_nargs = db_ctf_func_numargs(symp);
201 dt_dev_register_probe(dtp);
203 SLIST_INSERT_HEAD(&dtpf_entry[INSTTOIDX(dtp->dtp_addr)], kprobe_dtp, kprobe_next);
225 dtp = dt_dev_alloc_probe(name, KPROBE_RETURN, &dt_prov_kprobe);
226 if (dtp == NULL)
232 kprobe_dtp->dtp = dtp;
234 dtp->dtp_addr = inst;
235 dt_dev_register_probe(dtp);
236 SLIST_INSERT_HEAD(&dtpf_return[INSTTOIDX(dtp->dtp_addr)], kprobe_dtp, kprobe_next);
245 dt_prov_kprobe_alloc(struct dt_probe *dtp, struct dt_softc *sc,
252 dp = dt_pcb_alloc(dtp, sc);
257 dtp->dtp_ref++;
258 KASSERT(dtp->dtp_ref != 0);
260 if (dtp->dtp_ref == 1) {
262 db_write_bytes(dtp->dtp_addr, BKPT_SIZE, &patch);
272 dt_prov_kprobe_dealloc(struct dt_probe *dtp, struct dt_softc *sc,
279 if (strcmp(dtp->dtp_name, KPROBE_ENTRY) == 0) {
282 } else if (strcmp(dtp->dtp_name, KPROBE_RETURN) == 0) {
293 dtp->dtp_ref--;
295 if (dtp->dtp_ref == 0) {
297 db_write_bytes(dtp->dtp_addr, size, &patch);
308 struct dt_probe *dtp;
328 dtp = kprobe_dtp->dtp;
330 if (dtp->dtp_addr != addr)
337 if (!dtp->dtp_recording)
341 SMR_SLIST_FOREACH(dp, &dtp->dtp_pcbs, dp_pnext) {
370 dtp = kprobe_dtp->dtp;
372 if (dtp->dtp_addr != addr)
377 if (!dtp->dtp_recording)
381 SMR_SLIST_FOREACH(dp, &dtp->dtp_pcbs, dp_pnext) {
414 struct dt_probe *dtp;
420 dtp = kprobe_dtp->dtp;
421 dtp->dtp_ref++;
423 if (dtp->dtp_ref == 1) {
426 db_write_bytes(dtp->dtp_addr, BKPT_SIZE, &patch);
438 struct dt_probe *dtp;
444 dtp = kprobe_dtp->dtp;
445 dtp->dtp_ref--;
447 if (dtp->dtp_ref == 0) {
450 db_write_bytes(dtp->dtp_addr, SSF_SIZE, &patch);