aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/arm/mach-aaec2000/clock.c1
-rw-r--r--arch/arm/mach-epxa10db/mm.c1
-rw-r--r--arch/arm/mach-pxa/corgi_lcd.c1
-rw-r--r--arch/ppc/syslib/ppc_sys.c1
-rw-r--r--drivers/base/power/sysfs.c1
-rw-r--r--drivers/char/agp/amd64-agp.c1
-rw-r--r--drivers/hwmon/hwmon.c1
-rw-r--r--drivers/infiniband/core/agent.c3
-rw-r--r--drivers/infiniband/core/packer.c2
-rw-r--r--drivers/infiniband/core/sysfs.c3
-rw-r--r--drivers/infiniband/core/ud_header.c1
-rw-r--r--drivers/infiniband/core/verbs.c1
-rw-r--r--drivers/infiniband/hw/mthca/mthca_catas.c3
-rw-r--r--drivers/infiniband/hw/mthca/mthca_srq.c3
-rw-r--r--drivers/media/dvb/frontends/cx24110.c1
-rw-r--r--drivers/message/i2o/exec-osm.c1
-rw-r--r--drivers/mfd/mcp-core.c2
-rw-r--r--drivers/pci/hotplug/pciehprm_nonacpi.c1
-rw-r--r--drivers/pci/pci-driver.c1
-rw-r--r--drivers/scsi/atari_dma_emul.c2
-rw-r--r--drivers/scsi/raid_class.c2
-rw-r--r--drivers/scsi/scsi_transport_sas.c2
-rw-r--r--drivers/scsi/sym53c8xx_2/sym_hipd.c1
-rw-r--r--fs/9p/error.c1
-rw-r--r--include/asm-alpha/pgtable.h3
-rw-r--r--include/asm-cris/processor.h2
-rw-r--r--include/asm-frv/pgtable.h2
-rw-r--r--include/asm-generic/pgtable.h1
-rw-r--r--include/asm-i386/elf.h2
-rw-r--r--include/asm-i386/pgtable.h3
-rw-r--r--include/asm-ia64/pgtable.h1
-rw-r--r--include/asm-m32r/pgtable.h3
-rw-r--r--include/asm-mips/elf.h2
-rw-r--r--include/asm-mips/pgtable.h3
-rw-r--r--include/asm-parisc/pgtable.h3
-rw-r--r--include/asm-powerpc/elf.h2
-rw-r--r--include/asm-ppc/pgtable.h1
-rw-r--r--include/asm-ppc64/pgtable.h1
-rw-r--r--include/asm-s390/elf.h1
-rw-r--r--include/asm-s390/pgtable.h1
-rw-r--r--include/asm-sh/elf.h1
-rw-r--r--include/asm-sh/pgtable.h2
-rw-r--r--include/asm-sh64/pgtable.h2
-rw-r--r--include/asm-x86_64/elf.h2
-rw-r--r--include/asm-x86_64/pgtable.h2
-rw-r--r--include/asm-xtensa/elf.h2
-rw-r--r--include/asm-xtensa/pgtable.h3
-rw-r--r--include/linux/irq.h1
-rw-r--r--include/linux/memory.h3
-rw-r--r--include/linux/sem.h2
-rw-r--r--include/linux/wait.h1
-rw-r--r--kernel/module.c1
52 files changed, 89 insertions, 1 deletions
diff --git a/arch/arm/mach-aaec2000/clock.c b/arch/arm/mach-aaec2000/clock.c
index 99e019169dda..0340ddc4824e 100644
--- a/arch/arm/mach-aaec2000/clock.c
+++ b/arch/arm/mach-aaec2000/clock.c
@@ -14,6 +14,7 @@
14#include <linux/list.h> 14#include <linux/list.h>
15#include <linux/errno.h> 15#include <linux/errno.h>
16#include <linux/err.h> 16#include <linux/err.h>
17#include <linux/string.h>
17 18
18#include <asm/semaphore.h> 19#include <asm/semaphore.h>
19#include <asm/hardware/clock.h> 20#include <asm/hardware/clock.h>
diff --git a/arch/arm/mach-epxa10db/mm.c b/arch/arm/mach-epxa10db/mm.c
index e8832d0910ee..cfd0d2182d44 100644
--- a/arch/arm/mach-epxa10db/mm.c
+++ b/arch/arm/mach-epxa10db/mm.c
@@ -25,6 +25,7 @@
25#include <asm/hardware.h> 25#include <asm/hardware.h>
26#include <asm/io.h> 26#include <asm/io.h>
27#include <asm/sizes.h> 27#include <asm/sizes.h>
28#include <asm/page.h>
28 29
29#include <asm/mach/map.h> 30#include <asm/mach/map.h>
30 31
diff --git a/arch/arm/mach-pxa/corgi_lcd.c b/arch/arm/mach-pxa/corgi_lcd.c
index 54162ba95414..698eb06545c4 100644
--- a/arch/arm/mach-pxa/corgi_lcd.c
+++ b/arch/arm/mach-pxa/corgi_lcd.c
@@ -19,6 +19,7 @@
19#include <linux/kernel.h> 19#include <linux/kernel.h>
20#include <linux/platform_device.h> 20#include <linux/platform_device.h>
21#include <linux/module.h> 21#include <linux/module.h>
22#include <linux/string.h>
22#include <asm/arch/akita.h> 23#include <asm/arch/akita.h>
23#include <asm/arch/corgi.h> 24#include <asm/arch/corgi.h>
24#include <asm/arch/hardware.h> 25#include <asm/arch/hardware.h>
diff --git a/arch/ppc/syslib/ppc_sys.c b/arch/ppc/syslib/ppc_sys.c
index 62ee86e80711..603f01190816 100644
--- a/arch/ppc/syslib/ppc_sys.c
+++ b/arch/ppc/syslib/ppc_sys.c
@@ -14,6 +14,7 @@
14 * option) any later version. 14 * option) any later version.
15 */ 15 */
16 16
17#include <linux/string.h>
17#include <asm/ppc_sys.h> 18#include <asm/ppc_sys.h>
18 19
19int (*ppc_sys_device_fixup) (struct platform_device * pdev); 20int (*ppc_sys_device_fixup) (struct platform_device * pdev);
diff --git a/drivers/base/power/sysfs.c b/drivers/base/power/sysfs.c
index 89c57875f3e5..f3a0c562bcb5 100644
--- a/drivers/base/power/sysfs.c
+++ b/drivers/base/power/sysfs.c
@@ -3,6 +3,7 @@
3 */ 3 */
4 4
5#include <linux/device.h> 5#include <linux/device.h>
6#include <linux/string.h>
6#include "power.h" 7#include "power.h"
7 8
8 9
diff --git a/drivers/char/agp/amd64-agp.c b/drivers/char/agp/amd64-agp.c
index 0e6c3a31d344..78ce98a69f37 100644
--- a/drivers/char/agp/amd64-agp.c
+++ b/drivers/char/agp/amd64-agp.c
@@ -13,6 +13,7 @@
13#include <linux/pci.h> 13#include <linux/pci.h>
14#include <linux/init.h> 14#include <linux/init.h>
15#include <linux/agp_backend.h> 15#include <linux/agp_backend.h>
16#include <linux/mmzone.h>
16#include <asm/page.h> /* PAGE_SIZE */ 17#include <asm/page.h> /* PAGE_SIZE */
17#include "agp.h" 18#include "agp.h"
18 19
diff --git a/drivers/hwmon/hwmon.c b/drivers/hwmon/hwmon.c
index 6f48579799b5..dddd3eb9b387 100644
--- a/drivers/hwmon/hwmon.c
+++ b/drivers/hwmon/hwmon.c
@@ -16,6 +16,7 @@
16#include <linux/kdev_t.h> 16#include <linux/kdev_t.h>
17#include <linux/idr.h> 17#include <linux/idr.h>
18#include <linux/hwmon.h> 18#include <linux/hwmon.h>
19#include <linux/gfp.h>
19 20
20#define HWMON_ID_PREFIX "hwmon" 21#define HWMON_ID_PREFIX "hwmon"
21#define HWMON_ID_FORMAT HWMON_ID_PREFIX "%d" 22#define HWMON_ID_FORMAT HWMON_ID_PREFIX "%d"
diff --git a/drivers/infiniband/core/agent.c b/drivers/infiniband/core/agent.c
index 7545775d38ef..34b724afd28d 100644
--- a/drivers/infiniband/core/agent.c
+++ b/drivers/infiniband/core/agent.c
@@ -37,6 +37,9 @@
37 * $Id: agent.c 1389 2004-12-27 22:56:47Z roland $ 37 * $Id: agent.c 1389 2004-12-27 22:56:47Z roland $
38 */ 38 */
39 39
40#include <linux/slab.h>
41#include <linux/string.h>
42
40#include "agent.h" 43#include "agent.h"
41#include "smi.h" 44#include "smi.h"
42 45
diff --git a/drivers/infiniband/core/packer.c b/drivers/infiniband/core/packer.c
index 35df5010e723..c972d7235764 100644
--- a/drivers/infiniband/core/packer.c
+++ b/drivers/infiniband/core/packer.c
@@ -33,6 +33,8 @@
33 * $Id: packer.c 1349 2004-12-16 21:09:43Z roland $ 33 * $Id: packer.c 1349 2004-12-16 21:09:43Z roland $
34 */ 34 */
35 35
36#include <linux/string.h>
37
36#include <rdma/ib_pack.h> 38#include <rdma/ib_pack.h>
37 39
38static u64 value_read(int offset, int size, void *structure) 40static u64 value_read(int offset, int size, void *structure)
diff --git a/drivers/infiniband/core/sysfs.c b/drivers/infiniband/core/sysfs.c
index b8120650e711..08648b1a387e 100644
--- a/drivers/infiniband/core/sysfs.c
+++ b/drivers/infiniband/core/sysfs.c
@@ -36,6 +36,9 @@
36 36
37#include "core_priv.h" 37#include "core_priv.h"
38 38
39#include <linux/slab.h>
40#include <linux/string.h>
41
39#include <rdma/ib_mad.h> 42#include <rdma/ib_mad.h>
40 43
41struct ib_port { 44struct ib_port {
diff --git a/drivers/infiniband/core/ud_header.c b/drivers/infiniband/core/ud_header.c
index 527b23450ab3..997c07db6d8f 100644
--- a/drivers/infiniband/core/ud_header.c
+++ b/drivers/infiniband/core/ud_header.c
@@ -34,6 +34,7 @@
34 */ 34 */
35 35
36#include <linux/errno.h> 36#include <linux/errno.h>
37#include <linux/string.h>
37 38
38#include <rdma/ib_pack.h> 39#include <rdma/ib_pack.h>
39 40
diff --git a/drivers/infiniband/core/verbs.c b/drivers/infiniband/core/verbs.c
index 72d3ef786db5..4186cc888ea5 100644
--- a/drivers/infiniband/core/verbs.c
+++ b/drivers/infiniband/core/verbs.c
@@ -40,6 +40,7 @@
40 40
41#include <linux/errno.h> 41#include <linux/errno.h>
42#include <linux/err.h> 42#include <linux/err.h>
43#include <linux/string.h>
43 44
44#include <rdma/ib_verbs.h> 45#include <rdma/ib_verbs.h>
45#include <rdma/ib_cache.h> 46#include <rdma/ib_cache.h>
diff --git a/drivers/infiniband/hw/mthca/mthca_catas.c b/drivers/infiniband/hw/mthca/mthca_catas.c
index 7ac52af43b99..25ebab64bc42 100644
--- a/drivers/infiniband/hw/mthca/mthca_catas.c
+++ b/drivers/infiniband/hw/mthca/mthca_catas.c
@@ -32,6 +32,9 @@
32 * $Id$ 32 * $Id$
33 */ 33 */
34 34
35#include <linux/jiffies.h>
36#include <linux/timer.h>
37
35#include "mthca_dev.h" 38#include "mthca_dev.h"
36 39
37enum { 40enum {
diff --git a/drivers/infiniband/hw/mthca/mthca_srq.c b/drivers/infiniband/hw/mthca/mthca_srq.c
index 292f55be8cbd..26d5161fde07 100644
--- a/drivers/infiniband/hw/mthca/mthca_srq.c
+++ b/drivers/infiniband/hw/mthca/mthca_srq.c
@@ -32,6 +32,9 @@
32 * $Id: mthca_srq.c 3047 2005-08-10 03:59:35Z roland $ 32 * $Id: mthca_srq.c 3047 2005-08-10 03:59:35Z roland $
33 */ 33 */
34 34
35#include <linux/slab.h>
36#include <linux/string.h>
37
35#include "mthca_dev.h" 38#include "mthca_dev.h"
36#include "mthca_cmd.h" 39#include "mthca_cmd.h"
37#include "mthca_memfree.h" 40#include "mthca_memfree.h"
diff --git a/drivers/media/dvb/frontends/cx24110.c b/drivers/media/dvb/frontends/cx24110.c
index d4b97989e3ed..654d7dc879d9 100644
--- a/drivers/media/dvb/frontends/cx24110.c
+++ b/drivers/media/dvb/frontends/cx24110.c
@@ -27,6 +27,7 @@
27#include <linux/module.h> 27#include <linux/module.h>
28#include <linux/moduleparam.h> 28#include <linux/moduleparam.h>
29#include <linux/init.h> 29#include <linux/init.h>
30#include <linux/jiffies.h>
30 31
31#include "dvb_frontend.h" 32#include "dvb_frontend.h"
32#include "cx24110.h" 33#include "cx24110.h"
diff --git a/drivers/message/i2o/exec-osm.c b/drivers/message/i2o/exec-osm.c
index b675b4ebbebd..9c339a2505b0 100644
--- a/drivers/message/i2o/exec-osm.c
+++ b/drivers/message/i2o/exec-osm.c
@@ -33,6 +33,7 @@
33#include <linux/workqueue.h> 33#include <linux/workqueue.h>
34#include <linux/string.h> 34#include <linux/string.h>
35#include <linux/slab.h> 35#include <linux/slab.h>
36#include <linux/sched.h> /* wait_event_interruptible_timeout() needs this */
36#include <asm/param.h> /* HZ */ 37#include <asm/param.h> /* HZ */
37#include "core.h" 38#include "core.h"
38 39
diff --git a/drivers/mfd/mcp-core.c b/drivers/mfd/mcp-core.c
index c75d713c01e4..55ba23075c90 100644
--- a/drivers/mfd/mcp-core.c
+++ b/drivers/mfd/mcp-core.c
@@ -15,6 +15,8 @@
15#include <linux/errno.h> 15#include <linux/errno.h>
16#include <linux/smp.h> 16#include <linux/smp.h>
17#include <linux/device.h> 17#include <linux/device.h>
18#include <linux/slab.h>
19#include <linux/string.h>
18 20
19#include <asm/dma.h> 21#include <asm/dma.h>
20#include <asm/system.h> 22#include <asm/system.h>
diff --git a/drivers/pci/hotplug/pciehprm_nonacpi.c b/drivers/pci/hotplug/pciehprm_nonacpi.c
index 33b2c69a0829..76c727c74cc0 100644
--- a/drivers/pci/hotplug/pciehprm_nonacpi.c
+++ b/drivers/pci/hotplug/pciehprm_nonacpi.c
@@ -31,6 +31,7 @@
31#include <linux/module.h> 31#include <linux/module.h>
32#include <linux/kernel.h> 32#include <linux/kernel.h>
33#include <linux/types.h> 33#include <linux/types.h>
34#include <linux/sched.h>
34#include <linux/pci.h> 35#include <linux/pci.h>
35#include <linux/init.h> 36#include <linux/init.h>
36#include <linux/slab.h> 37#include <linux/slab.h>
diff --git a/drivers/pci/pci-driver.c b/drivers/pci/pci-driver.c
index ae986e590b48..94e68c54d273 100644
--- a/drivers/pci/pci-driver.c
+++ b/drivers/pci/pci-driver.c
@@ -10,6 +10,7 @@
10#include <linux/mempolicy.h> 10#include <linux/mempolicy.h>
11#include <linux/string.h> 11#include <linux/string.h>
12#include <linux/slab.h> 12#include <linux/slab.h>
13#include <linux/sched.h>
13#include "pci.h" 14#include "pci.h"
14 15
15/* 16/*
diff --git a/drivers/scsi/atari_dma_emul.c b/drivers/scsi/atari_dma_emul.c
index 7026045527fd..8d5d2a5da961 100644
--- a/drivers/scsi/atari_dma_emul.c
+++ b/drivers/scsi/atari_dma_emul.c
@@ -19,6 +19,8 @@
19 * this code. 19 * this code.
20 */ 20 */
21 21
22#include <linux/compiler.h>
23#include <asm/thread_info.h>
22#include <asm/uaccess.h> 24#include <asm/uaccess.h>
23 25
24#define hades_dma_ctrl (*(unsigned char *) 0xffff8717) 26#define hades_dma_ctrl (*(unsigned char *) 0xffff8717)
diff --git a/drivers/scsi/raid_class.c b/drivers/scsi/raid_class.c
index f1ea5027865f..caa0c3629626 100644
--- a/drivers/scsi/raid_class.c
+++ b/drivers/scsi/raid_class.c
@@ -4,6 +4,8 @@
4#include <linux/init.h> 4#include <linux/init.h>
5#include <linux/module.h> 5#include <linux/module.h>
6#include <linux/list.h> 6#include <linux/list.h>
7#include <linux/slab.h>
8#include <linux/string.h>
7#include <linux/raid_class.h> 9#include <linux/raid_class.h>
8#include <scsi/scsi_device.h> 10#include <scsi/scsi_device.h>
9#include <scsi/scsi_host.h> 11#include <scsi/scsi_host.h>
diff --git a/drivers/scsi/scsi_transport_sas.c b/drivers/scsi/scsi_transport_sas.c
index 0cc766a9aa65..edabbd05d258 100644
--- a/drivers/scsi/scsi_transport_sas.c
+++ b/drivers/scsi/scsi_transport_sas.c
@@ -26,6 +26,8 @@
26#include <linux/init.h> 26#include <linux/init.h>
27#include <linux/module.h> 27#include <linux/module.h>
28#include <linux/err.h> 28#include <linux/err.h>
29#include <linux/slab.h>
30#include <linux/string.h>
29 31
30#include <scsi/scsi_device.h> 32#include <scsi/scsi_device.h>
31#include <scsi/scsi_host.h> 33#include <scsi/scsi_host.h>
diff --git a/drivers/scsi/sym53c8xx_2/sym_hipd.c b/drivers/scsi/sym53c8xx_2/sym_hipd.c
index a1a58e1d5ad3..a7420cad4547 100644
--- a/drivers/scsi/sym53c8xx_2/sym_hipd.c
+++ b/drivers/scsi/sym53c8xx_2/sym_hipd.c
@@ -39,6 +39,7 @@
39 */ 39 */
40 40
41#include <linux/slab.h> 41#include <linux/slab.h>
42#include <asm/param.h> /* for timeouts in units of HZ */
42 43
43#include "sym_glue.h" 44#include "sym_glue.h"
44#include "sym_nvram.h" 45#include "sym_nvram.h"
diff --git a/fs/9p/error.c b/fs/9p/error.c
index fee5d19179c5..834cb179e388 100644
--- a/fs/9p/error.c
+++ b/fs/9p/error.c
@@ -33,6 +33,7 @@
33 33
34#include <linux/list.h> 34#include <linux/list.h>
35#include <linux/jhash.h> 35#include <linux/jhash.h>
36#include <linux/string.h>
36 37
37#include "debug.h" 38#include "debug.h"
38#include "error.h" 39#include "error.h"
diff --git a/include/asm-alpha/pgtable.h b/include/asm-alpha/pgtable.h
index 8393bf374b2b..a985cd29b6db 100644
--- a/include/asm-alpha/pgtable.h
+++ b/include/asm-alpha/pgtable.h
@@ -17,6 +17,9 @@
17#include <asm/processor.h> /* For TASK_SIZE */ 17#include <asm/processor.h> /* For TASK_SIZE */
18#include <asm/machvec.h> 18#include <asm/machvec.h>
19 19
20struct mm_struct;
21struct vm_area_struct;
22
20/* Certain architectures need to do special things when PTEs 23/* Certain architectures need to do special things when PTEs
21 * within a page table are directly modified. Thus, the following 24 * within a page table are directly modified. Thus, the following
22 * hook is made available. 25 * hook is made available.
diff --git a/include/asm-cris/processor.h b/include/asm-cris/processor.h
index e8b2abb2ae59..dce41009eeb0 100644
--- a/include/asm-cris/processor.h
+++ b/include/asm-cris/processor.h
@@ -16,6 +16,8 @@
16#include <asm/ptrace.h> 16#include <asm/ptrace.h>
17#include <asm/arch/processor.h> 17#include <asm/arch/processor.h>
18 18
19struct task_struct;
20
19/* This decides where the kernel will search for a free chunk of vm 21/* This decides where the kernel will search for a free chunk of vm
20 * space during mmap's. 22 * space during mmap's.
21 */ 23 */
diff --git a/include/asm-frv/pgtable.h b/include/asm-frv/pgtable.h
index b247e99dff49..844666377dcb 100644
--- a/include/asm-frv/pgtable.h
+++ b/include/asm-frv/pgtable.h
@@ -26,6 +26,8 @@
26#include <linux/slab.h> 26#include <linux/slab.h>
27#include <linux/list.h> 27#include <linux/list.h>
28#include <linux/spinlock.h> 28#include <linux/spinlock.h>
29struct mm_struct;
30struct vm_area_struct;
29#endif 31#endif
30 32
31#ifndef __ASSEMBLY__ 33#ifndef __ASSEMBLY__
diff --git a/include/asm-generic/pgtable.h b/include/asm-generic/pgtable.h
index 7dca30a26c53..358e4d309ceb 100644
--- a/include/asm-generic/pgtable.h
+++ b/include/asm-generic/pgtable.h
@@ -128,6 +128,7 @@ do { \
128#endif 128#endif
129 129
130#ifndef __HAVE_ARCH_PTEP_SET_WRPROTECT 130#ifndef __HAVE_ARCH_PTEP_SET_WRPROTECT
131struct mm_struct;
131static inline void ptep_set_wrprotect(struct mm_struct *mm, unsigned long address, pte_t *ptep) 132static inline void ptep_set_wrprotect(struct mm_struct *mm, unsigned long address, pte_t *ptep)
132{ 133{
133 pte_t old_pte = *ptep; 134 pte_t old_pte = *ptep;
diff --git a/include/asm-i386/elf.h b/include/asm-i386/elf.h
index fa11117d3cfa..4153d80e4d2b 100644
--- a/include/asm-i386/elf.h
+++ b/include/asm-i386/elf.h
@@ -119,6 +119,8 @@ typedef struct user_fxsr_struct elf_fpxregset_t;
119 */ 119 */
120#define elf_read_implies_exec(ex, executable_stack) (executable_stack != EXSTACK_DISABLE_X) 120#define elf_read_implies_exec(ex, executable_stack) (executable_stack != EXSTACK_DISABLE_X)
121 121
122struct task_struct;
123
122extern int dump_task_regs (struct task_struct *, elf_gregset_t *); 124extern int dump_task_regs (struct task_struct *, elf_gregset_t *);
123extern int dump_task_fpu (struct task_struct *, elf_fpregset_t *); 125extern int dump_task_fpu (struct task_struct *, elf_fpregset_t *);
124extern int dump_task_extended_fpu (struct task_struct *, struct user_fxsr_struct *); 126extern int dump_task_extended_fpu (struct task_struct *, struct user_fxsr_struct *);
diff --git a/include/asm-i386/pgtable.h b/include/asm-i386/pgtable.h
index 03f3c8ac6383..088a945bf26b 100644
--- a/include/asm-i386/pgtable.h
+++ b/include/asm-i386/pgtable.h
@@ -25,6 +25,9 @@
25#include <linux/list.h> 25#include <linux/list.h>
26#include <linux/spinlock.h> 26#include <linux/spinlock.h>
27 27
28struct mm_struct;
29struct vm_area_struct;
30
28/* 31/*
29 * ZERO_PAGE is a global shared page that is always zero: used 32 * ZERO_PAGE is a global shared page that is always zero: used
30 * for zero-mapped memory areas etc.. 33 * for zero-mapped memory areas etc..
diff --git a/include/asm-ia64/pgtable.h b/include/asm-ia64/pgtable.h
index 21e32a06bc82..c34ba80c1c31 100644
--- a/include/asm-ia64/pgtable.h
+++ b/include/asm-ia64/pgtable.h
@@ -127,6 +127,7 @@
127 127
128# ifndef __ASSEMBLY__ 128# ifndef __ASSEMBLY__
129 129
130#include <linux/sched.h> /* for mm_struct */
130#include <asm/bitops.h> 131#include <asm/bitops.h>
131#include <asm/cacheflush.h> 132#include <asm/cacheflush.h>
132#include <asm/mmu_context.h> 133#include <asm/mmu_context.h>
diff --git a/include/asm-m32r/pgtable.h b/include/asm-m32r/pgtable.h
index 1cd5fd4a5b2c..75740debcd01 100644
--- a/include/asm-m32r/pgtable.h
+++ b/include/asm-m32r/pgtable.h
@@ -27,6 +27,9 @@
27#include <asm/bitops.h> 27#include <asm/bitops.h>
28#include <asm/page.h> 28#include <asm/page.h>
29 29
30struct mm_struct;
31struct vm_area_struct;
32
30extern pgd_t swapper_pg_dir[1024]; 33extern pgd_t swapper_pg_dir[1024];
31extern void paging_init(void); 34extern void paging_init(void);
32 35
diff --git a/include/asm-mips/elf.h b/include/asm-mips/elf.h
index 7420f12742bb..d2c9a25f8459 100644
--- a/include/asm-mips/elf.h
+++ b/include/asm-mips/elf.h
@@ -275,6 +275,8 @@ do { \
275 275
276#endif /* CONFIG_64BIT */ 276#endif /* CONFIG_64BIT */
277 277
278struct task_struct;
279
278extern void dump_regs(elf_greg_t *, struct pt_regs *regs); 280extern void dump_regs(elf_greg_t *, struct pt_regs *regs);
279extern int dump_task_regs (struct task_struct *, elf_gregset_t *); 281extern int dump_task_regs (struct task_struct *, elf_gregset_t *);
280extern int dump_task_fpu(struct task_struct *, elf_fpregset_t *); 282extern int dump_task_fpu(struct task_struct *, elf_fpregset_t *);
diff --git a/include/asm-mips/pgtable.h b/include/asm-mips/pgtable.h
index 34facd996503..702a28fa7a34 100644
--- a/include/asm-mips/pgtable.h
+++ b/include/asm-mips/pgtable.h
@@ -19,6 +19,9 @@
19#include <asm/io.h> 19#include <asm/io.h>
20#include <asm/pgtable-bits.h> 20#include <asm/pgtable-bits.h>
21 21
22struct mm_struct;
23struct vm_area_struct;
24
22#define PAGE_NONE __pgprot(_PAGE_PRESENT | _CACHE_CACHABLE_NONCOHERENT) 25#define PAGE_NONE __pgprot(_PAGE_PRESENT | _CACHE_CACHABLE_NONCOHERENT)
23#define PAGE_SHARED __pgprot(_PAGE_PRESENT | _PAGE_READ | _PAGE_WRITE | \ 26#define PAGE_SHARED __pgprot(_PAGE_PRESENT | _PAGE_READ | _PAGE_WRITE | \
24 PAGE_CACHABLE_DEFAULT) 27 PAGE_CACHABLE_DEFAULT)
diff --git a/include/asm-parisc/pgtable.h b/include/asm-parisc/pgtable.h
index c28fb6f48c6c..b4554711c3e7 100644
--- a/include/asm-parisc/pgtable.h
+++ b/include/asm-parisc/pgtable.h
@@ -12,6 +12,7 @@
12 */ 12 */
13 13
14#include <linux/spinlock.h> 14#include <linux/spinlock.h>
15#include <linux/mm.h> /* for vm_area_struct */
15#include <asm/processor.h> 16#include <asm/processor.h>
16#include <asm/cache.h> 17#include <asm/cache.h>
17#include <asm/bitops.h> 18#include <asm/bitops.h>
@@ -418,7 +419,6 @@ extern void paging_init (void);
418 419
419#define PG_dcache_dirty PG_arch_1 420#define PG_dcache_dirty PG_arch_1
420 421
421struct vm_area_struct; /* forward declaration (include/linux/mm.h) */
422extern void update_mmu_cache(struct vm_area_struct *, unsigned long, pte_t); 422extern void update_mmu_cache(struct vm_area_struct *, unsigned long, pte_t);
423 423
424/* Encode and de-code a swap entry */ 424/* Encode and de-code a swap entry */
@@ -464,6 +464,7 @@ static inline int ptep_test_and_clear_dirty(struct vm_area_struct *vma, unsigned
464 464
465extern spinlock_t pa_dbit_lock; 465extern spinlock_t pa_dbit_lock;
466 466
467struct mm_struct;
467static inline pte_t ptep_get_and_clear(struct mm_struct *mm, unsigned long addr, pte_t *ptep) 468static inline pte_t ptep_get_and_clear(struct mm_struct *mm, unsigned long addr, pte_t *ptep)
468{ 469{
469 pte_t old_pte; 470 pte_t old_pte;
diff --git a/include/asm-powerpc/elf.h b/include/asm-powerpc/elf.h
index d140577d0a05..feac3458d71f 100644
--- a/include/asm-powerpc/elf.h
+++ b/include/asm-powerpc/elf.h
@@ -1,11 +1,13 @@
1#ifndef _ASM_POWERPC_ELF_H 1#ifndef _ASM_POWERPC_ELF_H
2#define _ASM_POWERPC_ELF_H 2#define _ASM_POWERPC_ELF_H
3 3
4#include <linux/sched.h> /* for task_struct */
4#include <asm/types.h> 5#include <asm/types.h>
5#include <asm/ptrace.h> 6#include <asm/ptrace.h>
6#include <asm/cputable.h> 7#include <asm/cputable.h>
7#include <asm/auxvec.h> 8#include <asm/auxvec.h>
8#include <asm/page.h> 9#include <asm/page.h>
10#include <asm/string.h>
9 11
10/* PowerPC relocations defined by the ABIs */ 12/* PowerPC relocations defined by the ABIs */
11#define R_PPC_NONE 0 13#define R_PPC_NONE 0
diff --git a/include/asm-ppc/pgtable.h b/include/asm-ppc/pgtable.h
index b28a713ba862..6d1c39e8a6af 100644
--- a/include/asm-ppc/pgtable.h
+++ b/include/asm-ppc/pgtable.h
@@ -12,6 +12,7 @@
12#include <asm/processor.h> /* For TASK_SIZE */ 12#include <asm/processor.h> /* For TASK_SIZE */
13#include <asm/mmu.h> 13#include <asm/mmu.h>
14#include <asm/page.h> 14#include <asm/page.h>
15struct mm_struct;
15 16
16extern unsigned long va_to_phys(unsigned long address); 17extern unsigned long va_to_phys(unsigned long address);
17extern pte_t *va_to_pte(unsigned long address); 18extern pte_t *va_to_pte(unsigned long address);
diff --git a/include/asm-ppc64/pgtable.h b/include/asm-ppc64/pgtable.h
index fde93ec36abc..a9783ba7fe98 100644
--- a/include/asm-ppc64/pgtable.h
+++ b/include/asm-ppc64/pgtable.h
@@ -13,6 +13,7 @@
13#include <asm/mmu.h> 13#include <asm/mmu.h>
14#include <asm/page.h> 14#include <asm/page.h>
15#include <asm/tlbflush.h> 15#include <asm/tlbflush.h>
16struct mm_struct;
16#endif /* __ASSEMBLY__ */ 17#endif /* __ASSEMBLY__ */
17 18
18#ifdef CONFIG_PPC_64K_PAGES 19#ifdef CONFIG_PPC_64K_PAGES
diff --git a/include/asm-s390/elf.h b/include/asm-s390/elf.h
index 3b8bd46832a1..372d51cccd53 100644
--- a/include/asm-s390/elf.h
+++ b/include/asm-s390/elf.h
@@ -96,6 +96,7 @@
96 * ELF register definitions.. 96 * ELF register definitions..
97 */ 97 */
98 98
99#include <linux/sched.h> /* for task_struct */
99#include <asm/ptrace.h> 100#include <asm/ptrace.h>
100#include <asm/user.h> 101#include <asm/user.h>
101#include <asm/system.h> /* for save_access_regs */ 102#include <asm/system.h> /* for save_access_regs */
diff --git a/include/asm-s390/pgtable.h b/include/asm-s390/pgtable.h
index df94f89038cc..9be741bb1496 100644
--- a/include/asm-s390/pgtable.h
+++ b/include/asm-s390/pgtable.h
@@ -36,6 +36,7 @@
36#include <linux/threads.h> 36#include <linux/threads.h>
37 37
38struct vm_area_struct; /* forward declaration (include/linux/mm.h) */ 38struct vm_area_struct; /* forward declaration (include/linux/mm.h) */
39struct mm_struct;
39 40
40extern pgd_t swapper_pg_dir[] __attribute__ ((aligned (4096))); 41extern pgd_t swapper_pg_dir[] __attribute__ ((aligned (4096)));
41extern void paging_init(void); 42extern void paging_init(void);
diff --git a/include/asm-sh/elf.h b/include/asm-sh/elf.h
index 8fe00a1981ce..1b63dfeea4f2 100644
--- a/include/asm-sh/elf.h
+++ b/include/asm-sh/elf.h
@@ -111,6 +111,7 @@ typedef struct user_fpu_struct elf_fpregset_t;
111 111
112#ifdef __KERNEL__ 112#ifdef __KERNEL__
113#define SET_PERSONALITY(ex, ibcs2) set_personality(PER_LINUX_32BIT) 113#define SET_PERSONALITY(ex, ibcs2) set_personality(PER_LINUX_32BIT)
114struct task_struct;
114extern int dump_task_regs (struct task_struct *, elf_gregset_t *); 115extern int dump_task_regs (struct task_struct *, elf_gregset_t *);
115extern int dump_task_fpu (struct task_struct *, elf_fpregset_t *); 116extern int dump_task_fpu (struct task_struct *, elf_fpregset_t *);
116 117
diff --git a/include/asm-sh/pgtable.h b/include/asm-sh/pgtable.h
index dee36bcbcf98..bb0efb31a8cb 100644
--- a/include/asm-sh/pgtable.h
+++ b/include/asm-sh/pgtable.h
@@ -284,6 +284,8 @@ typedef pte_t *pte_addr_t;
284#define GET_IOSPACE(pfn) 0 284#define GET_IOSPACE(pfn) 0
285#define GET_PFN(pfn) (pfn) 285#define GET_PFN(pfn) (pfn)
286 286
287struct mm_struct;
288
287/* 289/*
288 * No page table caches to initialise 290 * No page table caches to initialise
289 */ 291 */
diff --git a/include/asm-sh64/pgtable.h b/include/asm-sh64/pgtable.h
index 51b05818e4eb..a1906a772df9 100644
--- a/include/asm-sh64/pgtable.h
+++ b/include/asm-sh64/pgtable.h
@@ -24,6 +24,8 @@
24#include <linux/threads.h> 24#include <linux/threads.h>
25#include <linux/config.h> 25#include <linux/config.h>
26 26
27struct vm_area_struct;
28
27extern void paging_init(void); 29extern void paging_init(void);
28 30
29/* We provide our own get_unmapped_area to avoid cache synonym issue */ 31/* We provide our own get_unmapped_area to avoid cache synonym issue */
diff --git a/include/asm-x86_64/elf.h b/include/asm-x86_64/elf.h
index a60a35e79222..43862cd6a569 100644
--- a/include/asm-x86_64/elf.h
+++ b/include/asm-x86_64/elf.h
@@ -149,6 +149,8 @@ extern void set_personality_64bit(void);
149 */ 149 */
150#define elf_read_implies_exec(ex, executable_stack) (executable_stack != EXSTACK_DISABLE_X) 150#define elf_read_implies_exec(ex, executable_stack) (executable_stack != EXSTACK_DISABLE_X)
151 151
152struct task_struct;
153
152extern int dump_task_regs (struct task_struct *, elf_gregset_t *); 154extern int dump_task_regs (struct task_struct *, elf_gregset_t *);
153extern int dump_task_fpu (struct task_struct *, elf_fpregset_t *); 155extern int dump_task_fpu (struct task_struct *, elf_fpregset_t *);
154 156
diff --git a/include/asm-x86_64/pgtable.h b/include/asm-x86_64/pgtable.h
index 7a07196a7202..7309fffeec9a 100644
--- a/include/asm-x86_64/pgtable.h
+++ b/include/asm-x86_64/pgtable.h
@@ -105,6 +105,8 @@ static inline void pgd_clear (pgd_t * pgd)
105 105
106#define ptep_get_and_clear(mm,addr,xp) __pte(xchg(&(xp)->pte, 0)) 106#define ptep_get_and_clear(mm,addr,xp) __pte(xchg(&(xp)->pte, 0))
107 107
108struct mm_struct;
109
108static inline pte_t ptep_get_and_clear_full(struct mm_struct *mm, unsigned long addr, pte_t *ptep, int full) 110static inline pte_t ptep_get_and_clear_full(struct mm_struct *mm, unsigned long addr, pte_t *ptep, int full)
109{ 111{
110 pte_t pte; 112 pte_t pte;
diff --git a/include/asm-xtensa/elf.h b/include/asm-xtensa/elf.h
index 64f1f53874fe..de0667453b2e 100644
--- a/include/asm-xtensa/elf.h
+++ b/include/asm-xtensa/elf.h
@@ -209,6 +209,8 @@ extern void xtensa_elf_core_copy_regs (xtensa_gregset_t *, struct pt_regs *);
209 209
210#define SET_PERSONALITY(ex, ibcs2) set_personality(PER_LINUX_32BIT) 210#define SET_PERSONALITY(ex, ibcs2) set_personality(PER_LINUX_32BIT)
211 211
212struct task_struct;
213
212extern void do_copy_regs (xtensa_gregset_t*, struct pt_regs*, 214extern void do_copy_regs (xtensa_gregset_t*, struct pt_regs*,
213 struct task_struct*); 215 struct task_struct*);
214extern void do_restore_regs (xtensa_gregset_t*, struct pt_regs*, 216extern void do_restore_regs (xtensa_gregset_t*, struct pt_regs*,
diff --git a/include/asm-xtensa/pgtable.h b/include/asm-xtensa/pgtable.h
index 987e3b802313..7b15afb70c56 100644
--- a/include/asm-xtensa/pgtable.h
+++ b/include/asm-xtensa/pgtable.h
@@ -278,6 +278,8 @@ static inline void update_pte(pte_t *ptep, pte_t pteval)
278#endif 278#endif
279} 279}
280 280
281struct mm_struct;
282
281static inline void 283static inline void
282set_pte_at(struct mm_struct *mm, unsigned long addr, pte_t *ptep, pte_t pteval) 284set_pte_at(struct mm_struct *mm, unsigned long addr, pte_t *ptep, pte_t pteval)
283{ 285{
@@ -294,6 +296,7 @@ set_pmd(pmd_t *pmdp, pmd_t pmdval)
294#endif 296#endif
295} 297}
296 298
299struct vm_area_struct;
297 300
298static inline int 301static inline int
299ptep_test_and_clear_young(struct vm_area_struct *vma, unsigned long addr, 302ptep_test_and_clear_young(struct vm_area_struct *vma, unsigned long addr,
diff --git a/include/linux/irq.h b/include/linux/irq.h
index 69681c3b1f05..c516382fbec2 100644
--- a/include/linux/irq.h
+++ b/include/linux/irq.h
@@ -10,6 +10,7 @@
10 */ 10 */
11 11
12#include <linux/config.h> 12#include <linux/config.h>
13#include <asm/smp.h> /* cpu_online_map */
13 14
14#if !defined(CONFIG_ARCH_S390) 15#if !defined(CONFIG_ARCH_S390)
15 16
diff --git a/include/linux/memory.h b/include/linux/memory.h
index 0def328ab5cf..9a424383e6c6 100644
--- a/include/linux/memory.h
+++ b/include/linux/memory.h
@@ -54,6 +54,9 @@ struct memory_block {
54 */ 54 */
55#define MEM_MAPPING_INVALID (1<<3) 55#define MEM_MAPPING_INVALID (1<<3)
56 56
57struct notifier_block;
58struct mem_section;
59
57#ifndef CONFIG_MEMORY_HOTPLUG 60#ifndef CONFIG_MEMORY_HOTPLUG
58static inline int memory_dev_init(void) 61static inline int memory_dev_init(void)
59{ 62{
diff --git a/include/linux/sem.h b/include/linux/sem.h
index 106f9757339a..3c1f1120fe88 100644
--- a/include/linux/sem.h
+++ b/include/linux/sem.h
@@ -79,6 +79,8 @@ struct seminfo {
79 79
80#ifdef __KERNEL__ 80#ifdef __KERNEL__
81 81
82struct task_struct;
83
82/* One semaphore structure for each semaphore in the system. */ 84/* One semaphore structure for each semaphore in the system. */
83struct sem { 85struct sem {
84 int semval; /* current value */ 86 int semval; /* current value */
diff --git a/include/linux/wait.h b/include/linux/wait.h
index d38c9fecdc36..d28518236b62 100644
--- a/include/linux/wait.h
+++ b/include/linux/wait.h
@@ -54,6 +54,7 @@ struct __wait_queue_head {
54}; 54};
55typedef struct __wait_queue_head wait_queue_head_t; 55typedef struct __wait_queue_head wait_queue_head_t;
56 56
57struct task_struct;
57 58
58/* 59/*
59 * Macros for declaration and initialisaton of the datatypes 60 * Macros for declaration and initialisaton of the datatypes
diff --git a/kernel/module.c b/kernel/module.c
index ff5c500ab625..2ea929d51ad0 100644
--- a/kernel/module.c
+++ b/kernel/module.c
@@ -37,6 +37,7 @@
37#include <linux/stop_machine.h> 37#include <linux/stop_machine.h>
38#include <linux/device.h> 38#include <linux/device.h>
39#include <linux/string.h> 39#include <linux/string.h>
40#include <linux/sched.h>
40#include <asm/uaccess.h> 41#include <asm/uaccess.h>
41#include <asm/semaphore.h> 42#include <asm/semaphore.h>
42#include <asm/cacheflush.h> 43#include <asm/cacheflush.h>