]> granicus.if.org Git - strace/commitdiff
Move xlat_verbose and xlat_format from xlat.c to defs.h
authorEugene Syromyatnikov <evgsyr@gmail.com>
Wed, 4 Apr 2018 11:28:51 +0000 (13:28 +0200)
committerDmitry V. Levin <ldv@altlinux.org>
Tue, 24 Apr 2018 00:35:27 +0000 (00:35 +0000)
As it will be used elsewhere.

* xlat.c (xlat_verbose, xlat_format): Move...
* defs.h: ...here.

defs.h
xlat.c

diff --git a/defs.h b/defs.h
index 7263a8399b1cc60cb7f31b37d7101adff7418414..b2d683db5d4d5a201d58d3ab4d9668b5a7c435ac 100644 (file)
--- a/defs.h
+++ b/defs.h
@@ -595,6 +595,9 @@ extern void printaddr(kernel_ulong_t addr);
 #define XLAT_STYLE_FORMAT_SHIFT   2
 #define XLAT_STYLE_FORMAT_MASK    (3 << XLAT_STYLE_FORMAT_SHIFT)
 
+#define xlat_verbose(style_) ((style_) & XLAT_STYLE_VERBOSITY_MASK)
+#define xlat_format(style_)  ((style_) & XLAT_STYLE_FORMAT_MASK)
+
 enum xlat_style {
        /**
         * Special value that is used for passing to *print{xval,flags}*_ex
diff --git a/xlat.c b/xlat.c
index 247bff82c43710aa6dc830589aaba3dc492e797a..2156b178ac46e4116c78bc6b4c5eccc0c316b047 100644 (file)
--- a/xlat.c
+++ b/xlat.c
@@ -33,9 +33,6 @@
 #include "xstring.h"
 #include <stdarg.h>
 
-#define xlat_verbose(style_) ((style_) & XLAT_STYLE_VERBOSITY_MASK)
-#define xlat_format(style_)  ((style_) & XLAT_STYLE_FORMAT_MASK)
-
 static inline enum xlat_style
 get_xlat_style(enum xlat_style style)
 {