typedef struct Probe Probe;
struct Probe {
/* probe386.s knows offsets of these */
void (*entry)(Probe *);
void (*exit)(Probe *);
void *func;
void *saveret;
u32int *argp;
u32int rval;
u32int orig[5];
u32int probe[5];
// u32int exitcode[128];
u32int entrycode[128];
/* rest if devprobe */
Probe *next;
char name[16];
int enabled;
uvlong ticks;
u32int arg0;
};
/* probe386.s */
extern void pentrytmpl(void);
extern void pexittmpl(void);
/* arch dependent probe.c */
extern void freeprobe(Probe *);
extern Probe *mkprobe(void *, void (*)(Probe *), void (*)(Probe *));
extern void probeuninstall(Probe *);
extern void probeinstall(Probe *);
|