aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAnton Vorontsov <anton.vorontsov@linaro.org>2012-07-17 14:37:07 -0400
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-07-17 15:15:30 -0400
commit67a101f573b0cb1043c8c305112113450cb9fdbf (patch)
treea7683be1ef70c4843c82ac5981f15e79033f33d6
parentbfce7cf68673216168020f369365dfc8ccbf23de (diff)
pstore: Headers should include all stuff they use
Headers should really include all the needed prototypes, types, defines etc. to be self-contained. This is a long-standing issue, but apparently the new tracing code unearthed it (SMP=n is also a prerequisite): In file included from fs/pstore/internal.h:4:0, from fs/pstore/ftrace.c:21: include/linux/pstore.h:43:15: error: field ‘read_mutex’ has incomplete type While at it, I also added the following: linux/types.h -> size_t, phys_addr_t, uXX and friends linux/spinlock.h -> spinlock_t linux/errno.h -> Exxxx linux/time.h -> struct timespec (struct passed by value) struct module and rs_control forward declaration (passed via pointers). Signed-off-by: Anton Vorontsov <anton.vorontsov@linaro.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
-rw-r--r--fs/pstore/internal.h2
-rw-r--r--include/linux/pstore.h6
-rw-r--r--include/linux/pstore_ram.h1
3 files changed, 9 insertions, 0 deletions
diff --git a/fs/pstore/internal.h b/fs/pstore/internal.h
index 958c48d8905..0d0d3b7d5f1 100644
--- a/fs/pstore/internal.h
+++ b/fs/pstore/internal.h
@@ -1,6 +1,8 @@
1#ifndef __PSTORE_INTERNAL_H__ 1#ifndef __PSTORE_INTERNAL_H__
2#define __PSTORE_INTERNAL_H__ 2#define __PSTORE_INTERNAL_H__
3 3
4#include <linux/types.h>
5#include <linux/time.h>
4#include <linux/pstore.h> 6#include <linux/pstore.h>
5 7
6#if NR_CPUS <= 2 && defined(CONFIG_ARM_THUMB) 8#if NR_CPUS <= 2 && defined(CONFIG_ARM_THUMB)
diff --git a/include/linux/pstore.h b/include/linux/pstore.h
index 120443b0fda..c892587d9b8 100644
--- a/include/linux/pstore.h
+++ b/include/linux/pstore.h
@@ -24,6 +24,10 @@
24 24
25#include <linux/time.h> 25#include <linux/time.h>
26#include <linux/kmsg_dump.h> 26#include <linux/kmsg_dump.h>
27#include <linux/mutex.h>
28#include <linux/types.h>
29#include <linux/spinlock.h>
30#include <linux/errno.h>
27 31
28/* types */ 32/* types */
29enum pstore_type_id { 33enum pstore_type_id {
@@ -34,6 +38,8 @@ enum pstore_type_id {
34 PSTORE_TYPE_UNKNOWN = 255 38 PSTORE_TYPE_UNKNOWN = 255
35}; 39};
36 40
41struct module;
42
37struct pstore_info { 43struct pstore_info {
38 struct module *owner; 44 struct module *owner;
39 char *name; 45 char *name;
diff --git a/include/linux/pstore_ram.h b/include/linux/pstore_ram.h
index af848e1593b..ba2b211aaa8 100644
--- a/include/linux/pstore_ram.h
+++ b/include/linux/pstore_ram.h
@@ -24,6 +24,7 @@
24#include <linux/init.h> 24#include <linux/init.h>
25 25
26struct persistent_ram_buffer; 26struct persistent_ram_buffer;
27struct rs_control;
27 28
28struct persistent_ram_zone { 29struct persistent_ram_zone {
29 phys_addr_t paddr; 30 phys_addr_t paddr;