[RFC PATCH v4 3/9] printk-rb: fix missing includes/exports

John Ogness
2019-08-07T22:27:15Z

Add missing includes and exports.

Signed-off-by: John Ogness <john.ogness@linutronix.de>
---
kernel/printk/dataring.c | 1 +
kernel/printk/numlist.c | 1 +
kernel/printk/ringbuffer.c | 4 ++++
3 files changed, 6 insertions(+)

diff --git a/kernel/printk/dataring.c b/kernel/printk/dataring.c
index 911bac593ec1..6642e085a05d 100644
--- a/kernel/printk/dataring.c
+++ b/kernel/printk/dataring.c
@@ -1,5 +1,6 @@
// SPDX-License-Identifier: GPL-2.0

+#include <linux/kernel.h>
#include "dataring.h"

/**
diff --git a/kernel/printk/numlist.c b/kernel/printk/numlist.c
index df3f89e7f7fd..d5e224dafc0c 100644
--- a/kernel/printk/numlist.c
+++ b/kernel/printk/numlist.c
@@ -1,5 +1,6 @@
// SPDX-License-Identifier: GPL-2.0

+#include <linux/kernel.h>
#include <linux/sched.h>
#include "numlist.h"

diff --git a/kernel/printk/ringbuffer.c b/kernel/printk/ringbuffer.c
index 59bf59aba3de..b9fc13597b10 100644
--- a/kernel/printk/ringbuffer.c
+++ b/kernel/printk/ringbuffer.c
@@ -1,5 +1,6 @@
// SPDX-License-Identifier: GPL-2.0

+#include <linux/kernel.h>
#include <linux/irqflags.h>
#include <linux/string.h>
#include <linux/err.h>
@@ -222,6 +223,7 @@ struct nl_node *prb_desc_node(unsigned long id, void *arg)

return &d->list;
}
+EXPORT_SYMBOL(prb_desc_node);

/**
* prb_desc_busy() - Numbered list callback to report if a node is busy.
@@ -262,6 +264,7 @@ bool prb_desc_busy(unsigned long id, void *arg)
/* hC: */
return (id == atomic_long_read(&d->id));
}
+EXPORT_SYMBOL(prb_desc_busy);

/**
* prb_getdesc() - Data ringbuffer callback to lookup a descriptor from an ID.
@@ -296,6 +299,7 @@ struct dr_desc *prb_getdesc(unsigned long id, void *arg)
/* iB: */
return &d->desc;
}
+EXPORT_SYMBOL(prb_getdesc);

/**
* assign_desc() - Assign a descriptor to the caller.
--
2.20.1