[PATCH] printk-rb: fix test module macro usage

John Ogness
2019-08-19T21:30:15Z

DECLARE_PRINTKRB() now requires a wait queue argument, used
by the blocking reader interface.

Signed-off-by: John Ogness <john.ogness@linutronix.de>
---
For RFCv4 the macro prototype changed. The fixup for the
test module didn't make it into the series.

kernel/printk/test_prb.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/kernel/printk/test_prb.c b/kernel/printk/test_prb.c
index 0157bbdf051f..49bcf831af7e 100644
--- a/kernel/printk/test_prb.c
+++ b/kernel/printk/test_prb.c
@@ -6,8 +6,11 @@
#include <linux/delay.h>
#include <linux/random.h>
#include <linux/slab.h>
+#include <linux/wait.h>
#include "ringbuffer.h"

+DECLARE_WAIT_QUEUE_HEAD(test_wait);
+
/*
* This is a test module that starts "num_online_cpus() - 1" writer threads
* and 1 reader thread. The writer threads each write strings of varying
@@ -63,7 +66,7 @@ static void dump_rb(struct printk_ringbuffer *rb)
trace_printk("END full dump\n");
}

-DECLARE_PRINTKRB(test_rb, 5, 7);
+DECLARE_PRINTKRB(test_rb, 5, 7, &test_wait);

static int prbtest_writer(void *data)
{
--
2.20.1