Date: Sat, 24 May 2014 18:01:44 +0000 (UTC) From: Dmitry Chagin <dchagin@FreeBSD.org> To: src-committers@freebsd.org, svn-src-user@freebsd.org Subject: svn commit: r266623 - in user/dchagin/lemul/sys: amd64/linux amd64/linux32 compat/linux i386/linux Message-ID: <201405241801.s4OI1im6024807@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: dchagin Date: Sat May 24 18:01:44 2014 New Revision: 266623 URL: http://svnweb.freebsd.org/changeset/base/266623 Log: To reduce code duplication move debug macros to the MI header. Modified: user/dchagin/lemul/sys/amd64/linux/linux.h user/dchagin/lemul/sys/amd64/linux32/linux.h user/dchagin/lemul/sys/compat/linux/linux_util.h user/dchagin/lemul/sys/i386/linux/linux.h Modified: user/dchagin/lemul/sys/amd64/linux/linux.h ============================================================================== --- user/dchagin/lemul/sys/amd64/linux/linux.h Sat May 24 17:58:00 2014 (r266622) +++ user/dchagin/lemul/sys/amd64/linux/linux.h Sat May 24 18:01:44 2014 (r266623) @@ -39,8 +39,6 @@ */ extern u_char linux_debug_map[]; #define ldebug(name) isclr(linux_debug_map, LINUX_SYS_linux_ ## name) -#define ARGS(nm, fmt) "linux(%ld): "#nm"("fmt")\n", (long)td->td_proc->p_pid -#define LMSG(fmt) "linux(%ld): "fmt"\n", (long)td->td_proc->p_pid #define LINUX_DTRACE linuxulator #ifdef MALLOC_DECLARE Modified: user/dchagin/lemul/sys/amd64/linux32/linux.h ============================================================================== --- user/dchagin/lemul/sys/amd64/linux32/linux.h Sat May 24 17:58:00 2014 (r266622) +++ user/dchagin/lemul/sys/amd64/linux32/linux.h Sat May 24 18:01:44 2014 (r266623) @@ -40,10 +40,6 @@ */ extern u_char linux_debug_map[]; #define ldebug(name) isclr(linux_debug_map, LINUX_SYS_linux_ ## name) -#define ARGS(nm, fmt) "linux(%ld (%ld)): "#nm"("fmt")\n", \ - (long)td->td_proc->p_pid, (long)td->td_tid -#define LMSG(fmt) "linux(%ld (%ld)): "fmt"\n", \ - (long)td->td_proc->p_pid, (long)td->td_tid #define LINUX_DTRACE linuxulator32 #ifdef MALLOC_DECLARE Modified: user/dchagin/lemul/sys/compat/linux/linux_util.h ============================================================================== --- user/dchagin/lemul/sys/compat/linux/linux_util.h Sat May 24 17:58:00 2014 (r266622) +++ user/dchagin/lemul/sys/compat/linux/linux_util.h Sat May 24 18:01:44 2014 (r266623) @@ -89,6 +89,11 @@ linux_ ## s(struct thread *td, struct li } \ struct __hack +#define ARGS(nm, fmt) "linux(%zd (%zd)): "#nm"("fmt")\n", \ + td->td_proc->p_pid, td->td_tid +#define LMSG(fmt) "linux(%zd (%zd)): "fmt"\n", \ + td->td_proc->p_pid, td->td_tid + void linux_msg(const struct thread *td, const char *fmt, ...) __printflike(2, 3); Modified: user/dchagin/lemul/sys/i386/linux/linux.h ============================================================================== --- user/dchagin/lemul/sys/i386/linux/linux.h Sat May 24 17:58:00 2014 (r266622) +++ user/dchagin/lemul/sys/i386/linux/linux.h Sat May 24 18:01:44 2014 (r266623) @@ -40,10 +40,6 @@ */ extern u_char linux_debug_map[]; #define ldebug(name) isclr(linux_debug_map, LINUX_SYS_linux_ ## name) -#define ARGS(nm, fmt) "linux(%ld (%ld)): "#nm"("fmt")\n", \ - (long)td->td_proc->p_pid, (long)td->td_tid -#define LMSG(fmt) "linux(%ld (%ld)): "fmt"\n", \ - (long)td->td_proc->p_pid, (long)td->td_tid #define LINUX_DTRACE linuxulator #ifdef MALLOC_DECLARE
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201405241801.s4OI1im6024807>