diff mbox series

[1/3] lib/test_printf: use KSTM_MODULE_GLOBALS macro

Message ID 20210210051814.845713-2-timur@kernel.org (mailing list archive)
State New, archived
Headers show
Series add support for never printing hashed addresses | expand

Commit Message

Timur Tabi Feb. 10, 2021, 5:18 a.m. UTC
Instead of defining the total/failed test counters manually,
test_printf should use the kselftest macro created for this
purpose.

Signed-off-by: Timur Tabi <ttabi@nvidia.com>
---
 lib/test_printf.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Timur Tabi Feb. 10, 2021, 5:21 a.m. UTC | #1
On 2/9/21 11:18 PM, Timur Tabi wrote:
> Instead of defining the total/failed test counters manually,
> test_printf should use the kselftest macro created for this
> purpose.
> 
> Signed-off-by: Timur Tabi<ttabi@nvidia.com>

Ugh, I really need to stop sending patches late at night.  This is again 
the wrong email address.

I'm sure I'll need to post another version of these patches, so I'll 
just fix it then.
Petr Mladek Feb. 10, 2021, 1:14 p.m. UTC | #2
On Tue 2021-02-09 23:18:12, Timur Tabi wrote:
> Instead of defining the total/failed test counters manually,
> test_printf should use the kselftest macro created for this
> purpose.
> 
> Signed-off-by: Timur Tabi <ttabi@nvidia.com>

Reviewed-by: Petr Mladek <pmladek@suse.com>

Best Regards,
Petr
diff mbox series

Patch

diff --git a/lib/test_printf.c b/lib/test_printf.c
index 7ac87f18a10f..ad2bcfa8caa1 100644
--- a/lib/test_printf.c
+++ b/lib/test_printf.c
@@ -30,8 +30,8 @@ 
 #define PAD_SIZE 16
 #define FILL_CHAR '$'
 
-static unsigned total_tests __initdata;
-static unsigned failed_tests __initdata;
+KSTM_MODULE_GLOBALS();
+
 static char *test_buffer __initdata;
 static char *alloced_buffer __initdata;