Date: Sun, 22 Aug 2010 11:41:07 +0000 (UTC) From: Rui Paulo <rpaulo@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r211618 - head/sys/cddl/contrib/opensolaris/uts/common/sys Message-ID: <201008221141.o7MBf7ss002771@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: rpaulo Date: Sun Aug 22 11:41:06 2010 New Revision: 211618 URL: http://svn.freebsd.org/changeset/base/211618 Log: Port this to FreeBSD. We miss some suword functions, so we use copyout. Sponsored by: The FreeBSD Foundation > Description of fields to fill in above: 76 columns --| > PR: If a GNATS PR is affected by the change. > Submitted by: If someone else sent in the change. > Reviewed by: If someone else reviewed your modification. > Approved by: If you needed approval for this commit. > Obtained from: If the change is from a third party. > MFC after: N [day[s]|week[s]|month[s]]. Request a reminder email. > Security: Vulnerability reference (one per line) or description. > Empty fields above will be automatically removed. M sys/fasttrap_impl.h Modified: head/sys/cddl/contrib/opensolaris/uts/common/sys/fasttrap_impl.h Modified: head/sys/cddl/contrib/opensolaris/uts/common/sys/fasttrap_impl.h ============================================================================== --- head/sys/cddl/contrib/opensolaris/uts/common/sys/fasttrap_impl.h Sun Aug 22 11:30:49 2010 (r211617) +++ head/sys/cddl/contrib/opensolaris/uts/common/sys/fasttrap_impl.h Sun Aug 22 11:41:06 2010 (r211618) @@ -158,10 +158,16 @@ typedef struct fasttrap_hash { */ #define fasttrap_copyout copyout #define fasttrap_fuword32 fuword32 -#define fasttrap_suword32 suword32 +#define fasttrap_suword32(_k, _u) copyout((_k), (_u), sizeof(uint32_t)) +#define fasttrap_suword64(_k, _u) copyout((_k), (_u), sizeof(uint64_t)) -#define fasttrap_fulword fulword -#define fasttrap_sulword sulword +#ifdef __amd64__ +#define fasttrap_fulword fuword64 +#define fasttrap_sulword fasttrap_suword64 +#else +#define fasttrap_fulword fuword32 +#define fasttrap_sulword fasttrap_suword32 +#endif extern void fasttrap_sigtrap(proc_t *, kthread_t *, uintptr_t); @@ -179,8 +185,9 @@ extern int fasttrap_tracepoint_init(proc extern int fasttrap_tracepoint_install(proc_t *, fasttrap_tracepoint_t *); extern int fasttrap_tracepoint_remove(proc_t *, fasttrap_tracepoint_t *); -extern int fasttrap_pid_probe(struct regs *); -extern int fasttrap_return_probe(struct regs *); +struct reg; +extern int fasttrap_pid_probe(struct reg *); +extern int fasttrap_return_probe(struct reg *); extern uint64_t fasttrap_pid_getarg(void *, dtrace_id_t, void *, int, int); extern uint64_t fasttrap_usdt_getarg(void *, dtrace_id_t, void *, int, int);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201008221141.o7MBf7ss002771>