diff options
author | Jeff Garzik <jeff@garzik.org> | 2006-06-22 22:11:56 -0400 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2006-06-22 22:11:56 -0400 |
commit | 71d530cd1b6d97094481002a04c77fea1c8e1c22 (patch) | |
tree | e786da7145d83c19a594adf76ed90d52c51058b1 /include | |
parent | d7a80dad2fe19a2b8c119c8e9cba605474a75a2b (diff) | |
parent | d588fcbe5a7ba8bba2cebf7799ab2d573717a806 (diff) |
Merge branch 'master' into upstream
Conflicts:
drivers/scsi/libata-core.c
drivers/scsi/libata-scsi.c
include/linux/pci_ids.h
Diffstat (limited to 'include')
1122 files changed, 8135 insertions, 3496 deletions
diff --git a/include/acpi/platform/aclinux.h b/include/acpi/platform/aclinux.h index 2e6d54569ee8..3c6a6205853a 100644 --- a/include/acpi/platform/aclinux.h +++ b/include/acpi/platform/aclinux.h | |||
@@ -49,7 +49,6 @@ | |||
49 | 49 | ||
50 | #ifdef __KERNEL__ | 50 | #ifdef __KERNEL__ |
51 | 51 | ||
52 | #include <linux/config.h> | ||
53 | #include <linux/string.h> | 52 | #include <linux/string.h> |
54 | #include <linux/kernel.h> | 53 | #include <linux/kernel.h> |
55 | #include <linux/ctype.h> | 54 | #include <linux/ctype.h> |
diff --git a/include/acpi/processor.h b/include/acpi/processor.h index badf0277b1be..ef7d83a41470 100644 --- a/include/acpi/processor.h +++ b/include/acpi/processor.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define __ACPI_PROCESSOR_H | 2 | #define __ACPI_PROCESSOR_H |
3 | 3 | ||
4 | #include <linux/kernel.h> | 4 | #include <linux/kernel.h> |
5 | #include <linux/config.h> | ||
6 | 5 | ||
7 | #include <asm/acpi.h> | 6 | #include <asm/acpi.h> |
8 | 7 | ||
diff --git a/include/asm-alpha/bitops.h b/include/asm-alpha/bitops.h index 3f88715e811e..4b6ef7f21b93 100644 --- a/include/asm-alpha/bitops.h +++ b/include/asm-alpha/bitops.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ALPHA_BITOPS_H | 1 | #ifndef _ALPHA_BITOPS_H |
2 | #define _ALPHA_BITOPS_H | 2 | #define _ALPHA_BITOPS_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/compiler.h> | 4 | #include <asm/compiler.h> |
6 | 5 | ||
7 | /* | 6 | /* |
diff --git a/include/asm-alpha/cache.h b/include/asm-alpha/cache.h index e6d4d1695e25..f199e69a5d0b 100644 --- a/include/asm-alpha/cache.h +++ b/include/asm-alpha/cache.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #ifndef __ARCH_ALPHA_CACHE_H | 4 | #ifndef __ARCH_ALPHA_CACHE_H |
5 | #define __ARCH_ALPHA_CACHE_H | 5 | #define __ARCH_ALPHA_CACHE_H |
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | /* Bytes per L1 (data) cache line. */ | 8 | /* Bytes per L1 (data) cache line. */ |
10 | #if defined(CONFIG_ALPHA_GENERIC) || defined(CONFIG_ALPHA_EV6) | 9 | #if defined(CONFIG_ALPHA_GENERIC) || defined(CONFIG_ALPHA_EV6) |
diff --git a/include/asm-alpha/cacheflush.h b/include/asm-alpha/cacheflush.h index 3fc6ef726d8c..805640b41078 100644 --- a/include/asm-alpha/cacheflush.h +++ b/include/asm-alpha/cacheflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ALPHA_CACHEFLUSH_H | 1 | #ifndef _ALPHA_CACHEFLUSH_H |
2 | #define _ALPHA_CACHEFLUSH_H | 2 | #define _ALPHA_CACHEFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | 5 | ||
7 | /* Caches aren't brain-dead on the Alpha. */ | 6 | /* Caches aren't brain-dead on the Alpha. */ |
diff --git a/include/asm-alpha/core_cia.h b/include/asm-alpha/core_cia.h index 3a70d68bfce8..9e0516c0ca27 100644 --- a/include/asm-alpha/core_cia.h +++ b/include/asm-alpha/core_cia.h | |||
@@ -4,7 +4,6 @@ | |||
4 | /* Define to experiment with fitting everything into one 512MB HAE window. */ | 4 | /* Define to experiment with fitting everything into one 512MB HAE window. */ |
5 | #define CIA_ONE_HAE_WINDOW 1 | 5 | #define CIA_ONE_HAE_WINDOW 1 |
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | #include <linux/types.h> | 7 | #include <linux/types.h> |
9 | #include <asm/compiler.h> | 8 | #include <asm/compiler.h> |
10 | 9 | ||
diff --git a/include/asm-alpha/core_t2.h b/include/asm-alpha/core_t2.h index 5c1c40338c82..dba70c62a16c 100644 --- a/include/asm-alpha/core_t2.h +++ b/include/asm-alpha/core_t2.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ALPHA_T2__H__ | 1 | #ifndef __ALPHA_T2__H__ |
2 | #define __ALPHA_T2__H__ | 2 | #define __ALPHA_T2__H__ |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/types.h> | 4 | #include <linux/types.h> |
6 | #include <linux/spinlock.h> | 5 | #include <linux/spinlock.h> |
7 | #include <asm/compiler.h> | 6 | #include <asm/compiler.h> |
diff --git a/include/asm-alpha/dma-mapping.h b/include/asm-alpha/dma-mapping.h index 62d0d6681aa9..b9ff4d8cb33a 100644 --- a/include/asm-alpha/dma-mapping.h +++ b/include/asm-alpha/dma-mapping.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ALPHA_DMA_MAPPING_H | 1 | #ifndef _ALPHA_DMA_MAPPING_H |
2 | #define _ALPHA_DMA_MAPPING_H | 2 | #define _ALPHA_DMA_MAPPING_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_PCI | 5 | #ifdef CONFIG_PCI |
7 | 6 | ||
diff --git a/include/asm-alpha/dma.h b/include/asm-alpha/dma.h index 683afaa3deed..87cfdbdf08fc 100644 --- a/include/asm-alpha/dma.h +++ b/include/asm-alpha/dma.h | |||
@@ -18,7 +18,6 @@ | |||
18 | #ifndef _ASM_DMA_H | 18 | #ifndef _ASM_DMA_H |
19 | #define _ASM_DMA_H | 19 | #define _ASM_DMA_H |
20 | 20 | ||
21 | #include <linux/config.h> | ||
22 | #include <linux/spinlock.h> | 21 | #include <linux/spinlock.h> |
23 | #include <asm/io.h> | 22 | #include <asm/io.h> |
24 | 23 | ||
diff --git a/include/asm-alpha/floppy.h b/include/asm-alpha/floppy.h index 289a00d51a90..e177d4180f83 100644 --- a/include/asm-alpha/floppy.h +++ b/include/asm-alpha/floppy.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef __ASM_ALPHA_FLOPPY_H | 10 | #ifndef __ASM_ALPHA_FLOPPY_H |
11 | #define __ASM_ALPHA_FLOPPY_H | 11 | #define __ASM_ALPHA_FLOPPY_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | #define fd_inb(port) inb_p(port) | 14 | #define fd_inb(port) inb_p(port) |
16 | #define fd_outb(value,port) outb_p(value,port) | 15 | #define fd_outb(value,port) outb_p(value,port) |
diff --git a/include/asm-alpha/hardirq.h b/include/asm-alpha/hardirq.h index 7bb6a36c96a1..d953e234daa8 100644 --- a/include/asm-alpha/hardirq.h +++ b/include/asm-alpha/hardirq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ALPHA_HARDIRQ_H | 1 | #ifndef _ALPHA_HARDIRQ_H |
2 | #define _ALPHA_HARDIRQ_H | 2 | #define _ALPHA_HARDIRQ_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/threads.h> | 4 | #include <linux/threads.h> |
6 | #include <linux/cache.h> | 5 | #include <linux/cache.h> |
7 | 6 | ||
diff --git a/include/asm-alpha/hw_irq.h b/include/asm-alpha/hw_irq.h index a310b9efc906..ca9d43b63502 100644 --- a/include/asm-alpha/hw_irq.h +++ b/include/asm-alpha/hw_irq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ALPHA_HW_IRQ_H | 1 | #ifndef _ALPHA_HW_IRQ_H |
2 | #define _ALPHA_HW_IRQ_H | 2 | #define _ALPHA_HW_IRQ_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i) {} | 5 | static inline void hw_resend_irq(struct hw_interrupt_type *h, unsigned int i) {} |
7 | 6 | ||
diff --git a/include/asm-alpha/ide.h b/include/asm-alpha/ide.h index 6126afe27380..2a5cc0b367ab 100644 --- a/include/asm-alpha/ide.h +++ b/include/asm-alpha/ide.h | |||
@@ -13,7 +13,6 @@ | |||
13 | 13 | ||
14 | #ifdef __KERNEL__ | 14 | #ifdef __KERNEL__ |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | #define IDE_ARCH_OBSOLETE_DEFAULTS | 17 | #define IDE_ARCH_OBSOLETE_DEFAULTS |
19 | 18 | ||
diff --git a/include/asm-alpha/io.h b/include/asm-alpha/io.h index 3ebbeee753e9..f5ae98c25d1f 100644 --- a/include/asm-alpha/io.h +++ b/include/asm-alpha/io.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <linux/kernel.h> | 6 | #include <linux/kernel.h> |
8 | #include <asm/compiler.h> | 7 | #include <asm/compiler.h> |
9 | #include <asm/system.h> | 8 | #include <asm/system.h> |
diff --git a/include/asm-alpha/irq.h b/include/asm-alpha/irq.h index 566db720000a..f6de033718a0 100644 --- a/include/asm-alpha/irq.h +++ b/include/asm-alpha/irq.h | |||
@@ -8,7 +8,6 @@ | |||
8 | */ | 8 | */ |
9 | 9 | ||
10 | #include <linux/linkage.h> | 10 | #include <linux/linkage.h> |
11 | #include <linux/config.h> | ||
12 | 11 | ||
13 | #if defined(CONFIG_ALPHA_GENERIC) | 12 | #if defined(CONFIG_ALPHA_GENERIC) |
14 | 13 | ||
diff --git a/include/asm-alpha/kmap_types.h b/include/asm-alpha/kmap_types.h index 3d10cd3ea75f..3e6735a34c57 100644 --- a/include/asm-alpha/kmap_types.h +++ b/include/asm-alpha/kmap_types.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | /* Dummy header just to define km_type. */ | 4 | /* Dummy header just to define km_type. */ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | #ifdef CONFIG_DEBUG_HIGHMEM | 7 | #ifdef CONFIG_DEBUG_HIGHMEM |
9 | # define D(n) __KM_FENCE_##n , | 8 | # define D(n) __KM_FENCE_##n , |
diff --git a/include/asm-alpha/machvec.h b/include/asm-alpha/machvec.h index ece166a203ec..aced22f91752 100644 --- a/include/asm-alpha/machvec.h +++ b/include/asm-alpha/machvec.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ALPHA_MACHVEC_H | 1 | #ifndef __ALPHA_MACHVEC_H |
2 | #define __ALPHA_MACHVEC_H 1 | 2 | #define __ALPHA_MACHVEC_H 1 |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/types.h> | 4 | #include <linux/types.h> |
6 | 5 | ||
7 | /* | 6 | /* |
diff --git a/include/asm-alpha/mmu_context.h b/include/asm-alpha/mmu_context.h index 0c017fc181c1..fe249e9d3360 100644 --- a/include/asm-alpha/mmu_context.h +++ b/include/asm-alpha/mmu_context.h | |||
@@ -7,7 +7,6 @@ | |||
7 | * Copyright (C) 1996, Linus Torvalds | 7 | * Copyright (C) 1996, Linus Torvalds |
8 | */ | 8 | */ |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <asm/system.h> | 10 | #include <asm/system.h> |
12 | #include <asm/machvec.h> | 11 | #include <asm/machvec.h> |
13 | #include <asm/compiler.h> | 12 | #include <asm/compiler.h> |
diff --git a/include/asm-alpha/mmzone.h b/include/asm-alpha/mmzone.h index 192d80c875b0..64d0ab98fcd8 100644 --- a/include/asm-alpha/mmzone.h +++ b/include/asm-alpha/mmzone.h | |||
@@ -5,7 +5,6 @@ | |||
5 | #ifndef _ASM_MMZONE_H_ | 5 | #ifndef _ASM_MMZONE_H_ |
6 | #define _ASM_MMZONE_H_ | 6 | #define _ASM_MMZONE_H_ |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | #include <asm/smp.h> | 8 | #include <asm/smp.h> |
10 | 9 | ||
11 | struct bootmem_data_t; /* stupid forward decl. */ | 10 | struct bootmem_data_t; /* stupid forward decl. */ |
diff --git a/include/asm-alpha/page.h b/include/asm-alpha/page.h index 61bcf70b5eac..8c7cd50d4eae 100644 --- a/include/asm-alpha/page.h +++ b/include/asm-alpha/page.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ALPHA_PAGE_H | 1 | #ifndef _ALPHA_PAGE_H |
2 | #define _ALPHA_PAGE_H | 2 | #define _ALPHA_PAGE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/pal.h> | 4 | #include <asm/pal.h> |
6 | 5 | ||
7 | /* PAGE_SHIFT determines the page size */ | 6 | /* PAGE_SHIFT determines the page size */ |
diff --git a/include/asm-alpha/param.h b/include/asm-alpha/param.h index 3ed0b3b02e52..214e7996346f 100644 --- a/include/asm-alpha/param.h +++ b/include/asm-alpha/param.h | |||
@@ -5,7 +5,6 @@ | |||
5 | hardware ignores reprogramming. We also need userland buy-in to the | 5 | hardware ignores reprogramming. We also need userland buy-in to the |
6 | change in HZ, since this is visible in the wait4 resources etc. */ | 6 | change in HZ, since this is visible in the wait4 resources etc. */ |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | 8 | ||
10 | #ifndef HZ | 9 | #ifndef HZ |
11 | # ifndef CONFIG_ALPHA_RAWHIDE | 10 | # ifndef CONFIG_ALPHA_RAWHIDE |
diff --git a/include/asm-alpha/pgalloc.h b/include/asm-alpha/pgalloc.h index 308475642913..471864e8d4c3 100644 --- a/include/asm-alpha/pgalloc.h +++ b/include/asm-alpha/pgalloc.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ALPHA_PGALLOC_H | 1 | #ifndef _ALPHA_PGALLOC_H |
2 | #define _ALPHA_PGALLOC_H | 2 | #define _ALPHA_PGALLOC_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | #include <linux/mmzone.h> | 5 | #include <linux/mmzone.h> |
7 | 6 | ||
diff --git a/include/asm-alpha/pgtable.h b/include/asm-alpha/pgtable.h index a985cd29b6db..93eaa58b7961 100644 --- a/include/asm-alpha/pgtable.h +++ b/include/asm-alpha/pgtable.h | |||
@@ -10,7 +10,6 @@ | |||
10 | * This hopefully works with any standard Alpha page-size, as defined | 10 | * This hopefully works with any standard Alpha page-size, as defined |
11 | * in <asm/page.h> (currently 8192). | 11 | * in <asm/page.h> (currently 8192). |
12 | */ | 12 | */ |
13 | #include <linux/config.h> | ||
14 | #include <linux/mmzone.h> | 13 | #include <linux/mmzone.h> |
15 | 14 | ||
16 | #include <asm/page.h> | 15 | #include <asm/page.h> |
diff --git a/include/asm-alpha/serial.h b/include/asm-alpha/serial.h index 7e4b2987d453..9d263e8d8ccc 100644 --- a/include/asm-alpha/serial.h +++ b/include/asm-alpha/serial.h | |||
@@ -2,7 +2,6 @@ | |||
2 | * include/asm-alpha/serial.h | 2 | * include/asm-alpha/serial.h |
3 | */ | 3 | */ |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | 5 | ||
7 | /* | 6 | /* |
8 | * This assumes you have a 1.8432 MHz clock for your UART. | 7 | * This assumes you have a 1.8432 MHz clock for your UART. |
diff --git a/include/asm-alpha/smp.h b/include/asm-alpha/smp.h index e1432102be05..a1a1eca6be45 100644 --- a/include/asm-alpha/smp.h +++ b/include/asm-alpha/smp.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_SMP_H | 1 | #ifndef __ASM_SMP_H |
2 | #define __ASM_SMP_H | 2 | #define __ASM_SMP_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/threads.h> | 4 | #include <linux/threads.h> |
6 | #include <linux/cpumask.h> | 5 | #include <linux/cpumask.h> |
7 | #include <linux/bitops.h> | 6 | #include <linux/bitops.h> |
diff --git a/include/asm-alpha/spinlock.h b/include/asm-alpha/spinlock.h index 8197c69eff44..0c294c9b0c55 100644 --- a/include/asm-alpha/spinlock.h +++ b/include/asm-alpha/spinlock.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ALPHA_SPINLOCK_H | 1 | #ifndef _ALPHA_SPINLOCK_H |
2 | #define _ALPHA_SPINLOCK_H | 2 | #define _ALPHA_SPINLOCK_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/system.h> | 4 | #include <asm/system.h> |
6 | #include <linux/kernel.h> | 5 | #include <linux/kernel.h> |
7 | #include <asm/current.h> | 6 | #include <asm/current.h> |
diff --git a/include/asm-alpha/system.h b/include/asm-alpha/system.h index f3b7b1a59c56..03e9c0e5ed74 100644 --- a/include/asm-alpha/system.h +++ b/include/asm-alpha/system.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ALPHA_SYSTEM_H | 1 | #ifndef __ALPHA_SYSTEM_H |
2 | #define __ALPHA_SYSTEM_H | 2 | #define __ALPHA_SYSTEM_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/pal.h> | 4 | #include <asm/pal.h> |
6 | #include <asm/page.h> | 5 | #include <asm/page.h> |
7 | #include <asm/barrier.h> | 6 | #include <asm/barrier.h> |
diff --git a/include/asm-alpha/tlbflush.h b/include/asm-alpha/tlbflush.h index 9d484c1fdc82..1ca3ed3bd6d3 100644 --- a/include/asm-alpha/tlbflush.h +++ b/include/asm-alpha/tlbflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ALPHA_TLBFLUSH_H | 1 | #ifndef _ALPHA_TLBFLUSH_H |
2 | #define _ALPHA_TLBFLUSH_H | 2 | #define _ALPHA_TLBFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | #include <asm/compiler.h> | 5 | #include <asm/compiler.h> |
7 | 6 | ||
diff --git a/include/asm-alpha/unistd.h b/include/asm-alpha/unistd.h index ef25b6585119..bc6e6a9259dc 100644 --- a/include/asm-alpha/unistd.h +++ b/include/asm-alpha/unistd.h | |||
@@ -383,6 +383,8 @@ | |||
383 | #define __NR_inotify_add_watch 445 | 383 | #define __NR_inotify_add_watch 445 |
384 | #define __NR_inotify_rm_watch 446 | 384 | #define __NR_inotify_rm_watch 446 |
385 | 385 | ||
386 | #ifdef __KERNEL__ | ||
387 | |||
386 | #define NR_SYSCALLS 447 | 388 | #define NR_SYSCALLS 447 |
387 | 389 | ||
388 | #if defined(__GNUC__) | 390 | #if defined(__GNUC__) |
@@ -565,9 +567,8 @@ type name (type1 arg1,type2 arg2,type3 arg3,type4 arg4,type5 arg5, type6 arg6)\ | |||
565 | _syscall_return(type); \ | 567 | _syscall_return(type); \ |
566 | } | 568 | } |
567 | 569 | ||
568 | #endif /* __LIBRARY__ && __GNUC__ */ | 570 | #endif /* __GNUC__ */ |
569 | 571 | ||
570 | #ifdef __KERNEL__ | ||
571 | #define __ARCH_WANT_IPC_PARSE_VERSION | 572 | #define __ARCH_WANT_IPC_PARSE_VERSION |
572 | #define __ARCH_WANT_OLD_READDIR | 573 | #define __ARCH_WANT_OLD_READDIR |
573 | #define __ARCH_WANT_STAT64 | 574 | #define __ARCH_WANT_STAT64 |
@@ -578,7 +579,6 @@ type name (type1 arg1,type2 arg2,type3 arg3,type4 arg4,type5 arg5, type6 arg6)\ | |||
578 | #define __ARCH_WANT_SYS_OLD_GETRLIMIT | 579 | #define __ARCH_WANT_SYS_OLD_GETRLIMIT |
579 | #define __ARCH_WANT_SYS_OLDUMOUNT | 580 | #define __ARCH_WANT_SYS_OLDUMOUNT |
580 | #define __ARCH_WANT_SYS_SIGPENDING | 581 | #define __ARCH_WANT_SYS_SIGPENDING |
581 | #endif | ||
582 | 582 | ||
583 | #ifdef __KERNEL_SYSCALLS__ | 583 | #ifdef __KERNEL_SYSCALLS__ |
584 | 584 | ||
@@ -661,4 +661,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
661 | 661 | ||
662 | #define cond_syscall(x) asm(".weak\t" #x "\n" #x " = sys_ni_syscall") | 662 | #define cond_syscall(x) asm(".weak\t" #x "\n" #x " = sys_ni_syscall") |
663 | 663 | ||
664 | #endif /* __KERNEL__ */ | ||
664 | #endif /* _ALPHA_UNISTD_H */ | 665 | #endif /* _ALPHA_UNISTD_H */ |
diff --git a/include/asm-alpha/vga.h b/include/asm-alpha/vga.h index 8ca4f6b2da19..ed06f59b544d 100644 --- a/include/asm-alpha/vga.h +++ b/include/asm-alpha/vga.h | |||
@@ -46,6 +46,6 @@ extern void scr_memcpyw(u16 *d, const u16 *s, unsigned int count); | |||
46 | #define vga_readb(a) readb((u8 __iomem *)(a)) | 46 | #define vga_readb(a) readb((u8 __iomem *)(a)) |
47 | #define vga_writeb(v,a) writeb(v, (u8 __iomem *)(a)) | 47 | #define vga_writeb(v,a) writeb(v, (u8 __iomem *)(a)) |
48 | 48 | ||
49 | #define VGA_MAP_MEM(x) ((unsigned long) ioremap(x, 0)) | 49 | #define VGA_MAP_MEM(x,s) ((unsigned long) ioremap(x, s)) |
50 | 50 | ||
51 | #endif | 51 | #endif |
diff --git a/include/asm-arm/apm.h b/include/asm-arm/apm.h index 3a50eb759c28..d09113b37e4a 100644 --- a/include/asm-arm/apm.h +++ b/include/asm-arm/apm.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef ARM_ASM_SA1100_APM_H | 13 | #ifndef ARM_ASM_SA1100_APM_H |
14 | #define ARM_ASM_SA1100_APM_H | 14 | #define ARM_ASM_SA1100_APM_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/apm_bios.h> | 16 | #include <linux/apm_bios.h> |
18 | 17 | ||
19 | /* | 18 | /* |
diff --git a/include/asm-arm/arch-aaec2000/memory.h b/include/asm-arm/arch-aaec2000/memory.h index d8209f8911d6..24b51cccde8f 100644 --- a/include/asm-arm/arch-aaec2000/memory.h +++ b/include/asm-arm/arch-aaec2000/memory.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef __ASM_ARCH_MEMORY_H | 11 | #ifndef __ASM_ARCH_MEMORY_H |
12 | #define __ASM_ARCH_MEMORY_H | 12 | #define __ASM_ARCH_MEMORY_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | #define PHYS_OFFSET UL(0xf0000000) | 15 | #define PHYS_OFFSET UL(0xf0000000) |
17 | 16 | ||
diff --git a/include/asm-arm/arch-at91rm9200/at91rm9200_spi.h b/include/asm-arm/arch-at91rm9200/at91rm9200_spi.h new file mode 100644 index 000000000000..bff5ea45f604 --- /dev/null +++ b/include/asm-arm/arch-at91rm9200/at91rm9200_spi.h | |||
@@ -0,0 +1,81 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-at91rm9200/at91rm9200_spi.h | ||
3 | * | ||
4 | * Copyright (C) 2005 Ivan Kokshaysky | ||
5 | * Copyright (C) SAN People | ||
6 | * | ||
7 | * Serial Peripheral Interface (SPI) registers. | ||
8 | * Based on AT91RM9200 datasheet revision E. | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify | ||
11 | * it under the terms of the GNU General Public License as published by | ||
12 | * the Free Software Foundation; either version 2 of the License, or | ||
13 | * (at your option) any later version. | ||
14 | */ | ||
15 | |||
16 | #ifndef AT91RM9200_SPI_H | ||
17 | #define AT91RM9200_SPI_H | ||
18 | |||
19 | #define AT91_SPI_CR 0x00 /* Control Register */ | ||
20 | #define AT91_SPI_SPIEN (1 << 0) /* SPI Enable */ | ||
21 | #define AT91_SPI_SPIDIS (1 << 1) /* SPI Disable */ | ||
22 | #define AT91_SPI_SWRST (1 << 7) /* SPI Software Reset */ | ||
23 | #define AT91_SPI_LASTXFER (1 << 24) /* Last Transfer [SAM9261 only] */ | ||
24 | |||
25 | #define AT91_SPI_MR 0x04 /* Mode Register */ | ||
26 | #define AT91_SPI_MSTR (1 << 0) /* Master/Slave Mode */ | ||
27 | #define AT91_SPI_PS (1 << 1) /* Peripheral Select */ | ||
28 | #define AT91_SPI_PS_FIXED (0 << 1) | ||
29 | #define AT91_SPI_PS_VARIABLE (1 << 1) | ||
30 | #define AT91_SPI_PCSDEC (1 << 2) /* Chip Select Decode */ | ||
31 | #define AT91_SPI_DIV32 (1 << 3) /* Clock Selection */ | ||
32 | #define AT91_SPI_MODFDIS (1 << 4) /* Mode Fault Detection */ | ||
33 | #define AT91_SPI_LLB (1 << 7) /* Local Loopback Enable */ | ||
34 | #define AT91_SPI_PCS (0xf << 16) /* Peripheral Chip Select */ | ||
35 | #define AT91_SPI_DLYBCS (0xff << 24) /* Delay Between Chip Selects */ | ||
36 | |||
37 | #define AT91_SPI_RDR 0x08 /* Receive Data Register */ | ||
38 | #define AT91_SPI_RD (0xffff << 0) /* Receive Data */ | ||
39 | #define AT91_SPI_PCS (0xf << 16) /* Peripheral Chip Select */ | ||
40 | |||
41 | #define AT91_SPI_TDR 0x0c /* Transmit Data Register */ | ||
42 | #define AT91_SPI_TD (0xffff << 0) /* Transmit Data */ | ||
43 | #define AT91_SPI_PCS (0xf << 16) /* Peripheral Chip Select */ | ||
44 | #define AT91_SPI_LASTXFER (1 << 24) /* Last Transfer [SAM9261 only] */ | ||
45 | |||
46 | #define AT91_SPI_SR 0x10 /* Status Register */ | ||
47 | #define AT91_SPI_RDRF (1 << 0) /* Receive Data Register Full */ | ||
48 | #define AT91_SPI_TDRE (1 << 1) /* Transmit Data Register Full */ | ||
49 | #define AT91_SPI_MODF (1 << 2) /* Mode Fault Error */ | ||
50 | #define AT91_SPI_OVRES (1 << 3) /* Overrun Error Status */ | ||
51 | #define AT91_SPI_ENDRX (1 << 4) /* End of RX buffer */ | ||
52 | #define AT91_SPI_ENDTX (1 << 5) /* End of TX buffer */ | ||
53 | #define AT91_SPI_RXBUFF (1 << 6) /* RX Buffer Full */ | ||
54 | #define AT91_SPI_TXBUFE (1 << 7) /* TX Buffer Empty */ | ||
55 | #define AT91_SPI_NSSR (1 << 8) /* NSS Rising [SAM9261 only] */ | ||
56 | #define AT91_SPI_TXEMPTY (1 << 9) /* Transmission Register Empty [SAM9261 only] */ | ||
57 | #define AT91_SPI_SPIENS (1 << 16) /* SPI Enable Status */ | ||
58 | |||
59 | #define AT91_SPI_IER 0x14 /* Interrupt Enable Register */ | ||
60 | #define AT91_SPI_IDR 0x18 /* Interrupt Disable Register */ | ||
61 | #define AT91_SPI_IMR 0x1c /* Interrupt Mask Register */ | ||
62 | |||
63 | #define AT91_SPI_CSR(n) (0x30 + ((n) * 4)) /* Chip Select Registers 0-3 */ | ||
64 | #define AT91_SPI_CPOL (1 << 0) /* Clock Polarity */ | ||
65 | #define AT91_SPI_NCPHA (1 << 1) /* Clock Phase */ | ||
66 | #define AT91_SPI_CSAAT (1 << 3) /* Chip Select Active After Transfer [SAM9261 only] */ | ||
67 | #define AT91_SPI_BITS (0xf << 4) /* Bits Per Transfer */ | ||
68 | #define AT91_SPI_BITS_8 (0 << 4) | ||
69 | #define AT91_SPI_BITS_9 (1 << 4) | ||
70 | #define AT91_SPI_BITS_10 (2 << 4) | ||
71 | #define AT91_SPI_BITS_11 (3 << 4) | ||
72 | #define AT91_SPI_BITS_12 (4 << 4) | ||
73 | #define AT91_SPI_BITS_13 (5 << 4) | ||
74 | #define AT91_SPI_BITS_14 (6 << 4) | ||
75 | #define AT91_SPI_BITS_15 (7 << 4) | ||
76 | #define AT91_SPI_BITS_16 (8 << 4) | ||
77 | #define AT91_SPI_SCBR (0xff << 8) /* Serial Clock Baud Rate */ | ||
78 | #define AT91_SPI_DLYBS (0xff << 16) /* Delay before SPCK */ | ||
79 | #define AT91_SPI_DLYBCT (0xff << 24) /* Delay between Consecutive Transfers */ | ||
80 | |||
81 | #endif | ||
diff --git a/include/asm-arm/arch-at91rm9200/at91rm9200_ssc.h b/include/asm-arm/arch-at91rm9200/at91rm9200_ssc.h new file mode 100644 index 000000000000..ac880227147f --- /dev/null +++ b/include/asm-arm/arch-at91rm9200/at91rm9200_ssc.h | |||
@@ -0,0 +1,96 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-at91rm9200/at91rm9200_ssc.h | ||
3 | * | ||
4 | * Copyright (C) SAN People | ||
5 | * | ||
6 | * Serial Synchronous Controller (SSC) registers. | ||
7 | * Based on AT91RM9200 datasheet revision E. | ||
8 | * | ||
9 | * This program is free software; you can redistribute it and/or modify | ||
10 | * it under the terms of the GNU General Public License as published by | ||
11 | * the Free Software Foundation; either version 2 of the License, or | ||
12 | * (at your option) any later version. | ||
13 | */ | ||
14 | |||
15 | #ifndef AT91RM9200_SSC_H | ||
16 | #define AT91RM9200_SSC_H | ||
17 | |||
18 | #define AT91_SSC_CR 0x00 /* Control Register */ | ||
19 | #define AT91_SSC_RXEN (1 << 0) /* Receive Enable */ | ||
20 | #define AT91_SSC_RXDIS (1 << 1) /* Receive Disable */ | ||
21 | #define AT91_SSC_TXEN (1 << 8) /* Transmit Enable */ | ||
22 | #define AT91_SSC_TXDIS (1 << 9) /* Transmit Disable */ | ||
23 | #define AT91_SSC_SWRST (1 << 15) /* Software Reset */ | ||
24 | |||
25 | #define AT91_SSC_CMR 0x04 /* Clock Mode Register */ | ||
26 | #define AT91_SSC_CMR_DIV (0xfff << 0) /* Clock Divider */ | ||
27 | |||
28 | #define AT91_SSC_RCMR 0x10 /* Receive Clock Mode Register */ | ||
29 | #define AT91_SSC_CKS (3 << 0) /* Clock Selection */ | ||
30 | #define AT91_SSC_CKS_DIV (0 << 0) | ||
31 | #define AT91_SSC_CKS_CLOCK (1 << 0) | ||
32 | #define AT91_SSC_CKS_PIN (2 << 0) | ||
33 | #define AT91_SSC_CKO (7 << 2) /* Clock Output Mode Selection */ | ||
34 | #define AT91_SSC_CKO_NONE (0 << 2) | ||
35 | #define AT91_SSC_CKO_CONTINUOUS (1 << 2) | ||
36 | #define AT91_SSC_CKI (1 << 5) /* Clock Inversion */ | ||
37 | #define AT91_SSC_CKI_FALLING (0 << 5) | ||
38 | #define AT91_SSC_CK_RISING (1 << 5) | ||
39 | #define AT91_SSC_START (0xf << 8) /* Start Selection */ | ||
40 | #define AT91_SSC_START_CONTINUOUS (0 << 8) | ||
41 | #define AT91_SSC_START_TX_RX (1 << 8) | ||
42 | #define AT91_SSC_START_LOW_RF (2 << 8) | ||
43 | #define AT91_SSC_START_HIGH_RF (3 << 8) | ||
44 | #define AT91_SSC_START_FALLING_RF (4 << 8) | ||
45 | #define AT91_SSC_START_RISING_RF (5 << 8) | ||
46 | #define AT91_SSC_START_LEVEL_RF (6 << 8) | ||
47 | #define AT91_SSC_START_EDGE_RF (7 << 8) | ||
48 | #define AT91_SSC_STTDLY (0xff << 16) /* Start Delay */ | ||
49 | #define AT91_SSC_PERIOD (0xff << 24) /* Period Divider Selection */ | ||
50 | |||
51 | #define AT91_SSC_RFMR 0x14 /* Receive Frame Mode Register */ | ||
52 | #define AT91_SSC_DATALEN (0x1f << 0) /* Data Length */ | ||
53 | #define AT91_SSC_LOOP (1 << 5) /* Loop Mode */ | ||
54 | #define AT91_SSC_MSBF (1 << 7) /* Most Significant Bit First */ | ||
55 | #define AT91_SSC_DATNB (0xf << 8) /* Data Number per Frame */ | ||
56 | #define AT91_SSC_FSLEN (0xf << 16) /* Frame Sync Length */ | ||
57 | #define AT91_SSC_FSOS (7 << 20) /* Frame Sync Output Selection */ | ||
58 | #define AT91_SSC_FSOS_NONE (0 << 20) | ||
59 | #define AT91_SSC_FSOS_NEGATIVE (1 << 20) | ||
60 | #define AT91_SSC_FSOS_POSITIVE (2 << 20) | ||
61 | #define AT91_SSC_FSOS_LOW (3 << 20) | ||
62 | #define AT91_SSC_FSOS_HIGH (4 << 20) | ||
63 | #define AT91_SSC_FSOS_TOGGLE (5 << 20) | ||
64 | #define AT91_SSC_FSEDGE (1 << 24) /* Frame Sync Edge Detection */ | ||
65 | #define AT91_SSC_FSEDGE_POSITIVE (0 << 24) | ||
66 | #define AT91_SSC_FSEDGE_NEGATIVE (1 << 24) | ||
67 | |||
68 | #define AT91_SSC_TCMR 0x18 /* Transmit Clock Mode Register */ | ||
69 | #define AT91_SSC_TFMR 0x1c /* Transmit Fram Mode Register */ | ||
70 | #define AT91_SSC_DATDEF (1 << 5) /* Data Default Value */ | ||
71 | #define AT91_SSC_FSDEN (1 << 23) /* Frame Sync Data Enable */ | ||
72 | |||
73 | #define AT91_SSC_RHR 0x20 /* Receive Holding Register */ | ||
74 | #define AT91_SSC_THR 0x24 /* Transmit Holding Register */ | ||
75 | #define AT91_SSC_RSHR 0x30 /* Receive Sync Holding Register */ | ||
76 | #define AT91_SSC_TSHR 0x34 /* Transmit Sync Holding Register */ | ||
77 | |||
78 | #define AT91_SSC_SR 0x40 /* Status Register */ | ||
79 | #define AT91_SSC_TXRDY (1 << 0) /* Transmit Ready */ | ||
80 | #define AT91_SSC_TXEMPTY (1 << 1) /* Transmit Empty */ | ||
81 | #define AT91_SSC_ENDTX (1 << 2) /* End of Transmission */ | ||
82 | #define AT91_SSC_TXBUFE (1 << 3) /* Transmit Buffer Empty */ | ||
83 | #define AT91_SSC_RXRDY (1 << 4) /* Receive Ready */ | ||
84 | #define AT91_SSC_OVRUN (1 << 5) /* Receive Overrun */ | ||
85 | #define AT91_SSC_ENDRX (1 << 6) /* End of Reception */ | ||
86 | #define AT91_SSC_RXBUFF (1 << 7) /* Receive Buffer Full */ | ||
87 | #define AT91_SSC_TXSYN (1 << 10) /* Transmit Sync */ | ||
88 | #define AT91_SSC_RXSYN (1 << 11) /* Receive Sync */ | ||
89 | #define AT91_SSC_TXENA (1 << 16) /* Transmit Enable */ | ||
90 | #define AT91_SSC_RXENA (1 << 17) /* Receive Enable */ | ||
91 | |||
92 | #define AT91_SSC_IER 0x44 /* Interrupt Enable Register */ | ||
93 | #define AT91_SSC_IDR 0x48 /* Interrupt Disable Register */ | ||
94 | #define AT91_SSC_IMR 0x4c /* Interrupt Mask Register */ | ||
95 | |||
96 | #endif | ||
diff --git a/include/asm-arm/arch-at91rm9200/at91rm9200_sys.h b/include/asm-arm/arch-at91rm9200/at91rm9200_sys.h index 2910d359f919..0f4c12d5f0cd 100644 --- a/include/asm-arm/arch-at91rm9200/at91rm9200_sys.h +++ b/include/asm-arm/arch-at91rm9200/at91rm9200_sys.h | |||
@@ -68,8 +68,17 @@ | |||
68 | #define AT91_DBGU_RHR (AT91_DBGU + 0x18) /* Receiver Holding Register */ | 68 | #define AT91_DBGU_RHR (AT91_DBGU + 0x18) /* Receiver Holding Register */ |
69 | #define AT91_DBGU_THR (AT91_DBGU + 0x1c) /* Transmitter Holding Register */ | 69 | #define AT91_DBGU_THR (AT91_DBGU + 0x1c) /* Transmitter Holding Register */ |
70 | #define AT91_DBGU_BRGR (AT91_DBGU + 0x20) /* Baud Rate Generator Register */ | 70 | #define AT91_DBGU_BRGR (AT91_DBGU + 0x20) /* Baud Rate Generator Register */ |
71 | |||
71 | #define AT91_DBGU_CIDR (AT91_DBGU + 0x40) /* Chip ID Register */ | 72 | #define AT91_DBGU_CIDR (AT91_DBGU + 0x40) /* Chip ID Register */ |
72 | #define AT91_DBGU_EXID (AT91_DBGU + 0x44) /* Chip ID Extension Register */ | 73 | #define AT91_DBGU_EXID (AT91_DBGU + 0x44) /* Chip ID Extension Register */ |
74 | #define AT91_CIDR_VERSION (0x1f << 0) /* Version of the Device */ | ||
75 | #define AT91_CIDR_EPROC (7 << 5) /* Embedded Processor */ | ||
76 | #define AT91_CIDR_NVPSIZ (0xf << 8) /* Nonvolatile Program Memory Size */ | ||
77 | #define AT91_CIDR_NVPSIZ2 (0xf << 12) /* Second Nonvolatile Program Memory Size */ | ||
78 | #define AT91_CIDR_SRAMSIZ (0xf << 16) /* Internal SRAM Size */ | ||
79 | #define AT91_CIDR_ARCH (0xff << 20) /* Architecture Identifier */ | ||
80 | #define AT91_CIDR_NVPTYP (7 << 28) /* Nonvolatile Program Memory Type */ | ||
81 | #define AT91_CIDR_EXT (1 << 31) /* Extension Flag */ | ||
73 | 82 | ||
74 | 83 | ||
75 | /* | 84 | /* |
@@ -241,7 +250,7 @@ | |||
241 | #define AT91_RTC_SEC (0x7f << 0) /* Current Second */ | 250 | #define AT91_RTC_SEC (0x7f << 0) /* Current Second */ |
242 | #define AT91_RTC_MIN (0x7f << 8) /* Current Minute */ | 251 | #define AT91_RTC_MIN (0x7f << 8) /* Current Minute */ |
243 | #define AT91_RTC_HOUR (0x3f << 16) /* Current Hour */ | 252 | #define AT91_RTC_HOUR (0x3f << 16) /* Current Hour */ |
244 | #define At91_RTC_AMPM (1 << 22) /* Ante Meridiem Post Meridiem Indicator */ | 253 | #define AT91_RTC_AMPM (1 << 22) /* Ante Meridiem Post Meridiem Indicator */ |
245 | 254 | ||
246 | #define AT91_RTC_CALR (AT91_RTC + 0x0c) /* Calendar Register */ | 255 | #define AT91_RTC_CALR (AT91_RTC + 0x0c) /* Calendar Register */ |
247 | #define AT91_RTC_CENT (0x7f << 0) /* Current Century */ | 256 | #define AT91_RTC_CENT (0x7f << 0) /* Current Century */ |
diff --git a/include/asm-arm/arch-at91rm9200/at91rm9200_tc.h b/include/asm-arm/arch-at91rm9200/at91rm9200_tc.h new file mode 100644 index 000000000000..f4da752bb0c8 --- /dev/null +++ b/include/asm-arm/arch-at91rm9200/at91rm9200_tc.h | |||
@@ -0,0 +1,146 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-at91rm9200/at91rm9200_tc.h | ||
3 | * | ||
4 | * Copyright (C) SAN People | ||
5 | * | ||
6 | * Timer/Counter Unit (TC) registers. | ||
7 | * Based on AT91RM9200 datasheet revision E. | ||
8 | * | ||
9 | * This program is free software; you can redistribute it and/or modify | ||
10 | * it under the terms of the GNU General Public License as published by | ||
11 | * the Free Software Foundation; either version 2 of the License, or | ||
12 | * (at your option) any later version. | ||
13 | */ | ||
14 | |||
15 | #ifndef AT91RM9200_TC_H | ||
16 | #define AT91RM9200_TC_H | ||
17 | |||
18 | #define AT91_TC_BCR 0xc0 /* TC Block Control Register */ | ||
19 | #define AT91_TC_SYNC (1 << 0) /* Synchro Command */ | ||
20 | |||
21 | #define AT91_TC_BMR 0xc4 /* TC Block Mode Register */ | ||
22 | #define AT91_TC_TC0XC0S (3 << 0) /* External Clock Signal 0 Selection */ | ||
23 | #define AT91_TC_TC0XC0S_TCLK0 (0 << 0) | ||
24 | #define AT91_TC_TC0XC0S_NONE (1 << 0) | ||
25 | #define AT91_TC_TC0XC0S_TIOA1 (2 << 0) | ||
26 | #define AT91_TC_TC0XC0S_TIOA2 (3 << 0) | ||
27 | #define AT91_TC_TC1XC1S (3 << 2) /* External Clock Signal 1 Selection */ | ||
28 | #define AT91_TC_TC1XC1S_TCLK1 (0 << 2) | ||
29 | #define AT91_TC_TC1XC1S_NONE (1 << 2) | ||
30 | #define AT91_TC_TC1XC1S_TIOA0 (2 << 2) | ||
31 | #define AT91_TC_TC1XC1S_TIOA2 (3 << 2) | ||
32 | #define AT91_TC_TC2XC2S (3 << 4) /* External Clock Signal 2 Selection */ | ||
33 | #define AT91_TC_TC2XC2S_TCLK2 (0 << 4) | ||
34 | #define AT91_TC_TC2XC2S_NONE (1 << 4) | ||
35 | #define AT91_TC_TC2XC2S_TIOA0 (2 << 4) | ||
36 | #define AT91_TC_TC2XC2S_TIOA1 (3 << 4) | ||
37 | |||
38 | |||
39 | #define AT91_TC_CCR 0x00 /* Channel Control Register */ | ||
40 | #define AT91_TC_CLKEN (1 << 0) /* Counter Clock Enable Command */ | ||
41 | #define AT91_TC_CLKDIS (1 << 1) /* Counter CLock Disable Command */ | ||
42 | #define AT91_TC_SWTRG (1 << 2) /* Software Trigger Command */ | ||
43 | |||
44 | #define AT91_TC_CMR 0x04 /* Channel Mode Register */ | ||
45 | #define AT91_TC_TCCLKS (7 << 0) /* Capture/Waveform Mode: Clock Selection */ | ||
46 | #define AT91_TC_TIMER_CLOCK1 (0 << 0) | ||
47 | #define AT91_TC_TIMER_CLOCK2 (1 << 0) | ||
48 | #define AT91_TC_TIMER_CLOCK3 (2 << 0) | ||
49 | #define AT91_TC_TIMER_CLOCK4 (3 << 0) | ||
50 | #define AT91_TC_TIMER_CLOCK5 (4 << 0) | ||
51 | #define AT91_TC_XC0 (5 << 0) | ||
52 | #define AT91_TC_XC1 (6 << 0) | ||
53 | #define AT91_TC_XC2 (7 << 0) | ||
54 | #define AT91_TC_CLKI (1 << 3) /* Capture/Waveform Mode: Clock Invert */ | ||
55 | #define AT91_TC_BURST (3 << 4) /* Capture/Waveform Mode: Burst Signal Selection */ | ||
56 | #define AT91_TC_LDBSTOP (1 << 6) /* Capture Mode: Counter Clock Stopped with TB Loading */ | ||
57 | #define AT91_TC_LDBDIS (1 << 7) /* Capture Mode: Counter Clock Disable with RB Loading */ | ||
58 | #define AT91_TC_ETRGEDG (3 << 8) /* Capture Mode: External Trigger Edge Selection */ | ||
59 | #define AT91_TC_ABETRG (1 << 10) /* Capture Mode: TIOA or TIOB External Trigger Selection */ | ||
60 | #define AT91_TC_CPCTRG (1 << 14) /* Capture Mode: RC Compare Trigger Enable */ | ||
61 | #define AT91_TC_WAVE (1 << 15) /* Capture/Waveform mode */ | ||
62 | #define AT91_TC_LDRA (3 << 16) /* Capture Mode: RA Loading Selection */ | ||
63 | #define AT91_TC_LDRB (3 << 18) /* Capture Mode: RB Loading Selection */ | ||
64 | |||
65 | #define AT91_TC_CPCSTOP (1 << 6) /* Waveform Mode: Counter Clock Stopped with RC Compare */ | ||
66 | #define AT91_TC_CPCDIS (1 << 7) /* Waveform Mode: Counter Clock Disable with RC Compare */ | ||
67 | #define AT91_TC_EEVTEDG (3 << 8) /* Waveform Mode: External Event Edge Selection */ | ||
68 | #define AT91_TC_EEVTEDG_NONE (0 << 8) | ||
69 | #define AT91_TC_EEVTEDG_RISING (1 << 8) | ||
70 | #define AT91_TC_EEVTEDG_FALLING (2 << 8) | ||
71 | #define AT91_TC_EEVTEDG_BOTH (3 << 8) | ||
72 | #define AT91_TC_EEVT (3 << 10) /* Waveform Mode: External Event Selection */ | ||
73 | #define AT91_TC_EEVT_TIOB (0 << 10) | ||
74 | #define AT91_TC_EEVT_XC0 (1 << 10) | ||
75 | #define AT91_TC_EEVT_XC1 (2 << 10) | ||
76 | #define AT91_TC_EEVT_XC2 (3 << 10) | ||
77 | #define AT91_TC_ENETRG (1 << 12) /* Waveform Mode: External Event Trigger Enable */ | ||
78 | #define AT91_TC_WAVESEL (3 << 13) /* Waveform Mode: Waveform Selection */ | ||
79 | #define AT91_TC_WAVESEL_UP (0 << 13) | ||
80 | #define AT91_TC_WAVESEL_UP_AUTO (2 << 13) | ||
81 | #define AT91_TC_WAVESEL_UPDOWN (1 << 13) | ||
82 | #define AT91_TC_WAVESEL_UPDOWN_AUTO (3 << 13) | ||
83 | #define AT91_TC_ACPA (3 << 16) /* Waveform Mode: RA Compare Effect on TIOA */ | ||
84 | #define AT91_TC_ACPA_NONE (0 << 16) | ||
85 | #define AT91_TC_ACPA_SET (1 << 16) | ||
86 | #define AT91_TC_ACPA_CLEAR (2 << 16) | ||
87 | #define AT91_TC_ACPA_TOGGLE (3 << 16) | ||
88 | #define AT91_TC_ACPC (3 << 18) /* Waveform Mode: RC Compre Effect on TIOA */ | ||
89 | #define AT91_TC_ACPC_NONE (0 << 18) | ||
90 | #define AT91_TC_ACPC_SET (1 << 18) | ||
91 | #define AT91_TC_ACPC_CLEAR (2 << 18) | ||
92 | #define AT91_TC_ACPC_TOGGLE (3 << 18) | ||
93 | #define AT91_TC_AEEVT (3 << 20) /* Waveform Mode: External Event Effect on TIOA */ | ||
94 | #define AT91_TC_AEEVT_NONE (0 << 20) | ||
95 | #define AT91_TC_AEEVT_SET (1 << 20) | ||
96 | #define AT91_TC_AEEVT_CLEAR (2 << 20) | ||
97 | #define AT91_TC_AEEVT_TOGGLE (3 << 20) | ||
98 | #define AT91_TC_ASWTRG (3 << 22) /* Waveform Mode: Software Trigger Effect on TIOA */ | ||
99 | #define AT91_TC_ASWTRG_NONE (0 << 22) | ||
100 | #define AT91_TC_ASWTRG_SET (1 << 22) | ||
101 | #define AT91_TC_ASWTRG_CLEAR (2 << 22) | ||
102 | #define AT91_TC_ASWTRG_TOGGLE (3 << 22) | ||
103 | #define AT91_TC_BCPB (3 << 24) /* Waveform Mode: RB Compare Effect on TIOB */ | ||
104 | #define AT91_TC_BCPB_NONE (0 << 24) | ||
105 | #define AT91_TC_BCPB_SET (1 << 24) | ||
106 | #define AT91_TC_BCPB_CLEAR (2 << 24) | ||
107 | #define AT91_TC_BCPB_TOGGLE (3 << 24) | ||
108 | #define AT91_TC_BCPC (3 << 26) /* Waveform Mode: RC Compare Effect on TIOB */ | ||
109 | #define AT91_TC_BCPC_NONE (0 << 26) | ||
110 | #define AT91_TC_BCPC_SET (1 << 26) | ||
111 | #define AT91_TC_BCPC_CLEAR (2 << 26) | ||
112 | #define AT91_TC_BCPC_TOGGLE (3 << 26) | ||
113 | #define AT91_TC_BEEVT (3 << 28) /* Waveform Mode: External Event Effect on TIOB */ | ||
114 | #define AT91_TC_BEEVT_NONE (0 << 28) | ||
115 | #define AT91_TC_BEEVT_SET (1 << 28) | ||
116 | #define AT91_TC_BEEVT_CLEAR (2 << 28) | ||
117 | #define AT91_TC_BEEVT_TOGGLE (3 << 28) | ||
118 | #define AT91_TC_BSWTRG (3 << 30) /* Waveform Mode: Software Trigger Effect on TIOB */ | ||
119 | #define AT91_TC_BSWTRG_NONE (0 << 30) | ||
120 | #define AT91_TC_BSWTRG_SET (1 << 30) | ||
121 | #define AT91_TC_BSWTRG_CLEAR (2 << 30) | ||
122 | #define AT91_TC_BSWTRG_TOGGLE (3 << 30) | ||
123 | |||
124 | #define AT91_TC_CV 0x10 /* Counter Value */ | ||
125 | #define AT91_TC_RA 0x14 /* Register A */ | ||
126 | #define AT91_TC_RB 0x18 /* Register B */ | ||
127 | #define AT91_TC_RC 0x1c /* Register C */ | ||
128 | |||
129 | #define AT91_TC_SR 0x20 /* Status Register */ | ||
130 | #define AT91_TC_COVFS (1 << 0) /* Counter Overflow Status */ | ||
131 | #define AT91_TC_LOVRS (1 << 1) /* Load Overrun Status */ | ||
132 | #define AT91_TC_CPAS (1 << 2) /* RA Compare Status */ | ||
133 | #define AT91_TC_CPBS (1 << 3) /* RB Compare Status */ | ||
134 | #define AT91_TC_CPCS (1 << 4) /* RC Compare Status */ | ||
135 | #define AT91_TC_LDRAS (1 << 5) /* RA Loading Status */ | ||
136 | #define AT91_TC_LDRBS (1 << 6) /* RB Loading Status */ | ||
137 | #define AT91_TC_ETRGS (1 << 7) /* External Trigger Status */ | ||
138 | #define AT91_TC_CLKSTA (1 << 16) /* Clock Enabling Status */ | ||
139 | #define AT91_TC_MTIOA (1 << 17) /* TIOA Mirror */ | ||
140 | #define AT91_TC_MTIOB (1 << 18) /* TIOB Mirror */ | ||
141 | |||
142 | #define AT91_TC_IER 0x24 /* Interrupt Enable Register */ | ||
143 | #define AT91_TC_IDR 0x28 /* Interrupt Disable Register */ | ||
144 | #define AT91_TC_IMR 0x2c /* Interrupt Mask Register */ | ||
145 | |||
146 | #endif | ||
diff --git a/include/asm-arm/arch-at91rm9200/at91rm9200_udp.h b/include/asm-arm/arch-at91rm9200/at91rm9200_udp.h new file mode 100644 index 000000000000..951e3f61cef4 --- /dev/null +++ b/include/asm-arm/arch-at91rm9200/at91rm9200_udp.h | |||
@@ -0,0 +1,77 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-at91rm9200/at91rm9200_udp.h | ||
3 | * | ||
4 | * Copyright (C) 2005 Ivan Kokshaysky | ||
5 | * Copyright (C) SAN People | ||
6 | * | ||
7 | * USB Device Port (UDP) registers. | ||
8 | * Based on AT91RM9200 datasheet revision E. | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify | ||
11 | * it under the terms of the GNU General Public License as published by | ||
12 | * the Free Software Foundation; either version 2 of the License, or | ||
13 | * (at your option) any later version. | ||
14 | */ | ||
15 | |||
16 | #ifndef AT91RM9200_UDP_H | ||
17 | #define AT91RM9200_UDP_H | ||
18 | |||
19 | #define AT91_UDP_FRM_NUM 0x00 /* Frame Number Register */ | ||
20 | #define AT91_UDP_NUM (0x7ff << 0) /* Frame Number */ | ||
21 | #define AT91_UDP_FRM_ERR (1 << 16) /* Frame Error */ | ||
22 | #define AT91_UDP_FRM_OK (1 << 17) /* Frame OK */ | ||
23 | |||
24 | #define AT91_UDP_GLB_STAT 0x04 /* Global State Register */ | ||
25 | #define AT91_UDP_FADDEN (1 << 0) /* Function Address Enable */ | ||
26 | #define AT91_UDP_CONFG (1 << 1) /* Configured */ | ||
27 | #define AT91_UDP_ESR (1 << 2) /* Enable Send Resume */ | ||
28 | #define AT91_UDP_RSMINPR (1 << 3) /* Resume has been sent */ | ||
29 | #define AT91_UDP_RMWUPE (1 << 4) /* Remote Wake Up Enable */ | ||
30 | |||
31 | #define AT91_UDP_FADDR 0x08 /* Function Address Register */ | ||
32 | #define AT91_UDP_FADD (0x7f << 0) /* Function Address Value */ | ||
33 | #define AT91_UDP_FEN (1 << 8) /* Function Enable */ | ||
34 | |||
35 | #define AT91_UDP_IER 0x10 /* Interrupt Enable Register */ | ||
36 | #define AT91_UDP_IDR 0x14 /* Interrupt Disable Register */ | ||
37 | #define AT91_UDP_IMR 0x18 /* Interrupt Mask Register */ | ||
38 | |||
39 | #define AT91_UDP_ISR 0x1c /* Interrupt Status Register */ | ||
40 | #define AT91_UDP_EP(n) (1 << (n)) /* Endpoint Interrupt Status */ | ||
41 | #define AT91_UDP_RXSUSP (1 << 8) /* USB Suspend Interrupt Status */ | ||
42 | #define AT91_UDP_RXRSM (1 << 9) /* USB Resume Interrupt Status */ | ||
43 | #define AT91_UDP_EXTRSM (1 << 10) /* External Resume Interrupt Status */ | ||
44 | #define AT91_UDP_SOFINT (1 << 11) /* Start of Frame Interrupt Status */ | ||
45 | #define AT91_UDP_ENDBUSRES (1 << 12) /* End of Bus Reset Interrpt Status */ | ||
46 | #define AT91_UDP_WAKEUP (1 << 13) /* USB Wakeup Interrupt Status */ | ||
47 | |||
48 | #define AT91_UDP_ICR 0x20 /* Interrupt Clear Register */ | ||
49 | #define AT91_UDP_RST_EP 0x28 /* Reset Endpoint Register */ | ||
50 | |||
51 | #define AT91_UDP_CSR(n) (0x30 + ((n) * 4)) /* Endpoint Control/Status Registers 0-7 */ | ||
52 | #define AT91_UDP_TXCOMP (1 << 0) /* Generates IN packet with data previously written in DPR */ | ||
53 | #define AT91_UDP_RX_DATA_BK0 (1 << 1) /* Receive Data Bank 0 */ | ||
54 | #define AT91_UDP_RXSETUP (1 << 2) /* Send STALL to the host */ | ||
55 | #define AT91_UDP_STALLSENT (1 << 3) /* Stall Sent / Isochronous error (Isochronous endpoints) */ | ||
56 | #define AT91_UDP_TXPKTRDY (1 << 4) /* Transmit Packet Ready */ | ||
57 | #define AT91_UDP_FORCESTALL (1 << 5) /* Force Stall */ | ||
58 | #define AT91_UDP_RX_DATA_BK1 (1 << 6) /* Receive Data Bank 1 */ | ||
59 | #define AT91_UDP_DIR (1 << 7) /* Transfer Direction */ | ||
60 | #define AT91_UDP_EPTYPE (7 << 8) /* Endpoint Type */ | ||
61 | #define AT91_UDP_EPTYPE_CTRL (0 << 8) | ||
62 | #define AT91_UDP_EPTYPE_ISO_OUT (1 << 8) | ||
63 | #define AT91_UDP_EPTYPE_BULK_OUT (2 << 8) | ||
64 | #define AT91_UDP_EPTYPE_INT_OUT (3 << 8) | ||
65 | #define AT91_UDP_EPTYPE_ISO_IN (5 << 8) | ||
66 | #define AT91_UDP_EPTYPE_BULK_IN (6 << 8) | ||
67 | #define AT91_UDP_EPTYPE_INT_IN (7 << 8) | ||
68 | #define AT91_UDP_DTGLE (1 << 11) /* Data Toggle */ | ||
69 | #define AT91_UDP_EPEDS (1 << 15) /* Endpoint Enable/Disable */ | ||
70 | #define AT91_UDP_RXBYTECNT (0x7ff << 16) /* Number of bytes in FIFO */ | ||
71 | |||
72 | #define AT91_UDP_FDR(n) (0x50 + ((n) * 4)) /* Endpoint FIFO Data Registers 0-7 */ | ||
73 | |||
74 | #define AT91_UDP_TXVC 0x74 /* Transceiver Control Register */ | ||
75 | #define AT91_UDP_TXVC_TXVDIS (1 << 8) /* Transceiver Disable */ | ||
76 | |||
77 | #endif | ||
diff --git a/include/asm-arm/arch-at91rm9200/board.h b/include/asm-arm/arch-at91rm9200/board.h index 4fdef13d01d4..1fdd70b23809 100644 --- a/include/asm-arm/arch-at91rm9200/board.h +++ b/include/asm-arm/arch-at91rm9200/board.h | |||
@@ -31,14 +31,9 @@ | |||
31 | #ifndef __ASM_ARCH_BOARD_H | 31 | #ifndef __ASM_ARCH_BOARD_H |
32 | #define __ASM_ARCH_BOARD_H | 32 | #define __ASM_ARCH_BOARD_H |
33 | 33 | ||
34 | /* Clocks */ | ||
35 | extern unsigned long at91_master_clock; | ||
36 | |||
37 | /* Serial Port */ | ||
38 | extern int at91_serial_map[AT91_NR_UART]; | ||
39 | extern int at91_console_port; | ||
40 | |||
41 | #include <linux/mtd/partitions.h> | 34 | #include <linux/mtd/partitions.h> |
35 | #include <linux/device.h> | ||
36 | #include <linux/spi/spi.h> | ||
42 | 37 | ||
43 | /* USB Device */ | 38 | /* USB Device */ |
44 | struct at91_udc_data { | 39 | struct at91_udc_data { |
@@ -91,10 +86,25 @@ struct at91_nand_data { | |||
91 | extern void __init at91_add_device_nand(struct at91_nand_data *data); | 86 | extern void __init at91_add_device_nand(struct at91_nand_data *data); |
92 | 87 | ||
93 | /* I2C*/ | 88 | /* I2C*/ |
94 | void __init at91_add_device_i2c(void); | 89 | extern void __init at91_add_device_i2c(void); |
90 | |||
91 | /* SPI */ | ||
92 | extern void __init at91_add_device_spi(struct spi_board_info *devices, int nr_devices); | ||
95 | 93 | ||
96 | /* RTC */ | 94 | /* Serial */ |
97 | void __init at91_add_device_rtc(void); | 95 | struct at91_uart_config { |
96 | unsigned short console_tty; /* tty number of serial console */ | ||
97 | unsigned short nr_tty; /* number of serial tty's */ | ||
98 | short tty_map[]; /* map UART to tty number */ | ||
99 | }; | ||
100 | extern struct platform_device *at91_default_console_device; | ||
101 | extern void __init at91_init_serial(struct at91_uart_config *config); | ||
102 | |||
103 | struct at91_uart_data { | ||
104 | short use_dma_tx; /* use transmit DMA? */ | ||
105 | short use_dma_rx; /* use receive DMA? */ | ||
106 | }; | ||
107 | extern void __init at91_add_device_serial(void); | ||
98 | 108 | ||
99 | /* LEDs */ | 109 | /* LEDs */ |
100 | extern u8 at91_leds_cpu; | 110 | extern u8 at91_leds_cpu; |
diff --git a/include/asm-arm/arch-at91rm9200/gpio.h b/include/asm-arm/arch-at91rm9200/gpio.h index 6176ab2dc417..dbde1baaf251 100644 --- a/include/asm-arm/arch-at91rm9200/gpio.h +++ b/include/asm-arm/arch-at91rm9200/gpio.h | |||
@@ -13,6 +13,8 @@ | |||
13 | #ifndef __ASM_ARCH_AT91RM9200_GPIO_H | 13 | #ifndef __ASM_ARCH_AT91RM9200_GPIO_H |
14 | #define __ASM_ARCH_AT91RM9200_GPIO_H | 14 | #define __ASM_ARCH_AT91RM9200_GPIO_H |
15 | 15 | ||
16 | #include <asm/irq.h> | ||
17 | |||
16 | #define PIN_BASE NR_AIC_IRQS | 18 | #define PIN_BASE NR_AIC_IRQS |
17 | 19 | ||
18 | #define PQFP_GPIO_BANKS 3 /* PQFP package has 3 banks */ | 20 | #define PQFP_GPIO_BANKS 3 /* PQFP package has 3 banks */ |
@@ -188,6 +190,9 @@ extern int at91_set_multi_drive(unsigned pin, int is_on); | |||
188 | /* callable at any time */ | 190 | /* callable at any time */ |
189 | extern int at91_set_gpio_value(unsigned pin, int value); | 191 | extern int at91_set_gpio_value(unsigned pin, int value); |
190 | extern int at91_get_gpio_value(unsigned pin); | 192 | extern int at91_get_gpio_value(unsigned pin); |
193 | |||
194 | extern void at91_gpio_suspend(void); | ||
195 | extern void at91_gpio_resume(void); | ||
191 | #endif | 196 | #endif |
192 | 197 | ||
193 | #endif | 198 | #endif |
diff --git a/include/asm-arm/arch-at91rm9200/hardware.h b/include/asm-arm/arch-at91rm9200/hardware.h index 59e6f44d3a0d..235d39d91107 100644 --- a/include/asm-arm/arch-at91rm9200/hardware.h +++ b/include/asm-arm/arch-at91rm9200/hardware.h | |||
@@ -50,9 +50,12 @@ | |||
50 | #define AT91_VA_BASE_TCB0 AT91_IO_P2V(AT91_BASE_TCB0) | 50 | #define AT91_VA_BASE_TCB0 AT91_IO_P2V(AT91_BASE_TCB0) |
51 | 51 | ||
52 | /* Internal SRAM */ | 52 | /* Internal SRAM */ |
53 | #define AT91_BASE_SRAM 0x00200000 /* Internal SRAM base address */ | 53 | #define AT91_SRAM_BASE 0x00200000 /* Internal SRAM base address */ |
54 | #define AT91_SRAM_SIZE 0x00004000 /* Internal SRAM SIZE (16Kb) */ | 54 | #define AT91_SRAM_SIZE 0x00004000 /* Internal SRAM SIZE (16Kb) */ |
55 | 55 | ||
56 | /* Internal SRAM is mapped below the IO devices */ | ||
57 | #define AT91_SRAM_VIRT_BASE (AT91_IO_VIRT_BASE - AT91_SRAM_SIZE) | ||
58 | |||
56 | /* Serial ports */ | 59 | /* Serial ports */ |
57 | #define AT91_NR_UART 5 /* 4 USART3's and one DBGU port */ | 60 | #define AT91_NR_UART 5 /* 4 USART3's and one DBGU port */ |
58 | 61 | ||
@@ -81,14 +84,14 @@ static inline unsigned int at91_sys_read(unsigned int reg_offset) | |||
81 | { | 84 | { |
82 | void __iomem *addr = (void __iomem *)AT91_VA_BASE_SYS; | 85 | void __iomem *addr = (void __iomem *)AT91_VA_BASE_SYS; |
83 | 86 | ||
84 | return readl(addr + reg_offset); | 87 | return __raw_readl(addr + reg_offset); |
85 | } | 88 | } |
86 | 89 | ||
87 | static inline void at91_sys_write(unsigned int reg_offset, unsigned long value) | 90 | static inline void at91_sys_write(unsigned int reg_offset, unsigned long value) |
88 | { | 91 | { |
89 | void __iomem *addr = (void __iomem *)AT91_VA_BASE_SYS; | 92 | void __iomem *addr = (void __iomem *)AT91_VA_BASE_SYS; |
90 | 93 | ||
91 | writel(value, addr + reg_offset); | 94 | __raw_writel(value, addr + reg_offset); |
92 | } | 95 | } |
93 | #endif | 96 | #endif |
94 | 97 | ||
diff --git a/include/asm-arm/arch-at91rm9200/io.h b/include/asm-arm/arch-at91rm9200/io.h index 23e670d85c9d..88fd1bebcef3 100644 --- a/include/asm-arm/arch-at91rm9200/io.h +++ b/include/asm-arm/arch-at91rm9200/io.h | |||
@@ -21,7 +21,6 @@ | |||
21 | #ifndef __ASM_ARCH_IO_H | 21 | #ifndef __ASM_ARCH_IO_H |
22 | #define __ASM_ARCH_IO_H | 22 | #define __ASM_ARCH_IO_H |
23 | 23 | ||
24 | #include <asm/arch/at91rm9200.h> | ||
25 | #include <asm/io.h> | 24 | #include <asm/io.h> |
26 | 25 | ||
27 | #define IO_SPACE_LIMIT 0xFFFFFFFF | 26 | #define IO_SPACE_LIMIT 0xFFFFFFFF |
diff --git a/include/asm-arm/arch-at91rm9200/irqs.h b/include/asm-arm/arch-at91rm9200/irqs.h index 27b0497f1b36..2dc93b174a8f 100644 --- a/include/asm-arm/arch-at91rm9200/irqs.h +++ b/include/asm-arm/arch-at91rm9200/irqs.h | |||
@@ -37,8 +37,6 @@ | |||
37 | * symbols in gpio.h for ones handled indirectly as GPIOs. | 37 | * symbols in gpio.h for ones handled indirectly as GPIOs. |
38 | * We make provision for 4 banks of GPIO. | 38 | * We make provision for 4 banks of GPIO. |
39 | */ | 39 | */ |
40 | #include <asm/arch/gpio.h> | ||
41 | |||
42 | #define NR_IRQS (NR_AIC_IRQS + (4 * 32)) | 40 | #define NR_IRQS (NR_AIC_IRQS + (4 * 32)) |
43 | 41 | ||
44 | 42 | ||
diff --git a/include/asm-arm/arch-at91rm9200/memory.h b/include/asm-arm/arch-at91rm9200/memory.h index 462f1f0ad67c..3c327c404373 100644 --- a/include/asm-arm/arch-at91rm9200/memory.h +++ b/include/asm-arm/arch-at91rm9200/memory.h | |||
@@ -21,7 +21,7 @@ | |||
21 | #ifndef __ASM_ARCH_MEMORY_H | 21 | #ifndef __ASM_ARCH_MEMORY_H |
22 | #define __ASM_ARCH_MEMORY_H | 22 | #define __ASM_ARCH_MEMORY_H |
23 | 23 | ||
24 | #include <asm/arch/hardware.h> | 24 | #include <asm/hardware.h> |
25 | 25 | ||
26 | #define PHYS_OFFSET (AT91_SDRAM_BASE) | 26 | #define PHYS_OFFSET (AT91_SDRAM_BASE) |
27 | 27 | ||
diff --git a/include/asm-arm/arch-at91rm9200/pio.h b/include/asm-arm/arch-at91rm9200/pio.h deleted file mode 100644 index a89501b4a703..000000000000 --- a/include/asm-arm/arch-at91rm9200/pio.h +++ /dev/null | |||
@@ -1,115 +0,0 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-at91rm9200/pio.h | ||
3 | * | ||
4 | * Copyright (C) 2003 SAN People | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License as published by | ||
8 | * the Free Software Foundation; either version 2 of the License, or | ||
9 | * (at your option) any later version. | ||
10 | * | ||
11 | */ | ||
12 | |||
13 | #ifndef __ASM_ARCH_PIO_H | ||
14 | #define __ASM_ARCH_PIO_H | ||
15 | |||
16 | #include <asm/arch/hardware.h> | ||
17 | |||
18 | static inline void AT91_CfgPIO_USART0(void) { | ||
19 | at91_sys_write(AT91_PIOA + PIO_PDR, AT91_PA17_TXD0 | AT91_PA18_RXD0 | AT91_PA20_CTS0); | ||
20 | |||
21 | /* | ||
22 | * Errata #39 - RTS0 is not internally connected to PA21. We need to drive | ||
23 | * the pin manually. Default is off (RTS is active low). | ||
24 | */ | ||
25 | at91_sys_write(AT91_PIOA + PIO_PER, AT91_PA21_RTS0); | ||
26 | at91_sys_write(AT91_PIOA + PIO_OER, AT91_PA21_RTS0); | ||
27 | at91_sys_write(AT91_PIOA + PIO_SODR, AT91_PA21_RTS0); | ||
28 | } | ||
29 | |||
30 | static inline void AT91_CfgPIO_USART1(void) { | ||
31 | at91_sys_write(AT91_PIOB + PIO_PDR, AT91_PB18_RI1 | AT91_PB19_DTR1 | ||
32 | | AT91_PB20_TXD1 | AT91_PB21_RXD1 | AT91_PB23_DCD1 | ||
33 | | AT91_PB24_CTS1 | AT91_PB25_DSR1 | AT91_PB26_RTS1); | ||
34 | } | ||
35 | |||
36 | static inline void AT91_CfgPIO_USART2(void) { | ||
37 | at91_sys_write(AT91_PIOA + PIO_PDR, AT91_PA22_RXD2 | AT91_PA23_TXD2); | ||
38 | } | ||
39 | |||
40 | static inline void AT91_CfgPIO_USART3(void) { | ||
41 | at91_sys_write(AT91_PIOA + PIO_PDR, AT91_PA5_TXD3 | AT91_PA6_RXD3); | ||
42 | at91_sys_write(AT91_PIOA + PIO_BSR, AT91_PA5_TXD3 | AT91_PA6_RXD3); | ||
43 | } | ||
44 | |||
45 | static inline void AT91_CfgPIO_DBGU(void) { | ||
46 | at91_sys_write(AT91_PIOA + PIO_PDR, AT91_PA31_DTXD | AT91_PA30_DRXD); | ||
47 | } | ||
48 | |||
49 | /* | ||
50 | * Enable the Two-Wire interface. | ||
51 | */ | ||
52 | static inline void AT91_CfgPIO_TWI(void) { | ||
53 | at91_sys_write(AT91_PIOA + PIO_PDR, AT91_PA25_TWD | AT91_PA26_TWCK); | ||
54 | at91_sys_write(AT91_PIOA + PIO_ASR, AT91_PA25_TWD | AT91_PA26_TWCK); | ||
55 | at91_sys_write(AT91_PIOA + PIO_MDER, AT91_PA25_TWD | AT91_PA26_TWCK); /* open drain */ | ||
56 | } | ||
57 | |||
58 | /* | ||
59 | * Enable the Serial Peripheral Interface. | ||
60 | */ | ||
61 | static inline void AT91_CfgPIO_SPI(void) { | ||
62 | at91_sys_write(AT91_PIOA + PIO_PDR, AT91_PA0_MISO | AT91_PA1_MOSI | AT91_PA2_SPCK); | ||
63 | } | ||
64 | |||
65 | static inline void AT91_CfgPIO_SPI_CS0(void) { | ||
66 | at91_sys_write(AT91_PIOA + PIO_PDR, AT91_PA3_NPCS0); | ||
67 | } | ||
68 | |||
69 | static inline void AT91_CfgPIO_SPI_CS1(void) { | ||
70 | at91_sys_write(AT91_PIOA + PIO_PDR, AT91_PA4_NPCS1); | ||
71 | } | ||
72 | |||
73 | static inline void AT91_CfgPIO_SPI_CS2(void) { | ||
74 | at91_sys_write(AT91_PIOA + PIO_PDR, AT91_PA5_NPCS2); | ||
75 | } | ||
76 | |||
77 | static inline void AT91_CfgPIO_SPI_CS3(void) { | ||
78 | at91_sys_write(AT91_PIOA + PIO_PDR, AT91_PA6_NPCS3); | ||
79 | } | ||
80 | |||
81 | /* | ||
82 | * Select the DataFlash card. | ||
83 | */ | ||
84 | static inline void AT91_CfgPIO_DataFlashCard(void) { | ||
85 | at91_sys_write(AT91_PIOB + PIO_PER, AT91_PIO_P(7)); | ||
86 | at91_sys_write(AT91_PIOB + PIO_OER, AT91_PIO_P(7)); | ||
87 | at91_sys_write(AT91_PIOB + PIO_CODR, AT91_PIO_P(7)); | ||
88 | } | ||
89 | |||
90 | /* | ||
91 | * Enable NAND Flash (SmartMedia) interface. | ||
92 | */ | ||
93 | static inline void AT91_CfgPIO_SmartMedia(void) { | ||
94 | /* enable PC0=SMCE, PC1=SMOE, PC3=SMWE, A21=CLE, A22=ALE */ | ||
95 | at91_sys_write(AT91_PIOC + PIO_ASR, AT91_PC0_BFCK | AT91_PC1_BFRDY_SMOE | AT91_PC3_BFBAA_SMWE); | ||
96 | at91_sys_write(AT91_PIOC + PIO_PDR, AT91_PC0_BFCK | AT91_PC1_BFRDY_SMOE | AT91_PC3_BFBAA_SMWE); | ||
97 | |||
98 | /* Configure PC2 as input (signal READY of the SmartMedia) */ | ||
99 | at91_sys_write(AT91_PIOC + PIO_PER, AT91_PC2_BFAVD); /* enable direct output enable */ | ||
100 | at91_sys_write(AT91_PIOC + PIO_ODR, AT91_PC2_BFAVD); /* disable output */ | ||
101 | |||
102 | /* Configure PB1 as input (signal Card Detect of the SmartMedia) */ | ||
103 | at91_sys_write(AT91_PIOB + PIO_PER, AT91_PIO_P(1)); /* enable direct output enable */ | ||
104 | at91_sys_write(AT91_PIOB + PIO_ODR, AT91_PIO_P(1)); /* disable output */ | ||
105 | } | ||
106 | |||
107 | static inline int AT91_PIO_SmartMedia_RDY(void) { | ||
108 | return (at91_sys_read(AT91_PIOC + PIO_PDSR) & AT91_PIO_P(2)) ? 1 : 0; | ||
109 | } | ||
110 | |||
111 | static inline int AT91_PIO_SmartMedia_CardDetect(void) { | ||
112 | return (at91_sys_read(AT91_PIOB + PIO_PDSR) & AT91_PIO_P(1)) ? 1 : 0; | ||
113 | } | ||
114 | |||
115 | #endif | ||
diff --git a/include/asm-arm/arch-at91rm9200/system.h b/include/asm-arm/arch-at91rm9200/system.h index 29c42655f05c..8a2ff472e4cf 100644 --- a/include/asm-arm/arch-at91rm9200/system.h +++ b/include/asm-arm/arch-at91rm9200/system.h | |||
@@ -21,7 +21,7 @@ | |||
21 | #ifndef __ASM_ARCH_SYSTEM_H | 21 | #ifndef __ASM_ARCH_SYSTEM_H |
22 | #define __ASM_ARCH_SYSTEM_H | 22 | #define __ASM_ARCH_SYSTEM_H |
23 | 23 | ||
24 | #include <asm/arch/hardware.h> | 24 | #include <asm/hardware.h> |
25 | 25 | ||
26 | static inline void arch_idle(void) | 26 | static inline void arch_idle(void) |
27 | { | 27 | { |
@@ -48,4 +48,12 @@ static inline void arch_reset(char mode) | |||
48 | at91_sys_write(AT91_ST_CR, AT91_ST_WDRST); | 48 | at91_sys_write(AT91_ST_CR, AT91_ST_WDRST); |
49 | } | 49 | } |
50 | 50 | ||
51 | #define ARCH_ID_AT91RM9200 0x09200080 | ||
52 | #define ARCH_ID_AT91SAM9261 0x019000a0 | ||
53 | |||
54 | static inline unsigned long arch_identify(void) | ||
55 | { | ||
56 | return at91_sys_read(AT91_DBGU_CIDR) & (AT91_CIDR_EPROC | AT91_CIDR_ARCH); | ||
57 | } | ||
58 | |||
51 | #endif | 59 | #endif |
diff --git a/include/asm-arm/arch-at91rm9200/timex.h b/include/asm-arm/arch-at91rm9200/timex.h index 3f112dd12587..88687cefe6eb 100644 --- a/include/asm-arm/arch-at91rm9200/timex.h +++ b/include/asm-arm/arch-at91rm9200/timex.h | |||
@@ -21,7 +21,7 @@ | |||
21 | #ifndef __ASM_ARCH_TIMEX_H | 21 | #ifndef __ASM_ARCH_TIMEX_H |
22 | #define __ASM_ARCH_TIMEX_H | 22 | #define __ASM_ARCH_TIMEX_H |
23 | 23 | ||
24 | #include <asm/arch/hardware.h> | 24 | #include <asm/hardware.h> |
25 | 25 | ||
26 | #define CLOCK_TICK_RATE (AT91_SLOW_CLOCK) | 26 | #define CLOCK_TICK_RATE (AT91_SLOW_CLOCK) |
27 | 27 | ||
diff --git a/include/asm-arm/arch-at91rm9200/uncompress.h b/include/asm-arm/arch-at91rm9200/uncompress.h index 7b38497c24b5..ec7811ab0a52 100644 --- a/include/asm-arm/arch-at91rm9200/uncompress.h +++ b/include/asm-arm/arch-at91rm9200/uncompress.h | |||
@@ -21,7 +21,7 @@ | |||
21 | #ifndef __ASM_ARCH_UNCOMPRESS_H | 21 | #ifndef __ASM_ARCH_UNCOMPRESS_H |
22 | #define __ASM_ARCH_UNCOMPRESS_H | 22 | #define __ASM_ARCH_UNCOMPRESS_H |
23 | 23 | ||
24 | #include <asm/arch/hardware.h> | 24 | #include <asm/hardware.h> |
25 | 25 | ||
26 | /* | 26 | /* |
27 | * The following code assumes the serial port has already been | 27 | * The following code assumes the serial port has already been |
diff --git a/include/asm-arm/arch-at91rm9200/vmalloc.h b/include/asm-arm/arch-at91rm9200/vmalloc.h index 34d9718feb90..4c367eb57f47 100644 --- a/include/asm-arm/arch-at91rm9200/vmalloc.h +++ b/include/asm-arm/arch-at91rm9200/vmalloc.h | |||
@@ -21,6 +21,6 @@ | |||
21 | #ifndef __ASM_ARCH_VMALLOC_H | 21 | #ifndef __ASM_ARCH_VMALLOC_H |
22 | #define __ASM_ARCH_VMALLOC_H | 22 | #define __ASM_ARCH_VMALLOC_H |
23 | 23 | ||
24 | #define VMALLOC_END (AT91_IO_VIRT_BASE & PGDIR_MASK) | 24 | #define VMALLOC_END (AT91_SRAM_VIRT_BASE & PGDIR_MASK) |
25 | 25 | ||
26 | #endif | 26 | #endif |
diff --git a/include/asm-arm/arch-cl7500/acornfb.h b/include/asm-arm/arch-cl7500/acornfb.h index 3867231a4470..aea6330c9745 100644 --- a/include/asm-arm/arch-cl7500/acornfb.h +++ b/include/asm-arm/arch-cl7500/acornfb.h | |||
@@ -1,4 +1,3 @@ | |||
1 | #include <linux/config.h> | ||
2 | #define acornfb_valid_pixrate(var) (var->pixclock >= 39325 && var->pixclock <= 40119) | 1 | #define acornfb_valid_pixrate(var) (var->pixclock >= 39325 && var->pixclock <= 40119) |
3 | 2 | ||
4 | static inline void | 3 | static inline void |
diff --git a/include/asm-arm/arch-clps711x/hardware.h b/include/asm-arm/arch-clps711x/hardware.h index 1386871e1a5a..0fdbe72fff2a 100644 --- a/include/asm-arm/arch-clps711x/hardware.h +++ b/include/asm-arm/arch-clps711x/hardware.h | |||
@@ -22,7 +22,6 @@ | |||
22 | #ifndef __ASM_ARCH_HARDWARE_H | 22 | #ifndef __ASM_ARCH_HARDWARE_H |
23 | #define __ASM_ARCH_HARDWARE_H | 23 | #define __ASM_ARCH_HARDWARE_H |
24 | 24 | ||
25 | #include <linux/config.h> | ||
26 | 25 | ||
27 | #define CLPS7111_VIRT_BASE 0xff000000 | 26 | #define CLPS7111_VIRT_BASE 0xff000000 |
28 | #define CLPS7111_BASE CLPS7111_VIRT_BASE | 27 | #define CLPS7111_BASE CLPS7111_VIRT_BASE |
diff --git a/include/asm-arm/arch-clps711x/memory.h b/include/asm-arm/arch-clps711x/memory.h index 61d8717406ce..c6e8dcf674de 100644 --- a/include/asm-arm/arch-clps711x/memory.h +++ b/include/asm-arm/arch-clps711x/memory.h | |||
@@ -20,7 +20,6 @@ | |||
20 | #ifndef __ASM_ARCH_MEMORY_H | 20 | #ifndef __ASM_ARCH_MEMORY_H |
21 | #define __ASM_ARCH_MEMORY_H | 21 | #define __ASM_ARCH_MEMORY_H |
22 | 22 | ||
23 | #include <linux/config.h> | ||
24 | 23 | ||
25 | /* | 24 | /* |
26 | * Physical DRAM offset. | 25 | * Physical DRAM offset. |
diff --git a/include/asm-arm/arch-clps711x/uncompress.h b/include/asm-arm/arch-clps711x/uncompress.h index 07157b7e4b20..03d233ae87ce 100644 --- a/include/asm-arm/arch-clps711x/uncompress.h +++ b/include/asm-arm/arch-clps711x/uncompress.h | |||
@@ -17,7 +17,6 @@ | |||
17 | * along with this program; if not, write to the Free Software | 17 | * along with this program; if not, write to the Free Software |
18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | 18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA |
19 | */ | 19 | */ |
20 | #include <linux/config.h> | ||
21 | #include <asm/arch/io.h> | 20 | #include <asm/arch/io.h> |
22 | #include <asm/hardware.h> | 21 | #include <asm/hardware.h> |
23 | #include <asm/hardware/clps7111.h> | 22 | #include <asm/hardware/clps7111.h> |
diff --git a/include/asm-arm/arch-ebsa285/hardware.h b/include/asm-arm/arch-ebsa285/hardware.h index ec51fe92483b..daad8ee2d194 100644 --- a/include/asm-arm/arch-ebsa285/hardware.h +++ b/include/asm-arm/arch-ebsa285/hardware.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef __ASM_ARCH_HARDWARE_H | 12 | #ifndef __ASM_ARCH_HARDWARE_H |
13 | #define __ASM_ARCH_HARDWARE_H | 13 | #define __ASM_ARCH_HARDWARE_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <asm/arch/memory.h> | 15 | #include <asm/arch/memory.h> |
17 | 16 | ||
18 | #ifdef CONFIG_ARCH_FOOTBRIDGE | 17 | #ifdef CONFIG_ARCH_FOOTBRIDGE |
diff --git a/include/asm-arm/arch-ebsa285/memory.h b/include/asm-arm/arch-ebsa285/memory.h index 99181ffc7e27..cbd7ae64bcc9 100644 --- a/include/asm-arm/arch-ebsa285/memory.h +++ b/include/asm-arm/arch-ebsa285/memory.h | |||
@@ -19,7 +19,6 @@ | |||
19 | #ifndef __ASM_ARCH_MEMORY_H | 19 | #ifndef __ASM_ARCH_MEMORY_H |
20 | #define __ASM_ARCH_MEMORY_H | 20 | #define __ASM_ARCH_MEMORY_H |
21 | 21 | ||
22 | #include <linux/config.h> | ||
23 | 22 | ||
24 | #if defined(CONFIG_FOOTBRIDGE_ADDIN) | 23 | #if defined(CONFIG_FOOTBRIDGE_ADDIN) |
25 | /* | 24 | /* |
diff --git a/include/asm-arm/arch-ebsa285/vmalloc.h b/include/asm-arm/arch-ebsa285/vmalloc.h index d1ca955ce434..02598200997d 100644 --- a/include/asm-arm/arch-ebsa285/vmalloc.h +++ b/include/asm-arm/arch-ebsa285/vmalloc.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * published by the Free Software Foundation. | 6 | * published by the Free Software Foundation. |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | #ifdef CONFIG_ARCH_FOOTBRIDGE | 10 | #ifdef CONFIG_ARCH_FOOTBRIDGE |
12 | #define VMALLOC_END (PAGE_OFFSET + 0x30000000) | 11 | #define VMALLOC_END (PAGE_OFFSET + 0x30000000) |
diff --git a/include/asm-arm/arch-integrator/smp.h b/include/asm-arm/arch-integrator/smp.h index da6981efdc39..ab2c79bb9505 100644 --- a/include/asm-arm/arch-integrator/smp.h +++ b/include/asm-arm/arch-integrator/smp.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef ASMARM_ARCH_SMP_H | 1 | #ifndef ASMARM_ARCH_SMP_H |
2 | #define ASMARM_ARCH_SMP_H | 2 | #define ASMARM_ARCH_SMP_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #include <asm/hardware.h> | 5 | #include <asm/hardware.h> |
7 | #include <asm/io.h> | 6 | #include <asm/io.h> |
diff --git a/include/asm-arm/arch-iop3xx/memory.h b/include/asm-arm/arch-iop3xx/memory.h index bc62f4b13235..e43ebd984745 100644 --- a/include/asm-arm/arch-iop3xx/memory.h +++ b/include/asm-arm/arch-iop3xx/memory.h | |||
@@ -5,7 +5,6 @@ | |||
5 | #ifndef __ASM_ARCH_MEMORY_H | 5 | #ifndef __ASM_ARCH_MEMORY_H |
6 | #define __ASM_ARCH_MEMORY_H | 6 | #define __ASM_ARCH_MEMORY_H |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | #include <asm/hardware.h> | 8 | #include <asm/hardware.h> |
10 | 9 | ||
11 | /* | 10 | /* |
diff --git a/include/asm-arm/arch-iop3xx/timex.h b/include/asm-arm/arch-iop3xx/timex.h index 472badb451c4..14ca8d0f7b29 100644 --- a/include/asm-arm/arch-iop3xx/timex.h +++ b/include/asm-arm/arch-iop3xx/timex.h | |||
@@ -3,7 +3,6 @@ | |||
3 | * | 3 | * |
4 | * IOP3xx architecture timex specifications | 4 | * IOP3xx architecture timex specifications |
5 | */ | 5 | */ |
6 | #include <linux/config.h> | ||
7 | #include <asm/hardware.h> | 6 | #include <asm/hardware.h> |
8 | 7 | ||
9 | #if defined(CONFIG_ARCH_IQ80321) || defined(CONFIG_ARCH_IQ31244) | 8 | #if defined(CONFIG_ARCH_IQ80321) || defined(CONFIG_ARCH_IQ31244) |
diff --git a/include/asm-arm/arch-iop3xx/uncompress.h b/include/asm-arm/arch-iop3xx/uncompress.h index c98eb6254b1f..fbdd5af644fe 100644 --- a/include/asm-arm/arch-iop3xx/uncompress.h +++ b/include/asm-arm/arch-iop3xx/uncompress.h | |||
@@ -1,7 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | * linux/include/asm-arm/arch-iop3xx/uncompress.h | 2 | * linux/include/asm-arm/arch-iop3xx/uncompress.h |
3 | */ | 3 | */ |
4 | #include <linux/config.h> | ||
5 | #include <asm/types.h> | 4 | #include <asm/types.h> |
6 | #include <asm/mach-types.h> | 5 | #include <asm/mach-types.h> |
7 | #include <linux/serial_reg.h> | 6 | #include <linux/serial_reg.h> |
diff --git a/include/asm-arm/arch-ixp23xx/entry-macro.S b/include/asm-arm/arch-ixp23xx/entry-macro.S index 0ef4e6016ac4..867761677b57 100644 --- a/include/asm-arm/arch-ixp23xx/entry-macro.S +++ b/include/asm-arm/arch-ixp23xx/entry-macro.S | |||
@@ -8,7 +8,7 @@ | |||
8 | .macro get_irqnr_and_base, irqnr, irqstat, base, tmp | 8 | .macro get_irqnr_and_base, irqnr, irqstat, base, tmp |
9 | ldr \irqnr, =(IXP23XX_INTC_VIRT + IXP23XX_INTR_IRQ_ENC_ST_OFFSET) | 9 | ldr \irqnr, =(IXP23XX_INTC_VIRT + IXP23XX_INTR_IRQ_ENC_ST_OFFSET) |
10 | ldr \irqnr, [\irqnr] @ get interrupt number | 10 | ldr \irqnr, [\irqnr] @ get interrupt number |
11 | cmp \irqnr, #0x0 @ suprious interrupt ? | 11 | cmp \irqnr, #0x0 @ spurious interrupt ? |
12 | movne \irqnr, \irqnr, lsr #2 @ skip unwanted low order bits | 12 | movne \irqnr, \irqnr, lsr #2 @ skip unwanted low order bits |
13 | subne \irqnr, \irqnr, #1 @ convert to 0 based | 13 | subne \irqnr, \irqnr, #1 @ convert to 0 based |
14 | 14 | ||
diff --git a/include/asm-arm/arch-ixp23xx/ixp23xx.h b/include/asm-arm/arch-ixp23xx/ixp23xx.h index e49e1ca61b1a..01efdbd1180f 100644 --- a/include/asm-arm/arch-ixp23xx/ixp23xx.h +++ b/include/asm-arm/arch-ixp23xx/ixp23xx.h | |||
@@ -251,7 +251,7 @@ | |||
251 | * CAP CSRs. | 251 | * CAP CSRs. |
252 | ****************************************************************************/ | 252 | ****************************************************************************/ |
253 | #define IXP23XX_GLOBAL_REG(x) ((volatile unsigned long *)(IXP23XX_CAP_CSR_VIRT + 0x4a00 + (x))) | 253 | #define IXP23XX_GLOBAL_REG(x) ((volatile unsigned long *)(IXP23XX_CAP_CSR_VIRT + 0x4a00 + (x))) |
254 | #define IXP23XX_PROD_IDG IXP23XX_GLOBAL_REG(0x00) | 254 | #define IXP23XX_PRODUCT_ID IXP23XX_GLOBAL_REG(0x00) |
255 | #define IXP23XX_MISC_CONTROL IXP23XX_GLOBAL_REG(0x04) | 255 | #define IXP23XX_MISC_CONTROL IXP23XX_GLOBAL_REG(0x04) |
256 | #define IXP23XX_MSF_CLK_CNTRL IXP23XX_GLOBAL_REG(0x08) | 256 | #define IXP23XX_MSF_CLK_CNTRL IXP23XX_GLOBAL_REG(0x08) |
257 | #define IXP23XX_RESET0 IXP23XX_GLOBAL_REG(0x0c) | 257 | #define IXP23XX_RESET0 IXP23XX_GLOBAL_REG(0x0c) |
diff --git a/include/asm-arm/arch-ixp4xx/dma.h b/include/asm-arm/arch-ixp4xx/dma.h index b1a071ecebc8..789f7f53c357 100644 --- a/include/asm-arm/arch-ixp4xx/dma.h +++ b/include/asm-arm/arch-ixp4xx/dma.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef __ASM_ARCH_DMA_H | 11 | #ifndef __ASM_ARCH_DMA_H |
12 | #define __ASM_ARCH_DMA_H | 12 | #define __ASM_ARCH_DMA_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/device.h> | 14 | #include <linux/device.h> |
16 | #include <linux/pci.h> | 15 | #include <linux/pci.h> |
17 | #include <asm/page.h> | 16 | #include <asm/page.h> |
diff --git a/include/asm-arm/arch-lh7a40x/clocks.h b/include/asm-arm/arch-lh7a40x/clocks.h new file mode 100644 index 000000000000..bee02fd8dab1 --- /dev/null +++ b/include/asm-arm/arch-lh7a40x/clocks.h | |||
@@ -0,0 +1,20 @@ | |||
1 | /* include/asm-arm/arch-lh7a40x/clocks.h | ||
2 | * | ||
3 | * Copyright (C) 2004 Marc Singer | ||
4 | * | ||
5 | * This program is free software; you can redistribute it and/or | ||
6 | * modify it under the terms of the GNU General Public License | ||
7 | * version 2 as published by the Free Software Foundation. | ||
8 | * | ||
9 | */ | ||
10 | |||
11 | #include <linux/config.h> | ||
12 | |||
13 | #ifndef __ASM_ARCH_CLOCKS_H | ||
14 | #define __ASM_ARCH_CLOCKS_H | ||
15 | |||
16 | unsigned int fclkfreq_get (void); | ||
17 | unsigned int hclkfreq_get (void); | ||
18 | unsigned int pclkfreq_get (void); | ||
19 | |||
20 | #endif /* _ASM_ARCH_CLOCKS_H */ | ||
diff --git a/include/asm-arm/arch-lh7a40x/constants.h b/include/asm-arm/arch-lh7a40x/constants.h index 52c1cb9c39c6..51de96e87faf 100644 --- a/include/asm-arm/arch-lh7a40x/constants.h +++ b/include/asm-arm/arch-lh7a40x/constants.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef __ASM_ARCH_CONSTANTS_H | 12 | #ifndef __ASM_ARCH_CONSTANTS_H |
13 | #define __ASM_ARCH_CONSTANTS_H | 13 | #define __ASM_ARCH_CONSTANTS_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | /* Addressing constants */ | 16 | /* Addressing constants */ |
18 | 17 | ||
@@ -29,8 +28,7 @@ | |||
29 | 28 | ||
30 | #if defined (CONFIG_MACH_LPD7A400) || defined (CONFIG_MACH_LPD7A404) | 29 | #if defined (CONFIG_MACH_LPD7A400) || defined (CONFIG_MACH_LPD7A404) |
31 | 30 | ||
32 | # define IOBARRIER_PHYS 0xc0000000 /* Start of SDRAM */ | 31 | # define IOBARRIER_PHYS 0x10000000 /* Second bank, fastest timing */ |
33 | /*# define IOBARRIER_PHYS 0x00000000 */ /* Start of flash */ | ||
34 | # define IOBARRIER_VIRT 0xf0000000 | 32 | # define IOBARRIER_VIRT 0xf0000000 |
35 | # define IOBARRIER_SIZE PAGE_SIZE | 33 | # define IOBARRIER_SIZE PAGE_SIZE |
36 | 34 | ||
@@ -53,6 +51,9 @@ | |||
53 | # define CPLD08_PHYS CPLDX_PHYS (0x08) | 51 | # define CPLD08_PHYS CPLDX_PHYS (0x08) |
54 | # define CPLD08_VIRT CPLDX_VIRT (0x08) | 52 | # define CPLD08_VIRT CPLDX_VIRT (0x08) |
55 | # define CPLD08_SIZE PAGE_SIZE | 53 | # define CPLD08_SIZE PAGE_SIZE |
54 | # define CPLD0A_PHYS CPLDX_PHYS (0x0a) | ||
55 | # define CPLD0A_VIRT CPLDX_VIRT (0x0a) | ||
56 | # define CPLD0A_SIZE PAGE_SIZE | ||
56 | # define CPLD0C_PHYS CPLDX_PHYS (0x0c) | 57 | # define CPLD0C_PHYS CPLDX_PHYS (0x0c) |
57 | # define CPLD0C_VIRT CPLDX_VIRT (0x0c) | 58 | # define CPLD0C_VIRT CPLDX_VIRT (0x0c) |
58 | # define CPLD0C_SIZE PAGE_SIZE | 59 | # define CPLD0C_SIZE PAGE_SIZE |
@@ -84,5 +85,7 @@ | |||
84 | #define XTAL_IN 14745600 /* 14.7456 MHz crystal */ | 85 | #define XTAL_IN 14745600 /* 14.7456 MHz crystal */ |
85 | #define PLL_CLOCK (XTAL_IN * 21) /* 309 MHz PLL clock */ | 86 | #define PLL_CLOCK (XTAL_IN * 21) /* 309 MHz PLL clock */ |
86 | #define MAX_HCLK_KHZ 100000 /* HCLK max limit ~100MHz */ | 87 | #define MAX_HCLK_KHZ 100000 /* HCLK max limit ~100MHz */ |
88 | #define HCLK (99993600) | ||
89 | //#define HCLK (119808000) | ||
87 | 90 | ||
88 | #endif /* __ASM_ARCH_CONSTANTS_H */ | 91 | #endif /* __ASM_ARCH_CONSTANTS_H */ |
diff --git a/include/asm-arm/arch-lh7a40x/dma.h b/include/asm-arm/arch-lh7a40x/dma.h index 15492e3253f6..a8cbd14bbf9d 100644 --- a/include/asm-arm/arch-lh7a40x/dma.h +++ b/include/asm-arm/arch-lh7a40x/dma.h | |||
@@ -1,9 +1,86 @@ | |||
1 | /* include/asm-arm/arch-lh7a40x/dma.h | 1 | /* include/asm-arm/arch-lh7a40x/dma.h |
2 | * | 2 | * |
3 | * Copyright (C) 2003 Coastal Environmental Systems | 3 | * Copyright (C) 2005 Marc Singer |
4 | * | 4 | * |
5 | * This program is free software; you can redistribute it and/or | 5 | * This program is free software; you can redistribute it and/or |
6 | * modify it under the terms of the GNU General Public License | 6 | * modify it under the terms of the GNU General Public License |
7 | * version 2 as published by the Free Software Foundation. | 7 | * version 2 as published by the Free Software Foundation. |
8 | * | 8 | * |
9 | */ | 9 | */ |
10 | |||
11 | typedef enum { | ||
12 | DMA_M2M0 = 0, | ||
13 | DMA_M2M1 = 1, | ||
14 | DMA_M2P0 = 2, /* Tx */ | ||
15 | DMA_M2P1 = 3, /* Rx */ | ||
16 | DMA_M2P2 = 4, /* Tx */ | ||
17 | DMA_M2P3 = 5, /* Rx */ | ||
18 | DMA_M2P4 = 6, /* Tx - AC97 */ | ||
19 | DMA_M2P5 = 7, /* Rx - AC97 */ | ||
20 | DMA_M2P6 = 8, /* Tx */ | ||
21 | DMA_M2P7 = 9, /* Rx */ | ||
22 | } dma_device_t; | ||
23 | |||
24 | #define DMA_LENGTH_MAX ((64*1024) - 4) /* bytes */ | ||
25 | |||
26 | #define DMAC_GCA __REG(DMAC_PHYS + 0x2b80) | ||
27 | #define DMAC_GIR __REG(DMAC_PHYS + 0x2bc0) | ||
28 | |||
29 | #define DMAC_GIR_MMI1 (1<<11) | ||
30 | #define DMAC_GIR_MMI0 (1<<10) | ||
31 | #define DMAC_GIR_MPI8 (1<<9) | ||
32 | #define DMAC_GIR_MPI9 (1<<8) | ||
33 | #define DMAC_GIR_MPI6 (1<<7) | ||
34 | #define DMAC_GIR_MPI7 (1<<6) | ||
35 | #define DMAC_GIR_MPI4 (1<<5) | ||
36 | #define DMAC_GIR_MPI5 (1<<4) | ||
37 | #define DMAC_GIR_MPI2 (1<<3) | ||
38 | #define DMAC_GIR_MPI3 (1<<2) | ||
39 | #define DMAC_GIR_MPI0 (1<<1) | ||
40 | #define DMAC_GIR_MPI1 (1<<0) | ||
41 | |||
42 | #define DMAC_M2P0 0x0000 | ||
43 | #define DMAC_M2P1 0x0040 | ||
44 | #define DMAC_M2P2 0x0080 | ||
45 | #define DMAC_M2P3 0x00c0 | ||
46 | #define DMAC_M2P4 0x0240 | ||
47 | #define DMAC_M2P5 0x0200 | ||
48 | #define DMAC_M2P6 0x02c0 | ||
49 | #define DMAC_M2P7 0x0280 | ||
50 | #define DMAC_M2P8 0x0340 | ||
51 | #define DMAC_M2P9 0x0300 | ||
52 | #define DMAC_M2M0 0x0100 | ||
53 | #define DMAC_M2M1 0x0140 | ||
54 | |||
55 | #define DMAC_P_PCONTROL(c) __REG(DMAC_PHYS + (c) + 0x00) | ||
56 | #define DMAC_P_PINTERRUPT(c) __REG(DMAC_PHYS + (c) + 0x04) | ||
57 | #define DMAC_P_PPALLOC(c) __REG(DMAC_PHYS + (c) + 0x08) | ||
58 | #define DMAC_P_PSTATUS(c) __REG(DMAC_PHYS + (c) + 0x0c) | ||
59 | #define DMAC_P_REMAIN(c) __REG(DMAC_PHYS + (c) + 0x14) | ||
60 | #define DMAC_P_MAXCNT0(c) __REG(DMAC_PHYS + (c) + 0x20) | ||
61 | #define DMAC_P_BASE0(c) __REG(DMAC_PHYS + (c) + 0x24) | ||
62 | #define DMAC_P_CURRENT0(c) __REG(DMAC_PHYS + (c) + 0x28) | ||
63 | #define DMAC_P_MAXCNT1(c) __REG(DMAC_PHYS + (c) + 0x30) | ||
64 | #define DMAC_P_BASE1(c) __REG(DMAC_PHYS + (c) + 0x34) | ||
65 | #define DMAC_P_CURRENT1(c) __REG(DMAC_PHYS + (c) + 0x38) | ||
66 | |||
67 | #define DMAC_PCONTROL_ENABLE (1<<4) | ||
68 | |||
69 | #define DMAC_PORT_USB 0 | ||
70 | #define DMAC_PORT_SDMMC 1 | ||
71 | #define DMAC_PORT_AC97_1 2 | ||
72 | #define DMAC_PORT_AC97_2 3 | ||
73 | #define DMAC_PORT_AC97_3 4 | ||
74 | #define DMAC_PORT_UART1 6 | ||
75 | #define DMAC_PORT_UART2 7 | ||
76 | #define DMAC_PORT_UART3 8 | ||
77 | |||
78 | #define DMAC_PSTATUS_CURRSTATE_SHIFT 4 | ||
79 | #define DMAC_PSTATUS_CURRSTATE_MASK 0x3 | ||
80 | |||
81 | #define DMAC_PSTATUS_NEXTBUF (1<<6) | ||
82 | #define DMAC_PSTATUS_STALLRINT (1<<0) | ||
83 | |||
84 | #define DMAC_INT_CHE (1<<3) | ||
85 | #define DMAC_INT_NFB (1<<1) | ||
86 | #define DMAC_INT_STALL (1<<0) | ||
diff --git a/include/asm-arm/arch-lh7a40x/entry-macro.S b/include/asm-arm/arch-lh7a40x/entry-macro.S index a2f67c06d9c9..9fc7f4988124 100644 --- a/include/asm-arm/arch-lh7a40x/entry-macro.S +++ b/include/asm-arm/arch-lh7a40x/entry-macro.S | |||
@@ -10,11 +10,73 @@ | |||
10 | #include <asm/hardware.h> | 10 | #include <asm/hardware.h> |
11 | #include <asm/arch/irqs.h> | 11 | #include <asm/arch/irqs.h> |
12 | 12 | ||
13 | # if defined (CONFIG_ARCH_LH7A400) && defined (CONFIG_ARCH_LH7A404) | 13 | /* In order to allow there to be support for both of the processor |
14 | # error "LH7A400 and LH7A404 are mutually exclusive" | 14 | classes at the same time, we make a hack here that isn't very |
15 | # endif | 15 | pretty. At startup, the link pointed to with the |
16 | branch_irq_lh7a400 symbol is replaced with a NOP when the CPU is | ||
17 | detected as a lh7a404. | ||
16 | 18 | ||
17 | # if defined (CONFIG_ARCH_LH7A400) | 19 | *** FIXME: we should clean this up so that there is only one |
20 | implementation for each CPU's design. | ||
21 | |||
22 | */ | ||
23 | |||
24 | #if defined (CONFIG_ARCH_LH7A400) && defined (CONFIG_ARCH_LH7A404) | ||
25 | |||
26 | .macro disable_fiq | ||
27 | .endm | ||
28 | |||
29 | .macro get_irqnr_and_base, irqnr, irqstat, base, tmp | ||
30 | |||
31 | branch_irq_lh7a400: b 1000f | ||
32 | |||
33 | @ Implementation of the LH7A404 get_irqnr_and_base. | ||
34 | |||
35 | mov \irqnr, #0 @ VIC1 irq base | ||
36 | mov \base, #io_p2v(0x80000000) @ APB registers | ||
37 | add \base, \base, #0x8000 | ||
38 | ldr \tmp, [\base, #0x0030] @ VIC1_VECTADDR | ||
39 | tst \tmp, #VA_VECTORED @ Direct vectored | ||
40 | bne 1002f | ||
41 | tst \tmp, #VA_VIC1DEFAULT @ Default vectored VIC1 | ||
42 | ldrne \irqstat, [\base, #0] @ VIC1_IRQSTATUS | ||
43 | bne 1001f | ||
44 | add \base, \base, #(0xa000 - 0x8000) | ||
45 | ldr \tmp, [\base, #0x0030] @ VIC2_VECTADDR | ||
46 | tst \tmp, #VA_VECTORED @ Direct vectored | ||
47 | bne 1002f | ||
48 | ldr \irqstat, [\base, #0] @ VIC2_IRQSTATUS | ||
49 | mov \irqnr, #32 @ VIC2 irq base | ||
50 | |||
51 | 1001: movs \irqstat, \irqstat, lsr #1 @ Shift into carry | ||
52 | bcs 1008f @ Bit set; irq found | ||
53 | add \irqnr, \irqnr, #1 | ||
54 | bne 1001b @ Until no bits | ||
55 | b 1009f @ Nothing? Hmm. | ||
56 | 1002: and \irqnr, \tmp, #0x3f @ Mask for valid bits | ||
57 | 1008: movs \irqstat, #1 @ Force !Z | ||
58 | str \tmp, [\base, #0x0030] @ Clear vector | ||
59 | b 1009f | ||
60 | |||
61 | @ Implementation of the LH7A400 get_irqnr_and_base. | ||
62 | |||
63 | 1000: mov \irqnr, #0 | ||
64 | mov \base, #io_p2v(0x80000000) @ APB registers | ||
65 | ldr \irqstat, [\base, #0x500] @ PIC INTSR | ||
66 | |||
67 | 1001: movs \irqstat, \irqstat, lsr #1 @ Shift into carry | ||
68 | bcs 1008f @ Bit set; irq found | ||
69 | add \irqnr, \irqnr, #1 | ||
70 | bne 1001b @ Until no bits | ||
71 | b 1009f @ Nothing? Hmm. | ||
72 | 1008: movs \irqstat, #1 @ Force !Z | ||
73 | |||
74 | 1009: | ||
75 | .endm | ||
76 | |||
77 | |||
78 | |||
79 | #elif defined (CONFIG_ARCH_LH7A400) | ||
18 | .macro disable_fiq | 80 | .macro disable_fiq |
19 | .endm | 81 | .endm |
20 | 82 | ||
diff --git a/include/asm-arm/arch-lh7a40x/hardware.h b/include/asm-arm/arch-lh7a40x/hardware.h index aeb07c162e25..e9ff74fd7939 100644 --- a/include/asm-arm/arch-lh7a40x/hardware.h +++ b/include/asm-arm/arch-lh7a40x/hardware.h | |||
@@ -13,6 +13,8 @@ | |||
13 | #ifndef __ASM_ARCH_HARDWARE_H | 13 | #ifndef __ASM_ARCH_HARDWARE_H |
14 | #define __ASM_ARCH_HARDWARE_H | 14 | #define __ASM_ARCH_HARDWARE_H |
15 | 15 | ||
16 | #include <asm/sizes.h> /* Added for the sake of amba-clcd driver */ | ||
17 | |||
16 | #define io_p2v(x) (0xf0000000 | (((x) & 0xfff00000) >> 4) | ((x) & 0x0000ffff)) | 18 | #define io_p2v(x) (0xf0000000 | (((x) & 0xfff00000) >> 4) | ((x) & 0x0000ffff)) |
17 | #define io_v2p(x) ( (((x) & 0x0fff0000) << 4) | ((x) & 0x0000ffff)) | 19 | #define io_v2p(x) ( (((x) & 0x0fff0000) << 4) | ((x) & 0x0000ffff)) |
18 | 20 | ||
@@ -53,6 +55,8 @@ typedef struct { volatile u8 offset[4096]; } __regbase8; | |||
53 | 55 | ||
54 | #endif | 56 | #endif |
55 | 57 | ||
58 | #define MASK_AND_SET(v,m,s) (v) = ((v)&~(m))|(s) | ||
59 | |||
56 | #include "registers.h" | 60 | #include "registers.h" |
57 | 61 | ||
58 | #endif /* _ASM_ARCH_HARDWARE_H */ | 62 | #endif /* _ASM_ARCH_HARDWARE_H */ |
diff --git a/include/asm-arm/arch-lh7a40x/irqs.h b/include/asm-arm/arch-lh7a40x/irqs.h index f91f3e59f3ab..afe8c7cbad6a 100644 --- a/include/asm-arm/arch-lh7a40x/irqs.h +++ b/include/asm-arm/arch-lh7a40x/irqs.h | |||
@@ -18,7 +18,6 @@ | |||
18 | #ifndef __ASM_ARCH_IRQS_H | 18 | #ifndef __ASM_ARCH_IRQS_H |
19 | #define __ASM_ARCH_IRQS_H | 19 | #define __ASM_ARCH_IRQS_H |
20 | 20 | ||
21 | #include <linux/config.h> | ||
22 | 21 | ||
23 | #define FIQ_START 80 | 22 | #define FIQ_START 80 |
24 | 23 | ||
@@ -154,9 +153,10 @@ | |||
154 | #if !defined (IRQ_GPIO0INTR) | 153 | #if !defined (IRQ_GPIO0INTR) |
155 | # define IRQ_GPIO0INTR IRQ_GPIO0FIQ | 154 | # define IRQ_GPIO0INTR IRQ_GPIO0FIQ |
156 | #endif | 155 | #endif |
157 | #define IRQ_TICK IRQ_TINTR | 156 | #define IRQ_TICK IRQ_TINTR |
158 | #define IRQ_PCC1_RDY IRQ_GPIO6INTR /* PCCard 1 ready */ | 157 | #define IRQ_PCC1_RDY IRQ_GPIO6INTR /* PCCard 1 ready */ |
159 | #define IRQ_PCC2_RDY IRQ_GPIO7INTR /* PCCard 2 ready */ | 158 | #define IRQ_PCC2_RDY IRQ_GPIO7INTR /* PCCard 2 ready */ |
159 | #define IRQ_USB IRQ_USBINTR /* USB device */ | ||
160 | 160 | ||
161 | #ifdef CONFIG_MACH_KEV7A400 | 161 | #ifdef CONFIG_MACH_KEV7A400 |
162 | # define IRQ_TS IRQ_GPIOFIQ /* Touchscreen */ | 162 | # define IRQ_TS IRQ_GPIOFIQ /* Touchscreen */ |
@@ -191,6 +191,10 @@ | |||
191 | # define IRQ_LPD7A400_TS IRQ_LPD7A40X_CPLD + 1 /* Touch screen */ | 191 | # define IRQ_LPD7A400_TS IRQ_LPD7A40X_CPLD + 1 /* Touch screen */ |
192 | #endif | 192 | #endif |
193 | 193 | ||
194 | #if defined (CONFIG_MACH_LPD7A400) | ||
195 | # define IRQ_TOUCH IRQ_LPD7A400_TS | ||
196 | #endif | ||
197 | |||
194 | #define NR_IRQS (NR_IRQ_CPU + NR_IRQ_BOARD) | 198 | #define NR_IRQS (NR_IRQ_CPU + NR_IRQ_BOARD) |
195 | 199 | ||
196 | #endif | 200 | #endif |
diff --git a/include/asm-arm/arch-lh7a40x/registers.h b/include/asm-arm/arch-lh7a40x/registers.h index 2edb22e35450..b4f09b3e2d03 100644 --- a/include/asm-arm/arch-lh7a40x/registers.h +++ b/include/asm-arm/arch-lh7a40x/registers.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * | 9 | * |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <asm/arch/constants.h> | 12 | #include <asm/arch/constants.h> |
14 | 13 | ||
15 | #ifndef __ASM_ARCH_REGISTERS_H | 14 | #ifndef __ASM_ARCH_REGISTERS_H |
@@ -18,7 +17,7 @@ | |||
18 | 17 | ||
19 | /* Physical register base addresses */ | 18 | /* Physical register base addresses */ |
20 | 19 | ||
21 | #define AC97_PHYS (0x80000000) /* AC97 Controller */ | 20 | #define AC97C_PHYS (0x80000000) /* AC97 Controller */ |
22 | #define MMC_PHYS (0x80000100) /* Multimedia Card Controller */ | 21 | #define MMC_PHYS (0x80000100) /* Multimedia Card Controller */ |
23 | #define USB_PHYS (0x80000200) /* USB Client */ | 22 | #define USB_PHYS (0x80000200) /* USB Client */ |
24 | #define SCI_PHYS (0x80000300) /* Secure Card Interface */ | 23 | #define SCI_PHYS (0x80000300) /* Secure Card Interface */ |
@@ -35,6 +34,8 @@ | |||
35 | #define RTC_PHYS (0x80000d00) /* Real-time Clock */ | 34 | #define RTC_PHYS (0x80000d00) /* Real-time Clock */ |
36 | #define GPIO_PHYS (0x80000e00) /* General Purpose IO */ | 35 | #define GPIO_PHYS (0x80000e00) /* General Purpose IO */ |
37 | #define BMI_PHYS (0x80000f00) /* Battery Monitor Interface */ | 36 | #define BMI_PHYS (0x80000f00) /* Battery Monitor Interface */ |
37 | #define HRTFTC_PHYS (0x80001000) /* High-res TFT Controller (LH7A400) */ | ||
38 | #define ALI_PHYS (0x80001000) /* Advanced LCD Interface (LH7A404) */ | ||
38 | #define WDT_PHYS (0x80001400) /* Watchdog Timer */ | 39 | #define WDT_PHYS (0x80001400) /* Watchdog Timer */ |
39 | #define SMC_PHYS (0x80002000) /* Static Memory Controller */ | 40 | #define SMC_PHYS (0x80002000) /* Static Memory Controller */ |
40 | #define SDRC_PHYS (0x80002400) /* SDRAM Controller */ | 41 | #define SDRC_PHYS (0x80002400) /* SDRAM Controller */ |
@@ -43,6 +44,7 @@ | |||
43 | 44 | ||
44 | /* Physical registers of the LH7A404 */ | 45 | /* Physical registers of the LH7A404 */ |
45 | 46 | ||
47 | #define ADC_PHYS (0x80001300) /* A/D & Touchscreen Controller */ | ||
46 | #define VIC1_PHYS (0x80008000) /* Vectored Interrupt Controller 1 */ | 48 | #define VIC1_PHYS (0x80008000) /* Vectored Interrupt Controller 1 */ |
47 | #define USBH_PHYS (0x80009000) /* USB OHCI host controller */ | 49 | #define USBH_PHYS (0x80009000) /* USB OHCI host controller */ |
48 | #define VIC2_PHYS (0x8000a000) /* Vectored Interrupt Controller 2 */ | 50 | #define VIC2_PHYS (0x8000a000) /* Vectored Interrupt Controller 2 */ |
@@ -53,10 +55,32 @@ | |||
53 | 55 | ||
54 | /* Clock/State Controller register */ | 56 | /* Clock/State Controller register */ |
55 | 57 | ||
58 | #define CSC_PWRSR __REG(CSC_PHYS + 0x00) /* Reset register & ID */ | ||
56 | #define CSC_PWRCNT __REG(CSC_PHYS + 0x04) /* Power control */ | 59 | #define CSC_PWRCNT __REG(CSC_PHYS + 0x04) /* Power control */ |
60 | #define CSC_CLKSET __REG(CSC_PHYS + 0x20) /* Clock speed control */ | ||
61 | #define CSC_USBDRESET __REG(CSC_PHYS + 0x4c) /* USB Device resets */ | ||
57 | 62 | ||
58 | #define CSC_PWRCNT_USBH_EN (1<<28) /* USB Host power enable */ | 63 | #define CSC_PWRCNT_USBH_EN (1<<28) /* USB Host power enable */ |
59 | 64 | #define CSC_PWRCNT_DMAC_M2M1_EN (1<<27) | |
65 | #define CSC_PWRCNT_DMAC_M2M0_EN (1<<26) | ||
66 | #define CSC_PWRCNT_DMAC_M2P8_EN (1<<25) | ||
67 | #define CSC_PWRCNT_DMAC_M2P9_EN (1<<24) | ||
68 | #define CSC_PWRCNT_DMAC_M2P6_EN (1<<23) | ||
69 | #define CSC_PWRCNT_DMAC_M2P7_EN (1<<22) | ||
70 | #define CSC_PWRCNT_DMAC_M2P4_EN (1<<21) | ||
71 | #define CSC_PWRCNT_DMAC_M2P5_EN (1<<20) | ||
72 | #define CSC_PWRCNT_DMAC_M2P2_EN (1<<19) | ||
73 | #define CSC_PWRCNT_DMAC_M2P3_EN (1<<18) | ||
74 | #define CSC_PWRCNT_DMAC_M2P0_EN (1<<17) | ||
75 | #define CSC_PWRCNT_DMAC_M2P1_EN (1<<16) | ||
76 | |||
77 | #define CSC_PWRSR_CHIPMAN_SHIFT (24) | ||
78 | #define CSC_PWRSR_CHIPMAN_MASK (0xff) | ||
79 | #define CSC_PWRSR_CHIPID_SHIFT (16) | ||
80 | #define CSC_PWRSR_CHIPID_MASK (0xff) | ||
81 | |||
82 | #define CSC_USBDRESET_APBRESETREG (1<<1) | ||
83 | #define CSC_USBDRESET_IORESETREG (1<<0) | ||
60 | 84 | ||
61 | /* Interrupt Controller registers */ | 85 | /* Interrupt Controller registers */ |
62 | 86 | ||
@@ -109,6 +133,13 @@ | |||
109 | #define GPIO_GPIOFEOI __REG(GPIO_PHYS + 0x54) /* GPIO End-of-Interrupt */ | 133 | #define GPIO_GPIOFEOI __REG(GPIO_PHYS + 0x54) /* GPIO End-of-Interrupt */ |
110 | #define GPIO_GPIOINTEN __REG(GPIO_PHYS + 0x58) /* GPIO Interrupt Enable */ | 134 | #define GPIO_GPIOINTEN __REG(GPIO_PHYS + 0x58) /* GPIO Interrupt Enable */ |
111 | #define GPIO_INTSTATUS __REG(GPIO_PHYS + 0x5c) /* GPIO Interrupt Status */ | 135 | #define GPIO_INTSTATUS __REG(GPIO_PHYS + 0x5c) /* GPIO Interrupt Status */ |
136 | #define GPIO_PINMUX __REG(GPIO_PHYS + 0x2c) | ||
137 | #define GPIO_PADD __REG(GPIO_PHYS + 0x10) | ||
138 | #define GPIO_PAD __REG(GPIO_PHYS + 0x00) | ||
139 | #define GPIO_PCD __REG(GPIO_PHYS + 0x08) | ||
140 | #define GPIO_PCDD __REG(GPIO_PHYS + 0x18) | ||
141 | #define GPIO_PEDD __REG(GPIO_PHYS + 0x24) | ||
142 | #define GPIO_PED __REG(GPIO_PHYS + 0x20) | ||
112 | 143 | ||
113 | 144 | ||
114 | /* Static Memory Controller registers */ | 145 | /* Static Memory Controller registers */ |
@@ -138,20 +169,21 @@ | |||
138 | #endif | 169 | #endif |
139 | 170 | ||
140 | #if defined (CONFIG_MACH_LPD7A400) || defined (CONFIG_MACH_LPD7A404) | 171 | #if defined (CONFIG_MACH_LPD7A400) || defined (CONFIG_MACH_LPD7A404) |
141 | # define CPLD_CONTROL __REG8(CPLD02_PHYS) | ||
142 | # define CPLD_SPI_DATA __REG8(CPLD06_PHYS) | ||
143 | # define CPLD_SPI_CONTROL __REG8(CPLD08_PHYS) | ||
144 | # define CPLD_SPI_EEPROM __REG8(CPLD0A_PHYS) | ||
145 | # define CPLD_INTERRUPTS __REG8(CPLD0C_PHYS) /* IRQ mask/status */ | ||
146 | # define CPLD_BOOT_MODE __REG8(CPLD0E_PHYS) | ||
147 | # define CPLD_FLASH __REG8(CPLD10_PHYS) | ||
148 | # define CPLD_POWER_MGMT __REG8(CPLD12_PHYS) | ||
149 | # define CPLD_REVISION __REG8(CPLD14_PHYS) | ||
150 | # define CPLD_GPIO_EXT __REG8(CPLD16_PHYS) | ||
151 | # define CPLD_GPIO_DATA __REG8(CPLD18_PHYS) | ||
152 | # define CPLD_GPIO_DIR __REG8(CPLD1A_PHYS) | ||
153 | #endif | ||
154 | 172 | ||
173 | # define CPLD_CONTROL __REG16(CPLD02_PHYS) | ||
174 | # define CPLD_SPI_DATA __REG16(CPLD06_PHYS) | ||
175 | # define CPLD_SPI_CONTROL __REG16(CPLD08_PHYS) | ||
176 | # define CPLD_SPI_EEPROM __REG16(CPLD0A_PHYS) | ||
177 | # define CPLD_INTERRUPTS __REG16(CPLD0C_PHYS) /* IRQ mask/status */ | ||
178 | # define CPLD_BOOT_MODE __REG16(CPLD0E_PHYS) | ||
179 | # define CPLD_FLASH __REG16(CPLD10_PHYS) | ||
180 | # define CPLD_POWER_MGMT __REG16(CPLD12_PHYS) | ||
181 | # define CPLD_REVISION __REG16(CPLD14_PHYS) | ||
182 | # define CPLD_GPIO_EXT __REG16(CPLD16_PHYS) | ||
183 | # define CPLD_GPIO_DATA __REG16(CPLD18_PHYS) | ||
184 | # define CPLD_GPIO_DIR __REG16(CPLD1A_PHYS) | ||
185 | |||
186 | #endif | ||
155 | 187 | ||
156 | /* Timer registers */ | 188 | /* Timer registers */ |
157 | 189 | ||
@@ -190,4 +222,3 @@ | |||
190 | 222 | ||
191 | 223 | ||
192 | #endif /* _ASM_ARCH_REGISTERS_H */ | 224 | #endif /* _ASM_ARCH_REGISTERS_H */ |
193 | |||
diff --git a/include/asm-arm/arch-lh7a40x/ssp.h b/include/asm-arm/arch-lh7a40x/ssp.h new file mode 100644 index 000000000000..132b1c4d5ce6 --- /dev/null +++ b/include/asm-arm/arch-lh7a40x/ssp.h | |||
@@ -0,0 +1,71 @@ | |||
1 | /* ssp.h | ||
2 | $Id$ | ||
3 | |||
4 | written by Marc Singer | ||
5 | 6 Dec 2004 | ||
6 | |||
7 | Copyright (C) 2004 Marc Singer | ||
8 | |||
9 | ----------- | ||
10 | DESCRIPTION | ||
11 | ----------- | ||
12 | |||
13 | This SSP header is available throughout the kernel, for this | ||
14 | machine/architecture, because drivers that use it may be dispersed. | ||
15 | |||
16 | This file was cloned from the 7952x implementation. It would be | ||
17 | better to share them, but we're taking an easier approach for the | ||
18 | time being. | ||
19 | |||
20 | */ | ||
21 | |||
22 | #if !defined (__SSP_H__) | ||
23 | # define __SSP_H__ | ||
24 | |||
25 | /* ----- Includes */ | ||
26 | |||
27 | /* ----- Types */ | ||
28 | |||
29 | struct ssp_driver { | ||
30 | int (*init) (void); | ||
31 | void (*exit) (void); | ||
32 | void (*acquire) (void); | ||
33 | void (*release) (void); | ||
34 | int (*configure) (int device, int mode, int speed, | ||
35 | int frame_size_write, int frame_size_read); | ||
36 | void (*chip_select) (int enable); | ||
37 | void (*set_callbacks) (void* handle, | ||
38 | irqreturn_t (*callback_tx)(void*), | ||
39 | irqreturn_t (*callback_rx)(void*)); | ||
40 | void (*enable) (void); | ||
41 | void (*disable) (void); | ||
42 | // int (*save_state) (void*); | ||
43 | // void (*restore_state) (void*); | ||
44 | int (*read) (void); | ||
45 | int (*write) (u16 data); | ||
46 | int (*write_read) (u16 data); | ||
47 | void (*flush) (void); | ||
48 | void (*write_async) (void* pv, size_t cb); | ||
49 | size_t (*write_pos) (void); | ||
50 | }; | ||
51 | |||
52 | /* These modes are only available on the LH79524 */ | ||
53 | #define SSP_MODE_SPI (1) | ||
54 | #define SSP_MODE_SSI (2) | ||
55 | #define SSP_MODE_MICROWIRE (3) | ||
56 | #define SSP_MODE_I2S (4) | ||
57 | |||
58 | /* CPLD SPI devices */ | ||
59 | #define DEVICE_EEPROM 0 /* Configuration eeprom */ | ||
60 | #define DEVICE_MAC 1 /* MAC eeprom (LPD79524) */ | ||
61 | #define DEVICE_CODEC 2 /* Audio codec */ | ||
62 | #define DEVICE_TOUCH 3 /* Touch screen (LPD79520) */ | ||
63 | |||
64 | /* ----- Globals */ | ||
65 | |||
66 | /* ----- Prototypes */ | ||
67 | |||
68 | //extern struct ssp_driver lh79520_i2s_driver; | ||
69 | extern struct ssp_driver lh7a400_cpld_ssp_driver; | ||
70 | |||
71 | #endif /* __SSP_H__ */ | ||
diff --git a/include/asm-arm/arch-lh7a40x/uncompress.h b/include/asm-arm/arch-lh7a40x/uncompress.h index f8053346f608..3d1ce0426a33 100644 --- a/include/asm-arm/arch-lh7a40x/uncompress.h +++ b/include/asm-arm/arch-lh7a40x/uncompress.h | |||
@@ -16,7 +16,7 @@ | |||
16 | #ifndef UART_R_STATUS | 16 | #ifndef UART_R_STATUS |
17 | # define UART_R_STATUS (0x10) | 17 | # define UART_R_STATUS (0x10) |
18 | #endif | 18 | #endif |
19 | #define nTxRdy (0x20) /* Not TxReady (literally Tx FIFO full) */ | 19 | #define nTxRdy (0x20) /* Not TxReady (literally Tx FIFO full) */ |
20 | 20 | ||
21 | /* Access UART with physical addresses before MMU is setup */ | 21 | /* Access UART with physical addresses before MMU is setup */ |
22 | #define UART_STATUS (*(volatile unsigned long*) (UART2_PHYS + UART_R_STATUS)) | 22 | #define UART_STATUS (*(volatile unsigned long*) (UART2_PHYS + UART_R_STATUS)) |
diff --git a/include/asm-arm/arch-netx/debug-macro.S b/include/asm-arm/arch-netx/debug-macro.S new file mode 100644 index 000000000000..a940d0e80cb2 --- /dev/null +++ b/include/asm-arm/arch-netx/debug-macro.S | |||
@@ -0,0 +1,38 @@ | |||
1 | /* linux/include/asm-arm/arch-netx/debug-macro.S | ||
2 | * | ||
3 | * Debugging macro include header | ||
4 | * | ||
5 | * Copyright (C) 1994-1999 Russell King | ||
6 | * Moved from linux/arch/arm/kernel/debug.S by Ben Dooks | ||
7 | * | ||
8 | * This program is free software; you can redistribute it and/or modify | ||
9 | * it under the terms of the GNU General Public License version 2 as | ||
10 | * published by the Free Software Foundation. | ||
11 | * | ||
12 | */ | ||
13 | |||
14 | #include "hardware.h" | ||
15 | |||
16 | .macro addruart,rx | ||
17 | mrc p15, 0, \rx, c1, c0 | ||
18 | tst \rx, #1 @ MMU enabled? | ||
19 | moveq \rx, #0x00100000 @ physical | ||
20 | movne \rx, #io_p2v(0x00100000) @ virtual | ||
21 | orr \rx, \rx, #0x00000a00 | ||
22 | .endm | ||
23 | |||
24 | .macro senduart,rd,rx | ||
25 | str \rd, [\rx, #0] | ||
26 | .endm | ||
27 | |||
28 | .macro busyuart,rd,rx | ||
29 | 1002: ldr \rd, [\rx, #0x18] | ||
30 | tst \rd, #(1 << 3) | ||
31 | bne 1002b | ||
32 | .endm | ||
33 | |||
34 | .macro waituart,rd,rx | ||
35 | 1001: ldr \rd, [\rx, #0x18] | ||
36 | tst \rd, #(1 << 3) | ||
37 | bne 1001b | ||
38 | .endm | ||
diff --git a/include/asm-arm/arch-netx/dma.h b/include/asm-arm/arch-netx/dma.h new file mode 100644 index 000000000000..4eda5feed81c --- /dev/null +++ b/include/asm-arm/arch-netx/dma.h | |||
@@ -0,0 +1,21 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-netx/dma.h | ||
3 | * | ||
4 | * Copyright (C) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 | ||
8 | * as published by the Free Software Foundation. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
19 | |||
20 | #define MAX_DMA_CHANNELS 0 | ||
21 | #define MAX_DMA_ADDRESS ~0 | ||
diff --git a/include/asm-arm/arch-netx/entry-macro.S b/include/asm-arm/arch-netx/entry-macro.S new file mode 100644 index 000000000000..658df4d60ff3 --- /dev/null +++ b/include/asm-arm/arch-netx/entry-macro.S | |||
@@ -0,0 +1,35 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-netx/entry-macro.S | ||
3 | * | ||
4 | * Low-level IRQ helper macros for Hilscher netX based platforms | ||
5 | * | ||
6 | * Copyright (C) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
7 | * | ||
8 | * This program is free software; you can redistribute it and/or modify | ||
9 | * it under the terms of the GNU General Public License version 2 | ||
10 | * as published by the Free Software Foundation. | ||
11 | * | ||
12 | * This program is distributed in the hope that it will be useful, | ||
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
15 | * GNU General Public License for more details. | ||
16 | * | ||
17 | * You should have received a copy of the GNU General Public License | ||
18 | * along with this program; if not, write to the Free Software | ||
19 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
20 | */ | ||
21 | #include <asm/hardware.h> | ||
22 | |||
23 | .macro disable_fiq | ||
24 | .endm | ||
25 | |||
26 | .macro get_irqnr_and_base, irqnr, irqstat, base, tmp | ||
27 | mov \base, #io_p2v(0x00100000) | ||
28 | add \base, \base, #0x000ff000 | ||
29 | |||
30 | ldr \irqstat, [\base, #0] | ||
31 | clz \irqnr, \irqstat | ||
32 | rsb \irqnr, \irqnr, #31 | ||
33 | cmp \irqstat, #0 | ||
34 | .endm | ||
35 | |||
diff --git a/include/asm-arm/arch-netx/hardware.h b/include/asm-arm/arch-netx/hardware.h new file mode 100644 index 000000000000..7786c45455cd --- /dev/null +++ b/include/asm-arm/arch-netx/hardware.h | |||
@@ -0,0 +1,39 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-netx/hardware.h | ||
3 | * | ||
4 | * Copyright (C) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 | ||
8 | * as published by the Free Software Foundation. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
19 | #ifndef __ASM_ARCH_HARDWARE_H | ||
20 | #define __ASM_ARCH_HARDWARE_H | ||
21 | |||
22 | #define NETX_IO_PHYS 0x00100000 | ||
23 | #define NETX_IO_VIRT 0xe0000000 | ||
24 | #define NETX_IO_SIZE 0x00100000 | ||
25 | |||
26 | #define SRAM_INTERNAL_PHYS_0 0x00000 | ||
27 | #define SRAM_INTERNAL_PHYS_1 0x08000 | ||
28 | #define SRAM_INTERNAL_PHYS_2 0x10000 | ||
29 | #define SRAM_INTERNAL_PHYS_3 0x18000 | ||
30 | #define SRAM_INTERNAL_PHYS(no) ((no) * 0x8000) | ||
31 | |||
32 | #define XPEC_MEM_SIZE 0x4000 | ||
33 | #define XMAC_MEM_SIZE 0x1000 | ||
34 | #define SRAM_MEM_SIZE 0x8000 | ||
35 | |||
36 | #define io_p2v(x) ((x) - NETX_IO_PHYS + NETX_IO_VIRT) | ||
37 | #define io_v2p(x) ((x) - NETX_IO_VIRT + NETX_IO_PHYS) | ||
38 | |||
39 | #endif | ||
diff --git a/include/asm-arm/arch-netx/io.h b/include/asm-arm/arch-netx/io.h new file mode 100644 index 000000000000..81b7bc47747e --- /dev/null +++ b/include/asm-arm/arch-netx/io.h | |||
@@ -0,0 +1,29 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-netx/io.h | ||
3 | * | ||
4 | * Copyright (C) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 | ||
8 | * as published by the Free Software Foundation. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
19 | |||
20 | #ifndef __ASM_ARM_ARCH_IO_H | ||
21 | #define __ASM_ARM_ARCH_IO_H | ||
22 | |||
23 | #define IO_SPACE_LIMIT 0xffffffff | ||
24 | |||
25 | #define __io(a) ((void __iomem *)(a)) | ||
26 | #define __mem_pci(a) (a) | ||
27 | #define __mem_isa(a) (a) | ||
28 | |||
29 | #endif | ||
diff --git a/include/asm-arm/arch-netx/irqs.h b/include/asm-arm/arch-netx/irqs.h new file mode 100644 index 000000000000..a487dc6e2661 --- /dev/null +++ b/include/asm-arm/arch-netx/irqs.h | |||
@@ -0,0 +1,70 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-netx/irqs.h | ||
3 | * | ||
4 | * Copyright (C) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 | ||
8 | * as published by the Free Software Foundation. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
19 | |||
20 | #define NETX_IRQ_VIC_START 0 | ||
21 | #define NETX_IRQ_SOFTINT 0 | ||
22 | #define NETX_IRQ_TIMER0 1 | ||
23 | #define NETX_IRQ_TIMER1 2 | ||
24 | #define NETX_IRQ_TIMER2 3 | ||
25 | #define NETX_IRQ_SYSTIME_NS 4 | ||
26 | #define NETX_IRQ_SYSTIME_S 5 | ||
27 | #define NETX_IRQ_GPIO_15 6 | ||
28 | #define NETX_IRQ_WATCHDOG 7 | ||
29 | #define NETX_IRQ_UART0 8 | ||
30 | #define NETX_IRQ_UART1 9 | ||
31 | #define NETX_IRQ_UART2 10 | ||
32 | #define NETX_IRQ_USB 11 | ||
33 | #define NETX_IRQ_SPI 12 | ||
34 | #define NETX_IRQ_I2C 13 | ||
35 | #define NETX_IRQ_LCD 14 | ||
36 | #define NETX_IRQ_HIF 15 | ||
37 | #define NETX_IRQ_GPIO_0_14 16 | ||
38 | #define NETX_IRQ_XPEC0 17 | ||
39 | #define NETX_IRQ_XPEC1 18 | ||
40 | #define NETX_IRQ_XPEC2 19 | ||
41 | #define NETX_IRQ_XPEC3 20 | ||
42 | #define NETX_IRQ_XPEC(no) (17 + (no)) | ||
43 | #define NETX_IRQ_MSYNC0 21 | ||
44 | #define NETX_IRQ_MSYNC1 22 | ||
45 | #define NETX_IRQ_MSYNC2 23 | ||
46 | #define NETX_IRQ_MSYNC3 24 | ||
47 | #define NETX_IRQ_IRQ_PHY 25 | ||
48 | #define NETX_IRQ_ISO_AREA 26 | ||
49 | /* int 27 is reserved */ | ||
50 | /* int 28 is reserved */ | ||
51 | #define NETX_IRQ_TIMER3 29 | ||
52 | #define NETX_IRQ_TIMER4 30 | ||
53 | /* int 31 is reserved */ | ||
54 | |||
55 | #define NETX_IRQS 32 | ||
56 | |||
57 | /* for multiplexed irqs on gpio 0..14 */ | ||
58 | #define NETX_IRQ_GPIO(x) (NETX_IRQS + (x)) | ||
59 | #define NETX_IRQ_GPIO_LAST NETX_IRQ_GPIO(14) | ||
60 | |||
61 | /* Host interface interrupts */ | ||
62 | #define NETX_IRQ_HIF_CHAINED(x) (NETX_IRQ_GPIO_LAST + 1 + (x)) | ||
63 | #define NETX_IRQ_HIF_PIO35 NETX_IRQ_HIF_CHAINED(0) | ||
64 | #define NETX_IRQ_HIF_PIO36 NETX_IRQ_HIF_CHAINED(1) | ||
65 | #define NETX_IRQ_HIF_PIO40 NETX_IRQ_HIF_CHAINED(2) | ||
66 | #define NETX_IRQ_HIF_PIO47 NETX_IRQ_HIF_CHAINED(3) | ||
67 | #define NETX_IRQ_HIF_PIO72 NETX_IRQ_HIF_CHAINED(4) | ||
68 | #define NETX_IRQ_HIF_LAST NETX_IRQ_HIF_CHAINED(4) | ||
69 | |||
70 | #define NR_IRQS (NETX_IRQ_HIF_LAST + 1) | ||
diff --git a/include/asm-arm/arch-netx/memory.h b/include/asm-arm/arch-netx/memory.h new file mode 100644 index 000000000000..6d8d2df3e99d --- /dev/null +++ b/include/asm-arm/arch-netx/memory.h | |||
@@ -0,0 +1,36 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-netx/memory.h | ||
3 | * | ||
4 | * Copyright (C) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 | ||
8 | * as published by the Free Software Foundation. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
19 | |||
20 | #ifndef __ASM_ARCH_MEMORY_H | ||
21 | #define __ASM_ARCH_MEMORY_H | ||
22 | |||
23 | #define PHYS_OFFSET UL(0x80000000) | ||
24 | |||
25 | /* | ||
26 | * Virtual view <-> DMA view memory address translations | ||
27 | * virt_to_bus: Used to translate the virtual address to an | ||
28 | * address suitable to be passed to set_dma_addr | ||
29 | * bus_to_virt: Used to convert an address for DMA operations | ||
30 | * to an address that the kernel can use. | ||
31 | */ | ||
32 | #define __virt_to_bus(x) __virt_to_phys(x) | ||
33 | #define __bus_to_virt(x) __phys_to_virt(x) | ||
34 | |||
35 | #endif | ||
36 | |||
diff --git a/include/asm-arm/arch-netx/netx-regs.h b/include/asm-arm/arch-netx/netx-regs.h new file mode 100644 index 000000000000..8ab45bea83ca --- /dev/null +++ b/include/asm-arm/arch-netx/netx-regs.h | |||
@@ -0,0 +1,410 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-netx/netx-regs.h | ||
3 | * | ||
4 | * Copyright (c) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 | ||
8 | * as published by the Free Software Foundation. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
19 | |||
20 | #ifndef __ASM_ARCH_NETX_REGS_H | ||
21 | #define __ASM_ARCH_NETX_REGS_H | ||
22 | |||
23 | /* offsets relative to the beginning of the io space */ | ||
24 | #define NETX_OFS_SYSTEM 0x00000 | ||
25 | #define NETX_OFS_MEMCR 0x00100 | ||
26 | #define NETX_OFS_DPMAS 0x03000 | ||
27 | #define NETX_OFS_GPIO 0x00800 | ||
28 | #define NETX_OFS_PIO 0x00900 | ||
29 | #define NETX_OFS_UART0 0x00a00 | ||
30 | #define NETX_OFS_UART1 0x00a40 | ||
31 | #define NETX_OFS_UART2 0x00a80 | ||
32 | #define NETX_OF_MIIMU 0x00b00 | ||
33 | #define NETX_OFS_SPI 0x00c00 | ||
34 | #define NETX_OFS_I2C 0x00d00 | ||
35 | #define NETX_OFS_SYSTIME 0x01100 | ||
36 | #define NETX_OFS_RTC 0x01200 | ||
37 | #define NETX_OFS_EXTBUS 0x03600 | ||
38 | #define NETX_OFS_LCD 0x04000 | ||
39 | #define NETX_OFS_USB 0x20000 | ||
40 | #define NETX_OFS_XMAC0 0x60000 | ||
41 | #define NETX_OFS_XMAC1 0x61000 | ||
42 | #define NETX_OFS_XMAC2 0x62000 | ||
43 | #define NETX_OFS_XMAC3 0x63000 | ||
44 | #define NETX_OFS_XMAC(no) (0x60000 + (no) * 0x1000) | ||
45 | #define NETX_OFS_PFIFO 0x64000 | ||
46 | #define NETX_OFS_XPEC0 0x70000 | ||
47 | #define NETX_OFS_XPEC1 0x74000 | ||
48 | #define NETX_OFS_XPEC2 0x78000 | ||
49 | #define NETX_OFS_XPEC3 0x7c000 | ||
50 | #define NETX_OFS_XPEC(no) (0x70000 + (no) * 0x4000) | ||
51 | #define NETX_OFS_VIC 0xff000 | ||
52 | |||
53 | /* physical addresses */ | ||
54 | #define NETX_PA_SYSTEM (NETX_IO_PHYS + NETX_OFS_SYSTEM) | ||
55 | #define NETX_PA_MEMCR (NETX_IO_PHYS + NETX_OFS_MEMCR) | ||
56 | #define NETX_PA_DPMAS (NETX_IO_PHYS + NETX_OFS_DPMAS) | ||
57 | #define NETX_PA_GPIO (NETX_IO_PHYS + NETX_OFS_GPIO) | ||
58 | #define NETX_PA_PIO (NETX_IO_PHYS + NETX_OFS_PIO) | ||
59 | #define NETX_PA_UART0 (NETX_IO_PHYS + NETX_OFS_UART0) | ||
60 | #define NETX_PA_UART1 (NETX_IO_PHYS + NETX_OFS_UART1) | ||
61 | #define NETX_PA_UART2 (NETX_IO_PHYS + NETX_OFS_UART2) | ||
62 | #define NETX_PA_MIIMU (NETX_IO_PHYS + NETX_OF_MIIMU) | ||
63 | #define NETX_PA_SPI (NETX_IO_PHYS + NETX_OFS_SPI) | ||
64 | #define NETX_PA_I2C (NETX_IO_PHYS + NETX_OFS_I2C) | ||
65 | #define NETX_PA_SYSTIME (NETX_IO_PHYS + NETX_OFS_SYSTIME) | ||
66 | #define NETX_PA_RTC (NETX_IO_PHYS + NETX_OFS_RTC) | ||
67 | #define NETX_PA_EXTBUS (NETX_IO_PHYS + NETX_OFS_EXTBUS) | ||
68 | #define NETX_PA_LCD (NETX_IO_PHYS + NETX_OFS_LCD) | ||
69 | #define NETX_PA_USB (NETX_IO_PHYS + NETX_OFS_USB) | ||
70 | #define NETX_PA_XMAC0 (NETX_IO_PHYS + NETX_OFS_XMAC0) | ||
71 | #define NETX_PA_XMAC1 (NETX_IO_PHYS + NETX_OFS_XMAC1) | ||
72 | #define NETX_PA_XMAC2 (NETX_IO_PHYS + NETX_OFS_XMAC2) | ||
73 | #define NETX_PA_XMAC3 (NETX_IO_PHYS + NETX_OFS_XMAC3) | ||
74 | #define NETX_PA_XMAC(no) (NETX_IO_PHYS + NETX_OFS_XMAC(no)) | ||
75 | #define NETX_PA_PFIFO (NETX_IO_PHYS + NETX_OFS_PFIFO) | ||
76 | #define NETX_PA_XPEC0 (NETX_IO_PHYS + NETX_OFS_XPEC0) | ||
77 | #define NETX_PA_XPEC1 (NETX_IO_PHYS + NETX_OFS_XPEC1) | ||
78 | #define NETX_PA_XPEC2 (NETX_IO_PHYS + NETX_OFS_XPEC2) | ||
79 | #define NETX_PA_XPEC3 (NETX_IO_PHYS + NETX_OFS_XPEC3) | ||
80 | #define NETX_PA_XPEC(no) (NETX_IO_PHYS + NETX_OFS_XPEC(no)) | ||
81 | #define NETX_PA_VIC (NETX_IO_PHYS + NETX_OFS_VIC) | ||
82 | |||
83 | /* virual addresses */ | ||
84 | #define NETX_VA_SYSTEM (NETX_IO_VIRT + NETX_OFS_SYSTEM) | ||
85 | #define NETX_VA_MEMCR (NETX_IO_VIRT + NETX_OFS_MEMCR) | ||
86 | #define NETX_VA_DPMAS (NETX_IO_VIRT + NETX_OFS_DPMAS) | ||
87 | #define NETX_VA_GPIO (NETX_IO_VIRT + NETX_OFS_GPIO) | ||
88 | #define NETX_VA_PIO (NETX_IO_VIRT + NETX_OFS_PIO) | ||
89 | #define NETX_VA_UART0 (NETX_IO_VIRT + NETX_OFS_UART0) | ||
90 | #define NETX_VA_UART1 (NETX_IO_VIRT + NETX_OFS_UART1) | ||
91 | #define NETX_VA_UART2 (NETX_IO_VIRT + NETX_OFS_UART2) | ||
92 | #define NETX_VA_MIIMU (NETX_IO_VIRT + NETX_OF_MIIMU) | ||
93 | #define NETX_VA_SPI (NETX_IO_VIRT + NETX_OFS_SPI) | ||
94 | #define NETX_VA_I2C (NETX_IO_VIRT + NETX_OFS_I2C) | ||
95 | #define NETX_VA_SYSTIME (NETX_IO_VIRT + NETX_OFS_SYSTIME) | ||
96 | #define NETX_VA_RTC (NETX_IO_VIRT + NETX_OFS_RTC) | ||
97 | #define NETX_VA_EXTBUS (NETX_IO_VIRT + NETX_OFS_EXTBUS) | ||
98 | #define NETX_VA_LCD (NETX_IO_VIRT + NETX_OFS_LCD) | ||
99 | #define NETX_VA_USB (NETX_IO_VIRT + NETX_OFS_USB) | ||
100 | #define NETX_VA_XMAC0 (NETX_IO_VIRT + NETX_OFS_XMAC0) | ||
101 | #define NETX_VA_XMAC1 (NETX_IO_VIRT + NETX_OFS_XMAC1) | ||
102 | #define NETX_VA_XMAC2 (NETX_IO_VIRT + NETX_OFS_XMAC2) | ||
103 | #define NETX_VA_XMAC3 (NETX_IO_VIRT + NETX_OFS_XMAC3) | ||
104 | #define NETX_VA_XMAC(no) (NETX_IO_VIRT + NETX_OFS_XMAC(no)) | ||
105 | #define NETX_VA_PFIFO (NETX_IO_VIRT + NETX_OFS_PFIFO) | ||
106 | #define NETX_VA_XPEC0 (NETX_IO_VIRT + NETX_OFS_XPEC0) | ||
107 | #define NETX_VA_XPEC1 (NETX_IO_VIRT + NETX_OFS_XPEC1) | ||
108 | #define NETX_VA_XPEC2 (NETX_IO_VIRT + NETX_OFS_XPEC2) | ||
109 | #define NETX_VA_XPEC3 (NETX_IO_VIRT + NETX_OFS_XPEC3) | ||
110 | #define NETX_VA_XPEC(no) (NETX_IO_VIRT + NETX_OFS_XPEC(no)) | ||
111 | #define NETX_VA_VIC (NETX_IO_VIRT + NETX_OFS_VIC) | ||
112 | |||
113 | /********************************* | ||
114 | * System functions * | ||
115 | *********************************/ | ||
116 | |||
117 | /* Registers */ | ||
118 | #define NETX_SYSTEM_REG(ofs) __io(NETX_VA_SYSTEM + (ofs)) | ||
119 | #define NETX_SYSTEM_BOO_SR NETX_SYSTEM_REG(0x00) | ||
120 | #define NETX_SYSTEM_IOC_CR NETX_SYSTEM_REG(0x04) | ||
121 | #define NETX_SYSTEM_IOC_MR NETX_SYSTEM_REG(0x08) | ||
122 | |||
123 | /* FIXME: Docs are not consistent */ | ||
124 | #define NETX_SYSTEM_RES_CR NETX_SYSTEM_REG(0x08) | ||
125 | /* #define NETX_SYSTEM_RES_CR NETX_SYSTEM_REG(0x0c) */ | ||
126 | |||
127 | #define NETX_SYSTEM_PHY_CONTROL NETX_SYSTEM_REG(0x10) | ||
128 | #define NETX_SYSTEM_REV NETX_SYSTEM_REG(0x34) | ||
129 | #define NETX_SYSTEM_IOC_ACCESS_KEY NETX_SYSTEM_REG(0x70) | ||
130 | #define NETX_SYSTEM_WDG_TR NETX_SYSTEM_REG(0x200) | ||
131 | #define NETX_SYSTEM_WDG_CTR NETX_SYSTEM_REG(0x204) | ||
132 | #define NETX_SYSTEM_WDG_IRQ_TIMEOUT NETX_SYSTEM_REG(0x208) | ||
133 | #define NETX_SYSTEM_WDG_RES_TIMEOUT NETX_SYSTEM_REG(0x20c) | ||
134 | |||
135 | /* Bits */ | ||
136 | #define NETX_SYSTEM_RES_CR_RSTIN (1<<0) | ||
137 | #define NETX_SYSTEM_RES_CR_WDG_RES (1<<1) | ||
138 | #define NETX_SYSTEM_RES_CR_HOST_RES (1<<2) | ||
139 | #define NETX_SYSTEM_RES_CR_FIRMW_RES (1<<3) | ||
140 | #define NETX_SYSTEM_RES_CR_XPEC0_RES (1<<4) | ||
141 | #define NETX_SYSTEM_RES_CR_XPEC1_RES (1<<5) | ||
142 | #define NETX_SYSTEM_RES_CR_XPEC2_RES (1<<6) | ||
143 | #define NETX_SYSTEM_RES_CR_XPEC3_RES (1<<7) | ||
144 | #define NETX_SYSTEM_RES_CR_DIS_XPEC0_RES (1<<16) | ||
145 | #define NETX_SYSTEM_RES_CR_DIS_XPEC1_RES (1<<17) | ||
146 | #define NETX_SYSTEM_RES_CR_DIS_XPEC2_RES (1<<18) | ||
147 | #define NETX_SYSTEM_RES_CR_DIS_XPEC3_RES (1<<19) | ||
148 | #define NETX_SYSTEM_RES_CR_FIRMW_FLG0 (1<<20) | ||
149 | #define NETX_SYSTEM_RES_CR_FIRMW_FLG1 (1<<21) | ||
150 | #define NETX_SYSTEM_RES_CR_FIRMW_FLG2 (1<<22) | ||
151 | #define NETX_SYSTEM_RES_CR_FIRMW_FLG3 (1<<23) | ||
152 | #define NETX_SYSTEM_RES_CR_FIRMW_RES_EN (1<<24) | ||
153 | #define NETX_SYSTEM_RES_CR_RSTOUT (1<<25) | ||
154 | #define NETX_SYSTEM_RES_CR_EN_RSTOUT (1<<26) | ||
155 | |||
156 | #define PHY_CONTROL_RESET (1<<31) | ||
157 | #define PHY_CONTROL_SIM_BYP (1<<30) | ||
158 | #define PHY_CONTROL_CLK_XLATIN (1<<29) | ||
159 | #define PHY_CONTROL_PHY1_EN (1<<21) | ||
160 | #define PHY_CONTROL_PHY1_NP_MSG_CODE | ||
161 | #define PHY_CONTROL_PHY1_AUTOMDIX (1<<17) | ||
162 | #define PHY_CONTROL_PHY1_FIXMODE (1<<16) | ||
163 | #define PHY_CONTROL_PHY1_MODE(mode) (((mode) & 0x7) << 13) | ||
164 | #define PHY_CONTROL_PHY0_EN (1<<12) | ||
165 | #define PHY_CONTROL_PHY0_NP_MSG_CODE | ||
166 | #define PHY_CONTROL_PHY0_AUTOMDIX (1<<8) | ||
167 | #define PHY_CONTROL_PHY0_FIXMODE (1<<7) | ||
168 | #define PHY_CONTROL_PHY0_MODE(mode) (((mode) & 0x7) << 4) | ||
169 | #define PHY_CONTROL_PHY_ADDRESS(adr) ((adr) & 0xf) | ||
170 | |||
171 | #define PHY_MODE_10BASE_T_HALF 0 | ||
172 | #define PHY_MODE_10BASE_T_FULL 1 | ||
173 | #define PHY_MODE_100BASE_TX_FX_FULL 2 | ||
174 | #define PHY_MODE_100BASE_TX_FX_HALF 3 | ||
175 | #define PHY_MODE_100BASE_TX_HALF 4 | ||
176 | #define PHY_MODE_REPEATER 5 | ||
177 | #define PHY_MODE_POWER_DOWN 6 | ||
178 | #define PHY_MODE_ALL 7 | ||
179 | |||
180 | /* Bits */ | ||
181 | #define VECT_CNTL_ENABLE (1 << 5) | ||
182 | |||
183 | /******************************* | ||
184 | * GPIO and timer module * | ||
185 | *******************************/ | ||
186 | |||
187 | /* Registers */ | ||
188 | #define NETX_GPIO_REG(ofs) __io(NETX_VA_GPIO + (ofs)) | ||
189 | #define NETX_GPIO_CFG(gpio) NETX_GPIO_REG(0x0 + ((gpio)<<2)) | ||
190 | #define NETX_GPIO_THRESHOLD_CAPTURE(gpio) NETX_GPIO_REG(0x40 + ((gpio)<<2)) | ||
191 | #define NETX_GPIO_COUNTER_CTRL(counter) NETX_GPIO_REG(0x80 + ((counter)<<2)) | ||
192 | #define NETX_GPIO_COUNTER_MAX(counter) NETX_GPIO_REG(0x94 + ((counter)<<2)) | ||
193 | #define NETX_GPIO_COUNTER_CURRENT(counter) NETX_GPIO_REG(0xa8 + ((counter)<<2)) | ||
194 | #define NETX_GPIO_IRQ_ENABLE NETX_GPIO_REG(0xbc) | ||
195 | #define NETX_GPIO_IRQ_DISABLE NETX_GPIO_REG(0xc0) | ||
196 | #define NETX_GPIO_SYSTIME_NS_CMP NETX_GPIO_REG(0xc4) | ||
197 | #define NETX_GPIO_LINE NETX_GPIO_REG(0xc8) | ||
198 | #define NETX_GPIO_IRQ NETX_GPIO_REG(0xd0) | ||
199 | |||
200 | /* Bits */ | ||
201 | #define NETX_GPIO_CFG_IOCFG_GP_INPUT (0x0) | ||
202 | #define NETX_GPIO_CFG_IOCFG_GP_OUTPUT (0x1) | ||
203 | #define NETX_GPIO_CFG_IOCFG_GP_UART (0x2) | ||
204 | #define NETX_GPIO_CFG_INV (1<<2) | ||
205 | #define NETX_GPIO_CFG_MODE_INPUT_READ (0<<3) | ||
206 | #define NETX_GPIO_CFG_MODE_INPUT_CAPTURE_CONT_RISING (1<<3) | ||
207 | #define NETX_GPIO_CFG_MODE_INPUT_CAPTURE_ONCE_RISING (2<<3) | ||
208 | #define NETX_GPIO_CFG_MODE_INPUT_CAPTURE_HIGH_LEVEL (3<<3) | ||
209 | #define NETX_GPIO_CFG_COUNT_REF_COUNTER0 (0<<5) | ||
210 | #define NETX_GPIO_CFG_COUNT_REF_COUNTER1 (1<<5) | ||
211 | #define NETX_GPIO_CFG_COUNT_REF_COUNTER2 (2<<5) | ||
212 | #define NETX_GPIO_CFG_COUNT_REF_COUNTER3 (3<<5) | ||
213 | #define NETX_GPIO_CFG_COUNT_REF_COUNTER4 (4<<5) | ||
214 | #define NETX_GPIO_CFG_COUNT_REF_SYSTIME (7<<5) | ||
215 | |||
216 | #define NETX_GPIO_COUNTER_CTRL_RUN (1<<0) | ||
217 | #define NETX_GPIO_COUNTER_CTRL_SYM (1<<1) | ||
218 | #define NETX_GPIO_COUNTER_CTRL_ONCE (1<<2) | ||
219 | #define NETX_GPIO_COUNTER_CTRL_IRQ_EN (1<<3) | ||
220 | #define NETX_GPIO_COUNTER_CTRL_CNT_EVENT (1<<4) | ||
221 | #define NETX_GPIO_COUNTER_CTRL_RST_EN (1<<5) | ||
222 | #define NETX_GPIO_COUNTER_CTRL_SEL_EVENT (1<<6) | ||
223 | #define NETX_GPIO_COUNTER_CTRL_GPIO_REF /* FIXME */ | ||
224 | |||
225 | #define GPIO_BIT(gpio) (1<<(gpio)) | ||
226 | #define COUNTER_BIT(counter) ((1<<16)<<(counter)) | ||
227 | |||
228 | /******************************* | ||
229 | * PIO * | ||
230 | *******************************/ | ||
231 | |||
232 | /* Registers */ | ||
233 | #define NETX_PIO_REG(ofs) __io(NETX_VA_PIO + (ofs)) | ||
234 | #define NETX_PIO_INPIO NETX_PIO_REG(0x0) | ||
235 | #define NETX_PIO_OUTPIO NETX_PIO_REG(0x4) | ||
236 | #define NETX_PIO_OEPIO NETX_PIO_REG(0x8) | ||
237 | |||
238 | /******************************* | ||
239 | * MII Unit * | ||
240 | *******************************/ | ||
241 | |||
242 | /* Registers */ | ||
243 | #define NETX_MIIMU __io(NETX_VA_MIIMU) | ||
244 | |||
245 | /* Bits */ | ||
246 | #define MIIMU_SNRDY (1<<0) | ||
247 | #define MIIMU_PREAMBLE (1<<1) | ||
248 | #define MIIMU_OPMODE_WRITE (1<<2) | ||
249 | #define MIIMU_MDC_PERIOD (1<<3) | ||
250 | #define MIIMU_PHY_NRES (1<<4) | ||
251 | #define MIIMU_RTA (1<<5) | ||
252 | #define MIIMU_REGADDR(adr) (((adr) & 0x1f) << 6) | ||
253 | #define MIIMU_PHYADDR(adr) (((adr) & 0x1f) << 11) | ||
254 | #define MIIMU_DATA(data) (((data) & 0xffff) << 16) | ||
255 | |||
256 | /******************************* | ||
257 | * xmac / xpec * | ||
258 | *******************************/ | ||
259 | |||
260 | /* XPEC register offsets relative to NETX_VA_XPEC(no) */ | ||
261 | #define NETX_XPEC_R0_OFS 0x00 | ||
262 | #define NETX_XPEC_R1_OFS 0x04 | ||
263 | #define NETX_XPEC_R2_OFS 0x08 | ||
264 | #define NETX_XPEC_R3_OFS 0x0c | ||
265 | #define NETX_XPEC_R4_OFS 0x10 | ||
266 | #define NETX_XPEC_R5_OFS 0x14 | ||
267 | #define NETX_XPEC_R6_OFS 0x18 | ||
268 | #define NETX_XPEC_R7_OFS 0x1c | ||
269 | #define NETX_XPEC_RANGE01_OFS 0x20 | ||
270 | #define NETX_XPEC_RANGE23_OFS 0x24 | ||
271 | #define NETX_XPEC_RANGE45_OFS 0x28 | ||
272 | #define NETX_XPEC_RANGE67_OFS 0x2c | ||
273 | #define NETX_XPEC_PC_OFS 0x48 | ||
274 | #define NETX_XPEC_TIMER_OFS(timer) (0x30 + ((timer)<<2)) | ||
275 | #define NETX_XPEC_IRQ_OFS 0x8c | ||
276 | #define NETX_XPEC_SYSTIME_NS_OFS 0x90 | ||
277 | #define NETX_XPEC_FIFO_DATA_OFS 0x94 | ||
278 | #define NETX_XPEC_SYSTIME_S_OFS 0x98 | ||
279 | #define NETX_XPEC_ADC_OFS 0x9c | ||
280 | #define NETX_XPEC_URX_COUNT_OFS 0x40 | ||
281 | #define NETX_XPEC_UTX_COUNT_OFS 0x44 | ||
282 | #define NETX_XPEC_PC_OFS 0x48 | ||
283 | #define NETX_XPEC_ZERO_OFS 0x4c | ||
284 | #define NETX_XPEC_STATCFG_OFS 0x50 | ||
285 | #define NETX_XPEC_EC_MASKA_OFS 0x54 | ||
286 | #define NETX_XPEC_EC_MASKB_OFS 0x58 | ||
287 | #define NETX_XPEC_EC_MASK0_OFS 0x5c | ||
288 | #define NETX_XPEC_EC_MASK8_OFS 0x7c | ||
289 | #define NETX_XPEC_EC_MASK9_OFS 0x80 | ||
290 | #define NETX_XPEC_XPU_HOLD_PC_OFS 0x100 | ||
291 | #define NETX_XPEC_RAM_START_OFS 0x2000 | ||
292 | |||
293 | /* Bits */ | ||
294 | #define XPU_HOLD_PC (1<<0) | ||
295 | |||
296 | /* XMAC register offsets relative to NETX_VA_XMAC(no) */ | ||
297 | #define NETX_XMAC_RPU_PROGRAM_START_OFS 0x000 | ||
298 | #define NETX_XMAC_RPU_PROGRAM_END_OFS 0x3ff | ||
299 | #define NETX_XMAC_TPU_PROGRAM_START_OFS 0x400 | ||
300 | #define NETX_XMAC_TPU_PROGRAM_END_OFS 0x7ff | ||
301 | #define NETX_XMAC_RPU_HOLD_PC_OFS 0xa00 | ||
302 | #define NETX_XMAC_TPU_HOLD_PC_OFS 0xa04 | ||
303 | #define NETX_XMAC_STATUS_SHARED0_OFS 0x840 | ||
304 | #define NETX_XMAC_CONFIG_SHARED0_OFS 0x844 | ||
305 | #define NETX_XMAC_STATUS_SHARED1_OFS 0x848 | ||
306 | #define NETX_XMAC_CONFIG_SHARED1_OFS 0x84c | ||
307 | #define NETX_XMAC_STATUS_SHARED2_OFS 0x850 | ||
308 | #define NETX_XMAC_CONFIG_SHARED2_OFS 0x854 | ||
309 | #define NETX_XMAC_STATUS_SHARED3_OFS 0x858 | ||
310 | #define NETX_XMAC_CONFIG_SHARED3_OFS 0x85c | ||
311 | |||
312 | #define RPU_HOLD_PC (1<<15) | ||
313 | #define TPU_HOLD_PC (1<<15) | ||
314 | |||
315 | /******************************* | ||
316 | * Pointer FIFO * | ||
317 | *******************************/ | ||
318 | |||
319 | /* Registers */ | ||
320 | #define NETX_PFIFO_REG(ofs) __io(NETX_VA_PFIFO + (ofs)) | ||
321 | #define NETX_PFIFO_BASE(pfifo) NETX_PFIFO_REG(0x00 + ((pfifo)<<2)) | ||
322 | #define NETX_PFIFO_BORDER_BASE(pfifo) NETX_PFIFO_REG(0x80 + ((pfifo)<<2)) | ||
323 | #define NETX_PFIFO_RESET NETX_PFIFO_REG(0x100) | ||
324 | #define NETX_PFIFO_FULL NETX_PFIFO_REG(0x104) | ||
325 | #define NETX_PFIFO_EMPTY NETX_PFIFO_REG(0x108) | ||
326 | #define NETX_PFIFO_OVEFLOW NETX_PFIFO_REG(0x10c) | ||
327 | #define NETX_PFIFO_UNDERRUN NETX_PFIFO_REG(0x110) | ||
328 | #define NETX_PFIFO_FILL_LEVEL(pfifo) NETX_PFIFO_REG(0x180 + ((pfifo)<<2)) | ||
329 | #define NETX_PFIFO_XPEC_ISR(xpec) NETX_PFIFO_REG(0x400 + ((xpec) << 2)) | ||
330 | |||
331 | /******************************* | ||
332 | * Dual Port Memory * | ||
333 | *******************************/ | ||
334 | |||
335 | /* Registers */ | ||
336 | #define NETX_DPMAS_REG(ofs) __io(NETX_VA_DPMAS + (ofs)) | ||
337 | #define NETX_DPMAS_SYS_STAT NETX_DPMAS_REG(0x4d8) | ||
338 | #define NETX_DPMAS_INT_STAT NETX_DPMAS_REG(0x4e0) | ||
339 | #define NETX_DPMAS_INT_EN NETX_DPMAS_REG(0x4f0) | ||
340 | #define NETX_DPMAS_IF_CONF0 NETX_DPMAS_REG(0x608) | ||
341 | #define NETX_DPMAS_IF_CONF1 NETX_DPMAS_REG(0x60c) | ||
342 | #define NETX_DPMAS_EXT_CONFIG(cs) NETX_DPMAS_REG(0x610 + 4 * (cs)) | ||
343 | #define NETX_DPMAS_IO_MODE0 NETX_DPMAS_REG(0x620) /* I/O 32..63 */ | ||
344 | #define NETX_DPMAS_DRV_EN0 NETX_DPMAS_REG(0x624) | ||
345 | #define NETX_DPMAS_DATA0 NETX_DPMAS_REG(0x628) | ||
346 | #define NETX_DPMAS_IO_MODE1 NETX_DPMAS_REG(0x630) /* I/O 64..84 */ | ||
347 | #define NETX_DPMAS_DRV_EN1 NETX_DPMAS_REG(0x634) | ||
348 | #define NETX_DPMAS_DATA1 NETX_DPMAS_REG(0x638) | ||
349 | |||
350 | /* Bits */ | ||
351 | #define NETX_DPMAS_INT_EN_GLB_EN (1<<31) | ||
352 | #define NETX_DPMAS_INT_EN_MEM_LCK (1<<30) | ||
353 | #define NETX_DPMAS_INT_EN_WDG (1<<29) | ||
354 | #define NETX_DPMAS_INT_EN_PIO72 (1<<28) | ||
355 | #define NETX_DPMAS_INT_EN_PIO47 (1<<27) | ||
356 | #define NETX_DPMAS_INT_EN_PIO40 (1<<26) | ||
357 | #define NETX_DPMAS_INT_EN_PIO36 (1<<25) | ||
358 | #define NETX_DPMAS_INT_EN_PIO35 (1<<24) | ||
359 | |||
360 | #define NETX_DPMAS_IF_CONF0_HIF_DISABLED (0<<28) | ||
361 | #define NETX_DPMAS_IF_CONF0_HIF_EXT_BUS (1<<28) | ||
362 | #define NETX_DPMAS_IF_CONF0_HIF_UP_8BIT (2<<28) | ||
363 | #define NETX_DPMAS_IF_CONF0_HIF_UP_16BIT (3<<28) | ||
364 | #define NETX_DPMAS_IF_CONF0_HIF_IO (4<<28) | ||
365 | #define NETX_DPMAS_IF_CONF0_WAIT_DRV_PP (1<<14) | ||
366 | #define NETX_DPMAS_IF_CONF0_WAIT_DRV_OD (2<<14) | ||
367 | #define NETX_DPMAS_IF_CONF0_WAIT_DRV_TRI (3<<14) | ||
368 | |||
369 | #define NETX_DPMAS_IF_CONF1_IRQ_POL_PIO35 (1<<26) | ||
370 | #define NETX_DPMAS_IF_CONF1_IRQ_POL_PIO36 (1<<27) | ||
371 | #define NETX_DPMAS_IF_CONF1_IRQ_POL_PIO40 (1<<28) | ||
372 | #define NETX_DPMAS_IF_CONF1_IRQ_POL_PIO47 (1<<29) | ||
373 | #define NETX_DPMAS_IF_CONF1_IRQ_POL_PIO72 (1<<30) | ||
374 | |||
375 | #define NETX_EXT_CONFIG_TALEWIDTH(x) (((x) & 0x7) << 29) | ||
376 | #define NETX_EXT_CONFIG_TADRHOLD(x) (((x) & 0x7) << 26) | ||
377 | #define NETX_EXT_CONFIG_TCSON(x) (((x) & 0x7) << 23) | ||
378 | #define NETX_EXT_CONFIG_TRDON(x) (((x) & 0x7) << 20) | ||
379 | #define NETX_EXT_CONFIG_TWRON(x) (((x) & 0x7) << 17) | ||
380 | #define NETX_EXT_CONFIG_TWROFF(x) (((x) & 0x1f) << 12) | ||
381 | #define NETX_EXT_CONFIG_TRDWRCYC(x) (((x) & 0x1f) << 7) | ||
382 | #define NETX_EXT_CONFIG_WAIT_POL (1<<6) | ||
383 | #define NETX_EXT_CONFIG_WAIT_EN (1<<5) | ||
384 | #define NETX_EXT_CONFIG_NRD_MODE (1<<4) | ||
385 | #define NETX_EXT_CONFIG_DS_MODE (1<<3) | ||
386 | #define NETX_EXT_CONFIG_NWR_MODE (1<<2) | ||
387 | #define NETX_EXT_CONFIG_16BIT (1<<1) | ||
388 | #define NETX_EXT_CONFIG_CS_ENABLE (1<<0) | ||
389 | |||
390 | #define NETX_DPMAS_IO_MODE0_WRL (1<<13) | ||
391 | #define NETX_DPMAS_IO_MODE0_WAIT (1<<14) | ||
392 | #define NETX_DPMAS_IO_MODE0_READY (1<<15) | ||
393 | #define NETX_DPMAS_IO_MODE0_CS0 (1<<19) | ||
394 | #define NETX_DPMAS_IO_MODE0_EXTRD (1<<20) | ||
395 | |||
396 | #define NETX_DPMAS_IO_MODE1_CS2 (1<<15) | ||
397 | #define NETX_DPMAS_IO_MODE1_CS1 (1<<16) | ||
398 | #define NETX_DPMAS_IO_MODE1_SAMPLE_NPOR (0<<30) | ||
399 | #define NETX_DPMAS_IO_MODE1_SAMPLE_100MHZ (1<<30) | ||
400 | #define NETX_DPMAS_IO_MODE1_SAMPLE_NPIO36 (2<<30) | ||
401 | #define NETX_DPMAS_IO_MODE1_SAMPLE_PIO36 (3<<30) | ||
402 | |||
403 | /******************************* | ||
404 | * I2C * | ||
405 | *******************************/ | ||
406 | #define NETX_I2C_REG(ofs) __io(NETX_VA_I2C, (ofs)) | ||
407 | #define NETX_I2C_CTRL NETX_I2C_REG(0x0) | ||
408 | #define NETX_I2C_DATA NETX_I2C_REG(0x4) | ||
409 | |||
410 | #endif /* __ASM_ARCH_NETX_REGS_H */ | ||
diff --git a/include/asm-arm/arch-netx/param.h b/include/asm-arm/arch-netx/param.h new file mode 100644 index 000000000000..7a80c26178a8 --- /dev/null +++ b/include/asm-arm/arch-netx/param.h | |||
@@ -0,0 +1,18 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-netx/param.h | ||
3 | * | ||
4 | * Copyright (C) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 | ||
8 | * as published by the Free Software Foundation. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
diff --git a/include/asm-arm/arch-netx/pfifo.h b/include/asm-arm/arch-netx/pfifo.h new file mode 100644 index 000000000000..4af2ee4a32c1 --- /dev/null +++ b/include/asm-arm/arch-netx/pfifo.h | |||
@@ -0,0 +1,54 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-netx/pfifo.h | ||
3 | * | ||
4 | * Copyright (c) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 | ||
8 | * as published by the Free Software Foundation. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
19 | |||
20 | |||
21 | #ifndef ASM_ARCH_PFIFO_H | ||
22 | #define ASM_ARCH_PFIFO_H | ||
23 | |||
24 | static inline int pfifo_push(int no, unsigned int pointer) | ||
25 | { | ||
26 | writel(pointer, NETX_PFIFO_BASE(no)); | ||
27 | return 0; | ||
28 | } | ||
29 | |||
30 | static inline unsigned int pfifo_pop(int no) | ||
31 | { | ||
32 | return readl(NETX_PFIFO_BASE(no)); | ||
33 | } | ||
34 | |||
35 | static inline int pfifo_fill_level(int no) | ||
36 | { | ||
37 | |||
38 | return readl(NETX_PFIFO_FILL_LEVEL(no)); | ||
39 | } | ||
40 | |||
41 | static inline int pfifo_full(int no) | ||
42 | { | ||
43 | return readl(NETX_PFIFO_FULL) & (1<<no) ? 1 : 0; | ||
44 | } | ||
45 | |||
46 | static inline int pfifo_empty(int no) | ||
47 | { | ||
48 | return readl(NETX_PFIFO_EMPTY) & (1<<no) ? 1 : 0; | ||
49 | } | ||
50 | |||
51 | int pfifo_request(unsigned int pfifo_mask); | ||
52 | void pfifo_free(unsigned int pfifo_mask); | ||
53 | |||
54 | #endif /* ASM_ARCH_PFIFO_H */ | ||
diff --git a/include/asm-arm/arch-netx/system.h b/include/asm-arm/arch-netx/system.h new file mode 100644 index 000000000000..52adf368d765 --- /dev/null +++ b/include/asm-arm/arch-netx/system.h | |||
@@ -0,0 +1,38 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-netx/system.h | ||
3 | * | ||
4 | * Copyright (C) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 | ||
8 | * as published by the Free Software Foundation. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
19 | #ifndef __ASM_ARCH_SYSTEM_H | ||
20 | #define __ASM_ARCH_SYSTEM_H | ||
21 | |||
22 | #include <asm/io.h> | ||
23 | #include <asm/hardware.h> | ||
24 | #include "netx-regs.h" | ||
25 | |||
26 | static inline void arch_idle(void) | ||
27 | { | ||
28 | cpu_do_idle(); | ||
29 | } | ||
30 | |||
31 | static inline void arch_reset(char mode) | ||
32 | { | ||
33 | writel(NETX_SYSTEM_RES_CR_FIRMW_RES_EN | NETX_SYSTEM_RES_CR_FIRMW_RES, | ||
34 | NETX_SYSTEM_RES_CR); | ||
35 | } | ||
36 | |||
37 | #endif | ||
38 | |||
diff --git a/include/asm-arm/arch-netx/timex.h b/include/asm-arm/arch-netx/timex.h new file mode 100644 index 000000000000..7fdb42da0b40 --- /dev/null +++ b/include/asm-arm/arch-netx/timex.h | |||
@@ -0,0 +1,20 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-netx/timex.h | ||
3 | * | ||
4 | * Copyright (C) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 | ||
8 | * as published by the Free Software Foundation. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
19 | |||
20 | #define CLOCK_TICK_RATE 100000000 | ||
diff --git a/include/asm-arm/arch-netx/uncompress.h b/include/asm-arm/arch-netx/uncompress.h new file mode 100644 index 000000000000..f89434547102 --- /dev/null +++ b/include/asm-arm/arch-netx/uncompress.h | |||
@@ -0,0 +1,76 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-netx/uncompress.h | ||
3 | * | ||
4 | * Copyright (C) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 | ||
8 | * as published by the Free Software Foundation. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
19 | |||
20 | /* | ||
21 | * The following code assumes the serial port has already been | ||
22 | * initialized by the bootloader. We search for the first enabled | ||
23 | * port in the most probable order. If you didn't setup a port in | ||
24 | * your bootloader then nothing will appear (which might be desired). | ||
25 | * | ||
26 | * This does not append a newline | ||
27 | */ | ||
28 | |||
29 | #define REG(x) (*(volatile unsigned long *)(x)) | ||
30 | |||
31 | #define UART1_BASE 0x100a00 | ||
32 | #define UART2_BASE 0x100a80 | ||
33 | |||
34 | #define UART_DR 0x0 | ||
35 | |||
36 | #define UART_CR 0x14 | ||
37 | #define CR_UART_EN (1<<0) | ||
38 | |||
39 | #define UART_FR 0x18 | ||
40 | #define FR_BUSY (1<<3) | ||
41 | #define FR_TXFF (1<<5) | ||
42 | |||
43 | static void putc(char c) | ||
44 | { | ||
45 | unsigned long base; | ||
46 | |||
47 | if (REG(UART1_BASE + UART_CR) & CR_UART_EN) | ||
48 | base = UART1_BASE; | ||
49 | else if (REG(UART2_BASE + UART_CR) & CR_UART_EN) | ||
50 | base = UART2_BASE; | ||
51 | else | ||
52 | return; | ||
53 | |||
54 | while (REG(base + UART_FR) & FR_TXFF); | ||
55 | REG(base + UART_DR) = c; | ||
56 | } | ||
57 | |||
58 | static inline void flush(void) | ||
59 | { | ||
60 | unsigned long base; | ||
61 | |||
62 | if (REG(UART1_BASE + UART_CR) & CR_UART_EN) | ||
63 | base = UART1_BASE; | ||
64 | else if (REG(UART2_BASE + UART_CR) & CR_UART_EN) | ||
65 | base = UART2_BASE; | ||
66 | else | ||
67 | return; | ||
68 | |||
69 | while (REG(base + UART_FR) & FR_BUSY); | ||
70 | } | ||
71 | |||
72 | /* | ||
73 | * nothing to do | ||
74 | */ | ||
75 | #define arch_decomp_setup() | ||
76 | #define arch_decomp_wdog() | ||
diff --git a/include/asm-arm/arch-netx/vmalloc.h b/include/asm-arm/arch-netx/vmalloc.h new file mode 100644 index 000000000000..da2da5a595da --- /dev/null +++ b/include/asm-arm/arch-netx/vmalloc.h | |||
@@ -0,0 +1,19 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-netx/vmalloc.h | ||
3 | * | ||
4 | * Copyright (C) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 | ||
8 | * as published by the Free Software Foundation. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
19 | #define VMALLOC_END (PAGE_OFFSET + 0x10000000) | ||
diff --git a/include/asm-arm/arch-netx/xc.h b/include/asm-arm/arch-netx/xc.h new file mode 100644 index 000000000000..659af19512a9 --- /dev/null +++ b/include/asm-arm/arch-netx/xc.h | |||
@@ -0,0 +1,42 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-netx/xc.h | ||
3 | * | ||
4 | * Copyright (C) 2005 Sascha Hauer <s.hauer@pengutronix.de>, Pengutronix | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 | ||
8 | * as published by the Free Software Foundation. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
19 | |||
20 | #ifndef __ASM_ARCH_XC_H | ||
21 | #define __ASM_ARCH_XC_H | ||
22 | |||
23 | struct xc { | ||
24 | int no; | ||
25 | unsigned int type; | ||
26 | unsigned int version; | ||
27 | void __iomem *xpec_base; | ||
28 | void __iomem *xmac_base; | ||
29 | void __iomem *sram_base; | ||
30 | int irq; | ||
31 | struct device *dev; | ||
32 | }; | ||
33 | |||
34 | int xc_reset(struct xc *x); | ||
35 | int xc_stop(struct xc* x); | ||
36 | int xc_start(struct xc *x); | ||
37 | int xc_running(struct xc *x); | ||
38 | int xc_request_firmware(struct xc* x); | ||
39 | struct xc* request_xc(int xcno, struct device *dev); | ||
40 | void free_xc(struct xc *x); | ||
41 | |||
42 | #endif /* __ASM_ARCH_XC_H */ | ||
diff --git a/include/asm-arm/arch-omap/board.h b/include/asm-arm/arch-omap/board.h index 6d6240a4681c..dfdbf06fd646 100644 --- a/include/asm-arm/arch-omap/board.h +++ b/include/asm-arm/arch-omap/board.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _OMAP_BOARD_H | 10 | #ifndef _OMAP_BOARD_H |
11 | #define _OMAP_BOARD_H | 11 | #define _OMAP_BOARD_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/types.h> | 13 | #include <linux/types.h> |
15 | 14 | ||
16 | /* Different peripheral ids */ | 15 | /* Different peripheral ids */ |
diff --git a/include/asm-arm/arch-omap/hardware.h b/include/asm-arm/arch-omap/hardware.h index 7909b729826c..c7d9e857795d 100644 --- a/include/asm-arm/arch-omap/hardware.h +++ b/include/asm-arm/arch-omap/hardware.h | |||
@@ -37,7 +37,6 @@ | |||
37 | #define __ASM_ARCH_OMAP_HARDWARE_H | 37 | #define __ASM_ARCH_OMAP_HARDWARE_H |
38 | 38 | ||
39 | #include <asm/sizes.h> | 39 | #include <asm/sizes.h> |
40 | #include <linux/config.h> | ||
41 | #ifndef __ASSEMBLER__ | 40 | #ifndef __ASSEMBLER__ |
42 | #include <asm/types.h> | 41 | #include <asm/types.h> |
43 | #include <asm/arch/cpu.h> | 42 | #include <asm/arch/cpu.h> |
diff --git a/include/asm-arm/arch-omap/system.h b/include/asm-arm/arch-omap/system.h index 67970d1a2020..ac2bfa433f06 100644 --- a/include/asm-arm/arch-omap/system.h +++ b/include/asm-arm/arch-omap/system.h | |||
@@ -4,7 +4,6 @@ | |||
4 | */ | 4 | */ |
5 | #ifndef __ASM_ARCH_SYSTEM_H | 5 | #ifndef __ASM_ARCH_SYSTEM_H |
6 | #define __ASM_ARCH_SYSTEM_H | 6 | #define __ASM_ARCH_SYSTEM_H |
7 | #include <linux/config.h> | ||
8 | #include <linux/clk.h> | 7 | #include <linux/clk.h> |
9 | 8 | ||
10 | #include <asm/mach-types.h> | 9 | #include <asm/mach-types.h> |
diff --git a/include/asm-arm/arch-omap/uncompress.h b/include/asm-arm/arch-omap/uncompress.h index ca2c8bec82e7..aca0adfef1b8 100644 --- a/include/asm-arm/arch-omap/uncompress.h +++ b/include/asm-arm/arch-omap/uncompress.h | |||
@@ -17,7 +17,6 @@ | |||
17 | * kind, whether express or implied. | 17 | * kind, whether express or implied. |
18 | */ | 18 | */ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <linux/types.h> | 20 | #include <linux/types.h> |
22 | #include <linux/serial_reg.h> | 21 | #include <linux/serial_reg.h> |
23 | #include <asm/arch/serial.h> | 22 | #include <asm/arch/serial.h> |
diff --git a/include/asm-arm/arch-pnx4008/clock.h b/include/asm-arm/arch-pnx4008/clock.h new file mode 100644 index 000000000000..91ae0030fdf2 --- /dev/null +++ b/include/asm-arm/arch-pnx4008/clock.h | |||
@@ -0,0 +1,61 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-pnx4008/clock.h | ||
3 | * | ||
4 | * Clock control driver for PNX4008 - header file | ||
5 | * | ||
6 | * Authors: Vitaly Wool, Dmitry Chigirev <source@mvista.com> | ||
7 | * | ||
8 | * 2005 (c) MontaVista Software, Inc. This file is licensed under | ||
9 | * the terms of the GNU General Public License version 2. This program | ||
10 | * is licensed "as is" without any warranty of any kind, whether express | ||
11 | * or implied. | ||
12 | */ | ||
13 | #ifndef __PNX4008_CLOCK_H__ | ||
14 | #define __PNX4008_CLOCK_H__ | ||
15 | |||
16 | struct module; | ||
17 | struct clk; | ||
18 | |||
19 | #define PWRMAN_VA_BASE IO_ADDRESS(PNX4008_PWRMAN_BASE) | ||
20 | #define HCLKDIVCTRL_REG (PWRMAN_VA_BASE + 0x40) | ||
21 | #define PWRCTRL_REG (PWRMAN_VA_BASE + 0x44) | ||
22 | #define PLLCTRL_REG (PWRMAN_VA_BASE + 0x48) | ||
23 | #define OSC13CTRL_REG (PWRMAN_VA_BASE + 0x4c) | ||
24 | #define SYSCLKCTRL_REG (PWRMAN_VA_BASE + 0x50) | ||
25 | #define HCLKPLLCTRL_REG (PWRMAN_VA_BASE + 0x58) | ||
26 | #define USBCTRL_REG (PWRMAN_VA_BASE + 0x64) | ||
27 | #define SDRAMCLKCTRL_REG (PWRMAN_VA_BASE + 0x68) | ||
28 | #define MSCTRL_REG (PWRMAN_VA_BASE + 0x80) | ||
29 | #define BTCLKCTRL (PWRMAN_VA_BASE + 0x84) | ||
30 | #define DUMCLKCTRL_REG (PWRMAN_VA_BASE + 0x90) | ||
31 | #define I2CCLKCTRL_REG (PWRMAN_VA_BASE + 0xac) | ||
32 | #define KEYCLKCTRL_REG (PWRMAN_VA_BASE + 0xb0) | ||
33 | #define TSCLKCTRL_REG (PWRMAN_VA_BASE + 0xb4) | ||
34 | #define PWMCLKCTRL_REG (PWRMAN_VA_BASE + 0xb8) | ||
35 | #define SPICTRL_REG (PWRMAN_VA_BASE + 0xc4) | ||
36 | #define FLASHCLKCTRL_REG (PWRMAN_VA_BASE + 0xc8) | ||
37 | #define UART3CLK_REG (PWRMAN_VA_BASE + 0xd0) | ||
38 | #define UARTCLKCTRL_REG (PWRMAN_VA_BASE + 0xe4) | ||
39 | #define DMACLKCTRL_REG (PWRMAN_VA_BASE + 0xe8) | ||
40 | #define AUTOCLK_CTRL (PWRMAN_VA_BASE + 0xec) | ||
41 | #define JPEGCLKCTRL_REG (PWRMAN_VA_BASE + 0xfc) | ||
42 | |||
43 | #define AUDIOCONFIG_VA_BASE IO_ADDRESS(PNX4008_AUDIOCONFIG_BASE) | ||
44 | #define DSPPLLCTRL_REG (AUDIOCONFIG_VA_BASE + 0x60) | ||
45 | #define DSPCLKCTRL_REG (AUDIOCONFIG_VA_BASE + 0x64) | ||
46 | #define AUDIOCLKCTRL_REG (AUDIOCONFIG_VA_BASE + 0x68) | ||
47 | #define AUDIOPLLCTRL_REG (AUDIOCONFIG_VA_BASE + 0x6C) | ||
48 | |||
49 | #define USB_OTG_CLKCTRL_REG IO_ADDRESS(PNX4008_USB_CONFIG_BASE + 0xff4) | ||
50 | |||
51 | #define VFP9CLKCTRL_REG IO_ADDRESS(PNX4008_DEBUG_BASE) | ||
52 | |||
53 | #define CLK_RATE_13MHZ 13000 | ||
54 | #define CLK_RATE_1MHZ 1000 | ||
55 | #define CLK_RATE_208MHZ 208000 | ||
56 | #define CLK_RATE_48MHZ 48000 | ||
57 | #define CLK_RATE_32KHZ 32 | ||
58 | |||
59 | #define PNX4008_UART_CLK CLK_RATE_13MHZ * 1000 /* in MHz */ | ||
60 | |||
61 | #endif | ||
diff --git a/include/asm-arm/arch-pnx4008/debug-macro.S b/include/asm-arm/arch-pnx4008/debug-macro.S new file mode 100644 index 000000000000..eb3839de389a --- /dev/null +++ b/include/asm-arm/arch-pnx4008/debug-macro.S | |||
@@ -0,0 +1,27 @@ | |||
1 | /* linux/include/asm-arm/arch-pnx4008/debug-macro.S | ||
2 | * | ||
3 | * Debugging macro include header | ||
4 | * | ||
5 | * Copyright (C) 1994-1999 Russell King | ||
6 | * Moved from linux/arch/arm/kernel/debug.S by Ben Dooks | ||
7 | * | ||
8 | * This program is free software; you can redistribute it and/or modify | ||
9 | * it under the terms of the GNU General Public License version 2 as | ||
10 | * published by the Free Software Foundation. | ||
11 | * | ||
12 | */ | ||
13 | |||
14 | .macro addruart,rx | ||
15 | mrc p15, 0, \rx, c1, c0 | ||
16 | tst \rx, #1 @ MMU enabled? | ||
17 | mov \rx, #0x00090000 | ||
18 | addeq \rx, \rx, #0x40000000 | ||
19 | addne \rx, \rx, #0xf4000000 | ||
20 | .endm | ||
21 | |||
22 | .macro senduart,rd,rx | ||
23 | strb \rd, [\rx, #0x0] | ||
24 | .endm | ||
25 | |||
26 | #define UART_SHIFT 2 | ||
27 | #include <asm/hardware/debug-8250.S> | ||
diff --git a/include/asm-arm/arch-pnx4008/dma.h b/include/asm-arm/arch-pnx4008/dma.h new file mode 100644 index 000000000000..3aee1204795b --- /dev/null +++ b/include/asm-arm/arch-pnx4008/dma.h | |||
@@ -0,0 +1,162 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-pnx4008/dma.h | ||
3 | * | ||
4 | * PNX4008 DMA header file | ||
5 | * | ||
6 | * Author: Vitaly Wool | ||
7 | * Copyright: MontaVista Software Inc. (c) 2005 | ||
8 | * | ||
9 | * This program is free software; you can redistribute it and/or modify | ||
10 | * it under the terms of the GNU General Public License version 2 as | ||
11 | * published by the Free Software Foundation. | ||
12 | */ | ||
13 | |||
14 | #ifndef __ASM_ARCH_DMA_H | ||
15 | #define __ASM_ARCH_DMA_H | ||
16 | |||
17 | #include "platform.h" | ||
18 | |||
19 | #define MAX_DMA_ADDRESS 0xffffffff | ||
20 | |||
21 | #define MAX_DMA_CHANNELS 8 | ||
22 | |||
23 | #define DMAC_BASE IO_ADDRESS(PNX4008_DMA_CONFIG_BASE) | ||
24 | #define DMAC_INT_STAT (DMAC_BASE + 0x0000) | ||
25 | #define DMAC_INT_TC_STAT (DMAC_BASE + 0x0004) | ||
26 | #define DMAC_INT_TC_CLEAR (DMAC_BASE + 0x0008) | ||
27 | #define DMAC_INT_ERR_STAT (DMAC_BASE + 0x000c) | ||
28 | #define DMAC_INT_ERR_CLEAR (DMAC_BASE + 0x0010) | ||
29 | #define DMAC_SOFT_SREQ (DMAC_BASE + 0x0024) | ||
30 | #define DMAC_CONFIG (DMAC_BASE + 0x0030) | ||
31 | #define DMAC_Cx_SRC_ADDR(c) (DMAC_BASE + 0x0100 + (c) * 0x20) | ||
32 | #define DMAC_Cx_DEST_ADDR(c) (DMAC_BASE + 0x0104 + (c) * 0x20) | ||
33 | #define DMAC_Cx_LLI(c) (DMAC_BASE + 0x0108 + (c) * 0x20) | ||
34 | #define DMAC_Cx_CONTROL(c) (DMAC_BASE + 0x010c + (c) * 0x20) | ||
35 | #define DMAC_Cx_CONFIG(c) (DMAC_BASE + 0x0110 + (c) * 0x20) | ||
36 | |||
37 | enum { | ||
38 | WIDTH_BYTE = 0, | ||
39 | WIDTH_HWORD, | ||
40 | WIDTH_WORD | ||
41 | }; | ||
42 | |||
43 | enum { | ||
44 | FC_MEM2MEM_DMA, | ||
45 | FC_MEM2PER_DMA, | ||
46 | FC_PER2MEM_DMA, | ||
47 | FC_PER2PER_DMA, | ||
48 | FC_PER2PER_DPER, | ||
49 | FC_MEM2PER_PER, | ||
50 | FC_PER2MEM_PER, | ||
51 | FC_PER2PER_SPER | ||
52 | }; | ||
53 | |||
54 | enum { | ||
55 | DMA_INT_UNKNOWN = 0, | ||
56 | DMA_ERR_INT = 1, | ||
57 | DMA_TC_INT = 2, | ||
58 | }; | ||
59 | |||
60 | enum { | ||
61 | DMA_BUFFER_ALLOCATED = 1, | ||
62 | DMA_HAS_LL = 2, | ||
63 | }; | ||
64 | |||
65 | enum { | ||
66 | PER_CAM_DMA_1 = 0, | ||
67 | PER_NDF_FLASH = 1, | ||
68 | PER_MBX_SLAVE_FIFO = 2, | ||
69 | PER_SPI2_REC_XMIT = 3, | ||
70 | PER_MS_SD_RX_XMIT = 4, | ||
71 | PER_HS_UART_1_XMIT = 5, | ||
72 | PER_HS_UART_1_RX = 6, | ||
73 | PER_HS_UART_2_XMIT = 7, | ||
74 | PER_HS_UART_2_RX = 8, | ||
75 | PER_HS_UART_7_XMIT = 9, | ||
76 | PER_HS_UART_7_RX = 10, | ||
77 | PER_SPI1_REC_XMIT = 11, | ||
78 | PER_MLC_NDF_SREC = 12, | ||
79 | PER_CAM_DMA_2 = 13, | ||
80 | PER_PRNG_INFIFO = 14, | ||
81 | PER_PRNG_OUTFIFO = 15, | ||
82 | }; | ||
83 | |||
84 | struct pnx4008_dma_ch_ctrl { | ||
85 | int tc_mask; | ||
86 | int cacheable; | ||
87 | int bufferable; | ||
88 | int priv_mode; | ||
89 | int di; | ||
90 | int si; | ||
91 | int dest_ahb1; | ||
92 | int src_ahb1; | ||
93 | int dwidth; | ||
94 | int swidth; | ||
95 | int dbsize; | ||
96 | int sbsize; | ||
97 | int tr_size; | ||
98 | }; | ||
99 | |||
100 | struct pnx4008_dma_ch_config { | ||
101 | int halt; | ||
102 | int active; | ||
103 | int lock; | ||
104 | int itc; | ||
105 | int ie; | ||
106 | int flow_cntrl; | ||
107 | int dest_per; | ||
108 | int src_per; | ||
109 | }; | ||
110 | |||
111 | struct pnx4008_dma_ll { | ||
112 | unsigned long src_addr; | ||
113 | unsigned long dest_addr; | ||
114 | u32 next_dma; | ||
115 | unsigned long ch_ctrl; | ||
116 | struct pnx4008_dma_ll *next; | ||
117 | int flags; | ||
118 | void *alloc_data; | ||
119 | int (*free) (void *); | ||
120 | }; | ||
121 | |||
122 | struct pnx4008_dma_config { | ||
123 | int is_ll; | ||
124 | unsigned long src_addr; | ||
125 | unsigned long dest_addr; | ||
126 | unsigned long ch_ctrl; | ||
127 | unsigned long ch_cfg; | ||
128 | struct pnx4008_dma_ll *ll; | ||
129 | u32 ll_dma; | ||
130 | int flags; | ||
131 | void *alloc_data; | ||
132 | int (*free) (void *); | ||
133 | }; | ||
134 | |||
135 | extern struct pnx4008_dma_ll *pnx4008_alloc_ll_entry(dma_addr_t *); | ||
136 | extern void pnx4008_free_ll_entry(struct pnx4008_dma_ll *, dma_addr_t); | ||
137 | extern void pnx4008_free_ll(u32 ll_dma, struct pnx4008_dma_ll *); | ||
138 | |||
139 | extern int pnx4008_request_channel(char *, int, | ||
140 | void (*)(int, int, void *, struct pt_regs *), | ||
141 | void *); | ||
142 | extern void pnx4008_free_channel(int); | ||
143 | extern int pnx4008_config_dma(int, int, int); | ||
144 | extern int pnx4008_dma_pack_control(const struct pnx4008_dma_ch_ctrl *, | ||
145 | unsigned long *); | ||
146 | extern int pnx4008_dma_parse_control(unsigned long, | ||
147 | struct pnx4008_dma_ch_ctrl *); | ||
148 | extern int pnx4008_dma_pack_config(const struct pnx4008_dma_ch_config *, | ||
149 | unsigned long *); | ||
150 | extern int pnx4008_dma_parse_config(unsigned long, | ||
151 | struct pnx4008_dma_ch_config *); | ||
152 | extern int pnx4008_config_channel(int, struct pnx4008_dma_config *); | ||
153 | extern int pnx4008_channel_get_config(int, struct pnx4008_dma_config *); | ||
154 | extern int pnx4008_dma_ch_enable(int); | ||
155 | extern int pnx4008_dma_ch_disable(int); | ||
156 | extern int pnx4008_dma_ch_enabled(int); | ||
157 | extern void pnx4008_dma_split_head_entry(struct pnx4008_dma_config *, | ||
158 | struct pnx4008_dma_ch_ctrl *); | ||
159 | extern void pnx4008_dma_split_ll_entry(struct pnx4008_dma_ll *, | ||
160 | struct pnx4008_dma_ch_ctrl *); | ||
161 | |||
162 | #endif /* _ASM_ARCH_DMA_H */ | ||
diff --git a/include/asm-arm/arch-pnx4008/entry-macro.S b/include/asm-arm/arch-pnx4008/entry-macro.S new file mode 100644 index 000000000000..c1c198e3680b --- /dev/null +++ b/include/asm-arm/arch-pnx4008/entry-macro.S | |||
@@ -0,0 +1,121 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-pnx4008/entry-macro.S | ||
3 | * | ||
4 | * Low-level IRQ helper macros for PNX4008-based platforms | ||
5 | * | ||
6 | * 2005-2006 (c) MontaVista Software, Inc. | ||
7 | * Author: Vitaly Wool <vwool@ru.mvista.com> | ||
8 | * This file is licensed under the terms of the GNU General Public | ||
9 | * License version 2. This program is licensed "as is" without any | ||
10 | * warranty of any kind, whether express or implied. | ||
11 | */ | ||
12 | |||
13 | #include "platform.h" | ||
14 | |||
15 | #define IO_BASE 0xF0000000 | ||
16 | #define IO_ADDRESS(x) (((((x) & 0xff000000) >> 4) | ((x) & 0xfffff)) | IO_BASE) | ||
17 | |||
18 | #define INTRC_MASK 0x00 | ||
19 | #define INTRC_RAW_STAT 0x04 | ||
20 | #define INTRC_STAT 0x08 | ||
21 | #define INTRC_POLAR 0x0C | ||
22 | #define INTRC_ACT_TYPE 0x10 | ||
23 | #define INTRC_TYPE 0x14 | ||
24 | |||
25 | #define SIC1_BASE_INT 32 | ||
26 | #define SIC2_BASE_INT 64 | ||
27 | |||
28 | .macro disable_fiq | ||
29 | .endm | ||
30 | |||
31 | .macro get_irqnr_and_base, irqnr, irqstat, base, tmp | ||
32 | /* decode the MIC interrupt numbers */ | ||
33 | ldr \base, =IO_ADDRESS(PNX4008_INTCTRLMIC_BASE) | ||
34 | ldr \irqstat, [\base, #INTRC_STAT] | ||
35 | |||
36 | cmp \irqstat,#1<<16 | ||
37 | movhs \irqnr,#16 | ||
38 | movlo \irqnr,#0 | ||
39 | movhs \irqstat,\irqstat,lsr#16 | ||
40 | cmp \irqstat,#1<<8 | ||
41 | addhs \irqnr,\irqnr,#8 | ||
42 | movhs \irqstat,\irqstat,lsr#8 | ||
43 | cmp \irqstat,#1<<4 | ||
44 | addhs \irqnr,\irqnr,#4 | ||
45 | movhs \irqstat,\irqstat,lsr#4 | ||
46 | cmp \irqstat,#1<<2 | ||
47 | addhs \irqnr,\irqnr,#2 | ||
48 | movhs \irqstat,\irqstat,lsr#2 | ||
49 | cmp \irqstat,#1<<1 | ||
50 | addhs \irqnr,\irqnr,#1 | ||
51 | |||
52 | /* was there an interrupt ? if not then drop out with EQ status */ | ||
53 | teq \irqstat,#0 | ||
54 | beq 1003f | ||
55 | |||
56 | /* and now check for extended IRQ reasons */ | ||
57 | cmp \irqnr,#1 | ||
58 | bls 1003f | ||
59 | cmp \irqnr,#30 | ||
60 | blo 1002f | ||
61 | |||
62 | /* IRQ 31,30 : High priority cascade IRQ handle */ | ||
63 | /* read the correct SIC */ | ||
64 | /* decoding status after compare : eq is 30 (SIC1) , ne is 31 (SIC2) */ | ||
65 | /* set the base IRQ number */ | ||
66 | ldreq \base, =IO_ADDRESS(PNX4008_INTCTRLSIC1_BASE) | ||
67 | moveq \irqnr,#SIC1_BASE_INT | ||
68 | ldrne \base, =IO_ADDRESS(PNX4008_INTCTRLSIC2_BASE) | ||
69 | movne \irqnr,#SIC2_BASE_INT | ||
70 | ldr \irqstat, [\base, #INTRC_STAT] | ||
71 | ldr \tmp, [\base, #INTRC_TYPE] | ||
72 | /* and with inverted mask : low priority interrupts */ | ||
73 | and \irqstat,\irqstat,\tmp | ||
74 | b 1004f | ||
75 | |||
76 | 1003: | ||
77 | /* IRQ 1,0 : Low priority cascade IRQ handle */ | ||
78 | /* read the correct SIC */ | ||
79 | /* decoding status after compare : eq is 1 (SIC2) , ne is 0 (SIC1)*/ | ||
80 | /* read the correct SIC */ | ||
81 | /* set the base IRQ number */ | ||
82 | ldrne \base, =IO_ADDRESS(PNX4008_INTCTRLSIC1_BASE) | ||
83 | movne \irqnr,#SIC1_BASE_INT | ||
84 | ldreq \base, =IO_ADDRESS(PNX4008_INTCTRLSIC2_BASE) | ||
85 | moveq \irqnr,#SIC2_BASE_INT | ||
86 | ldr \irqstat, [\base, #INTRC_STAT] | ||
87 | ldr \tmp, [\base, #INTRC_TYPE] | ||
88 | /* and with inverted mask : low priority interrupts */ | ||
89 | bic \irqstat,\irqstat,\tmp | ||
90 | |||
91 | 1004: | ||
92 | |||
93 | cmp \irqstat,#1<<16 | ||
94 | addhs \irqnr,\irqnr,#16 | ||
95 | movhs \irqstat,\irqstat,lsr#16 | ||
96 | cmp \irqstat,#1<<8 | ||
97 | addhs \irqnr,\irqnr,#8 | ||
98 | movhs \irqstat,\irqstat,lsr#8 | ||
99 | cmp \irqstat,#1<<4 | ||
100 | addhs \irqnr,\irqnr,#4 | ||
101 | movhs \irqstat,\irqstat,lsr#4 | ||
102 | cmp \irqstat,#1<<2 | ||
103 | addhs \irqnr,\irqnr,#2 | ||
104 | movhs \irqstat,\irqstat,lsr#2 | ||
105 | cmp \irqstat,#1<<1 | ||
106 | addhs \irqnr,\irqnr,#1 | ||
107 | |||
108 | |||
109 | /* is irqstat not zero */ | ||
110 | |||
111 | 1002: | ||
112 | /* we assert that irqstat is not equal to zero and return ne status if true*/ | ||
113 | teq \irqstat,#0 | ||
114 | 1003: | ||
115 | .endm | ||
116 | |||
117 | |||
118 | .macro irq_prio_table | ||
119 | .endm | ||
120 | |||
121 | |||
diff --git a/include/asm-arm/arch-pnx4008/gpio.h b/include/asm-arm/arch-pnx4008/gpio.h new file mode 100644 index 000000000000..1fa5a77c3010 --- /dev/null +++ b/include/asm-arm/arch-pnx4008/gpio.h | |||
@@ -0,0 +1,139 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-pnx4008/gpio.h | ||
3 | * | ||
4 | * PNX4008 GPIO driver - header file | ||
5 | * | ||
6 | * Author: Dmitry Chigirev <source@mvista.com> | ||
7 | * | ||
8 | * Based on reference code by Iwo Mergler and Z.Tabaaloute from Philips: | ||
9 | * Copyright (c) 2005 Koninklijke Philips Electronics N.V. | ||
10 | * | ||
11 | * 2005 (c) MontaVista Software, Inc. This file is licensed under | ||
12 | * the terms of the GNU General Public License version 2. This program | ||
13 | * is licensed "as is" without any warranty of any kind, whether express | ||
14 | * or implied. | ||
15 | */ | ||
16 | |||
17 | #ifndef _PNX4008_GPIO_H_ | ||
18 | #define _PNX4008_GPIO_H_ | ||
19 | |||
20 | |||
21 | /* Block numbers */ | ||
22 | #define GPIO_IN (0) | ||
23 | #define GPIO_OUT (0x100) | ||
24 | #define GPIO_BID (0x200) | ||
25 | #define GPIO_RAM (0x300) | ||
26 | #define GPIO_MUX (0x400) | ||
27 | |||
28 | #define GPIO_TYPE_MASK(K) ((K) & 0x700) | ||
29 | |||
30 | /* INPUT GPIOs */ | ||
31 | /* GPI */ | ||
32 | #define GPI_00 (GPIO_IN | 0) | ||
33 | #define GPI_01 (GPIO_IN | 1) | ||
34 | #define GPI_02 (GPIO_IN | 2) | ||
35 | #define GPI_03 (GPIO_IN | 3) | ||
36 | #define GPI_04 (GPIO_IN | 4) | ||
37 | #define GPI_05 (GPIO_IN | 5) | ||
38 | #define GPI_06 (GPIO_IN | 6) | ||
39 | #define GPI_07 (GPIO_IN | 7) | ||
40 | #define GPI_08 (GPIO_IN | 8) | ||
41 | #define GPI_09 (GPIO_IN | 9) | ||
42 | #define U1_RX (GPIO_IN | 15) | ||
43 | #define U2_HTCS (GPIO_IN | 16) | ||
44 | #define U2_RX (GPIO_IN | 17) | ||
45 | #define U3_RX (GPIO_IN | 18) | ||
46 | #define U4_RX (GPIO_IN | 19) | ||
47 | #define U5_RX (GPIO_IN | 20) | ||
48 | #define U6_IRRX (GPIO_IN | 21) | ||
49 | #define U7_HCTS (GPIO_IN | 22) | ||
50 | #define U7_RX (GPIO_IN | 23) | ||
51 | /* MISC IN */ | ||
52 | #define SPI1_DATIN (GPIO_IN | 25) | ||
53 | #define DISP_SYNC (GPIO_IN | 26) | ||
54 | #define SPI2_DATIN (GPIO_IN | 27) | ||
55 | #define GPI_11 (GPIO_IN | 28) | ||
56 | |||
57 | #define GPIO_IN_MASK 0x1eff83ff | ||
58 | |||
59 | /* OUTPUT GPIOs */ | ||
60 | /* GPO */ | ||
61 | #define GPO_00 (GPIO_OUT | 0) | ||
62 | #define GPO_01 (GPIO_OUT | 1) | ||
63 | #define GPO_02 (GPIO_OUT | 2) | ||
64 | #define GPO_03 (GPIO_OUT | 3) | ||
65 | #define GPO_04 (GPIO_OUT | 4) | ||
66 | #define GPO_05 (GPIO_OUT | 5) | ||
67 | #define GPO_06 (GPIO_OUT | 6) | ||
68 | #define GPO_07 (GPIO_OUT | 7) | ||
69 | #define GPO_08 (GPIO_OUT | 8) | ||
70 | #define GPO_09 (GPIO_OUT | 9) | ||
71 | #define GPO_10 (GPIO_OUT | 10) | ||
72 | #define GPO_11 (GPIO_OUT | 11) | ||
73 | #define GPO_12 (GPIO_OUT | 12) | ||
74 | #define GPO_13 (GPIO_OUT | 13) | ||
75 | #define GPO_14 (GPIO_OUT | 14) | ||
76 | #define GPO_15 (GPIO_OUT | 15) | ||
77 | #define GPO_16 (GPIO_OUT | 16) | ||
78 | #define GPO_17 (GPIO_OUT | 17) | ||
79 | #define GPO_18 (GPIO_OUT | 18) | ||
80 | #define GPO_19 (GPIO_OUT | 19) | ||
81 | #define GPO_20 (GPIO_OUT | 20) | ||
82 | #define GPO_21 (GPIO_OUT | 21) | ||
83 | #define GPO_22 (GPIO_OUT | 22) | ||
84 | #define GPO_23 (GPIO_OUT | 23) | ||
85 | |||
86 | #define GPIO_OUT_MASK 0xffffff | ||
87 | |||
88 | /* BIDIRECTIONAL GPIOs */ | ||
89 | /* RAM pins */ | ||
90 | #define RAM_D19 (GPIO_RAM | 0) | ||
91 | #define RAM_D20 (GPIO_RAM | 1) | ||
92 | #define RAM_D21 (GPIO_RAM | 2) | ||
93 | #define RAM_D22 (GPIO_RAM | 3) | ||
94 | #define RAM_D23 (GPIO_RAM | 4) | ||
95 | #define RAM_D24 (GPIO_RAM | 5) | ||
96 | #define RAM_D25 (GPIO_RAM | 6) | ||
97 | #define RAM_D26 (GPIO_RAM | 7) | ||
98 | #define RAM_D27 (GPIO_RAM | 8) | ||
99 | #define RAM_D28 (GPIO_RAM | 9) | ||
100 | #define RAM_D29 (GPIO_RAM | 10) | ||
101 | #define RAM_D30 (GPIO_RAM | 11) | ||
102 | #define RAM_D31 (GPIO_RAM | 12) | ||
103 | |||
104 | #define GPIO_RAM_MASK 0x1fff | ||
105 | |||
106 | /* I/O pins */ | ||
107 | #define GPIO_00 (GPIO_BID | 25) | ||
108 | #define GPIO_01 (GPIO_BID | 26) | ||
109 | #define GPIO_02 (GPIO_BID | 27) | ||
110 | #define GPIO_03 (GPIO_BID | 28) | ||
111 | #define GPIO_04 (GPIO_BID | 29) | ||
112 | #define GPIO_05 (GPIO_BID | 30) | ||
113 | |||
114 | #define GPIO_BID_MASK 0x7e000000 | ||
115 | |||
116 | /* Non-GPIO multiplexed PIOs. For multiplexing with GPIO, please use GPIO macros */ | ||
117 | #define GPIO_SDRAM_SEL (GPIO_MUX | 3) | ||
118 | |||
119 | #define GPIO_MUX_MASK 0x8 | ||
120 | |||
121 | /* Extraction/assembly macros */ | ||
122 | #define GPIO_BIT_MASK(K) ((K) & 0x1F) | ||
123 | #define GPIO_BIT(K) (1 << GPIO_BIT_MASK(K)) | ||
124 | #define GPIO_ISMUX(K) ((GPIO_TYPE_MASK(K) == GPIO_MUX) && (GPIO_BIT(K) & GPIO_MUX_MASK)) | ||
125 | #define GPIO_ISRAM(K) ((GPIO_TYPE_MASK(K) == GPIO_RAM) && (GPIO_BIT(K) & GPIO_RAM_MASK)) | ||
126 | #define GPIO_ISBID(K) ((GPIO_TYPE_MASK(K) == GPIO_BID) && (GPIO_BIT(K) & GPIO_BID_MASK)) | ||
127 | #define GPIO_ISOUT(K) ((GPIO_TYPE_MASK(K) == GPIO_OUT) && (GPIO_BIT(K) & GPIO_OUT_MASK)) | ||
128 | #define GPIO_ISIN(K) ((GPIO_TYPE_MASK(K) == GPIO_IN) && (GPIO_BIT(K) & GPIO_IN_MASK)) | ||
129 | |||
130 | extern int pnx4008_gpio_register_pin(unsigned short pin); | ||
131 | extern int pnx4008_gpio_unregister_pin(unsigned short pin); | ||
132 | extern unsigned long pnx4008_gpio_read_pin(unsigned short pin); | ||
133 | extern int pnx4008_gpio_write_pin(unsigned short pin, int output); | ||
134 | extern int pnx4008_gpio_set_pin_direction(unsigned short pin, int output); | ||
135 | extern int pnx4008_gpio_read_pin_direction(unsigned short pin); | ||
136 | extern int pnx4008_gpio_set_pin_mux(unsigned short pin, int output); | ||
137 | extern int pnx4008_gpio_read_pin_mux(unsigned short pin); | ||
138 | |||
139 | #endif /* _PNX4008_GPIO_H_ */ | ||
diff --git a/include/asm-arm/arch-pnx4008/hardware.h b/include/asm-arm/arch-pnx4008/hardware.h new file mode 100644 index 000000000000..a4410397a921 --- /dev/null +++ b/include/asm-arm/arch-pnx4008/hardware.h | |||
@@ -0,0 +1,32 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-pnx4008/hardware.h | ||
3 | * | ||
4 | * Copyright (c) 2005 MontaVista Software, Inc. <source@mvista.com> | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License as published by | ||
8 | * the Free Software Foundation; either version 2 of the License, or | ||
9 | * (at your option) any later version. | ||
10 | * | ||
11 | * This program is distributed in the hope that it will be useful, | ||
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
14 | * GNU General Public License for more details. | ||
15 | * | ||
16 | * You should have received a copy of the GNU General Public License | ||
17 | * along with this program; if not, write to the Free Software | ||
18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
19 | */ | ||
20 | #ifndef __ASM_ARCH_HARDWARE_H | ||
21 | #define __ASM_ARCH_HARDWARE_H | ||
22 | |||
23 | #include <asm/sizes.h> | ||
24 | #include <asm/arch/platform.h> | ||
25 | |||
26 | /* Start of virtual addresses for IO devices */ | ||
27 | #define IO_BASE 0xF0000000 | ||
28 | |||
29 | /* This macro relies on fact that for all HW i/o addresses bits 20-23 are 0 */ | ||
30 | #define IO_ADDRESS(x) (((((x) & 0xff000000) >> 4) | ((x) & 0xfffff)) | IO_BASE) | ||
31 | |||
32 | #endif | ||
diff --git a/include/asm-arm/arch-pnx4008/io.h b/include/asm-arm/arch-pnx4008/io.h new file mode 100644 index 000000000000..29ee43955c52 --- /dev/null +++ b/include/asm-arm/arch-pnx4008/io.h | |||
@@ -0,0 +1,21 @@ | |||
1 | |||
2 | /* | ||
3 | * include/asm-arm/arch-pnx4008/io.h | ||
4 | * | ||
5 | * Author: Dmitry Chigirev <chigirev@ru.mvista.com> | ||
6 | * | ||
7 | * 2005 (c) MontaVista Software, Inc. This file is licensed under | ||
8 | * the terms of the GNU General Public License version 2. This program | ||
9 | * is licensed "as is" without any warranty of any kind, whether express | ||
10 | * or implied. | ||
11 | */ | ||
12 | |||
13 | #ifndef __ASM_ARM_ARCH_IO_H | ||
14 | #define __ASM_ARM_ARCH_IO_H | ||
15 | |||
16 | #define IO_SPACE_LIMIT 0xffffffff | ||
17 | |||
18 | #define __io(a) ((void __iomem *)(a)) | ||
19 | #define __mem_pci(a) (a) | ||
20 | |||
21 | #endif | ||
diff --git a/include/asm-arm/arch-pnx4008/irq.h b/include/asm-arm/arch-pnx4008/irq.h new file mode 100644 index 000000000000..fabff5dc337f --- /dev/null +++ b/include/asm-arm/arch-pnx4008/irq.h | |||
@@ -0,0 +1,42 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-pnx4008/irq.h | ||
3 | * | ||
4 | * PNX4008 IRQ controller driver - header file | ||
5 | * this one is used in entry-arnv.S as well so it cannot contain C code | ||
6 | * | ||
7 | * Copyright (c) 2005 Philips Semiconductors | ||
8 | * Copyright (c) 2005 MontaVista Software, Inc. | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify it | ||
11 | * under the terms of the GNU General Public License as published by the | ||
12 | * Free Software Foundation; either version 2 of the License, or (at your | ||
13 | * option) any later version. | ||
14 | */ | ||
15 | #ifndef __PNX4008_IRQ_H__ | ||
16 | #define __PNX4008_IRQ_H__ | ||
17 | |||
18 | #define MIC_VA_BASE IO_ADDRESS(PNX4008_INTCTRLMIC_BASE) | ||
19 | #define SIC1_VA_BASE IO_ADDRESS(PNX4008_INTCTRLSIC1_BASE) | ||
20 | #define SIC2_VA_BASE IO_ADDRESS(PNX4008_INTCTRLSIC2_BASE) | ||
21 | |||
22 | /* Manual: Chapter 20, page 195 */ | ||
23 | |||
24 | #define INTC_BIT(irq) (1<< ((irq) & 0x1F)) | ||
25 | |||
26 | #define INTC_ER(irq) IO_ADDRESS((PNX4008_INTCTRLMIC_BASE + 0x0 + (((irq)&(0x3<<5))<<9))) | ||
27 | #define INTC_RSR(irq) IO_ADDRESS((PNX4008_INTCTRLMIC_BASE + 0x4 + (((irq)&(0x3<<5))<<9))) | ||
28 | #define INTC_SR(irq) IO_ADDRESS((PNX4008_INTCTRLMIC_BASE + 0x8 + (((irq)&(0x3<<5))<<9))) | ||
29 | #define INTC_APR(irq) IO_ADDRESS((PNX4008_INTCTRLMIC_BASE + 0xC + (((irq)&(0x3<<5))<<9))) | ||
30 | #define INTC_ATR(irq) IO_ADDRESS((PNX4008_INTCTRLMIC_BASE + 0x10 + (((irq)&(0x3<<5))<<9))) | ||
31 | #define INTC_ITR(irq) IO_ADDRESS((PNX4008_INTCTRLMIC_BASE + 0x14 + (((irq)&(0x3<<5))<<9))) | ||
32 | |||
33 | #define START_INT_REG_BIT(irq) (1<<((irq)&0x1F)) | ||
34 | |||
35 | #define START_INT_ER_REG(irq) IO_ADDRESS((PNX4008_PWRMAN_BASE + 0x20 + (((irq)&(0x1<<5))>>1))) | ||
36 | #define START_INT_RSR_REG(irq) IO_ADDRESS((PNX4008_PWRMAN_BASE + 0x24 + (((irq)&(0x1<<5))>>1))) | ||
37 | #define START_INT_SR_REG(irq) IO_ADDRESS((PNX4008_PWRMAN_BASE + 0x28 + (((irq)&(0x1<<5))>>1))) | ||
38 | #define START_INT_APR_REG(irq) IO_ADDRESS((PNX4008_PWRMAN_BASE + 0x2C + (((irq)&(0x1<<5))>>1))) | ||
39 | |||
40 | extern void __init pnx4008_init_irq(void); | ||
41 | |||
42 | #endif /* __PNX4008_IRQ_H__ */ | ||
diff --git a/include/asm-arm/arch-pnx4008/irqs.h b/include/asm-arm/arch-pnx4008/irqs.h new file mode 100644 index 000000000000..13ec7ed0f501 --- /dev/null +++ b/include/asm-arm/arch-pnx4008/irqs.h | |||
@@ -0,0 +1,215 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-pnx4008/irqs.h | ||
3 | * | ||
4 | * PNX4008 IRQ controller driver - header file | ||
5 | * | ||
6 | * Author: Dmitry Chigirev <source@mvista.com> | ||
7 | * | ||
8 | * 2005 (c) MontaVista Software, Inc. This file is licensed under | ||
9 | * the terms of the GNU General Public License version 2. This program | ||
10 | * is licensed "as is" without any warranty of any kind, whether express | ||
11 | * or implied. | ||
12 | */ | ||
13 | #ifndef __PNX4008_IRQS_h__ | ||
14 | #define __PNX4008_IRQS_h__ | ||
15 | |||
16 | #define NR_IRQS 96 | ||
17 | |||
18 | /*Manual: table 259, page 199*/ | ||
19 | |||
20 | /*SUB2 Interrupt Routing (SIC2)*/ | ||
21 | |||
22 | #define SIC2_BASE_INT 64 | ||
23 | |||
24 | #define CLK_SWITCH_ARM_INT 95 /*manual: Clkswitch ARM */ | ||
25 | #define CLK_SWITCH_DSP_INT 94 /*manual: ClkSwitch DSP */ | ||
26 | #define CLK_SWITCH_AUD_INT 93 /*manual: Clkswitch AUD */ | ||
27 | #define GPI_06_INT 92 | ||
28 | #define GPI_05_INT 91 | ||
29 | #define GPI_04_INT 90 | ||
30 | #define GPI_03_INT 89 | ||
31 | #define GPI_02_INT 88 | ||
32 | #define GPI_01_INT 87 | ||
33 | #define GPI_00_INT 86 | ||
34 | #define BT_CLKREQ_INT 85 | ||
35 | #define SPI1_DATIN_INT 84 | ||
36 | #define U5_RX_INT 83 | ||
37 | #define SDIO_INT_N 82 | ||
38 | #define CAM_HS_INT 81 | ||
39 | #define CAM_VS_INT 80 | ||
40 | #define GPI_07_INT 79 | ||
41 | #define DISP_SYNC_INT 78 | ||
42 | #define DSP_INT8 77 | ||
43 | #define U7_HCTS_INT 76 | ||
44 | #define GPI_10_INT 75 | ||
45 | #define GPI_09_INT 74 | ||
46 | #define GPI_08_INT 73 | ||
47 | #define DSP_INT7 72 | ||
48 | #define U2_HCTS_INT 71 | ||
49 | #define SPI2_DATIN_INT 70 | ||
50 | #define GPIO_05_INT 69 | ||
51 | #define GPIO_04_INT 68 | ||
52 | #define GPIO_03_INT 67 | ||
53 | #define GPIO_02_INT 66 | ||
54 | #define GPIO_01_INT 65 | ||
55 | #define GPIO_00_INT 64 | ||
56 | |||
57 | /*Manual: table 258, page 198*/ | ||
58 | |||
59 | /*SUB1 Interrupt Routing (SIC1)*/ | ||
60 | |||
61 | #define SIC1_BASE_INT 32 | ||
62 | |||
63 | #define USB_I2C_INT 63 | ||
64 | #define USB_DEV_HP_INT 62 | ||
65 | #define USB_DEV_LP_INT 61 | ||
66 | #define USB_DEV_DMA_INT 60 | ||
67 | #define USB_HOST_INT 59 | ||
68 | #define USB_OTG_ATX_INT_N 58 | ||
69 | #define USB_OTG_TIMER_INT 57 | ||
70 | #define SW_INT 56 | ||
71 | #define SPI1_INT 55 | ||
72 | #define KEY_IRQ 54 | ||
73 | #define DSP_M_INT 53 | ||
74 | #define RTC_INT 52 | ||
75 | #define I2C_1_INT 51 | ||
76 | #define I2C_2_INT 50 | ||
77 | #define PLL1_LOCK_INT 49 | ||
78 | #define PLL2_LOCK_INT 48 | ||
79 | #define PLL3_LOCK_INT 47 | ||
80 | #define PLL4_LOCK_INT 46 | ||
81 | #define PLL5_LOCK_INT 45 | ||
82 | #define SPI2_INT 44 | ||
83 | #define DSP_INT1 43 | ||
84 | #define DSP_INT2 42 | ||
85 | #define DSP_TDM_INT2 41 | ||
86 | #define TS_AUX_INT 40 | ||
87 | #define TS_IRQ 39 | ||
88 | #define TS_P_INT 38 | ||
89 | #define UOUT1_TO_PAD_INT 37 | ||
90 | #define GPI_11_INT 36 | ||
91 | #define DSP_INT4 35 | ||
92 | #define JTAG_COMM_RX_INT 34 | ||
93 | #define JTAG_COMM_TX_INT 33 | ||
94 | #define DSP_INT3 32 | ||
95 | |||
96 | /*Manual: table 257, page 197*/ | ||
97 | |||
98 | /*MAIN Interrupt Routing*/ | ||
99 | |||
100 | #define MAIN_BASE_INT 0 | ||
101 | |||
102 | #define SUB2_FIQ_N 31 /*active low */ | ||
103 | #define SUB1_FIQ_N 30 /*active low */ | ||
104 | #define JPEG_INT 29 | ||
105 | #define DMA_INT 28 | ||
106 | #define MSTIMER_INT 27 | ||
107 | #define IIR1_INT 26 | ||
108 | #define IIR2_INT 25 | ||
109 | #define IIR7_INT 24 | ||
110 | #define DSP_TDM_INT0 23 | ||
111 | #define DSP_TDM_INT1 22 | ||
112 | #define DSP_P_INT 21 | ||
113 | #define DSP_INT0 20 | ||
114 | #define DUM_INT 19 | ||
115 | #define UOUT0_TO_PAD_INT 18 | ||
116 | #define MP4_ENC_INT 17 | ||
117 | #define MP4_DEC_INT 16 | ||
118 | #define SD0_INT 15 | ||
119 | #define MBX_INT 14 | ||
120 | #define SD1_INT 13 | ||
121 | #define MS_INT_N 12 | ||
122 | #define FLASH_INT 11 /*NAND*/ | ||
123 | #define IIR6_INT 10 | ||
124 | #define IIR5_INT 9 | ||
125 | #define IIR4_INT 8 | ||
126 | #define IIR3_INT 7 | ||
127 | #define WATCH_INT 6 | ||
128 | #define HSTIMER_INT 5 | ||
129 | #define ARCH_TIMER_IRQ HSTIMER_INT | ||
130 | #define CAM_INT 4 | ||
131 | #define PRNG_INT 3 | ||
132 | #define CRYPTO_INT 2 | ||
133 | #define SUB2_IRQ_N 1 /*active low */ | ||
134 | #define SUB1_IRQ_N 0 /*active low */ | ||
135 | |||
136 | #define PNX4008_IRQ_TYPES \ | ||
137 | { /*IRQ #'s: */ \ | ||
138 | IRQT_LOW, IRQT_LOW, IRQT_LOW, IRQT_HIGH, /* 0, 1, 2, 3 */ \ | ||
139 | IRQT_LOW, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 4, 5, 6, 7 */ \ | ||
140 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 8, 9,10,11 */ \ | ||
141 | IRQT_LOW, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 12,13,14,15 */ \ | ||
142 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 16,17,18,19 */ \ | ||
143 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 20,21,22,23 */ \ | ||
144 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 24,25,26,27 */ \ | ||
145 | IRQT_HIGH, IRQT_HIGH, IRQT_LOW, IRQT_LOW, /* 28,29,30,31 */ \ | ||
146 | IRQT_HIGH, IRQT_LOW, IRQT_HIGH, IRQT_HIGH, /* 32,33,34,35 */ \ | ||
147 | IRQT_HIGH, IRQT_HIGH, IRQT_FALLING, IRQT_HIGH, /* 36,37,38,39 */ \ | ||
148 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 40,41,42,43 */ \ | ||
149 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 44,45,46,47 */ \ | ||
150 | IRQT_HIGH, IRQT_HIGH, IRQT_LOW, IRQT_LOW, /* 48,49,50,51 */ \ | ||
151 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 52,53,54,55 */ \ | ||
152 | IRQT_HIGH, IRQT_HIGH, IRQT_LOW, IRQT_HIGH, /* 56,57,58,59 */ \ | ||
153 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 60,61,62,63 */ \ | ||
154 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 64,65,66,67 */ \ | ||
155 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 68,69,70,71 */ \ | ||
156 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 72,73,74,75 */ \ | ||
157 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 76,77,78,79 */ \ | ||
158 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 80,81,82,83 */ \ | ||
159 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 84,85,86,87 */ \ | ||
160 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 88,89,90,91 */ \ | ||
161 | IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, IRQT_HIGH, /* 92,93,94,95 */ \ | ||
162 | } | ||
163 | |||
164 | /* Start Enable Pin Interrupts - table 58 page 66 */ | ||
165 | |||
166 | #define SE_PIN_BASE_INT 32 | ||
167 | |||
168 | #define SE_U7_RX_INT 63 | ||
169 | #define SE_U7_HCTS_INT 62 | ||
170 | #define SE_BT_CLKREQ_INT 61 | ||
171 | #define SE_U6_IRRX_INT 60 | ||
172 | /*59 unused*/ | ||
173 | #define SE_U5_RX_INT 58 | ||
174 | #define SE_GPI_11_INT 57 | ||
175 | #define SE_U3_RX_INT 56 | ||
176 | #define SE_U2_HCTS_INT 55 | ||
177 | #define SE_U2_RX_INT 54 | ||
178 | #define SE_U1_RX_INT 53 | ||
179 | #define SE_DISP_SYNC_INT 52 | ||
180 | /*51 unused*/ | ||
181 | #define SE_SDIO_INT_N 50 | ||
182 | #define SE_MSDIO_START_INT 49 | ||
183 | #define SE_GPI_06_INT 48 | ||
184 | #define SE_GPI_05_INT 47 | ||
185 | #define SE_GPI_04_INT 46 | ||
186 | #define SE_GPI_03_INT 45 | ||
187 | #define SE_GPI_02_INT 44 | ||
188 | #define SE_GPI_01_INT 43 | ||
189 | #define SE_GPI_00_INT 42 | ||
190 | #define SE_SYSCLKEN_PIN_INT 41 | ||
191 | #define SE_SPI1_DATAIN_INT 40 | ||
192 | #define SE_GPI_07_INT 39 | ||
193 | #define SE_SPI2_DATAIN_INT 38 | ||
194 | #define SE_GPI_10_INT 37 | ||
195 | #define SE_GPI_09_INT 36 | ||
196 | #define SE_GPI_08_INT 35 | ||
197 | /*34-32 unused*/ | ||
198 | |||
199 | /* Start Enable Internal Interrupts - table 57 page 65 */ | ||
200 | |||
201 | #define SE_INT_BASE_INT 0 | ||
202 | |||
203 | #define SE_TS_IRQ 31 | ||
204 | #define SE_TS_P_INT 30 | ||
205 | #define SE_TS_AUX_INT 29 | ||
206 | /*27-28 unused*/ | ||
207 | #define SE_USB_AHB_NEED_CLK_INT 26 | ||
208 | #define SE_MSTIMER_INT 25 | ||
209 | #define SE_RTC_INT 24 | ||
210 | #define SE_USB_NEED_CLK_INT 23 | ||
211 | #define SE_USB_INT 22 | ||
212 | #define SE_USB_I2C_INT 21 | ||
213 | #define SE_USB_OTG_TIMER_INT 20 | ||
214 | |||
215 | #endif /* __PNX4008_IRQS_h__ */ | ||
diff --git a/include/asm-arm/arch-pnx4008/memory.h b/include/asm-arm/arch-pnx4008/memory.h new file mode 100644 index 000000000000..0d8268a95261 --- /dev/null +++ b/include/asm-arm/arch-pnx4008/memory.h | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-pnx4008/memory.h | ||
3 | * | ||
4 | * Copyright (c) 2005 Philips Semiconductors | ||
5 | * Copyright (c) 2005 MontaVista Software, Inc. | ||
6 | * | ||
7 | * This program is free software; you can redistribute it and/or modify it | ||
8 | * under the terms of the GNU General Public License as published by the | ||
9 | * Free Software Foundation; either version 2 of the License, or (at your | ||
10 | * option) any later version. | ||
11 | */ | ||
12 | |||
13 | #ifndef __ASM_ARCH_MEMORY_H | ||
14 | #define __ASM_ARCH_MEMORY_H | ||
15 | |||
16 | /* | ||
17 | * Physical DRAM offset. | ||
18 | */ | ||
19 | #define PHYS_OFFSET (0x80000000) | ||
20 | |||
21 | #define __virt_to_bus(x) ((x) - PAGE_OFFSET + PHYS_OFFSET) | ||
22 | #define __bus_to_virt(x) ((x) + PAGE_OFFSET - PHYS_OFFSET) | ||
23 | |||
24 | #endif | ||
diff --git a/include/asm-arm/arch-pnx4008/param.h b/include/asm-arm/arch-pnx4008/param.h new file mode 100644 index 000000000000..95d5f547b416 --- /dev/null +++ b/include/asm-arm/arch-pnx4008/param.h | |||
@@ -0,0 +1,21 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-pnx4008/param.h | ||
3 | * | ||
4 | * Copyright (C) 1999 ARM Limited | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License as published by | ||
8 | * the Free Software Foundation; either version 2 of the License, or | ||
9 | * (at your option) any later version. | ||
10 | * | ||
11 | * This program is distributed in the hope that it will be useful, | ||
12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
14 | * GNU General Public License for more details. | ||
15 | * | ||
16 | * You should have received a copy of the GNU General Public License | ||
17 | * along with this program; if not, write to the Free Software | ||
18 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
19 | */ | ||
20 | |||
21 | #define HZ 100 | ||
diff --git a/include/asm-arm/arch-pnx4008/platform.h b/include/asm-arm/arch-pnx4008/platform.h new file mode 100644 index 000000000000..485a3651b4d7 --- /dev/null +++ b/include/asm-arm/arch-pnx4008/platform.h | |||
@@ -0,0 +1,69 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-pnx4008/platfrom.h | ||
3 | * | ||
4 | * PNX4008 Base addresses - header file | ||
5 | * | ||
6 | * Author: Dmitry Chigirev <source@mvista.com> | ||
7 | * | ||
8 | * Based on reference code received from Philips: | ||
9 | * Copyright (C) 2003 Philips Semiconductors | ||
10 | * | ||
11 | * 2005 (c) MontaVista Software, Inc. This file is licensed under | ||
12 | * the terms of the GNU General Public License version 2. This program | ||
13 | * is licensed "as is" without any warranty of any kind, whether express | ||
14 | * or implied. | ||
15 | */ | ||
16 | |||
17 | |||
18 | #ifndef __ASM_ARCH_PLATFORM_H__ | ||
19 | #define __ASM_ARCH_PLATFORM_H__ | ||
20 | |||
21 | #define PNX4008_IRAM_BASE 0x08000000 | ||
22 | #define PNX4008_IRAM_SIZE 0x00010000 | ||
23 | #define PNX4008_YUV_SLAVE_BASE 0x10000000 | ||
24 | #define PNX4008_DUM_SLAVE_BASE 0x18000000 | ||
25 | #define PNX4008_NDF_FLASH_BASE 0x20020000 | ||
26 | #define PNX4008_SPI1_BASE 0x20088000 | ||
27 | #define PNX4008_SPI2_BASE 0x20090000 | ||
28 | #define PNX4008_SD_CONFIG_BASE 0x20098000 | ||
29 | #define PNX4008_FLASH_DATA 0x200B0000 | ||
30 | #define PNX4008_MLC_FLASH_BASE 0x200B8000 | ||
31 | #define PNX4008_JPEG_CONFIG_BASE 0x300A0000 | ||
32 | #define PNX4008_DMA_CONFIG_BASE 0x31000000 | ||
33 | #define PNX4008_USB_CONFIG_BASE 0x31020000 | ||
34 | #define PNX4008_SDRAM_CFG_BASE 0x31080000 | ||
35 | #define PNX4008_AHB2FAB_BASE 0x40000000 | ||
36 | #define PNX4008_PWRMAN_BASE 0x40004000 | ||
37 | #define PNX4008_INTCTRLMIC_BASE 0x40008000 | ||
38 | #define PNX4008_INTCTRLSIC1_BASE 0x4000C000 | ||
39 | #define PNX4008_INTCTRLSIC2_BASE 0x40010000 | ||
40 | #define PNX4008_HSUART1_BASE 0x40014000 | ||
41 | #define PNX4008_HSUART2_BASE 0x40018000 | ||
42 | #define PNX4008_HSUART7_BASE 0x4001C000 | ||
43 | #define PNX4008_RTC_BASE 0x40024000 | ||
44 | #define PNX4008_PIO_BASE 0x40028000 | ||
45 | #define PNX4008_MSTIMER_BASE 0x40034000 | ||
46 | #define PNX4008_HSTIMER_BASE 0x40038000 | ||
47 | #define PNX4008_WDOG_BASE 0x4003C000 | ||
48 | #define PNX4008_DEBUG_BASE 0x40040000 | ||
49 | #define PNX4008_TOUCH1_BASE 0x40048000 | ||
50 | #define PNX4008_KEYSCAN_BASE 0x40050000 | ||
51 | #define PNX4008_UARTCTRL_BASE 0x40054000 | ||
52 | #define PNX4008_PWM_BASE 0x4005C000 | ||
53 | #define PNX4008_UART3_BASE 0x40080000 | ||
54 | #define PNX4008_UART4_BASE 0x40088000 | ||
55 | #define PNX4008_UART5_BASE 0x40090000 | ||
56 | #define PNX4008_UART6_BASE 0x40098000 | ||
57 | #define PNX4008_I2C1_BASE 0x400A0000 | ||
58 | #define PNX4008_I2C2_BASE 0x400A8000 | ||
59 | #define PNX4008_MAGICGATE_BASE 0x400B0000 | ||
60 | #define PNX4008_DUMCONF_BASE 0x400B8000 | ||
61 | #define PNX4008_DUM_MAINCFG_BASE 0x400BC000 | ||
62 | #define PNX4008_DSP_BASE 0x400C0000 | ||
63 | #define PNX4008_PROFCOUNTER_BASE 0x400C8000 | ||
64 | #define PNX4008_CRYPTO_BASE 0x400D0000 | ||
65 | #define PNX4008_CAMIFCONF_BASE 0x400D8000 | ||
66 | #define PNX4008_YUV2RGB_BASE 0x400E0000 | ||
67 | #define PNX4008_AUDIOCONFIG_BASE 0x400E8000 | ||
68 | |||
69 | #endif | ||
diff --git a/include/asm-arm/arch-pnx4008/pm.h b/include/asm-arm/arch-pnx4008/pm.h new file mode 100644 index 000000000000..c660486670fb --- /dev/null +++ b/include/asm-arm/arch-pnx4008/pm.h | |||
@@ -0,0 +1,62 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-pnx4008/pm.h | ||
3 | * | ||
4 | * PNX4008 Power Management Routiness - header file | ||
5 | * | ||
6 | * Authors: Vitaly Wool, Dmitry Chigirev <source@mvista.com> | ||
7 | * | ||
8 | * 2005 (c) MontaVista Software, Inc. This file is licensed under | ||
9 | * the terms of the GNU General Public License version 2. This program | ||
10 | * is licensed "as is" without any warranty of any kind, whether express | ||
11 | * or implied. | ||
12 | */ | ||
13 | |||
14 | #ifndef __ASM_ARCH_PNX4008_PM_H | ||
15 | #define __ASM_ARCH_PNX4008_PM_H | ||
16 | |||
17 | #ifndef __ASSEMBLER__ | ||
18 | #include "irq.h" | ||
19 | #include "irqs.h" | ||
20 | #include "clock.h" | ||
21 | |||
22 | extern void pnx4008_pm_idle(void); | ||
23 | extern void pnx4008_pm_suspend(void); | ||
24 | extern unsigned int pnx4008_cpu_suspend_sz; | ||
25 | extern void pnx4008_cpu_suspend(void); | ||
26 | extern unsigned int pnx4008_cpu_standby_sz; | ||
27 | extern void pnx4008_cpu_standby(void); | ||
28 | |||
29 | extern int pnx4008_startup_pll(struct clk *); | ||
30 | extern int pnx4008_shutdown_pll(struct clk *); | ||
31 | |||
32 | static inline void start_int_umask(u8 irq) | ||
33 | { | ||
34 | __raw_writel(__raw_readl(START_INT_ER_REG(irq)) | | ||
35 | START_INT_REG_BIT(irq), START_INT_ER_REG(irq)); | ||
36 | } | ||
37 | |||
38 | static inline void start_int_mask(u8 irq) | ||
39 | { | ||
40 | __raw_writel(__raw_readl(START_INT_ER_REG(irq)) & | ||
41 | ~START_INT_REG_BIT(irq), START_INT_ER_REG(irq)); | ||
42 | } | ||
43 | |||
44 | static inline void start_int_ack(u8 irq) | ||
45 | { | ||
46 | __raw_writel(START_INT_REG_BIT(irq), START_INT_RSR_REG(irq)); | ||
47 | } | ||
48 | |||
49 | static inline void start_int_set_falling_edge(u8 irq) | ||
50 | { | ||
51 | __raw_writel(__raw_readl(START_INT_APR_REG(irq)) & | ||
52 | ~START_INT_REG_BIT(irq), START_INT_APR_REG(irq)); | ||
53 | } | ||
54 | |||
55 | static inline void start_int_set_rising_edge(u8 irq) | ||
56 | { | ||
57 | __raw_writel(__raw_readl(START_INT_APR_REG(irq)) | | ||
58 | START_INT_REG_BIT(irq), START_INT_APR_REG(irq)); | ||
59 | } | ||
60 | |||
61 | #endif /* ASSEMBLER */ | ||
62 | #endif /* __ASM_ARCH_PNX4008_PM_H */ | ||
diff --git a/include/asm-arm/arch-pnx4008/system.h b/include/asm-arm/arch-pnx4008/system.h new file mode 100644 index 000000000000..6e3da70ab107 --- /dev/null +++ b/include/asm-arm/arch-pnx4008/system.h | |||
@@ -0,0 +1,38 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-pnx4008/system.h | ||
3 | * | ||
4 | * Copyright (C) 2003 Philips Semiconductors | ||
5 | * Copyright (C) 2005 MontaVista Software, Inc. | ||
6 | * | ||
7 | * This program is free software; you can redistribute it and/or modify | ||
8 | * it under the terms of the GNU General Public License as published by | ||
9 | * the Free Software Foundation; either version 2 of the License, or | ||
10 | * (at your option) any later version. | ||
11 | * | ||
12 | * This program is distributed in the hope that it will be useful, | ||
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
15 | * GNU General Public License for more details. | ||
16 | * | ||
17 | * You should have received a copy of the GNU General Public License | ||
18 | * along with this program; if not, write to the Free Software | ||
19 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
20 | */ | ||
21 | #ifndef __ASM_ARCH_SYSTEM_H | ||
22 | #define __ASM_ARCH_SYSTEM_H | ||
23 | |||
24 | #include <asm/hardware.h> | ||
25 | #include <asm/io.h> | ||
26 | #include <asm/arch/platform.h> | ||
27 | |||
28 | static void arch_idle(void) | ||
29 | { | ||
30 | cpu_do_idle(); | ||
31 | } | ||
32 | |||
33 | static inline void arch_reset(char mode) | ||
34 | { | ||
35 | cpu_reset(0); | ||
36 | } | ||
37 | |||
38 | #endif | ||
diff --git a/include/asm-arm/arch-pnx4008/timex.h b/include/asm-arm/arch-pnx4008/timex.h new file mode 100644 index 000000000000..ee470a39089a --- /dev/null +++ b/include/asm-arm/arch-pnx4008/timex.h | |||
@@ -0,0 +1,73 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-pnx4008/timex.h | ||
3 | * | ||
4 | * PNX4008 timers header file | ||
5 | * | ||
6 | * Author: Dmitry Chigirev <source@mvista.com> | ||
7 | * | ||
8 | * 2005 (c) MontaVista Software, Inc. This file is licensed under | ||
9 | * the terms of the GNU General Public License version 2. This program | ||
10 | * is licensed "as is" without any warranty of any kind, whether express | ||
11 | * or implied. | ||
12 | */ | ||
13 | |||
14 | #ifndef __PNX4008_TIMEX_H | ||
15 | #define __PNX4008_TIMEX_H | ||
16 | |||
17 | #include <asm/hardware.h> | ||
18 | #include <asm/io.h> | ||
19 | |||
20 | #define CLOCK_TICK_RATE 1000000 | ||
21 | |||
22 | #define TICKS2USECS(x) (x) | ||
23 | |||
24 | /* MilliSecond Timer - Chapter 21 Page 202 */ | ||
25 | |||
26 | #define MSTIM_INT IO_ADDRESS((PNX4008_MSTIMER_BASE + 0x0)) | ||
27 | #define MSTIM_CTRL IO_ADDRESS((PNX4008_MSTIMER_BASE + 0x4)) | ||
28 | #define MSTIM_COUNTER IO_ADDRESS((PNX4008_MSTIMER_BASE + 0x8)) | ||
29 | #define MSTIM_MCTRL IO_ADDRESS((PNX4008_MSTIMER_BASE + 0x14)) | ||
30 | #define MSTIM_MATCH0 IO_ADDRESS((PNX4008_MSTIMER_BASE + 0x18)) | ||
31 | #define MSTIM_MATCH1 IO_ADDRESS((PNX4008_MSTIMER_BASE + 0x1c)) | ||
32 | |||
33 | /* High Speed Timer - Chpater 22, Page 205 */ | ||
34 | |||
35 | #define HSTIM_INT IO_ADDRESS((PNX4008_HSTIMER_BASE + 0x0)) | ||
36 | #define HSTIM_CTRL IO_ADDRESS((PNX4008_HSTIMER_BASE + 0x4)) | ||
37 | #define HSTIM_COUNTER IO_ADDRESS((PNX4008_HSTIMER_BASE + 0x8)) | ||
38 | #define HSTIM_PMATCH IO_ADDRESS((PNX4008_HSTIMER_BASE + 0xC)) | ||
39 | #define HSTIM_PCOUNT IO_ADDRESS((PNX4008_HSTIMER_BASE + 0x10)) | ||
40 | #define HSTIM_MCTRL IO_ADDRESS((PNX4008_HSTIMER_BASE + 0x14)) | ||
41 | #define HSTIM_MATCH0 IO_ADDRESS((PNX4008_HSTIMER_BASE + 0x18)) | ||
42 | #define HSTIM_MATCH1 IO_ADDRESS((PNX4008_HSTIMER_BASE + 0x1c)) | ||
43 | #define HSTIM_MATCH2 IO_ADDRESS((PNX4008_HSTIMER_BASE + 0x20)) | ||
44 | #define HSTIM_CCR IO_ADDRESS((PNX4008_HSTIMER_BASE + 0x28)) | ||
45 | #define HSTIM_CR0 IO_ADDRESS((PNX4008_HSTIMER_BASE + 0x2C)) | ||
46 | #define HSTIM_CR1 IO_ADDRESS((PNX4008_HSTIMER_BASE + 0x30)) | ||
47 | |||
48 | /* IMPORTANT: both timers are UPCOUNTING */ | ||
49 | |||
50 | /* xSTIM_MCTRL bit definitions */ | ||
51 | #define MR0_INT 1 | ||
52 | #define RESET_COUNT0 (1<<1) | ||
53 | #define STOP_COUNT0 (1<<2) | ||
54 | #define MR1_INT (1<<3) | ||
55 | #define RESET_COUNT1 (1<<4) | ||
56 | #define STOP_COUNT1 (1<<5) | ||
57 | #define MR2_INT (1<<6) | ||
58 | #define RESET_COUNT2 (1<<7) | ||
59 | #define STOP_COUNT2 (1<<8) | ||
60 | |||
61 | /* xSTIM_CTRL bit definitions */ | ||
62 | #define COUNT_ENAB 1 | ||
63 | #define RESET_COUNT (1<<1) | ||
64 | #define DEBUG_EN (1<<2) | ||
65 | |||
66 | /* xSTIM_INT bit definitions */ | ||
67 | #define MATCH0_INT 1 | ||
68 | #define MATCH1_INT (1<<1) | ||
69 | #define MATCH2_INT (1<<2) | ||
70 | #define RTC_TICK0 (1<<4) | ||
71 | #define RTC_TICK1 (1<<5) | ||
72 | |||
73 | #endif | ||
diff --git a/include/asm-arm/arch-pnx4008/uncompress.h b/include/asm-arm/arch-pnx4008/uncompress.h new file mode 100644 index 000000000000..8fa4d24b72b4 --- /dev/null +++ b/include/asm-arm/arch-pnx4008/uncompress.h | |||
@@ -0,0 +1,46 @@ | |||
1 | /* | ||
2 | * linux/include/asm-arm/arch-pnx4008/uncompress.h | ||
3 | * | ||
4 | * Copyright (C) 1999 ARM Limited | ||
5 | * Copyright (C) 2006 MontaVista Software, Inc. | ||
6 | * | ||
7 | * This program is free software; you can redistribute it and/or modify | ||
8 | * it under the terms of the GNU General Public License as published by | ||
9 | * the Free Software Foundation; either version 2 of the License, or | ||
10 | * (at your option) any later version. | ||
11 | * | ||
12 | * This program is distributed in the hope that it will be useful, | ||
13 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
14 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
15 | * GNU General Public License for more details. | ||
16 | * | ||
17 | * You should have received a copy of the GNU General Public License | ||
18 | * along with this program; if not, write to the Free Software | ||
19 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
20 | */ | ||
21 | |||
22 | #define UART5_BASE 0x40090000 | ||
23 | |||
24 | #define UART5_DR (*(volatile unsigned char *) (UART5_BASE)) | ||
25 | #define UART5_FR (*(volatile unsigned char *) (UART5_BASE + 18)) | ||
26 | |||
27 | static __inline__ void putc(char c) | ||
28 | { | ||
29 | while (UART5_FR & (1 << 5)) | ||
30 | barrier(); | ||
31 | |||
32 | UART5_DR = c; | ||
33 | } | ||
34 | |||
35 | /* | ||
36 | * This does not append a newline | ||
37 | */ | ||
38 | static inline void flush(void) | ||
39 | { | ||
40 | } | ||
41 | |||
42 | /* | ||
43 | * nothing to do | ||
44 | */ | ||
45 | #define arch_decomp_setup() | ||
46 | #define arch_decomp_wdog() | ||
diff --git a/include/asm-arm/arch-pnx4008/vmalloc.h b/include/asm-arm/arch-pnx4008/vmalloc.h new file mode 100644 index 000000000000..140d925f6f37 --- /dev/null +++ b/include/asm-arm/arch-pnx4008/vmalloc.h | |||
@@ -0,0 +1,20 @@ | |||
1 | /* | ||
2 | * include/asm-arm/arch-pnx4008/vmalloc.h | ||
3 | * | ||
4 | * Author: Vitaly Wool <source@mvista.com> | ||
5 | * | ||
6 | * 2006 (c) MontaVista Software, Inc. This file is licensed under | ||
7 | * the terms of the GNU General Public License version 2. This program | ||
8 | * is licensed "as is" without any warranty of any kind, whether express | ||
9 | * or implied. | ||
10 | */ | ||
11 | |||
12 | /* | ||
13 | * Just any arbitrary offset to the start of the vmalloc VM area: the | ||
14 | * current 8MB value just means that there will be a 8MB "hole" after the | ||
15 | * physical memory until the kernel virtual memory starts. That means that | ||
16 | * any out-of-bounds memory accesses will hopefully be caught. | ||
17 | * The vmalloc() routines leaves a hole of 4kB between each vmalloced | ||
18 | * area for the same reason. ;) | ||
19 | */ | ||
20 | #define VMALLOC_END (PAGE_OFFSET + 0x10000000) | ||
diff --git a/include/asm-arm/arch-pxa/idp.h b/include/asm-arm/arch-pxa/idp.h index e7ef497417bb..b6952534a4e1 100644 --- a/include/asm-arm/arch-pxa/idp.h +++ b/include/asm-arm/arch-pxa/idp.h | |||
@@ -15,7 +15,6 @@ | |||
15 | * Changes for 2.6 kernel. | 15 | * Changes for 2.6 kernel. |
16 | */ | 16 | */ |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | 18 | ||
20 | /* | 19 | /* |
21 | * Note: this file must be safe to include in assembly files | 20 | * Note: this file must be safe to include in assembly files |
diff --git a/include/asm-arm/arch-pxa/irqs.h b/include/asm-arm/arch-pxa/irqs.h index 67af238a8f8e..f3bc70eee35b 100644 --- a/include/asm-arm/arch-pxa/irqs.h +++ b/include/asm-arm/arch-pxa/irqs.h | |||
@@ -10,7 +10,6 @@ | |||
10 | * published by the Free Software Foundation. | 10 | * published by the Free Software Foundation. |
11 | */ | 11 | */ |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | #ifdef CONFIG_PXA27x | 14 | #ifdef CONFIG_PXA27x |
16 | #define PXA_IRQ_SKIP 0 | 15 | #define PXA_IRQ_SKIP 0 |
diff --git a/include/asm-arm/arch-pxa/poodle.h b/include/asm-arm/arch-pxa/poodle.h index 6b5ac5144e70..4d6a40315764 100644 --- a/include/asm-arm/arch-pxa/poodle.h +++ b/include/asm-arm/arch-pxa/poodle.h | |||
@@ -31,6 +31,7 @@ | |||
31 | #define POODLE_GPIO_CF_CD (14) | 31 | #define POODLE_GPIO_CF_CD (14) |
32 | #define POODLE_GPIO_CF_STSCHG (14) | 32 | #define POODLE_GPIO_CF_STSCHG (14) |
33 | #define POODLE_GPIO_SD_PWR (33) | 33 | #define POODLE_GPIO_SD_PWR (33) |
34 | #define POODLE_GPIO_SD_PWR1 (3) | ||
34 | #define POODLE_GPIO_nSD_CLK (6) | 35 | #define POODLE_GPIO_nSD_CLK (6) |
35 | #define POODLE_GPIO_nSD_WP (7) | 36 | #define POODLE_GPIO_nSD_WP (7) |
36 | #define POODLE_GPIO_nSD_INT (8) | 37 | #define POODLE_GPIO_nSD_INT (8) |
@@ -42,6 +43,7 @@ | |||
42 | #define POODLE_GPIO_BYPASS_ON (36) | 43 | #define POODLE_GPIO_BYPASS_ON (36) |
43 | #define POODLE_GPIO_CHRG_ON (38) | 44 | #define POODLE_GPIO_CHRG_ON (38) |
44 | #define POODLE_GPIO_CHRG_FULL (16) | 45 | #define POODLE_GPIO_CHRG_FULL (16) |
46 | #define POODLE_GPIO_DISCHARGE_ON (42) /* Enable battery discharge */ | ||
45 | 47 | ||
46 | /* PXA GPIOs */ | 48 | /* PXA GPIOs */ |
47 | #define POODLE_IRQ_GPIO_ON_KEY IRQ_GPIO(0) | 49 | #define POODLE_IRQ_GPIO_ON_KEY IRQ_GPIO(0) |
@@ -68,4 +70,6 @@ | |||
68 | #define POODLE_SCOOP_IO_DIR ( POODLE_SCOOP_VPEN | POODLE_SCOOP_HS_OUT ) | 70 | #define POODLE_SCOOP_IO_DIR ( POODLE_SCOOP_VPEN | POODLE_SCOOP_HS_OUT ) |
69 | #define POODLE_SCOOP_IO_OUT ( 0 ) | 71 | #define POODLE_SCOOP_IO_OUT ( 0 ) |
70 | 72 | ||
73 | extern struct platform_device poodle_locomo_device; | ||
74 | |||
71 | #endif /* __ASM_ARCH_POODLE_H */ | 75 | #endif /* __ASM_ARCH_POODLE_H */ |
diff --git a/include/asm-arm/arch-pxa/pxa-regs.h b/include/asm-arm/arch-pxa/pxa-regs.h index c8f53a71c076..9f83f4adfbf3 100644 --- a/include/asm-arm/arch-pxa/pxa-regs.h +++ b/include/asm-arm/arch-pxa/pxa-regs.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef __PXA_REGS_H | 13 | #ifndef __PXA_REGS_H |
14 | #define __PXA_REGS_H | 14 | #define __PXA_REGS_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | /* | 17 | /* |
19 | * PXA Chip selects | 18 | * PXA Chip selects |
@@ -1626,7 +1625,7 @@ | |||
1626 | #define SSCR0_RIM (1 << 22) /* Receive FIFO overrrun interrupt mask */ | 1625 | #define SSCR0_RIM (1 << 22) /* Receive FIFO overrrun interrupt mask */ |
1627 | #define SSCR0_TUM (1 << 23) /* Transmit FIFO underrun interrupt mask */ | 1626 | #define SSCR0_TUM (1 << 23) /* Transmit FIFO underrun interrupt mask */ |
1628 | #define SSCR0_FRDC (0x07000000) /* Frame rate divider control (mask) */ | 1627 | #define SSCR0_FRDC (0x07000000) /* Frame rate divider control (mask) */ |
1629 | #define SSCR0_SlotsPerFrm(c) ((x) - 1) /* Time slots per frame [1..8] */ | 1628 | #define SSCR0_SlotsPerFrm(x) ((x) - 1) /* Time slots per frame [1..8] */ |
1630 | #define SSCR0_ADC (1 << 30) /* Audio clock select */ | 1629 | #define SSCR0_ADC (1 << 30) /* Audio clock select */ |
1631 | #define SSCR0_MOD (1 << 31) /* Mode (normal or network) */ | 1630 | #define SSCR0_MOD (1 << 31) /* Mode (normal or network) */ |
1632 | #endif | 1631 | #endif |
@@ -1707,6 +1706,10 @@ | |||
1707 | #if defined (CONFIG_PXA27x) | 1706 | #if defined (CONFIG_PXA27x) |
1708 | #define SSTO_P1 __REG(0x41000028) /* SSP Port 1 Time Out Register */ | 1707 | #define SSTO_P1 __REG(0x41000028) /* SSP Port 1 Time Out Register */ |
1709 | #define SSPSP_P1 __REG(0x4100002C) /* SSP Port 1 Programmable Serial Protocol */ | 1708 | #define SSPSP_P1 __REG(0x4100002C) /* SSP Port 1 Programmable Serial Protocol */ |
1709 | #define SSTSA_P1 __REG(0x41000030) /* SSP Port 1 Tx Timeslot Active */ | ||
1710 | #define SSRSA_P1 __REG(0x41000034) /* SSP Port 1 Rx Timeslot Active */ | ||
1711 | #define SSTSS_P1 __REG(0x41000038) /* SSP Port 1 Timeslot Status */ | ||
1712 | #define SSACD_P1 __REG(0x4100003C) /* SSP Port 1 Audio Clock Divider */ | ||
1710 | #define SSCR0_P2 __REG(0x41700000) /* SSP Port 2 Control Register 0 */ | 1713 | #define SSCR0_P2 __REG(0x41700000) /* SSP Port 2 Control Register 0 */ |
1711 | #define SSCR1_P2 __REG(0x41700004) /* SSP Port 2 Control Register 1 */ | 1714 | #define SSCR1_P2 __REG(0x41700004) /* SSP Port 2 Control Register 1 */ |
1712 | #define SSSR_P2 __REG(0x41700008) /* SSP Port 2 Status Register */ | 1715 | #define SSSR_P2 __REG(0x41700008) /* SSP Port 2 Status Register */ |
@@ -1714,6 +1717,10 @@ | |||
1714 | #define SSDR_P2 __REG(0x41700010) /* (Write / Read) SSP Port 2 Data Write Register/SSP Data Read Register */ | 1717 | #define SSDR_P2 __REG(0x41700010) /* (Write / Read) SSP Port 2 Data Write Register/SSP Data Read Register */ |
1715 | #define SSTO_P2 __REG(0x41700028) /* SSP Port 2 Time Out Register */ | 1718 | #define SSTO_P2 __REG(0x41700028) /* SSP Port 2 Time Out Register */ |
1716 | #define SSPSP_P2 __REG(0x4170002C) /* SSP Port 2 Programmable Serial Protocol */ | 1719 | #define SSPSP_P2 __REG(0x4170002C) /* SSP Port 2 Programmable Serial Protocol */ |
1720 | #define SSTSA_P2 __REG(0x41700030) /* SSP Port 2 Tx Timeslot Active */ | ||
1721 | #define SSRSA_P2 __REG(0x41700034) /* SSP Port 2 Rx Timeslot Active */ | ||
1722 | #define SSTSS_P2 __REG(0x41700038) /* SSP Port 2 Timeslot Status */ | ||
1723 | #define SSACD_P2 __REG(0x4170003C) /* SSP Port 2 Audio Clock Divider */ | ||
1717 | #define SSCR0_P3 __REG(0x41900000) /* SSP Port 3 Control Register 0 */ | 1724 | #define SSCR0_P3 __REG(0x41900000) /* SSP Port 3 Control Register 0 */ |
1718 | #define SSCR1_P3 __REG(0x41900004) /* SSP Port 3 Control Register 1 */ | 1725 | #define SSCR1_P3 __REG(0x41900004) /* SSP Port 3 Control Register 1 */ |
1719 | #define SSSR_P3 __REG(0x41900008) /* SSP Port 3 Status Register */ | 1726 | #define SSSR_P3 __REG(0x41900008) /* SSP Port 3 Status Register */ |
@@ -1721,6 +1728,10 @@ | |||
1721 | #define SSDR_P3 __REG(0x41900010) /* (Write / Read) SSP Port 3 Data Write Register/SSP Data Read Register */ | 1728 | #define SSDR_P3 __REG(0x41900010) /* (Write / Read) SSP Port 3 Data Write Register/SSP Data Read Register */ |
1722 | #define SSTO_P3 __REG(0x41900028) /* SSP Port 3 Time Out Register */ | 1729 | #define SSTO_P3 __REG(0x41900028) /* SSP Port 3 Time Out Register */ |
1723 | #define SSPSP_P3 __REG(0x4190002C) /* SSP Port 3 Programmable Serial Protocol */ | 1730 | #define SSPSP_P3 __REG(0x4190002C) /* SSP Port 3 Programmable Serial Protocol */ |
1731 | #define SSTSA_P3 __REG(0x41900030) /* SSP Port 3 Tx Timeslot Active */ | ||
1732 | #define SSRSA_P3 __REG(0x41900034) /* SSP Port 3 Rx Timeslot Active */ | ||
1733 | #define SSTSS_P3 __REG(0x41900038) /* SSP Port 3 Timeslot Status */ | ||
1734 | #define SSACD_P3 __REG(0x4190003C) /* SSP Port 3 Audio Clock Divider */ | ||
1724 | #else /* PXA255 (only port 2) and PXA26x ports*/ | 1735 | #else /* PXA255 (only port 2) and PXA26x ports*/ |
1725 | #define SSTO_P1 __REG(0x41000028) /* SSP Port 1 Time Out Register */ | 1736 | #define SSTO_P1 __REG(0x41000028) /* SSP Port 1 Time Out Register */ |
1726 | #define SSPSP_P1 __REG(0x4100002C) /* SSP Port 1 Programmable Serial Protocol */ | 1737 | #define SSPSP_P1 __REG(0x4100002C) /* SSP Port 1 Programmable Serial Protocol */ |
@@ -1747,6 +1758,10 @@ | |||
1747 | #define SSDR_P(x) (*(((x) == 1) ? &SSDR_P1 : ((x) == 2) ? &SSDR_P2 : ((x) == 3) ? &SSDR_P3 : NULL)) | 1758 | #define SSDR_P(x) (*(((x) == 1) ? &SSDR_P1 : ((x) == 2) ? &SSDR_P2 : ((x) == 3) ? &SSDR_P3 : NULL)) |
1748 | #define SSTO_P(x) (*(((x) == 1) ? &SSTO_P1 : ((x) == 2) ? &SSTO_P2 : ((x) == 3) ? &SSTO_P3 : NULL)) | 1759 | #define SSTO_P(x) (*(((x) == 1) ? &SSTO_P1 : ((x) == 2) ? &SSTO_P2 : ((x) == 3) ? &SSTO_P3 : NULL)) |
1749 | #define SSPSP_P(x) (*(((x) == 1) ? &SSPSP_P1 : ((x) == 2) ? &SSPSP_P2 : ((x) == 3) ? &SSPSP_P3 : NULL)) | 1760 | #define SSPSP_P(x) (*(((x) == 1) ? &SSPSP_P1 : ((x) == 2) ? &SSPSP_P2 : ((x) == 3) ? &SSPSP_P3 : NULL)) |
1761 | #define SSTSA_P(x) (*(((x) == 1) ? &SSTSA_P1 : ((x) == 2) ? &SSTSA_P2 : ((x) == 3) ? &SSTSA_P3 : NULL)) | ||
1762 | #define SSRSA_P(x) (*(((x) == 1) ? &SSRSA_P1 : ((x) == 2) ? &SSRSA_P2 : ((x) == 3) ? &SSRSA_P3 : NULL)) | ||
1763 | #define SSTSS_P(x) (*(((x) == 1) ? &SSTSS_P1 : ((x) == 2) ? &SSTSS_P2 : ((x) == 3) ? &SSTSS_P3 : NULL)) | ||
1764 | #define SSACD_P(x) (*(((x) == 1) ? &SSACD_P1 : ((x) == 2) ? &SSACD_P2 : ((x) == 3) ? &SSACD_P3 : NULL)) | ||
1750 | 1765 | ||
1751 | /* | 1766 | /* |
1752 | * MultiMediaCard (MMC) controller | 1767 | * MultiMediaCard (MMC) controller |
diff --git a/include/asm-arm/arch-pxa/system.h b/include/asm-arm/arch-pxa/system.h index 840a46bfbc54..1d56a3ef89fd 100644 --- a/include/asm-arm/arch-pxa/system.h +++ b/include/asm-arm/arch-pxa/system.h | |||
@@ -10,6 +10,7 @@ | |||
10 | * published by the Free Software Foundation. | 10 | * published by the Free Software Foundation. |
11 | */ | 11 | */ |
12 | 12 | ||
13 | #include <asm/proc-fns.h> | ||
13 | #include "hardware.h" | 14 | #include "hardware.h" |
14 | #include "pxa-regs.h" | 15 | #include "pxa-regs.h" |
15 | 16 | ||
diff --git a/include/asm-arm/arch-pxa/timex.h b/include/asm-arm/arch-pxa/timex.h index aa125ec56a32..2473bb51d0a6 100644 --- a/include/asm-arm/arch-pxa/timex.h +++ b/include/asm-arm/arch-pxa/timex.h | |||
@@ -10,7 +10,6 @@ | |||
10 | * published by the Free Software Foundation. | 10 | * published by the Free Software Foundation. |
11 | */ | 11 | */ |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | #if defined(CONFIG_PXA25x) | 14 | #if defined(CONFIG_PXA25x) |
16 | /* PXA250/210 timer base */ | 15 | /* PXA250/210 timer base */ |
diff --git a/include/asm-arm/arch-realview/smp.h b/include/asm-arm/arch-realview/smp.h index fc87783e8e8b..515819efd046 100644 --- a/include/asm-arm/arch-realview/smp.h +++ b/include/asm-arm/arch-realview/smp.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef ASMARM_ARCH_SMP_H | 1 | #ifndef ASMARM_ARCH_SMP_H |
2 | #define ASMARM_ARCH_SMP_H | 2 | #define ASMARM_ARCH_SMP_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #include <asm/hardware/gic.h> | 5 | #include <asm/hardware/gic.h> |
7 | 6 | ||
diff --git a/include/asm-arm/arch-s3c2410/dma.h b/include/asm-arm/arch-s3c2410/dma.h index b011e14f3bc6..72964f9b8414 100644 --- a/include/asm-arm/arch-s3c2410/dma.h +++ b/include/asm-arm/arch-s3c2410/dma.h | |||
@@ -18,7 +18,6 @@ | |||
18 | #ifndef __ASM_ARCH_DMA_H | 18 | #ifndef __ASM_ARCH_DMA_H |
19 | #define __ASM_ARCH_DMA_H __FILE__ | 19 | #define __ASM_ARCH_DMA_H __FILE__ |
20 | 20 | ||
21 | #include <linux/config.h> | ||
22 | #include <linux/sysdev.h> | 21 | #include <linux/sysdev.h> |
23 | #include "hardware.h" | 22 | #include "hardware.h" |
24 | 23 | ||
diff --git a/include/asm-arm/arch-s3c2410/map.h b/include/asm-arm/arch-s3c2410/map.h index c380d264a847..5e4c8c37bc66 100644 --- a/include/asm-arm/arch-s3c2410/map.h +++ b/include/asm-arm/arch-s3c2410/map.h | |||
@@ -126,9 +126,18 @@ | |||
126 | #define S3C24XX_SZ_IIS SZ_1M | 126 | #define S3C24XX_SZ_IIS SZ_1M |
127 | 127 | ||
128 | /* GPIO ports */ | 128 | /* GPIO ports */ |
129 | #define S3C24XX_VA_GPIO S3C2410_ADDR(0x00E00000) | 129 | |
130 | /* the calculation for the VA of this must ensure that | ||
131 | * it is the same distance apart from the UART in the | ||
132 | * phsyical address space, as the initial mapping for the IO | ||
133 | * is done as a 1:1 maping. This puts it (currently) at | ||
134 | * 0xF6800000, which is not in the way of any current mapping | ||
135 | * by the base system. | ||
136 | */ | ||
137 | |||
130 | #define S3C2400_PA_GPIO (0x15600000) | 138 | #define S3C2400_PA_GPIO (0x15600000) |
131 | #define S3C2410_PA_GPIO (0x56000000) | 139 | #define S3C2410_PA_GPIO (0x56000000) |
140 | #define S3C24XX_VA_GPIO ((S3C2410_PA_GPIO - S3C24XX_PA_UART) + S3C24XX_VA_UART) | ||
132 | #define S3C24XX_SZ_GPIO SZ_1M | 141 | #define S3C24XX_SZ_GPIO SZ_1M |
133 | 142 | ||
134 | /* RTC */ | 143 | /* RTC */ |
diff --git a/include/asm-arm/arch-s3c2410/regs-clock.h b/include/asm-arm/arch-s3c2410/regs-clock.h index 34360706e016..6c92faffe985 100644 --- a/include/asm-arm/arch-s3c2410/regs-clock.h +++ b/include/asm-arm/arch-s3c2410/regs-clock.h | |||
@@ -114,7 +114,7 @@ s3c2410_get_pll(unsigned int pllval, unsigned int baseclk) | |||
114 | 114 | ||
115 | #endif /* __ASSEMBLY__ */ | 115 | #endif /* __ASSEMBLY__ */ |
116 | 116 | ||
117 | #ifdef CONFIG_CPU_S3C2440 | 117 | #if defined(CONFIG_CPU_S3C2440) || defined(CONFIG_CPU_S3C2442) |
118 | 118 | ||
119 | /* extra registers */ | 119 | /* extra registers */ |
120 | #define S3C2440_CAMDIVN S3C2410_CLKREG(0x18) | 120 | #define S3C2440_CAMDIVN S3C2410_CLKREG(0x18) |
@@ -136,7 +136,9 @@ s3c2410_get_pll(unsigned int pllval, unsigned int baseclk) | |||
136 | #define S3C2440_CAMDIVN_HCLK4_HALF (1<<9) | 136 | #define S3C2440_CAMDIVN_HCLK4_HALF (1<<9) |
137 | #define S3C2440_CAMDIVN_DVSEN (1<<12) | 137 | #define S3C2440_CAMDIVN_DVSEN (1<<12) |
138 | 138 | ||
139 | #endif /* CONFIG_CPU_S3C2440 */ | 139 | #define S3C2442_CAMDIVN_CAMCLK_DIV3 (1<<5) |
140 | |||
141 | #endif /* CONFIG_CPU_S3C2440 or CONFIG_CPU_S3C2442 */ | ||
140 | 142 | ||
141 | 143 | ||
142 | #endif /* __ASM_ARM_REGS_CLOCK */ | 144 | #endif /* __ASM_ARM_REGS_CLOCK */ |
diff --git a/include/asm-arm/arch-s3c2410/regs-gpio.h b/include/asm-arm/arch-s3c2410/regs-gpio.h index d2574084697f..5f10334f06bf 100644 --- a/include/asm-arm/arch-s3c2410/regs-gpio.h +++ b/include/asm-arm/arch-s3c2410/regs-gpio.h | |||
@@ -450,12 +450,14 @@ | |||
450 | #define S3C2410_GPD0_OUTP (0x01 << 0) | 450 | #define S3C2410_GPD0_OUTP (0x01 << 0) |
451 | #define S3C2410_GPD0_VD8 (0x02 << 0) | 451 | #define S3C2410_GPD0_VD8 (0x02 << 0) |
452 | #define S3C2400_GPD0_VFRAME (0x02 << 0) | 452 | #define S3C2400_GPD0_VFRAME (0x02 << 0) |
453 | #define S3C2442_GPD0_nSPICS1 (0x03 << 0) | ||
453 | 454 | ||
454 | #define S3C2410_GPD1 S3C2410_GPIONO(S3C2410_GPIO_BANKD, 1) | 455 | #define S3C2410_GPD1 S3C2410_GPIONO(S3C2410_GPIO_BANKD, 1) |
455 | #define S3C2410_GPD1_INP (0x00 << 2) | 456 | #define S3C2410_GPD1_INP (0x00 << 2) |
456 | #define S3C2410_GPD1_OUTP (0x01 << 2) | 457 | #define S3C2410_GPD1_OUTP (0x01 << 2) |
457 | #define S3C2410_GPD1_VD9 (0x02 << 2) | 458 | #define S3C2410_GPD1_VD9 (0x02 << 2) |
458 | #define S3C2400_GPD1_VM (0x02 << 2) | 459 | #define S3C2400_GPD1_VM (0x02 << 2) |
460 | #define S3C2442_GPD1_SPICLK1 (0x03 << 2) | ||
459 | 461 | ||
460 | #define S3C2410_GPD2 S3C2410_GPIONO(S3C2410_GPIO_BANKD, 2) | 462 | #define S3C2410_GPD2 S3C2410_GPIONO(S3C2410_GPIO_BANKD, 2) |
461 | #define S3C2410_GPD2_INP (0x00 << 4) | 463 | #define S3C2410_GPD2_INP (0x00 << 4) |
@@ -858,6 +860,7 @@ | |||
858 | #define S3C2410_GPG12_OUTP (0x01 << 24) | 860 | #define S3C2410_GPG12_OUTP (0x01 << 24) |
859 | #define S3C2410_GPG12_EINT20 (0x02 << 24) | 861 | #define S3C2410_GPG12_EINT20 (0x02 << 24) |
860 | #define S3C2410_GPG12_XMON (0x03 << 24) | 862 | #define S3C2410_GPG12_XMON (0x03 << 24) |
863 | #define S3C2442_GPG12_nSPICS0 (0x03 << 24) | ||
861 | 864 | ||
862 | #define S3C2410_GPG13 S3C2410_GPIONO(S3C2410_GPIO_BANKG, 13) | 865 | #define S3C2410_GPG13 S3C2410_GPIONO(S3C2410_GPIO_BANKG, 13) |
863 | #define S3C2410_GPG13_INP (0x00 << 26) | 866 | #define S3C2410_GPG13_INP (0x00 << 26) |
@@ -943,6 +946,7 @@ | |||
943 | #define S3C2410_GPH9_INP (0x00 << 18) | 946 | #define S3C2410_GPH9_INP (0x00 << 18) |
944 | #define S3C2410_GPH9_OUTP (0x01 << 18) | 947 | #define S3C2410_GPH9_OUTP (0x01 << 18) |
945 | #define S3C2410_GPH9_CLKOUT0 (0x02 << 18) | 948 | #define S3C2410_GPH9_CLKOUT0 (0x02 << 18) |
949 | #define S3C2442_GPH9_nSPICS0 (0x03 << 18) | ||
946 | 950 | ||
947 | #define S3C2410_GPH10 S3C2410_GPIONO(S3C2410_GPIO_BANKH, 10) | 951 | #define S3C2410_GPH10 S3C2410_GPIONO(S3C2410_GPIO_BANKH, 10) |
948 | #define S3C2410_GPH10_INP (0x00 << 20) | 952 | #define S3C2410_GPH10_INP (0x00 << 20) |
@@ -1051,6 +1055,7 @@ | |||
1051 | #define S3C2410_GSTATUS1_IDMASK (0xffff0000) | 1055 | #define S3C2410_GSTATUS1_IDMASK (0xffff0000) |
1052 | #define S3C2410_GSTATUS1_2410 (0x32410000) | 1056 | #define S3C2410_GSTATUS1_2410 (0x32410000) |
1053 | #define S3C2410_GSTATUS1_2440 (0x32440000) | 1057 | #define S3C2410_GSTATUS1_2440 (0x32440000) |
1058 | #define S3C2410_GSTATUS1_2442 (0x32440aaa) | ||
1054 | 1059 | ||
1055 | #define S3C2410_GSTATUS2_WTRESET (1<<2) | 1060 | #define S3C2410_GSTATUS2_WTRESET (1<<2) |
1056 | #define S3C2410_GSTATUS2_OFFRESET (1<<1) | 1061 | #define S3C2410_GSTATUS2_OFFRESET (1<<1) |
diff --git a/include/asm-arm/arch-s3c2410/uncompress.h b/include/asm-arm/arch-s3c2410/uncompress.h index a6f6a0e44afa..8e152a05e533 100644 --- a/include/asm-arm/arch-s3c2410/uncompress.h +++ b/include/asm-arm/arch-s3c2410/uncompress.h | |||
@@ -22,7 +22,6 @@ | |||
22 | #ifndef __ASM_ARCH_UNCOMPRESS_H | 22 | #ifndef __ASM_ARCH_UNCOMPRESS_H |
23 | #define __ASM_ARCH_UNCOMPRESS_H | 23 | #define __ASM_ARCH_UNCOMPRESS_H |
24 | 24 | ||
25 | #include <linux/config.h> | ||
26 | 25 | ||
27 | /* defines for UART registers */ | 26 | /* defines for UART registers */ |
28 | #include "asm/arch/regs-serial.h" | 27 | #include "asm/arch/regs-serial.h" |
@@ -82,7 +81,8 @@ static void putc(int ch) | |||
82 | while (1) { | 81 | while (1) { |
83 | level = uart_rd(S3C2410_UFSTAT); | 82 | level = uart_rd(S3C2410_UFSTAT); |
84 | 83 | ||
85 | if (cpuid == S3C2410_GSTATUS1_2440) { | 84 | if (cpuid == S3C2410_GSTATUS1_2440 || |
85 | cpuid == S3C2410_GSTATUS1_2442) { | ||
86 | level &= S3C2440_UFSTAT_TXMASK; | 86 | level &= S3C2440_UFSTAT_TXMASK; |
87 | level >>= S3C2440_UFSTAT_TXSHIFT; | 87 | level >>= S3C2440_UFSTAT_TXSHIFT; |
88 | } else { | 88 | } else { |
@@ -130,7 +130,7 @@ static void arch_decomp_wdog_start(void) | |||
130 | { | 130 | { |
131 | __raw_writel(WDOG_COUNT, S3C2410_WTDAT); | 131 | __raw_writel(WDOG_COUNT, S3C2410_WTDAT); |
132 | __raw_writel(WDOG_COUNT, S3C2410_WTCNT); | 132 | __raw_writel(WDOG_COUNT, S3C2410_WTCNT); |
133 | __raw_writel(S3C2410_WTCON_ENABLE | S3C2410_WTCON_DIV128 | S3C2410_WTCON_RSTEN | S3C2410_WTCON_PRESCALE(0x40), S3C2410_WTCON); | 133 | __raw_writel(S3C2410_WTCON_ENABLE | S3C2410_WTCON_DIV128 | S3C2410_WTCON_RSTEN | S3C2410_WTCON_PRESCALE(0x80), S3C2410_WTCON); |
134 | } | 134 | } |
135 | 135 | ||
136 | #else | 136 | #else |
diff --git a/include/asm-arm/arch-sa1100/assabet.h b/include/asm-arm/arch-sa1100/assabet.h index 1f59b368c3f6..d6a1bb5b4944 100644 --- a/include/asm-arm/arch-sa1100/assabet.h +++ b/include/asm-arm/arch-sa1100/assabet.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef __ASM_ARCH_ASSABET_H | 12 | #ifndef __ASM_ARCH_ASSABET_H |
13 | #define __ASM_ARCH_ASSABET_H | 13 | #define __ASM_ARCH_ASSABET_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | /* System Configuration Register flags */ | 16 | /* System Configuration Register flags */ |
18 | 17 | ||
diff --git a/include/asm-arm/arch-sa1100/cerf.h b/include/asm-arm/arch-sa1100/cerf.h index 356d5ba88991..9a19c3d07c1e 100644 --- a/include/asm-arm/arch-sa1100/cerf.h +++ b/include/asm-arm/arch-sa1100/cerf.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _INCLUDE_CERF_H_ | 10 | #ifndef _INCLUDE_CERF_H_ |
11 | #define _INCLUDE_CERF_H_ | 11 | #define _INCLUDE_CERF_H_ |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | #define CERF_ETH_IO 0xf0000000 | 14 | #define CERF_ETH_IO 0xf0000000 |
16 | #define CERF_ETH_IRQ IRQ_GPIO26 | 15 | #define CERF_ETH_IRQ IRQ_GPIO26 |
diff --git a/include/asm-arm/arch-sa1100/collie.h b/include/asm-arm/arch-sa1100/collie.h index d49e5ff63ca4..14a344aa3cc7 100644 --- a/include/asm-arm/arch-sa1100/collie.h +++ b/include/asm-arm/arch-sa1100/collie.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef __ASM_ARCH_COLLIE_H | 13 | #ifndef __ASM_ARCH_COLLIE_H |
14 | #define __ASM_ARCH_COLLIE_H | 14 | #define __ASM_ARCH_COLLIE_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | #define COLLIE_SCP_CHARGE_ON SCOOP_GPCR_PA11 | 17 | #define COLLIE_SCP_CHARGE_ON SCOOP_GPCR_PA11 |
19 | #define COLLIE_SCP_DIAG_BOOT1 SCOOP_GPCR_PA12 | 18 | #define COLLIE_SCP_DIAG_BOOT1 SCOOP_GPCR_PA12 |
diff --git a/include/asm-arm/arch-sa1100/dma.h b/include/asm-arm/arch-sa1100/dma.h index 02575d72ac6b..6b7917a2e77a 100644 --- a/include/asm-arm/arch-sa1100/dma.h +++ b/include/asm-arm/arch-sa1100/dma.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef __ASM_ARCH_DMA_H | 10 | #ifndef __ASM_ARCH_DMA_H |
11 | #define __ASM_ARCH_DMA_H | 11 | #define __ASM_ARCH_DMA_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include "hardware.h" | 13 | #include "hardware.h" |
15 | 14 | ||
16 | 15 | ||
diff --git a/include/asm-arm/arch-sa1100/hardware.h b/include/asm-arm/arch-sa1100/hardware.h index ee008a5484f3..1abd7cfc8bce 100644 --- a/include/asm-arm/arch-sa1100/hardware.h +++ b/include/asm-arm/arch-sa1100/hardware.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef __ASM_ARCH_HARDWARE_H | 12 | #ifndef __ASM_ARCH_HARDWARE_H |
13 | #define __ASM_ARCH_HARDWARE_H | 13 | #define __ASM_ARCH_HARDWARE_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | #define UNCACHEABLE_ADDR 0xfa050000 | 16 | #define UNCACHEABLE_ADDR 0xfa050000 |
18 | 17 | ||
diff --git a/include/asm-arm/arch-sa1100/ide.h b/include/asm-arm/arch-sa1100/ide.h index 2153538069c7..98b10bcf9f1b 100644 --- a/include/asm-arm/arch-sa1100/ide.h +++ b/include/asm-arm/arch-sa1100/ide.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * architectures. | 9 | * architectures. |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <asm/irq.h> | 12 | #include <asm/irq.h> |
14 | #include <asm/hardware.h> | 13 | #include <asm/hardware.h> |
15 | #include <asm/mach-types.h> | 14 | #include <asm/mach-types.h> |
diff --git a/include/asm-arm/arch-sa1100/irqs.h b/include/asm-arm/arch-sa1100/irqs.h index eabd3be3d705..d7940683efb1 100644 --- a/include/asm-arm/arch-sa1100/irqs.h +++ b/include/asm-arm/arch-sa1100/irqs.h | |||
@@ -7,7 +7,6 @@ | |||
7 | * | 7 | * |
8 | * 2001/11/14 RMK Cleaned up and standardised a lot of the IRQs. | 8 | * 2001/11/14 RMK Cleaned up and standardised a lot of the IRQs. |
9 | */ | 9 | */ |
10 | #include <linux/config.h> | ||
11 | 10 | ||
12 | #define IRQ_GPIO0 0 | 11 | #define IRQ_GPIO0 0 |
13 | #define IRQ_GPIO1 1 | 12 | #define IRQ_GPIO1 1 |
diff --git a/include/asm-arm/arch-sa1100/memory.h b/include/asm-arm/arch-sa1100/memory.h index a29fac1387ca..1ff172dc8e33 100644 --- a/include/asm-arm/arch-sa1100/memory.h +++ b/include/asm-arm/arch-sa1100/memory.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef __ASM_ARCH_MEMORY_H | 7 | #ifndef __ASM_ARCH_MEMORY_H |
8 | #define __ASM_ARCH_MEMORY_H | 8 | #define __ASM_ARCH_MEMORY_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <asm/sizes.h> | 10 | #include <asm/sizes.h> |
12 | 11 | ||
13 | /* | 12 | /* |
diff --git a/include/asm-arm/arch-sa1100/system.h b/include/asm-arm/arch-sa1100/system.h index 0f0612f79b2b..aef91e3b63fe 100644 --- a/include/asm-arm/arch-sa1100/system.h +++ b/include/asm-arm/arch-sa1100/system.h | |||
@@ -3,7 +3,6 @@ | |||
3 | * | 3 | * |
4 | * Copyright (c) 1999 Nicolas Pitre <nico@cam.org> | 4 | * Copyright (c) 1999 Nicolas Pitre <nico@cam.org> |
5 | */ | 5 | */ |
6 | #include <linux/config.h> | ||
7 | #include <asm/hardware.h> | 6 | #include <asm/hardware.h> |
8 | 7 | ||
9 | static inline void arch_idle(void) | 8 | static inline void arch_idle(void) |
diff --git a/include/asm-arm/arch-versatile/system.h b/include/asm-arm/arch-versatile/system.h index 8889a189739f..71c6254c0d9b 100644 --- a/include/asm-arm/arch-versatile/system.h +++ b/include/asm-arm/arch-versatile/system.h | |||
@@ -36,16 +36,14 @@ static inline void arch_idle(void) | |||
36 | 36 | ||
37 | static inline void arch_reset(char mode) | 37 | static inline void arch_reset(char mode) |
38 | { | 38 | { |
39 | unsigned int hdr_ctrl = (IO_ADDRESS(VERSATILE_SYS_BASE) + VERSATILE_SYS_RESETCTL_OFFSET); | 39 | u32 val; |
40 | unsigned int val; | ||
41 | 40 | ||
42 | /* | 41 | val = __raw_readl(IO_ADDRESS(VERSATILE_SYS_RESETCTL)) & ~0x7; |
43 | * To reset, we hit the on-board reset register | 42 | val |= 0x105; |
44 | * in the system FPGA | 43 | |
45 | */ | 44 | __raw_writel(0xa05f, IO_ADDRESS(VERSATILE_SYS_LOCK)); |
46 | val = __raw_readl(hdr_ctrl); | 45 | __raw_writel(val, IO_ADDRESS(VERSATILE_SYS_RESETCTL)); |
47 | val |= VERSATILE_SYS_CTRL_RESET_CONFIGCLR; | 46 | __raw_writel(0, IO_ADDRESS(VERSATILE_SYS_LOCK)); |
48 | __raw_writel(val, hdr_ctrl); | ||
49 | } | 47 | } |
50 | 48 | ||
51 | #endif | 49 | #endif |
diff --git a/include/asm-arm/atomic.h b/include/asm-arm/atomic.h index 3d7283d84405..4b0ce3e7de9a 100644 --- a/include/asm-arm/atomic.h +++ b/include/asm-arm/atomic.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef __ASM_ARM_ATOMIC_H | 11 | #ifndef __ASM_ARM_ATOMIC_H |
12 | #define __ASM_ARM_ATOMIC_H | 12 | #define __ASM_ARM_ATOMIC_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/compiler.h> | 14 | #include <linux/compiler.h> |
16 | 15 | ||
17 | typedef struct { volatile int counter; } atomic_t; | 16 | typedef struct { volatile int counter; } atomic_t; |
diff --git a/include/asm-arm/bug.h b/include/asm-arm/bug.h index 5ab8216f5204..7fb02138f585 100644 --- a/include/asm-arm/bug.h +++ b/include/asm-arm/bug.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define _ASMARM_BUG_H | 2 | #define _ASMARM_BUG_H |
3 | 3 | ||
4 | #include <linux/config.h> | 4 | #include <linux/config.h> |
5 | #include <linux/stddef.h> | ||
6 | 5 | ||
7 | #ifdef CONFIG_BUG | 6 | #ifdef CONFIG_BUG |
8 | #ifdef CONFIG_DEBUG_BUGVERBOSE | 7 | #ifdef CONFIG_DEBUG_BUGVERBOSE |
diff --git a/include/asm-arm/byteorder.h b/include/asm-arm/byteorder.h index 17eaf8bdf092..e6f7fcdc73b0 100644 --- a/include/asm-arm/byteorder.h +++ b/include/asm-arm/byteorder.h | |||
@@ -22,16 +22,18 @@ static inline __attribute_const__ __u32 ___arch__swab32(__u32 x) | |||
22 | { | 22 | { |
23 | __u32 t; | 23 | __u32 t; |
24 | 24 | ||
25 | if (__builtin_constant_p(x)) { | 25 | #ifndef __thumb__ |
26 | t = x ^ ((x << 16) | (x >> 16)); /* eor r1,r0,r0,ror #16 */ | 26 | if (!__builtin_constant_p(x)) { |
27 | } else { | ||
28 | /* | 27 | /* |
29 | * The compiler needs a bit of a hint here to always do the | 28 | * The compiler needs a bit of a hint here to always do the |
30 | * right thing and not screw it up to different degrees | 29 | * right thing and not screw it up to different degrees |
31 | * depending on the gcc version. | 30 | * depending on the gcc version. |
32 | */ | 31 | */ |
33 | asm ("eor\t%0, %1, %1, ror #16" : "=r" (t) : "r" (x)); | 32 | asm ("eor\t%0, %1, %1, ror #16" : "=r" (t) : "r" (x)); |
34 | } | 33 | } else |
34 | #endif | ||
35 | t = x ^ ((x << 16) | (x >> 16)); /* eor r1,r0,r0,ror #16 */ | ||
36 | |||
35 | x = (x << 24) | (x >> 8); /* mov r0,r0,ror #8 */ | 37 | x = (x << 24) | (x >> 8); /* mov r0,r0,ror #8 */ |
36 | t &= ~0x00FF0000; /* bic r1,r1,#0x00FF0000 */ | 38 | t &= ~0x00FF0000; /* bic r1,r1,#0x00FF0000 */ |
37 | x ^= (t >> 8); /* eor r0,r0,r1,lsr #8 */ | 39 | x ^= (t >> 8); /* eor r0,r0,r1,lsr #8 */ |
diff --git a/include/asm-arm/cacheflush.h b/include/asm-arm/cacheflush.h index 746be56b1b70..fe0c744e0266 100644 --- a/include/asm-arm/cacheflush.h +++ b/include/asm-arm/cacheflush.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASMARM_CACHEFLUSH_H | 10 | #ifndef _ASMARM_CACHEFLUSH_H |
11 | #define _ASMARM_CACHEFLUSH_H | 11 | #define _ASMARM_CACHEFLUSH_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/sched.h> | 13 | #include <linux/sched.h> |
15 | #include <linux/mm.h> | 14 | #include <linux/mm.h> |
16 | 15 | ||
diff --git a/include/asm-arm/cpu.h b/include/asm-arm/cpu.h index 751bc7462074..715426b9b08e 100644 --- a/include/asm-arm/cpu.h +++ b/include/asm-arm/cpu.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef __ASM_ARM_CPU_H | 10 | #ifndef __ASM_ARM_CPU_H |
11 | #define __ASM_ARM_CPU_H | 11 | #define __ASM_ARM_CPU_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/percpu.h> | 13 | #include <linux/percpu.h> |
15 | 14 | ||
16 | struct cpuinfo_arm { | 15 | struct cpuinfo_arm { |
diff --git a/include/asm-arm/dma-mapping.h b/include/asm-arm/dma-mapping.h index 63ca7412a462..55eb4dc3253d 100644 --- a/include/asm-arm/dma-mapping.h +++ b/include/asm-arm/dma-mapping.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <linux/mm.h> /* need struct page */ | 6 | #include <linux/mm.h> /* need struct page */ |
8 | 7 | ||
9 | #include <asm/scatterlist.h> | 8 | #include <asm/scatterlist.h> |
diff --git a/include/asm-arm/dma.h b/include/asm-arm/dma.h index 49c01e2bf7c8..9f2c5305c260 100644 --- a/include/asm-arm/dma.h +++ b/include/asm-arm/dma.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | typedef unsigned int dmach_t; | 4 | typedef unsigned int dmach_t; |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <linux/spinlock.h> | 6 | #include <linux/spinlock.h> |
8 | #include <asm/system.h> | 7 | #include <asm/system.h> |
9 | #include <asm/scatterlist.h> | 8 | #include <asm/scatterlist.h> |
diff --git a/include/asm-arm/elf.h b/include/asm-arm/elf.h index 2d44b42d1847..71061ca5c5d0 100644 --- a/include/asm-arm/elf.h +++ b/include/asm-arm/elf.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASMARM_ELF_H | 1 | #ifndef __ASMARM_ELF_H |
2 | #define __ASMARM_ELF_H | 2 | #define __ASMARM_ELF_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * ELF register definitions.. | 6 | * ELF register definitions.. |
diff --git a/include/asm-arm/fpstate.h b/include/asm-arm/fpstate.h index 52bae088a185..132c3c5628b2 100644 --- a/include/asm-arm/fpstate.h +++ b/include/asm-arm/fpstate.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef __ASM_ARM_FPSTATE_H | 11 | #ifndef __ASM_ARM_FPSTATE_H |
12 | #define __ASM_ARM_FPSTATE_H | 12 | #define __ASM_ARM_FPSTATE_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | #ifndef __ASSEMBLY__ | 15 | #ifndef __ASSEMBLY__ |
17 | 16 | ||
diff --git a/include/asm-arm/glue.h b/include/asm-arm/glue.h index 223e0d6c41be..0cc5d3b10ce2 100644 --- a/include/asm-arm/glue.h +++ b/include/asm-arm/glue.h | |||
@@ -15,7 +15,6 @@ | |||
15 | */ | 15 | */ |
16 | #ifdef __KERNEL__ | 16 | #ifdef __KERNEL__ |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | 18 | ||
20 | #ifdef __STDC__ | 19 | #ifdef __STDC__ |
21 | #define ____glue(name,fn) name##fn | 20 | #define ____glue(name,fn) name##fn |
diff --git a/include/asm-arm/hardirq.h b/include/asm-arm/hardirq.h index 1cbb173bf5b1..182310b99195 100644 --- a/include/asm-arm/hardirq.h +++ b/include/asm-arm/hardirq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_HARDIRQ_H | 1 | #ifndef __ASM_HARDIRQ_H |
2 | #define __ASM_HARDIRQ_H | 2 | #define __ASM_HARDIRQ_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/cache.h> | 4 | #include <linux/cache.h> |
6 | #include <linux/threads.h> | 5 | #include <linux/threads.h> |
7 | #include <asm/irq.h> | 6 | #include <asm/irq.h> |
diff --git a/include/asm-arm/hardware/dec21285.h b/include/asm-arm/hardware/dec21285.h index 6685e3fb97b1..546f7077be9c 100644 --- a/include/asm-arm/hardware/dec21285.h +++ b/include/asm-arm/hardware/dec21285.h | |||
@@ -18,7 +18,6 @@ | |||
18 | #define DC21285_PCI_IO 0x7c000000 | 18 | #define DC21285_PCI_IO 0x7c000000 |
19 | #define DC21285_PCI_MEM 0x80000000 | 19 | #define DC21285_PCI_MEM 0x80000000 |
20 | 20 | ||
21 | #include <linux/config.h> | ||
22 | #ifndef __ASSEMBLY__ | 21 | #ifndef __ASSEMBLY__ |
23 | #include <asm/hardware.h> | 22 | #include <asm/hardware.h> |
24 | #define DC21285_IO(x) ((volatile unsigned long *)(ARMCSR_BASE+(x))) | 23 | #define DC21285_IO(x) ((volatile unsigned long *)(ARMCSR_BASE+(x))) |
diff --git a/include/asm-arm/hardware/iomd.h b/include/asm-arm/hardware/iomd.h index 82fa2c279a18..396e55ad06c6 100644 --- a/include/asm-arm/hardware/iomd.h +++ b/include/asm-arm/hardware/iomd.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef __ASMARM_HARDWARE_IOMD_H | 13 | #ifndef __ASMARM_HARDWARE_IOMD_H |
14 | #define __ASMARM_HARDWARE_IOMD_H | 14 | #define __ASMARM_HARDWARE_IOMD_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | #ifndef __ASSEMBLY__ | 17 | #ifndef __ASSEMBLY__ |
19 | 18 | ||
diff --git a/include/asm-arm/hardware/sharpsl_pm.h b/include/asm-arm/hardware/sharpsl_pm.h index 36983e5f3665..ecf15b83956f 100644 --- a/include/asm-arm/hardware/sharpsl_pm.h +++ b/include/asm-arm/hardware/sharpsl_pm.h | |||
@@ -16,6 +16,7 @@ struct sharpsl_charger_machinfo { | |||
16 | void (*exit)(void); | 16 | void (*exit)(void); |
17 | int gpio_acin; | 17 | int gpio_acin; |
18 | int gpio_batfull; | 18 | int gpio_batfull; |
19 | int batfull_irq; | ||
19 | int gpio_batlock; | 20 | int gpio_batlock; |
20 | int gpio_fatal; | 21 | int gpio_fatal; |
21 | void (*discharge)(int); | 22 | void (*discharge)(int); |
@@ -34,9 +35,19 @@ struct sharpsl_charger_machinfo { | |||
34 | #define SHARPSL_STATUS_FATAL 7 | 35 | #define SHARPSL_STATUS_FATAL 7 |
35 | unsigned long (*charger_wakeup)(void); | 36 | unsigned long (*charger_wakeup)(void); |
36 | int (*should_wakeup)(unsigned int resume_on_alarm); | 37 | int (*should_wakeup)(unsigned int resume_on_alarm); |
38 | void (*backlight_limit)(int); | ||
39 | int (*backlight_get_status) (void); | ||
40 | int charge_on_volt; | ||
41 | int charge_on_temp; | ||
42 | int charge_acin_high; | ||
43 | int charge_acin_low; | ||
44 | int fatal_acin_volt; | ||
45 | int fatal_noacin_volt; | ||
37 | int bat_levels; | 46 | int bat_levels; |
38 | struct battery_thresh *bat_levels_noac; | 47 | struct battery_thresh *bat_levels_noac; |
39 | struct battery_thresh *bat_levels_acin; | 48 | struct battery_thresh *bat_levels_acin; |
49 | struct battery_thresh *bat_levels_noac_bl; | ||
50 | struct battery_thresh *bat_levels_acin_bl; | ||
40 | int status_high_acin; | 51 | int status_high_acin; |
41 | int status_low_acin; | 52 | int status_low_acin; |
42 | int status_high_noac; | 53 | int status_high_noac; |
diff --git a/include/asm-arm/leds.h b/include/asm-arm/leds.h index 88ce4124f854..12290ea55801 100644 --- a/include/asm-arm/leds.h +++ b/include/asm-arm/leds.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef ASM_ARM_LEDS_H | 13 | #ifndef ASM_ARM_LEDS_H |
14 | #define ASM_ARM_LEDS_H | 14 | #define ASM_ARM_LEDS_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | typedef enum { | 17 | typedef enum { |
19 | led_idle_start, | 18 | led_idle_start, |
diff --git a/include/asm-arm/mach/serial_at91rm9200.h b/include/asm-arm/mach/serial_at91.h index 98f4b0cb883c..1290bb32802d 100644 --- a/include/asm-arm/mach/serial_at91rm9200.h +++ b/include/asm-arm/mach/serial_at91.h | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * linux/include/asm-arm/mach/serial_at91rm9200.h | 2 | * linux/include/asm-arm/mach/serial_at91.h |
3 | * | 3 | * |
4 | * Based on serial_sa1100.h by Nicolas Pitre | 4 | * Based on serial_sa1100.h by Nicolas Pitre |
5 | * | 5 | * |
@@ -7,7 +7,6 @@ | |||
7 | * | 7 | * |
8 | * Low level machine dependent UART functions. | 8 | * Low level machine dependent UART functions. |
9 | */ | 9 | */ |
10 | #include <linux/config.h> | ||
11 | 10 | ||
12 | struct uart_port; | 11 | struct uart_port; |
13 | 12 | ||
@@ -15,7 +14,7 @@ struct uart_port; | |||
15 | * This is a temporary structure for registering these | 14 | * This is a temporary structure for registering these |
16 | * functions; it is intended to be discarded after boot. | 15 | * functions; it is intended to be discarded after boot. |
17 | */ | 16 | */ |
18 | struct at91rm9200_port_fns { | 17 | struct at91_port_fns { |
19 | void (*set_mctrl)(struct uart_port *, u_int); | 18 | void (*set_mctrl)(struct uart_port *, u_int); |
20 | u_int (*get_mctrl)(struct uart_port *); | 19 | u_int (*get_mctrl)(struct uart_port *); |
21 | void (*enable_ms)(struct uart_port *); | 20 | void (*enable_ms)(struct uart_port *); |
@@ -26,11 +25,9 @@ struct at91rm9200_port_fns { | |||
26 | }; | 25 | }; |
27 | 26 | ||
28 | #if defined(CONFIG_SERIAL_AT91) | 27 | #if defined(CONFIG_SERIAL_AT91) |
29 | void at91_register_uart_fns(struct at91rm9200_port_fns *fns); | 28 | void at91_register_uart_fns(struct at91_port_fns *fns); |
30 | void at91_register_uart(int idx, int port); | ||
31 | #else | 29 | #else |
32 | #define at91_register_uart_fns(fns) do { } while (0) | 30 | #define at91_register_uart_fns(fns) do { } while (0) |
33 | #define at91_register_uart(idx,port) do { } while (0) | ||
34 | #endif | 31 | #endif |
35 | 32 | ||
36 | 33 | ||
diff --git a/include/asm-arm/mach/serial_sa1100.h b/include/asm-arm/mach/serial_sa1100.h index 9162018585df..20c22bb218d9 100644 --- a/include/asm-arm/mach/serial_sa1100.h +++ b/include/asm-arm/mach/serial_sa1100.h | |||
@@ -7,7 +7,6 @@ | |||
7 | * | 7 | * |
8 | * Low level machine dependent UART functions. | 8 | * Low level machine dependent UART functions. |
9 | */ | 9 | */ |
10 | #include <linux/config.h> | ||
11 | 10 | ||
12 | struct uart_port; | 11 | struct uart_port; |
13 | struct uart_info; | 12 | struct uart_info; |
diff --git a/include/asm-arm/mach/time.h b/include/asm-arm/mach/time.h index 96c6db7dd0e1..9f28073559e8 100644 --- a/include/asm-arm/mach/time.h +++ b/include/asm-arm/mach/time.h | |||
@@ -50,6 +50,7 @@ struct sys_timer { | |||
50 | #define DYN_TICK_ENABLED (1 << 1) | 50 | #define DYN_TICK_ENABLED (1 << 1) |
51 | 51 | ||
52 | struct dyn_tick_timer { | 52 | struct dyn_tick_timer { |
53 | spinlock_t lock; | ||
53 | unsigned int state; /* Current state */ | 54 | unsigned int state; /* Current state */ |
54 | int (*enable)(void); /* Enables dynamic tick */ | 55 | int (*enable)(void); /* Enables dynamic tick */ |
55 | int (*disable)(void); /* Disables dynamic tick */ | 56 | int (*disable)(void); /* Disables dynamic tick */ |
diff --git a/include/asm-arm/memory.h b/include/asm-arm/memory.h index 209289407595..731e321a57d1 100644 --- a/include/asm-arm/memory.h +++ b/include/asm-arm/memory.h | |||
@@ -22,7 +22,6 @@ | |||
22 | #define UL(x) (x) | 22 | #define UL(x) (x) |
23 | #endif | 23 | #endif |
24 | 24 | ||
25 | #include <linux/config.h> | ||
26 | #include <linux/compiler.h> | 25 | #include <linux/compiler.h> |
27 | #include <asm/arch/memory.h> | 26 | #include <asm/arch/memory.h> |
28 | #include <asm/sizes.h> | 27 | #include <asm/sizes.h> |
diff --git a/include/asm-arm/page.h b/include/asm-arm/page.h index a404d2bf0c68..66cfeb5290ea 100644 --- a/include/asm-arm/page.h +++ b/include/asm-arm/page.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASMARM_PAGE_H | 10 | #ifndef _ASMARM_PAGE_H |
11 | #define _ASMARM_PAGE_H | 11 | #define _ASMARM_PAGE_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | /* PAGE_SHIFT determines the page size */ | 14 | /* PAGE_SHIFT determines the page size */ |
16 | #define PAGE_SHIFT 12 | 15 | #define PAGE_SHIFT 12 |
diff --git a/include/asm-arm/pci.h b/include/asm-arm/pci.h index ead3ced38cb8..f21abd4ddac6 100644 --- a/include/asm-arm/pci.h +++ b/include/asm-arm/pci.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define ASMARM_PCI_H | 2 | #define ASMARM_PCI_H |
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | #include <linux/config.h> | ||
6 | #include <asm-generic/pci-dma-compat.h> | 5 | #include <asm-generic/pci-dma-compat.h> |
7 | 6 | ||
8 | #include <asm/hardware.h> /* for PCIBIOS_MIN_* */ | 7 | #include <asm/hardware.h> /* for PCIBIOS_MIN_* */ |
diff --git a/include/asm-arm/proc-fns.h b/include/asm-arm/proc-fns.h index 106045edb862..e9310895e79d 100644 --- a/include/asm-arm/proc-fns.h +++ b/include/asm-arm/proc-fns.h | |||
@@ -13,7 +13,6 @@ | |||
13 | 13 | ||
14 | #ifdef __KERNEL__ | 14 | #ifdef __KERNEL__ |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | /* | 17 | /* |
19 | * Work out if we need multiple CPU support | 18 | * Work out if we need multiple CPU support |
diff --git a/include/asm-arm/ptrace.h b/include/asm-arm/ptrace.h index 77adb7fa169b..2bebe3dc0a30 100644 --- a/include/asm-arm/ptrace.h +++ b/include/asm-arm/ptrace.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef __ASM_ARM_PTRACE_H | 10 | #ifndef __ASM_ARM_PTRACE_H |
11 | #define __ASM_ARM_PTRACE_H | 11 | #define __ASM_ARM_PTRACE_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | #define PTRACE_GETREGS 12 | 14 | #define PTRACE_GETREGS 12 |
16 | #define PTRACE_SETREGS 13 | 15 | #define PTRACE_SETREGS 13 |
diff --git a/include/asm-arm/smp.h b/include/asm-arm/smp.h index fe45f7f61223..f67acce387e7 100644 --- a/include/asm-arm/smp.h +++ b/include/asm-arm/smp.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef __ASM_ARM_SMP_H | 10 | #ifndef __ASM_ARM_SMP_H |
11 | #define __ASM_ARM_SMP_H | 11 | #define __ASM_ARM_SMP_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/threads.h> | 13 | #include <linux/threads.h> |
15 | #include <linux/cpumask.h> | 14 | #include <linux/cpumask.h> |
16 | #include <linux/thread_info.h> | 15 | #include <linux/thread_info.h> |
diff --git a/include/asm-arm/system.h b/include/asm-arm/system.h index 7c9568d30307..6001febfe63b 100644 --- a/include/asm-arm/system.h +++ b/include/asm-arm/system.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | #define CPU_ARCH_UNKNOWN 0 | 7 | #define CPU_ARCH_UNKNOWN 0 |
9 | #define CPU_ARCH_ARMv3 1 | 8 | #define CPU_ARCH_ARMv3 1 |
@@ -108,6 +107,9 @@ extern void __show_regs(struct pt_regs *); | |||
108 | extern int cpu_architecture(void); | 107 | extern int cpu_architecture(void); |
109 | extern void cpu_init(void); | 108 | extern void cpu_init(void); |
110 | 109 | ||
110 | void arm_machine_restart(char mode); | ||
111 | extern void (*arm_pm_restart)(char str); | ||
112 | |||
111 | /* | 113 | /* |
112 | * Intel's XScale3 core supports some v6 features (supersections, L2) | 114 | * Intel's XScale3 core supports some v6 features (supersections, L2) |
113 | * but advertises itself as v5 as it does not support the v6 ISA. For | 115 | * but advertises itself as v5 as it does not support the v6 ISA. For |
diff --git a/include/asm-arm/tlbflush.h b/include/asm-arm/tlbflush.h index 728992451dd1..d97fc76189a5 100644 --- a/include/asm-arm/tlbflush.h +++ b/include/asm-arm/tlbflush.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASMARM_TLBFLUSH_H | 10 | #ifndef _ASMARM_TLBFLUSH_H |
11 | #define _ASMARM_TLBFLUSH_H | 11 | #define _ASMARM_TLBFLUSH_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | #ifndef CONFIG_MMU | 14 | #ifndef CONFIG_MMU |
16 | 15 | ||
diff --git a/include/asm-arm/unistd.h b/include/asm-arm/unistd.h index cbf39a56dbe7..1e891f860ef3 100644 --- a/include/asm-arm/unistd.h +++ b/include/asm-arm/unistd.h | |||
@@ -13,8 +13,6 @@ | |||
13 | #ifndef __ASM_ARM_UNISTD_H | 13 | #ifndef __ASM_ARM_UNISTD_H |
14 | #define __ASM_ARM_UNISTD_H | 14 | #define __ASM_ARM_UNISTD_H |
15 | 15 | ||
16 | #include <linux/linkage.h> | ||
17 | |||
18 | #define __NR_OABI_SYSCALL_BASE 0x900000 | 16 | #define __NR_OABI_SYSCALL_BASE 0x900000 |
19 | 17 | ||
20 | #if defined(__thumb__) || defined(__ARM_EABI__) | 18 | #if defined(__thumb__) || defined(__ARM_EABI__) |
@@ -378,6 +376,9 @@ | |||
378 | #undef __NR_ipc | 376 | #undef __NR_ipc |
379 | #endif | 377 | #endif |
380 | 378 | ||
379 | #ifdef __KERNEL__ | ||
380 | #include <linux/linkage.h> | ||
381 | |||
381 | #define __sys2(x) #x | 382 | #define __sys2(x) #x |
382 | #define __sys1(x) __sys2(x) | 383 | #define __sys1(x) __sys2(x) |
383 | 384 | ||
@@ -526,7 +527,6 @@ type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4, type5 arg5, type6 arg6 | |||
526 | __syscall_return(type,__res); \ | 527 | __syscall_return(type,__res); \ |
527 | } | 528 | } |
528 | 529 | ||
529 | #ifdef __KERNEL__ | ||
530 | #define __ARCH_WANT_IPC_PARSE_VERSION | 530 | #define __ARCH_WANT_IPC_PARSE_VERSION |
531 | #define __ARCH_WANT_STAT64 | 531 | #define __ARCH_WANT_STAT64 |
532 | #define __ARCH_WANT_SYS_GETHOSTNAME | 532 | #define __ARCH_WANT_SYS_GETHOSTNAME |
@@ -547,7 +547,6 @@ type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4, type5 arg5, type6 arg6 | |||
547 | #define __ARCH_WANT_OLD_READDIR | 547 | #define __ARCH_WANT_OLD_READDIR |
548 | #define __ARCH_WANT_SYS_SOCKETCALL | 548 | #define __ARCH_WANT_SYS_SOCKETCALL |
549 | #endif | 549 | #endif |
550 | #endif | ||
551 | 550 | ||
552 | #ifdef __KERNEL_SYSCALLS__ | 551 | #ifdef __KERNEL_SYSCALLS__ |
553 | 552 | ||
@@ -571,7 +570,7 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
571 | struct sigaction __user *oact, | 570 | struct sigaction __user *oact, |
572 | size_t sigsetsize); | 571 | size_t sigsetsize); |
573 | 572 | ||
574 | #endif | 573 | #endif /* __KERNEL_SYSCALLS__ */ |
575 | 574 | ||
576 | /* | 575 | /* |
577 | * "Conditional" syscalls | 576 | * "Conditional" syscalls |
@@ -581,4 +580,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
581 | */ | 580 | */ |
582 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 581 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
583 | 582 | ||
583 | #endif /* __KERNEL__ */ | ||
584 | #endif /* __ASM_ARM_UNISTD_H */ | 584 | #endif /* __ASM_ARM_UNISTD_H */ |
diff --git a/include/asm-arm/vga.h b/include/asm-arm/vga.h index 926e5ee128e9..1e0b913c3d71 100644 --- a/include/asm-arm/vga.h +++ b/include/asm-arm/vga.h | |||
@@ -4,7 +4,7 @@ | |||
4 | #include <asm/hardware.h> | 4 | #include <asm/hardware.h> |
5 | #include <asm/io.h> | 5 | #include <asm/io.h> |
6 | 6 | ||
7 | #define VGA_MAP_MEM(x) (PCIMEM_BASE + (x)) | 7 | #define VGA_MAP_MEM(x,s) (PCIMEM_BASE + (x)) |
8 | 8 | ||
9 | #define vga_readb(x) (*((volatile unsigned char *)x)) | 9 | #define vga_readb(x) (*((volatile unsigned char *)x)) |
10 | #define vga_writeb(x,y) (*((volatile unsigned char *)y) = (x)) | 10 | #define vga_writeb(x,y) (*((volatile unsigned char *)y) = (x)) |
diff --git a/include/asm-arm26/atomic.h b/include/asm-arm26/atomic.h index 1552c8653990..97e944fe1cff 100644 --- a/include/asm-arm26/atomic.h +++ b/include/asm-arm26/atomic.h | |||
@@ -20,7 +20,6 @@ | |||
20 | #ifndef __ASM_ARM_ATOMIC_H | 20 | #ifndef __ASM_ARM_ATOMIC_H |
21 | #define __ASM_ARM_ATOMIC_H | 21 | #define __ASM_ARM_ATOMIC_H |
22 | 22 | ||
23 | #include <linux/config.h> | ||
24 | 23 | ||
25 | #ifdef CONFIG_SMP | 24 | #ifdef CONFIG_SMP |
26 | #error SMP is NOT supported | 25 | #error SMP is NOT supported |
diff --git a/include/asm-arm26/bug.h b/include/asm-arm26/bug.h index 7177c7399967..8545d58b0475 100644 --- a/include/asm-arm26/bug.h +++ b/include/asm-arm26/bug.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASMARM_BUG_H | 1 | #ifndef _ASMARM_BUG_H |
2 | #define _ASMARM_BUG_H | 2 | #define _ASMARM_BUG_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_BUG | 5 | #ifdef CONFIG_BUG |
7 | #ifdef CONFIG_DEBUG_BUGVERBOSE | 6 | #ifdef CONFIG_DEBUG_BUGVERBOSE |
diff --git a/include/asm-arm26/dma.h b/include/asm-arm26/dma.h index 995e223e43a1..4326ba85eb72 100644 --- a/include/asm-arm26/dma.h +++ b/include/asm-arm26/dma.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | typedef unsigned int dmach_t; | 4 | typedef unsigned int dmach_t; |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <linux/spinlock.h> | 6 | #include <linux/spinlock.h> |
8 | #include <asm/system.h> | 7 | #include <asm/system.h> |
9 | #include <asm/memory.h> | 8 | #include <asm/memory.h> |
diff --git a/include/asm-arm26/hardirq.h b/include/asm-arm26/hardirq.h index 87c19d2bb6a8..e717742ffce0 100644 --- a/include/asm-arm26/hardirq.h +++ b/include/asm-arm26/hardirq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_HARDIRQ_H | 1 | #ifndef __ASM_HARDIRQ_H |
2 | #define __ASM_HARDIRQ_H | 2 | #define __ASM_HARDIRQ_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/cache.h> | 4 | #include <linux/cache.h> |
6 | #include <linux/threads.h> | 5 | #include <linux/threads.h> |
7 | #include <asm/irq.h> | 6 | #include <asm/irq.h> |
diff --git a/include/asm-arm26/hardware.h b/include/asm-arm26/hardware.h index 82fc55e2a009..801df0bde8b7 100644 --- a/include/asm-arm26/hardware.h +++ b/include/asm-arm26/hardware.h | |||
@@ -16,7 +16,6 @@ | |||
16 | #ifndef __ASM_HARDWARE_H | 16 | #ifndef __ASM_HARDWARE_H |
17 | #define __ASM_HARDWARE_H | 17 | #define __ASM_HARDWARE_H |
18 | 18 | ||
19 | #include <linux/config.h> | ||
20 | 19 | ||
21 | 20 | ||
22 | /* | 21 | /* |
diff --git a/include/asm-arm26/io.h b/include/asm-arm26/io.h index 02f94d88a124..2aa033bd0678 100644 --- a/include/asm-arm26/io.h +++ b/include/asm-arm26/io.h | |||
@@ -22,7 +22,6 @@ | |||
22 | 22 | ||
23 | #ifdef __KERNEL__ | 23 | #ifdef __KERNEL__ |
24 | 24 | ||
25 | #include <linux/config.h> | ||
26 | #include <linux/types.h> | 25 | #include <linux/types.h> |
27 | #include <asm/byteorder.h> | 26 | #include <asm/byteorder.h> |
28 | #include <asm/memory.h> | 27 | #include <asm/memory.h> |
diff --git a/include/asm-arm26/leds.h b/include/asm-arm26/leds.h index 88ce4124f854..12290ea55801 100644 --- a/include/asm-arm26/leds.h +++ b/include/asm-arm26/leds.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef ASM_ARM_LEDS_H | 13 | #ifndef ASM_ARM_LEDS_H |
14 | #define ASM_ARM_LEDS_H | 14 | #define ASM_ARM_LEDS_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | typedef enum { | 17 | typedef enum { |
19 | led_idle_start, | 18 | led_idle_start, |
diff --git a/include/asm-arm26/mach-types.h b/include/asm-arm26/mach-types.h index b34045b78128..0aeaedcbac96 100644 --- a/include/asm-arm26/mach-types.h +++ b/include/asm-arm26/mach-types.h | |||
@@ -6,7 +6,6 @@ | |||
6 | #ifndef __ASM_ARM_MACH_TYPE_H | 6 | #ifndef __ASM_ARM_MACH_TYPE_H |
7 | #define __ASM_ARM_MACH_TYPE_H | 7 | #define __ASM_ARM_MACH_TYPE_H |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | #ifndef __ASSEMBLY__ | 10 | #ifndef __ASSEMBLY__ |
12 | extern unsigned int __machine_arch_type; | 11 | extern unsigned int __machine_arch_type; |
diff --git a/include/asm-arm26/page.h b/include/asm-arm26/page.h index d3f23ac4d468..fa19de28fda0 100644 --- a/include/asm-arm26/page.h +++ b/include/asm-arm26/page.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASMARM_PAGE_H | 1 | #ifndef _ASMARM_PAGE_H |
2 | #define _ASMARM_PAGE_H | 2 | #define _ASMARM_PAGE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef __KERNEL__ | 5 | #ifdef __KERNEL__ |
7 | #ifndef __ASSEMBLY__ | 6 | #ifndef __ASSEMBLY__ |
diff --git a/include/asm-arm26/pgtable.h b/include/asm-arm26/pgtable.h index a590250277f8..19ac9101a6bb 100644 --- a/include/asm-arm26/pgtable.h +++ b/include/asm-arm26/pgtable.h | |||
@@ -13,7 +13,6 @@ | |||
13 | 13 | ||
14 | #include <asm-generic/4level-fixup.h> | 14 | #include <asm-generic/4level-fixup.h> |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <asm/memory.h> | 16 | #include <asm/memory.h> |
18 | 17 | ||
19 | /* | 18 | /* |
diff --git a/include/asm-arm26/serial.h b/include/asm-arm26/serial.h index 5fc747d1b501..dd86a716cb0b 100644 --- a/include/asm-arm26/serial.h +++ b/include/asm-arm26/serial.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #ifndef __ASM_SERIAL_H | 14 | #ifndef __ASM_SERIAL_H |
15 | #define __ASM_SERIAL_H | 15 | #define __ASM_SERIAL_H |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | 17 | ||
19 | /* | 18 | /* |
20 | * This assumes you have a 1.8432 MHz clock for your UART. | 19 | * This assumes you have a 1.8432 MHz clock for your UART. |
diff --git a/include/asm-arm26/smp.h b/include/asm-arm26/smp.h index 5ca771631fd8..38349ec8b61b 100644 --- a/include/asm-arm26/smp.h +++ b/include/asm-arm26/smp.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_SMP_H | 1 | #ifndef __ASM_SMP_H |
2 | #define __ASM_SMP_H | 2 | #define __ASM_SMP_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_SMP | 5 | #ifdef CONFIG_SMP |
7 | #error SMP not supported | 6 | #error SMP not supported |
diff --git a/include/asm-arm26/sysirq.h b/include/asm-arm26/sysirq.h index cad250c7b9ec..81dca90d9a3f 100644 --- a/include/asm-arm26/sysirq.h +++ b/include/asm-arm26/sysirq.h | |||
@@ -11,7 +11,6 @@ | |||
11 | * 04-04-1998 PJB Merged arc and a5k versions | 11 | * 04-04-1998 PJB Merged arc and a5k versions |
12 | */ | 12 | */ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | #if defined(CONFIG_ARCH_A5K) | 15 | #if defined(CONFIG_ARCH_A5K) |
17 | #define IRQ_PRINTER 0 | 16 | #define IRQ_PRINTER 0 |
diff --git a/include/asm-arm26/system.h b/include/asm-arm26/system.h index 702884926a55..d1f69d706198 100644 --- a/include/asm-arm26/system.h +++ b/include/asm-arm26/system.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | /* | 7 | /* |
9 | * This is used to ensure the compiler did actually allocate the register we | 8 | * This is used to ensure the compiler did actually allocate the register we |
diff --git a/include/asm-arm26/unistd.h b/include/asm-arm26/unistd.h index be4c2fb9c049..70eb6d91cfd0 100644 --- a/include/asm-arm26/unistd.h +++ b/include/asm-arm26/unistd.h | |||
@@ -14,8 +14,6 @@ | |||
14 | #ifndef __ASM_ARM_UNISTD_H | 14 | #ifndef __ASM_ARM_UNISTD_H |
15 | #define __ASM_ARM_UNISTD_H | 15 | #define __ASM_ARM_UNISTD_H |
16 | 16 | ||
17 | #include <linux/linkage.h> | ||
18 | |||
19 | #define __NR_SYSCALL_BASE 0x900000 | 17 | #define __NR_SYSCALL_BASE 0x900000 |
20 | 18 | ||
21 | /* | 19 | /* |
@@ -312,6 +310,9 @@ | |||
312 | #define __ARM_NR_cacheflush (__ARM_NR_BASE+2) | 310 | #define __ARM_NR_cacheflush (__ARM_NR_BASE+2) |
313 | #define __ARM_NR_usr26 (__ARM_NR_BASE+3) | 311 | #define __ARM_NR_usr26 (__ARM_NR_BASE+3) |
314 | 312 | ||
313 | #ifdef __KERNEL__ | ||
314 | #include <linux/linkage.h> | ||
315 | |||
315 | #define __sys2(x) #x | 316 | #define __sys2(x) #x |
316 | #define __sys1(x) __sys2(x) | 317 | #define __sys1(x) __sys2(x) |
317 | 318 | ||
@@ -443,7 +444,6 @@ type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4, type5 arg5, type6 arg6 | |||
443 | __syscall_return(type,__res); \ | 444 | __syscall_return(type,__res); \ |
444 | } | 445 | } |
445 | 446 | ||
446 | #ifdef __KERNEL__ | ||
447 | #define __ARCH_WANT_IPC_PARSE_VERSION | 447 | #define __ARCH_WANT_IPC_PARSE_VERSION |
448 | #define __ARCH_WANT_OLD_READDIR | 448 | #define __ARCH_WANT_OLD_READDIR |
449 | #define __ARCH_WANT_STAT64 | 449 | #define __ARCH_WANT_STAT64 |
@@ -462,7 +462,6 @@ type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4, type5 arg5, type6 arg6 | |||
462 | #define __ARCH_WANT_SYS_SIGPENDING | 462 | #define __ARCH_WANT_SYS_SIGPENDING |
463 | #define __ARCH_WANT_SYS_SIGPROCMASK | 463 | #define __ARCH_WANT_SYS_SIGPROCMASK |
464 | #define __ARCH_WANT_SYS_RT_SIGACTION | 464 | #define __ARCH_WANT_SYS_RT_SIGACTION |
465 | #endif | ||
466 | 465 | ||
467 | #ifdef __KERNEL_SYSCALLS__ | 466 | #ifdef __KERNEL_SYSCALLS__ |
468 | 467 | ||
@@ -486,7 +485,7 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
486 | struct sigaction __user *oact, | 485 | struct sigaction __user *oact, |
487 | size_t sigsetsize); | 486 | size_t sigsetsize); |
488 | 487 | ||
489 | #endif | 488 | #endif /* __KERNEL_SYSCALLS__ */ |
490 | 489 | ||
491 | /* | 490 | /* |
492 | * "Conditional" syscalls | 491 | * "Conditional" syscalls |
@@ -496,4 +495,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
496 | */ | 495 | */ |
497 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 496 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
498 | 497 | ||
498 | #endif /* __KERNEL__ */ | ||
499 | #endif /* __ASM_ARM_UNISTD_H */ | 499 | #endif /* __ASM_ARM_UNISTD_H */ |
diff --git a/include/asm-cris/arch-v10/io.h b/include/asm-cris/arch-v10/io.h index dd39198ec67d..11ef5b53d84e 100644 --- a/include/asm-cris/arch-v10/io.h +++ b/include/asm-cris/arch-v10/io.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define _ASM_ARCH_CRIS_IO_H | 2 | #define _ASM_ARCH_CRIS_IO_H |
3 | 3 | ||
4 | #include <asm/arch/svinto.h> | 4 | #include <asm/arch/svinto.h> |
5 | #include <linux/config.h> | ||
6 | 5 | ||
7 | /* Etrax shadow registers - which live in arch/cris/kernel/shadows.c */ | 6 | /* Etrax shadow registers - which live in arch/cris/kernel/shadows.c */ |
8 | 7 | ||
diff --git a/include/asm-cris/arch-v10/page.h b/include/asm-cris/arch-v10/page.h index 407e6e68f49e..7d8307aed7f3 100644 --- a/include/asm-cris/arch-v10/page.h +++ b/include/asm-cris/arch-v10/page.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _CRIS_ARCH_PAGE_H | 1 | #ifndef _CRIS_ARCH_PAGE_H |
2 | #define _CRIS_ARCH_PAGE_H | 2 | #define _CRIS_ARCH_PAGE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef __KERNEL__ | 5 | #ifdef __KERNEL__ |
7 | 6 | ||
diff --git a/include/asm-cris/arch-v10/system.h b/include/asm-cris/arch-v10/system.h index 1ac7b639b1b0..4a9cd36c9e16 100644 --- a/include/asm-cris/arch-v10/system.h +++ b/include/asm-cris/arch-v10/system.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_CRIS_ARCH_SYSTEM_H | 1 | #ifndef __ASM_CRIS_ARCH_SYSTEM_H |
2 | #define __ASM_CRIS_ARCH_SYSTEM_H | 2 | #define __ASM_CRIS_ARCH_SYSTEM_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* read the CPU version register */ | 5 | /* read the CPU version register */ |
7 | 6 | ||
diff --git a/include/asm-cris/arch-v32/io.h b/include/asm-cris/arch-v32/io.h index 043c9ce5294e..5efe4d949001 100644 --- a/include/asm-cris/arch-v32/io.h +++ b/include/asm-cris/arch-v32/io.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #include <asm/arch/hwregs/reg_map.h> | 4 | #include <asm/arch/hwregs/reg_map.h> |
5 | #include <asm/arch/hwregs/reg_rdwr.h> | 5 | #include <asm/arch/hwregs/reg_rdwr.h> |
6 | #include <asm/arch/hwregs/gio_defs.h> | 6 | #include <asm/arch/hwregs/gio_defs.h> |
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | enum crisv32_io_dir | 8 | enum crisv32_io_dir |
10 | { | 9 | { |
diff --git a/include/asm-cris/arch-v32/irq.h b/include/asm-cris/arch-v32/irq.h index d35aa8174c2f..eeb0a80262c8 100644 --- a/include/asm-cris/arch-v32/irq.h +++ b/include/asm-cris/arch-v32/irq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_ARCH_IRQ_H | 1 | #ifndef _ASM_ARCH_IRQ_H |
2 | #define _ASM_ARCH_IRQ_H | 2 | #define _ASM_ARCH_IRQ_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include "hwregs/intr_vect.h" | 4 | #include "hwregs/intr_vect.h" |
6 | 5 | ||
7 | /* Number of non-cpu interrupts. */ | 6 | /* Number of non-cpu interrupts. */ |
diff --git a/include/asm-cris/arch-v32/page.h b/include/asm-cris/arch-v32/page.h index 77827bc17cca..fa454fe12425 100644 --- a/include/asm-cris/arch-v32/page.h +++ b/include/asm-cris/arch-v32/page.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_CRIS_ARCH_PAGE_H | 1 | #ifndef _ASM_CRIS_ARCH_PAGE_H |
2 | #define _ASM_CRIS_ARCH_PAGE_H | 2 | #define _ASM_CRIS_ARCH_PAGE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef __KERNEL__ | 5 | #ifdef __KERNEL__ |
7 | 6 | ||
diff --git a/include/asm-cris/arch-v32/processor.h b/include/asm-cris/arch-v32/processor.h index 32bf2e538ced..5553b0cd02bf 100644 --- a/include/asm-cris/arch-v32/processor.h +++ b/include/asm-cris/arch-v32/processor.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_CRIS_ARCH_PROCESSOR_H | 1 | #ifndef _ASM_CRIS_ARCH_PROCESSOR_H |
2 | #define _ASM_CRIS_ARCH_PROCESSOR_H | 2 | #define _ASM_CRIS_ARCH_PROCESSOR_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* Return current instruction pointer. */ | 5 | /* Return current instruction pointer. */ |
7 | #define current_text_addr() \ | 6 | #define current_text_addr() \ |
diff --git a/include/asm-cris/arch-v32/system.h b/include/asm-cris/arch-v32/system.h index a3d75d581e2f..d20e2d6d64a3 100644 --- a/include/asm-cris/arch-v32/system.h +++ b/include/asm-cris/arch-v32/system.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_CRIS_ARCH_SYSTEM_H | 1 | #ifndef _ASM_CRIS_ARCH_SYSTEM_H |
2 | #define _ASM_CRIS_ARCH_SYSTEM_H | 2 | #define _ASM_CRIS_ARCH_SYSTEM_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* Read the CPU version register. */ | 5 | /* Read the CPU version register. */ |
7 | static inline unsigned long rdvr(void) | 6 | static inline unsigned long rdvr(void) |
diff --git a/include/asm-cris/eshlibld.h b/include/asm-cris/eshlibld.h index 2b577cde17eb..10ce36cf79a9 100644 --- a/include/asm-cris/eshlibld.h +++ b/include/asm-cris/eshlibld.h | |||
@@ -32,7 +32,6 @@ | |||
32 | /* We have dependencies all over the place for the host system | 32 | /* We have dependencies all over the place for the host system |
33 | for xsim being a linux system, so let's not pretend anything | 33 | for xsim being a linux system, so let's not pretend anything |
34 | else with #ifdef:s here until fixed. */ | 34 | else with #ifdef:s here until fixed. */ |
35 | #include <linux/config.h> | ||
36 | #include <linux/limits.h> | 35 | #include <linux/limits.h> |
37 | 36 | ||
38 | /* Maybe do sanity checking if file input. */ | 37 | /* Maybe do sanity checking if file input. */ |
diff --git a/include/asm-cris/etraxgpio.h b/include/asm-cris/etraxgpio.h index 80ee10f70d43..5d0028dba7c6 100644 --- a/include/asm-cris/etraxgpio.h +++ b/include/asm-cris/etraxgpio.h | |||
@@ -25,7 +25,6 @@ | |||
25 | #ifndef _ASM_ETRAXGPIO_H | 25 | #ifndef _ASM_ETRAXGPIO_H |
26 | #define _ASM_ETRAXGPIO_H | 26 | #define _ASM_ETRAXGPIO_H |
27 | 27 | ||
28 | #include <linux/config.h> | ||
29 | /* etraxgpio _IOC_TYPE, bits 8 to 15 in ioctl cmd */ | 28 | /* etraxgpio _IOC_TYPE, bits 8 to 15 in ioctl cmd */ |
30 | #ifdef CONFIG_ETRAX_ARCH_V10 | 29 | #ifdef CONFIG_ETRAX_ARCH_V10 |
31 | #define ETRAXGPIO_IOCTYPE 43 | 30 | #define ETRAXGPIO_IOCTYPE 43 |
diff --git a/include/asm-cris/fasttimer.h b/include/asm-cris/fasttimer.h index 69522028baa5..a3a77132ce32 100644 --- a/include/asm-cris/fasttimer.h +++ b/include/asm-cris/fasttimer.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * This may be useful in other OS than Linux so use 2 space indentation... | 5 | * This may be useful in other OS than Linux so use 2 space indentation... |
6 | * Copyright (C) 2000, 2002 Axis Communications AB | 6 | * Copyright (C) 2000, 2002 Axis Communications AB |
7 | */ | 7 | */ |
8 | #include <linux/config.h> | ||
9 | #include <linux/time.h> /* struct timeval */ | 8 | #include <linux/time.h> /* struct timeval */ |
10 | #include <linux/timex.h> | 9 | #include <linux/timex.h> |
11 | 10 | ||
diff --git a/include/asm-cris/page.h b/include/asm-cris/page.h index 3787633e6209..81832e9e157f 100644 --- a/include/asm-cris/page.h +++ b/include/asm-cris/page.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _CRIS_PAGE_H | 1 | #ifndef _CRIS_PAGE_H |
2 | #define _CRIS_PAGE_H | 2 | #define _CRIS_PAGE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/arch/page.h> | 4 | #include <asm/arch/page.h> |
6 | 5 | ||
7 | /* PAGE_SHIFT determines the page size */ | 6 | /* PAGE_SHIFT determines the page size */ |
diff --git a/include/asm-cris/pci.h b/include/asm-cris/pci.h index 2064bc1de074..b2ac8a331da1 100644 --- a/include/asm-cris/pci.h +++ b/include/asm-cris/pci.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_CRIS_PCI_H | 1 | #ifndef __ASM_CRIS_PCI_H |
2 | #define __ASM_CRIS_PCI_H | 2 | #define __ASM_CRIS_PCI_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef __KERNEL__ | 5 | #ifdef __KERNEL__ |
7 | #include <linux/mm.h> /* for struct page */ | 6 | #include <linux/mm.h> /* for struct page */ |
diff --git a/include/asm-cris/pgtable.h b/include/asm-cris/pgtable.h index 70a832514f62..5d76c1c0d6c9 100644 --- a/include/asm-cris/pgtable.h +++ b/include/asm-cris/pgtable.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #include <asm-generic/pgtable-nopmd.h> | 9 | #include <asm-generic/pgtable-nopmd.h> |
10 | 10 | ||
11 | #ifndef __ASSEMBLY__ | 11 | #ifndef __ASSEMBLY__ |
12 | #include <linux/config.h> | ||
13 | #include <linux/sched.h> | 12 | #include <linux/sched.h> |
14 | #include <asm/mmu.h> | 13 | #include <asm/mmu.h> |
15 | #endif | 14 | #endif |
diff --git a/include/asm-cris/processor.h b/include/asm-cris/processor.h index 961e2bceadbc..568da1deceb9 100644 --- a/include/asm-cris/processor.h +++ b/include/asm-cris/processor.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef __ASM_CRIS_PROCESSOR_H | 10 | #ifndef __ASM_CRIS_PROCESSOR_H |
11 | #define __ASM_CRIS_PROCESSOR_H | 11 | #define __ASM_CRIS_PROCESSOR_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <asm/system.h> | 13 | #include <asm/system.h> |
15 | #include <asm/page.h> | 14 | #include <asm/page.h> |
16 | #include <asm/ptrace.h> | 15 | #include <asm/ptrace.h> |
diff --git a/include/asm-cris/rtc.h b/include/asm-cris/rtc.h index 97c13039834a..cb4bf9217fee 100644 --- a/include/asm-cris/rtc.h +++ b/include/asm-cris/rtc.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #define __RTC_H__ | 4 | #define __RTC_H__ |
5 | 5 | ||
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | #ifdef CONFIG_ETRAX_DS1302 | 8 | #ifdef CONFIG_ETRAX_DS1302 |
10 | /* Dallas DS1302 clock/calendar register numbers. */ | 9 | /* Dallas DS1302 clock/calendar register numbers. */ |
diff --git a/include/asm-cris/tlbflush.h b/include/asm-cris/tlbflush.h index c52238005b55..0569612477e3 100644 --- a/include/asm-cris/tlbflush.h +++ b/include/asm-cris/tlbflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _CRIS_TLBFLUSH_H | 1 | #ifndef _CRIS_TLBFLUSH_H |
2 | #define _CRIS_TLBFLUSH_H | 2 | #define _CRIS_TLBFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | #include <asm/processor.h> | 5 | #include <asm/processor.h> |
7 | #include <asm/pgtable.h> | 6 | #include <asm/pgtable.h> |
diff --git a/include/asm-cris/unistd.h b/include/asm-cris/unistd.h index bb2dfe480213..c2954e90aa24 100644 --- a/include/asm-cris/unistd.h +++ b/include/asm-cris/unistd.h | |||
@@ -295,11 +295,11 @@ | |||
295 | #define __NR_request_key 287 | 295 | #define __NR_request_key 287 |
296 | #define __NR_keyctl 288 | 296 | #define __NR_keyctl 288 |
297 | 297 | ||
298 | #define NR_syscalls 289 | 298 | #ifdef __KERNEL__ |
299 | 299 | ||
300 | #define NR_syscalls 289 | ||
300 | 301 | ||
301 | 302 | ||
302 | #ifdef __KERNEL__ | ||
303 | #define __ARCH_WANT_IPC_PARSE_VERSION | 303 | #define __ARCH_WANT_IPC_PARSE_VERSION |
304 | #define __ARCH_WANT_OLD_READDIR | 304 | #define __ARCH_WANT_OLD_READDIR |
305 | #define __ARCH_WANT_OLD_STAT | 305 | #define __ARCH_WANT_OLD_STAT |
@@ -379,12 +379,10 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
379 | * complaints. We don't want to use -fno-builtin, so just use a | 379 | * complaints. We don't want to use -fno-builtin, so just use a |
380 | * different name when in the kernel. | 380 | * different name when in the kernel. |
381 | */ | 381 | */ |
382 | #ifdef __KERNEL__ | ||
383 | #define _exit kernel_syscall_exit | 382 | #define _exit kernel_syscall_exit |
384 | #endif | ||
385 | static inline _syscall1(int,_exit,int,exitcode) | 383 | static inline _syscall1(int,_exit,int,exitcode) |
386 | static inline _syscall3(pid_t,waitpid,pid_t,pid,int *,wait_stat,int,options) | 384 | static inline _syscall3(pid_t,waitpid,pid_t,pid,int *,wait_stat,int,options) |
387 | #endif | 385 | #endif /* __KERNEL_SYSCALLS__ */ |
388 | 386 | ||
389 | 387 | ||
390 | /* | 388 | /* |
@@ -395,4 +393,5 @@ static inline _syscall3(pid_t,waitpid,pid_t,pid,int *,wait_stat,int,options) | |||
395 | */ | 393 | */ |
396 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 394 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
397 | 395 | ||
396 | #endif /* __KERNEL__ */ | ||
398 | #endif /* _ASM_CRIS_UNISTD_H_ */ | 397 | #endif /* _ASM_CRIS_UNISTD_H_ */ |
diff --git a/include/asm-frv/atomic.h b/include/asm-frv/atomic.h index 5d9f84bfdcad..9a4ff03c3969 100644 --- a/include/asm-frv/atomic.h +++ b/include/asm-frv/atomic.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #ifndef _ASM_ATOMIC_H | 14 | #ifndef _ASM_ATOMIC_H |
15 | #define _ASM_ATOMIC_H | 15 | #define _ASM_ATOMIC_H |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | #include <linux/types.h> | 17 | #include <linux/types.h> |
19 | #include <asm/spr-regs.h> | 18 | #include <asm/spr-regs.h> |
20 | 19 | ||
diff --git a/include/asm-frv/bitops.h b/include/asm-frv/bitops.h index 6344d06390b9..980ae1b0cd28 100644 --- a/include/asm-frv/bitops.h +++ b/include/asm-frv/bitops.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #ifndef _ASM_BITOPS_H | 14 | #ifndef _ASM_BITOPS_H |
15 | #define _ASM_BITOPS_H | 15 | #define _ASM_BITOPS_H |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | #include <linux/compiler.h> | 17 | #include <linux/compiler.h> |
19 | #include <asm/byteorder.h> | 18 | #include <asm/byteorder.h> |
20 | #include <asm/system.h> | 19 | #include <asm/system.h> |
diff --git a/include/asm-frv/bug.h b/include/asm-frv/bug.h index 451712cc3060..6b1b44d71028 100644 --- a/include/asm-frv/bug.h +++ b/include/asm-frv/bug.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_BUG_H | 11 | #ifndef _ASM_BUG_H |
12 | #define _ASM_BUG_H | 12 | #define _ASM_BUG_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/linkage.h> | 14 | #include <linux/linkage.h> |
16 | 15 | ||
17 | #ifdef CONFIG_BUG | 16 | #ifdef CONFIG_BUG |
diff --git a/include/asm-frv/cache.h b/include/asm-frv/cache.h index cf69b6373b34..2797163b8f4f 100644 --- a/include/asm-frv/cache.h +++ b/include/asm-frv/cache.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef __ASM_CACHE_H | 12 | #ifndef __ASM_CACHE_H |
13 | #define __ASM_CACHE_H | 13 | #define __ASM_CACHE_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | /* bytes per L1 cache line */ | 16 | /* bytes per L1 cache line */ |
18 | #define L1_CACHE_SHIFT (CONFIG_FRV_L1_CACHE_SHIFT) | 17 | #define L1_CACHE_SHIFT (CONFIG_FRV_L1_CACHE_SHIFT) |
diff --git a/include/asm-frv/dma.h b/include/asm-frv/dma.h index d8f9a2f21521..18d6bb8f84fc 100644 --- a/include/asm-frv/dma.h +++ b/include/asm-frv/dma.h | |||
@@ -14,7 +14,6 @@ | |||
14 | 14 | ||
15 | //#define DMA_DEBUG 1 | 15 | //#define DMA_DEBUG 1 |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | #include <linux/interrupt.h> | 17 | #include <linux/interrupt.h> |
19 | 18 | ||
20 | #undef MAX_DMA_CHANNELS /* don't use kernel/dma.c */ | 19 | #undef MAX_DMA_CHANNELS /* don't use kernel/dma.c */ |
diff --git a/include/asm-frv/elf.h b/include/asm-frv/elf.h index 7d2098f0476b..38656da00e40 100644 --- a/include/asm-frv/elf.h +++ b/include/asm-frv/elf.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef __ASM_ELF_H | 12 | #ifndef __ASM_ELF_H |
13 | #define __ASM_ELF_H | 13 | #define __ASM_ELF_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <asm/ptrace.h> | 15 | #include <asm/ptrace.h> |
17 | #include <asm/user.h> | 16 | #include <asm/user.h> |
18 | 17 | ||
diff --git a/include/asm-frv/fpu.h b/include/asm-frv/fpu.h index b1178f8ca5ce..d73c60b56641 100644 --- a/include/asm-frv/fpu.h +++ b/include/asm-frv/fpu.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_FPU_H | 1 | #ifndef __ASM_FPU_H |
2 | #define __ASM_FPU_H | 2 | #define __ASM_FPU_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * MAX floating point unit state size (FSAVE/FRESTORE) | 6 | * MAX floating point unit state size (FSAVE/FRESTORE) |
diff --git a/include/asm-frv/hardirq.h b/include/asm-frv/hardirq.h index 685123981e8b..7581b5a7559a 100644 --- a/include/asm-frv/hardirq.h +++ b/include/asm-frv/hardirq.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef __ASM_HARDIRQ_H | 12 | #ifndef __ASM_HARDIRQ_H |
13 | #define __ASM_HARDIRQ_H | 13 | #define __ASM_HARDIRQ_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <linux/threads.h> | 15 | #include <linux/threads.h> |
17 | #include <linux/irq.h> | 16 | #include <linux/irq.h> |
18 | 17 | ||
diff --git a/include/asm-frv/highmem.h b/include/asm-frv/highmem.h index 295f74a57f22..cfbf7d3a1feb 100644 --- a/include/asm-frv/highmem.h +++ b/include/asm-frv/highmem.h | |||
@@ -17,7 +17,6 @@ | |||
17 | 17 | ||
18 | #ifdef __KERNEL__ | 18 | #ifdef __KERNEL__ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <linux/init.h> | 20 | #include <linux/init.h> |
22 | #include <asm/mem-layout.h> | 21 | #include <asm/mem-layout.h> |
23 | #include <asm/spr-regs.h> | 22 | #include <asm/spr-regs.h> |
diff --git a/include/asm-frv/ide.h b/include/asm-frv/ide.h index ae031eaa3dd2..f0bd2cb250c1 100644 --- a/include/asm-frv/ide.h +++ b/include/asm-frv/ide.h | |||
@@ -14,7 +14,6 @@ | |||
14 | 14 | ||
15 | #ifdef __KERNEL__ | 15 | #ifdef __KERNEL__ |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | #include <asm/setup.h> | 17 | #include <asm/setup.h> |
19 | #include <asm/io.h> | 18 | #include <asm/io.h> |
20 | #include <asm/irq.h> | 19 | #include <asm/irq.h> |
diff --git a/include/asm-frv/io.h b/include/asm-frv/io.h index 01247cb2bc39..b56eba59e3cd 100644 --- a/include/asm-frv/io.h +++ b/include/asm-frv/io.h | |||
@@ -17,7 +17,6 @@ | |||
17 | 17 | ||
18 | #ifdef __KERNEL__ | 18 | #ifdef __KERNEL__ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <linux/types.h> | 20 | #include <linux/types.h> |
22 | #include <asm/virtconvert.h> | 21 | #include <asm/virtconvert.h> |
23 | #include <asm/string.h> | 22 | #include <asm/string.h> |
diff --git a/include/asm-frv/irq.h b/include/asm-frv/irq.h index 2c16d8dc02fd..58b619215a50 100644 --- a/include/asm-frv/irq.h +++ b/include/asm-frv/irq.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef _ASM_IRQ_H_ | 12 | #ifndef _ASM_IRQ_H_ |
13 | #define _ASM_IRQ_H_ | 13 | #define _ASM_IRQ_H_ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | /* | 16 | /* |
18 | * the system has an on-CPU PIC and another PIC on the FPGA and other PICs on other peripherals, | 17 | * the system has an on-CPU PIC and another PIC on the FPGA and other PICs on other peripherals, |
diff --git a/include/asm-frv/mmu_context.h b/include/asm-frv/mmu_context.h index 4fb9ea3c5bc9..72edcaaccd5d 100644 --- a/include/asm-frv/mmu_context.h +++ b/include/asm-frv/mmu_context.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef _ASM_MMU_CONTEXT_H | 12 | #ifndef _ASM_MMU_CONTEXT_H |
13 | #define _ASM_MMU_CONTEXT_H | 13 | #define _ASM_MMU_CONTEXT_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <asm/setup.h> | 15 | #include <asm/setup.h> |
17 | #include <asm/page.h> | 16 | #include <asm/page.h> |
18 | #include <asm/pgalloc.h> | 17 | #include <asm/pgalloc.h> |
diff --git a/include/asm-frv/page.h b/include/asm-frv/page.h index dc0f7e08a4c2..134cc0cdf6c2 100644 --- a/include/asm-frv/page.h +++ b/include/asm-frv/page.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <asm/virtconvert.h> | 6 | #include <asm/virtconvert.h> |
8 | #include <asm/mem-layout.h> | 7 | #include <asm/mem-layout.h> |
9 | #include <asm/sections.h> | 8 | #include <asm/sections.h> |
diff --git a/include/asm-frv/pci.h b/include/asm-frv/pci.h index 598b0c6b695d..f35a4511e7b9 100644 --- a/include/asm-frv/pci.h +++ b/include/asm-frv/pci.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef ASM_PCI_H | 13 | #ifndef ASM_PCI_H |
14 | #define ASM_PCI_H | 14 | #define ASM_PCI_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/mm.h> | 16 | #include <linux/mm.h> |
18 | #include <asm/scatterlist.h> | 17 | #include <asm/scatterlist.h> |
19 | #include <asm-generic/pci-dma-compat.h> | 18 | #include <asm-generic/pci-dma-compat.h> |
diff --git a/include/asm-frv/pgalloc.h b/include/asm-frv/pgalloc.h index 1bd28f41bfa8..ce982a6c610f 100644 --- a/include/asm-frv/pgalloc.h +++ b/include/asm-frv/pgalloc.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #ifndef _ASM_PGALLOC_H | 15 | #ifndef _ASM_PGALLOC_H |
16 | #define _ASM_PGALLOC_H | 16 | #define _ASM_PGALLOC_H |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | #include <asm/setup.h> | 18 | #include <asm/setup.h> |
20 | #include <asm/virtconvert.h> | 19 | #include <asm/virtconvert.h> |
21 | 20 | ||
diff --git a/include/asm-frv/pgtable.h b/include/asm-frv/pgtable.h index d1c3b182c691..7af7485e889e 100644 --- a/include/asm-frv/pgtable.h +++ b/include/asm-frv/pgtable.h | |||
@@ -16,7 +16,6 @@ | |||
16 | #ifndef _ASM_PGTABLE_H | 16 | #ifndef _ASM_PGTABLE_H |
17 | #define _ASM_PGTABLE_H | 17 | #define _ASM_PGTABLE_H |
18 | 18 | ||
19 | #include <linux/config.h> | ||
20 | #include <asm/mem-layout.h> | 19 | #include <asm/mem-layout.h> |
21 | #include <asm/setup.h> | 20 | #include <asm/setup.h> |
22 | #include <asm/processor.h> | 21 | #include <asm/processor.h> |
diff --git a/include/asm-frv/processor.h b/include/asm-frv/processor.h index 5228c18b7f78..1c4dba1c5f57 100644 --- a/include/asm-frv/processor.h +++ b/include/asm-frv/processor.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef _ASM_PROCESSOR_H | 12 | #ifndef _ASM_PROCESSOR_H |
13 | #define _ASM_PROCESSOR_H | 13 | #define _ASM_PROCESSOR_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <asm/mem-layout.h> | 15 | #include <asm/mem-layout.h> |
17 | 16 | ||
18 | #ifndef __ASSEMBLY__ | 17 | #ifndef __ASSEMBLY__ |
diff --git a/include/asm-frv/segment.h b/include/asm-frv/segment.h index 61222f00dfc1..e3616a6f941d 100644 --- a/include/asm-frv/segment.h +++ b/include/asm-frv/segment.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef _ASM_SEGMENT_H | 12 | #ifndef _ASM_SEGMENT_H |
13 | #define _ASM_SEGMENT_H | 13 | #define _ASM_SEGMENT_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | #ifndef __ASSEMBLY__ | 16 | #ifndef __ASSEMBLY__ |
18 | 17 | ||
diff --git a/include/asm-frv/serial.h b/include/asm-frv/serial.h index 6917d556a1e1..dbb825998689 100644 --- a/include/asm-frv/serial.h +++ b/include/asm-frv/serial.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * | 6 | * |
7 | * Based on linux/include/asm-i386/serial.h | 7 | * Based on linux/include/asm-i386/serial.h |
8 | */ | 8 | */ |
9 | #include <linux/config.h> | ||
10 | #include <asm/serial-regs.h> | 9 | #include <asm/serial-regs.h> |
11 | 10 | ||
12 | /* | 11 | /* |
diff --git a/include/asm-frv/smp.h b/include/asm-frv/smp.h index 5ca771631fd8..38349ec8b61b 100644 --- a/include/asm-frv/smp.h +++ b/include/asm-frv/smp.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_SMP_H | 1 | #ifndef __ASM_SMP_H |
2 | #define __ASM_SMP_H | 2 | #define __ASM_SMP_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_SMP | 5 | #ifdef CONFIG_SMP |
7 | #error SMP not supported | 6 | #error SMP not supported |
diff --git a/include/asm-frv/system.h b/include/asm-frv/system.h index 1734ed91bcdc..351863dfd06e 100644 --- a/include/asm-frv/system.h +++ b/include/asm-frv/system.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef _ASM_SYSTEM_H | 12 | #ifndef _ASM_SYSTEM_H |
13 | #define _ASM_SYSTEM_H | 13 | #define _ASM_SYSTEM_H |
14 | 14 | ||
15 | #include <linux/config.h> /* get configuration macros */ | ||
16 | #include <linux/linkage.h> | 15 | #include <linux/linkage.h> |
17 | #include <asm/atomic.h> | 16 | #include <asm/atomic.h> |
18 | 17 | ||
diff --git a/include/asm-frv/tlbflush.h b/include/asm-frv/tlbflush.h index bc3462625084..da3a3179a85d 100644 --- a/include/asm-frv/tlbflush.h +++ b/include/asm-frv/tlbflush.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef _ASM_TLBFLUSH_H | 12 | #ifndef _ASM_TLBFLUSH_H |
13 | #define _ASM_TLBFLUSH_H | 13 | #define _ASM_TLBFLUSH_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <linux/mm.h> | 15 | #include <linux/mm.h> |
17 | #include <asm/processor.h> | 16 | #include <asm/processor.h> |
18 | 17 | ||
diff --git a/include/asm-frv/types.h b/include/asm-frv/types.h index 2560f596a75d..1b6d1923b25b 100644 --- a/include/asm-frv/types.h +++ b/include/asm-frv/types.h | |||
@@ -46,7 +46,6 @@ typedef unsigned long long __u64; | |||
46 | 46 | ||
47 | #ifndef __ASSEMBLY__ | 47 | #ifndef __ASSEMBLY__ |
48 | 48 | ||
49 | #include <linux/config.h> | ||
50 | 49 | ||
51 | typedef signed char s8; | 50 | typedef signed char s8; |
52 | typedef unsigned char u8; | 51 | typedef unsigned char u8; |
diff --git a/include/asm-frv/unaligned.h b/include/asm-frv/unaligned.h index a0d199bf01d9..dc8e9c9bf6bd 100644 --- a/include/asm-frv/unaligned.h +++ b/include/asm-frv/unaligned.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef _ASM_UNALIGNED_H | 12 | #ifndef _ASM_UNALIGNED_H |
13 | #define _ASM_UNALIGNED_H | 13 | #define _ASM_UNALIGNED_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | /* | 16 | /* |
18 | * Unaligned accesses on uClinux can't be performed in a fault handler - the | 17 | * Unaligned accesses on uClinux can't be performed in a fault handler - the |
diff --git a/include/asm-frv/unistd.h b/include/asm-frv/unistd.h index 2662a3e12dc4..7c2e712c3b73 100644 --- a/include/asm-frv/unistd.h +++ b/include/asm-frv/unistd.h | |||
@@ -317,6 +317,8 @@ | |||
317 | #define __NR_pselect6 308 | 317 | #define __NR_pselect6 308 |
318 | #define __NR_ppoll 309 | 318 | #define __NR_ppoll 309 |
319 | 319 | ||
320 | #ifdef __KERNEL__ | ||
321 | |||
320 | #define NR_syscalls 310 | 322 | #define NR_syscalls 310 |
321 | 323 | ||
322 | /* | 324 | /* |
@@ -477,9 +479,8 @@ static inline pid_t wait(int * wait_stat) | |||
477 | return waitpid(-1,wait_stat,0); | 479 | return waitpid(-1,wait_stat,0); |
478 | } | 480 | } |
479 | 481 | ||
480 | #endif | 482 | #endif /* __KERNEL_SYSCALLS__ */ |
481 | 483 | ||
482 | #ifdef __KERNEL__ | ||
483 | #define __ARCH_WANT_IPC_PARSE_VERSION | 484 | #define __ARCH_WANT_IPC_PARSE_VERSION |
484 | /* #define __ARCH_WANT_OLD_READDIR */ | 485 | /* #define __ARCH_WANT_OLD_READDIR */ |
485 | #define __ARCH_WANT_OLD_STAT | 486 | #define __ARCH_WANT_OLD_STAT |
@@ -503,7 +504,6 @@ static inline pid_t wait(int * wait_stat) | |||
503 | #define __ARCH_WANT_SYS_SIGPROCMASK | 504 | #define __ARCH_WANT_SYS_SIGPROCMASK |
504 | #define __ARCH_WANT_SYS_RT_SIGACTION | 505 | #define __ARCH_WANT_SYS_RT_SIGACTION |
505 | #define __ARCH_WANT_SYS_RT_SIGSUSPEND | 506 | #define __ARCH_WANT_SYS_RT_SIGSUSPEND |
506 | #endif | ||
507 | 507 | ||
508 | /* | 508 | /* |
509 | * "Conditional" syscalls | 509 | * "Conditional" syscalls |
@@ -515,4 +515,5 @@ static inline pid_t wait(int * wait_stat) | |||
515 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 515 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
516 | #endif | 516 | #endif |
517 | 517 | ||
518 | #endif /* __KERNEL__ */ | ||
518 | #endif /* _ASM_UNISTD_H_ */ | 519 | #endif /* _ASM_UNISTD_H_ */ |
diff --git a/include/asm-frv/virtconvert.h b/include/asm-frv/virtconvert.h index a29a0aec291f..59788fa2a813 100644 --- a/include/asm-frv/virtconvert.h +++ b/include/asm-frv/virtconvert.h | |||
@@ -17,7 +17,6 @@ | |||
17 | 17 | ||
18 | #ifdef __KERNEL__ | 18 | #ifdef __KERNEL__ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <asm/setup.h> | 20 | #include <asm/setup.h> |
22 | 21 | ||
23 | #ifdef CONFIG_MMU | 22 | #ifdef CONFIG_MMU |
diff --git a/include/asm-generic/bug.h b/include/asm-generic/bug.h index 1a565a9d2fa7..0cd9711895fa 100644 --- a/include/asm-generic/bug.h +++ b/include/asm-generic/bug.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define _ASM_GENERIC_BUG_H | 2 | #define _ASM_GENERIC_BUG_H |
3 | 3 | ||
4 | #include <linux/compiler.h> | 4 | #include <linux/compiler.h> |
5 | #include <linux/config.h> | ||
6 | 5 | ||
7 | #ifdef CONFIG_BUG | 6 | #ifdef CONFIG_BUG |
8 | #ifndef HAVE_ARCH_BUG | 7 | #ifndef HAVE_ARCH_BUG |
diff --git a/include/asm-generic/dma-mapping.h b/include/asm-generic/dma-mapping.h index 1b356207712c..b541e48cc545 100644 --- a/include/asm-generic/dma-mapping.h +++ b/include/asm-generic/dma-mapping.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef _ASM_GENERIC_DMA_MAPPING_H | 7 | #ifndef _ASM_GENERIC_DMA_MAPPING_H |
8 | #define _ASM_GENERIC_DMA_MAPPING_H | 8 | #define _ASM_GENERIC_DMA_MAPPING_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | 10 | ||
12 | #ifdef CONFIG_PCI | 11 | #ifdef CONFIG_PCI |
13 | 12 | ||
diff --git a/include/asm-generic/fcntl.h b/include/asm-generic/fcntl.h index b663520dcdc4..c154b9d6e7e5 100644 --- a/include/asm-generic/fcntl.h +++ b/include/asm-generic/fcntl.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_GENERIC_FCNTL_H | 1 | #ifndef _ASM_GENERIC_FCNTL_H |
2 | #define _ASM_GENERIC_FCNTL_H | 2 | #define _ASM_GENERIC_FCNTL_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/types.h> | 4 | #include <linux/types.h> |
6 | 5 | ||
7 | /* open/fcntl - O_SYNC is only implemented on blocks devices and on files | 6 | /* open/fcntl - O_SYNC is only implemented on blocks devices and on files |
diff --git a/include/asm-generic/local.h b/include/asm-generic/local.h index 9291c24f5819..ab469297272c 100644 --- a/include/asm-generic/local.h +++ b/include/asm-generic/local.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_GENERIC_LOCAL_H | 1 | #ifndef _ASM_GENERIC_LOCAL_H |
2 | #define _ASM_GENERIC_LOCAL_H | 2 | #define _ASM_GENERIC_LOCAL_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/percpu.h> | 4 | #include <linux/percpu.h> |
6 | #include <linux/hardirq.h> | 5 | #include <linux/hardirq.h> |
7 | #include <asm/atomic.h> | 6 | #include <asm/atomic.h> |
diff --git a/include/asm-generic/signal.h b/include/asm-generic/signal.h index 9418d6e9b8cd..dae1d8720076 100644 --- a/include/asm-generic/signal.h +++ b/include/asm-generic/signal.h | |||
@@ -1,3 +1,8 @@ | |||
1 | #ifndef __ASM_GENERIC_SIGNAL_H | ||
2 | #define __ASM_GENERIC_SIGNAL_H | ||
3 | |||
4 | #include <linux/compiler.h> | ||
5 | |||
1 | #ifndef SIG_BLOCK | 6 | #ifndef SIG_BLOCK |
2 | #define SIG_BLOCK 0 /* for blocking signals */ | 7 | #define SIG_BLOCK 0 /* for blocking signals */ |
3 | #endif | 8 | #endif |
@@ -19,3 +24,5 @@ typedef __restorefn_t __user *__sigrestore_t; | |||
19 | #define SIG_IGN ((__force __sighandler_t)1) /* ignore signal */ | 24 | #define SIG_IGN ((__force __sighandler_t)1) /* ignore signal */ |
20 | #define SIG_ERR ((__force __sighandler_t)-1) /* error return from signal */ | 25 | #define SIG_ERR ((__force __sighandler_t)-1) /* error return from signal */ |
21 | #endif | 26 | #endif |
27 | |||
28 | #endif /* __ASM_GENERIC_SIGNAL_H */ | ||
diff --git a/include/asm-generic/tlb.h b/include/asm-generic/tlb.h index cdd4145243cd..867d9008fafa 100644 --- a/include/asm-generic/tlb.h +++ b/include/asm-generic/tlb.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef _ASM_GENERIC__TLB_H | 13 | #ifndef _ASM_GENERIC__TLB_H |
14 | #define _ASM_GENERIC__TLB_H | 14 | #define _ASM_GENERIC__TLB_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/swap.h> | 16 | #include <linux/swap.h> |
18 | #include <asm/pgalloc.h> | 17 | #include <asm/pgalloc.h> |
19 | #include <asm/tlbflush.h> | 18 | #include <asm/tlbflush.h> |
diff --git a/include/asm-h8300/bitops.h b/include/asm-h8300/bitops.h index 574f57b6c4d1..d76299c98b81 100644 --- a/include/asm-h8300/bitops.h +++ b/include/asm-h8300/bitops.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * Copyright 2002, Yoshinori Sato | 6 | * Copyright 2002, Yoshinori Sato |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <linux/compiler.h> | 9 | #include <linux/compiler.h> |
11 | #include <asm/system.h> | 10 | #include <asm/system.h> |
12 | 11 | ||
diff --git a/include/asm-h8300/dma.h b/include/asm-h8300/dma.h index 3708681b7ddc..3edbaaaedf5b 100644 --- a/include/asm-h8300/dma.h +++ b/include/asm-h8300/dma.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _H8300_DMA_H | 1 | #ifndef _H8300_DMA_H |
2 | #define _H8300_DMA_H | 2 | #define _H8300_DMA_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * Set number of channels of DMA on ColdFire for different implementations. | 6 | * Set number of channels of DMA on ColdFire for different implementations. |
diff --git a/include/asm-h8300/elf.h b/include/asm-h8300/elf.h index f4af1553a55f..7ba6a0af447c 100644 --- a/include/asm-h8300/elf.h +++ b/include/asm-h8300/elf.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * ELF register definitions.. | 5 | * ELF register definitions.. |
6 | */ | 6 | */ |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | #include <asm/ptrace.h> | 8 | #include <asm/ptrace.h> |
10 | #include <asm/user.h> | 9 | #include <asm/user.h> |
11 | 10 | ||
diff --git a/include/asm-h8300/hardirq.h b/include/asm-h8300/hardirq.h index e961bfe201b8..18fa7931e09f 100644 --- a/include/asm-h8300/hardirq.h +++ b/include/asm-h8300/hardirq.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define __H8300_HARDIRQ_H | 2 | #define __H8300_HARDIRQ_H |
3 | 3 | ||
4 | #include <linux/kernel.h> | 4 | #include <linux/kernel.h> |
5 | #include <linux/config.h> | ||
6 | #include <linux/threads.h> | 5 | #include <linux/threads.h> |
7 | #include <linux/interrupt.h> | 6 | #include <linux/interrupt.h> |
8 | #include <linux/irq.h> | 7 | #include <linux/irq.h> |
diff --git a/include/asm-h8300/io.h b/include/asm-h8300/io.h index 1773e373e9c6..91b7487cb7ae 100644 --- a/include/asm-h8300/io.h +++ b/include/asm-h8300/io.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <asm/virtconvert.h> | 6 | #include <asm/virtconvert.h> |
8 | 7 | ||
9 | #if defined(CONFIG_H83007) || defined(CONFIG_H83068) | 8 | #if defined(CONFIG_H83007) || defined(CONFIG_H83068) |
diff --git a/include/asm-h8300/keyboard.h b/include/asm-h8300/keyboard.h index b05d11387ae5..fbad65e8a5c0 100644 --- a/include/asm-h8300/keyboard.h +++ b/include/asm-h8300/keyboard.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef _H8300_KEYBOARD_H | 7 | #ifndef _H8300_KEYBOARD_H |
8 | #define _H8300_KEYBOARD_H | 8 | #define _H8300_KEYBOARD_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | 10 | ||
12 | /* dummy i.e. no real keyboard */ | 11 | /* dummy i.e. no real keyboard */ |
13 | #define kbd_setkeycode(x...) (-ENOSYS) | 12 | #define kbd_setkeycode(x...) (-ENOSYS) |
diff --git a/include/asm-h8300/mmu_context.h b/include/asm-h8300/mmu_context.h index 23b555b7b4b9..855721a5dcc9 100644 --- a/include/asm-h8300/mmu_context.h +++ b/include/asm-h8300/mmu_context.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __H8300_MMU_CONTEXT_H | 1 | #ifndef __H8300_MMU_CONTEXT_H |
2 | #define __H8300_MMU_CONTEXT_H | 2 | #define __H8300_MMU_CONTEXT_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/setup.h> | 4 | #include <asm/setup.h> |
6 | #include <asm/page.h> | 5 | #include <asm/page.h> |
7 | #include <asm/pgalloc.h> | 6 | #include <asm/pgalloc.h> |
diff --git a/include/asm-h8300/page.h b/include/asm-h8300/page.h index 6472c9f88227..f9f9d3eea8ed 100644 --- a/include/asm-h8300/page.h +++ b/include/asm-h8300/page.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _H8300_PAGE_H | 1 | #ifndef _H8300_PAGE_H |
2 | #define _H8300_PAGE_H | 2 | #define _H8300_PAGE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* PAGE_SHIFT determines the page size */ | 5 | /* PAGE_SHIFT determines the page size */ |
7 | 6 | ||
diff --git a/include/asm-h8300/page_offset.h b/include/asm-h8300/page_offset.h index 8cc6e17218a8..f8706463008c 100644 --- a/include/asm-h8300/page_offset.h +++ b/include/asm-h8300/page_offset.h | |||
@@ -1,4 +1,3 @@ | |||
1 | 1 | ||
2 | #include <linux/config.h> | ||
3 | #define PAGE_OFFSET_RAW 0x00000000 | 2 | #define PAGE_OFFSET_RAW 0x00000000 |
4 | 3 | ||
diff --git a/include/asm-h8300/param.h b/include/asm-h8300/param.h index 126dddf72359..c25806ed1fb3 100644 --- a/include/asm-h8300/param.h +++ b/include/asm-h8300/param.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _H8300_PARAM_H | 1 | #ifndef _H8300_PARAM_H |
2 | #define _H8300_PARAM_H | 2 | #define _H8300_PARAM_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifndef HZ | 5 | #ifndef HZ |
7 | #define HZ 100 | 6 | #define HZ 100 |
diff --git a/include/asm-h8300/pgtable.h b/include/asm-h8300/pgtable.h index f6e296fc1297..8b7c6857998b 100644 --- a/include/asm-h8300/pgtable.h +++ b/include/asm-h8300/pgtable.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #include <asm-generic/4level-fixup.h> | 4 | #include <asm-generic/4level-fixup.h> |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <linux/slab.h> | 6 | #include <linux/slab.h> |
8 | #include <asm/processor.h> | 7 | #include <asm/processor.h> |
9 | #include <asm/page.h> | 8 | #include <asm/page.h> |
diff --git a/include/asm-h8300/processor.h b/include/asm-h8300/processor.h index c6f0a7108ef3..c7e2f454b83a 100644 --- a/include/asm-h8300/processor.h +++ b/include/asm-h8300/processor.h | |||
@@ -17,7 +17,6 @@ | |||
17 | */ | 17 | */ |
18 | #define current_text_addr() ({ __label__ _l; _l: &&_l;}) | 18 | #define current_text_addr() ({ __label__ _l; _l: &&_l;}) |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <asm/segment.h> | 20 | #include <asm/segment.h> |
22 | #include <asm/fpu.h> | 21 | #include <asm/fpu.h> |
23 | #include <asm/ptrace.h> | 22 | #include <asm/ptrace.h> |
diff --git a/include/asm-h8300/semaphore-helper.h b/include/asm-h8300/semaphore-helper.h index 29e0fbf1acb7..4fea36be5fd8 100644 --- a/include/asm-h8300/semaphore-helper.h +++ b/include/asm-h8300/semaphore-helper.h | |||
@@ -10,7 +10,6 @@ | |||
10 | * m68k version by Andreas Schwab | 10 | * m68k version by Andreas Schwab |
11 | */ | 11 | */ |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/errno.h> | 13 | #include <linux/errno.h> |
15 | 14 | ||
16 | /* | 15 | /* |
diff --git a/include/asm-h8300/shm.h b/include/asm-h8300/shm.h index bec758524839..ed6623c0545d 100644 --- a/include/asm-h8300/shm.h +++ b/include/asm-h8300/shm.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _H8300_SHM_H | 1 | #ifndef _H8300_SHM_H |
2 | #define _H8300_SHM_H | 2 | #define _H8300_SHM_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* format of page table entries that correspond to shared memory pages | 5 | /* format of page table entries that correspond to shared memory pages |
7 | currently out in swap space (see also mm/swap.c): | 6 | currently out in swap space (see also mm/swap.c): |
diff --git a/include/asm-h8300/system.h b/include/asm-h8300/system.h index 8e81cf665e75..134e0929fce5 100644 --- a/include/asm-h8300/system.h +++ b/include/asm-h8300/system.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _H8300_SYSTEM_H | 1 | #ifndef _H8300_SYSTEM_H |
2 | #define _H8300_SYSTEM_H | 2 | #define _H8300_SYSTEM_H |
3 | 3 | ||
4 | #include <linux/config.h> /* get configuration macros */ | ||
5 | #include <linux/linkage.h> | 4 | #include <linux/linkage.h> |
6 | 5 | ||
7 | /* | 6 | /* |
diff --git a/include/asm-h8300/unaligned.h b/include/asm-h8300/unaligned.h index 8a93961173c3..ffb67f472070 100644 --- a/include/asm-h8300/unaligned.h +++ b/include/asm-h8300/unaligned.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __H8300_UNALIGNED_H | 1 | #ifndef __H8300_UNALIGNED_H |
2 | #define __H8300_UNALIGNED_H | 2 | #define __H8300_UNALIGNED_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* Use memmove here, so gcc does not insert a __builtin_memcpy. */ | 5 | /* Use memmove here, so gcc does not insert a __builtin_memcpy. */ |
7 | 6 | ||
diff --git a/include/asm-h8300/unistd.h b/include/asm-h8300/unistd.h index adb05159379b..226dd596c2da 100644 --- a/include/asm-h8300/unistd.h +++ b/include/asm-h8300/unistd.h | |||
@@ -292,6 +292,8 @@ | |||
292 | #define __NR_request_key 287 | 292 | #define __NR_request_key 287 |
293 | #define __NR_keyctl 288 | 293 | #define __NR_keyctl 288 |
294 | 294 | ||
295 | #ifdef __KERNEL__ | ||
296 | |||
295 | #define NR_syscalls 289 | 297 | #define NR_syscalls 289 |
296 | 298 | ||
297 | 299 | ||
@@ -460,7 +462,6 @@ type name(atype a, btype b, ctype c, dtype d, etype e, ftype f) \ | |||
460 | __syscall_return(type, __res); \ | 462 | __syscall_return(type, __res); \ |
461 | } | 463 | } |
462 | 464 | ||
463 | #ifdef __KERNEL__ | ||
464 | #define __ARCH_WANT_IPC_PARSE_VERSION | 465 | #define __ARCH_WANT_IPC_PARSE_VERSION |
465 | #define __ARCH_WANT_OLD_READDIR | 466 | #define __ARCH_WANT_OLD_READDIR |
466 | #define __ARCH_WANT_OLD_STAT | 467 | #define __ARCH_WANT_OLD_STAT |
@@ -483,7 +484,6 @@ type name(atype a, btype b, ctype c, dtype d, etype e, ftype f) \ | |||
483 | #define __ARCH_WANT_SYS_SIGPENDING | 484 | #define __ARCH_WANT_SYS_SIGPENDING |
484 | #define __ARCH_WANT_SYS_SIGPROCMASK | 485 | #define __ARCH_WANT_SYS_SIGPROCMASK |
485 | #define __ARCH_WANT_SYS_RT_SIGACTION | 486 | #define __ARCH_WANT_SYS_RT_SIGACTION |
486 | #endif | ||
487 | 487 | ||
488 | #ifdef __KERNEL_SYSCALLS__ | 488 | #ifdef __KERNEL_SYSCALLS__ |
489 | 489 | ||
@@ -534,7 +534,7 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
534 | struct sigaction __user *oact, | 534 | struct sigaction __user *oact, |
535 | size_t sigsetsize); | 535 | size_t sigsetsize); |
536 | 536 | ||
537 | #endif | 537 | #endif /* __KERNEL_SYSCALLS__ */ |
538 | 538 | ||
539 | /* | 539 | /* |
540 | * "Conditional" syscalls | 540 | * "Conditional" syscalls |
@@ -543,4 +543,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
543 | asm (".weak\t_" #name "\n" \ | 543 | asm (".weak\t_" #name "\n" \ |
544 | ".set\t_" #name ",_sys_ni_syscall"); | 544 | ".set\t_" #name ",_sys_ni_syscall"); |
545 | 545 | ||
546 | #endif /* __KERNEL__ */ | ||
546 | #endif /* _ASM_H8300_UNISTD_H_ */ | 547 | #endif /* _ASM_H8300_UNISTD_H_ */ |
diff --git a/include/asm-h8300/virtconvert.h b/include/asm-h8300/virtconvert.h index 3b344c1dfe0f..ee7d5ea10065 100644 --- a/include/asm-h8300/virtconvert.h +++ b/include/asm-h8300/virtconvert.h | |||
@@ -7,7 +7,6 @@ | |||
7 | 7 | ||
8 | #ifdef __KERNEL__ | 8 | #ifdef __KERNEL__ |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <asm/setup.h> | 10 | #include <asm/setup.h> |
12 | #include <asm/page.h> | 11 | #include <asm/page.h> |
13 | 12 | ||
diff --git a/include/asm-i386/apic.h b/include/asm-i386/apic.h index 288233fd77d7..cc9b940fb7e8 100644 --- a/include/asm-i386/apic.h +++ b/include/asm-i386/apic.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_APIC_H | 1 | #ifndef __ASM_APIC_H |
2 | #define __ASM_APIC_H | 2 | #define __ASM_APIC_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/pm.h> | 4 | #include <linux/pm.h> |
6 | #include <asm/fixmap.h> | 5 | #include <asm/fixmap.h> |
7 | #include <asm/apicdef.h> | 6 | #include <asm/apicdef.h> |
diff --git a/include/asm-i386/atomic.h b/include/asm-i386/atomic.h index 4ddce5296a78..4f061fa73794 100644 --- a/include/asm-i386/atomic.h +++ b/include/asm-i386/atomic.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ARCH_I386_ATOMIC__ | 1 | #ifndef __ARCH_I386_ATOMIC__ |
2 | #define __ARCH_I386_ATOMIC__ | 2 | #define __ARCH_I386_ATOMIC__ |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/compiler.h> | 4 | #include <linux/compiler.h> |
6 | #include <asm/processor.h> | 5 | #include <asm/processor.h> |
7 | 6 | ||
diff --git a/include/asm-i386/bitops.h b/include/asm-i386/bitops.h index 08deaeee6be9..1c780fa1e762 100644 --- a/include/asm-i386/bitops.h +++ b/include/asm-i386/bitops.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * Copyright 1992, Linus Torvalds. | 5 | * Copyright 1992, Linus Torvalds. |
6 | */ | 6 | */ |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | #include <linux/compiler.h> | 8 | #include <linux/compiler.h> |
10 | #include <asm/alternative.h> | 9 | #include <asm/alternative.h> |
11 | 10 | ||
diff --git a/include/asm-i386/bug.h b/include/asm-i386/bug.h index 8f79de19eb94..8062cdbf2587 100644 --- a/include/asm-i386/bug.h +++ b/include/asm-i386/bug.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _I386_BUG_H | 1 | #ifndef _I386_BUG_H |
2 | #define _I386_BUG_H | 2 | #define _I386_BUG_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * Tell the user there is some problem. | 6 | * Tell the user there is some problem. |
diff --git a/include/asm-i386/bugs.h b/include/asm-i386/bugs.h index 50233e0345fb..2a9e4ee5904d 100644 --- a/include/asm-i386/bugs.h +++ b/include/asm-i386/bugs.h | |||
@@ -17,7 +17,6 @@ | |||
17 | * void check_bugs(void); | 17 | * void check_bugs(void); |
18 | */ | 18 | */ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <linux/init.h> | 20 | #include <linux/init.h> |
22 | #include <asm/processor.h> | 21 | #include <asm/processor.h> |
23 | #include <asm/i387.h> | 22 | #include <asm/i387.h> |
diff --git a/include/asm-i386/byteorder.h b/include/asm-i386/byteorder.h index a0d73f48d5be..a45470a8b74a 100644 --- a/include/asm-i386/byteorder.h +++ b/include/asm-i386/byteorder.h | |||
@@ -8,7 +8,6 @@ | |||
8 | 8 | ||
9 | /* For avoiding bswap on i386 */ | 9 | /* For avoiding bswap on i386 */ |
10 | #ifdef __KERNEL__ | 10 | #ifdef __KERNEL__ |
11 | #include <linux/config.h> | ||
12 | #endif | 11 | #endif |
13 | 12 | ||
14 | static __inline__ __attribute_const__ __u32 ___arch__swab32(__u32 x) | 13 | static __inline__ __attribute_const__ __u32 ___arch__swab32(__u32 x) |
diff --git a/include/asm-i386/cache.h b/include/asm-i386/cache.h index ca15c9c665cf..57c62f414158 100644 --- a/include/asm-i386/cache.h +++ b/include/asm-i386/cache.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #ifndef __ARCH_I386_CACHE_H | 4 | #ifndef __ARCH_I386_CACHE_H |
5 | #define __ARCH_I386_CACHE_H | 5 | #define __ARCH_I386_CACHE_H |
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | /* L1 cache line size */ | 8 | /* L1 cache line size */ |
10 | #define L1_CACHE_SHIFT (CONFIG_X86_L1_CACHE_SHIFT) | 9 | #define L1_CACHE_SHIFT (CONFIG_X86_L1_CACHE_SHIFT) |
diff --git a/include/asm-i386/dma.h b/include/asm-i386/dma.h index f24b2bba2831..d23aac8e1a50 100644 --- a/include/asm-i386/dma.h +++ b/include/asm-i386/dma.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef _ASM_DMA_H | 8 | #ifndef _ASM_DMA_H |
9 | #define _ASM_DMA_H | 9 | #define _ASM_DMA_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #include <linux/spinlock.h> /* And spinlocks */ | 11 | #include <linux/spinlock.h> /* And spinlocks */ |
13 | #include <asm/io.h> /* need byte IO */ | 12 | #include <asm/io.h> /* need byte IO */ |
14 | #include <linux/delay.h> | 13 | #include <linux/delay.h> |
diff --git a/include/asm-i386/fixmap.h b/include/asm-i386/fixmap.h index cfb1c61d3b9c..f7e068f4d2f9 100644 --- a/include/asm-i386/fixmap.h +++ b/include/asm-i386/fixmap.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef _ASM_FIXMAP_H | 13 | #ifndef _ASM_FIXMAP_H |
14 | #define _ASM_FIXMAP_H | 14 | #define _ASM_FIXMAP_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | /* used by vmalloc.c, vsyscall.lds.S. | 17 | /* used by vmalloc.c, vsyscall.lds.S. |
19 | * | 18 | * |
diff --git a/include/asm-i386/hardirq.h b/include/asm-i386/hardirq.h index ee754d359734..0e358dc405f8 100644 --- a/include/asm-i386/hardirq.h +++ b/include/asm-i386/hardirq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_HARDIRQ_H | 1 | #ifndef __ASM_HARDIRQ_H |
2 | #define __ASM_HARDIRQ_H | 2 | #define __ASM_HARDIRQ_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/threads.h> | 4 | #include <linux/threads.h> |
6 | #include <linux/irq.h> | 5 | #include <linux/irq.h> |
7 | 6 | ||
diff --git a/include/asm-i386/highmem.h b/include/asm-i386/highmem.h index 0fd331306b60..e9a34ebc25d5 100644 --- a/include/asm-i386/highmem.h +++ b/include/asm-i386/highmem.h | |||
@@ -20,7 +20,6 @@ | |||
20 | 20 | ||
21 | #ifdef __KERNEL__ | 21 | #ifdef __KERNEL__ |
22 | 22 | ||
23 | #include <linux/config.h> | ||
24 | #include <linux/interrupt.h> | 23 | #include <linux/interrupt.h> |
25 | #include <linux/threads.h> | 24 | #include <linux/threads.h> |
26 | #include <asm/kmap_types.h> | 25 | #include <asm/kmap_types.h> |
diff --git a/include/asm-i386/hpet.h b/include/asm-i386/hpet.h index 7f1a8a6ee32f..af5d435519d1 100644 --- a/include/asm-i386/hpet.h +++ b/include/asm-i386/hpet.h | |||
@@ -27,7 +27,6 @@ | |||
27 | #include <asm/processor.h> | 27 | #include <asm/processor.h> |
28 | 28 | ||
29 | #include <linux/timex.h> | 29 | #include <linux/timex.h> |
30 | #include <linux/config.h> | ||
31 | 30 | ||
32 | #include <asm/fixmap.h> | 31 | #include <asm/fixmap.h> |
33 | 32 | ||
diff --git a/include/asm-i386/hw_irq.h b/include/asm-i386/hw_irq.h index 622815bf3243..95d3fd090298 100644 --- a/include/asm-i386/hw_irq.h +++ b/include/asm-i386/hw_irq.h | |||
@@ -12,7 +12,6 @@ | |||
12 | * <tomsoft@informatik.tu-chemnitz.de> | 12 | * <tomsoft@informatik.tu-chemnitz.de> |
13 | */ | 13 | */ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <linux/profile.h> | 15 | #include <linux/profile.h> |
17 | #include <asm/atomic.h> | 16 | #include <asm/atomic.h> |
18 | #include <asm/irq.h> | 17 | #include <asm/irq.h> |
diff --git a/include/asm-i386/ide.h b/include/asm-i386/ide.h index 454440193eac..73465d2892b9 100644 --- a/include/asm-i386/ide.h +++ b/include/asm-i386/ide.h | |||
@@ -13,7 +13,6 @@ | |||
13 | 13 | ||
14 | #ifdef __KERNEL__ | 14 | #ifdef __KERNEL__ |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | #ifndef MAX_HWIFS | 17 | #ifndef MAX_HWIFS |
19 | # ifdef CONFIG_BLK_DEV_IDEPCI | 18 | # ifdef CONFIG_BLK_DEV_IDEPCI |
diff --git a/include/asm-i386/io.h b/include/asm-i386/io.h index 79670bb4b0c7..b3724fe93ff1 100644 --- a/include/asm-i386/io.h +++ b/include/asm-i386/io.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_IO_H | 1 | #ifndef _ASM_IO_H |
2 | #define _ASM_IO_H | 2 | #define _ASM_IO_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/string.h> | 4 | #include <linux/string.h> |
6 | #include <linux/compiler.h> | 5 | #include <linux/compiler.h> |
7 | 6 | ||
diff --git a/include/asm-i386/io_apic.h b/include/asm-i386/io_apic.h index d92e253f7f6f..5092e819b8a2 100644 --- a/include/asm-i386/io_apic.h +++ b/include/asm-i386/io_apic.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_IO_APIC_H | 1 | #ifndef __ASM_IO_APIC_H |
2 | #define __ASM_IO_APIC_H | 2 | #define __ASM_IO_APIC_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/types.h> | 4 | #include <asm/types.h> |
6 | #include <asm/mpspec.h> | 5 | #include <asm/mpspec.h> |
7 | 6 | ||
diff --git a/include/asm-i386/irq.h b/include/asm-i386/irq.h index 5169d7af456f..331726b41128 100644 --- a/include/asm-i386/irq.h +++ b/include/asm-i386/irq.h | |||
@@ -10,7 +10,6 @@ | |||
10 | * <tomsoft@informatik.tu-chemnitz.de> | 10 | * <tomsoft@informatik.tu-chemnitz.de> |
11 | */ | 11 | */ |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/sched.h> | 13 | #include <linux/sched.h> |
15 | /* include comes from machine specific directory */ | 14 | /* include comes from machine specific directory */ |
16 | #include "irq_vectors.h" | 15 | #include "irq_vectors.h" |
diff --git a/include/asm-i386/kmap_types.h b/include/asm-i386/kmap_types.h index 6886a0c3fedf..806aae3c5338 100644 --- a/include/asm-i386/kmap_types.h +++ b/include/asm-i386/kmap_types.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_KMAP_TYPES_H | 1 | #ifndef _ASM_KMAP_TYPES_H |
2 | #define _ASM_KMAP_TYPES_H | 2 | #define _ASM_KMAP_TYPES_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_DEBUG_HIGHMEM | 5 | #ifdef CONFIG_DEBUG_HIGHMEM |
7 | # define D(n) __KM_FENCE_##n , | 6 | # define D(n) __KM_FENCE_##n , |
diff --git a/include/asm-i386/mach-summit/mach_apic.h b/include/asm-i386/mach-summit/mach_apic.h index 3d6d12937e1f..9fd073286289 100644 --- a/include/asm-i386/mach-summit/mach_apic.h +++ b/include/asm-i386/mach-summit/mach_apic.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_MACH_APIC_H | 1 | #ifndef __ASM_MACH_APIC_H |
2 | #define __ASM_MACH_APIC_H | 2 | #define __ASM_MACH_APIC_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/smp.h> | 4 | #include <asm/smp.h> |
6 | 5 | ||
7 | #define esr_disable (1) | 6 | #define esr_disable (1) |
diff --git a/include/asm-i386/mmu_context.h b/include/asm-i386/mmu_context.h index bf08218357ea..62b7bf184094 100644 --- a/include/asm-i386/mmu_context.h +++ b/include/asm-i386/mmu_context.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __I386_SCHED_H | 1 | #ifndef __I386_SCHED_H |
2 | #define __I386_SCHED_H | 2 | #define __I386_SCHED_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/desc.h> | 4 | #include <asm/desc.h> |
6 | #include <asm/atomic.h> | 5 | #include <asm/atomic.h> |
7 | #include <asm/pgalloc.h> | 6 | #include <asm/pgalloc.h> |
diff --git a/include/asm-i386/msi.h b/include/asm-i386/msi.h index f041d4495faf..b11c4b7dfaef 100644 --- a/include/asm-i386/msi.h +++ b/include/asm-i386/msi.h | |||
@@ -9,7 +9,15 @@ | |||
9 | #include <asm/desc.h> | 9 | #include <asm/desc.h> |
10 | #include <mach_apic.h> | 10 | #include <mach_apic.h> |
11 | 11 | ||
12 | #define LAST_DEVICE_VECTOR 232 | 12 | #define LAST_DEVICE_VECTOR (FIRST_SYSTEM_VECTOR - 1) |
13 | #define MSI_TARGET_CPU_SHIFT 12 | 13 | #define MSI_TARGET_CPU_SHIFT 12 |
14 | 14 | ||
15 | extern struct msi_ops msi_apic_ops; | ||
16 | |||
17 | static inline int msi_arch_init(void) | ||
18 | { | ||
19 | msi_register(&msi_apic_ops); | ||
20 | return 0; | ||
21 | } | ||
22 | |||
15 | #endif /* ASM_MSI_H */ | 23 | #endif /* ASM_MSI_H */ |
diff --git a/include/asm-i386/mtrr.h b/include/asm-i386/mtrr.h index 64cf937c7e33..5a46de08efea 100644 --- a/include/asm-i386/mtrr.h +++ b/include/asm-i386/mtrr.h | |||
@@ -23,7 +23,6 @@ | |||
23 | #ifndef _LINUX_MTRR_H | 23 | #ifndef _LINUX_MTRR_H |
24 | #define _LINUX_MTRR_H | 24 | #define _LINUX_MTRR_H |
25 | 25 | ||
26 | #include <linux/config.h> | ||
27 | #include <linux/ioctl.h> | 26 | #include <linux/ioctl.h> |
28 | #include <linux/errno.h> | 27 | #include <linux/errno.h> |
29 | 28 | ||
diff --git a/include/asm-i386/page.h b/include/asm-i386/page.h index 30f52a2263ba..e3a552fa5538 100644 --- a/include/asm-i386/page.h +++ b/include/asm-i386/page.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifdef __KERNEL__ | 12 | #ifdef __KERNEL__ |
13 | #ifndef __ASSEMBLY__ | 13 | #ifndef __ASSEMBLY__ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | #ifdef CONFIG_X86_USE_3DNOW | 16 | #ifdef CONFIG_X86_USE_3DNOW |
18 | 17 | ||
@@ -137,9 +136,9 @@ extern int page_is_ram(unsigned long pagenr); | |||
137 | ((current->personality & READ_IMPLIES_EXEC) ? VM_EXEC : 0 ) | \ | 136 | ((current->personality & READ_IMPLIES_EXEC) ? VM_EXEC : 0 ) | \ |
138 | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) | 137 | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) |
139 | 138 | ||
140 | #endif /* __KERNEL__ */ | ||
141 | |||
142 | #include <asm-generic/memory_model.h> | 139 | #include <asm-generic/memory_model.h> |
143 | #include <asm-generic/page.h> | 140 | #include <asm-generic/page.h> |
144 | 141 | ||
142 | #endif /* __KERNEL__ */ | ||
143 | |||
145 | #endif /* _I386_PAGE_H */ | 144 | #endif /* _I386_PAGE_H */ |
diff --git a/include/asm-i386/param.h b/include/asm-i386/param.h index 095580f3a45c..745dc5bd0fbc 100644 --- a/include/asm-i386/param.h +++ b/include/asm-i386/param.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define _ASMi386_PARAM_H | 2 | #define _ASMi386_PARAM_H |
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | # include <linux/config.h> | ||
6 | # define HZ CONFIG_HZ /* Internal kernel timer frequency */ | 5 | # define HZ CONFIG_HZ /* Internal kernel timer frequency */ |
7 | # define USER_HZ 100 /* .. some user interfaces are in "ticks" */ | 6 | # define USER_HZ 100 /* .. some user interfaces are in "ticks" */ |
8 | # define CLOCKS_PER_SEC (USER_HZ) /* like times() */ | 7 | # define CLOCKS_PER_SEC (USER_HZ) /* like times() */ |
diff --git a/include/asm-i386/pci.h b/include/asm-i386/pci.h index 78c85985aee3..64b6d0baedbc 100644 --- a/include/asm-i386/pci.h +++ b/include/asm-i386/pci.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __i386_PCI_H | 1 | #ifndef __i386_PCI_H |
2 | #define __i386_PCI_H | 2 | #define __i386_PCI_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef __KERNEL__ | 5 | #ifdef __KERNEL__ |
7 | #include <linux/mm.h> /* for struct page */ | 6 | #include <linux/mm.h> /* for struct page */ |
diff --git a/include/asm-i386/pgalloc.h b/include/asm-i386/pgalloc.h index 0380c3dc1f7e..4b1e61359f89 100644 --- a/include/asm-i386/pgalloc.h +++ b/include/asm-i386/pgalloc.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _I386_PGALLOC_H | 1 | #ifndef _I386_PGALLOC_H |
2 | #define _I386_PGALLOC_H | 2 | #define _I386_PGALLOC_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/fixmap.h> | 4 | #include <asm/fixmap.h> |
6 | #include <linux/threads.h> | 5 | #include <linux/threads.h> |
7 | #include <linux/mm.h> /* for struct page */ | 6 | #include <linux/mm.h> /* for struct page */ |
diff --git a/include/asm-i386/pgtable.h b/include/asm-i386/pgtable.h index 672c3f76b9df..09697fec3d2b 100644 --- a/include/asm-i386/pgtable.h +++ b/include/asm-i386/pgtable.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _I386_PGTABLE_H | 1 | #ifndef _I386_PGTABLE_H |
2 | #define _I386_PGTABLE_H | 2 | #define _I386_PGTABLE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * The Linux memory management assumes a three-level page table setup. On | 6 | * The Linux memory management assumes a three-level page table setup. On |
diff --git a/include/asm-i386/processor.h b/include/asm-i386/processor.h index 805f0dcda468..4df3818e4122 100644 --- a/include/asm-i386/processor.h +++ b/include/asm-i386/processor.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #include <asm/msr.h> | 17 | #include <asm/msr.h> |
18 | #include <asm/system.h> | 18 | #include <asm/system.h> |
19 | #include <linux/cache.h> | 19 | #include <linux/cache.h> |
20 | #include <linux/config.h> | ||
21 | #include <linux/threads.h> | 20 | #include <linux/threads.h> |
22 | #include <asm/percpu.h> | 21 | #include <asm/percpu.h> |
23 | #include <linux/cpumask.h> | 22 | #include <linux/cpumask.h> |
diff --git a/include/asm-i386/serial.h b/include/asm-i386/serial.h index e1ecfccb743b..bd67480ca109 100644 --- a/include/asm-i386/serial.h +++ b/include/asm-i386/serial.h | |||
@@ -2,7 +2,6 @@ | |||
2 | * include/asm-i386/serial.h | 2 | * include/asm-i386/serial.h |
3 | */ | 3 | */ |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | 5 | ||
7 | /* | 6 | /* |
8 | * This assumes you have a 1.8432 MHz clock for your UART. | 7 | * This assumes you have a 1.8432 MHz clock for your UART. |
diff --git a/include/asm-i386/smp.h b/include/asm-i386/smp.h index 61d3ab9db70c..142d10e34ade 100644 --- a/include/asm-i386/smp.h +++ b/include/asm-i386/smp.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * We need the APIC definitions automatically as part of 'smp.h' | 5 | * We need the APIC definitions automatically as part of 'smp.h' |
6 | */ | 6 | */ |
7 | #ifndef __ASSEMBLY__ | 7 | #ifndef __ASSEMBLY__ |
8 | #include <linux/config.h> | ||
9 | #include <linux/kernel.h> | 8 | #include <linux/kernel.h> |
10 | #include <linux/threads.h> | 9 | #include <linux/threads.h> |
11 | #include <linux/cpumask.h> | 10 | #include <linux/cpumask.h> |
diff --git a/include/asm-i386/spinlock.h b/include/asm-i386/spinlock.h index d76b7693cf1d..04ba30234c48 100644 --- a/include/asm-i386/spinlock.h +++ b/include/asm-i386/spinlock.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #include <asm/atomic.h> | 4 | #include <asm/atomic.h> |
5 | #include <asm/rwlock.h> | 5 | #include <asm/rwlock.h> |
6 | #include <asm/page.h> | 6 | #include <asm/page.h> |
7 | #include <linux/config.h> | ||
8 | #include <linux/compiler.h> | 7 | #include <linux/compiler.h> |
9 | 8 | ||
10 | /* | 9 | /* |
diff --git a/include/asm-i386/string.h b/include/asm-i386/string.h index bb5f88a27f7a..b9277361954b 100644 --- a/include/asm-i386/string.h +++ b/include/asm-i386/string.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define _I386_STRING_H_ | 2 | #define _I386_STRING_H_ |
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | #include <linux/config.h> | ||
6 | /* | 5 | /* |
7 | * On a 486 or Pentium, we are better off not using the | 6 | * On a 486 or Pentium, we are better off not using the |
8 | * byte string operations. But on a 386 or a PPro the | 7 | * byte string operations. But on a 386 or a PPro the |
diff --git a/include/asm-i386/system.h b/include/asm-i386/system.h index 19cc79c9a35d..0249f912a29c 100644 --- a/include/asm-i386/system.h +++ b/include/asm-i386/system.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_SYSTEM_H | 1 | #ifndef __ASM_SYSTEM_H |
2 | #define __ASM_SYSTEM_H | 2 | #define __ASM_SYSTEM_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/kernel.h> | 4 | #include <linux/kernel.h> |
6 | #include <asm/segment.h> | 5 | #include <asm/segment.h> |
7 | #include <asm/cpufeature.h> | 6 | #include <asm/cpufeature.h> |
diff --git a/include/asm-i386/thread_info.h b/include/asm-i386/thread_info.h index 1f7d48c9ba3f..8420ed12491e 100644 --- a/include/asm-i386/thread_info.h +++ b/include/asm-i386/thread_info.h | |||
@@ -9,7 +9,6 @@ | |||
9 | 9 | ||
10 | #ifdef __KERNEL__ | 10 | #ifdef __KERNEL__ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/compiler.h> | 12 | #include <linux/compiler.h> |
14 | #include <asm/page.h> | 13 | #include <asm/page.h> |
15 | 14 | ||
diff --git a/include/asm-i386/timex.h b/include/asm-i386/timex.h index 292b5a68f627..d434984303ca 100644 --- a/include/asm-i386/timex.h +++ b/include/asm-i386/timex.h | |||
@@ -6,7 +6,6 @@ | |||
6 | #ifndef _ASMi386_TIMEX_H | 6 | #ifndef _ASMi386_TIMEX_H |
7 | #define _ASMi386_TIMEX_H | 7 | #define _ASMi386_TIMEX_H |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <asm/processor.h> | 9 | #include <asm/processor.h> |
11 | 10 | ||
12 | #ifdef CONFIG_X86_ELAN | 11 | #ifdef CONFIG_X86_ELAN |
diff --git a/include/asm-i386/tlbflush.h b/include/asm-i386/tlbflush.h index ab216e1370ef..d57ca5c540b6 100644 --- a/include/asm-i386/tlbflush.h +++ b/include/asm-i386/tlbflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _I386_TLBFLUSH_H | 1 | #ifndef _I386_TLBFLUSH_H |
2 | #define _I386_TLBFLUSH_H | 2 | #define _I386_TLBFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | #include <asm/processor.h> | 5 | #include <asm/processor.h> |
7 | 6 | ||
diff --git a/include/asm-i386/types.h b/include/asm-i386/types.h index e50a08bd7ced..4b4b295ccdb9 100644 --- a/include/asm-i386/types.h +++ b/include/asm-i386/types.h | |||
@@ -35,7 +35,6 @@ typedef unsigned long long __u64; | |||
35 | 35 | ||
36 | #ifndef __ASSEMBLY__ | 36 | #ifndef __ASSEMBLY__ |
37 | 37 | ||
38 | #include <linux/config.h> | ||
39 | 38 | ||
40 | typedef signed char s8; | 39 | typedef signed char s8; |
41 | typedef unsigned char u8; | 40 | typedef unsigned char u8; |
diff --git a/include/asm-i386/uaccess.h b/include/asm-i386/uaccess.h index 371457b1ceb6..1ec65523ea5e 100644 --- a/include/asm-i386/uaccess.h +++ b/include/asm-i386/uaccess.h | |||
@@ -4,7 +4,6 @@ | |||
4 | /* | 4 | /* |
5 | * User space memory access functions | 5 | * User space memory access functions |
6 | */ | 6 | */ |
7 | #include <linux/config.h> | ||
8 | #include <linux/errno.h> | 7 | #include <linux/errno.h> |
9 | #include <linux/thread_info.h> | 8 | #include <linux/thread_info.h> |
10 | #include <linux/prefetch.h> | 9 | #include <linux/prefetch.h> |
diff --git a/include/asm-i386/unistd.h b/include/asm-i386/unistd.h index eb4b152c82fc..de2ccc149e34 100644 --- a/include/asm-i386/unistd.h +++ b/include/asm-i386/unistd.h | |||
@@ -323,6 +323,8 @@ | |||
323 | #define __NR_tee 315 | 323 | #define __NR_tee 315 |
324 | #define __NR_vmsplice 316 | 324 | #define __NR_vmsplice 316 |
325 | 325 | ||
326 | #ifdef __KERNEL__ | ||
327 | |||
326 | #define NR_syscalls 317 | 328 | #define NR_syscalls 317 |
327 | 329 | ||
328 | /* | 330 | /* |
@@ -422,7 +424,6 @@ __asm__ volatile ("push %%ebp ; push %%ebx ; movl 4(%2),%%ebp ; " \ | |||
422 | __syscall_return(type,__res); \ | 424 | __syscall_return(type,__res); \ |
423 | } | 425 | } |
424 | 426 | ||
425 | #ifdef __KERNEL__ | ||
426 | #define __ARCH_WANT_IPC_PARSE_VERSION | 427 | #define __ARCH_WANT_IPC_PARSE_VERSION |
427 | #define __ARCH_WANT_OLD_READDIR | 428 | #define __ARCH_WANT_OLD_READDIR |
428 | #define __ARCH_WANT_OLD_STAT | 429 | #define __ARCH_WANT_OLD_STAT |
@@ -446,7 +447,6 @@ __syscall_return(type,__res); \ | |||
446 | #define __ARCH_WANT_SYS_SIGPROCMASK | 447 | #define __ARCH_WANT_SYS_SIGPROCMASK |
447 | #define __ARCH_WANT_SYS_RT_SIGACTION | 448 | #define __ARCH_WANT_SYS_RT_SIGACTION |
448 | #define __ARCH_WANT_SYS_RT_SIGSUSPEND | 449 | #define __ARCH_WANT_SYS_RT_SIGSUSPEND |
449 | #endif | ||
450 | 450 | ||
451 | #ifdef __KERNEL_SYSCALLS__ | 451 | #ifdef __KERNEL_SYSCALLS__ |
452 | 452 | ||
@@ -485,7 +485,7 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
485 | struct sigaction __user *oact, | 485 | struct sigaction __user *oact, |
486 | size_t sigsetsize); | 486 | size_t sigsetsize); |
487 | 487 | ||
488 | #endif | 488 | #endif /* __KERNEL_SYSCALLS__ */ |
489 | 489 | ||
490 | /* | 490 | /* |
491 | * "Conditional" syscalls | 491 | * "Conditional" syscalls |
@@ -497,4 +497,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
497 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 497 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
498 | #endif | 498 | #endif |
499 | 499 | ||
500 | #endif /* __KERNEL__ */ | ||
500 | #endif /* _ASM_I386_UNISTD_H_ */ | 501 | #endif /* _ASM_I386_UNISTD_H_ */ |
diff --git a/include/asm-i386/vga.h b/include/asm-i386/vga.h index ef0c0e50cc95..0ecf68ac03aa 100644 --- a/include/asm-i386/vga.h +++ b/include/asm-i386/vga.h | |||
@@ -12,7 +12,7 @@ | |||
12 | * access the videoram directly without any black magic. | 12 | * access the videoram directly without any black magic. |
13 | */ | 13 | */ |
14 | 14 | ||
15 | #define VGA_MAP_MEM(x) (unsigned long)phys_to_virt(x) | 15 | #define VGA_MAP_MEM(x,s) (unsigned long)phys_to_virt(x) |
16 | 16 | ||
17 | #define vga_readb(x) (*(x)) | 17 | #define vga_readb(x) (*(x)) |
18 | #define vga_writeb(x,y) (*(y) = (x)) | 18 | #define vga_writeb(x,y) (*(y) = (x)) |
diff --git a/include/asm-ia64/asmmacro.h b/include/asm-ia64/asmmacro.h index edf2cebb2969..c22b4658fc61 100644 --- a/include/asm-ia64/asmmacro.h +++ b/include/asm-ia64/asmmacro.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * David Mosberger-Tang <davidm@hpl.hp.com> | 6 | * David Mosberger-Tang <davidm@hpl.hp.com> |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | #define ENTRY(name) \ | 10 | #define ENTRY(name) \ |
12 | .align 32; \ | 11 | .align 32; \ |
diff --git a/include/asm-ia64/cache.h b/include/asm-ia64/cache.h index f0a104db8f20..e7482bd628ff 100644 --- a/include/asm-ia64/cache.h +++ b/include/asm-ia64/cache.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_IA64_CACHE_H | 1 | #ifndef _ASM_IA64_CACHE_H |
2 | #define _ASM_IA64_CACHE_H | 2 | #define _ASM_IA64_CACHE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * Copyright (C) 1998-2000 Hewlett-Packard Co | 6 | * Copyright (C) 1998-2000 Hewlett-Packard Co |
diff --git a/include/asm-ia64/delay.h b/include/asm-ia64/delay.h index bba702076391..a30a62f235e1 100644 --- a/include/asm-ia64/delay.h +++ b/include/asm-ia64/delay.h | |||
@@ -12,7 +12,6 @@ | |||
12 | * Copyright (C) 1999 Don Dugger <don.dugger@intel.com> | 12 | * Copyright (C) 1999 Don Dugger <don.dugger@intel.com> |
13 | */ | 13 | */ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <linux/kernel.h> | 15 | #include <linux/kernel.h> |
17 | #include <linux/sched.h> | 16 | #include <linux/sched.h> |
18 | #include <linux/compiler.h> | 17 | #include <linux/compiler.h> |
diff --git a/include/asm-ia64/dma-mapping.h b/include/asm-ia64/dma-mapping.h index df67d40801de..99a8f8e1218c 100644 --- a/include/asm-ia64/dma-mapping.h +++ b/include/asm-ia64/dma-mapping.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * Copyright (C) 2003-2004 Hewlett-Packard Co | 5 | * Copyright (C) 2003-2004 Hewlett-Packard Co |
6 | * David Mosberger-Tang <davidm@hpl.hp.com> | 6 | * David Mosberger-Tang <davidm@hpl.hp.com> |
7 | */ | 7 | */ |
8 | #include <linux/config.h> | ||
9 | #include <asm/machvec.h> | 8 | #include <asm/machvec.h> |
10 | 9 | ||
11 | #define dma_alloc_coherent platform_dma_alloc_coherent | 10 | #define dma_alloc_coherent platform_dma_alloc_coherent |
diff --git a/include/asm-ia64/dma.h b/include/asm-ia64/dma.h index 3be1b4925e18..dad3a735df8b 100644 --- a/include/asm-ia64/dma.h +++ b/include/asm-ia64/dma.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * David Mosberger-Tang <davidm@hpl.hp.com> | 6 | * David Mosberger-Tang <davidm@hpl.hp.com> |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | #include <asm/io.h> /* need byte IO */ | 10 | #include <asm/io.h> /* need byte IO */ |
12 | 11 | ||
diff --git a/include/asm-ia64/elf.h b/include/asm-ia64/elf.h index 446fce036fd9..25f9835d5459 100644 --- a/include/asm-ia64/elf.h +++ b/include/asm-ia64/elf.h | |||
@@ -8,7 +8,6 @@ | |||
8 | * David Mosberger-Tang <davidm@hpl.hp.com> | 8 | * David Mosberger-Tang <davidm@hpl.hp.com> |
9 | */ | 9 | */ |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | 11 | ||
13 | #include <asm/fpu.h> | 12 | #include <asm/fpu.h> |
14 | #include <asm/page.h> | 13 | #include <asm/page.h> |
diff --git a/include/asm-ia64/hardirq.h b/include/asm-ia64/hardirq.h index 33ef8f096d95..140e495b8e0e 100644 --- a/include/asm-ia64/hardirq.h +++ b/include/asm-ia64/hardirq.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * David Mosberger-Tang <davidm@hpl.hp.com> | 6 | * David Mosberger-Tang <davidm@hpl.hp.com> |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | #include <linux/threads.h> | 10 | #include <linux/threads.h> |
12 | #include <linux/irq.h> | 11 | #include <linux/irq.h> |
diff --git a/include/asm-ia64/hw_irq.h b/include/asm-ia64/hw_irq.h index 0cf119b42f7d..ea8b8c407ab4 100644 --- a/include/asm-ia64/hw_irq.h +++ b/include/asm-ia64/hw_irq.h | |||
@@ -47,9 +47,19 @@ typedef u8 ia64_vector; | |||
47 | #define IA64_CMC_VECTOR 0x1f /* corrected machine-check interrupt vector */ | 47 | #define IA64_CMC_VECTOR 0x1f /* corrected machine-check interrupt vector */ |
48 | /* | 48 | /* |
49 | * Vectors 0x20-0x2f are reserved for legacy ISA IRQs. | 49 | * Vectors 0x20-0x2f are reserved for legacy ISA IRQs. |
50 | * Use vectors 0x30-0xe7 as the default device vector range for ia64. | ||
51 | * Platforms may choose to reduce this range in platform_irq_setup, but the | ||
52 | * platform range must fall within | ||
53 | * [IA64_DEF_FIRST_DEVICE_VECTOR..IA64_DEF_LAST_DEVICE_VECTOR] | ||
50 | */ | 54 | */ |
51 | #define IA64_FIRST_DEVICE_VECTOR 0x30 | 55 | extern int ia64_first_device_vector; |
52 | #define IA64_LAST_DEVICE_VECTOR 0xe7 | 56 | extern int ia64_last_device_vector; |
57 | |||
58 | #define IA64_DEF_FIRST_DEVICE_VECTOR 0x30 | ||
59 | #define IA64_DEF_LAST_DEVICE_VECTOR 0xe7 | ||
60 | #define IA64_FIRST_DEVICE_VECTOR ia64_first_device_vector | ||
61 | #define IA64_LAST_DEVICE_VECTOR ia64_last_device_vector | ||
62 | #define IA64_MAX_DEVICE_VECTORS (IA64_DEF_LAST_DEVICE_VECTOR - IA64_DEF_FIRST_DEVICE_VECTOR + 1) | ||
53 | #define IA64_NUM_DEVICE_VECTORS (IA64_LAST_DEVICE_VECTOR - IA64_FIRST_DEVICE_VECTOR + 1) | 63 | #define IA64_NUM_DEVICE_VECTORS (IA64_LAST_DEVICE_VECTOR - IA64_FIRST_DEVICE_VECTOR + 1) |
54 | 64 | ||
55 | #define IA64_MCA_RENDEZ_VECTOR 0xe8 /* MCA rendez interrupt */ | 65 | #define IA64_MCA_RENDEZ_VECTOR 0xe8 /* MCA rendez interrupt */ |
@@ -83,6 +93,7 @@ extern struct hw_interrupt_type irq_type_ia64_lsapic; /* CPU-internal interrupt | |||
83 | 93 | ||
84 | extern int assign_irq_vector (int irq); /* allocate a free vector */ | 94 | extern int assign_irq_vector (int irq); /* allocate a free vector */ |
85 | extern void free_irq_vector (int vector); | 95 | extern void free_irq_vector (int vector); |
96 | extern int reserve_irq_vector (int vector); | ||
86 | extern void ia64_send_ipi (int cpu, int vector, int delivery_mode, int redirect); | 97 | extern void ia64_send_ipi (int cpu, int vector, int delivery_mode, int redirect); |
87 | extern void register_percpu_irq (ia64_vector vec, struct irqaction *action); | 98 | extern void register_percpu_irq (ia64_vector vec, struct irqaction *action); |
88 | 99 | ||
diff --git a/include/asm-ia64/ia32.h b/include/asm-ia64/ia32.h index f8044a1169cd..5ff8d74c3e00 100644 --- a/include/asm-ia64/ia32.h +++ b/include/asm-ia64/ia32.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_IA64_IA32_H | 1 | #ifndef _ASM_IA64_IA32_H |
2 | #define _ASM_IA64_IA32_H | 2 | #define _ASM_IA64_IA32_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #include <asm/ptrace.h> | 5 | #include <asm/ptrace.h> |
7 | #include <asm/signal.h> | 6 | #include <asm/signal.h> |
diff --git a/include/asm-ia64/ide.h b/include/asm-ia64/ide.h index 93f45c5f189f..e928675de352 100644 --- a/include/asm-ia64/ide.h +++ b/include/asm-ia64/ide.h | |||
@@ -13,7 +13,6 @@ | |||
13 | 13 | ||
14 | #ifdef __KERNEL__ | 14 | #ifdef __KERNEL__ |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | #include <linux/irq.h> | 17 | #include <linux/irq.h> |
19 | 18 | ||
diff --git a/include/asm-ia64/intrinsics.h b/include/asm-ia64/intrinsics.h index 8089f955e5d2..3a95aa432e99 100644 --- a/include/asm-ia64/intrinsics.h +++ b/include/asm-ia64/intrinsics.h | |||
@@ -9,7 +9,6 @@ | |||
9 | */ | 9 | */ |
10 | 10 | ||
11 | #ifndef __ASSEMBLY__ | 11 | #ifndef __ASSEMBLY__ |
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | /* include compiler specific intrinsics */ | 13 | /* include compiler specific intrinsics */ |
15 | #include <asm/ia64regs.h> | 14 | #include <asm/ia64regs.h> |
diff --git a/include/asm-ia64/kmap_types.h b/include/asm-ia64/kmap_types.h index bc777525fa12..5d1658aa2b3b 100644 --- a/include/asm-ia64/kmap_types.h +++ b/include/asm-ia64/kmap_types.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_IA64_KMAP_TYPES_H | 1 | #ifndef _ASM_IA64_KMAP_TYPES_H |
2 | #define _ASM_IA64_KMAP_TYPES_H | 2 | #define _ASM_IA64_KMAP_TYPES_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_DEBUG_HIGHMEM | 5 | #ifdef CONFIG_DEBUG_HIGHMEM |
7 | # define D(n) __KM_FENCE_##n , | 6 | # define D(n) __KM_FENCE_##n , |
diff --git a/include/asm-ia64/machvec.h b/include/asm-ia64/machvec.h index a9c995a86c21..15b545a897a4 100644 --- a/include/asm-ia64/machvec.h +++ b/include/asm-ia64/machvec.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASM_IA64_MACHVEC_H | 10 | #ifndef _ASM_IA64_MACHVEC_H |
11 | #define _ASM_IA64_MACHVEC_H | 11 | #define _ASM_IA64_MACHVEC_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/types.h> | 13 | #include <linux/types.h> |
15 | 14 | ||
16 | /* forward declarations: */ | 15 | /* forward declarations: */ |
@@ -76,6 +75,7 @@ typedef unsigned char ia64_mv_readb_relaxed_t (const volatile void __iomem *); | |||
76 | typedef unsigned short ia64_mv_readw_relaxed_t (const volatile void __iomem *); | 75 | typedef unsigned short ia64_mv_readw_relaxed_t (const volatile void __iomem *); |
77 | typedef unsigned int ia64_mv_readl_relaxed_t (const volatile void __iomem *); | 76 | typedef unsigned int ia64_mv_readl_relaxed_t (const volatile void __iomem *); |
78 | typedef unsigned long ia64_mv_readq_relaxed_t (const volatile void __iomem *); | 77 | typedef unsigned long ia64_mv_readq_relaxed_t (const volatile void __iomem *); |
78 | typedef int ia64_mv_msi_init_t (void); | ||
79 | 79 | ||
80 | static inline void | 80 | static inline void |
81 | machvec_noop (void) | 81 | machvec_noop (void) |
@@ -154,6 +154,7 @@ extern void machvec_tlb_migrate_finish (struct mm_struct *); | |||
154 | # define platform_readl_relaxed ia64_mv.readl_relaxed | 154 | # define platform_readl_relaxed ia64_mv.readl_relaxed |
155 | # define platform_readq_relaxed ia64_mv.readq_relaxed | 155 | # define platform_readq_relaxed ia64_mv.readq_relaxed |
156 | # define platform_migrate ia64_mv.migrate | 156 | # define platform_migrate ia64_mv.migrate |
157 | # define platform_msi_init ia64_mv.msi_init | ||
157 | # endif | 158 | # endif |
158 | 159 | ||
159 | /* __attribute__((__aligned__(16))) is required to make size of the | 160 | /* __attribute__((__aligned__(16))) is required to make size of the |
@@ -203,6 +204,7 @@ struct ia64_machine_vector { | |||
203 | ia64_mv_readl_relaxed_t *readl_relaxed; | 204 | ia64_mv_readl_relaxed_t *readl_relaxed; |
204 | ia64_mv_readq_relaxed_t *readq_relaxed; | 205 | ia64_mv_readq_relaxed_t *readq_relaxed; |
205 | ia64_mv_migrate_t *migrate; | 206 | ia64_mv_migrate_t *migrate; |
207 | ia64_mv_msi_init_t *msi_init; | ||
206 | } __attribute__((__aligned__(16))); /* align attrib? see above comment */ | 208 | } __attribute__((__aligned__(16))); /* align attrib? see above comment */ |
207 | 209 | ||
208 | #define MACHVEC_INIT(name) \ | 210 | #define MACHVEC_INIT(name) \ |
@@ -248,6 +250,7 @@ struct ia64_machine_vector { | |||
248 | platform_readl_relaxed, \ | 250 | platform_readl_relaxed, \ |
249 | platform_readq_relaxed, \ | 251 | platform_readq_relaxed, \ |
250 | platform_migrate, \ | 252 | platform_migrate, \ |
253 | platform_msi_init, \ | ||
251 | } | 254 | } |
252 | 255 | ||
253 | extern struct ia64_machine_vector ia64_mv; | 256 | extern struct ia64_machine_vector ia64_mv; |
@@ -401,5 +404,8 @@ extern int ia64_pci_legacy_write(struct pci_bus *bus, u16 port, u32 val, u8 size | |||
401 | #ifndef platform_migrate | 404 | #ifndef platform_migrate |
402 | # define platform_migrate machvec_noop_task | 405 | # define platform_migrate machvec_noop_task |
403 | #endif | 406 | #endif |
407 | #ifndef platform_msi_init | ||
408 | # define platform_msi_init ((ia64_mv_msi_init_t*)NULL) | ||
409 | #endif | ||
404 | 410 | ||
405 | #endif /* _ASM_IA64_MACHVEC_H */ | 411 | #endif /* _ASM_IA64_MACHVEC_H */ |
diff --git a/include/asm-ia64/machvec_sn2.h b/include/asm-ia64/machvec_sn2.h index da1d43755afe..cf724dc79d8c 100644 --- a/include/asm-ia64/machvec_sn2.h +++ b/include/asm-ia64/machvec_sn2.h | |||
@@ -67,6 +67,8 @@ extern ia64_mv_dma_sync_sg_for_device sn_dma_sync_sg_for_device; | |||
67 | extern ia64_mv_dma_mapping_error sn_dma_mapping_error; | 67 | extern ia64_mv_dma_mapping_error sn_dma_mapping_error; |
68 | extern ia64_mv_dma_supported sn_dma_supported; | 68 | extern ia64_mv_dma_supported sn_dma_supported; |
69 | extern ia64_mv_migrate_t sn_migrate; | 69 | extern ia64_mv_migrate_t sn_migrate; |
70 | extern ia64_mv_msi_init_t sn_msi_init; | ||
71 | |||
70 | 72 | ||
71 | /* | 73 | /* |
72 | * This stuff has dual use! | 74 | * This stuff has dual use! |
@@ -117,6 +119,11 @@ extern ia64_mv_migrate_t sn_migrate; | |||
117 | #define platform_dma_mapping_error sn_dma_mapping_error | 119 | #define platform_dma_mapping_error sn_dma_mapping_error |
118 | #define platform_dma_supported sn_dma_supported | 120 | #define platform_dma_supported sn_dma_supported |
119 | #define platform_migrate sn_migrate | 121 | #define platform_migrate sn_migrate |
122 | #ifdef CONFIG_PCI_MSI | ||
123 | #define platform_msi_init sn_msi_init | ||
124 | #else | ||
125 | #define platform_msi_init ((ia64_mv_msi_init_t*)NULL) | ||
126 | #endif | ||
120 | 127 | ||
121 | #include <asm/sn/io.h> | 128 | #include <asm/sn/io.h> |
122 | 129 | ||
diff --git a/include/asm-ia64/meminit.h b/include/asm-ia64/meminit.h index 46501b01a5c5..894bc4d89dc0 100644 --- a/include/asm-ia64/meminit.h +++ b/include/asm-ia64/meminit.h | |||
@@ -7,7 +7,6 @@ | |||
7 | * for more details. | 7 | * for more details. |
8 | */ | 8 | */ |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | 10 | ||
12 | /* | 11 | /* |
13 | * Entries defined so far: | 12 | * Entries defined so far: |
diff --git a/include/asm-ia64/msi.h b/include/asm-ia64/msi.h index 97890f7762b3..bb92b0dbde2f 100644 --- a/include/asm-ia64/msi.h +++ b/include/asm-ia64/msi.h | |||
@@ -14,4 +14,16 @@ static inline void set_intr_gate (int nr, void *func) {} | |||
14 | #define ack_APIC_irq ia64_eoi | 14 | #define ack_APIC_irq ia64_eoi |
15 | #define MSI_TARGET_CPU_SHIFT 4 | 15 | #define MSI_TARGET_CPU_SHIFT 4 |
16 | 16 | ||
17 | extern struct msi_ops msi_apic_ops; | ||
18 | |||
19 | static inline int msi_arch_init(void) | ||
20 | { | ||
21 | if (platform_msi_init) | ||
22 | return platform_msi_init(); | ||
23 | |||
24 | /* default ops for most ia64 platforms */ | ||
25 | msi_register(&msi_apic_ops); | ||
26 | return 0; | ||
27 | } | ||
28 | |||
17 | #endif /* ASM_MSI_H */ | 29 | #endif /* ASM_MSI_H */ |
diff --git a/include/asm-ia64/nodedata.h b/include/asm-ia64/nodedata.h index 9978c7ce7549..a140310bf84d 100644 --- a/include/asm-ia64/nodedata.h +++ b/include/asm-ia64/nodedata.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_IA64_NODEDATA_H | 11 | #ifndef _ASM_IA64_NODEDATA_H |
12 | #define _ASM_IA64_NODEDATA_H | 12 | #define _ASM_IA64_NODEDATA_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/numa.h> | 14 | #include <linux/numa.h> |
16 | 15 | ||
17 | #include <asm/percpu.h> | 16 | #include <asm/percpu.h> |
diff --git a/include/asm-ia64/numa.h b/include/asm-ia64/numa.h index dae6aeb7b119..e5a8260593a5 100644 --- a/include/asm-ia64/numa.h +++ b/include/asm-ia64/numa.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_IA64_NUMA_H | 11 | #ifndef _ASM_IA64_NUMA_H |
12 | #define _ASM_IA64_NUMA_H | 12 | #define _ASM_IA64_NUMA_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | #ifdef CONFIG_NUMA | 15 | #ifdef CONFIG_NUMA |
17 | 16 | ||
diff --git a/include/asm-ia64/page.h b/include/asm-ia64/page.h index 2087825eefa4..f5a949ec6e1e 100644 --- a/include/asm-ia64/page.h +++ b/include/asm-ia64/page.h | |||
@@ -7,7 +7,6 @@ | |||
7 | * David Mosberger-Tang <davidm@hpl.hp.com> | 7 | * David Mosberger-Tang <davidm@hpl.hp.com> |
8 | */ | 8 | */ |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | 10 | ||
12 | #include <asm/intrinsics.h> | 11 | #include <asm/intrinsics.h> |
13 | #include <asm/types.h> | 12 | #include <asm/types.h> |
diff --git a/include/asm-ia64/param.h b/include/asm-ia64/param.h index 5e1e0d2d7baf..49c62dd5eccf 100644 --- a/include/asm-ia64/param.h +++ b/include/asm-ia64/param.h | |||
@@ -19,7 +19,6 @@ | |||
19 | #define MAXHOSTNAMELEN 64 /* max length of hostname */ | 19 | #define MAXHOSTNAMELEN 64 /* max length of hostname */ |
20 | 20 | ||
21 | #ifdef __KERNEL__ | 21 | #ifdef __KERNEL__ |
22 | # include <linux/config.h> /* mustn't include <linux/config.h> outside of #ifdef __KERNEL__ */ | ||
23 | # ifdef CONFIG_IA64_HP_SIM | 22 | # ifdef CONFIG_IA64_HP_SIM |
24 | /* | 23 | /* |
25 | * Yeah, simulating stuff is slow, so let us catch some breath between | 24 | * Yeah, simulating stuff is slow, so let us catch some breath between |
diff --git a/include/asm-ia64/percpu.h b/include/asm-ia64/percpu.h index 2b14dee29ce7..ae357d504fba 100644 --- a/include/asm-ia64/percpu.h +++ b/include/asm-ia64/percpu.h | |||
@@ -12,7 +12,6 @@ | |||
12 | # define THIS_CPU(var) (per_cpu__##var) /* use this to mark accesses to per-CPU variables... */ | 12 | # define THIS_CPU(var) (per_cpu__##var) /* use this to mark accesses to per-CPU variables... */ |
13 | #else /* !__ASSEMBLY__ */ | 13 | #else /* !__ASSEMBLY__ */ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | #include <linux/threads.h> | 16 | #include <linux/threads.h> |
18 | 17 | ||
diff --git a/include/asm-ia64/pgalloc.h b/include/asm-ia64/pgalloc.h index f2f233846476..9cb68e9b377e 100644 --- a/include/asm-ia64/pgalloc.h +++ b/include/asm-ia64/pgalloc.h | |||
@@ -13,7 +13,6 @@ | |||
13 | * Copyright (C) 2000, Goutham Rao <goutham.rao@intel.com> | 13 | * Copyright (C) 2000, Goutham Rao <goutham.rao@intel.com> |
14 | */ | 14 | */ |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | #include <linux/compiler.h> | 17 | #include <linux/compiler.h> |
19 | #include <linux/mm.h> | 18 | #include <linux/mm.h> |
diff --git a/include/asm-ia64/pgtable.h b/include/asm-ia64/pgtable.h index c0f8144f2349..eaac08d5e0bd 100644 --- a/include/asm-ia64/pgtable.h +++ b/include/asm-ia64/pgtable.h | |||
@@ -12,7 +12,6 @@ | |||
12 | * David Mosberger-Tang <davidm@hpl.hp.com> | 12 | * David Mosberger-Tang <davidm@hpl.hp.com> |
13 | */ | 13 | */ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | #include <asm/mman.h> | 16 | #include <asm/mman.h> |
18 | #include <asm/page.h> | 17 | #include <asm/page.h> |
diff --git a/include/asm-ia64/processor.h b/include/asm-ia64/processor.h index b3bd58e80690..265f4824db0e 100644 --- a/include/asm-ia64/processor.h +++ b/include/asm-ia64/processor.h | |||
@@ -13,7 +13,6 @@ | |||
13 | * 06/16/00 A. Mallick added csd/ssd/tssd for ia32 support | 13 | * 06/16/00 A. Mallick added csd/ssd/tssd for ia32 support |
14 | */ | 14 | */ |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | #include <asm/intrinsics.h> | 17 | #include <asm/intrinsics.h> |
19 | #include <asm/kregs.h> | 18 | #include <asm/kregs.h> |
diff --git a/include/asm-ia64/ptrace.h b/include/asm-ia64/ptrace.h index 9471cdc3f4c0..415abb23b210 100644 --- a/include/asm-ia64/ptrace.h +++ b/include/asm-ia64/ptrace.h | |||
@@ -54,7 +54,6 @@ | |||
54 | * This is because ar.ec is saved as part of ar.pfs. | 54 | * This is because ar.ec is saved as part of ar.pfs. |
55 | */ | 55 | */ |
56 | 56 | ||
57 | #include <linux/config.h> | ||
58 | 57 | ||
59 | #include <asm/fpu.h> | 58 | #include <asm/fpu.h> |
60 | #ifndef ASM_OFFSETS_C | 59 | #ifndef ASM_OFFSETS_C |
diff --git a/include/asm-ia64/smp.h b/include/asm-ia64/smp.h index a3914352c995..719ff309ce09 100644 --- a/include/asm-ia64/smp.h +++ b/include/asm-ia64/smp.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASM_IA64_SMP_H | 10 | #ifndef _ASM_IA64_SMP_H |
11 | #define _ASM_IA64_SMP_H | 11 | #define _ASM_IA64_SMP_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/init.h> | 13 | #include <linux/init.h> |
15 | #include <linux/threads.h> | 14 | #include <linux/threads.h> |
16 | #include <linux/kernel.h> | 15 | #include <linux/kernel.h> |
diff --git a/include/asm-ia64/sn/intr.h b/include/asm-ia64/sn/intr.h index 60a51a406eec..12b54ddb06be 100644 --- a/include/asm-ia64/sn/intr.h +++ b/include/asm-ia64/sn/intr.h | |||
@@ -10,6 +10,7 @@ | |||
10 | #define _ASM_IA64_SN_INTR_H | 10 | #define _ASM_IA64_SN_INTR_H |
11 | 11 | ||
12 | #include <linux/rcupdate.h> | 12 | #include <linux/rcupdate.h> |
13 | #include <asm/sn/types.h> | ||
13 | 14 | ||
14 | #define SGI_UART_VECTOR 0xe9 | 15 | #define SGI_UART_VECTOR 0xe9 |
15 | 16 | ||
@@ -40,6 +41,7 @@ struct sn_irq_info { | |||
40 | int irq_cpuid; /* kernel logical cpuid */ | 41 | int irq_cpuid; /* kernel logical cpuid */ |
41 | int irq_irq; /* the IRQ number */ | 42 | int irq_irq; /* the IRQ number */ |
42 | int irq_int_bit; /* Bridge interrupt pin */ | 43 | int irq_int_bit; /* Bridge interrupt pin */ |
44 | /* <0 means MSI */ | ||
43 | u64 irq_xtalkaddr; /* xtalkaddr IRQ is sent to */ | 45 | u64 irq_xtalkaddr; /* xtalkaddr IRQ is sent to */ |
44 | int irq_bridge_type;/* pciio asic type (pciio.h) */ | 46 | int irq_bridge_type;/* pciio asic type (pciio.h) */ |
45 | void *irq_bridge; /* bridge generating irq */ | 47 | void *irq_bridge; /* bridge generating irq */ |
@@ -53,6 +55,12 @@ struct sn_irq_info { | |||
53 | }; | 55 | }; |
54 | 56 | ||
55 | extern void sn_send_IPI_phys(int, long, int, int); | 57 | extern void sn_send_IPI_phys(int, long, int, int); |
58 | extern u64 sn_intr_alloc(nasid_t, int, | ||
59 | struct sn_irq_info *, | ||
60 | int, nasid_t, int); | ||
61 | extern void sn_intr_free(nasid_t, int, struct sn_irq_info *); | ||
62 | extern struct sn_irq_info *sn_retarget_vector(struct sn_irq_info *, nasid_t, int); | ||
63 | extern struct list_head **sn_irq_lh; | ||
56 | 64 | ||
57 | #define CPU_VECTOR_TO_IRQ(cpuid,vector) (vector) | 65 | #define CPU_VECTOR_TO_IRQ(cpuid,vector) (vector) |
58 | 66 | ||
diff --git a/include/asm-ia64/sn/pcibr_provider.h b/include/asm-ia64/sn/pcibr_provider.h index 51260ab70d91..e3b0c3fe5eed 100644 --- a/include/asm-ia64/sn/pcibr_provider.h +++ b/include/asm-ia64/sn/pcibr_provider.h | |||
@@ -55,6 +55,7 @@ | |||
55 | #define PCI32_ATE_V (0x1 << 0) | 55 | #define PCI32_ATE_V (0x1 << 0) |
56 | #define PCI32_ATE_CO (0x1 << 1) | 56 | #define PCI32_ATE_CO (0x1 << 1) |
57 | #define PCI32_ATE_PREC (0x1 << 2) | 57 | #define PCI32_ATE_PREC (0x1 << 2) |
58 | #define PCI32_ATE_MSI (0x1 << 2) | ||
58 | #define PCI32_ATE_PREF (0x1 << 3) | 59 | #define PCI32_ATE_PREF (0x1 << 3) |
59 | #define PCI32_ATE_BAR (0x1 << 4) | 60 | #define PCI32_ATE_BAR (0x1 << 4) |
60 | #define PCI32_ATE_ADDR_SHFT 12 | 61 | #define PCI32_ATE_ADDR_SHFT 12 |
@@ -117,8 +118,8 @@ struct pcibus_info { | |||
117 | 118 | ||
118 | extern int pcibr_init_provider(void); | 119 | extern int pcibr_init_provider(void); |
119 | extern void *pcibr_bus_fixup(struct pcibus_bussoft *, struct pci_controller *); | 120 | extern void *pcibr_bus_fixup(struct pcibus_bussoft *, struct pci_controller *); |
120 | extern dma_addr_t pcibr_dma_map(struct pci_dev *, unsigned long, size_t); | 121 | extern dma_addr_t pcibr_dma_map(struct pci_dev *, unsigned long, size_t, int type); |
121 | extern dma_addr_t pcibr_dma_map_consistent(struct pci_dev *, unsigned long, size_t); | 122 | extern dma_addr_t pcibr_dma_map_consistent(struct pci_dev *, unsigned long, size_t, int type); |
122 | extern void pcibr_dma_unmap(struct pci_dev *, dma_addr_t, int); | 123 | extern void pcibr_dma_unmap(struct pci_dev *, dma_addr_t, int); |
123 | 124 | ||
124 | /* | 125 | /* |
diff --git a/include/asm-ia64/sn/pcibus_provider_defs.h b/include/asm-ia64/sn/pcibus_provider_defs.h index ce3f6c328241..8f7c83d0f6d3 100644 --- a/include/asm-ia64/sn/pcibus_provider_defs.h +++ b/include/asm-ia64/sn/pcibus_provider_defs.h | |||
@@ -3,7 +3,7 @@ | |||
3 | * License. See the file "COPYING" in the main directory of this archive | 3 | * License. See the file "COPYING" in the main directory of this archive |
4 | * for more details. | 4 | * for more details. |
5 | * | 5 | * |
6 | * Copyright (C) 1992 - 1997, 2000-2004 Silicon Graphics, Inc. All rights reserved. | 6 | * Copyright (C) 1992 - 1997, 2000-2005 Silicon Graphics, Inc. All rights reserved. |
7 | */ | 7 | */ |
8 | #ifndef _ASM_IA64_SN_PCI_PCIBUS_PROVIDER_H | 8 | #ifndef _ASM_IA64_SN_PCI_PCIBUS_PROVIDER_H |
9 | #define _ASM_IA64_SN_PCI_PCIBUS_PROVIDER_H | 9 | #define _ASM_IA64_SN_PCI_PCIBUS_PROVIDER_H |
@@ -45,13 +45,24 @@ struct pci_controller; | |||
45 | */ | 45 | */ |
46 | 46 | ||
47 | struct sn_pcibus_provider { | 47 | struct sn_pcibus_provider { |
48 | dma_addr_t (*dma_map)(struct pci_dev *, unsigned long, size_t); | 48 | dma_addr_t (*dma_map)(struct pci_dev *, unsigned long, size_t, int flags); |
49 | dma_addr_t (*dma_map_consistent)(struct pci_dev *, unsigned long, size_t); | 49 | dma_addr_t (*dma_map_consistent)(struct pci_dev *, unsigned long, size_t, int flags); |
50 | void (*dma_unmap)(struct pci_dev *, dma_addr_t, int); | 50 | void (*dma_unmap)(struct pci_dev *, dma_addr_t, int); |
51 | void * (*bus_fixup)(struct pcibus_bussoft *, struct pci_controller *); | 51 | void * (*bus_fixup)(struct pcibus_bussoft *, struct pci_controller *); |
52 | void (*force_interrupt)(struct sn_irq_info *); | 52 | void (*force_interrupt)(struct sn_irq_info *); |
53 | void (*target_interrupt)(struct sn_irq_info *); | 53 | void (*target_interrupt)(struct sn_irq_info *); |
54 | }; | 54 | }; |
55 | 55 | ||
56 | /* | ||
57 | * Flags used by the map interfaces | ||
58 | * bits 3:0 specifies format of passed in address | ||
59 | * bit 4 specifies that address is to be used for MSI | ||
60 | */ | ||
61 | |||
62 | #define SN_DMA_ADDRTYPE(x) ((x) & 0xf) | ||
63 | #define SN_DMA_ADDR_PHYS 1 /* address is an xio address. */ | ||
64 | #define SN_DMA_ADDR_XIO 2 /* address is phys memory */ | ||
65 | #define SN_DMA_MSI 0x10 /* Bus address is to be used for MSI */ | ||
66 | |||
56 | extern struct sn_pcibus_provider *sn_pci_provider[]; | 67 | extern struct sn_pcibus_provider *sn_pci_provider[]; |
57 | #endif /* _ASM_IA64_SN_PCI_PCIBUS_PROVIDER_H */ | 68 | #endif /* _ASM_IA64_SN_PCI_PCIBUS_PROVIDER_H */ |
diff --git a/include/asm-ia64/sn/simulator.h b/include/asm-ia64/sn/simulator.h index 16a48b5a039c..c3fd3eb25768 100644 --- a/include/asm-ia64/sn/simulator.h +++ b/include/asm-ia64/sn/simulator.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef _ASM_IA64_SN_SIMULATOR_H | 8 | #ifndef _ASM_IA64_SN_SIMULATOR_H |
9 | #define _ASM_IA64_SN_SIMULATOR_H | 9 | #define _ASM_IA64_SN_SIMULATOR_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | 11 | ||
13 | #define SNMAGIC 0xaeeeeeee8badbeefL | 12 | #define SNMAGIC 0xaeeeeeee8badbeefL |
14 | #define IS_MEDUSA() ({long sn; asm("mov %0=cpuid[%1]" : "=r"(sn) : "r"(2)); sn == SNMAGIC;}) | 13 | #define IS_MEDUSA() ({long sn; asm("mov %0=cpuid[%1]" : "=r"(sn) : "r"(2)); sn == SNMAGIC;}) |
diff --git a/include/asm-ia64/sn/sn_cpuid.h b/include/asm-ia64/sn/sn_cpuid.h index 749deb2ca6c1..a676dd9ace3e 100644 --- a/include/asm-ia64/sn/sn_cpuid.h +++ b/include/asm-ia64/sn/sn_cpuid.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_IA64_SN_SN_CPUID_H | 11 | #ifndef _ASM_IA64_SN_SN_CPUID_H |
12 | #define _ASM_IA64_SN_SN_CPUID_H | 12 | #define _ASM_IA64_SN_SN_CPUID_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/smp.h> | 14 | #include <linux/smp.h> |
16 | #include <asm/sn/addrs.h> | 15 | #include <asm/sn/addrs.h> |
17 | #include <asm/sn/pda.h> | 16 | #include <asm/sn/pda.h> |
diff --git a/include/asm-ia64/sn/sn_sal.h b/include/asm-ia64/sn/sn_sal.h index 51aca022cf39..8c865e43f609 100644 --- a/include/asm-ia64/sn/sn_sal.h +++ b/include/asm-ia64/sn/sn_sal.h | |||
@@ -12,7 +12,6 @@ | |||
12 | */ | 12 | */ |
13 | 13 | ||
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <asm/sal.h> | 15 | #include <asm/sal.h> |
17 | #include <asm/sn/sn_cpuid.h> | 16 | #include <asm/sn/sn_cpuid.h> |
18 | #include <asm/sn/arch.h> | 17 | #include <asm/sn/arch.h> |
diff --git a/include/asm-ia64/sn/tiocp.h b/include/asm-ia64/sn/tiocp.h index f47c08ab483c..e8ad0bb5b6c5 100644 --- a/include/asm-ia64/sn/tiocp.h +++ b/include/asm-ia64/sn/tiocp.h | |||
@@ -3,13 +3,14 @@ | |||
3 | * License. See the file "COPYING" in the main directory of this archive | 3 | * License. See the file "COPYING" in the main directory of this archive |
4 | * for more details. | 4 | * for more details. |
5 | * | 5 | * |
6 | * Copyright (C) 2003-2004 Silicon Graphics, Inc. All rights reserved. | 6 | * Copyright (C) 2003-2005 Silicon Graphics, Inc. All rights reserved. |
7 | */ | 7 | */ |
8 | #ifndef _ASM_IA64_SN_PCI_TIOCP_H | 8 | #ifndef _ASM_IA64_SN_PCI_TIOCP_H |
9 | #define _ASM_IA64_SN_PCI_TIOCP_H | 9 | #define _ASM_IA64_SN_PCI_TIOCP_H |
10 | 10 | ||
11 | #define TIOCP_HOST_INTR_ADDR 0x003FFFFFFFFFFFFFUL | 11 | #define TIOCP_HOST_INTR_ADDR 0x003FFFFFFFFFFFFFUL |
12 | #define TIOCP_PCI64_CMDTYPE_MEM (0x1ull << 60) | 12 | #define TIOCP_PCI64_CMDTYPE_MEM (0x1ull << 60) |
13 | #define TIOCP_PCI64_CMDTYPE_MSI (0x3ull << 60) | ||
13 | 14 | ||
14 | 15 | ||
15 | /***************************************************************************** | 16 | /***************************************************************************** |
diff --git a/include/asm-ia64/sn/xpc.h b/include/asm-ia64/sn/xpc.h index aa3b8ace9030..8406f1ef4caf 100644 --- a/include/asm-ia64/sn/xpc.h +++ b/include/asm-ia64/sn/xpc.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #define _ASM_IA64_SN_XPC_H | 15 | #define _ASM_IA64_SN_XPC_H |
16 | 16 | ||
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | #include <linux/interrupt.h> | 18 | #include <linux/interrupt.h> |
20 | #include <linux/sysctl.h> | 19 | #include <linux/sysctl.h> |
21 | #include <linux/device.h> | 20 | #include <linux/device.h> |
diff --git a/include/asm-ia64/string.h b/include/asm-ia64/string.h index 43502d3b57e5..85fd65c52a8c 100644 --- a/include/asm-ia64/string.h +++ b/include/asm-ia64/string.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * David Mosberger-Tang <davidm@hpl.hp.com> | 9 | * David Mosberger-Tang <davidm@hpl.hp.com> |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> /* remove this once we remove the A-step workaround... */ | ||
13 | 12 | ||
14 | #define __HAVE_ARCH_STRLEN 1 /* see arch/ia64/lib/strlen.S */ | 13 | #define __HAVE_ARCH_STRLEN 1 /* see arch/ia64/lib/strlen.S */ |
15 | #define __HAVE_ARCH_MEMSET 1 /* see arch/ia64/lib/memset.S */ | 14 | #define __HAVE_ARCH_MEMSET 1 /* see arch/ia64/lib/memset.S */ |
diff --git a/include/asm-ia64/system.h b/include/asm-ia64/system.h index 2f3620593687..65db43ce4de6 100644 --- a/include/asm-ia64/system.h +++ b/include/asm-ia64/system.h | |||
@@ -12,7 +12,6 @@ | |||
12 | * Copyright (C) 1999 Asit Mallick <asit.k.mallick@intel.com> | 12 | * Copyright (C) 1999 Asit Mallick <asit.k.mallick@intel.com> |
13 | * Copyright (C) 1999 Don Dugger <don.dugger@intel.com> | 13 | * Copyright (C) 1999 Don Dugger <don.dugger@intel.com> |
14 | */ | 14 | */ |
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | #include <asm/kregs.h> | 16 | #include <asm/kregs.h> |
18 | #include <asm/page.h> | 17 | #include <asm/page.h> |
diff --git a/include/asm-ia64/tlb.h b/include/asm-ia64/tlb.h index 834370b9dea1..26edcb750f9f 100644 --- a/include/asm-ia64/tlb.h +++ b/include/asm-ia64/tlb.h | |||
@@ -37,7 +37,6 @@ | |||
37 | * } | 37 | * } |
38 | * tlb_finish_mmu(tlb, start, end); // finish unmap for address space MM | 38 | * tlb_finish_mmu(tlb, start, end); // finish unmap for address space MM |
39 | */ | 39 | */ |
40 | #include <linux/config.h> | ||
41 | #include <linux/mm.h> | 40 | #include <linux/mm.h> |
42 | #include <linux/pagemap.h> | 41 | #include <linux/pagemap.h> |
43 | #include <linux/swap.h> | 42 | #include <linux/swap.h> |
diff --git a/include/asm-ia64/tlbflush.h b/include/asm-ia64/tlbflush.h index a35b323bae4c..cf9acb9bb1fb 100644 --- a/include/asm-ia64/tlbflush.h +++ b/include/asm-ia64/tlbflush.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * David Mosberger-Tang <davidm@hpl.hp.com> | 6 | * David Mosberger-Tang <davidm@hpl.hp.com> |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | #include <linux/mm.h> | 10 | #include <linux/mm.h> |
12 | 11 | ||
diff --git a/include/asm-ia64/unistd.h b/include/asm-ia64/unistd.h index 7107763168bf..632f2eedf72c 100644 --- a/include/asm-ia64/unistd.h +++ b/include/asm-ia64/unistd.h | |||
@@ -294,7 +294,6 @@ | |||
294 | 294 | ||
295 | #ifdef __KERNEL__ | 295 | #ifdef __KERNEL__ |
296 | 296 | ||
297 | #include <linux/config.h> | ||
298 | 297 | ||
299 | #define NR_syscalls 279 /* length of syscall table */ | 298 | #define NR_syscalls 279 /* length of syscall table */ |
300 | 299 | ||
diff --git a/include/asm-ia64/vga.h b/include/asm-ia64/vga.h index 091177cda223..02184ecd8208 100644 --- a/include/asm-ia64/vga.h +++ b/include/asm-ia64/vga.h | |||
@@ -17,7 +17,7 @@ | |||
17 | extern unsigned long vga_console_iobase; | 17 | extern unsigned long vga_console_iobase; |
18 | extern unsigned long vga_console_membase; | 18 | extern unsigned long vga_console_membase; |
19 | 19 | ||
20 | #define VGA_MAP_MEM(x) ((unsigned long) ioremap_nocache(vga_console_membase + (x), 0)) | 20 | #define VGA_MAP_MEM(x,s) ((unsigned long) ioremap_nocache(vga_console_membase + (x), s)) |
21 | 21 | ||
22 | #define vga_readb(x) (*(x)) | 22 | #define vga_readb(x) (*(x)) |
23 | #define vga_writeb(x,y) (*(y) = (x)) | 23 | #define vga_writeb(x,y) (*(y) = (x)) |
diff --git a/include/asm-m32r/assembler.h b/include/asm-m32r/assembler.h index 1a1aa17edd33..47041d19d4a8 100644 --- a/include/asm-m32r/assembler.h +++ b/include/asm-m32r/assembler.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * This file contains M32R architecture specific macro definitions. | 9 | * This file contains M32R architecture specific macro definitions. |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | #ifndef __STR | 13 | #ifndef __STR |
15 | #ifdef __ASSEMBLY__ | 14 | #ifdef __ASSEMBLY__ |
diff --git a/include/asm-m32r/atomic.h b/include/asm-m32r/atomic.h index 3122fe106f05..f5a7d7301c72 100644 --- a/include/asm-m32r/atomic.h +++ b/include/asm-m32r/atomic.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * Copyright (C) 2004 Hirokazu Takata <takata at linux-m32r.org> | 9 | * Copyright (C) 2004 Hirokazu Takata <takata at linux-m32r.org> |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <asm/assembler.h> | 12 | #include <asm/assembler.h> |
14 | #include <asm/system.h> | 13 | #include <asm/system.h> |
15 | 14 | ||
diff --git a/include/asm-m32r/bitops.h b/include/asm-m32r/bitops.h index 902a366101a5..66ab672162cd 100644 --- a/include/asm-m32r/bitops.h +++ b/include/asm-m32r/bitops.h | |||
@@ -11,7 +11,6 @@ | |||
11 | * Copyright (C) 2004 Hirokazu Takata <takata at linux-m32r.org> | 11 | * Copyright (C) 2004 Hirokazu Takata <takata at linux-m32r.org> |
12 | */ | 12 | */ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/compiler.h> | 14 | #include <linux/compiler.h> |
16 | #include <asm/assembler.h> | 15 | #include <asm/assembler.h> |
17 | #include <asm/system.h> | 16 | #include <asm/system.h> |
diff --git a/include/asm-m32r/cacheflush.h b/include/asm-m32r/cacheflush.h index e57427b6e249..8b261b49149e 100644 --- a/include/asm-m32r/cacheflush.h +++ b/include/asm-m32r/cacheflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_M32R_CACHEFLUSH_H | 1 | #ifndef _ASM_M32R_CACHEFLUSH_H |
2 | #define _ASM_M32R_CACHEFLUSH_H | 2 | #define _ASM_M32R_CACHEFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | 5 | ||
7 | extern void _flush_cache_all(void); | 6 | extern void _flush_cache_all(void); |
diff --git a/include/asm-m32r/hardirq.h b/include/asm-m32r/hardirq.h index 5da830ec1587..cb8aa762f235 100644 --- a/include/asm-m32r/hardirq.h +++ b/include/asm-m32r/hardirq.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #ifndef __ASM_HARDIRQ_H | 2 | #ifndef __ASM_HARDIRQ_H |
3 | #define __ASM_HARDIRQ_H | 3 | #define __ASM_HARDIRQ_H |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | #include <linux/threads.h> | 5 | #include <linux/threads.h> |
7 | #include <linux/irq.h> | 6 | #include <linux/irq.h> |
8 | 7 | ||
diff --git a/include/asm-m32r/ide.h b/include/asm-m32r/ide.h index f7aa96970d18..219a0f74eff3 100644 --- a/include/asm-m32r/ide.h +++ b/include/asm-m32r/ide.h | |||
@@ -15,7 +15,6 @@ | |||
15 | 15 | ||
16 | #ifdef __KERNEL__ | 16 | #ifdef __KERNEL__ |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | 18 | ||
20 | #ifndef MAX_HWIFS | 19 | #ifndef MAX_HWIFS |
21 | # ifdef CONFIG_BLK_DEV_IDEPCI | 20 | # ifdef CONFIG_BLK_DEV_IDEPCI |
diff --git a/include/asm-m32r/irq.h b/include/asm-m32r/irq.h index ca943954572a..2f93f4743add 100644 --- a/include/asm-m32r/irq.h +++ b/include/asm-m32r/irq.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #ifndef _ASM_M32R_IRQ_H | 2 | #ifndef _ASM_M32R_IRQ_H |
3 | #define _ASM_M32R_IRQ_H | 3 | #define _ASM_M32R_IRQ_H |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | 5 | ||
7 | #if defined(CONFIG_PLAT_M32700UT_Alpha) || defined(CONFIG_PLAT_USRV) | 6 | #if defined(CONFIG_PLAT_M32700UT_Alpha) || defined(CONFIG_PLAT_USRV) |
8 | /* | 7 | /* |
diff --git a/include/asm-m32r/kmap_types.h b/include/asm-m32r/kmap_types.h index 7429591010b6..0524d89edb0f 100644 --- a/include/asm-m32r/kmap_types.h +++ b/include/asm-m32r/kmap_types.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | /* Dummy header just to define km_type. */ | 4 | /* Dummy header just to define km_type. */ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | #ifdef CONFIG_DEBUG_HIGHMEM | 7 | #ifdef CONFIG_DEBUG_HIGHMEM |
9 | # define D(n) __KM_FENCE_##n , | 8 | # define D(n) __KM_FENCE_##n , |
diff --git a/include/asm-m32r/m32104ut/m32104ut_pld.h b/include/asm-m32r/m32104ut/m32104ut_pld.h index a4eac20553df..6ba4ddf7dcf7 100644 --- a/include/asm-m32r/m32104ut/m32104ut_pld.h +++ b/include/asm-m32r/m32104ut/m32104ut_pld.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #ifndef _M32104UT_M32104UT_PLD_H | 15 | #ifndef _M32104UT_M32104UT_PLD_H |
16 | #define _M32104UT_M32104UT_PLD_H | 16 | #define _M32104UT_M32104UT_PLD_H |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | 18 | ||
20 | #if defined(CONFIG_PLAT_M32104UT) | 19 | #if defined(CONFIG_PLAT_M32104UT) |
21 | #define PLD_PLAT_BASE 0x02c00000 | 20 | #define PLD_PLAT_BASE 0x02c00000 |
diff --git a/include/asm-m32r/m32700ut/m32700ut_lan.h b/include/asm-m32r/m32700ut/m32700ut_lan.h index 50545ec9c42c..c050b19e8101 100644 --- a/include/asm-m32r/m32700ut/m32700ut_lan.h +++ b/include/asm-m32r/m32700ut/m32700ut_lan.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #ifndef _M32700UT_M32700UT_LAN_H | 15 | #ifndef _M32700UT_M32700UT_LAN_H |
16 | #define _M32700UT_M32700UT_LAN_H | 16 | #define _M32700UT_M32700UT_LAN_H |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | 18 | ||
20 | #ifndef __ASSEMBLY__ | 19 | #ifndef __ASSEMBLY__ |
21 | /* | 20 | /* |
diff --git a/include/asm-m32r/m32700ut/m32700ut_lcd.h b/include/asm-m32r/m32700ut/m32700ut_lcd.h index ede6c77bd5e6..4da4e822e2f3 100644 --- a/include/asm-m32r/m32700ut/m32700ut_lcd.h +++ b/include/asm-m32r/m32700ut/m32700ut_lcd.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #ifndef _M32700UT_M32700UT_LCD_H | 15 | #ifndef _M32700UT_M32700UT_LCD_H |
16 | #define _M32700UT_M32700UT_LCD_H | 16 | #define _M32700UT_M32700UT_LCD_H |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | 18 | ||
20 | #ifndef __ASSEMBLY__ | 19 | #ifndef __ASSEMBLY__ |
21 | /* | 20 | /* |
diff --git a/include/asm-m32r/m32700ut/m32700ut_pld.h b/include/asm-m32r/m32700ut/m32700ut_pld.h index f5e479486696..f35f9159acff 100644 --- a/include/asm-m32r/m32700ut/m32700ut_pld.h +++ b/include/asm-m32r/m32700ut/m32700ut_pld.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #ifndef _M32700UT_M32700UT_PLD_H | 15 | #ifndef _M32700UT_M32700UT_PLD_H |
16 | #define _M32700UT_M32700UT_PLD_H | 16 | #define _M32700UT_M32700UT_PLD_H |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | 18 | ||
20 | #if defined(CONFIG_PLAT_M32700UT_Alpha) | 19 | #if defined(CONFIG_PLAT_M32700UT_Alpha) |
21 | #define PLD_PLAT_BASE 0x08c00000 | 20 | #define PLD_PLAT_BASE 0x08c00000 |
diff --git a/include/asm-m32r/m32r.h b/include/asm-m32r/m32r.h index b133ca61acf1..decfc59907c7 100644 --- a/include/asm-m32r/m32r.h +++ b/include/asm-m32r/m32r.h | |||
@@ -7,7 +7,6 @@ | |||
7 | * Copyright (C) 2003, 2004 Renesas Technology Corp. | 7 | * Copyright (C) 2003, 2004 Renesas Technology Corp. |
8 | */ | 8 | */ |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | 10 | ||
12 | /* Chip type */ | 11 | /* Chip type */ |
13 | #if defined(CONFIG_CHIP_XNUX_MP) || defined(CONFIG_CHIP_XNUX2_MP) | 12 | #if defined(CONFIG_CHIP_XNUX_MP) || defined(CONFIG_CHIP_XNUX2_MP) |
diff --git a/include/asm-m32r/mmu.h b/include/asm-m32r/mmu.h index 9c00eb78ee50..cf3f6d78ac66 100644 --- a/include/asm-m32r/mmu.h +++ b/include/asm-m32r/mmu.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_M32R_MMU_H | 1 | #ifndef _ASM_M32R_MMU_H |
2 | #define _ASM_M32R_MMU_H | 2 | #define _ASM_M32R_MMU_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #if !defined(CONFIG_MMU) | 5 | #if !defined(CONFIG_MMU) |
7 | typedef struct { | 6 | typedef struct { |
diff --git a/include/asm-m32r/mmu_context.h b/include/asm-m32r/mmu_context.h index 3634c5361a9b..542302eb6bcb 100644 --- a/include/asm-m32r/mmu_context.h +++ b/include/asm-m32r/mmu_context.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | #include <asm/m32r.h> | 7 | #include <asm/m32r.h> |
9 | 8 | ||
@@ -15,7 +14,6 @@ | |||
15 | 14 | ||
16 | #ifndef __ASSEMBLY__ | 15 | #ifndef __ASSEMBLY__ |
17 | 16 | ||
18 | #include <linux/config.h> | ||
19 | #include <asm/atomic.h> | 17 | #include <asm/atomic.h> |
20 | #include <asm/pgalloc.h> | 18 | #include <asm/pgalloc.h> |
21 | #include <asm/mmu.h> | 19 | #include <asm/mmu.h> |
diff --git a/include/asm-m32r/opsput/opsput_lan.h b/include/asm-m32r/opsput/opsput_lan.h index 7a2a839eedab..61948296f445 100644 --- a/include/asm-m32r/opsput/opsput_lan.h +++ b/include/asm-m32r/opsput/opsput_lan.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #ifndef _OPSPUT_OPSPUT_LAN_H | 15 | #ifndef _OPSPUT_OPSPUT_LAN_H |
16 | #define _OPSPUT_OPSPUT_LAN_H | 16 | #define _OPSPUT_OPSPUT_LAN_H |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | 18 | ||
20 | #ifndef __ASSEMBLY__ | 19 | #ifndef __ASSEMBLY__ |
21 | /* | 20 | /* |
diff --git a/include/asm-m32r/opsput/opsput_lcd.h b/include/asm-m32r/opsput/opsput_lcd.h index 3a883e3d7187..44cfd7fe2d88 100644 --- a/include/asm-m32r/opsput/opsput_lcd.h +++ b/include/asm-m32r/opsput/opsput_lcd.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #ifndef _OPSPUT_OPSPUT_LCD_H | 15 | #ifndef _OPSPUT_OPSPUT_LCD_H |
16 | #define _OPSPUT_OPSPUT_LCD_H | 16 | #define _OPSPUT_OPSPUT_LCD_H |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | 18 | ||
20 | #ifndef __ASSEMBLY__ | 19 | #ifndef __ASSEMBLY__ |
21 | /* | 20 | /* |
diff --git a/include/asm-m32r/opsput/opsput_pld.h b/include/asm-m32r/opsput/opsput_pld.h index 2018e6925035..46296fe1ec1a 100644 --- a/include/asm-m32r/opsput/opsput_pld.h +++ b/include/asm-m32r/opsput/opsput_pld.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #ifndef _OPSPUT_OPSPUT_PLD_H | 15 | #ifndef _OPSPUT_OPSPUT_PLD_H |
16 | #define _OPSPUT_OPSPUT_PLD_H | 16 | #define _OPSPUT_OPSPUT_PLD_H |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | 18 | ||
20 | #define PLD_PLAT_BASE 0x1cc00000 | 19 | #define PLD_PLAT_BASE 0x1cc00000 |
21 | 20 | ||
diff --git a/include/asm-m32r/page.h b/include/asm-m32r/page.h index 9ddbc087dbc5..9688be003620 100644 --- a/include/asm-m32r/page.h +++ b/include/asm-m32r/page.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_M32R_PAGE_H | 1 | #ifndef _ASM_M32R_PAGE_H |
2 | #define _ASM_M32R_PAGE_H | 2 | #define _ASM_M32R_PAGE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* PAGE_SHIFT determines the page size */ | 5 | /* PAGE_SHIFT determines the page size */ |
7 | #define PAGE_SHIFT 12 | 6 | #define PAGE_SHIFT 12 |
diff --git a/include/asm-m32r/pgalloc.h b/include/asm-m32r/pgalloc.h index 6da309b6fda7..e09a86c3cadf 100644 --- a/include/asm-m32r/pgalloc.h +++ b/include/asm-m32r/pgalloc.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | /* $Id$ */ | 4 | /* $Id$ */ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <linux/mm.h> | 6 | #include <linux/mm.h> |
8 | 7 | ||
9 | #include <asm/io.h> | 8 | #include <asm/io.h> |
diff --git a/include/asm-m32r/pgtable-2level.h b/include/asm-m32r/pgtable-2level.h index 861727c20e8f..be0f167e344a 100644 --- a/include/asm-m32r/pgtable-2level.h +++ b/include/asm-m32r/pgtable-2level.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | /* | 7 | /* |
9 | * traditional M32R two-level paging structure: | 8 | * traditional M32R two-level paging structure: |
diff --git a/include/asm-m32r/pgtable.h b/include/asm-m32r/pgtable.h index 75740debcd01..1983b7f4527a 100644 --- a/include/asm-m32r/pgtable.h +++ b/include/asm-m32r/pgtable.h | |||
@@ -20,7 +20,6 @@ | |||
20 | 20 | ||
21 | #ifndef __ASSEMBLY__ | 21 | #ifndef __ASSEMBLY__ |
22 | 22 | ||
23 | #include <linux/config.h> | ||
24 | #include <linux/threads.h> | 23 | #include <linux/threads.h> |
25 | #include <asm/processor.h> | 24 | #include <asm/processor.h> |
26 | #include <asm/addrspace.h> | 25 | #include <asm/addrspace.h> |
diff --git a/include/asm-m32r/processor.h b/include/asm-m32r/processor.h index 09fd1813e780..32755bf136de 100644 --- a/include/asm-m32r/processor.h +++ b/include/asm-m32r/processor.h | |||
@@ -14,7 +14,6 @@ | |||
14 | */ | 14 | */ |
15 | 15 | ||
16 | #include <linux/kernel.h> | 16 | #include <linux/kernel.h> |
17 | #include <linux/config.h> | ||
18 | #include <asm/cache.h> | 17 | #include <asm/cache.h> |
19 | #include <asm/ptrace.h> /* pt_regs */ | 18 | #include <asm/ptrace.h> /* pt_regs */ |
20 | 19 | ||
diff --git a/include/asm-m32r/ptrace.h b/include/asm-m32r/ptrace.h index 53c792452dfc..a07fa90314d2 100644 --- a/include/asm-m32r/ptrace.h +++ b/include/asm-m32r/ptrace.h | |||
@@ -12,7 +12,6 @@ | |||
12 | * Copyright (C) 2001-2002, 2004 Hirokazu Takata <takata at linux-m32r.org> | 12 | * Copyright (C) 2001-2002, 2004 Hirokazu Takata <takata at linux-m32r.org> |
13 | */ | 13 | */ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <asm/m32r.h> /* M32R_PSW_BSM, M32R_PSW_BPM */ | 15 | #include <asm/m32r.h> /* M32R_PSW_BSM, M32R_PSW_BPM */ |
17 | 16 | ||
18 | /* 0 - 13 are integer registers (general purpose registers). */ | 17 | /* 0 - 13 are integer registers (general purpose registers). */ |
diff --git a/include/asm-m32r/rtc.h b/include/asm-m32r/rtc.h index ec3cdf666c68..6b2b837c5978 100644 --- a/include/asm-m32r/rtc.h +++ b/include/asm-m32r/rtc.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #define __RTC_H__ | 4 | #define __RTC_H__ |
5 | 5 | ||
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | /* Dallas DS1302 clock/calendar register numbers. */ | 8 | /* Dallas DS1302 clock/calendar register numbers. */ |
10 | # define RTC_SECONDS 0 | 9 | # define RTC_SECONDS 0 |
diff --git a/include/asm-m32r/semaphore.h b/include/asm-m32r/semaphore.h index 81750edc8916..41e45d7b87ef 100644 --- a/include/asm-m32r/semaphore.h +++ b/include/asm-m32r/semaphore.h | |||
@@ -12,7 +12,6 @@ | |||
12 | * Copyright (C) 2004, 2006 Hirokazu Takata <takata at linux-m32r.org> | 12 | * Copyright (C) 2004, 2006 Hirokazu Takata <takata at linux-m32r.org> |
13 | */ | 13 | */ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <linux/wait.h> | 15 | #include <linux/wait.h> |
17 | #include <linux/rwsem.h> | 16 | #include <linux/rwsem.h> |
18 | #include <asm/assembler.h> | 17 | #include <asm/assembler.h> |
diff --git a/include/asm-m32r/serial.h b/include/asm-m32r/serial.h index 1bf480f58493..5ac244c72f15 100644 --- a/include/asm-m32r/serial.h +++ b/include/asm-m32r/serial.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | /* include/asm-m32r/serial.h */ | 4 | /* include/asm-m32r/serial.h */ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | #define BASE_BAUD 115200 | 7 | #define BASE_BAUD 115200 |
9 | 8 | ||
diff --git a/include/asm-m32r/sigcontext.h b/include/asm-m32r/sigcontext.h index 942b8a30937d..73025c0c41a1 100644 --- a/include/asm-m32r/sigcontext.h +++ b/include/asm-m32r/sigcontext.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | /* $Id$ */ | 4 | /* $Id$ */ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | struct sigcontext { | 7 | struct sigcontext { |
9 | /* CPU registers */ | 8 | /* CPU registers */ |
diff --git a/include/asm-m32r/smp.h b/include/asm-m32r/smp.h index 1184293e5712..650d2558c304 100644 --- a/include/asm-m32r/smp.h +++ b/include/asm-m32r/smp.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | /* $Id$ */ | 4 | /* $Id$ */ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | #ifdef CONFIG_SMP | 7 | #ifdef CONFIG_SMP |
9 | #ifndef __ASSEMBLY__ | 8 | #ifndef __ASSEMBLY__ |
diff --git a/include/asm-m32r/spinlock.h b/include/asm-m32r/spinlock.h index 7de7def28da9..f94c1a673569 100644 --- a/include/asm-m32r/spinlock.h +++ b/include/asm-m32r/spinlock.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * Copyright (C) 2004 Hirokazu Takata <takata at linux-m32r.org> | 9 | * Copyright (C) 2004 Hirokazu Takata <takata at linux-m32r.org> |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> /* CONFIG_DEBUG_SPINLOCK, CONFIG_SMP */ | ||
13 | #include <linux/compiler.h> | 12 | #include <linux/compiler.h> |
14 | #include <asm/atomic.h> | 13 | #include <asm/atomic.h> |
15 | #include <asm/page.h> | 14 | #include <asm/page.h> |
diff --git a/include/asm-m32r/system.h b/include/asm-m32r/system.h index e55013f378e5..33567e8bfe6b 100644 --- a/include/asm-m32r/system.h +++ b/include/asm-m32r/system.h | |||
@@ -10,7 +10,6 @@ | |||
10 | * Copyright (C) 2004, 2006 Hirokazu Takata <takata at linux-m32r.org> | 10 | * Copyright (C) 2004, 2006 Hirokazu Takata <takata at linux-m32r.org> |
11 | */ | 11 | */ |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <asm/assembler.h> | 13 | #include <asm/assembler.h> |
15 | 14 | ||
16 | #ifdef __KERNEL__ | 15 | #ifdef __KERNEL__ |
diff --git a/include/asm-m32r/timex.h b/include/asm-m32r/timex.h index abf12e7ffbf3..e89bfd17db51 100644 --- a/include/asm-m32r/timex.h +++ b/include/asm-m32r/timex.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * m32r architecture timex specifications | 9 | * m32r architecture timex specifications |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | #define CLOCK_TICK_RATE (CONFIG_BUS_CLOCK / CONFIG_TIMER_DIVIDE) | 13 | #define CLOCK_TICK_RATE (CONFIG_BUS_CLOCK / CONFIG_TIMER_DIVIDE) |
15 | #define CLOCK_TICK_FACTOR 20 /* Factor of both 1000000 and CLOCK_TICK_RATE */ | 14 | #define CLOCK_TICK_FACTOR 20 /* Factor of both 1000000 and CLOCK_TICK_RATE */ |
diff --git a/include/asm-m32r/tlbflush.h b/include/asm-m32r/tlbflush.h index bc7c407dbd92..ae4494960593 100644 --- a/include/asm-m32r/tlbflush.h +++ b/include/asm-m32r/tlbflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_M32R_TLBFLUSH_H | 1 | #ifndef _ASM_M32R_TLBFLUSH_H |
2 | #define _ASM_M32R_TLBFLUSH_H | 2 | #define _ASM_M32R_TLBFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/m32r.h> | 4 | #include <asm/m32r.h> |
6 | 5 | ||
7 | /* | 6 | /* |
diff --git a/include/asm-m32r/uaccess.h b/include/asm-m32r/uaccess.h index 819cc28a94f7..26e978c7e3b4 100644 --- a/include/asm-m32r/uaccess.h +++ b/include/asm-m32r/uaccess.h | |||
@@ -11,7 +11,6 @@ | |||
11 | /* | 11 | /* |
12 | * User space memory access functions | 12 | * User space memory access functions |
13 | */ | 13 | */ |
14 | #include <linux/config.h> | ||
15 | #include <linux/errno.h> | 14 | #include <linux/errno.h> |
16 | #include <linux/thread_info.h> | 15 | #include <linux/thread_info.h> |
17 | #include <asm/page.h> | 16 | #include <asm/page.h> |
diff --git a/include/asm-m32r/unistd.h b/include/asm-m32r/unistd.h index be0eb014c3b0..cc31790d8077 100644 --- a/include/asm-m32r/unistd.h +++ b/include/asm-m32r/unistd.h | |||
@@ -295,6 +295,8 @@ | |||
295 | #define __NR_kexec_load 283 | 295 | #define __NR_kexec_load 283 |
296 | #define __NR_waitid 284 | 296 | #define __NR_waitid 284 |
297 | 297 | ||
298 | #ifdef __KERNEL__ | ||
299 | |||
298 | #define NR_syscalls 285 | 300 | #define NR_syscalls 285 |
299 | 301 | ||
300 | /* user-visible error numbers are in the range -1 - -124: see | 302 | /* user-visible error numbers are in the range -1 - -124: see |
@@ -405,7 +407,6 @@ __asm__ __volatile__ (\ | |||
405 | __syscall_return(type,__res); \ | 407 | __syscall_return(type,__res); \ |
406 | } | 408 | } |
407 | 409 | ||
408 | #ifdef __KERNEL__ | ||
409 | #define __ARCH_WANT_IPC_PARSE_VERSION | 410 | #define __ARCH_WANT_IPC_PARSE_VERSION |
410 | #define __ARCH_WANT_STAT64 | 411 | #define __ARCH_WANT_STAT64 |
411 | #define __ARCH_WANT_SYS_ALARM | 412 | #define __ARCH_WANT_SYS_ALARM |
@@ -421,7 +422,6 @@ __syscall_return(type,__res); \ | |||
421 | #define __ARCH_WANT_SYS_OLD_GETRLIMIT /*will be unused*/ | 422 | #define __ARCH_WANT_SYS_OLD_GETRLIMIT /*will be unused*/ |
422 | #define __ARCH_WANT_SYS_OLDUMOUNT | 423 | #define __ARCH_WANT_SYS_OLDUMOUNT |
423 | #define __ARCH_WANT_SYS_RT_SIGACTION | 424 | #define __ARCH_WANT_SYS_RT_SIGACTION |
424 | #endif | ||
425 | 425 | ||
426 | #ifdef __KERNEL_SYSCALLS__ | 426 | #ifdef __KERNEL_SYSCALLS__ |
427 | 427 | ||
@@ -470,4 +470,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
470 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 470 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
471 | #endif | 471 | #endif |
472 | 472 | ||
473 | #endif /* __KERNEL__ */ | ||
473 | #endif /* _ASM_M32R_UNISTD_H */ | 474 | #endif /* _ASM_M32R_UNISTD_H */ |
diff --git a/include/asm-m32r/vga.h b/include/asm-m32r/vga.h index d0f4b6eed7a3..533163447cc9 100644 --- a/include/asm-m32r/vga.h +++ b/include/asm-m32r/vga.h | |||
@@ -14,7 +14,7 @@ | |||
14 | * access the videoram directly without any black magic. | 14 | * access the videoram directly without any black magic. |
15 | */ | 15 | */ |
16 | 16 | ||
17 | #define VGA_MAP_MEM(x) (unsigned long)phys_to_virt(x) | 17 | #define VGA_MAP_MEM(x,s) (unsigned long)phys_to_virt(x) |
18 | 18 | ||
19 | #define vga_readb(x) (*(x)) | 19 | #define vga_readb(x) (*(x)) |
20 | #define vga_writeb(x,y) (*(y) = (x)) | 20 | #define vga_writeb(x,y) (*(y) = (x)) |
diff --git a/include/asm-m68k/atomic.h b/include/asm-m68k/atomic.h index 732d696d31a6..d5eed64cb833 100644 --- a/include/asm-m68k/atomic.h +++ b/include/asm-m68k/atomic.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ARCH_M68K_ATOMIC__ | 1 | #ifndef __ARCH_M68K_ATOMIC__ |
2 | #define __ARCH_M68K_ATOMIC__ | 2 | #define __ARCH_M68K_ATOMIC__ |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #include <asm/system.h> /* local_irq_XXX() */ | 5 | #include <asm/system.h> /* local_irq_XXX() */ |
7 | 6 | ||
diff --git a/include/asm-m68k/bug.h b/include/asm-m68k/bug.h index 072ce274d537..7b60776cc966 100644 --- a/include/asm-m68k/bug.h +++ b/include/asm-m68k/bug.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _M68K_BUG_H | 1 | #ifndef _M68K_BUG_H |
2 | #define _M68K_BUG_H | 2 | #define _M68K_BUG_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_BUG | 5 | #ifdef CONFIG_BUG |
7 | #ifdef CONFIG_DEBUG_BUGVERBOSE | 6 | #ifdef CONFIG_DEBUG_BUGVERBOSE |
diff --git a/include/asm-m68k/dma-mapping.h b/include/asm-m68k/dma-mapping.h index b1920c703d82..dffd59cf1364 100644 --- a/include/asm-m68k/dma-mapping.h +++ b/include/asm-m68k/dma-mapping.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _M68K_DMA_MAPPING_H | 1 | #ifndef _M68K_DMA_MAPPING_H |
2 | #define _M68K_DMA_MAPPING_H | 2 | #define _M68K_DMA_MAPPING_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_PCI | 5 | #ifdef CONFIG_PCI |
7 | #include <asm-generic/dma-mapping.h> | 6 | #include <asm-generic/dma-mapping.h> |
diff --git a/include/asm-m68k/dma.h b/include/asm-m68k/dma.h index d5266a886226..d0c9e61e57b4 100644 --- a/include/asm-m68k/dma.h +++ b/include/asm-m68k/dma.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _M68K_DMA_H | 1 | #ifndef _M68K_DMA_H |
2 | #define _M68K_DMA_H 1 | 2 | #define _M68K_DMA_H 1 |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* it's useless on the m68k, but unfortunately needed by the new | 5 | /* it's useless on the m68k, but unfortunately needed by the new |
7 | bootmem allocator (but this should do it for this) */ | 6 | bootmem allocator (but this should do it for this) */ |
diff --git a/include/asm-m68k/dvma.h b/include/asm-m68k/dvma.h index 5978f87b0a8a..e1112de5a5e3 100644 --- a/include/asm-m68k/dvma.h +++ b/include/asm-m68k/dvma.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef __M68K_DVMA_H | 9 | #ifndef __M68K_DVMA_H |
10 | #define __M68K_DVMA_H | 10 | #define __M68K_DVMA_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | #define DVMA_PAGE_SHIFT 13 | 13 | #define DVMA_PAGE_SHIFT 13 |
15 | #define DVMA_PAGE_SIZE (1UL << DVMA_PAGE_SHIFT) | 14 | #define DVMA_PAGE_SIZE (1UL << DVMA_PAGE_SHIFT) |
diff --git a/include/asm-m68k/elf.h b/include/asm-m68k/elf.h index 38bf8347f14d..eb63b85f9336 100644 --- a/include/asm-m68k/elf.h +++ b/include/asm-m68k/elf.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * ELF register definitions.. | 5 | * ELF register definitions.. |
6 | */ | 6 | */ |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | #include <asm/ptrace.h> | 8 | #include <asm/ptrace.h> |
10 | #include <asm/user.h> | 9 | #include <asm/user.h> |
11 | 10 | ||
diff --git a/include/asm-m68k/entry.h b/include/asm-m68k/entry.h index 0396495cd97d..f8f6b185d793 100644 --- a/include/asm-m68k/entry.h +++ b/include/asm-m68k/entry.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __M68K_ENTRY_H | 1 | #ifndef __M68K_ENTRY_H |
2 | #define __M68K_ENTRY_H | 2 | #define __M68K_ENTRY_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/setup.h> | 4 | #include <asm/setup.h> |
6 | #include <asm/page.h> | 5 | #include <asm/page.h> |
7 | 6 | ||
diff --git a/include/asm-m68k/fpu.h b/include/asm-m68k/fpu.h index 3bcf85065c19..59701d7b4e78 100644 --- a/include/asm-m68k/fpu.h +++ b/include/asm-m68k/fpu.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __M68K_FPU_H | 1 | #ifndef __M68K_FPU_H |
2 | #define __M68K_FPU_H | 2 | #define __M68K_FPU_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * MAX floating point unit state size (FSAVE/FRESTORE) | 6 | * MAX floating point unit state size (FSAVE/FRESTORE) |
diff --git a/include/asm-m68k/hardirq.h b/include/asm-m68k/hardirq.h index 5e1c5826c83d..394ee946015c 100644 --- a/include/asm-m68k/hardirq.h +++ b/include/asm-m68k/hardirq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __M68K_HARDIRQ_H | 1 | #ifndef __M68K_HARDIRQ_H |
2 | #define __M68K_HARDIRQ_H | 2 | #define __M68K_HARDIRQ_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/threads.h> | 4 | #include <linux/threads.h> |
6 | #include <linux/cache.h> | 5 | #include <linux/cache.h> |
7 | 6 | ||
diff --git a/include/asm-m68k/ide.h b/include/asm-m68k/ide.h index 36118fd01867..365f76fb8013 100644 --- a/include/asm-m68k/ide.h +++ b/include/asm-m68k/ide.h | |||
@@ -31,7 +31,6 @@ | |||
31 | 31 | ||
32 | #ifdef __KERNEL__ | 32 | #ifdef __KERNEL__ |
33 | 33 | ||
34 | #include <linux/config.h> | ||
35 | 34 | ||
36 | #include <asm/setup.h> | 35 | #include <asm/setup.h> |
37 | #include <asm/io.h> | 36 | #include <asm/io.h> |
diff --git a/include/asm-m68k/io.h b/include/asm-m68k/io.h index dcfaa352d34c..5e0fcf41804d 100644 --- a/include/asm-m68k/io.h +++ b/include/asm-m68k/io.h | |||
@@ -23,7 +23,6 @@ | |||
23 | 23 | ||
24 | #ifdef __KERNEL__ | 24 | #ifdef __KERNEL__ |
25 | 25 | ||
26 | #include <linux/config.h> | ||
27 | #include <linux/compiler.h> | 26 | #include <linux/compiler.h> |
28 | #include <asm/raw_io.h> | 27 | #include <asm/raw_io.h> |
29 | #include <asm/virtconvert.h> | 28 | #include <asm/virtconvert.h> |
diff --git a/include/asm-m68k/irq.h b/include/asm-m68k/irq.h index 9ac047c400c4..b4f48b2a6a57 100644 --- a/include/asm-m68k/irq.h +++ b/include/asm-m68k/irq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _M68K_IRQ_H_ | 1 | #ifndef _M68K_IRQ_H_ |
2 | #define _M68K_IRQ_H_ | 2 | #define _M68K_IRQ_H_ |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/interrupt.h> | 4 | #include <linux/interrupt.h> |
6 | 5 | ||
7 | /* | 6 | /* |
diff --git a/include/asm-m68k/mc146818rtc.h b/include/asm-m68k/mc146818rtc.h index 11442095a8cf..11fe12ddb913 100644 --- a/include/asm-m68k/mc146818rtc.h +++ b/include/asm-m68k/mc146818rtc.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #ifndef _ASM_MC146818RTC_H | 4 | #ifndef _ASM_MC146818RTC_H |
5 | #define _ASM_MC146818RTC_H | 5 | #define _ASM_MC146818RTC_H |
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | #ifdef CONFIG_ATARI | 8 | #ifdef CONFIG_ATARI |
10 | /* RTC in Atari machines */ | 9 | /* RTC in Atari machines */ |
diff --git a/include/asm-m68k/mmu_context.h b/include/asm-m68k/mmu_context.h index 661191d15c81..231d11bd8e32 100644 --- a/include/asm-m68k/mmu_context.h +++ b/include/asm-m68k/mmu_context.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __M68K_MMU_CONTEXT_H | 1 | #ifndef __M68K_MMU_CONTEXT_H |
2 | #define __M68K_MMU_CONTEXT_H | 2 | #define __M68K_MMU_CONTEXT_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | static inline void enter_lazy_tlb(struct mm_struct *mm, struct task_struct *tsk) | 5 | static inline void enter_lazy_tlb(struct mm_struct *mm, struct task_struct *tsk) |
7 | { | 6 | { |
diff --git a/include/asm-m68k/motorola_pgtable.h b/include/asm-m68k/motorola_pgtable.h index 1628723458f5..1ccc7338a54b 100644 --- a/include/asm-m68k/motorola_pgtable.h +++ b/include/asm-m68k/motorola_pgtable.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _MOTOROLA_PGTABLE_H | 1 | #ifndef _MOTOROLA_PGTABLE_H |
2 | #define _MOTOROLA_PGTABLE_H | 2 | #define _MOTOROLA_PGTABLE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * Definitions for MMU descriptors | 6 | * Definitions for MMU descriptors |
diff --git a/include/asm-m68k/openprom.h b/include/asm-m68k/openprom.h index efbfb0bec6e2..869ab9176e9f 100644 --- a/include/asm-m68k/openprom.h +++ b/include/asm-m68k/openprom.h | |||
@@ -8,7 +8,6 @@ | |||
8 | * Copyright (C) 1995 David S. Miller (davem@caip.rutgers.edu) | 8 | * Copyright (C) 1995 David S. Miller (davem@caip.rutgers.edu) |
9 | */ | 9 | */ |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | 11 | ||
13 | /* Empirical constants... */ | 12 | /* Empirical constants... */ |
14 | #ifdef CONFIG_SUN3 | 13 | #ifdef CONFIG_SUN3 |
diff --git a/include/asm-m68k/page.h b/include/asm-m68k/page.h index f206dfbc1d48..db017f838c29 100644 --- a/include/asm-m68k/page.h +++ b/include/asm-m68k/page.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _M68K_PAGE_H | 1 | #ifndef _M68K_PAGE_H |
2 | #define _M68K_PAGE_H | 2 | #define _M68K_PAGE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* PAGE_SHIFT determines the page size */ | 5 | /* PAGE_SHIFT determines the page size */ |
7 | #ifndef CONFIG_SUN3 | 6 | #ifndef CONFIG_SUN3 |
diff --git a/include/asm-m68k/page_offset.h b/include/asm-m68k/page_offset.h index 86d3c2845ad4..1cbdb7f30ac2 100644 --- a/include/asm-m68k/page_offset.h +++ b/include/asm-m68k/page_offset.h | |||
@@ -1,4 +1,3 @@ | |||
1 | #include <linux/config.h> | ||
2 | 1 | ||
3 | /* This handles the memory map.. */ | 2 | /* This handles the memory map.. */ |
4 | #ifndef CONFIG_SUN3 | 3 | #ifndef CONFIG_SUN3 |
diff --git a/include/asm-m68k/pgalloc.h b/include/asm-m68k/pgalloc.h index b468b7958aaa..a9cfb4b99d88 100644 --- a/include/asm-m68k/pgalloc.h +++ b/include/asm-m68k/pgalloc.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #ifndef M68K_PGALLOC_H | 2 | #ifndef M68K_PGALLOC_H |
3 | #define M68K_PGALLOC_H | 3 | #define M68K_PGALLOC_H |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | #include <linux/mm.h> | 5 | #include <linux/mm.h> |
7 | #include <linux/highmem.h> | 6 | #include <linux/highmem.h> |
8 | #include <asm/setup.h> | 7 | #include <asm/setup.h> |
diff --git a/include/asm-m68k/pgtable.h b/include/asm-m68k/pgtable.h index add129e93fd7..f3aa05377987 100644 --- a/include/asm-m68k/pgtable.h +++ b/include/asm-m68k/pgtable.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #include <asm-generic/4level-fixup.h> | 4 | #include <asm-generic/4level-fixup.h> |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <asm/setup.h> | 6 | #include <asm/setup.h> |
8 | 7 | ||
9 | #ifndef __ASSEMBLY__ | 8 | #ifndef __ASSEMBLY__ |
diff --git a/include/asm-m68k/processor.h b/include/asm-m68k/processor.h index 7982285e84ed..352799e71f08 100644 --- a/include/asm-m68k/processor.h +++ b/include/asm-m68k/processor.h | |||
@@ -13,7 +13,6 @@ | |||
13 | */ | 13 | */ |
14 | #define current_text_addr() ({ __label__ _l; _l: &&_l;}) | 14 | #define current_text_addr() ({ __label__ _l; _l: &&_l;}) |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/thread_info.h> | 16 | #include <linux/thread_info.h> |
18 | #include <asm/segment.h> | 17 | #include <asm/segment.h> |
19 | #include <asm/fpu.h> | 18 | #include <asm/fpu.h> |
diff --git a/include/asm-m68k/semaphore-helper.h b/include/asm-m68k/semaphore-helper.h index 1516a642f9a5..eef30ba0b499 100644 --- a/include/asm-m68k/semaphore-helper.h +++ b/include/asm-m68k/semaphore-helper.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * m68k version by Andreas Schwab | 9 | * m68k version by Andreas Schwab |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/errno.h> | 12 | #include <linux/errno.h> |
14 | 13 | ||
15 | /* | 14 | /* |
diff --git a/include/asm-m68k/serial.h b/include/asm-m68k/serial.h index 3fe29f8b0194..2b90d6e69070 100644 --- a/include/asm-m68k/serial.h +++ b/include/asm-m68k/serial.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * | 6 | * |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | /* | 10 | /* |
12 | * This assumes you have a 1.8432 MHz clock for your UART. | 11 | * This assumes you have a 1.8432 MHz clock for your UART. |
diff --git a/include/asm-m68k/setup.h b/include/asm-m68k/setup.h index a89aa84073e5..7facc9a46e74 100644 --- a/include/asm-m68k/setup.h +++ b/include/asm-m68k/setup.h | |||
@@ -23,7 +23,6 @@ | |||
23 | #ifndef _M68K_SETUP_H | 23 | #ifndef _M68K_SETUP_H |
24 | #define _M68K_SETUP_H | 24 | #define _M68K_SETUP_H |
25 | 25 | ||
26 | #include <linux/config.h> | ||
27 | 26 | ||
28 | 27 | ||
29 | /* | 28 | /* |
diff --git a/include/asm-m68k/shm.h b/include/asm-m68k/shm.h index 3fa2f368fc1a..fa56ec84a126 100644 --- a/include/asm-m68k/shm.h +++ b/include/asm-m68k/shm.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _M68K_SHM_H | 1 | #ifndef _M68K_SHM_H |
2 | #define _M68K_SHM_H | 2 | #define _M68K_SHM_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* format of page table entries that correspond to shared memory pages | 5 | /* format of page table entries that correspond to shared memory pages |
7 | currently out in swap space (see also mm/swap.c): | 6 | currently out in swap space (see also mm/swap.c): |
diff --git a/include/asm-m68k/system.h b/include/asm-m68k/system.h index 64d3481df74c..d6dd8052cd6f 100644 --- a/include/asm-m68k/system.h +++ b/include/asm-m68k/system.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _M68K_SYSTEM_H | 1 | #ifndef _M68K_SYSTEM_H |
2 | #define _M68K_SYSTEM_H | 2 | #define _M68K_SYSTEM_H |
3 | 3 | ||
4 | #include <linux/config.h> /* get configuration macros */ | ||
5 | #include <linux/linkage.h> | 4 | #include <linux/linkage.h> |
6 | #include <linux/kernel.h> | 5 | #include <linux/kernel.h> |
7 | #include <asm/segment.h> | 6 | #include <asm/segment.h> |
diff --git a/include/asm-m68k/tlbflush.h b/include/asm-m68k/tlbflush.h index 8e61ccffe13a..31678831ee47 100644 --- a/include/asm-m68k/tlbflush.h +++ b/include/asm-m68k/tlbflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _M68K_TLBFLUSH_H | 1 | #ifndef _M68K_TLBFLUSH_H |
2 | #define _M68K_TLBFLUSH_H | 2 | #define _M68K_TLBFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifndef CONFIG_SUN3 | 5 | #ifndef CONFIG_SUN3 |
7 | 6 | ||
diff --git a/include/asm-m68k/unistd.h b/include/asm-m68k/unistd.h index c2554bcd1747..f236fe92156f 100644 --- a/include/asm-m68k/unistd.h +++ b/include/asm-m68k/unistd.h | |||
@@ -285,6 +285,8 @@ | |||
285 | #define __NR_request_key 280 | 285 | #define __NR_request_key 280 |
286 | #define __NR_keyctl 281 | 286 | #define __NR_keyctl 281 |
287 | 287 | ||
288 | #ifdef __KERNEL__ | ||
289 | |||
288 | #define NR_syscalls 282 | 290 | #define NR_syscalls 282 |
289 | 291 | ||
290 | /* user-visible error numbers are in the range -1 - -124: see | 292 | /* user-visible error numbers are in the range -1 - -124: see |
@@ -383,7 +385,6 @@ __asm__ __volatile__ ("trap #0" \ | |||
383 | __syscall_return(type,__res); \ | 385 | __syscall_return(type,__res); \ |
384 | } | 386 | } |
385 | 387 | ||
386 | #ifdef __KERNEL__ | ||
387 | #define __ARCH_WANT_IPC_PARSE_VERSION | 388 | #define __ARCH_WANT_IPC_PARSE_VERSION |
388 | #define __ARCH_WANT_OLD_READDIR | 389 | #define __ARCH_WANT_OLD_READDIR |
389 | #define __ARCH_WANT_OLD_STAT | 390 | #define __ARCH_WANT_OLD_STAT |
@@ -406,7 +407,6 @@ __syscall_return(type,__res); \ | |||
406 | #define __ARCH_WANT_SYS_SIGPENDING | 407 | #define __ARCH_WANT_SYS_SIGPENDING |
407 | #define __ARCH_WANT_SYS_SIGPROCMASK | 408 | #define __ARCH_WANT_SYS_SIGPROCMASK |
408 | #define __ARCH_WANT_SYS_RT_SIGACTION | 409 | #define __ARCH_WANT_SYS_RT_SIGACTION |
409 | #endif | ||
410 | 410 | ||
411 | #ifdef __KERNEL_SYSCALLS__ | 411 | #ifdef __KERNEL_SYSCALLS__ |
412 | 412 | ||
@@ -451,7 +451,7 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
451 | struct sigaction __user *oact, | 451 | struct sigaction __user *oact, |
452 | size_t sigsetsize); | 452 | size_t sigsetsize); |
453 | 453 | ||
454 | #endif | 454 | #endif /* __KERNEL_SYSCALLS__ */ |
455 | 455 | ||
456 | /* | 456 | /* |
457 | * "Conditional" syscalls | 457 | * "Conditional" syscalls |
@@ -461,4 +461,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
461 | */ | 461 | */ |
462 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 462 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
463 | 463 | ||
464 | #endif /* __KERNEL__ */ | ||
464 | #endif /* _ASM_M68K_UNISTD_H_ */ | 465 | #endif /* _ASM_M68K_UNISTD_H_ */ |
diff --git a/include/asm-m68k/virtconvert.h b/include/asm-m68k/virtconvert.h index 8c4e8037b898..83a87c9b1a16 100644 --- a/include/asm-m68k/virtconvert.h +++ b/include/asm-m68k/virtconvert.h | |||
@@ -7,7 +7,6 @@ | |||
7 | 7 | ||
8 | #ifdef __KERNEL__ | 8 | #ifdef __KERNEL__ |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <linux/compiler.h> | 10 | #include <linux/compiler.h> |
12 | #include <asm/setup.h> | 11 | #include <asm/setup.h> |
13 | #include <asm/page.h> | 12 | #include <asm/page.h> |
diff --git a/include/asm-m68knommu/bitops.h b/include/asm-m68knommu/bitops.h index 0b68ccd327f7..d7fa7d9c0e0f 100644 --- a/include/asm-m68knommu/bitops.h +++ b/include/asm-m68knommu/bitops.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * Copyright 1992, Linus Torvalds. | 5 | * Copyright 1992, Linus Torvalds. |
6 | */ | 6 | */ |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | #include <linux/compiler.h> | 8 | #include <linux/compiler.h> |
10 | #include <asm/byteorder.h> /* swab32 */ | 9 | #include <asm/byteorder.h> /* swab32 */ |
11 | #include <asm/system.h> /* save_flags */ | 10 | #include <asm/system.h> /* save_flags */ |
diff --git a/include/asm-m68knommu/coldfire.h b/include/asm-m68knommu/coldfire.h index 6190f77b1e6c..2fabca91df83 100644 --- a/include/asm-m68knommu/coldfire.h +++ b/include/asm-m68knommu/coldfire.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #define coldfire_h | 12 | #define coldfire_h |
13 | /****************************************************************************/ | 13 | /****************************************************************************/ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | /* | 16 | /* |
18 | * Define the processor support peripherals base address. | 17 | * Define the processor support peripherals base address. |
diff --git a/include/asm-m68knommu/commproc.h b/include/asm-m68knommu/commproc.h index e522ca8193a2..0161ebb5d883 100644 --- a/include/asm-m68knommu/commproc.h +++ b/include/asm-m68knommu/commproc.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #ifndef __CPM_360__ | 17 | #ifndef __CPM_360__ |
18 | #define __CPM_360__ | 18 | #define __CPM_360__ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | 20 | ||
22 | /* CPM Command register masks: */ | 21 | /* CPM Command register masks: */ |
23 | #define CPM_CR_RST ((ushort)0x8000) | 22 | #define CPM_CR_RST ((ushort)0x8000) |
diff --git a/include/asm-m68knommu/dma-mapping.h b/include/asm-m68knommu/dma-mapping.h index a6c42ba48da6..5622b855a577 100644 --- a/include/asm-m68knommu/dma-mapping.h +++ b/include/asm-m68knommu/dma-mapping.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _M68KNOMMU_DMA_MAPPING_H | 1 | #ifndef _M68KNOMMU_DMA_MAPPING_H |
2 | #define _M68KNOMMU_DMA_MAPPING_H | 2 | #define _M68KNOMMU_DMA_MAPPING_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_PCI | 5 | #ifdef CONFIG_PCI |
7 | #include <asm-generic/dma-mapping.h> | 6 | #include <asm-generic/dma-mapping.h> |
diff --git a/include/asm-m68knommu/dma.h b/include/asm-m68knommu/dma.h index 43e98c96a5c2..3338001abb40 100644 --- a/include/asm-m68knommu/dma.h +++ b/include/asm-m68knommu/dma.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | //#define DMA_DEBUG 1 | 4 | //#define DMA_DEBUG 1 |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | #ifdef CONFIG_COLDFIRE | 7 | #ifdef CONFIG_COLDFIRE |
9 | /* | 8 | /* |
diff --git a/include/asm-m68knommu/elf.h b/include/asm-m68knommu/elf.h index 9919487703bc..40b1ed6827db 100644 --- a/include/asm-m68knommu/elf.h +++ b/include/asm-m68knommu/elf.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * ELF register definitions.. | 5 | * ELF register definitions.. |
6 | */ | 6 | */ |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | #include <asm/ptrace.h> | 8 | #include <asm/ptrace.h> |
10 | #include <asm/user.h> | 9 | #include <asm/user.h> |
11 | 10 | ||
diff --git a/include/asm-m68knommu/elia.h b/include/asm-m68knommu/elia.h index f18b8e9d8c36..e037d4e2de33 100644 --- a/include/asm-m68knommu/elia.h +++ b/include/asm-m68knommu/elia.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #define elia_h | 12 | #define elia_h |
13 | /****************************************************************************/ | 13 | /****************************************************************************/ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <asm/coldfire.h> | 15 | #include <asm/coldfire.h> |
17 | 16 | ||
18 | #ifdef CONFIG_eLIA | 17 | #ifdef CONFIG_eLIA |
diff --git a/include/asm-m68knommu/entry.h b/include/asm-m68knommu/entry.h index 06f5aa70b0b5..c2553d26273d 100644 --- a/include/asm-m68knommu/entry.h +++ b/include/asm-m68knommu/entry.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __M68KNOMMU_ENTRY_H | 1 | #ifndef __M68KNOMMU_ENTRY_H |
2 | #define __M68KNOMMU_ENTRY_H | 2 | #define __M68KNOMMU_ENTRY_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/setup.h> | 4 | #include <asm/setup.h> |
6 | #include <asm/page.h> | 5 | #include <asm/page.h> |
7 | 6 | ||
diff --git a/include/asm-m68knommu/fpu.h b/include/asm-m68knommu/fpu.h index 225082991a03..b16b2e4fca2a 100644 --- a/include/asm-m68knommu/fpu.h +++ b/include/asm-m68knommu/fpu.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __M68KNOMMU_FPU_H | 1 | #ifndef __M68KNOMMU_FPU_H |
2 | #define __M68KNOMMU_FPU_H | 2 | #define __M68KNOMMU_FPU_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * MAX floating point unit state size (FSAVE/FRESTORE) | 6 | * MAX floating point unit state size (FSAVE/FRESTORE) |
diff --git a/include/asm-m68knommu/hardirq.h b/include/asm-m68knommu/hardirq.h index 476180f4cba2..980075bab792 100644 --- a/include/asm-m68knommu/hardirq.h +++ b/include/asm-m68knommu/hardirq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __M68K_HARDIRQ_H | 1 | #ifndef __M68K_HARDIRQ_H |
2 | #define __M68K_HARDIRQ_H | 2 | #define __M68K_HARDIRQ_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/cache.h> | 4 | #include <linux/cache.h> |
6 | #include <linux/threads.h> | 5 | #include <linux/threads.h> |
7 | #include <asm/irq.h> | 6 | #include <asm/irq.h> |
diff --git a/include/asm-m68knommu/io.h b/include/asm-m68knommu/io.h index e08f2ee4b4a2..8df4cee2a0cd 100644 --- a/include/asm-m68knommu/io.h +++ b/include/asm-m68knommu/io.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | /* | 7 | /* |
9 | * These are for ISA/PCI shared memory _only_ and should never be used | 8 | * These are for ISA/PCI shared memory _only_ and should never be used |
diff --git a/include/asm-m68knommu/irq.h b/include/asm-m68knommu/irq.h index 20c48ec858a4..2b408842a30e 100644 --- a/include/asm-m68knommu/irq.h +++ b/include/asm-m68knommu/irq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _M68K_IRQ_H_ | 1 | #ifndef _M68K_IRQ_H_ |
2 | #define _M68K_IRQ_H_ | 2 | #define _M68K_IRQ_H_ |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/ptrace.h> | 4 | #include <asm/ptrace.h> |
6 | 5 | ||
7 | #ifdef CONFIG_COLDFIRE | 6 | #ifdef CONFIG_COLDFIRE |
diff --git a/include/asm-m68knommu/m5206sim.h b/include/asm-m68knommu/m5206sim.h index d1e7509021c5..7e3594dea88b 100644 --- a/include/asm-m68knommu/m5206sim.h +++ b/include/asm-m68knommu/m5206sim.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #define m5206sim_h | 12 | #define m5206sim_h |
13 | /****************************************************************************/ | 13 | /****************************************************************************/ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | /* | 16 | /* |
18 | * Define the 5206 SIM register set addresses. | 17 | * Define the 5206 SIM register set addresses. |
diff --git a/include/asm-m68knommu/m520xsim.h b/include/asm-m68knommu/m520xsim.h index 6dc62869e62b..1dac22ea95ba 100644 --- a/include/asm-m68knommu/m520xsim.h +++ b/include/asm-m68knommu/m520xsim.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #define m520xsim_h | 11 | #define m520xsim_h |
12 | /****************************************************************************/ | 12 | /****************************************************************************/ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | /* | 15 | /* |
17 | * Define the 5282 SIM register set addresses. | 16 | * Define the 5282 SIM register set addresses. |
diff --git a/include/asm-m68knommu/m523xsim.h b/include/asm-m68knommu/m523xsim.h index 926cfb805df7..bf397313e93f 100644 --- a/include/asm-m68knommu/m523xsim.h +++ b/include/asm-m68knommu/m523xsim.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #define m523xsim_h | 11 | #define m523xsim_h |
12 | /****************************************************************************/ | 12 | /****************************************************************************/ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | /* | 15 | /* |
17 | * Define the 523x SIM register set addresses. | 16 | * Define the 523x SIM register set addresses. |
diff --git a/include/asm-m68knommu/m5272sim.h b/include/asm-m68knommu/m5272sim.h index b40875362f46..6217edc21139 100644 --- a/include/asm-m68knommu/m5272sim.h +++ b/include/asm-m68knommu/m5272sim.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #define m5272sim_h | 12 | #define m5272sim_h |
13 | /****************************************************************************/ | 13 | /****************************************************************************/ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | /* | 16 | /* |
18 | * Define the 5272 SIM register set addresses. | 17 | * Define the 5272 SIM register set addresses. |
diff --git a/include/asm-m68knommu/m527xsim.h b/include/asm-m68knommu/m527xsim.h index e7878d0f7d7a..1f63ab3fb3e6 100644 --- a/include/asm-m68knommu/m527xsim.h +++ b/include/asm-m68knommu/m527xsim.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #define m527xsim_h | 11 | #define m527xsim_h |
12 | /****************************************************************************/ | 12 | /****************************************************************************/ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | /* | 15 | /* |
17 | * Define the 5270/5271 SIM register set addresses. | 16 | * Define the 5270/5271 SIM register set addresses. |
diff --git a/include/asm-m68knommu/m528xsim.h b/include/asm-m68knommu/m528xsim.h index 610774a17f70..1a3b1ae06b1e 100644 --- a/include/asm-m68knommu/m528xsim.h +++ b/include/asm-m68knommu/m528xsim.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #define m528xsim_h | 11 | #define m528xsim_h |
12 | /****************************************************************************/ | 12 | /****************************************************************************/ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | /* | 15 | /* |
17 | * Define the 5280/5282 SIM register set addresses. | 16 | * Define the 5280/5282 SIM register set addresses. |
diff --git a/include/asm-m68knommu/mcfcache.h b/include/asm-m68knommu/mcfcache.h index 9cb401421835..45d1ac57ea82 100644 --- a/include/asm-m68knommu/mcfcache.h +++ b/include/asm-m68knommu/mcfcache.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #define __M68KNOMMU_MCFCACHE_H | 11 | #define __M68KNOMMU_MCFCACHE_H |
12 | /****************************************************************************/ | 12 | /****************************************************************************/ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | /* | 15 | /* |
17 | * The different ColdFire families have different cache arrangments. | 16 | * The different ColdFire families have different cache arrangments. |
diff --git a/include/asm-m68knommu/mcfdma.h b/include/asm-m68knommu/mcfdma.h index b93f8ba8a248..ea729e81a6be 100644 --- a/include/asm-m68knommu/mcfdma.h +++ b/include/asm-m68knommu/mcfdma.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #define mcfdma_h | 11 | #define mcfdma_h |
12 | /****************************************************************************/ | 12 | /****************************************************************************/ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | /* | 15 | /* |
17 | * Get address specific defines for this Coldfire member. | 16 | * Get address specific defines for this Coldfire member. |
diff --git a/include/asm-m68knommu/mcfmbus.h b/include/asm-m68knommu/mcfmbus.h index 4762589e858a..13df9d41bd1a 100644 --- a/include/asm-m68knommu/mcfmbus.h +++ b/include/asm-m68knommu/mcfmbus.h | |||
@@ -11,7 +11,6 @@ | |||
11 | 11 | ||
12 | #ifndef mcfmbus_h | 12 | #ifndef mcfmbus_h |
13 | #define mcfmbus_h | 13 | #define mcfmbus_h |
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | 15 | ||
17 | #define MCFMBUS_BASE 0x280 | 16 | #define MCFMBUS_BASE 0x280 |
diff --git a/include/asm-m68knommu/mcfne.h b/include/asm-m68knommu/mcfne.h index a71b1c8cb4f8..c920ccdb61fe 100644 --- a/include/asm-m68knommu/mcfne.h +++ b/include/asm-m68knommu/mcfne.h | |||
@@ -18,7 +18,6 @@ | |||
18 | #define mcfne_h | 18 | #define mcfne_h |
19 | /****************************************************************************/ | 19 | /****************************************************************************/ |
20 | 20 | ||
21 | #include <linux/config.h> | ||
22 | 21 | ||
23 | /* | 22 | /* |
24 | * Support for NE2000 clones devices in ColdFire based boards. | 23 | * Support for NE2000 clones devices in ColdFire based boards. |
diff --git a/include/asm-m68knommu/mcfpci.h b/include/asm-m68knommu/mcfpci.h index d6229047d06e..f1507dd06ec6 100644 --- a/include/asm-m68knommu/mcfpci.h +++ b/include/asm-m68knommu/mcfpci.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #define mcfpci_h | 12 | #define mcfpci_h |
13 | /****************************************************************************/ | 13 | /****************************************************************************/ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | #ifdef CONFIG_PCI | 16 | #ifdef CONFIG_PCI |
18 | 17 | ||
diff --git a/include/asm-m68knommu/mcfpit.h b/include/asm-m68knommu/mcfpit.h index a685f1b45401..0d2672dd518a 100644 --- a/include/asm-m68knommu/mcfpit.h +++ b/include/asm-m68knommu/mcfpit.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #define mcfpit_h | 11 | #define mcfpit_h |
12 | /****************************************************************************/ | 12 | /****************************************************************************/ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | /* | 15 | /* |
17 | * Get address specific defines for the 5270/5271, 5280/5282, and 5208. | 16 | * Get address specific defines for the 5270/5271, 5280/5282, and 5208. |
diff --git a/include/asm-m68knommu/mcfsim.h b/include/asm-m68knommu/mcfsim.h index 81d74a31dc43..97a0c2734a72 100644 --- a/include/asm-m68knommu/mcfsim.h +++ b/include/asm-m68knommu/mcfsim.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #define mcfsim_h | 12 | #define mcfsim_h |
13 | /****************************************************************************/ | 13 | /****************************************************************************/ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | /* | 16 | /* |
18 | * Include 5204, 5206/e, 5235, 5249, 5270/5271, 5272, 5280/5282, | 17 | * Include 5204, 5206/e, 5235, 5249, 5270/5271, 5272, 5280/5282, |
diff --git a/include/asm-m68knommu/mcfsmc.h b/include/asm-m68knommu/mcfsmc.h index 2583900b9591..2d7a4dbd9683 100644 --- a/include/asm-m68knommu/mcfsmc.h +++ b/include/asm-m68knommu/mcfsmc.h | |||
@@ -17,7 +17,6 @@ | |||
17 | * allow 8 bit accesses. So this code is 16bit access only. | 17 | * allow 8 bit accesses. So this code is 16bit access only. |
18 | */ | 18 | */ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | 20 | ||
22 | #undef outb | 21 | #undef outb |
23 | #undef inb | 22 | #undef inb |
diff --git a/include/asm-m68knommu/mcftimer.h b/include/asm-m68knommu/mcftimer.h index 0f47164c33a9..68bf33ac10d1 100644 --- a/include/asm-m68knommu/mcftimer.h +++ b/include/asm-m68knommu/mcftimer.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #define mcftimer_h | 12 | #define mcftimer_h |
13 | /****************************************************************************/ | 13 | /****************************************************************************/ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | /* | 16 | /* |
18 | * Get address specific defines for this ColdFire member. | 17 | * Get address specific defines for this ColdFire member. |
diff --git a/include/asm-m68knommu/mcfuart.h b/include/asm-m68knommu/mcfuart.h index b016fad83119..8040e43786be 100644 --- a/include/asm-m68knommu/mcfuart.h +++ b/include/asm-m68knommu/mcfuart.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #define mcfuart_h | 12 | #define mcfuart_h |
13 | /****************************************************************************/ | 13 | /****************************************************************************/ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | /* | 16 | /* |
18 | * Define the base address of the UARTS within the MBAR address | 17 | * Define the base address of the UARTS within the MBAR address |
diff --git a/include/asm-m68knommu/mcfwdebug.h b/include/asm-m68knommu/mcfwdebug.h index 6ceae103596b..27f70e45d700 100644 --- a/include/asm-m68knommu/mcfwdebug.h +++ b/include/asm-m68knommu/mcfwdebug.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef mcfdebug_h | 10 | #ifndef mcfdebug_h |
11 | #define mcfdebug_h | 11 | #define mcfdebug_h |
12 | /****************************************************************************/ | 12 | /****************************************************************************/ |
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | /* Define the debug module registers */ | 14 | /* Define the debug module registers */ |
16 | #define MCFDEBUG_CSR 0x0 /* Configuration status */ | 15 | #define MCFDEBUG_CSR 0x0 /* Configuration status */ |
diff --git a/include/asm-m68knommu/mmu_context.h b/include/asm-m68knommu/mmu_context.h index 1e080eca9ca8..6c077d3a2572 100644 --- a/include/asm-m68knommu/mmu_context.h +++ b/include/asm-m68knommu/mmu_context.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __M68KNOMMU_MMU_CONTEXT_H | 1 | #ifndef __M68KNOMMU_MMU_CONTEXT_H |
2 | #define __M68KNOMMU_MMU_CONTEXT_H | 2 | #define __M68KNOMMU_MMU_CONTEXT_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/setup.h> | 4 | #include <asm/setup.h> |
6 | #include <asm/page.h> | 5 | #include <asm/page.h> |
7 | #include <asm/pgalloc.h> | 6 | #include <asm/pgalloc.h> |
diff --git a/include/asm-m68knommu/nettel.h b/include/asm-m68knommu/nettel.h index 9bda307e6544..0299f6a2deeb 100644 --- a/include/asm-m68knommu/nettel.h +++ b/include/asm-m68knommu/nettel.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #define nettel_h | 13 | #define nettel_h |
14 | /****************************************************************************/ | 14 | /****************************************************************************/ |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | /****************************************************************************/ | 17 | /****************************************************************************/ |
19 | #ifdef CONFIG_NETtel | 18 | #ifdef CONFIG_NETtel |
diff --git a/include/asm-m68knommu/page.h b/include/asm-m68knommu/page.h index 942dfbead27f..a22bf5a88160 100644 --- a/include/asm-m68knommu/page.h +++ b/include/asm-m68knommu/page.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _M68KNOMMU_PAGE_H | 1 | #ifndef _M68KNOMMU_PAGE_H |
2 | #define _M68KNOMMU_PAGE_H | 2 | #define _M68KNOMMU_PAGE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* PAGE_SHIFT determines the page size */ | 5 | /* PAGE_SHIFT determines the page size */ |
7 | 6 | ||
diff --git a/include/asm-m68knommu/page_offset.h b/include/asm-m68knommu/page_offset.h index 2b45645e9b29..8ed6d7b7d9d1 100644 --- a/include/asm-m68knommu/page_offset.h +++ b/include/asm-m68knommu/page_offset.h | |||
@@ -1,5 +1,4 @@ | |||
1 | 1 | ||
2 | #include <linux/config.h> | ||
3 | 2 | ||
4 | /* This handles the memory map.. */ | 3 | /* This handles the memory map.. */ |
5 | 4 | ||
diff --git a/include/asm-m68knommu/param.h b/include/asm-m68knommu/param.h index 3f57d5db81f5..4c9904d6512e 100644 --- a/include/asm-m68knommu/param.h +++ b/include/asm-m68knommu/param.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _M68KNOMMU_PARAM_H | 1 | #ifndef _M68KNOMMU_PARAM_H |
2 | #define _M68KNOMMU_PARAM_H | 2 | #define _M68KNOMMU_PARAM_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #if defined(CONFIG_CLEOPATRA) | 5 | #if defined(CONFIG_CLEOPATRA) |
7 | #define HZ 1000 | 6 | #define HZ 1000 |
diff --git a/include/asm-m68knommu/pgtable.h b/include/asm-m68knommu/pgtable.h index 00893055e6c2..549ad231efad 100644 --- a/include/asm-m68knommu/pgtable.h +++ b/include/asm-m68knommu/pgtable.h | |||
@@ -7,7 +7,6 @@ | |||
7 | * (C) Copyright 2000-2002, Greg Ungerer <gerg@snapgear.com> | 7 | * (C) Copyright 2000-2002, Greg Ungerer <gerg@snapgear.com> |
8 | */ | 8 | */ |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <linux/slab.h> | 10 | #include <linux/slab.h> |
12 | #include <asm/processor.h> | 11 | #include <asm/processor.h> |
13 | #include <asm/page.h> | 12 | #include <asm/page.h> |
diff --git a/include/asm-m68knommu/processor.h b/include/asm-m68knommu/processor.h index ba393b1a023b..278b00bc60c5 100644 --- a/include/asm-m68knommu/processor.h +++ b/include/asm-m68knommu/processor.h | |||
@@ -13,7 +13,6 @@ | |||
13 | */ | 13 | */ |
14 | #define current_text_addr() ({ __label__ _l; _l: &&_l;}) | 14 | #define current_text_addr() ({ __label__ _l; _l: &&_l;}) |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/threads.h> | 16 | #include <linux/threads.h> |
18 | #include <asm/types.h> | 17 | #include <asm/types.h> |
19 | #include <asm/segment.h> | 18 | #include <asm/segment.h> |
diff --git a/include/asm-m68knommu/semaphore-helper.h b/include/asm-m68knommu/semaphore-helper.h index a6586417c1c2..43da7bc483c7 100644 --- a/include/asm-m68knommu/semaphore-helper.h +++ b/include/asm-m68knommu/semaphore-helper.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * m68k version by Andreas Schwab | 9 | * m68k version by Andreas Schwab |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | /* | 13 | /* |
15 | * These two _must_ execute atomically wrt each other. | 14 | * These two _must_ execute atomically wrt each other. |
diff --git a/include/asm-m68knommu/system.h b/include/asm-m68knommu/system.h index 6338afc850ba..2bbe2db00a22 100644 --- a/include/asm-m68knommu/system.h +++ b/include/asm-m68knommu/system.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _M68KNOMMU_SYSTEM_H | 1 | #ifndef _M68KNOMMU_SYSTEM_H |
2 | #define _M68KNOMMU_SYSTEM_H | 2 | #define _M68KNOMMU_SYSTEM_H |
3 | 3 | ||
4 | #include <linux/config.h> /* get configuration macros */ | ||
5 | #include <linux/linkage.h> | 4 | #include <linux/linkage.h> |
6 | #include <asm/segment.h> | 5 | #include <asm/segment.h> |
7 | #include <asm/entry.h> | 6 | #include <asm/entry.h> |
diff --git a/include/asm-m68knommu/unaligned.h b/include/asm-m68knommu/unaligned.h index 8876f034ea64..869e9dd24f54 100644 --- a/include/asm-m68knommu/unaligned.h +++ b/include/asm-m68knommu/unaligned.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __M68K_UNALIGNED_H | 1 | #ifndef __M68K_UNALIGNED_H |
2 | #define __M68K_UNALIGNED_H | 2 | #define __M68K_UNALIGNED_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_COLDFIRE | 5 | #ifdef CONFIG_COLDFIRE |
7 | 6 | ||
diff --git a/include/asm-m68knommu/unistd.h b/include/asm-m68knommu/unistd.h index 5373988a7e51..1b2abdf281e1 100644 --- a/include/asm-m68knommu/unistd.h +++ b/include/asm-m68knommu/unistd.h | |||
@@ -286,6 +286,8 @@ | |||
286 | #define __NR_request_key 280 | 286 | #define __NR_request_key 280 |
287 | #define __NR_keyctl 281 | 287 | #define __NR_keyctl 281 |
288 | 288 | ||
289 | #ifdef __KERNEL__ | ||
290 | |||
289 | #define NR_syscalls 282 | 291 | #define NR_syscalls 282 |
290 | 292 | ||
291 | /* user-visible error numbers are in the range -1 - -122: see | 293 | /* user-visible error numbers are in the range -1 - -122: see |
@@ -437,7 +439,6 @@ type name(atype a, btype b, ctype c, dtype d, etype e) \ | |||
437 | return (type)__res; \ | 439 | return (type)__res; \ |
438 | } | 440 | } |
439 | 441 | ||
440 | #ifdef __KERNEL__ | ||
441 | #define __ARCH_WANT_IPC_PARSE_VERSION | 442 | #define __ARCH_WANT_IPC_PARSE_VERSION |
442 | #define __ARCH_WANT_OLD_READDIR | 443 | #define __ARCH_WANT_OLD_READDIR |
443 | #define __ARCH_WANT_OLD_STAT | 444 | #define __ARCH_WANT_OLD_STAT |
@@ -460,7 +461,6 @@ type name(atype a, btype b, ctype c, dtype d, etype e) \ | |||
460 | #define __ARCH_WANT_SYS_SIGPENDING | 461 | #define __ARCH_WANT_SYS_SIGPENDING |
461 | #define __ARCH_WANT_SYS_SIGPROCMASK | 462 | #define __ARCH_WANT_SYS_SIGPROCMASK |
462 | #define __ARCH_WANT_SYS_RT_SIGACTION | 463 | #define __ARCH_WANT_SYS_RT_SIGACTION |
463 | #endif | ||
464 | 464 | ||
465 | #ifdef __KERNEL_SYSCALLS__ | 465 | #ifdef __KERNEL_SYSCALLS__ |
466 | 466 | ||
@@ -515,7 +515,7 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
515 | struct sigaction __user *oact, | 515 | struct sigaction __user *oact, |
516 | size_t sigsetsize); | 516 | size_t sigsetsize); |
517 | 517 | ||
518 | #endif | 518 | #endif /* __KERNEL_SYSCALLS__ */ |
519 | 519 | ||
520 | /* | 520 | /* |
521 | * "Conditional" syscalls | 521 | * "Conditional" syscalls |
@@ -525,4 +525,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
525 | */ | 525 | */ |
526 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 526 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
527 | 527 | ||
528 | #endif /* __KERNEL__ */ | ||
528 | #endif /* _ASM_M68K_UNISTD_H_ */ | 529 | #endif /* _ASM_M68K_UNISTD_H_ */ |
diff --git a/include/asm-mips/a.out.h b/include/asm-mips/a.out.h index 2b3dc3bed4da..ef33c3f13484 100644 --- a/include/asm-mips/a.out.h +++ b/include/asm-mips/a.out.h | |||
@@ -10,7 +10,6 @@ | |||
10 | 10 | ||
11 | #ifdef __KERNEL__ | 11 | #ifdef __KERNEL__ |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | #endif | 14 | #endif |
16 | 15 | ||
diff --git a/include/asm-mips/addrspace.h b/include/asm-mips/addrspace.h index 1386af1cb7d9..45c706e34df1 100644 --- a/include/asm-mips/addrspace.h +++ b/include/asm-mips/addrspace.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASM_ADDRSPACE_H | 10 | #ifndef _ASM_ADDRSPACE_H |
11 | #define _ASM_ADDRSPACE_H | 11 | #define _ASM_ADDRSPACE_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <spaces.h> | 13 | #include <spaces.h> |
15 | 14 | ||
16 | /* | 15 | /* |
@@ -133,57 +132,22 @@ | |||
133 | || defined (CONFIG_CPU_NEVADA) \ | 132 | || defined (CONFIG_CPU_NEVADA) \ |
134 | || defined (CONFIG_CPU_TX49XX) \ | 133 | || defined (CONFIG_CPU_TX49XX) \ |
135 | || defined (CONFIG_CPU_MIPS64) | 134 | || defined (CONFIG_CPU_MIPS64) |
136 | #define KUSIZE _LLCONST_(0x0000010000000000) /* 2^^40 */ | ||
137 | #define KUSIZE_64 _LLCONST_(0x0000010000000000) /* 2^^40 */ | ||
138 | #define K0SIZE _LLCONST_(0x0000001000000000) /* 2^^36 */ | ||
139 | #define K1SIZE _LLCONST_(0x0000001000000000) /* 2^^36 */ | ||
140 | #define K2SIZE _LLCONST_(0x000000ff80000000) | ||
141 | #define KSEGSIZE _LLCONST_(0x000000ff80000000) /* max syssegsz */ | ||
142 | #define TO_PHYS_MASK _LLCONST_(0x0000000fffffffff) /* 2^^36 - 1 */ | 135 | #define TO_PHYS_MASK _LLCONST_(0x0000000fffffffff) /* 2^^36 - 1 */ |
143 | #endif | 136 | #endif |
144 | 137 | ||
145 | #if defined (CONFIG_CPU_R8000) | 138 | #if defined (CONFIG_CPU_R8000) |
146 | /* We keep KUSIZE consistent with R4000 for now (2^^40) instead of (2^^48) */ | 139 | /* We keep KUSIZE consistent with R4000 for now (2^^40) instead of (2^^48) */ |
147 | #define KUSIZE _LLCONST_(0x0000010000000000) /* 2^^40 */ | ||
148 | #define KUSIZE_64 _LLCONST_(0x0000010000000000) /* 2^^40 */ | ||
149 | #define K0SIZE _LLCONST_(0x0000010000000000) /* 2^^40 */ | ||
150 | #define K1SIZE _LLCONST_(0x0000010000000000) /* 2^^40 */ | ||
151 | #define K2SIZE _LLCONST_(0x0001000000000000) | ||
152 | #define KSEGSIZE _LLCONST_(0x0000010000000000) /* max syssegsz */ | ||
153 | #define TO_PHYS_MASK _LLCONST_(0x000000ffffffffff) /* 2^^40 - 1 */ | 140 | #define TO_PHYS_MASK _LLCONST_(0x000000ffffffffff) /* 2^^40 - 1 */ |
154 | #endif | 141 | #endif |
155 | 142 | ||
156 | #if defined (CONFIG_CPU_R10000) | 143 | #if defined (CONFIG_CPU_R10000) |
157 | #define KUSIZE _LLCONST_(0x0000010000000000) /* 2^^40 */ | ||
158 | #define KUSIZE_64 _LLCONST_(0x0000010000000000) /* 2^^40 */ | ||
159 | #define K0SIZE _LLCONST_(0x0000010000000000) /* 2^^40 */ | ||
160 | #define K1SIZE _LLCONST_(0x0000010000000000) /* 2^^40 */ | ||
161 | #define K2SIZE _LLCONST_(0x00000fff80000000) | ||
162 | #define KSEGSIZE _LLCONST_(0x00000fff80000000) /* max syssegsz */ | ||
163 | #define TO_PHYS_MASK _LLCONST_(0x000000ffffffffff) /* 2^^40 - 1 */ | 144 | #define TO_PHYS_MASK _LLCONST_(0x000000ffffffffff) /* 2^^40 - 1 */ |
164 | #endif | 145 | #endif |
165 | 146 | ||
166 | #if defined(CONFIG_CPU_SB1) || defined(CONFIG_CPU_SB1A) | 147 | #if defined(CONFIG_CPU_SB1) || defined(CONFIG_CPU_SB1A) |
167 | #define KUSIZE _LLCONST_(0x0000100000000000) /* 2^^44 */ | ||
168 | #define KUSIZE_64 _LLCONST_(0x0000100000000000) /* 2^^44 */ | ||
169 | #define K0SIZE _LLCONST_(0x0000100000000000) /* 2^^44 */ | ||
170 | #define K1SIZE _LLCONST_(0x0000100000000000) /* 2^^44 */ | ||
171 | #define K2SIZE _LLCONST_(0x0000ffff80000000) | ||
172 | #define KSEGSIZE _LLCONST_(0x0000ffff80000000) /* max syssegsz */ | ||
173 | #define TO_PHYS_MASK _LLCONST_(0x00000fffffffffff) /* 2^^44 - 1 */ | 148 | #define TO_PHYS_MASK _LLCONST_(0x00000fffffffffff) /* 2^^44 - 1 */ |
174 | #endif | 149 | #endif |
175 | 150 | ||
176 | /* | ||
177 | * Further names for SGI source compatibility. These are stolen from | ||
178 | * IRIX's <sys/mips_addrspace.h>. | ||
179 | */ | ||
180 | #define KUBASE _LLCONST_(0) | ||
181 | #define KUSIZE_32 _LLCONST_(0x0000000080000000) /* KUSIZE | ||
182 | for a 32 bit proc */ | ||
183 | #define K0BASE_EXL_WR _LLCONST_(0xa800000000000000) /* exclusive on write */ | ||
184 | #define K0BASE_NONCOH _LLCONST_(0x9800000000000000) /* noncoherent */ | ||
185 | #define K0BASE_EXL _LLCONST_(0xa000000000000000) /* exclusive */ | ||
186 | |||
187 | #ifndef CONFIG_CPU_R8000 | 151 | #ifndef CONFIG_CPU_R8000 |
188 | 152 | ||
189 | /* | 153 | /* |
diff --git a/include/asm-mips/apm.h b/include/asm-mips/apm.h new file mode 100644 index 000000000000..e8c69208f63a --- /dev/null +++ b/include/asm-mips/apm.h | |||
@@ -0,0 +1,65 @@ | |||
1 | /* -*- linux-c -*- | ||
2 | * | ||
3 | * (C) 2003 zecke@handhelds.org | ||
4 | * | ||
5 | * GPL version 2 | ||
6 | * | ||
7 | * based on arch/arm/kernel/apm.c | ||
8 | * factor out the information needed by architectures to provide | ||
9 | * apm status | ||
10 | * | ||
11 | * | ||
12 | */ | ||
13 | #ifndef MIPS_ASM_SA1100_APM_H | ||
14 | #define MIPS_ASM_SA1100_APM_H | ||
15 | |||
16 | #include <linux/config.h> | ||
17 | #include <linux/apm_bios.h> | ||
18 | |||
19 | /* | ||
20 | * This structure gets filled in by the machine specific 'get_power_status' | ||
21 | * implementation. Any fields which are not set default to a safe value. | ||
22 | */ | ||
23 | struct apm_power_info { | ||
24 | unsigned char ac_line_status; | ||
25 | #define APM_AC_OFFLINE 0 | ||
26 | #define APM_AC_ONLINE 1 | ||
27 | #define APM_AC_BACKUP 2 | ||
28 | #define APM_AC_UNKNOWN 0xff | ||
29 | |||
30 | unsigned char battery_status; | ||
31 | #define APM_BATTERY_STATUS_HIGH 0 | ||
32 | #define APM_BATTERY_STATUS_LOW 1 | ||
33 | #define APM_BATTERY_STATUS_CRITICAL 2 | ||
34 | #define APM_BATTERY_STATUS_CHARGING 3 | ||
35 | #define APM_BATTERY_STATUS_NOT_PRESENT 4 | ||
36 | #define APM_BATTERY_STATUS_UNKNOWN 0xff | ||
37 | |||
38 | unsigned char battery_flag; | ||
39 | #define APM_BATTERY_FLAG_HIGH (1 << 0) | ||
40 | #define APM_BATTERY_FLAG_LOW (1 << 1) | ||
41 | #define APM_BATTERY_FLAG_CRITICAL (1 << 2) | ||
42 | #define APM_BATTERY_FLAG_CHARGING (1 << 3) | ||
43 | #define APM_BATTERY_FLAG_NOT_PRESENT (1 << 7) | ||
44 | #define APM_BATTERY_FLAG_UNKNOWN 0xff | ||
45 | |||
46 | int battery_life; | ||
47 | int time; | ||
48 | int units; | ||
49 | #define APM_UNITS_MINS 0 | ||
50 | #define APM_UNITS_SECS 1 | ||
51 | #define APM_UNITS_UNKNOWN -1 | ||
52 | |||
53 | }; | ||
54 | |||
55 | /* | ||
56 | * This allows machines to provide their own "apm get power status" function. | ||
57 | */ | ||
58 | extern void (*apm_get_power_status)(struct apm_power_info *); | ||
59 | |||
60 | /* | ||
61 | * Queue an event (APM_SYS_SUSPEND or APM_CRITICAL_SUSPEND) | ||
62 | */ | ||
63 | void apm_queue_event(apm_event_t event); | ||
64 | |||
65 | #endif | ||
diff --git a/include/asm-mips/arc/types.h b/include/asm-mips/arc/types.h index bbb725c366fb..b9adcd6f0860 100644 --- a/include/asm-mips/arc/types.h +++ b/include/asm-mips/arc/types.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_ARC_TYPES_H | 9 | #ifndef _ASM_ARC_TYPES_H |
10 | #define _ASM_ARC_TYPES_H | 10 | #define _ASM_ARC_TYPES_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | #ifdef CONFIG_ARC32 | 13 | #ifdef CONFIG_ARC32 |
15 | 14 | ||
diff --git a/include/asm-mips/asm.h b/include/asm-mips/asm.h index 4b090f3142e0..e3038a4599ee 100644 --- a/include/asm-mips/asm.h +++ b/include/asm-mips/asm.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #ifndef __ASM_ASM_H | 17 | #ifndef __ASM_ASM_H |
18 | #define __ASM_ASM_H | 18 | #define __ASM_ASM_H |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <asm/sgidefs.h> | 20 | #include <asm/sgidefs.h> |
22 | 21 | ||
23 | #ifndef CAT | 22 | #ifndef CAT |
diff --git a/include/asm-mips/asmmacro-32.h b/include/asm-mips/asmmacro-32.h index 11daf5ceb7b4..5de3963f511e 100644 --- a/include/asm-mips/asmmacro-32.h +++ b/include/asm-mips/asmmacro-32.h | |||
@@ -12,7 +12,7 @@ | |||
12 | #include <asm/fpregdef.h> | 12 | #include <asm/fpregdef.h> |
13 | #include <asm/mipsregs.h> | 13 | #include <asm/mipsregs.h> |
14 | 14 | ||
15 | .macro fpu_save_double thread status tmp1=t0 tmp2 | 15 | .macro fpu_save_double thread status tmp1=t0 |
16 | cfc1 \tmp1, fcr31 | 16 | cfc1 \tmp1, fcr31 |
17 | sdc1 $f0, THREAD_FPR0(\thread) | 17 | sdc1 $f0, THREAD_FPR0(\thread) |
18 | sdc1 $f2, THREAD_FPR2(\thread) | 18 | sdc1 $f2, THREAD_FPR2(\thread) |
@@ -70,7 +70,7 @@ | |||
70 | sw \tmp, THREAD_FCR31(\thread) | 70 | sw \tmp, THREAD_FCR31(\thread) |
71 | .endm | 71 | .endm |
72 | 72 | ||
73 | .macro fpu_restore_double thread tmp=t0 | 73 | .macro fpu_restore_double thread status tmp=t0 |
74 | lw \tmp, THREAD_FCR31(\thread) | 74 | lw \tmp, THREAD_FCR31(\thread) |
75 | ldc1 $f0, THREAD_FPR0(\thread) | 75 | ldc1 $f0, THREAD_FPR0(\thread) |
76 | ldc1 $f2, THREAD_FPR2(\thread) | 76 | ldc1 $f2, THREAD_FPR2(\thread) |
diff --git a/include/asm-mips/asmmacro-64.h b/include/asm-mips/asmmacro-64.h index 559c355b9b86..225feefcb25d 100644 --- a/include/asm-mips/asmmacro-64.h +++ b/include/asm-mips/asmmacro-64.h | |||
@@ -53,12 +53,12 @@ | |||
53 | sdc1 $f31, THREAD_FPR31(\thread) | 53 | sdc1 $f31, THREAD_FPR31(\thread) |
54 | .endm | 54 | .endm |
55 | 55 | ||
56 | .macro fpu_save_double thread status tmp1 tmp2 | 56 | .macro fpu_save_double thread status tmp |
57 | sll \tmp2, \tmp1, 5 | 57 | sll \tmp, \status, 5 |
58 | bgez \tmp2, 2f | 58 | bgez \tmp, 2f |
59 | fpu_save_16odd \thread | 59 | fpu_save_16odd \thread |
60 | 2: | 60 | 2: |
61 | fpu_save_16even \thread \tmp1 # clobbers t1 | 61 | fpu_save_16even \thread \tmp |
62 | .endm | 62 | .endm |
63 | 63 | ||
64 | .macro fpu_restore_16even thread tmp=t0 | 64 | .macro fpu_restore_16even thread tmp=t0 |
@@ -101,13 +101,12 @@ | |||
101 | ldc1 $f31, THREAD_FPR31(\thread) | 101 | ldc1 $f31, THREAD_FPR31(\thread) |
102 | .endm | 102 | .endm |
103 | 103 | ||
104 | .macro fpu_restore_double thread tmp | 104 | .macro fpu_restore_double thread status tmp |
105 | mfc0 t0, CP0_STATUS | 105 | sll \tmp, \status, 5 |
106 | sll t1, t0, 5 | 106 | bgez \tmp, 1f # 16 register mode? |
107 | bgez t1, 1f # 16 register mode? | ||
108 | 107 | ||
109 | fpu_restore_16odd a0 | 108 | fpu_restore_16odd \thread |
110 | 1: fpu_restore_16even a0, t0 # clobbers t0 | 109 | 1: fpu_restore_16even \thread \tmp |
111 | .endm | 110 | .endm |
112 | 111 | ||
113 | .macro cpu_save_nonscratch thread | 112 | .macro cpu_save_nonscratch thread |
diff --git a/include/asm-mips/asmmacro.h b/include/asm-mips/asmmacro.h index f54aa147ec19..2c42f6b00a49 100644 --- a/include/asm-mips/asmmacro.h +++ b/include/asm-mips/asmmacro.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef _ASM_ASMMACRO_H | 8 | #ifndef _ASM_ASMMACRO_H |
9 | #define _ASM_ASMMACRO_H | 9 | #define _ASM_ASMMACRO_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #include <asm/hazards.h> | 11 | #include <asm/hazards.h> |
13 | 12 | ||
14 | #ifdef CONFIG_32BIT | 13 | #ifdef CONFIG_32BIT |
diff --git a/include/asm-mips/atomic.h b/include/asm-mips/atomic.h index 2c8b853376c9..13d44e14025a 100644 --- a/include/asm-mips/atomic.h +++ b/include/asm-mips/atomic.h | |||
@@ -17,7 +17,6 @@ | |||
17 | * <linux/spinlock.h> we have to include <linux/spinlock.h> outside the | 17 | * <linux/spinlock.h> we have to include <linux/spinlock.h> outside the |
18 | * main big wrapper ... | 18 | * main big wrapper ... |
19 | */ | 19 | */ |
20 | #include <linux/config.h> | ||
21 | #include <linux/spinlock.h> | 20 | #include <linux/spinlock.h> |
22 | 21 | ||
23 | #ifndef _ASM_ATOMIC_H | 22 | #ifndef _ASM_ATOMIC_H |
diff --git a/include/asm-mips/bcache.h b/include/asm-mips/bcache.h index 446102b34f4e..3646a3f2ed38 100644 --- a/include/asm-mips/bcache.h +++ b/include/asm-mips/bcache.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_BCACHE_H | 9 | #ifndef _ASM_BCACHE_H |
10 | #define _ASM_BCACHE_H | 10 | #define _ASM_BCACHE_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | /* Some R4000 / R4400 / R4600 / R5000 machines may have a non-dma-coherent, | 13 | /* Some R4000 / R4400 / R4600 / R5000 machines may have a non-dma-coherent, |
15 | chipset implemented caches. On machines with other CPUs the CPU does the | 14 | chipset implemented caches. On machines with other CPUs the CPU does the |
diff --git a/include/asm-mips/bitops.h b/include/asm-mips/bitops.h index d2f444537e4b..098cec263681 100644 --- a/include/asm-mips/bitops.h +++ b/include/asm-mips/bitops.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_BITOPS_H | 9 | #ifndef _ASM_BITOPS_H |
10 | #define _ASM_BITOPS_H | 10 | #define _ASM_BITOPS_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/compiler.h> | 12 | #include <linux/compiler.h> |
14 | #include <linux/types.h> | 13 | #include <linux/types.h> |
15 | #include <asm/bug.h> | 14 | #include <asm/bug.h> |
diff --git a/include/asm-mips/bootinfo.h b/include/asm-mips/bootinfo.h index 14fc88f27226..3b745e76f429 100644 --- a/include/asm-mips/bootinfo.h +++ b/include/asm-mips/bootinfo.h | |||
@@ -217,6 +217,13 @@ | |||
217 | */ | 217 | */ |
218 | #define MACH_GROUP_TITAN 22 /* PMC-Sierra Titan */ | 218 | #define MACH_GROUP_TITAN 22 /* PMC-Sierra Titan */ |
219 | #define MACH_TITAN_YOSEMITE 1 /* PMC-Sierra Yosemite */ | 219 | #define MACH_TITAN_YOSEMITE 1 /* PMC-Sierra Yosemite */ |
220 | #define MACH_TITAN_EXCITE 2 /* Basler eXcite */ | ||
221 | |||
222 | /* | ||
223 | * Valid machtype for group NEC EMMA2RH | ||
224 | */ | ||
225 | #define MACH_GROUP_NEC_EMMA2RH 25 /* NEC EMMA2RH (was 23) */ | ||
226 | #define MACH_NEC_MARKEINS 0 /* NEC EMMA2RH Mark-eins */ | ||
220 | 227 | ||
221 | #define CL_SIZE COMMAND_LINE_SIZE | 228 | #define CL_SIZE COMMAND_LINE_SIZE |
222 | 229 | ||
@@ -258,4 +265,10 @@ extern char arcs_cmdline[CL_SIZE]; | |||
258 | * Registers a0, a1, a3 and a4 as passed to the kenrel entry by firmware | 265 | * Registers a0, a1, a3 and a4 as passed to the kenrel entry by firmware |
259 | */ | 266 | */ |
260 | extern unsigned long fw_arg0, fw_arg1, fw_arg2, fw_arg3; | 267 | extern unsigned long fw_arg0, fw_arg1, fw_arg2, fw_arg3; |
268 | |||
269 | /* | ||
270 | * Platform memory detection hook called by setup_arch | ||
271 | */ | ||
272 | extern void plat_mem_setup(void); | ||
273 | |||
261 | #endif /* _ASM_BOOTINFO_H */ | 274 | #endif /* _ASM_BOOTINFO_H */ |
diff --git a/include/asm-mips/bug.h b/include/asm-mips/bug.h index 87d49a5bdc63..7b4739dc8f3f 100644 --- a/include/asm-mips/bug.h +++ b/include/asm-mips/bug.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_BUG_H | 1 | #ifndef __ASM_BUG_H |
2 | #define __ASM_BUG_H | 2 | #define __ASM_BUG_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_BUG | 5 | #ifdef CONFIG_BUG |
7 | 6 | ||
diff --git a/include/asm-mips/bugs.h b/include/asm-mips/bugs.h index cb2ea7c15c7a..0d7f9c1f5546 100644 --- a/include/asm-mips/bugs.h +++ b/include/asm-mips/bugs.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef _ASM_BUGS_H | 7 | #ifndef _ASM_BUGS_H |
8 | #define _ASM_BUGS_H | 8 | #define _ASM_BUGS_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <linux/delay.h> | 10 | #include <linux/delay.h> |
12 | #include <asm/cpu.h> | 11 | #include <asm/cpu.h> |
13 | #include <asm/cpu-info.h> | 12 | #include <asm/cpu-info.h> |
diff --git a/include/asm-mips/byteorder.h b/include/asm-mips/byteorder.h index aefc02f16fd8..eee83cbdf2b0 100644 --- a/include/asm-mips/byteorder.h +++ b/include/asm-mips/byteorder.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef _ASM_BYTEORDER_H | 8 | #ifndef _ASM_BYTEORDER_H |
9 | #define _ASM_BYTEORDER_H | 9 | #define _ASM_BYTEORDER_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #include <linux/compiler.h> | 11 | #include <linux/compiler.h> |
13 | #include <asm/types.h> | 12 | #include <asm/types.h> |
14 | 13 | ||
diff --git a/include/asm-mips/cache.h b/include/asm-mips/cache.h index 55e19f2ff0e0..37f175c42bb5 100644 --- a/include/asm-mips/cache.h +++ b/include/asm-mips/cache.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_CACHE_H | 9 | #ifndef _ASM_CACHE_H |
10 | #define _ASM_CACHE_H | 10 | #define _ASM_CACHE_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <kmalloc.h> | 12 | #include <kmalloc.h> |
14 | 13 | ||
15 | #define L1_CACHE_SHIFT CONFIG_MIPS_L1_CACHE_SHIFT | 14 | #define L1_CACHE_SHIFT CONFIG_MIPS_L1_CACHE_SHIFT |
diff --git a/include/asm-mips/checksum.h b/include/asm-mips/checksum.h index b09f8971e95d..a5e6050ec0f3 100644 --- a/include/asm-mips/checksum.h +++ b/include/asm-mips/checksum.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_CHECKSUM_H | 11 | #ifndef _ASM_CHECKSUM_H |
12 | #define _ASM_CHECKSUM_H | 12 | #define _ASM_CHECKSUM_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/in6.h> | 14 | #include <linux/in6.h> |
16 | 15 | ||
17 | #include <asm/uaccess.h> | 16 | #include <asm/uaccess.h> |
diff --git a/include/asm-mips/cpu-features.h b/include/asm-mips/cpu-features.h index 254e11ed247b..881ce1f9803d 100644 --- a/include/asm-mips/cpu-features.h +++ b/include/asm-mips/cpu-features.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef __ASM_CPU_FEATURES_H | 9 | #ifndef __ASM_CPU_FEATURES_H |
10 | #define __ASM_CPU_FEATURES_H | 10 | #define __ASM_CPU_FEATURES_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | #include <asm/cpu.h> | 13 | #include <asm/cpu.h> |
15 | #include <asm/cpu-info.h> | 14 | #include <asm/cpu-info.h> |
diff --git a/include/asm-mips/cpu-info.h b/include/asm-mips/cpu-info.h index 6572ac703662..a2f0c8ea9160 100644 --- a/include/asm-mips/cpu-info.h +++ b/include/asm-mips/cpu-info.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef __ASM_CPU_INFO_H | 12 | #ifndef __ASM_CPU_INFO_H |
13 | #define __ASM_CPU_INFO_H | 13 | #define __ASM_CPU_INFO_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <asm/cache.h> | 15 | #include <asm/cache.h> |
17 | 16 | ||
18 | #ifdef CONFIG_SGI_IP27 | 17 | #ifdef CONFIG_SGI_IP27 |
diff --git a/include/asm-mips/ddb5074.h b/include/asm-mips/ddb5074.h deleted file mode 100644 index 0d09ac27f9a5..000000000000 --- a/include/asm-mips/ddb5074.h +++ /dev/null | |||
@@ -1,11 +0,0 @@ | |||
1 | /* | ||
2 | * include/asm-mips/ddb5074.h -- NEC DDB Vrc-5074 definitions | ||
3 | * | ||
4 | * Copyright (C) 2000 Geert Uytterhoeven <geert@sonycom.com> | ||
5 | * Sony Software Development Center Europe (SDCE), Brussels | ||
6 | */ | ||
7 | |||
8 | extern void ddb5074_led_hex(int hex); | ||
9 | extern void ddb5074_led_d2(int on); | ||
10 | extern void ddb5074_led_d3(int on); | ||
11 | |||
diff --git a/include/asm-mips/ddb5xxx/ddb5074.h b/include/asm-mips/ddb5xxx/ddb5074.h deleted file mode 100644 index 58d88306af65..000000000000 --- a/include/asm-mips/ddb5xxx/ddb5074.h +++ /dev/null | |||
@@ -1,38 +0,0 @@ | |||
1 | /* | ||
2 | * include/asm-mips/ddb5074.h -- NEC DDB Vrc-5074 definitions | ||
3 | * | ||
4 | * Copyright (C) 2000 Geert Uytterhoeven <geert@sonycom.com> | ||
5 | * Sony Software Development Center Europe (SDCE), Brussels | ||
6 | */ | ||
7 | |||
8 | #ifndef _ASM_DDB5XXX_DDB5074_H | ||
9 | #define _ASM_DDB5XXX_DDB5074_H | ||
10 | |||
11 | #include <asm/nile4.h> | ||
12 | |||
13 | #define DDB_SDRAM_SIZE 0x04000000 /* 64MB */ | ||
14 | |||
15 | #define DDB_PCI_IO_BASE 0x06000000 | ||
16 | #define DDB_PCI_IO_SIZE 0x02000000 /* 32 MB */ | ||
17 | |||
18 | #define DDB_PCI_MEM_BASE 0x08000000 | ||
19 | #define DDB_PCI_MEM_SIZE 0x08000000 /* 128 MB */ | ||
20 | |||
21 | #define DDB_PCI_CONFIG_BASE DDB_PCI_MEM_BASE | ||
22 | #define DDB_PCI_CONFIG_SIZE DDB_PCI_MEM_SIZE | ||
23 | |||
24 | #define NILE4_PCI_IO_BASE 0xa6000000 | ||
25 | #define NILE4_PCI_MEM_BASE 0xa8000000 | ||
26 | #define NILE4_PCI_CFG_BASE NILE4_PCI_MEM_BASE | ||
27 | #define DDB_PCI_IACK_BASE NILE4_PCI_IO_BASE | ||
28 | |||
29 | #define NILE4_IRQ_BASE NUM_I8259_INTERRUPTS | ||
30 | #define CPU_IRQ_BASE (NUM_NILE4_INTERRUPTS + NILE4_IRQ_BASE) | ||
31 | #define CPU_NILE4_CASCADE 2 | ||
32 | |||
33 | extern void ddb5074_led_hex(int hex); | ||
34 | extern void ddb5074_led_d2(int on); | ||
35 | extern void ddb5074_led_d3(int on); | ||
36 | |||
37 | extern void nile4_irq_setup(u32 base); | ||
38 | #endif | ||
diff --git a/include/asm-mips/ddb5xxx/ddb5476.h b/include/asm-mips/ddb5xxx/ddb5476.h deleted file mode 100644 index 4c23390d9354..000000000000 --- a/include/asm-mips/ddb5xxx/ddb5476.h +++ /dev/null | |||
@@ -1,157 +0,0 @@ | |||
1 | /* | ||
2 | * header file specific for ddb5476 | ||
3 | * | ||
4 | * Copyright (C) 2001 MontaVista Software Inc. | ||
5 | * Author: Jun Sun, jsun@mvista.com or jsun@junsun.net | ||
6 | * | ||
7 | * This program is free software; you can redistribute it and/or modify it | ||
8 | * under the terms of the GNU General Public License as published by the | ||
9 | * Free Software Foundation; either version 2 of the License, or (at your | ||
10 | * option) any later version. | ||
11 | * | ||
12 | */ | ||
13 | |||
14 | /* | ||
15 | * Memory map (physical address) | ||
16 | * | ||
17 | * Note most of the following address must be properly aligned by the | ||
18 | * corresponding size. For example, if PCI_IO_SIZE is 16MB, then | ||
19 | * PCI_IO_BASE must be aligned along 16MB boundary. | ||
20 | */ | ||
21 | #define DDB_SDRAM_BASE 0x00000000 | ||
22 | #define DDB_SDRAM_SIZE 0x04000000 /* 64MB */ | ||
23 | |||
24 | #define DDB_DCS3_BASE 0x04000000 /* flash 1 */ | ||
25 | #define DDB_DCS3_SIZE 0x01000000 /* 16MB */ | ||
26 | |||
27 | #define DDB_DCS2_BASE 0x05000000 /* flash 2 */ | ||
28 | #define DDB_DCS2_SIZE 0x01000000 /* 16MB */ | ||
29 | |||
30 | #define DDB_PCI_IO_BASE 0x06000000 | ||
31 | #define DDB_PCI_IO_SIZE 0x02000000 /* 32 MB */ | ||
32 | |||
33 | #define DDB_PCI_MEM_BASE 0x08000000 | ||
34 | #define DDB_PCI_MEM_SIZE 0x08000000 /* 128 MB */ | ||
35 | |||
36 | #define DDB_DCS5_BASE 0x13000000 /* DDB status regs */ | ||
37 | #define DDB_DCS5_SIZE 0x00200000 /* 2MB, 8-bit */ | ||
38 | |||
39 | #define DDB_DCS4_BASE 0x14000000 /* DDB control regs */ | ||
40 | #define DDB_DCS4_SIZE 0x00200000 /* 2MB, 8-bit */ | ||
41 | |||
42 | #define DDB_INTCS_BASE 0x1fa00000 /* VRC5476 control regs */ | ||
43 | #define DDB_INTCS_SIZE 0x00200000 /* 2MB */ | ||
44 | |||
45 | #define DDB_BOOTCS_BASE 0x1fc00000 /* Boot ROM / EPROM /Flash */ | ||
46 | #define DDB_BOOTCS_SIZE 0x00200000 /* 2 MB - doc says 4MB */ | ||
47 | |||
48 | |||
49 | /* aliases */ | ||
50 | #define DDB_PCI_CONFIG_BASE DDB_PCI_MEM_BASE | ||
51 | #define DDB_PCI_CONFIG_SIZE DDB_PCI_MEM_SIZE | ||
52 | |||
53 | /* PCI intr ack share PCIW0 with PCI IO */ | ||
54 | #define DDB_PCI_IACK_BASE DDB_PCI_IO_BASE | ||
55 | |||
56 | /* | ||
57 | * Interrupt mapping | ||
58 | * | ||
59 | * We have three interrupt controllers: | ||
60 | * | ||
61 | * . CPU itself - 8 sources | ||
62 | * . i8259 - 16 sources | ||
63 | * . vrc5476 - 16 sources | ||
64 | * | ||
65 | * They connected as follows: | ||
66 | * all vrc5476 interrupts are routed to cpu IP2 (by software setting) | ||
67 | * all i2869 are routed to INTC in vrc5476 (by hardware connection) | ||
68 | * | ||
69 | * All VRC5476 PCI interrupts are level-triggered (no ack needed). | ||
70 | * All PCI irq but INTC are active low. | ||
71 | */ | ||
72 | |||
73 | /* | ||
74 | * irq number block assignment | ||
75 | */ | ||
76 | |||
77 | #define NUM_CPU_IRQ 8 | ||
78 | #define NUM_I8259_IRQ 16 | ||
79 | #define NUM_VRC5476_IRQ 16 | ||
80 | |||
81 | #define DDB_IRQ_BASE 0 | ||
82 | |||
83 | #define I8259_IRQ_BASE DDB_IRQ_BASE | ||
84 | #define VRC5476_IRQ_BASE (I8259_IRQ_BASE + NUM_I8259_IRQ) | ||
85 | #define CPU_IRQ_BASE (VRC5476_IRQ_BASE + NUM_VRC5476_IRQ) | ||
86 | |||
87 | /* | ||
88 | * vrc5476 irq defs, see page 52-64 of Vrc5074 system controller manual | ||
89 | */ | ||
90 | |||
91 | #define VRC5476_IRQ_CPCE 0 /* cpu parity error */ | ||
92 | #define VRC5476_IRQ_CNTD 1 /* cpu no target */ | ||
93 | #define VRC5476_IRQ_MCE 2 /* memory check error */ | ||
94 | #define VRC5476_IRQ_DMA 3 /* DMA */ | ||
95 | #define VRC5476_IRQ_UART 4 /* vrc5476 builtin UART, not used */ | ||
96 | #define VRC5476_IRQ_WDOG 5 /* watchdog timer */ | ||
97 | #define VRC5476_IRQ_GPT 6 /* general purpose timer */ | ||
98 | #define VRC5476_IRQ_LBRT 7 /* local bus read timeout */ | ||
99 | #define VRC5476_IRQ_INTA 8 /* PCI INT #A */ | ||
100 | #define VRC5476_IRQ_INTB 9 /* PCI INT #B */ | ||
101 | #define VRC5476_IRQ_INTC 10 /* PCI INT #C */ | ||
102 | #define VRC5476_IRQ_INTD 11 /* PCI INT #D */ | ||
103 | #define VRC5476_IRQ_INTE 12 /* PCI INT #E */ | ||
104 | #define VRC5476_IRQ_RESERVED_13 13 /* reserved */ | ||
105 | #define VRC5476_IRQ_PCIS 14 /* PCI SERR # */ | ||
106 | #define VRC5476_IRQ_PCI 15 /* PCI internal error */ | ||
107 | |||
108 | /* | ||
109 | * i2859 irq assignment | ||
110 | */ | ||
111 | #define I8259_IRQ_RESERVED_0 0 | ||
112 | #define I8259_IRQ_KEYBOARD 1 /* M1543 default */ | ||
113 | #define I8259_IRQ_CASCADE 2 | ||
114 | #define I8259_IRQ_UART_B 3 /* M1543 default, may conflict with RTC according to schematic diagram */ | ||
115 | #define I8259_IRQ_UART_A 4 /* M1543 default */ | ||
116 | #define I8259_IRQ_PARALLEL 5 /* M1543 default */ | ||
117 | #define I8259_IRQ_RESERVED_6 6 | ||
118 | #define I8259_IRQ_RESERVED_7 7 | ||
119 | #define I8259_IRQ_RTC 8 /* who set this? */ | ||
120 | #define I8259_IRQ_USB 9 /* ddb_setup */ | ||
121 | #define I8259_IRQ_PMU 10 /* ddb_setup */ | ||
122 | #define I8259_IRQ_RESERVED_11 11 | ||
123 | #define I8259_IRQ_RESERVED_12 12 /* m1543_irq_setup */ | ||
124 | #define I8259_IRQ_RESERVED_13 13 | ||
125 | #define I8259_IRQ_HDC1 14 /* default and ddb_setup */ | ||
126 | #define I8259_IRQ_HDC2 15 /* default */ | ||
127 | |||
128 | |||
129 | /* | ||
130 | * misc | ||
131 | */ | ||
132 | #define VRC5476_I8259_CASCADE VRC5476_IRQ_INTC | ||
133 | #define CPU_VRC5476_CASCADE 2 | ||
134 | |||
135 | #define is_i8259_irq(irq) ((irq) < NUM_I8259_IRQ) | ||
136 | #define nile4_to_irq(n) ((n)+NUM_I8259_IRQ) | ||
137 | #define irq_to_nile4(n) ((n)-NUM_I8259_IRQ) | ||
138 | |||
139 | /* | ||
140 | * low-level irq functions | ||
141 | */ | ||
142 | #ifndef __ASSEMBLY__ | ||
143 | extern void nile4_map_irq(int nile4_irq, int cpu_irq); | ||
144 | extern void nile4_map_irq_all(int cpu_irq); | ||
145 | extern void nile4_enable_irq(int nile4_irq); | ||
146 | extern void nile4_disable_irq(int nile4_irq); | ||
147 | extern void nile4_disable_irq_all(void); | ||
148 | extern u16 nile4_get_irq_stat(int cpu_irq); | ||
149 | extern void nile4_enable_irq_output(int cpu_irq); | ||
150 | extern void nile4_disable_irq_output(int cpu_irq); | ||
151 | extern void nile4_set_pci_irq_polarity(int pci_irq, int high); | ||
152 | extern void nile4_set_pci_irq_level_or_edge(int pci_irq, int level); | ||
153 | extern void nile4_clear_irq(int nile4_irq); | ||
154 | extern void nile4_clear_irq_mask(u32 mask); | ||
155 | extern u8 nile4_i8259_iack(void); | ||
156 | extern void nile4_dump_irq_status(void); /* Debug */ | ||
157 | #endif /* !__ASSEMBLY__ */ | ||
diff --git a/include/asm-mips/ddb5xxx/ddb5477.h b/include/asm-mips/ddb5xxx/ddb5477.h index a438548e6ef3..c5af4b73fdd7 100644 --- a/include/asm-mips/ddb5xxx/ddb5477.h +++ b/include/asm-mips/ddb5xxx/ddb5477.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #ifndef __ASM_DDB5XXX_DDB5477_H | 17 | #ifndef __ASM_DDB5XXX_DDB5477_H |
18 | #define __ASM_DDB5XXX_DDB5477_H | 18 | #define __ASM_DDB5XXX_DDB5477_H |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | 20 | ||
22 | /* | 21 | /* |
23 | * This contains macros that are specific to DDB5477 or renamed from | 22 | * This contains macros that are specific to DDB5477 or renamed from |
diff --git a/include/asm-mips/ddb5xxx/ddb5xxx.h b/include/asm-mips/ddb5xxx/ddb5xxx.h index 873c03f2c5fe..e97fcc8d548b 100644 --- a/include/asm-mips/ddb5xxx/ddb5xxx.h +++ b/include/asm-mips/ddb5xxx/ddb5xxx.h | |||
@@ -18,7 +18,6 @@ | |||
18 | #ifndef __ASM_DDB5XXX_DDB5XXX_H | 18 | #ifndef __ASM_DDB5XXX_DDB5XXX_H |
19 | #define __ASM_DDB5XXX_DDB5XXX_H | 19 | #define __ASM_DDB5XXX_DDB5XXX_H |
20 | 20 | ||
21 | #include <linux/config.h> | ||
22 | #include <linux/types.h> | 21 | #include <linux/types.h> |
23 | 22 | ||
24 | /* | 23 | /* |
@@ -174,13 +173,8 @@ | |||
174 | 173 | ||
175 | static inline void ddb_sync(void) | 174 | static inline void ddb_sync(void) |
176 | { | 175 | { |
177 | /* The DDB5074 doesn't seem to like these accesses. They kill the board on | ||
178 | * interrupt load | ||
179 | */ | ||
180 | #ifndef CONFIG_DDB5074 | ||
181 | volatile u32 *p = (volatile u32 *)0xbfc00000; | 176 | volatile u32 *p = (volatile u32 *)0xbfc00000; |
182 | (void)(*p); | 177 | (void)(*p); |
183 | #endif | ||
184 | } | 178 | } |
185 | 179 | ||
186 | static inline void ddb_out32(u32 offset, u32 val) | 180 | static inline void ddb_out32(u32 offset, u32 val) |
@@ -260,11 +254,7 @@ extern void ddb_pci_reset_bus(void); | |||
260 | /* | 254 | /* |
261 | * include the board dependent part | 255 | * include the board dependent part |
262 | */ | 256 | */ |
263 | #if defined(CONFIG_DDB5074) | 257 | #if defined(CONFIG_DDB5477) |
264 | #include <asm/ddb5xxx/ddb5074.h> | ||
265 | #elif defined(CONFIG_DDB5476) | ||
266 | #include <asm/ddb5xxx/ddb5476.h> | ||
267 | #elif defined(CONFIG_DDB5477) | ||
268 | #include <asm/ddb5xxx/ddb5477.h> | 258 | #include <asm/ddb5xxx/ddb5477.h> |
269 | #else | 259 | #else |
270 | #error "Unknown DDB board!" | 260 | #error "Unknown DDB board!" |
diff --git a/include/asm-mips/debug.h b/include/asm-mips/debug.h index 930f2b75e766..1fd5a2b39445 100644 --- a/include/asm-mips/debug.h +++ b/include/asm-mips/debug.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #ifndef _ASM_DEBUG_H | 15 | #ifndef _ASM_DEBUG_H |
16 | #define _ASM_DEBUG_H | 16 | #define _ASM_DEBUG_H |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | 18 | ||
20 | /* | 19 | /* |
21 | * run-time macros for catching spurious errors. Eable CONFIG_RUNTIME_DEBUG in | 20 | * run-time macros for catching spurious errors. Eable CONFIG_RUNTIME_DEBUG in |
diff --git a/include/asm-mips/dec/prom.h b/include/asm-mips/dec/prom.h index 1384dd0964b9..b9c8203688d5 100644 --- a/include/asm-mips/dec/prom.h +++ b/include/asm-mips/dec/prom.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #ifndef _ASM_DEC_PROM_H | 15 | #ifndef _ASM_DEC_PROM_H |
16 | #define _ASM_DEC_PROM_H | 16 | #define _ASM_DEC_PROM_H |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | #include <linux/types.h> | 18 | #include <linux/types.h> |
20 | 19 | ||
21 | #include <asm/addrspace.h> | 20 | #include <asm/addrspace.h> |
diff --git a/include/asm-mips/delay.h b/include/asm-mips/delay.h index 928f30f8c45c..ea77050f8e3a 100644 --- a/include/asm-mips/delay.h +++ b/include/asm-mips/delay.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASM_DELAY_H | 10 | #ifndef _ASM_DELAY_H |
11 | #define _ASM_DELAY_H | 11 | #define _ASM_DELAY_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/param.h> | 13 | #include <linux/param.h> |
15 | #include <linux/smp.h> | 14 | #include <linux/smp.h> |
16 | #include <asm/compiler.h> | 15 | #include <asm/compiler.h> |
diff --git a/include/asm-mips/dma.h b/include/asm-mips/dma.h index 6aaf9939a716..e85849ac165f 100644 --- a/include/asm-mips/dma.h +++ b/include/asm-mips/dma.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef _ASM_DMA_H | 12 | #ifndef _ASM_DMA_H |
13 | #define _ASM_DMA_H | 13 | #define _ASM_DMA_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <asm/io.h> /* need byte IO */ | 15 | #include <asm/io.h> /* need byte IO */ |
17 | #include <linux/spinlock.h> /* And spinlocks */ | 16 | #include <linux/spinlock.h> /* And spinlocks */ |
18 | #include <linux/delay.h> | 17 | #include <linux/delay.h> |
diff --git a/include/asm-mips/elf.h b/include/asm-mips/elf.h index bdc9de2df1ef..ebd6bfb19d66 100644 --- a/include/asm-mips/elf.h +++ b/include/asm-mips/elf.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef _ASM_ELF_H | 8 | #ifndef _ASM_ELF_H |
9 | #define _ASM_ELF_H | 9 | #define _ASM_ELF_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | 11 | ||
13 | /* ELF header e_flags defines. */ | 12 | /* ELF header e_flags defines. */ |
14 | /* MIPS architecture level. */ | 13 | /* MIPS architecture level. */ |
diff --git a/include/asm-mips/emma2rh/emma2rh.h b/include/asm-mips/emma2rh/emma2rh.h new file mode 100644 index 000000000000..4fb8df71caa9 --- /dev/null +++ b/include/asm-mips/emma2rh/emma2rh.h | |||
@@ -0,0 +1,330 @@ | |||
1 | /* | ||
2 | * include/asm-mips/emma2rh/emma2rh.h | ||
3 | * This file is EMMA2RH common header. | ||
4 | * | ||
5 | * Copyright (C) NEC Electronics Corporation 2005-2006 | ||
6 | * | ||
7 | * This file based on include/asm-mips/ddb5xxx/ddb5xxx.h | ||
8 | * Copyright 2001 MontaVista Software Inc. | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify | ||
11 | * it under the terms of the GNU General Public License as published by | ||
12 | * the Free Software Foundation; either version 2 of the License, or | ||
13 | * (at your option) any later version. | ||
14 | * | ||
15 | * This program is distributed in the hope that it will be useful, | ||
16 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
17 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
18 | * GNU General Public License for more details. | ||
19 | * | ||
20 | * You should have received a copy of the GNU General Public License | ||
21 | * along with this program; if not, write to the Free Software | ||
22 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
23 | */ | ||
24 | #ifndef __ASM_EMMA2RH_EMMA2RH_H | ||
25 | #define __ASM_EMMA2RH_EMMA2RH_H | ||
26 | |||
27 | /* | ||
28 | * EMMA2RH registers | ||
29 | */ | ||
30 | #define REGBASE 0x10000000 | ||
31 | |||
32 | #define EMMA2RH_BHIF_STRAP_0 (0x000010+REGBASE) | ||
33 | #define EMMA2RH_BHIF_INT_ST_0 (0x000030+REGBASE) | ||
34 | #define EMMA2RH_BHIF_INT_ST_1 (0x000034+REGBASE) | ||
35 | #define EMMA2RH_BHIF_INT_ST_2 (0x000038+REGBASE) | ||
36 | #define EMMA2RH_BHIF_INT_EN_0 (0x000040+REGBASE) | ||
37 | #define EMMA2RH_BHIF_INT_EN_1 (0x000044+REGBASE) | ||
38 | #define EMMA2RH_BHIF_INT_EN_2 (0x000048+REGBASE) | ||
39 | #define EMMA2RH_BHIF_INT1_EN_0 (0x000050+REGBASE) | ||
40 | #define EMMA2RH_BHIF_INT1_EN_1 (0x000054+REGBASE) | ||
41 | #define EMMA2RH_BHIF_INT1_EN_2 (0x000058+REGBASE) | ||
42 | #define EMMA2RH_BHIF_SW_INT (0x000070+REGBASE) | ||
43 | #define EMMA2RH_BHIF_SW_INT_EN (0x000080+REGBASE) | ||
44 | #define EMMA2RH_BHIF_SW_INT_CLR (0x000090+REGBASE) | ||
45 | #define EMMA2RH_BHIF_MAIN_CTRL (0x0000b4+REGBASE) | ||
46 | #define EMMA2RH_BHIF_EXCEPT_VECT_BASE_ADDRESS (0x0000c0+REGBASE) | ||
47 | #define EMMA2RH_GPIO_DIR (0x110d20+REGBASE) | ||
48 | #define EMMA2RH_GPIO_INT_ST (0x110d30+REGBASE) | ||
49 | #define EMMA2RH_GPIO_INT_MASK (0x110d3c+REGBASE) | ||
50 | #define EMMA2RH_GPIO_INT_MODE (0x110d48+REGBASE) | ||
51 | #define EMMA2RH_GPIO_INT_CND_A (0x110d54+REGBASE) | ||
52 | #define EMMA2RH_GPIO_INT_CND_B (0x110d60+REGBASE) | ||
53 | #define EMMA2RH_PBRD_INT_EN (0x100010+REGBASE) | ||
54 | #define EMMA2RH_PBRD_CLKSEL (0x100028+REGBASE) | ||
55 | #define EMMA2RH_PFUR0_BASE (0x101000+REGBASE) | ||
56 | #define EMMA2RH_PFUR1_BASE (0x102000+REGBASE) | ||
57 | #define EMMA2RH_PFUR2_BASE (0x103000+REGBASE) | ||
58 | #define EMMA2RH_PIIC0_BASE (0x107000+REGBASE) | ||
59 | #define EMMA2RH_PIIC1_BASE (0x108000+REGBASE) | ||
60 | #define EMMA2RH_PIIC2_BASE (0x109000+REGBASE) | ||
61 | #define EMMA2RH_PCI_CONTROL (0x200000+REGBASE) | ||
62 | #define EMMA2RH_PCI_ARBIT_CTR (0x200004+REGBASE) | ||
63 | #define EMMA2RH_PCI_IWIN0_CTR (0x200010+REGBASE) | ||
64 | #define EMMA2RH_PCI_IWIN1_CTR (0x200014+REGBASE) | ||
65 | #define EMMA2RH_PCI_INIT_ESWP (0x200018+REGBASE) | ||
66 | #define EMMA2RH_PCI_INT (0x200020+REGBASE) | ||
67 | #define EMMA2RH_PCI_INT_EN (0x200024+REGBASE) | ||
68 | #define EMMA2RH_PCI_TWIN_CTR (0x200030+REGBASE) | ||
69 | #define EMMA2RH_PCI_TWIN_BADR (0x200034+REGBASE) | ||
70 | #define EMMA2RH_PCI_TWIN0_DADR (0x200038+REGBASE) | ||
71 | #define EMMA2RH_PCI_TWIN1_DADR (0x20003c+REGBASE) | ||
72 | |||
73 | /* | ||
74 | * Memory map (physical address) | ||
75 | * | ||
76 | * Note most of the following address must be properly aligned by the | ||
77 | * corresponding size. For example, if PCI_IO_SIZE is 16MB, then | ||
78 | * PCI_IO_BASE must be aligned along 16MB boundary. | ||
79 | */ | ||
80 | |||
81 | /* the actual ram size is detected at run-time */ | ||
82 | #define EMMA2RH_RAM_BASE 0x00000000 | ||
83 | #define EMMA2RH_RAM_SIZE 0x10000000 /* less than 256MB */ | ||
84 | |||
85 | #define EMMA2RH_IO_BASE 0x10000000 | ||
86 | #define EMMA2RH_IO_SIZE 0x01000000 /* 16 MB */ | ||
87 | |||
88 | #define EMMA2RH_GENERALIO_BASE 0x11000000 | ||
89 | #define EMMA2RH_GENERALIO_SIZE 0x01000000 /* 16 MB */ | ||
90 | |||
91 | #define EMMA2RH_PCI_IO_BASE 0x12000000 | ||
92 | #define EMMA2RH_PCI_IO_SIZE 0x02000000 /* 32 MB */ | ||
93 | |||
94 | #define EMMA2RH_PCI_MEM_BASE 0x14000000 | ||
95 | #define EMMA2RH_PCI_MEM_SIZE 0x08000000 /* 128 MB */ | ||
96 | |||
97 | #define EMMA2RH_ROM_BASE 0x1c000000 | ||
98 | #define EMMA2RH_ROM_SIZE 0x04000000 /* 64 MB */ | ||
99 | |||
100 | #define EMMA2RH_PCI_CONFIG_BASE EMMA2RH_PCI_IO_BASE | ||
101 | #define EMMA2RH_PCI_CONFIG_SIZE EMMA2RH_PCI_IO_SIZE | ||
102 | |||
103 | #define NUM_CPU_IRQ 8 | ||
104 | #define NUM_EMMA2RH_IRQ 96 | ||
105 | |||
106 | #define CPU_EMMA2RH_CASCADE 2 | ||
107 | #define EMMA2RH_IRQ_BASE 0 | ||
108 | |||
109 | /* | ||
110 | * emma2rh irq defs | ||
111 | */ | ||
112 | |||
113 | #define EMMA2RH_IRQ_INT0 (0 + EMMA2RH_IRQ_BASE) | ||
114 | #define EMMA2RH_IRQ_INT1 (1 + EMMA2RH_IRQ_BASE) | ||
115 | #define EMMA2RH_IRQ_INT2 (2 + EMMA2RH_IRQ_BASE) | ||
116 | #define EMMA2RH_IRQ_INT3 (3 + EMMA2RH_IRQ_BASE) | ||
117 | #define EMMA2RH_IRQ_INT4 (4 + EMMA2RH_IRQ_BASE) | ||
118 | #define EMMA2RH_IRQ_INT5 (5 + EMMA2RH_IRQ_BASE) | ||
119 | #define EMMA2RH_IRQ_INT6 (6 + EMMA2RH_IRQ_BASE) | ||
120 | #define EMMA2RH_IRQ_INT7 (7 + EMMA2RH_IRQ_BASE) | ||
121 | #define EMMA2RH_IRQ_INT8 (8 + EMMA2RH_IRQ_BASE) | ||
122 | #define EMMA2RH_IRQ_INT9 (9 + EMMA2RH_IRQ_BASE) | ||
123 | #define EMMA2RH_IRQ_INT10 (10 + EMMA2RH_IRQ_BASE) | ||
124 | #define EMMA2RH_IRQ_INT11 (11 + EMMA2RH_IRQ_BASE) | ||
125 | #define EMMA2RH_IRQ_INT12 (12 + EMMA2RH_IRQ_BASE) | ||
126 | #define EMMA2RH_IRQ_INT13 (13 + EMMA2RH_IRQ_BASE) | ||
127 | #define EMMA2RH_IRQ_INT14 (14 + EMMA2RH_IRQ_BASE) | ||
128 | #define EMMA2RH_IRQ_INT15 (15 + EMMA2RH_IRQ_BASE) | ||
129 | #define EMMA2RH_IRQ_INT16 (16 + EMMA2RH_IRQ_BASE) | ||
130 | #define EMMA2RH_IRQ_INT17 (17 + EMMA2RH_IRQ_BASE) | ||
131 | #define EMMA2RH_IRQ_INT18 (18 + EMMA2RH_IRQ_BASE) | ||
132 | #define EMMA2RH_IRQ_INT19 (19 + EMMA2RH_IRQ_BASE) | ||
133 | #define EMMA2RH_IRQ_INT20 (20 + EMMA2RH_IRQ_BASE) | ||
134 | #define EMMA2RH_IRQ_INT21 (21 + EMMA2RH_IRQ_BASE) | ||
135 | #define EMMA2RH_IRQ_INT22 (22 + EMMA2RH_IRQ_BASE) | ||
136 | #define EMMA2RH_IRQ_INT23 (23 + EMMA2RH_IRQ_BASE) | ||
137 | #define EMMA2RH_IRQ_INT24 (24 + EMMA2RH_IRQ_BASE) | ||
138 | #define EMMA2RH_IRQ_INT25 (25 + EMMA2RH_IRQ_BASE) | ||
139 | #define EMMA2RH_IRQ_INT26 (26 + EMMA2RH_IRQ_BASE) | ||
140 | #define EMMA2RH_IRQ_INT27 (27 + EMMA2RH_IRQ_BASE) | ||
141 | #define EMMA2RH_IRQ_INT28 (28 + EMMA2RH_IRQ_BASE) | ||
142 | #define EMMA2RH_IRQ_INT29 (29 + EMMA2RH_IRQ_BASE) | ||
143 | #define EMMA2RH_IRQ_INT30 (30 + EMMA2RH_IRQ_BASE) | ||
144 | #define EMMA2RH_IRQ_INT31 (31 + EMMA2RH_IRQ_BASE) | ||
145 | #define EMMA2RH_IRQ_INT32 (32 + EMMA2RH_IRQ_BASE) | ||
146 | #define EMMA2RH_IRQ_INT33 (33 + EMMA2RH_IRQ_BASE) | ||
147 | #define EMMA2RH_IRQ_INT34 (34 + EMMA2RH_IRQ_BASE) | ||
148 | #define EMMA2RH_IRQ_INT35 (35 + EMMA2RH_IRQ_BASE) | ||
149 | #define EMMA2RH_IRQ_INT36 (36 + EMMA2RH_IRQ_BASE) | ||
150 | #define EMMA2RH_IRQ_INT37 (37 + EMMA2RH_IRQ_BASE) | ||
151 | #define EMMA2RH_IRQ_INT38 (38 + EMMA2RH_IRQ_BASE) | ||
152 | #define EMMA2RH_IRQ_INT39 (39 + EMMA2RH_IRQ_BASE) | ||
153 | #define EMMA2RH_IRQ_INT40 (40 + EMMA2RH_IRQ_BASE) | ||
154 | #define EMMA2RH_IRQ_INT41 (41 + EMMA2RH_IRQ_BASE) | ||
155 | #define EMMA2RH_IRQ_INT42 (42 + EMMA2RH_IRQ_BASE) | ||
156 | #define EMMA2RH_IRQ_INT43 (43 + EMMA2RH_IRQ_BASE) | ||
157 | #define EMMA2RH_IRQ_INT44 (44 + EMMA2RH_IRQ_BASE) | ||
158 | #define EMMA2RH_IRQ_INT45 (45 + EMMA2RH_IRQ_BASE) | ||
159 | #define EMMA2RH_IRQ_INT46 (46 + EMMA2RH_IRQ_BASE) | ||
160 | #define EMMA2RH_IRQ_INT47 (47 + EMMA2RH_IRQ_BASE) | ||
161 | #define EMMA2RH_IRQ_INT48 (48 + EMMA2RH_IRQ_BASE) | ||
162 | #define EMMA2RH_IRQ_INT49 (49 + EMMA2RH_IRQ_BASE) | ||
163 | #define EMMA2RH_IRQ_INT50 (50 + EMMA2RH_IRQ_BASE) | ||
164 | #define EMMA2RH_IRQ_INT51 (51 + EMMA2RH_IRQ_BASE) | ||
165 | #define EMMA2RH_IRQ_INT52 (52 + EMMA2RH_IRQ_BASE) | ||
166 | #define EMMA2RH_IRQ_INT53 (53 + EMMA2RH_IRQ_BASE) | ||
167 | #define EMMA2RH_IRQ_INT54 (54 + EMMA2RH_IRQ_BASE) | ||
168 | #define EMMA2RH_IRQ_INT55 (55 + EMMA2RH_IRQ_BASE) | ||
169 | #define EMMA2RH_IRQ_INT56 (56 + EMMA2RH_IRQ_BASE) | ||
170 | #define EMMA2RH_IRQ_INT57 (57 + EMMA2RH_IRQ_BASE) | ||
171 | #define EMMA2RH_IRQ_INT58 (58 + EMMA2RH_IRQ_BASE) | ||
172 | #define EMMA2RH_IRQ_INT59 (59 + EMMA2RH_IRQ_BASE) | ||
173 | #define EMMA2RH_IRQ_INT60 (60 + EMMA2RH_IRQ_BASE) | ||
174 | #define EMMA2RH_IRQ_INT61 (61 + EMMA2RH_IRQ_BASE) | ||
175 | #define EMMA2RH_IRQ_INT62 (62 + EMMA2RH_IRQ_BASE) | ||
176 | #define EMMA2RH_IRQ_INT63 (63 + EMMA2RH_IRQ_BASE) | ||
177 | |||
178 | #define EMMA2RH_IRQ_PFUR0 EMMA2RH_IRQ_INT49 | ||
179 | #define EMMA2RH_IRQ_PFUR1 EMMA2RH_IRQ_INT50 | ||
180 | #define EMMA2RH_IRQ_PFUR2 EMMA2RH_IRQ_INT51 | ||
181 | #define EMMA2RH_IRQ_PIIC0 EMMA2RH_IRQ_INT56 | ||
182 | #define EMMA2RH_IRQ_PIIC1 EMMA2RH_IRQ_INT57 | ||
183 | #define EMMA2RH_IRQ_PIIC2 EMMA2RH_IRQ_INT58 | ||
184 | |||
185 | /* | ||
186 | * EMMA2RH Register Access | ||
187 | */ | ||
188 | |||
189 | #define EMMA2RH_BASE (0xa0000000) | ||
190 | |||
191 | static inline void emma2rh_sync(void) | ||
192 | { | ||
193 | volatile u32 *p = (volatile u32 *)0xbfc00000; | ||
194 | (void)(*p); | ||
195 | } | ||
196 | |||
197 | static inline void emma2rh_out32(u32 offset, u32 val) | ||
198 | { | ||
199 | *(volatile u32 *)(EMMA2RH_BASE | offset) = val; | ||
200 | emma2rh_sync(); | ||
201 | } | ||
202 | |||
203 | static inline u32 emma2rh_in32(u32 offset) | ||
204 | { | ||
205 | u32 val = *(volatile u32 *)(EMMA2RH_BASE | offset); | ||
206 | emma2rh_sync(); | ||
207 | return val; | ||
208 | } | ||
209 | |||
210 | static inline void emma2rh_out16(u32 offset, u16 val) | ||
211 | { | ||
212 | *(volatile u16 *)(EMMA2RH_BASE | offset) = val; | ||
213 | emma2rh_sync(); | ||
214 | } | ||
215 | |||
216 | static inline u16 emma2rh_in16(u32 offset) | ||
217 | { | ||
218 | u16 val = *(volatile u16 *)(EMMA2RH_BASE | offset); | ||
219 | emma2rh_sync(); | ||
220 | return val; | ||
221 | } | ||
222 | |||
223 | static inline void emma2rh_out8(u32 offset, u8 val) | ||
224 | { | ||
225 | *(volatile u8 *)(EMMA2RH_BASE | offset) = val; | ||
226 | emma2rh_sync(); | ||
227 | } | ||
228 | |||
229 | static inline u8 emma2rh_in8(u32 offset) | ||
230 | { | ||
231 | u8 val = *(volatile u8 *)(EMMA2RH_BASE | offset); | ||
232 | emma2rh_sync(); | ||
233 | return val; | ||
234 | } | ||
235 | |||
236 | /** | ||
237 | * IIC registers map | ||
238 | **/ | ||
239 | |||
240 | /*---------------------------------------------------------------------------*/ | ||
241 | /* CNT - Control register (00H R/W) */ | ||
242 | /*---------------------------------------------------------------------------*/ | ||
243 | #define SPT 0x00000001 | ||
244 | #define STT 0x00000002 | ||
245 | #define ACKE 0x00000004 | ||
246 | #define WTIM 0x00000008 | ||
247 | #define SPIE 0x00000010 | ||
248 | #define WREL 0x00000020 | ||
249 | #define LREL 0x00000040 | ||
250 | #define IICE 0x00000080 | ||
251 | #define CNT_RESERVED 0x000000ff /* reserved bit 0 */ | ||
252 | |||
253 | #define I2C_EMMA_START (IICE | STT) | ||
254 | #define I2C_EMMA_STOP (IICE | SPT) | ||
255 | #define I2C_EMMA_REPSTART I2C_EMMA_START | ||
256 | |||
257 | /*---------------------------------------------------------------------------*/ | ||
258 | /* STA - Status register (10H Read) */ | ||
259 | /*---------------------------------------------------------------------------*/ | ||
260 | #define MSTS 0x00000080 | ||
261 | #define ALD 0x00000040 | ||
262 | #define EXC 0x00000020 | ||
263 | #define COI 0x00000010 | ||
264 | #define TRC 0x00000008 | ||
265 | #define ACKD 0x00000004 | ||
266 | #define STD 0x00000002 | ||
267 | #define SPD 0x00000001 | ||
268 | |||
269 | /*---------------------------------------------------------------------------*/ | ||
270 | /* CSEL - Clock select register (20H R/W) */ | ||
271 | /*---------------------------------------------------------------------------*/ | ||
272 | #define FCL 0x00000080 | ||
273 | #define ND50 0x00000040 | ||
274 | #define CLD 0x00000020 | ||
275 | #define DAD 0x00000010 | ||
276 | #define SMC 0x00000008 | ||
277 | #define DFC 0x00000004 | ||
278 | #define CL 0x00000003 | ||
279 | #define CSEL_RESERVED 0x000000ff /* reserved bit 0 */ | ||
280 | |||
281 | #define FAST397 0x0000008b | ||
282 | #define FAST297 0x0000008a | ||
283 | #define FAST347 0x0000000b | ||
284 | #define FAST260 0x0000000a | ||
285 | #define FAST130 0x00000008 | ||
286 | #define STANDARD108 0x00000083 | ||
287 | #define STANDARD83 0x00000082 | ||
288 | #define STANDARD95 0x00000003 | ||
289 | #define STANDARD73 0x00000002 | ||
290 | #define STANDARD36 0x00000001 | ||
291 | #define STANDARD71 0x00000000 | ||
292 | |||
293 | /*---------------------------------------------------------------------------*/ | ||
294 | /* SVA - Slave address register (30H R/W) */ | ||
295 | /*---------------------------------------------------------------------------*/ | ||
296 | #define SVA 0x000000fe | ||
297 | |||
298 | /*---------------------------------------------------------------------------*/ | ||
299 | /* SHR - Shift register (40H R/W) */ | ||
300 | /*---------------------------------------------------------------------------*/ | ||
301 | #define SR 0x000000ff | ||
302 | |||
303 | /*---------------------------------------------------------------------------*/ | ||
304 | /* INT - Interrupt register (50H R/W) */ | ||
305 | /* INTM - Interrupt mask register (60H R/W) */ | ||
306 | /*---------------------------------------------------------------------------*/ | ||
307 | #define INTE0 0x00000001 | ||
308 | |||
309 | /*********************************************************************** | ||
310 | * I2C registers | ||
311 | *********************************************************************** | ||
312 | */ | ||
313 | #define I2C_EMMA_CNT 0x00 | ||
314 | #define I2C_EMMA_STA 0x10 | ||
315 | #define I2C_EMMA_CSEL 0x20 | ||
316 | #define I2C_EMMA_SVA 0x30 | ||
317 | #define I2C_EMMA_SHR 0x40 | ||
318 | #define I2C_EMMA_INT 0x50 | ||
319 | #define I2C_EMMA_INTM 0x60 | ||
320 | |||
321 | /* | ||
322 | * include the board dependent part | ||
323 | */ | ||
324 | #if defined(CONFIG_MARKEINS) | ||
325 | #include <asm/emma2rh/markeins.h> | ||
326 | #else | ||
327 | #error "Unknown EMMA2RH board!" | ||
328 | #endif | ||
329 | |||
330 | #endif /* __ASM_EMMA2RH_EMMA2RH_H */ | ||
diff --git a/include/asm-mips/emma2rh/markeins.h b/include/asm-mips/emma2rh/markeins.h new file mode 100644 index 000000000000..8fa766795078 --- /dev/null +++ b/include/asm-mips/emma2rh/markeins.h | |||
@@ -0,0 +1,76 @@ | |||
1 | /* | ||
2 | * include/asm-mips/emma2rh/markeins.h | ||
3 | * This file is EMMA2RH board depended header. | ||
4 | * | ||
5 | * Copyright (C) NEC Electronics Corporation 2005-2006 | ||
6 | * | ||
7 | * This file based on include/asm-mips/ddb5xxx/ddb5xxx.h | ||
8 | * Copyright 2001 MontaVista Software Inc. | ||
9 | * | ||
10 | * This program is free software; you can redistribute it and/or modify | ||
11 | * it under the terms of the GNU General Public License as published by | ||
12 | * the Free Software Foundation; either version 2 of the License, or | ||
13 | * (at your option) any later version. | ||
14 | * | ||
15 | * This program is distributed in the hope that it will be useful, | ||
16 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
17 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
18 | * GNU General Public License for more details. | ||
19 | * | ||
20 | * You should have received a copy of the GNU General Public License | ||
21 | * along with this program; if not, write to the Free Software | ||
22 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
23 | */ | ||
24 | |||
25 | #ifndef MARKEINS_H | ||
26 | #define MARKEINS_H | ||
27 | |||
28 | #define NUM_EMMA2RH_IRQ_SW 32 | ||
29 | #define NUM_EMMA2RH_IRQ_GPIO 32 | ||
30 | |||
31 | #define EMMA2RH_SW_CASCADE (EMMA2RH_IRQ_INT7 - EMMA2RH_IRQ_INT0) | ||
32 | #define EMMA2RH_GPIO_CASCADE (EMMA2RH_IRQ_INT46 - EMMA2RH_IRQ_INT0) | ||
33 | |||
34 | #define EMMA2RH_SW_IRQ_BASE (EMMA2RH_IRQ_BASE + NUM_EMMA2RH_IRQ) | ||
35 | #define EMMA2RH_GPIO_IRQ_BASE (EMMA2RH_SW_IRQ_BASE + NUM_EMMA2RH_IRQ_SW) | ||
36 | #define CPU_IRQ_BASE (EMMA2RH_GPIO_IRQ_BASE + NUM_EMMA2RH_IRQ_GPIO) | ||
37 | |||
38 | #define EMMA2RH_SW_IRQ_INT0 (0+EMMA2RH_SW_IRQ_BASE) | ||
39 | #define EMMA2RH_SW_IRQ_INT1 (1+EMMA2RH_SW_IRQ_BASE) | ||
40 | #define EMMA2RH_SW_IRQ_INT2 (2+EMMA2RH_SW_IRQ_BASE) | ||
41 | #define EMMA2RH_SW_IRQ_INT3 (3+EMMA2RH_SW_IRQ_BASE) | ||
42 | #define EMMA2RH_SW_IRQ_INT4 (4+EMMA2RH_SW_IRQ_BASE) | ||
43 | #define EMMA2RH_SW_IRQ_INT5 (5+EMMA2RH_SW_IRQ_BASE) | ||
44 | #define EMMA2RH_SW_IRQ_INT6 (6+EMMA2RH_SW_IRQ_BASE) | ||
45 | #define EMMA2RH_SW_IRQ_INT7 (7+EMMA2RH_SW_IRQ_BASE) | ||
46 | #define EMMA2RH_SW_IRQ_INT8 (8+EMMA2RH_SW_IRQ_BASE) | ||
47 | #define EMMA2RH_SW_IRQ_INT9 (9+EMMA2RH_SW_IRQ_BASE) | ||
48 | #define EMMA2RH_SW_IRQ_INT10 (10+EMMA2RH_SW_IRQ_BASE) | ||
49 | #define EMMA2RH_SW_IRQ_INT11 (11+EMMA2RH_SW_IRQ_BASE) | ||
50 | #define EMMA2RH_SW_IRQ_INT12 (12+EMMA2RH_SW_IRQ_BASE) | ||
51 | #define EMMA2RH_SW_IRQ_INT13 (13+EMMA2RH_SW_IRQ_BASE) | ||
52 | #define EMMA2RH_SW_IRQ_INT14 (14+EMMA2RH_SW_IRQ_BASE) | ||
53 | #define EMMA2RH_SW_IRQ_INT15 (15+EMMA2RH_SW_IRQ_BASE) | ||
54 | #define EMMA2RH_SW_IRQ_INT16 (16+EMMA2RH_SW_IRQ_BASE) | ||
55 | #define EMMA2RH_SW_IRQ_INT17 (17+EMMA2RH_SW_IRQ_BASE) | ||
56 | #define EMMA2RH_SW_IRQ_INT18 (18+EMMA2RH_SW_IRQ_BASE) | ||
57 | #define EMMA2RH_SW_IRQ_INT19 (19+EMMA2RH_SW_IRQ_BASE) | ||
58 | #define EMMA2RH_SW_IRQ_INT20 (20+EMMA2RH_SW_IRQ_BASE) | ||
59 | #define EMMA2RH_SW_IRQ_INT21 (21+EMMA2RH_SW_IRQ_BASE) | ||
60 | #define EMMA2RH_SW_IRQ_INT22 (22+EMMA2RH_SW_IRQ_BASE) | ||
61 | #define EMMA2RH_SW_IRQ_INT23 (23+EMMA2RH_SW_IRQ_BASE) | ||
62 | #define EMMA2RH_SW_IRQ_INT24 (24+EMMA2RH_SW_IRQ_BASE) | ||
63 | #define EMMA2RH_SW_IRQ_INT25 (25+EMMA2RH_SW_IRQ_BASE) | ||
64 | #define EMMA2RH_SW_IRQ_INT26 (26+EMMA2RH_SW_IRQ_BASE) | ||
65 | #define EMMA2RH_SW_IRQ_INT27 (27+EMMA2RH_SW_IRQ_BASE) | ||
66 | #define EMMA2RH_SW_IRQ_INT28 (28+EMMA2RH_SW_IRQ_BASE) | ||
67 | #define EMMA2RH_SW_IRQ_INT29 (29+EMMA2RH_SW_IRQ_BASE) | ||
68 | #define EMMA2RH_SW_IRQ_INT30 (30+EMMA2RH_SW_IRQ_BASE) | ||
69 | #define EMMA2RH_SW_IRQ_INT31 (31+EMMA2RH_SW_IRQ_BASE) | ||
70 | |||
71 | #define MARKEINS_PCI_IRQ_INTA EMMA2RH_GPIO_IRQ_BASE+15 | ||
72 | #define MARKEINS_PCI_IRQ_INTB EMMA2RH_GPIO_IRQ_BASE+16 | ||
73 | #define MARKEINS_PCI_IRQ_INTC EMMA2RH_GPIO_IRQ_BASE+17 | ||
74 | #define MARKEINS_PCI_IRQ_INTD EMMA2RH_GPIO_IRQ_BASE+18 | ||
75 | |||
76 | #endif /* CONFIG_MARKEINS */ | ||
diff --git a/include/asm-mips/fcntl.h b/include/asm-mips/fcntl.h index 43d047a9a6af..787220e6c1fc 100644 --- a/include/asm-mips/fcntl.h +++ b/include/asm-mips/fcntl.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef _ASM_FCNTL_H | 8 | #ifndef _ASM_FCNTL_H |
9 | #define _ASM_FCNTL_H | 9 | #define _ASM_FCNTL_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | 11 | ||
13 | #define O_APPEND 0x0008 | 12 | #define O_APPEND 0x0008 |
14 | #define O_SYNC 0x0010 | 13 | #define O_SYNC 0x0010 |
diff --git a/include/asm-mips/fixmap.h b/include/asm-mips/fixmap.h index 73a3028dd9f9..1cadefbbc037 100644 --- a/include/asm-mips/fixmap.h +++ b/include/asm-mips/fixmap.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef _ASM_FIXMAP_H | 13 | #ifndef _ASM_FIXMAP_H |
14 | #define _ASM_FIXMAP_H | 14 | #define _ASM_FIXMAP_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <asm/page.h> | 16 | #include <asm/page.h> |
18 | #ifdef CONFIG_HIGHMEM | 17 | #ifdef CONFIG_HIGHMEM |
19 | #include <linux/threads.h> | 18 | #include <linux/threads.h> |
diff --git a/include/asm-mips/fpu.h b/include/asm-mips/fpu.h index b0f50015e252..58c561a9ec6b 100644 --- a/include/asm-mips/fpu.h +++ b/include/asm-mips/fpu.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASM_FPU_H | 10 | #ifndef _ASM_FPU_H |
11 | #define _ASM_FPU_H | 11 | #define _ASM_FPU_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/sched.h> | 13 | #include <linux/sched.h> |
15 | #include <linux/thread_info.h> | 14 | #include <linux/thread_info.h> |
16 | 15 | ||
@@ -138,10 +137,9 @@ static inline fpureg_t *get_fpu_regs(struct task_struct *tsk) | |||
138 | if (cpu_has_fpu) { | 137 | if (cpu_has_fpu) { |
139 | if ((tsk == current) && __is_fpu_owner()) | 138 | if ((tsk == current) && __is_fpu_owner()) |
140 | _save_fp(current); | 139 | _save_fp(current); |
141 | return tsk->thread.fpu.hard.fpr; | ||
142 | } | 140 | } |
143 | 141 | ||
144 | return tsk->thread.fpu.soft.fpr; | 142 | return tsk->thread.fpu.fpr; |
145 | } | 143 | } |
146 | 144 | ||
147 | #endif /* _ASM_FPU_H */ | 145 | #endif /* _ASM_FPU_H */ |
diff --git a/include/asm-mips/fpu_emulator.h b/include/asm-mips/fpu_emulator.h index 16cb4d11dd0b..2731c38bd7ae 100644 --- a/include/asm-mips/fpu_emulator.h +++ b/include/asm-mips/fpu_emulator.h | |||
@@ -12,8 +12,8 @@ | |||
12 | * with this program; if not, write to the Free Software Foundation, Inc., | 12 | * with this program; if not, write to the Free Software Foundation, Inc., |
13 | * 59 Temple Place - Suite 330, Boston MA 02111-1307, USA. | 13 | * 59 Temple Place - Suite 330, Boston MA 02111-1307, USA. |
14 | * | 14 | * |
15 | * Further private data for which no space exists in mips_fpu_soft_struct. | 15 | * Further private data for which no space exists in mips_fpu_struct. |
16 | * This should be subsumed into the mips_fpu_soft_struct structure as | 16 | * This should be subsumed into the mips_fpu_struct structure as |
17 | * defined in processor.h as soon as the absurd wired absolute assembler | 17 | * defined in processor.h as soon as the absurd wired absolute assembler |
18 | * offsets become dynamic at compile time. | 18 | * offsets become dynamic at compile time. |
19 | * | 19 | * |
diff --git a/include/asm-mips/futex.h b/include/asm-mips/futex.h index 12d118f1bc9c..ed023eae0674 100644 --- a/include/asm-mips/futex.h +++ b/include/asm-mips/futex.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <linux/futex.h> | 6 | #include <linux/futex.h> |
8 | #include <asm/errno.h> | 7 | #include <asm/errno.h> |
9 | #include <asm/uaccess.h> | 8 | #include <asm/uaccess.h> |
@@ -22,51 +21,53 @@ | |||
22 | " .set push \n" \ | 21 | " .set push \n" \ |
23 | " .set noat \n" \ | 22 | " .set noat \n" \ |
24 | " .set mips3 \n" \ | 23 | " .set mips3 \n" \ |
25 | "1: ll %1, (%3) # __futex_atomic_op \n" \ | 24 | "1: ll %1, %4 # __futex_atomic_op \n" \ |
26 | " .set mips0 \n" \ | 25 | " .set mips0 \n" \ |
27 | " " insn " \n" \ | 26 | " " insn " \n" \ |
28 | " .set mips3 \n" \ | 27 | " .set mips3 \n" \ |
29 | "2: sc $1, (%3) \n" \ | 28 | "2: sc $1, %2 \n" \ |
30 | " beqzl $1, 1b \n" \ | 29 | " beqzl $1, 1b \n" \ |
31 | __FUTEX_SMP_SYNC \ | 30 | __FUTEX_SMP_SYNC \ |
32 | "3: \n" \ | 31 | "3: \n" \ |
33 | " .set pop \n" \ | 32 | " .set pop \n" \ |
34 | " .set mips0 \n" \ | 33 | " .set mips0 \n" \ |
35 | " .section .fixup,\"ax\" \n" \ | 34 | " .section .fixup,\"ax\" \n" \ |
36 | "4: li %0, %5 \n" \ | 35 | "4: li %0, %6 \n" \ |
37 | " j 2b \n" \ | 36 | " j 2b \n" \ |
38 | " .previous \n" \ | 37 | " .previous \n" \ |
39 | " .section __ex_table,\"a\" \n" \ | 38 | " .section __ex_table,\"a\" \n" \ |
40 | " "__UA_ADDR "\t1b, 4b \n" \ | 39 | " "__UA_ADDR "\t1b, 4b \n" \ |
41 | " "__UA_ADDR "\t2b, 4b \n" \ | 40 | " "__UA_ADDR "\t2b, 4b \n" \ |
42 | " .previous \n" \ | 41 | " .previous \n" \ |
43 | : "=r" (ret), "=r" (oldval) \ | 42 | : "=r" (ret), "=&r" (oldval), "=R" (*uaddr) \ |
44 | : "0" (0), "r" (uaddr), "Jr" (oparg), "i" (-EFAULT)); \ | 43 | : "0" (0), "R" (*uaddr), "Jr" (oparg), "i" (-EFAULT) \ |
44 | : "memory"); \ | ||
45 | } else if (cpu_has_llsc) { \ | 45 | } else if (cpu_has_llsc) { \ |
46 | __asm__ __volatile__( \ | 46 | __asm__ __volatile__( \ |
47 | " .set push \n" \ | 47 | " .set push \n" \ |
48 | " .set noat \n" \ | 48 | " .set noat \n" \ |
49 | " .set mips3 \n" \ | 49 | " .set mips3 \n" \ |
50 | "1: ll %1, (%3) # __futex_atomic_op \n" \ | 50 | "1: ll %1, %4 # __futex_atomic_op \n" \ |
51 | " .set mips0 \n" \ | 51 | " .set mips0 \n" \ |
52 | " " insn " \n" \ | 52 | " " insn " \n" \ |
53 | " .set mips3 \n" \ | 53 | " .set mips3 \n" \ |
54 | "2: sc $1, (%3) \n" \ | 54 | "2: sc $1, %2 \n" \ |
55 | " beqz $1, 1b \n" \ | 55 | " beqz $1, 1b \n" \ |
56 | __FUTEX_SMP_SYNC \ | 56 | __FUTEX_SMP_SYNC \ |
57 | "3: \n" \ | 57 | "3: \n" \ |
58 | " .set pop \n" \ | 58 | " .set pop \n" \ |
59 | " .set mips0 \n" \ | 59 | " .set mips0 \n" \ |
60 | " .section .fixup,\"ax\" \n" \ | 60 | " .section .fixup,\"ax\" \n" \ |
61 | "4: li %0, %5 \n" \ | 61 | "4: li %0, %6 \n" \ |
62 | " j 2b \n" \ | 62 | " j 2b \n" \ |
63 | " .previous \n" \ | 63 | " .previous \n" \ |
64 | " .section __ex_table,\"a\" \n" \ | 64 | " .section __ex_table,\"a\" \n" \ |
65 | " "__UA_ADDR "\t1b, 4b \n" \ | 65 | " "__UA_ADDR "\t1b, 4b \n" \ |
66 | " "__UA_ADDR "\t2b, 4b \n" \ | 66 | " "__UA_ADDR "\t2b, 4b \n" \ |
67 | " .previous \n" \ | 67 | " .previous \n" \ |
68 | : "=r" (ret), "=r" (oldval) \ | 68 | : "=r" (ret), "=&r" (oldval), "=R" (*uaddr) \ |
69 | : "0" (0), "r" (uaddr), "Jr" (oparg), "i" (-EFAULT)); \ | 69 | : "0" (0), "R" (*uaddr), "Jr" (oparg), "i" (-EFAULT) \ |
70 | : "memory"); \ | ||
70 | } else \ | 71 | } else \ |
71 | ret = -ENOSYS; \ | 72 | ret = -ENOSYS; \ |
72 | } | 73 | } |
@@ -89,23 +90,23 @@ futex_atomic_op_inuser (int encoded_op, int __user *uaddr) | |||
89 | 90 | ||
90 | switch (op) { | 91 | switch (op) { |
91 | case FUTEX_OP_SET: | 92 | case FUTEX_OP_SET: |
92 | __futex_atomic_op("move $1, %z4", ret, oldval, uaddr, oparg); | 93 | __futex_atomic_op("move $1, %z5", ret, oldval, uaddr, oparg); |
93 | break; | 94 | break; |
94 | 95 | ||
95 | case FUTEX_OP_ADD: | 96 | case FUTEX_OP_ADD: |
96 | __futex_atomic_op("addu $1, %1, %z4", | 97 | __futex_atomic_op("addu $1, %1, %z5", |
97 | ret, oldval, uaddr, oparg); | 98 | ret, oldval, uaddr, oparg); |
98 | break; | 99 | break; |
99 | case FUTEX_OP_OR: | 100 | case FUTEX_OP_OR: |
100 | __futex_atomic_op("or $1, %1, %z4", | 101 | __futex_atomic_op("or $1, %1, %z5", |
101 | ret, oldval, uaddr, oparg); | 102 | ret, oldval, uaddr, oparg); |
102 | break; | 103 | break; |
103 | case FUTEX_OP_ANDN: | 104 | case FUTEX_OP_ANDN: |
104 | __futex_atomic_op("and $1, %1, %z4", | 105 | __futex_atomic_op("and $1, %1, %z5", |
105 | ret, oldval, uaddr, ~oparg); | 106 | ret, oldval, uaddr, ~oparg); |
106 | break; | 107 | break; |
107 | case FUTEX_OP_XOR: | 108 | case FUTEX_OP_XOR: |
108 | __futex_atomic_op("xor $1, %1, %z4", | 109 | __futex_atomic_op("xor $1, %1, %z5", |
109 | ret, oldval, uaddr, oparg); | 110 | ret, oldval, uaddr, oparg); |
110 | break; | 111 | break; |
111 | default: | 112 | default: |
diff --git a/include/asm-mips/hazards.h b/include/asm-mips/hazards.h index dadc05188db7..66943c451c1d 100644 --- a/include/asm-mips/hazards.h +++ b/include/asm-mips/hazards.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASM_HAZARDS_H | 10 | #ifndef _ASM_HAZARDS_H |
11 | #define _ASM_HAZARDS_H | 11 | #define _ASM_HAZARDS_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | #ifdef __ASSEMBLY__ | 14 | #ifdef __ASSEMBLY__ |
16 | 15 | ||
diff --git a/include/asm-mips/highmem.h b/include/asm-mips/highmem.h index 8cf598402492..c976bfaaba83 100644 --- a/include/asm-mips/highmem.h +++ b/include/asm-mips/highmem.h | |||
@@ -19,7 +19,6 @@ | |||
19 | 19 | ||
20 | #ifdef __KERNEL__ | 20 | #ifdef __KERNEL__ |
21 | 21 | ||
22 | #include <linux/config.h> | ||
23 | #include <linux/init.h> | 22 | #include <linux/init.h> |
24 | #include <linux/interrupt.h> | 23 | #include <linux/interrupt.h> |
25 | #include <asm/kmap_types.h> | 24 | #include <asm/kmap_types.h> |
diff --git a/include/asm-mips/interrupt.h b/include/asm-mips/interrupt.h index 4bb9c06f4410..a99d6867510f 100644 --- a/include/asm-mips/interrupt.h +++ b/include/asm-mips/interrupt.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_INTERRUPT_H | 11 | #ifndef _ASM_INTERRUPT_H |
12 | #define _ASM_INTERRUPT_H | 12 | #define _ASM_INTERRUPT_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <asm/hazards.h> | 14 | #include <asm/hazards.h> |
16 | 15 | ||
17 | __asm__ ( | 16 | __asm__ ( |
diff --git a/include/asm-mips/io.h b/include/asm-mips/io.h index 6b17eb9d79a5..df624e1ee6e2 100644 --- a/include/asm-mips/io.h +++ b/include/asm-mips/io.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef _ASM_IO_H | 12 | #ifndef _ASM_IO_H |
13 | #define _ASM_IO_H | 13 | #define _ASM_IO_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <linux/compiler.h> | 15 | #include <linux/compiler.h> |
17 | #include <linux/kernel.h> | 16 | #include <linux/kernel.h> |
18 | #include <linux/types.h> | 17 | #include <linux/types.h> |
diff --git a/include/asm-mips/ip32/machine.h b/include/asm-mips/ip32/machine.h index e440fdf4b232..1b631b8da6f8 100644 --- a/include/asm-mips/ip32/machine.h +++ b/include/asm-mips/ip32/machine.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASM_IP32_MACHINE_H | 10 | #ifndef _ASM_IP32_MACHINE_H |
11 | #define _ASM_IP32_MACHINE_H | 11 | #define _ASM_IP32_MACHINE_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | #ifdef CONFIG_SGI_IP32 | 14 | #ifdef CONFIG_SGI_IP32 |
16 | 15 | ||
diff --git a/include/asm-mips/irq.h b/include/asm-mips/irq.h index dde677f02bc0..d35c61776a02 100644 --- a/include/asm-mips/irq.h +++ b/include/asm-mips/irq.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_IRQ_H | 9 | #ifndef _ASM_IRQ_H |
10 | #define _ASM_IRQ_H | 10 | #define _ASM_IRQ_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/linkage.h> | 12 | #include <linux/linkage.h> |
14 | 13 | ||
15 | #include <asm/mipsmtregs.h> | 14 | #include <asm/mipsmtregs.h> |
diff --git a/include/asm-mips/isadep.h b/include/asm-mips/isadep.h index 7bb003511d9e..24c6cda79377 100644 --- a/include/asm-mips/isadep.h +++ b/include/asm-mips/isadep.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * | 5 | * |
6 | * Copyright (c) 1998 Harald Koerfgen | 6 | * Copyright (c) 1998 Harald Koerfgen |
7 | */ | 7 | */ |
8 | #include <linux/config.h> | ||
9 | 8 | ||
10 | #ifndef __ASM_ISADEP_H | 9 | #ifndef __ASM_ISADEP_H |
11 | #define __ASM_ISADEP_H | 10 | #define __ASM_ISADEP_H |
diff --git a/include/asm-mips/jmr3927/irq.h b/include/asm-mips/jmr3927/irq.h index b0c325a22343..fe551f33a74f 100644 --- a/include/asm-mips/jmr3927/irq.h +++ b/include/asm-mips/jmr3927/irq.h | |||
@@ -12,7 +12,6 @@ | |||
12 | 12 | ||
13 | #ifndef __ASSEMBLY__ | 13 | #ifndef __ASSEMBLY__ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <asm/irq.h> | 15 | #include <asm/irq.h> |
17 | 16 | ||
18 | struct tb_irq_space { | 17 | struct tb_irq_space { |
diff --git a/include/asm-mips/kmap_types.h b/include/asm-mips/kmap_types.h index 6886a0c3fedf..806aae3c5338 100644 --- a/include/asm-mips/kmap_types.h +++ b/include/asm-mips/kmap_types.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_KMAP_TYPES_H | 1 | #ifndef _ASM_KMAP_TYPES_H |
2 | #define _ASM_KMAP_TYPES_H | 2 | #define _ASM_KMAP_TYPES_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_DEBUG_HIGHMEM | 5 | #ifdef CONFIG_DEBUG_HIGHMEM |
7 | # define D(n) __KM_FENCE_##n , | 6 | # define D(n) __KM_FENCE_##n , |
diff --git a/include/asm-mips/local.h b/include/asm-mips/local.h index c38844f615fc..9e2d43bae388 100644 --- a/include/asm-mips/local.h +++ b/include/asm-mips/local.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_LOCAL_H | 1 | #ifndef _ASM_LOCAL_H |
2 | #define _ASM_LOCAL_H | 2 | #define _ASM_LOCAL_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/percpu.h> | 4 | #include <linux/percpu.h> |
6 | #include <asm/atomic.h> | 5 | #include <asm/atomic.h> |
7 | 6 | ||
diff --git a/include/asm-mips/mach-au1x00/au1000.h b/include/asm-mips/mach-au1x00/au1000.h index 4686e17c206c..582acd8adb81 100644 --- a/include/asm-mips/mach-au1x00/au1000.h +++ b/include/asm-mips/mach-au1x00/au1000.h | |||
@@ -35,7 +35,6 @@ | |||
35 | #ifndef _AU1000_H_ | 35 | #ifndef _AU1000_H_ |
36 | #define _AU1000_H_ | 36 | #define _AU1000_H_ |
37 | 37 | ||
38 | #include <linux/config.h> | ||
39 | 38 | ||
40 | #ifndef _LANGUAGE_ASSEMBLY | 39 | #ifndef _LANGUAGE_ASSEMBLY |
41 | 40 | ||
diff --git a/include/asm-mips/mach-au1x00/au1xxx.h b/include/asm-mips/mach-au1x00/au1xxx.h index b7b46dd9b929..947135941033 100644 --- a/include/asm-mips/mach-au1x00/au1xxx.h +++ b/include/asm-mips/mach-au1x00/au1xxx.h | |||
@@ -23,7 +23,6 @@ | |||
23 | #ifndef _AU1XXX_H_ | 23 | #ifndef _AU1XXX_H_ |
24 | #define _AU1XXX_H_ | 24 | #define _AU1XXX_H_ |
25 | 25 | ||
26 | #include <linux/config.h> | ||
27 | 26 | ||
28 | #include <asm/mach-au1x00/au1000.h> | 27 | #include <asm/mach-au1x00/au1000.h> |
29 | 28 | ||
diff --git a/include/asm-mips/mach-au1x00/au1xxx_dbdma.h b/include/asm-mips/mach-au1x00/au1xxx_dbdma.h index b327bcd3fee1..d5b38a247e5a 100644 --- a/include/asm-mips/mach-au1x00/au1xxx_dbdma.h +++ b/include/asm-mips/mach-au1x00/au1xxx_dbdma.h | |||
@@ -34,7 +34,6 @@ | |||
34 | #ifndef _AU1000_DBDMA_H_ | 34 | #ifndef _AU1000_DBDMA_H_ |
35 | #define _AU1000_DBDMA_H_ | 35 | #define _AU1000_DBDMA_H_ |
36 | 36 | ||
37 | #include <linux/config.h> | ||
38 | 37 | ||
39 | #ifndef _LANGUAGE_ASSEMBLY | 38 | #ifndef _LANGUAGE_ASSEMBLY |
40 | 39 | ||
diff --git a/include/asm-mips/mach-au1x00/au1xxx_ide.h b/include/asm-mips/mach-au1x00/au1xxx_ide.h index e867b4ef96d1..301e71300779 100644 --- a/include/asm-mips/mach-au1x00/au1xxx_ide.h +++ b/include/asm-mips/mach-au1x00/au1xxx_ide.h | |||
@@ -29,7 +29,6 @@ | |||
29 | * Note: for more information, please refer "AMD Alchemy Au1200/Au1550 IDE | 29 | * Note: for more information, please refer "AMD Alchemy Au1200/Au1550 IDE |
30 | * Interface and Linux Device Driver" Application Note. | 30 | * Interface and Linux Device Driver" Application Note. |
31 | */ | 31 | */ |
32 | #include <linux/config.h> | ||
33 | 32 | ||
34 | #ifdef CONFIG_BLK_DEV_IDE_AU1XXX_MDMA2_DBDMA | 33 | #ifdef CONFIG_BLK_DEV_IDE_AU1XXX_MDMA2_DBDMA |
35 | #define DMA_WAIT_TIMEOUT 100 | 34 | #define DMA_WAIT_TIMEOUT 100 |
diff --git a/include/asm-mips/mach-au1x00/au1xxx_psc.h b/include/asm-mips/mach-au1x00/au1xxx_psc.h index 8e5fb3c7da4d..5c3e2a38ce12 100644 --- a/include/asm-mips/mach-au1x00/au1xxx_psc.h +++ b/include/asm-mips/mach-au1x00/au1xxx_psc.h | |||
@@ -33,7 +33,6 @@ | |||
33 | #ifndef _AU1000_PSC_H_ | 33 | #ifndef _AU1000_PSC_H_ |
34 | #define _AU1000_PSC_H_ | 34 | #define _AU1000_PSC_H_ |
35 | 35 | ||
36 | #include <linux/config.h> | ||
37 | 36 | ||
38 | /* The PSC base addresses. */ | 37 | /* The PSC base addresses. */ |
39 | #ifdef CONFIG_SOC_AU1550 | 38 | #ifdef CONFIG_SOC_AU1550 |
diff --git a/include/asm-mips/mach-au1x00/ioremap.h b/include/asm-mips/mach-au1x00/ioremap.h index d3ec6274575a..098fca4289bb 100644 --- a/include/asm-mips/mach-au1x00/ioremap.h +++ b/include/asm-mips/mach-au1x00/ioremap.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef __ASM_MACH_AU1X00_IOREMAP_H | 9 | #ifndef __ASM_MACH_AU1X00_IOREMAP_H |
10 | #define __ASM_MACH_AU1X00_IOREMAP_H | 10 | #define __ASM_MACH_AU1X00_IOREMAP_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/types.h> | 12 | #include <linux/types.h> |
14 | 13 | ||
15 | #ifdef CONFIG_64BIT_PHYS_ADDR | 14 | #ifdef CONFIG_64BIT_PHYS_ADDR |
diff --git a/include/asm-mips/mach-cobalt/cpu-feature-overrides.h b/include/asm-mips/mach-cobalt/cpu-feature-overrides.h index ace8c5ef9701..e0e08fc5d7f7 100644 --- a/include/asm-mips/mach-cobalt/cpu-feature-overrides.h +++ b/include/asm-mips/mach-cobalt/cpu-feature-overrides.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef __ASM_COBALT_CPU_FEATURE_OVERRIDES_H | 8 | #ifndef __ASM_COBALT_CPU_FEATURE_OVERRIDES_H |
9 | #define __ASM_COBALT_CPU_FEATURE_OVERRIDES_H | 9 | #define __ASM_COBALT_CPU_FEATURE_OVERRIDES_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | 11 | ||
13 | #define cpu_has_tlb 1 | 12 | #define cpu_has_tlb 1 |
14 | #define cpu_has_4kex 1 | 13 | #define cpu_has_4kex 1 |
diff --git a/include/asm-mips/mach-db1x00/db1x00.h b/include/asm-mips/mach-db1x00/db1x00.h index 7b28b23f91ce..8fbb4b42a8b5 100644 --- a/include/asm-mips/mach-db1x00/db1x00.h +++ b/include/asm-mips/mach-db1x00/db1x00.h | |||
@@ -28,7 +28,6 @@ | |||
28 | #ifndef __ASM_DB1X00_H | 28 | #ifndef __ASM_DB1X00_H |
29 | #define __ASM_DB1X00_H | 29 | #define __ASM_DB1X00_H |
30 | 30 | ||
31 | #include <linux/config.h> | ||
32 | 31 | ||
33 | #ifdef CONFIG_MIPS_DB1550 | 32 | #ifdef CONFIG_MIPS_DB1550 |
34 | #define BCSR_KSEG1_ADDR 0xAF000000 | 33 | #define BCSR_KSEG1_ADDR 0xAF000000 |
diff --git a/include/asm-mips/mach-ddb5074/mc146818rtc.h b/include/asm-mips/mach-ddb5074/mc146818rtc.h deleted file mode 100644 index 2eb9acb10a5a..000000000000 --- a/include/asm-mips/mach-ddb5074/mc146818rtc.h +++ /dev/null | |||
@@ -1,31 +0,0 @@ | |||
1 | /* | ||
2 | * This file is subject to the terms and conditions of the GNU General Public | ||
3 | * License. See the file "COPYING" in the main directory of this archive | ||
4 | * for more details. | ||
5 | * | ||
6 | * Copyright (C) 1998, 2001, 03 by Ralf Baechle | ||
7 | * | ||
8 | * RTC routines for PC style attached Dallas chip. | ||
9 | */ | ||
10 | #ifndef __ASM_MACH_DDB5074_MC146818RTC_H | ||
11 | #define __ASM_MACH_DDB5074_MC146818RTC_H | ||
12 | |||
13 | #include <asm/ddb5xxx/ddb5074.h> | ||
14 | #include <asm/ddb5xxx/ddb5xxx.h> | ||
15 | |||
16 | #define RTC_PORT(x) (0x70 + (x)) | ||
17 | #define RTC_IRQ 8 | ||
18 | |||
19 | static inline unsigned char CMOS_READ(unsigned long addr) | ||
20 | { | ||
21 | return *(volatile unsigned char *)(KSEG1ADDR(DDB_PCI_MEM_BASE)+addr); | ||
22 | } | ||
23 | |||
24 | static inline void CMOS_WRITE(unsigned char data, unsigned long addr) | ||
25 | { | ||
26 | *(volatile unsigned char *)(KSEG1ADDR(DDB_PCI_MEM_BASE)+addr) = data; | ||
27 | } | ||
28 | |||
29 | #define RTC_ALWAYS_BCD 1 | ||
30 | |||
31 | #endif /* __ASM_MACH_DDB5074_MC146818RTC_H */ | ||
diff --git a/include/asm-mips/mach-dec/param.h b/include/asm-mips/mach-dec/param.h deleted file mode 100644 index 3e4f0e390847..000000000000 --- a/include/asm-mips/mach-dec/param.h +++ /dev/null | |||
@@ -1,18 +0,0 @@ | |||
1 | /* | ||
2 | * This file is subject to the terms and conditions of the GNU General Public | ||
3 | * License. See the file "COPYING" in the main directory of this archive | ||
4 | * for more details. | ||
5 | * | ||
6 | * Copyright (C) 2003 by Ralf Baechle | ||
7 | */ | ||
8 | #ifndef __ASM_MACH_DEC_PARAM_H | ||
9 | #define __ASM_MACH_DEC_PARAM_H | ||
10 | |||
11 | /* | ||
12 | * log2(HZ), change this here if you want another HZ value. This is also | ||
13 | * used in dec_time_init. Minimum is 1, Maximum is 15. | ||
14 | */ | ||
15 | #define LOG_2_HZ 7 | ||
16 | #define HZ (1 << LOG_2_HZ) | ||
17 | |||
18 | #endif /* __ASM_MACH_DEC_PARAM_H */ | ||
diff --git a/include/asm-mips/mach-mips/param.h b/include/asm-mips/mach-emma2rh/irq.h index 805ef6d27d3c..bce64244b800 100644 --- a/include/asm-mips/mach-mips/param.h +++ b/include/asm-mips/mach-emma2rh/irq.h | |||
@@ -5,9 +5,9 @@ | |||
5 | * | 5 | * |
6 | * Copyright (C) 2003 by Ralf Baechle | 6 | * Copyright (C) 2003 by Ralf Baechle |
7 | */ | 7 | */ |
8 | #ifndef __ASM_MACH_MIPS_PARAM_H | 8 | #ifndef __ASM_MACH_EMMA2RH_IRQ_H |
9 | #define __ASM_MACH_MIPS_PARAM_H | 9 | #define __ASM_MACH_EMMA2RH_IRQ_H |
10 | 10 | ||
11 | #define HZ 100 /* Internal kernel timer frequency */ | 11 | #define NR_IRQS 256 |
12 | 12 | ||
13 | #endif /* __ASM_MACH_MIPS_PARAM_H */ | 13 | #endif /* __ASM_MACH_EMMA2RH_IRQ_H */ |
diff --git a/include/asm-mips/mach-excite/cpu-feature-overrides.h b/include/asm-mips/mach-excite/cpu-feature-overrides.h new file mode 100644 index 000000000000..abb76b2fd865 --- /dev/null +++ b/include/asm-mips/mach-excite/cpu-feature-overrides.h | |||
@@ -0,0 +1,40 @@ | |||
1 | /* | ||
2 | * This file is subject to the terms and conditions of the GNU General Public | ||
3 | * License. See the file "COPYING" in the main directory of this archive | ||
4 | * for more details. | ||
5 | * | ||
6 | * Copyright (C) 2004 Thomas Koeller <thomas.koeller@baslerweb.com> | ||
7 | */ | ||
8 | #ifndef __ASM_MACH_EXCITE_CPU_FEATURE_OVERRIDES_H | ||
9 | #define __ASM_MACH_EXCITE_CPU_FEATURE_OVERRIDES_H | ||
10 | |||
11 | /* | ||
12 | * Basler eXcite has an RM9122 processor. | ||
13 | */ | ||
14 | #define cpu_has_watch 1 | ||
15 | #define cpu_has_mips16 0 | ||
16 | #define cpu_has_divec 0 | ||
17 | #define cpu_has_vce 0 | ||
18 | #define cpu_has_cache_cdex_p 0 | ||
19 | #define cpu_has_cache_cdex_s 0 | ||
20 | #define cpu_has_prefetch 1 | ||
21 | #define cpu_has_mcheck 0 | ||
22 | #define cpu_has_ejtag 0 | ||
23 | |||
24 | #define cpu_has_llsc 1 | ||
25 | #define cpu_has_vtag_icache 0 | ||
26 | #define cpu_has_dc_aliases 0 | ||
27 | #define cpu_has_ic_fills_f_dc 0 | ||
28 | #define cpu_has_dsp 0 | ||
29 | #define cpu_icache_snoops_remote_store 0 | ||
30 | |||
31 | #define cpu_has_nofpuex 0 | ||
32 | #define cpu_has_64bits 1 | ||
33 | |||
34 | #define cpu_has_subset_pcaches 0 | ||
35 | |||
36 | #define cpu_dcache_line_size() 32 | ||
37 | #define cpu_icache_line_size() 32 | ||
38 | #define cpu_scache_line_size() 32 | ||
39 | |||
40 | #endif /* __ASM_MACH_EXCITE_CPU_FEATURE_OVERRIDES_H */ | ||
diff --git a/include/asm-mips/mach-excite/excite.h b/include/asm-mips/mach-excite/excite.h new file mode 100644 index 000000000000..c52610de2b3a --- /dev/null +++ b/include/asm-mips/mach-excite/excite.h | |||
@@ -0,0 +1,155 @@ | |||
1 | #ifndef __EXCITE_H__ | ||
2 | #define __EXCITE_H__ | ||
3 | |||
4 | #include <linux/config.h> | ||
5 | #include <linux/init.h> | ||
6 | #include <asm/addrspace.h> | ||
7 | #include <asm/types.h> | ||
8 | |||
9 | #define EXCITE_CPU_EXT_CLOCK 100000000 | ||
10 | |||
11 | #if !defined(__ASSEMBLER__) | ||
12 | void __init excite_kgdb_init(void); | ||
13 | void excite_procfs_init(void); | ||
14 | extern unsigned long memsize; | ||
15 | extern char modetty[]; | ||
16 | extern u32 unit_id; | ||
17 | #endif | ||
18 | |||
19 | /* Base name for XICAP devices */ | ||
20 | #define XICAP_NAME "xicap_gpi" | ||
21 | |||
22 | /* OCD register offsets */ | ||
23 | #define LKB0 0x0038 | ||
24 | #define LKB5 0x0128 | ||
25 | #define LKM5 0x012C | ||
26 | #define LKB7 0x0138 | ||
27 | #define LKM7 0x013c | ||
28 | #define LKB8 0x0140 | ||
29 | #define LKM8 0x0144 | ||
30 | #define LKB9 0x0148 | ||
31 | #define LKM9 0x014c | ||
32 | #define LKB10 0x0150 | ||
33 | #define LKM10 0x0154 | ||
34 | #define LKB11 0x0158 | ||
35 | #define LKM11 0x015c | ||
36 | #define LKB12 0x0160 | ||
37 | #define LKM12 0x0164 | ||
38 | #define LKB13 0x0168 | ||
39 | #define LKM13 0x016c | ||
40 | #define LDP0 0x0200 | ||
41 | #define LDP1 0x0210 | ||
42 | #define LDP2 0x0220 | ||
43 | #define LDP3 0x0230 | ||
44 | #define INTPIN0 0x0A40 | ||
45 | #define INTPIN1 0x0A44 | ||
46 | #define INTPIN2 0x0A48 | ||
47 | #define INTPIN3 0x0A4C | ||
48 | #define INTPIN4 0x0A50 | ||
49 | #define INTPIN5 0x0A54 | ||
50 | #define INTPIN6 0x0A58 | ||
51 | #define INTPIN7 0x0A5C | ||
52 | |||
53 | |||
54 | |||
55 | |||
56 | /* TITAN register offsets */ | ||
57 | #define CPRR 0x0004 | ||
58 | #define CPDSR 0x0008 | ||
59 | #define CPTC0R 0x000c | ||
60 | #define CPTC1R 0x0010 | ||
61 | #define CPCFG0 0x0020 | ||
62 | #define CPCFG1 0x0024 | ||
63 | #define CPDST0A 0x0028 | ||
64 | #define CPDST0B 0x002c | ||
65 | #define CPDST1A 0x0030 | ||
66 | #define CPDST1B 0x0034 | ||
67 | #define CPXDSTA 0x0038 | ||
68 | #define CPXDSTB 0x003c | ||
69 | #define CPXCISRA 0x0048 | ||
70 | #define CPXCISRB 0x004c | ||
71 | #define CPGIG0ER 0x0050 | ||
72 | #define CPGIG1ER 0x0054 | ||
73 | #define CPGRWL 0x0068 | ||
74 | #define CPURSLMT 0x00f8 | ||
75 | #define UACFG 0x0200 | ||
76 | #define UAINTS 0x0204 | ||
77 | #define SDRXFCIE 0x4828 | ||
78 | #define SDTXFCIE 0x4928 | ||
79 | #define INTP0Status0 0x1B00 | ||
80 | #define INTP0Mask0 0x1B04 | ||
81 | #define INTP0Set0 0x1B08 | ||
82 | #define INTP0Clear0 0x1B0C | ||
83 | #define GXCFG 0x5000 | ||
84 | #define GXDMADRPFX 0x5018 | ||
85 | #define GXDMA_DESCADR 0x501c | ||
86 | #define GXCH0TDESSTRT 0x5054 | ||
87 | |||
88 | /* IRQ definitions */ | ||
89 | #define NMICONFIG 0xac0 | ||
90 | #define TITAN_MSGINT 0xc4 | ||
91 | #define TITAN_IRQ ((TITAN_MSGINT / 0x20) + 2) | ||
92 | #define FPGA0_MSGINT 0x5a | ||
93 | #define FPGA0_IRQ ((FPGA0_MSGINT / 0x20) + 2) | ||
94 | #define FPGA1_MSGINT 0x7b | ||
95 | #define FPGA1_IRQ ((FPGA1_MSGINT / 0x20) + 2) | ||
96 | #define PHY_MSGINT 0x9c | ||
97 | #define PHY_IRQ ((PHY_MSGINT / 0x20) + 2) | ||
98 | |||
99 | #if defined(CONFIG_BASLER_EXCITE_PROTOTYPE) | ||
100 | /* Pre-release units used interrupt pin #9 */ | ||
101 | #define USB_IRQ 11 | ||
102 | #else | ||
103 | /* Re-designed units use interrupt pin #1 */ | ||
104 | #define USB_MSGINT 0x39 | ||
105 | #define USB_IRQ ((USB_MSGINT / 0x20) + 2) | ||
106 | #endif | ||
107 | #define TIMER_IRQ 12 | ||
108 | |||
109 | |||
110 | /* Device address ranges */ | ||
111 | #define EXCITE_OFFS_OCD 0x1fffc000 | ||
112 | #define EXCITE_SIZE_OCD (16 * 1024) | ||
113 | #define EXCITE_PHYS_OCD CPHYSADDR(EXCITE_OFFS_OCD) | ||
114 | #define EXCITE_ADDR_OCD CKSEG1ADDR(EXCITE_OFFS_OCD) | ||
115 | |||
116 | #define EXCITE_OFFS_SCRAM 0x1fffa000 | ||
117 | #define EXCITE_SIZE_SCRAM (8 << 10) | ||
118 | #define EXCITE_PHYS_SCRAM CPHYSADDR(EXCITE_OFFS_SCRAM) | ||
119 | #define EXCITE_ADDR_SCRAM CKSEG1ADDR(EXCITE_OFFS_SCRAM) | ||
120 | |||
121 | #define EXCITE_OFFS_PCI_IO 0x1fff8000 | ||
122 | #define EXCITE_SIZE_PCI_IO (8 << 10) | ||
123 | #define EXCITE_PHYS_PCI_IO CPHYSADDR(EXCITE_OFFS_PCI_IO) | ||
124 | #define EXCITE_ADDR_PCI_IO CKSEG1ADDR(EXCITE_OFFS_PCI_IO) | ||
125 | |||
126 | #define EXCITE_OFFS_TITAN 0x1fff0000 | ||
127 | #define EXCITE_SIZE_TITAN (32 << 10) | ||
128 | #define EXCITE_PHYS_TITAN CPHYSADDR(EXCITE_OFFS_TITAN) | ||
129 | #define EXCITE_ADDR_TITAN CKSEG1ADDR(EXCITE_OFFS_TITAN) | ||
130 | |||
131 | #define EXCITE_OFFS_PCI_MEM 0x1ffe0000 | ||
132 | #define EXCITE_SIZE_PCI_MEM (64 << 10) | ||
133 | #define EXCITE_PHYS_PCI_MEM CPHYSADDR(EXCITE_OFFS_PCI_MEM) | ||
134 | #define EXCITE_ADDR_PCI_MEM CKSEG1ADDR(EXCITE_OFFS_PCI_MEM) | ||
135 | |||
136 | #define EXCITE_OFFS_FPGA 0x1ffdc000 | ||
137 | #define EXCITE_SIZE_FPGA (16 << 10) | ||
138 | #define EXCITE_PHYS_FPGA CPHYSADDR(EXCITE_OFFS_FPGA) | ||
139 | #define EXCITE_ADDR_FPGA CKSEG1ADDR(EXCITE_OFFS_FPGA) | ||
140 | |||
141 | #define EXCITE_OFFS_NAND 0x1ffd8000 | ||
142 | #define EXCITE_SIZE_NAND (16 << 10) | ||
143 | #define EXCITE_PHYS_NAND CPHYSADDR(EXCITE_OFFS_NAND) | ||
144 | #define EXCITE_ADDR_NAND CKSEG1ADDR(EXCITE_OFFS_NAND) | ||
145 | |||
146 | #define EXCITE_OFFS_BOOTROM 0x1f000000 | ||
147 | #define EXCITE_SIZE_BOOTROM (8 << 20) | ||
148 | #define EXCITE_PHYS_BOOTROM CPHYSADDR(EXCITE_OFFS_BOOTROM) | ||
149 | #define EXCITE_ADDR_BOOTROM CKSEG1ADDR(EXCITE_OFFS_BOOTROM) | ||
150 | |||
151 | /* FPGA address offsets */ | ||
152 | #define EXCITE_FPGA_DPR 0x0104 /* dual-ported ram */ | ||
153 | #define EXCITE_FPGA_SYSCTL 0x0200 /* system control register block */ | ||
154 | |||
155 | #endif /* __EXCITE_H__ */ | ||
diff --git a/include/asm-mips/mach-excite/excite_nandflash.h b/include/asm-mips/mach-excite/excite_nandflash.h new file mode 100644 index 000000000000..c4cf6140622e --- /dev/null +++ b/include/asm-mips/mach-excite/excite_nandflash.h | |||
@@ -0,0 +1,7 @@ | |||
1 | #ifndef __EXCITE_NANDFLASH_H__ | ||
2 | #define __EXCITE_NANDFLASH_H__ | ||
3 | |||
4 | /* Resource names */ | ||
5 | #define EXCITE_NANDFLASH_RESOURCE_REGS "excite_nandflash_regs" | ||
6 | |||
7 | #endif /* __EXCITE_NANDFLASH_H__ */ | ||
diff --git a/include/asm-mips/mach-excite/rm9k_eth.h b/include/asm-mips/mach-excite/rm9k_eth.h new file mode 100644 index 000000000000..94705a46f72e --- /dev/null +++ b/include/asm-mips/mach-excite/rm9k_eth.h | |||
@@ -0,0 +1,23 @@ | |||
1 | #if !defined(__RM9K_ETH_H__) | ||
2 | #define __RM9K_ETH_H__ | ||
3 | |||
4 | #define RM9K_GE_NAME "rm9k_ge" | ||
5 | |||
6 | /* Resource names */ | ||
7 | #define RM9K_GE_RESOURCE_MAC "rm9k_ge_mac" | ||
8 | #define RM9K_GE_RESOURCE_MSTAT "rm9k_ge_mstat" | ||
9 | #define RM9K_GE_RESOURCE_PKTPROC "rm9k_ge_pktproc" | ||
10 | #define RM9K_GE_RESOURCE_XDMA "rm9k_ge_xdma" | ||
11 | #define RM9K_GE_RESOURCE_FIFO_RX "rm9k_ge_fifo_rx" | ||
12 | #define RM9K_GE_RESOURCE_FIFO_TX "rm9k_ge_fifo_tx" | ||
13 | #define RM9K_GE_RESOURCE_FIFOMEM_RX "rm9k_ge_fifo_memory_rx" | ||
14 | #define RM9K_GE_RESOURCE_FIFOMEM_TX "rm9k_ge_fifo_memory_tx" | ||
15 | #define RM9K_GE_RESOURCE_PHY "rm9k_ge_phy" | ||
16 | #define RM9K_GE_RESOURCE_DMADESC_RX "rm9k_ge_dmadesc_rx" | ||
17 | #define RM9K_GE_RESOURCE_DMADESC_TX "rm9k_ge_dmadesc_tx" | ||
18 | #define RM9K_GE_RESOURCE_IRQ_MAIN "rm9k_ge_irq_main" | ||
19 | #define RM9K_GE_RESOURCE_IRQ_PHY "rm9k_ge_irq_phy" | ||
20 | #define RM9K_GE_RESOURCE_GPI_SLICE "rm9k_ge_gpi_slice" | ||
21 | #define RM9K_GE_RESOURCE_MDIO_CHANNEL "rm9k_ge_mdio_channel" | ||
22 | |||
23 | #endif /* !defined(__RM9K_ETH_H__) */ | ||
diff --git a/include/asm-mips/mach-excite/rm9k_wdt.h b/include/asm-mips/mach-excite/rm9k_wdt.h new file mode 100644 index 000000000000..3fa3c08d2da7 --- /dev/null +++ b/include/asm-mips/mach-excite/rm9k_wdt.h | |||
@@ -0,0 +1,12 @@ | |||
1 | #ifndef __RM9K_WDT_H__ | ||
2 | #define __RM9K_WDT_H__ | ||
3 | |||
4 | /* Device name */ | ||
5 | #define WDT_NAME "wdt_gpi" | ||
6 | |||
7 | /* Resource names */ | ||
8 | #define WDT_RESOURCE_REGS "excite_watchdog_regs" | ||
9 | #define WDT_RESOURCE_IRQ "excite_watchdog_irq" | ||
10 | #define WDT_RESOURCE_COUNTER "excite_watchdog_counter" | ||
11 | |||
12 | #endif /* __RM9K_WDT_H__ */ | ||
diff --git a/include/asm-mips/mach-excite/rm9k_xicap.h b/include/asm-mips/mach-excite/rm9k_xicap.h new file mode 100644 index 000000000000..009577734a8d --- /dev/null +++ b/include/asm-mips/mach-excite/rm9k_xicap.h | |||
@@ -0,0 +1,16 @@ | |||
1 | #ifndef __EXCITE_XICAP_H__ | ||
2 | #define __EXCITE_XICAP_H__ | ||
3 | |||
4 | |||
5 | /* Resource names */ | ||
6 | #define XICAP_RESOURCE_FIFO_RX "xicap_fifo_rx" | ||
7 | #define XICAP_RESOURCE_FIFO_TX "xicap_fifo_tx" | ||
8 | #define XICAP_RESOURCE_XDMA "xicap_xdma" | ||
9 | #define XICAP_RESOURCE_DMADESC "xicap_dmadesc" | ||
10 | #define XICAP_RESOURCE_PKTPROC "xicap_pktproc" | ||
11 | #define XICAP_RESOURCE_IRQ "xicap_irq" | ||
12 | #define XICAP_RESOURCE_GPI_SLICE "xicap_gpi_slice" | ||
13 | #define XICAP_RESOURCE_FIFO_BLK "xicap_fifo_blocks" | ||
14 | #define XICAP_RESOURCE_PKT_STREAM "xicap_pkt_stream" | ||
15 | |||
16 | #endif /* __EXCITE_XICAP_H__ */ | ||
diff --git a/include/asm-mips/mach-generic/ide.h b/include/asm-mips/mach-generic/ide.h index e3315359500a..6eba2e576aaa 100644 --- a/include/asm-mips/mach-generic/ide.h +++ b/include/asm-mips/mach-generic/ide.h | |||
@@ -15,7 +15,6 @@ | |||
15 | 15 | ||
16 | #ifdef __KERNEL__ | 16 | #ifdef __KERNEL__ |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | #include <linux/pci.h> | 18 | #include <linux/pci.h> |
20 | #include <linux/stddef.h> | 19 | #include <linux/stddef.h> |
21 | #include <asm/processor.h> | 20 | #include <asm/processor.h> |
diff --git a/include/asm-mips/mach-generic/kmalloc.h b/include/asm-mips/mach-generic/kmalloc.h index 373d66dee9d7..410ab5f6c563 100644 --- a/include/asm-mips/mach-generic/kmalloc.h +++ b/include/asm-mips/mach-generic/kmalloc.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_MACH_GENERIC_KMALLOC_H | 1 | #ifndef __ASM_MACH_GENERIC_KMALLOC_H |
2 | #define __ASM_MACH_GENERIC_KMALLOC_H | 2 | #define __ASM_MACH_GENERIC_KMALLOC_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifndef CONFIG_DMA_COHERENT | 5 | #ifndef CONFIG_DMA_COHERENT |
7 | /* | 6 | /* |
diff --git a/include/asm-mips/mach-generic/param.h b/include/asm-mips/mach-generic/param.h deleted file mode 100644 index a0d12f964e4f..000000000000 --- a/include/asm-mips/mach-generic/param.h +++ /dev/null | |||
@@ -1,13 +0,0 @@ | |||
1 | /* | ||
2 | * This file is subject to the terms and conditions of the GNU General Public | ||
3 | * License. See the file "COPYING" in the main directory of this archive | ||
4 | * for more details. | ||
5 | * | ||
6 | * Copyright (C) 2003 by Ralf Baechle | ||
7 | */ | ||
8 | #ifndef __ASM_MACH_GENERIC_PARAM_H | ||
9 | #define __ASM_MACH_GENERIC_PARAM_H | ||
10 | |||
11 | #define HZ 1000 /* Internal kernel timer frequency */ | ||
12 | |||
13 | #endif /* __ASM_MACH_GENERIC_PARAM_H */ | ||
diff --git a/include/asm-mips/mach-generic/spaces.h b/include/asm-mips/mach-generic/spaces.h index b849d8dd7e78..0ae9997bc9a8 100644 --- a/include/asm-mips/mach-generic/spaces.h +++ b/include/asm-mips/mach-generic/spaces.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASM_MACH_GENERIC_SPACES_H | 10 | #ifndef _ASM_MACH_GENERIC_SPACES_H |
11 | #define _ASM_MACH_GENERIC_SPACES_H | 11 | #define _ASM_MACH_GENERIC_SPACES_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | #ifdef CONFIG_32BIT | 14 | #ifdef CONFIG_32BIT |
16 | 15 | ||
diff --git a/include/asm-mips/mach-ip22/cpu-feature-overrides.h b/include/asm-mips/mach-ip22/cpu-feature-overrides.h index 2a37bedb4053..f7c5dc8a5336 100644 --- a/include/asm-mips/mach-ip22/cpu-feature-overrides.h +++ b/include/asm-mips/mach-ip22/cpu-feature-overrides.h | |||
@@ -13,7 +13,7 @@ | |||
13 | */ | 13 | */ |
14 | #define cpu_has_tlb 1 | 14 | #define cpu_has_tlb 1 |
15 | #define cpu_has_4kex 1 | 15 | #define cpu_has_4kex 1 |
16 | #define cpu_has_4kcache 1 | 16 | #define cpu_has_4k_cache 1 |
17 | #define cpu_has_fpu 1 | 17 | #define cpu_has_fpu 1 |
18 | #define cpu_has_32fpr 1 | 18 | #define cpu_has_32fpr 1 |
19 | #define cpu_has_counter 1 | 19 | #define cpu_has_counter 1 |
diff --git a/include/asm-mips/mach-ip22/spaces.h b/include/asm-mips/mach-ip22/spaces.h index 8385f716798d..ab20c026fd19 100644 --- a/include/asm-mips/mach-ip22/spaces.h +++ b/include/asm-mips/mach-ip22/spaces.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASM_MACH_IP22_SPACES_H | 10 | #ifndef _ASM_MACH_IP22_SPACES_H |
11 | #define _ASM_MACH_IP22_SPACES_H | 11 | #define _ASM_MACH_IP22_SPACES_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | #ifdef CONFIG_32BIT | 14 | #ifdef CONFIG_32BIT |
16 | 15 | ||
diff --git a/include/asm-mips/mach-ip27/cpu-feature-overrides.h b/include/asm-mips/mach-ip27/cpu-feature-overrides.h index 2d2f5b91e47f..19c2d135985b 100644 --- a/include/asm-mips/mach-ip27/cpu-feature-overrides.h +++ b/include/asm-mips/mach-ip27/cpu-feature-overrides.h | |||
@@ -31,6 +31,9 @@ | |||
31 | #define cpu_has_nofpuex 0 | 31 | #define cpu_has_nofpuex 0 |
32 | #define cpu_has_64bits 1 | 32 | #define cpu_has_64bits 1 |
33 | 33 | ||
34 | #define cpu_has_4kex 1 | ||
35 | #define cpu_has_4k_cache 1 | ||
36 | |||
34 | #define cpu_has_subset_pcaches 1 | 37 | #define cpu_has_subset_pcaches 1 |
35 | 38 | ||
36 | #define cpu_dcache_line_size() 32 | 39 | #define cpu_dcache_line_size() 32 |
diff --git a/include/asm-mips/mach-ip32/cpu-feature-overrides.h b/include/asm-mips/mach-ip32/cpu-feature-overrides.h index 36070b5654ab..2a3de092bf13 100644 --- a/include/asm-mips/mach-ip32/cpu-feature-overrides.h +++ b/include/asm-mips/mach-ip32/cpu-feature-overrides.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef __ASM_MACH_IP32_CPU_FEATURE_OVERRIDES_H | 9 | #ifndef __ASM_MACH_IP32_CPU_FEATURE_OVERRIDES_H |
10 | #define __ASM_MACH_IP32_CPU_FEATURE_OVERRIDES_H | 10 | #define __ASM_MACH_IP32_CPU_FEATURE_OVERRIDES_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | /* | 13 | /* |
15 | * R5000 has an interesting "restriction": ll(d)/sc(d) | 14 | * R5000 has an interesting "restriction": ll(d)/sc(d) |
@@ -38,6 +37,8 @@ | |||
38 | #define cpu_has_vtag_icache 0 | 37 | #define cpu_has_vtag_icache 0 |
39 | #define cpu_has_ic_fills_f_dc 0 | 38 | #define cpu_has_ic_fills_f_dc 0 |
40 | #define cpu_has_dsp 0 | 39 | #define cpu_has_dsp 0 |
40 | #define cpu_has_4k_cache 1 | ||
41 | |||
41 | 42 | ||
42 | #define cpu_has_mips32r1 0 | 43 | #define cpu_has_mips32r1 0 |
43 | #define cpu_has_mips32r2 0 | 44 | #define cpu_has_mips32r2 0 |
diff --git a/include/asm-mips/mach-ip32/kmalloc.h b/include/asm-mips/mach-ip32/kmalloc.h index 9d2d4d9ac036..f6198a21fba1 100644 --- a/include/asm-mips/mach-ip32/kmalloc.h +++ b/include/asm-mips/mach-ip32/kmalloc.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_MACH_IP32_KMALLOC_H | 1 | #ifndef __ASM_MACH_IP32_KMALLOC_H |
2 | #define __ASM_MACH_IP32_KMALLOC_H | 2 | #define __ASM_MACH_IP32_KMALLOC_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #if defined(CONFIG_CPU_R5000) || defined (CONFIG_CPU_RM7000) | 5 | #if defined(CONFIG_CPU_R5000) || defined (CONFIG_CPU_RM7000) |
7 | #define ARCH_KMALLOC_MINALIGN 32 | 6 | #define ARCH_KMALLOC_MINALIGN 32 |
diff --git a/include/asm-mips/mach-jazz/param.h b/include/asm-mips/mach-jazz/param.h deleted file mode 100644 index 639763a517bc..000000000000 --- a/include/asm-mips/mach-jazz/param.h +++ /dev/null | |||
@@ -1,16 +0,0 @@ | |||
1 | /* | ||
2 | * This file is subject to the terms and conditions of the GNU General Public | ||
3 | * License. See the file "COPYING" in the main directory of this archive | ||
4 | * for more details. | ||
5 | * | ||
6 | * Copyright (C) 2003 by Ralf Baechle | ||
7 | */ | ||
8 | #ifndef __ASM_MACH_JAZZ_PARAM_H | ||
9 | #define __ASM_MACH_JAZZ_PARAM_H | ||
10 | |||
11 | /* | ||
12 | * Jazz is currently using the internal 100Hz timer of the R4030 | ||
13 | */ | ||
14 | #define HZ 100 /* Internal kernel timer frequency */ | ||
15 | |||
16 | #endif /* __ASM_MACH_JAZZ_PARAM_H */ | ||
diff --git a/include/asm-mips/mach-mips/cpu-feature-overrides.h b/include/asm-mips/mach-mips/cpu-feature-overrides.h index e06af6c86f86..e960679f54ba 100644 --- a/include/asm-mips/mach-mips/cpu-feature-overrides.h +++ b/include/asm-mips/mach-mips/cpu-feature-overrides.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef __ASM_MACH_MIPS_CPU_FEATURE_OVERRIDES_H | 9 | #ifndef __ASM_MACH_MIPS_CPU_FEATURE_OVERRIDES_H |
10 | #define __ASM_MACH_MIPS_CPU_FEATURE_OVERRIDES_H | 10 | #define __ASM_MACH_MIPS_CPU_FEATURE_OVERRIDES_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | /* | 13 | /* |
15 | * CPU feature overrides for MIPS boards | 14 | * CPU feature overrides for MIPS boards |
@@ -17,7 +16,7 @@ | |||
17 | #ifdef CONFIG_CPU_MIPS32 | 16 | #ifdef CONFIG_CPU_MIPS32 |
18 | #define cpu_has_tlb 1 | 17 | #define cpu_has_tlb 1 |
19 | #define cpu_has_4kex 1 | 18 | #define cpu_has_4kex 1 |
20 | #define cpu_has_4kcache 1 | 19 | #define cpu_has_4k_cache 1 |
21 | /* #define cpu_has_fpu ? */ | 20 | /* #define cpu_has_fpu ? */ |
22 | /* #define cpu_has_32fpr ? */ | 21 | /* #define cpu_has_32fpr ? */ |
23 | #define cpu_has_counter 1 | 22 | #define cpu_has_counter 1 |
@@ -47,7 +46,7 @@ | |||
47 | #ifdef CONFIG_CPU_MIPS64 | 46 | #ifdef CONFIG_CPU_MIPS64 |
48 | #define cpu_has_tlb 1 | 47 | #define cpu_has_tlb 1 |
49 | #define cpu_has_4kex 1 | 48 | #define cpu_has_4kex 1 |
50 | #define cpu_has_4kcache 1 | 49 | #define cpu_has_4k_cache 1 |
51 | /* #define cpu_has_fpu ? */ | 50 | /* #define cpu_has_fpu ? */ |
52 | /* #define cpu_has_32fpr ? */ | 51 | /* #define cpu_has_32fpr ? */ |
53 | #define cpu_has_counter 1 | 52 | #define cpu_has_counter 1 |
diff --git a/include/asm-mips/mach-mips/irq.h b/include/asm-mips/mach-mips/irq.h index f8579696ca54..083d9c512a04 100644 --- a/include/asm-mips/mach-mips/irq.h +++ b/include/asm-mips/mach-mips/irq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_MACH_MIPS_IRQ_H | 1 | #ifndef __ASM_MACH_MIPS_IRQ_H |
2 | #define __ASM_MACH_MIPS_IRQ_H | 2 | #define __ASM_MACH_MIPS_IRQ_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #define NR_IRQS 256 | 5 | #define NR_IRQS 256 |
7 | 6 | ||
diff --git a/include/asm-mips/mach-pb1x00/pb1550.h b/include/asm-mips/mach-pb1x00/pb1550.h index 9578ead11e8a..9a4955ce3b4a 100644 --- a/include/asm-mips/mach-pb1x00/pb1550.h +++ b/include/asm-mips/mach-pb1x00/pb1550.h | |||
@@ -27,7 +27,6 @@ | |||
27 | #ifndef __ASM_PB1550_H | 27 | #ifndef __ASM_PB1550_H |
28 | #define __ASM_PB1550_H | 28 | #define __ASM_PB1550_H |
29 | 29 | ||
30 | #include <linux/config.h> | ||
31 | #include <linux/types.h> | 30 | #include <linux/types.h> |
32 | 31 | ||
33 | #define DBDMA_AC97_TX_CHAN DSCR_CMD0_PSC1_TX | 32 | #define DBDMA_AC97_TX_CHAN DSCR_CMD0_PSC1_TX |
diff --git a/include/asm-mips/mach-qemu/param.h b/include/asm-mips/mach-qemu/param.h deleted file mode 100644 index cb30ee490ae6..000000000000 --- a/include/asm-mips/mach-qemu/param.h +++ /dev/null | |||
@@ -1,13 +0,0 @@ | |||
1 | /* | ||
2 | * This file is subject to the terms and conditions of the GNU General Public | ||
3 | * License. See the file "COPYING" in the main directory of this archive | ||
4 | * for more details. | ||
5 | * | ||
6 | * Copyright (C) 2005 by Ralf Baechle | ||
7 | */ | ||
8 | #ifndef __ASM_MACH_QEMU_PARAM_H | ||
9 | #define __ASM_MACH_QEMU_PARAM_H | ||
10 | |||
11 | #define HZ 100 /* Internal kernel timer frequency */ | ||
12 | |||
13 | #endif /* __ASM_MACH_QEMU_PARAM_H */ | ||
diff --git a/include/asm-mips/mach-rm200/cpu-feature-overrides.h b/include/asm-mips/mach-rm200/cpu-feature-overrides.h index 91e7cf5f2bfe..11410ae10d36 100644 --- a/include/asm-mips/mach-rm200/cpu-feature-overrides.h +++ b/include/asm-mips/mach-rm200/cpu-feature-overrides.h | |||
@@ -14,7 +14,7 @@ | |||
14 | 14 | ||
15 | #define cpu_has_tlb 1 | 15 | #define cpu_has_tlb 1 |
16 | #define cpu_has_4kex 1 | 16 | #define cpu_has_4kex 1 |
17 | #define cpu_has_4kcache 1 | 17 | #define cpu_has_4k_cache 1 |
18 | #define cpu_has_fpu 1 | 18 | #define cpu_has_fpu 1 |
19 | #define cpu_has_32fpr 1 | 19 | #define cpu_has_32fpr 1 |
20 | #define cpu_has_counter 1 | 20 | #define cpu_has_counter 1 |
@@ -35,10 +35,8 @@ | |||
35 | #define cpu_has_nofpuex 0 | 35 | #define cpu_has_nofpuex 0 |
36 | #define cpu_has_64bits 1 | 36 | #define cpu_has_64bits 1 |
37 | 37 | ||
38 | #define cpu_has_subset_pcaches 0 /* No S-cache on R5000 I think ... */ | ||
39 | #define cpu_dcache_line_size() 32 | 38 | #define cpu_dcache_line_size() 32 |
40 | #define cpu_icache_line_size() 32 | 39 | #define cpu_icache_line_size() 32 |
41 | #define cpu_scache_line_size() 0 /* No S-cache on R5000 I think ... */ | ||
42 | 40 | ||
43 | #define cpu_has_mips32r1 0 | 41 | #define cpu_has_mips32r1 0 |
44 | #define cpu_has_mips32r2 0 | 42 | #define cpu_has_mips32r2 0 |
diff --git a/include/asm-mips/mach-sim/cpu-feature-overrides.h b/include/asm-mips/mach-sim/cpu-feature-overrides.h index cadbe8eda79c..d736bdadb6df 100644 --- a/include/asm-mips/mach-sim/cpu-feature-overrides.h +++ b/include/asm-mips/mach-sim/cpu-feature-overrides.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef __ASM_MACH_SIM_CPU_FEATURE_OVERRIDES_H | 8 | #ifndef __ASM_MACH_SIM_CPU_FEATURE_OVERRIDES_H |
9 | #define __ASM_MACH_SIM_CPU_FEATURE_OVERRIDES_H | 9 | #define __ASM_MACH_SIM_CPU_FEATURE_OVERRIDES_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | 11 | ||
13 | /* | 12 | /* |
14 | * CPU feature overrides for MIPS boards | 13 | * CPU feature overrides for MIPS boards |
@@ -16,7 +15,7 @@ | |||
16 | #ifdef CONFIG_CPU_MIPS32 | 15 | #ifdef CONFIG_CPU_MIPS32 |
17 | #define cpu_has_tlb 1 | 16 | #define cpu_has_tlb 1 |
18 | #define cpu_has_4kex 1 | 17 | #define cpu_has_4kex 1 |
19 | #define cpu_has_4kcache 1 | 18 | #define cpu_has_4k_cache 1 |
20 | #define cpu_has_fpu 0 | 19 | #define cpu_has_fpu 0 |
21 | /* #define cpu_has_32fpr ? */ | 20 | /* #define cpu_has_32fpr ? */ |
22 | #define cpu_has_counter 1 | 21 | #define cpu_has_counter 1 |
@@ -41,7 +40,7 @@ | |||
41 | #ifdef CONFIG_CPU_MIPS64 | 40 | #ifdef CONFIG_CPU_MIPS64 |
42 | #define cpu_has_tlb 1 | 41 | #define cpu_has_tlb 1 |
43 | #define cpu_has_4kex 1 | 42 | #define cpu_has_4kex 1 |
44 | #define cpu_has_4kcache 1 | 43 | #define cpu_has_4k_cache 1 |
45 | /* #define cpu_has_fpu ? */ | 44 | /* #define cpu_has_fpu ? */ |
46 | /* #define cpu_has_32fpr ? */ | 45 | /* #define cpu_has_32fpr ? */ |
47 | #define cpu_has_counter 1 | 46 | #define cpu_has_counter 1 |
diff --git a/include/asm-mips/mach-wrppmc/mach-gt64120.h b/include/asm-mips/mach-wrppmc/mach-gt64120.h new file mode 100644 index 000000000000..ba9205a04582 --- /dev/null +++ b/include/asm-mips/mach-wrppmc/mach-gt64120.h | |||
@@ -0,0 +1,84 @@ | |||
1 | /* | ||
2 | * This is a direct copy of the ev96100.h file, with a global | ||
3 | * search and replace. The numbers are the same. | ||
4 | * | ||
5 | * The reason I'm duplicating this is so that the 64120/96100 | ||
6 | * defines won't be confusing in the source code. | ||
7 | */ | ||
8 | #ifndef __ASM_MIPS_GT64120_H | ||
9 | #define __ASM_MIPS_GT64120_H | ||
10 | |||
11 | /* | ||
12 | * This is the CPU physical memory map of PPMC Board: | ||
13 | * | ||
14 | * 0x00000000-0x03FFFFFF - 64MB SDRAM (SCS[0]#) | ||
15 | * 0x1C000000-0x1C000000 - LED (CS0) | ||
16 | * 0x1C800000-0x1C800007 - UART 16550 port (CS1) | ||
17 | * 0x1F000000-0x1F000000 - MailBox (CS3) | ||
18 | * 0x1FC00000-0x20000000 - 4MB Flash (BOOT CS) | ||
19 | */ | ||
20 | |||
21 | #define WRPPMC_SDRAM_SCS0_BASE 0x00000000 | ||
22 | #define WRPPMC_SDRAM_SCS0_SIZE 0x04000000 | ||
23 | |||
24 | #define WRPPMC_UART16550_BASE 0x1C800000 | ||
25 | #define WRPPMC_UART16550_CLOCK 3686400 /* 3.68MHZ */ | ||
26 | |||
27 | #define WRPPMC_LED_BASE 0x1C000000 | ||
28 | #define WRPPMC_MBOX_BASE 0x1F000000 | ||
29 | |||
30 | #define WRPPMC_BOOTROM_BASE 0x1FC00000 | ||
31 | #define WRPPMC_BOOTROM_SIZE 0x00400000 /* 4M Flash */ | ||
32 | |||
33 | #define WRPPMC_MIPS_TIMER_IRQ 7 /* MIPS compare/count timer interrupt */ | ||
34 | #define WRPPMC_UART16550_IRQ 6 | ||
35 | #define WRPPMC_PCI_INTA_IRQ 3 | ||
36 | |||
37 | /* | ||
38 | * PCI Bus I/O and Memory resources allocation | ||
39 | * | ||
40 | * NOTE: We only have PCI_0 hose interface | ||
41 | */ | ||
42 | #define GT_PCI_MEM_BASE 0x13000000UL | ||
43 | #define GT_PCI_MEM_SIZE 0x02000000UL | ||
44 | #define GT_PCI_IO_BASE 0x11000000UL | ||
45 | #define GT_PCI_IO_SIZE 0x02000000UL | ||
46 | #define GT_ISA_IO_BASE PCI_IO_BASE | ||
47 | |||
48 | /* | ||
49 | * PCI interrupts will come in on either the INTA or INTD interrups lines, | ||
50 | * which are mapped to the #2 and #5 interrupt pins of the MIPS. On our | ||
51 | * boards, they all either come in on IntD or they all come in on IntA, they | ||
52 | * aren't mixed. There can be numerous PCI interrupts, so we keep a list of the | ||
53 | * "requested" interrupt numbers and go through the list whenever we get an | ||
54 | * IntA/D. | ||
55 | * | ||
56 | * Interrupts < 8 are directly wired to the processor; PCI INTA is 8 and | ||
57 | * INTD is 11. | ||
58 | */ | ||
59 | #define GT_TIMER 4 | ||
60 | #define GT_INTA 2 | ||
61 | #define GT_INTD 5 | ||
62 | |||
63 | #ifndef __ASSEMBLY__ | ||
64 | |||
65 | /* | ||
66 | * GT64120 internal register space base address | ||
67 | */ | ||
68 | extern unsigned long gt64120_base; | ||
69 | |||
70 | #define GT64120_BASE (gt64120_base) | ||
71 | |||
72 | /* define WRPPMC_EARLY_DEBUG to enable early output something to UART */ | ||
73 | #undef WRPPMC_EARLY_DEBUG | ||
74 | |||
75 | #ifdef WRPPMC_EARLY_DEBUG | ||
76 | extern void wrppmc_led_on(int mask); | ||
77 | extern void wrppmc_led_off(int mask); | ||
78 | extern void wrppmc_early_printk(const char *fmt, ...); | ||
79 | #else | ||
80 | #define wrppmc_early_printk(fmt, ...) do {} while (0) | ||
81 | #endif /* WRPPMC_EARLY_DEBUG */ | ||
82 | |||
83 | #endif /* __ASSEMBLY__ */ | ||
84 | #endif /* __ASM_MIPS_GT64120_H */ | ||
diff --git a/include/asm-mips/mips-boards/generic.h b/include/asm-mips/mips-boards/generic.h index fa8b913cc3e0..b98f1658cfd0 100644 --- a/include/asm-mips/mips-boards/generic.h +++ b/include/asm-mips/mips-boards/generic.h | |||
@@ -20,7 +20,6 @@ | |||
20 | #ifndef __ASM_MIPS_BOARDS_GENERIC_H | 20 | #ifndef __ASM_MIPS_BOARDS_GENERIC_H |
21 | #define __ASM_MIPS_BOARDS_GENERIC_H | 21 | #define __ASM_MIPS_BOARDS_GENERIC_H |
22 | 22 | ||
23 | #include <linux/config.h> | ||
24 | #include <asm/addrspace.h> | 23 | #include <asm/addrspace.h> |
25 | #include <asm/byteorder.h> | 24 | #include <asm/byteorder.h> |
26 | #include <asm/mips-boards/bonito64.h> | 25 | #include <asm/mips-boards/bonito64.h> |
diff --git a/include/asm-mips/mipsregs.h b/include/asm-mips/mipsregs.h index 5af7517fce8a..673977901ed3 100644 --- a/include/asm-mips/mipsregs.h +++ b/include/asm-mips/mipsregs.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef _ASM_MIPSREGS_H | 13 | #ifndef _ASM_MIPSREGS_H |
14 | #define _ASM_MIPSREGS_H | 14 | #define _ASM_MIPSREGS_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/linkage.h> | 16 | #include <linux/linkage.h> |
18 | #include <asm/hazards.h> | 17 | #include <asm/hazards.h> |
19 | 18 | ||
@@ -1451,12 +1450,10 @@ static inline void __emt(unsigned int previous) | |||
1451 | { | 1450 | { |
1452 | if ((previous & __EMT_ENABLE)) | 1451 | if ((previous & __EMT_ENABLE)) |
1453 | __asm__ __volatile__( | 1452 | __asm__ __volatile__( |
1454 | " .set noreorder \n" | ||
1455 | " .set mips32r2 \n" | 1453 | " .set mips32r2 \n" |
1456 | " .word 0x41600be1 # emt \n" | 1454 | " .word 0x41600be1 # emt \n" |
1457 | " ehb \n" | 1455 | " ehb \n" |
1458 | " .set mips0 \n" | 1456 | " .set mips0 \n"); |
1459 | " .set reorder \n"); | ||
1460 | } | 1457 | } |
1461 | 1458 | ||
1462 | static inline void __ehb(void) | 1459 | static inline void __ehb(void) |
diff --git a/include/asm-mips/mmu_context.h b/include/asm-mips/mmu_context.h index 6e09f4c87211..18b69de87daa 100644 --- a/include/asm-mips/mmu_context.h +++ b/include/asm-mips/mmu_context.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_MMU_CONTEXT_H | 11 | #ifndef _ASM_MMU_CONTEXT_H |
12 | #define _ASM_MMU_CONTEXT_H | 12 | #define _ASM_MMU_CONTEXT_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/errno.h> | 14 | #include <linux/errno.h> |
16 | #include <linux/sched.h> | 15 | #include <linux/sched.h> |
17 | #include <linux/slab.h> | 16 | #include <linux/slab.h> |
diff --git a/include/asm-mips/mmzone.h b/include/asm-mips/mmzone.h index 7bde4432092b..dc231c89bef9 100644 --- a/include/asm-mips/mmzone.h +++ b/include/asm-mips/mmzone.h | |||
@@ -5,7 +5,6 @@ | |||
5 | #ifndef _ASM_MMZONE_H_ | 5 | #ifndef _ASM_MMZONE_H_ |
6 | #define _ASM_MMZONE_H_ | 6 | #define _ASM_MMZONE_H_ |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | #include <asm/page.h> | 8 | #include <asm/page.h> |
10 | #include <mmzone.h> | 9 | #include <mmzone.h> |
11 | 10 | ||
@@ -14,17 +13,6 @@ | |||
14 | #define kvaddr_to_nid(kvaddr) pa_to_nid(__pa(kvaddr)) | 13 | #define kvaddr_to_nid(kvaddr) pa_to_nid(__pa(kvaddr)) |
15 | #define pfn_to_nid(pfn) pa_to_nid((pfn) << PAGE_SHIFT) | 14 | #define pfn_to_nid(pfn) pa_to_nid((pfn) << PAGE_SHIFT) |
16 | 15 | ||
17 | #define pfn_valid(pfn) \ | ||
18 | ({ \ | ||
19 | unsigned long __pfn = (pfn); \ | ||
20 | int __n = pfn_to_nid(__pfn); \ | ||
21 | ((__n >= 0) ? (__pfn < NODE_DATA(__n)->node_start_pfn + \ | ||
22 | NODE_DATA(__n)->node_spanned_pages) : 0);\ | ||
23 | }) | ||
24 | |||
25 | /* XXX: FIXME -- wli */ | ||
26 | #define kern_addr_valid(addr) (0) | ||
27 | |||
28 | #endif /* CONFIG_DISCONTIGMEM */ | 16 | #endif /* CONFIG_DISCONTIGMEM */ |
29 | 17 | ||
30 | #endif /* _ASM_MMZONE_H_ */ | 18 | #endif /* _ASM_MMZONE_H_ */ |
diff --git a/include/asm-mips/module.h b/include/asm-mips/module.h index 2af496c78c12..399d03f1c4fc 100644 --- a/include/asm-mips/module.h +++ b/include/asm-mips/module.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_MODULE_H | 1 | #ifndef _ASM_MODULE_H |
2 | #define _ASM_MODULE_H | 2 | #define _ASM_MODULE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/list.h> | 4 | #include <linux/list.h> |
6 | #include <asm/uaccess.h> | 5 | #include <asm/uaccess.h> |
7 | 6 | ||
diff --git a/include/asm-mips/msgbuf.h b/include/asm-mips/msgbuf.h index a1533959742e..0d6c7f14de31 100644 --- a/include/asm-mips/msgbuf.h +++ b/include/asm-mips/msgbuf.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_MSGBUF_H | 1 | #ifndef _ASM_MSGBUF_H |
2 | #define _ASM_MSGBUF_H | 2 | #define _ASM_MSGBUF_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * The msqid64_ds structure for the MIPS architecture. | 6 | * The msqid64_ds structure for the MIPS architecture. |
diff --git a/include/asm-mips/paccess.h b/include/asm-mips/paccess.h index 46f2d23d2697..147844ef103b 100644 --- a/include/asm-mips/paccess.h +++ b/include/asm-mips/paccess.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef _ASM_PACCESS_H | 13 | #ifndef _ASM_PACCESS_H |
14 | #define _ASM_PACCESS_H | 14 | #define _ASM_PACCESS_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/errno.h> | 16 | #include <linux/errno.h> |
18 | 17 | ||
19 | #ifdef CONFIG_32BIT | 18 | #ifdef CONFIG_32BIT |
diff --git a/include/asm-mips/page.h b/include/asm-mips/page.h index 4035ec79ecd4..6b97744f00cd 100644 --- a/include/asm-mips/page.h +++ b/include/asm-mips/page.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_PAGE_H | 9 | #ifndef _ASM_PAGE_H |
10 | #define _ASM_PAGE_H | 10 | #define _ASM_PAGE_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | #ifdef __KERNEL__ | 13 | #ifdef __KERNEL__ |
15 | 14 | ||
@@ -145,6 +144,25 @@ typedef struct { unsigned long pgprot; } pgprot_t; | |||
145 | #endif | 144 | #endif |
146 | #endif | 145 | #endif |
147 | 146 | ||
147 | #ifdef CONFIG_FLATMEM | ||
148 | |||
149 | #define pfn_valid(pfn) ((pfn) < max_mapnr) | ||
150 | |||
151 | #elif defined(CONFIG_NEED_MULTIPLE_NODES) | ||
152 | |||
153 | #define pfn_valid(pfn) \ | ||
154 | ({ \ | ||
155 | unsigned long __pfn = (pfn); \ | ||
156 | int __n = pfn_to_nid(__pfn); \ | ||
157 | ((__n >= 0) ? (__pfn < NODE_DATA(__n)->node_start_pfn + \ | ||
158 | NODE_DATA(__n)->node_spanned_pages) \ | ||
159 | : 0); \ | ||
160 | }) | ||
161 | |||
162 | #else | ||
163 | #error Provide a definition of pfn_valid | ||
164 | #endif | ||
165 | |||
148 | #define virt_to_page(kaddr) pfn_to_page(__pa(kaddr) >> PAGE_SHIFT) | 166 | #define virt_to_page(kaddr) pfn_to_page(__pa(kaddr) >> PAGE_SHIFT) |
149 | #define virt_addr_valid(kaddr) pfn_valid(__pa(kaddr) >> PAGE_SHIFT) | 167 | #define virt_addr_valid(kaddr) pfn_valid(__pa(kaddr) >> PAGE_SHIFT) |
150 | 168 | ||
diff --git a/include/asm-mips/param.h b/include/asm-mips/param.h index 2bead8273ced..1d9bb8c5ab24 100644 --- a/include/asm-mips/param.h +++ b/include/asm-mips/param.h | |||
@@ -11,7 +11,7 @@ | |||
11 | 11 | ||
12 | #ifdef __KERNEL__ | 12 | #ifdef __KERNEL__ |
13 | 13 | ||
14 | # include <param.h> /* Internal kernel timer frequency */ | 14 | # define HZ CONFIG_HZ /* Internal kernel timer frequency */ |
15 | # define USER_HZ 100 /* .. some user interfaces are in "ticks" */ | 15 | # define USER_HZ 100 /* .. some user interfaces are in "ticks" */ |
16 | # define CLOCKS_PER_SEC (USER_HZ) /* like times() */ | 16 | # define CLOCKS_PER_SEC (USER_HZ) /* like times() */ |
17 | #endif | 17 | #endif |
diff --git a/include/asm-mips/pci.h b/include/asm-mips/pci.h index 6c9ad8171a77..c4d68bebdca6 100644 --- a/include/asm-mips/pci.h +++ b/include/asm-mips/pci.h | |||
@@ -6,7 +6,6 @@ | |||
6 | #ifndef _ASM_PCI_H | 6 | #ifndef _ASM_PCI_H |
7 | #define _ASM_PCI_H | 7 | #define _ASM_PCI_H |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <linux/mm.h> | 9 | #include <linux/mm.h> |
11 | 10 | ||
12 | #ifdef __KERNEL__ | 11 | #ifdef __KERNEL__ |
diff --git a/include/asm-mips/pci/bridge.h b/include/asm-mips/pci/bridge.h index b4ee995c56e6..0c45e7598f3f 100644 --- a/include/asm-mips/pci/bridge.h +++ b/include/asm-mips/pci/bridge.h | |||
@@ -15,6 +15,7 @@ | |||
15 | #include <linux/types.h> | 15 | #include <linux/types.h> |
16 | #include <linux/pci.h> | 16 | #include <linux/pci.h> |
17 | #include <asm/xtalk/xwidget.h> /* generic widget header */ | 17 | #include <asm/xtalk/xwidget.h> /* generic widget header */ |
18 | #include <asm/sn/types.h> | ||
18 | 19 | ||
19 | /* I/O page size */ | 20 | /* I/O page size */ |
20 | 21 | ||
@@ -848,4 +849,6 @@ struct bridge_controller { | |||
848 | extern void register_bridge_irq(unsigned int irq); | 849 | extern void register_bridge_irq(unsigned int irq); |
849 | extern int request_bridge_irq(struct bridge_controller *bc); | 850 | extern int request_bridge_irq(struct bridge_controller *bc); |
850 | 851 | ||
852 | extern struct pci_ops bridge_pci_ops; | ||
853 | |||
851 | #endif /* _ASM_PCI_BRIDGE_H */ | 854 | #endif /* _ASM_PCI_BRIDGE_H */ |
diff --git a/include/asm-mips/pgalloc.h b/include/asm-mips/pgalloc.h index fe1df572318b..582c1fe6cc4a 100644 --- a/include/asm-mips/pgalloc.h +++ b/include/asm-mips/pgalloc.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_PGALLOC_H | 9 | #ifndef _ASM_PGALLOC_H |
10 | #define _ASM_PGALLOC_H | 10 | #define _ASM_PGALLOC_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/highmem.h> | 12 | #include <linux/highmem.h> |
14 | #include <linux/mm.h> | 13 | #include <linux/mm.h> |
15 | 14 | ||
diff --git a/include/asm-mips/pgtable-32.h b/include/asm-mips/pgtable-32.h index 087c20769256..4b26d8528133 100644 --- a/include/asm-mips/pgtable-32.h +++ b/include/asm-mips/pgtable-32.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_PGTABLE_32_H | 9 | #ifndef _ASM_PGTABLE_32_H |
10 | #define _ASM_PGTABLE_32_H | 10 | #define _ASM_PGTABLE_32_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <asm/addrspace.h> | 12 | #include <asm/addrspace.h> |
14 | #include <asm/page.h> | 13 | #include <asm/page.h> |
15 | 14 | ||
diff --git a/include/asm-mips/pgtable-64.h b/include/asm-mips/pgtable-64.h index 2faf5c9ff127..e3db93212eab 100644 --- a/include/asm-mips/pgtable-64.h +++ b/include/asm-mips/pgtable-64.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_PGTABLE_64_H | 9 | #ifndef _ASM_PGTABLE_64_H |
10 | #define _ASM_PGTABLE_64_H | 10 | #define _ASM_PGTABLE_64_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/linkage.h> | 12 | #include <linux/linkage.h> |
14 | 13 | ||
15 | #include <asm/addrspace.h> | 14 | #include <asm/addrspace.h> |
diff --git a/include/asm-mips/pgtable-bits.h b/include/asm-mips/pgtable-bits.h index 01e76e932e3f..7494ba91112a 100644 --- a/include/asm-mips/pgtable-bits.h +++ b/include/asm-mips/pgtable-bits.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASM_PGTABLE_BITS_H | 10 | #ifndef _ASM_PGTABLE_BITS_H |
11 | #define _ASM_PGTABLE_BITS_H | 11 | #define _ASM_PGTABLE_BITS_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | /* | 14 | /* |
16 | * Note that we shift the lower 32bits of each EntryLo[01] entry | 15 | * Note that we shift the lower 32bits of each EntryLo[01] entry |
diff --git a/include/asm-mips/pgtable.h b/include/asm-mips/pgtable.h index d0af2a3b0152..a36ca1be17f2 100644 --- a/include/asm-mips/pgtable.h +++ b/include/asm-mips/pgtable.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef _ASM_PGTABLE_H | 8 | #ifndef _ASM_PGTABLE_H |
9 | #define _ASM_PGTABLE_H | 9 | #define _ASM_PGTABLE_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #ifdef CONFIG_32BIT | 11 | #ifdef CONFIG_32BIT |
13 | #include <asm/pgtable-32.h> | 12 | #include <asm/pgtable-32.h> |
14 | #endif | 13 | #endif |
@@ -379,9 +378,7 @@ static inline void update_mmu_cache(struct vm_area_struct *vma, | |||
379 | __update_cache(vma, address, pte); | 378 | __update_cache(vma, address, pte); |
380 | } | 379 | } |
381 | 380 | ||
382 | #ifndef CONFIG_NEED_MULTIPLE_NODES | ||
383 | #define kern_addr_valid(addr) (1) | 381 | #define kern_addr_valid(addr) (1) |
384 | #endif | ||
385 | 382 | ||
386 | #ifdef CONFIG_64BIT_PHYS_ADDR | 383 | #ifdef CONFIG_64BIT_PHYS_ADDR |
387 | extern int remap_pfn_range(struct vm_area_struct *vma, unsigned long from, unsigned long pfn, unsigned long size, pgprot_t prot); | 384 | extern int remap_pfn_range(struct vm_area_struct *vma, unsigned long from, unsigned long pfn, unsigned long size, pgprot_t prot); |
diff --git a/include/asm-mips/prefetch.h b/include/asm-mips/prefetch.h index 71293ec1657c..17850834ccb0 100644 --- a/include/asm-mips/prefetch.h +++ b/include/asm-mips/prefetch.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef __ASM_PREFETCH_H | 8 | #ifndef __ASM_PREFETCH_H |
9 | #define __ASM_PREFETCH_H | 9 | #define __ASM_PREFETCH_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | 11 | ||
13 | /* | 12 | /* |
14 | * R5000 and RM5200 implements pref and prefx instructions but they're nops, so | 13 | * R5000 and RM5200 implements pref and prefx instructions but they're nops, so |
diff --git a/include/asm-mips/processor.h b/include/asm-mips/processor.h index 0fb75f0762e0..5f80ba71ab92 100644 --- a/include/asm-mips/processor.h +++ b/include/asm-mips/processor.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_PROCESSOR_H | 11 | #ifndef _ASM_PROCESSOR_H |
12 | #define _ASM_PROCESSOR_H | 12 | #define _ASM_PROCESSOR_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/cpumask.h> | 14 | #include <linux/cpumask.h> |
16 | #include <linux/threads.h> | 15 | #include <linux/threads.h> |
17 | 16 | ||
@@ -71,11 +70,6 @@ extern unsigned int vced_count, vcei_count; | |||
71 | 70 | ||
72 | typedef __u64 fpureg_t; | 71 | typedef __u64 fpureg_t; |
73 | 72 | ||
74 | struct mips_fpu_hard_struct { | ||
75 | fpureg_t fpr[NUM_FPU_REGS]; | ||
76 | unsigned int fcr31; | ||
77 | }; | ||
78 | |||
79 | /* | 73 | /* |
80 | * It would be nice to add some more fields for emulator statistics, but there | 74 | * It would be nice to add some more fields for emulator statistics, but there |
81 | * are a number of fixed offsets in offset.h and elsewhere that would have to | 75 | * are a number of fixed offsets in offset.h and elsewhere that would have to |
@@ -83,18 +77,13 @@ struct mips_fpu_hard_struct { | |||
83 | * the FPU emulator for now. See asm-mips/fpu_emulator.h. | 77 | * the FPU emulator for now. See asm-mips/fpu_emulator.h. |
84 | */ | 78 | */ |
85 | 79 | ||
86 | struct mips_fpu_soft_struct { | 80 | struct mips_fpu_struct { |
87 | fpureg_t fpr[NUM_FPU_REGS]; | 81 | fpureg_t fpr[NUM_FPU_REGS]; |
88 | unsigned int fcr31; | 82 | unsigned int fcr31; |
89 | }; | 83 | }; |
90 | 84 | ||
91 | union mips_fpu_union { | ||
92 | struct mips_fpu_hard_struct hard; | ||
93 | struct mips_fpu_soft_struct soft; | ||
94 | }; | ||
95 | |||
96 | #define INIT_FPU { \ | 85 | #define INIT_FPU { \ |
97 | {{0,},} \ | 86 | {0,} \ |
98 | } | 87 | } |
99 | 88 | ||
100 | #define NUM_DSP_REGS 6 | 89 | #define NUM_DSP_REGS 6 |
@@ -133,7 +122,7 @@ struct thread_struct { | |||
133 | unsigned long cp0_status; | 122 | unsigned long cp0_status; |
134 | 123 | ||
135 | /* Saved fpu/fpu emulator stuff. */ | 124 | /* Saved fpu/fpu emulator stuff. */ |
136 | union mips_fpu_union fpu; | 125 | struct mips_fpu_struct fpu; |
137 | #ifdef CONFIG_MIPS_MT_FPAFF | 126 | #ifdef CONFIG_MIPS_MT_FPAFF |
138 | /* Emulated instruction count */ | 127 | /* Emulated instruction count */ |
139 | unsigned long emulated_fp; | 128 | unsigned long emulated_fp; |
diff --git a/include/asm-mips/ptrace.h b/include/asm-mips/ptrace.h index fa9d8713c12a..4113316ee0da 100644 --- a/include/asm-mips/ptrace.h +++ b/include/asm-mips/ptrace.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_PTRACE_H | 9 | #ifndef _ASM_PTRACE_H |
10 | #define _ASM_PTRACE_H | 10 | #define _ASM_PTRACE_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | #include <asm/isadep.h> | 13 | #include <asm/isadep.h> |
15 | 14 | ||
diff --git a/include/asm-mips/qemu.h b/include/asm-mips/qemu.h index 905c39585903..531caf44560c 100644 --- a/include/asm-mips/qemu.h +++ b/include/asm-mips/qemu.h | |||
@@ -21,4 +21,10 @@ | |||
21 | */ | 21 | */ |
22 | #define QEMU_C0_COUNTER_CLOCK 100000000 | 22 | #define QEMU_C0_COUNTER_CLOCK 100000000 |
23 | 23 | ||
24 | /* | ||
25 | * Magic qemu system control location. | ||
26 | */ | ||
27 | #define QEMU_RESTART_REG 0xBFBF0000 | ||
28 | #define QEMU_HALT_REG 0xBFBF0004 | ||
29 | |||
24 | #endif /* __ASM_QEMU_H */ | 30 | #endif /* __ASM_QEMU_H */ |
diff --git a/include/asm-mips/reg.h b/include/asm-mips/reg.h index 6173004cc88e..634b55d7e7f6 100644 --- a/include/asm-mips/reg.h +++ b/include/asm-mips/reg.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef __ASM_MIPS_REG_H | 12 | #ifndef __ASM_MIPS_REG_H |
13 | #define __ASM_MIPS_REG_H | 13 | #define __ASM_MIPS_REG_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | #if defined(CONFIG_32BIT) || defined(WANT_COMPAT_REG_H) | 16 | #if defined(CONFIG_32BIT) || defined(WANT_COMPAT_REG_H) |
18 | 17 | ||
diff --git a/include/asm-mips/resource.h b/include/asm-mips/resource.h index 1fba00c22077..87cb3085269c 100644 --- a/include/asm-mips/resource.h +++ b/include/asm-mips/resource.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_RESOURCE_H | 9 | #ifndef _ASM_RESOURCE_H |
10 | #define _ASM_RESOURCE_H | 10 | #define _ASM_RESOURCE_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | /* | 13 | /* |
15 | * These five resource limit IDs have a MIPS/Linux-specific ordering, | 14 | * These five resource limit IDs have a MIPS/Linux-specific ordering, |
diff --git a/include/asm-mips/rm9k-ocd.h b/include/asm-mips/rm9k-ocd.h new file mode 100644 index 000000000000..b0b80d9ecf96 --- /dev/null +++ b/include/asm-mips/rm9k-ocd.h | |||
@@ -0,0 +1,56 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2004 by Basler Vision Technologies AG | ||
3 | * Author: Thomas Koeller <thomas.koeller@baslerweb.com> | ||
4 | * | ||
5 | * This program is free software; you can redistribute it and/or modify | ||
6 | * it under the terms of the GNU General Public License as published by | ||
7 | * the Free Software Foundation; either version 2 of the License, or | ||
8 | * (at your option) any later version. | ||
9 | * | ||
10 | * This program is distributed in the hope that it will be useful, | ||
11 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
13 | * GNU General Public License for more details. | ||
14 | * | ||
15 | * You should have received a copy of the GNU General Public License | ||
16 | * along with this program; if not, write to the Free Software | ||
17 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
18 | */ | ||
19 | |||
20 | #if !defined(_ASM_RM9K_OCD_H) | ||
21 | #define _ASM_RM9K_OCD_H | ||
22 | |||
23 | #include <linux/types.h> | ||
24 | #include <linux/spinlock.h> | ||
25 | #include <asm/io.h> | ||
26 | |||
27 | extern volatile void __iomem * const ocd_base; | ||
28 | extern volatile void __iomem * const titan_base; | ||
29 | |||
30 | #define ocd_addr(__x__) (ocd_base + (__x__)) | ||
31 | #define titan_addr(__x__) (titan_base + (__x__)) | ||
32 | #define scram_addr(__x__) (scram_base + (__x__)) | ||
33 | |||
34 | /* OCD register access */ | ||
35 | #define ocd_readl(__offs__) __raw_readl(ocd_addr(__offs__)) | ||
36 | #define ocd_readw(__offs__) __raw_readw(ocd_addr(__offs__)) | ||
37 | #define ocd_readb(__offs__) __raw_readb(ocd_addr(__offs__)) | ||
38 | #define ocd_writel(__val__, __offs__) \ | ||
39 | __raw_writel((__val__), ocd_addr(__offs__)) | ||
40 | #define ocd_writew(__val__, __offs__) \ | ||
41 | __raw_writew((__val__), ocd_addr(__offs__)) | ||
42 | #define ocd_writeb(__val__, __offs__) \ | ||
43 | __raw_writeb((__val__), ocd_addr(__offs__)) | ||
44 | |||
45 | /* TITAN register access - 32 bit-wide only */ | ||
46 | #define titan_readl(__offs__) __raw_readl(titan_addr(__offs__)) | ||
47 | #define titan_writel(__val__, __offs__) \ | ||
48 | __raw_writel((__val__), titan_addr(__offs__)) | ||
49 | |||
50 | /* Protect access to shared TITAN registers */ | ||
51 | extern spinlock_t titan_lock; | ||
52 | extern int titan_irqflags; | ||
53 | #define lock_titan_regs() spin_lock_irqsave(&titan_lock, titan_irqflags) | ||
54 | #define unlock_titan_regs() spin_unlock_irqrestore(&titan_lock, titan_irqflags) | ||
55 | |||
56 | #endif /* !defined(_ASM_RM9K_OCD_H) */ | ||
diff --git a/include/asm-mips/serial.h b/include/asm-mips/serial.h index 7196ceb0e948..584bd9c0ab2e 100644 --- a/include/asm-mips/serial.h +++ b/include/asm-mips/serial.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_SERIAL_H | 9 | #ifndef _ASM_SERIAL_H |
10 | #define _ASM_SERIAL_H | 10 | #define _ASM_SERIAL_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | /* | 13 | /* |
15 | * This assumes you have a 1.8432 MHz clock for your UART. | 14 | * This assumes you have a 1.8432 MHz clock for your UART. |
diff --git a/include/asm-mips/sgiarcs.h b/include/asm-mips/sgiarcs.h index 722b77a8c5e5..ddb859d05257 100644 --- a/include/asm-mips/sgiarcs.h +++ b/include/asm-mips/sgiarcs.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef _ASM_SGIARCS_H | 12 | #ifndef _ASM_SGIARCS_H |
13 | #define _ASM_SGIARCS_H | 13 | #define _ASM_SGIARCS_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <asm/types.h> | 15 | #include <asm/types.h> |
17 | #include <asm/arc/types.h> | 16 | #include <asm/arc/types.h> |
18 | 17 | ||
diff --git a/include/asm-mips/sibyte/board.h b/include/asm-mips/sibyte/board.h index 900edcbeec37..3dfe29ed42a8 100644 --- a/include/asm-mips/sibyte/board.h +++ b/include/asm-mips/sibyte/board.h | |||
@@ -19,7 +19,6 @@ | |||
19 | #ifndef _SIBYTE_BOARD_H | 19 | #ifndef _SIBYTE_BOARD_H |
20 | #define _SIBYTE_BOARD_H | 20 | #define _SIBYTE_BOARD_H |
21 | 21 | ||
22 | #include <linux/config.h> | ||
23 | 22 | ||
24 | #if defined(CONFIG_SIBYTE_SWARM) || defined(CONFIG_SIBYTE_PTSWARM) || \ | 23 | #if defined(CONFIG_SIBYTE_SWARM) || defined(CONFIG_SIBYTE_PTSWARM) || \ |
25 | defined(CONFIG_SIBYTE_CRHONE) || defined(CONFIG_SIBYTE_CRHINE) || \ | 24 | defined(CONFIG_SIBYTE_CRHONE) || defined(CONFIG_SIBYTE_CRHINE) || \ |
diff --git a/include/asm-mips/sibyte/carmel.h b/include/asm-mips/sibyte/carmel.h index b5e7dae19f0f..57c53e62a37a 100644 --- a/include/asm-mips/sibyte/carmel.h +++ b/include/asm-mips/sibyte/carmel.h | |||
@@ -18,7 +18,6 @@ | |||
18 | #ifndef __ASM_SIBYTE_CARMEL_H | 18 | #ifndef __ASM_SIBYTE_CARMEL_H |
19 | #define __ASM_SIBYTE_CARMEL_H | 19 | #define __ASM_SIBYTE_CARMEL_H |
20 | 20 | ||
21 | #include <linux/config.h> | ||
22 | 21 | ||
23 | #include <asm/sibyte/sb1250.h> | 22 | #include <asm/sibyte/sb1250.h> |
24 | #include <asm/sibyte/sb1250_int.h> | 23 | #include <asm/sibyte/sb1250_int.h> |
diff --git a/include/asm-mips/sibyte/sentosa.h b/include/asm-mips/sibyte/sentosa.h index 824605847af4..64c47874f32d 100644 --- a/include/asm-mips/sibyte/sentosa.h +++ b/include/asm-mips/sibyte/sentosa.h | |||
@@ -18,7 +18,6 @@ | |||
18 | #ifndef __ASM_SIBYTE_SENTOSA_H | 18 | #ifndef __ASM_SIBYTE_SENTOSA_H |
19 | #define __ASM_SIBYTE_SENTOSA_H | 19 | #define __ASM_SIBYTE_SENTOSA_H |
20 | 20 | ||
21 | #include <linux/config.h> | ||
22 | #include <asm/sibyte/sb1250.h> | 21 | #include <asm/sibyte/sb1250.h> |
23 | #include <asm/sibyte/sb1250_int.h> | 22 | #include <asm/sibyte/sb1250_int.h> |
24 | 23 | ||
diff --git a/include/asm-mips/sibyte/swarm.h b/include/asm-mips/sibyte/swarm.h index 06e1d528e03a..86db37e5ad85 100644 --- a/include/asm-mips/sibyte/swarm.h +++ b/include/asm-mips/sibyte/swarm.h | |||
@@ -18,7 +18,6 @@ | |||
18 | #ifndef __ASM_SIBYTE_SWARM_H | 18 | #ifndef __ASM_SIBYTE_SWARM_H |
19 | #define __ASM_SIBYTE_SWARM_H | 19 | #define __ASM_SIBYTE_SWARM_H |
20 | 20 | ||
21 | #include <linux/config.h> | ||
22 | #include <asm/sibyte/sb1250.h> | 21 | #include <asm/sibyte/sb1250.h> |
23 | #include <asm/sibyte/sb1250_int.h> | 22 | #include <asm/sibyte/sb1250_int.h> |
24 | 23 | ||
diff --git a/include/asm-mips/siginfo.h b/include/asm-mips/siginfo.h index 2ba313d94a78..2e32949bd674 100644 --- a/include/asm-mips/siginfo.h +++ b/include/asm-mips/siginfo.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_SIGINFO_H | 9 | #ifndef _ASM_SIGINFO_H |
10 | #define _ASM_SIGINFO_H | 10 | #define _ASM_SIGINFO_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | #define __ARCH_SIGEV_PREAMBLE_SIZE (sizeof(long) + 2*sizeof(int)) | 13 | #define __ARCH_SIGEV_PREAMBLE_SIZE (sizeof(long) + 2*sizeof(int)) |
15 | #undef __ARCH_SI_TRAPNO /* exception code needs to fill this ... */ | 14 | #undef __ARCH_SI_TRAPNO /* exception code needs to fill this ... */ |
diff --git a/include/asm-mips/signal.h b/include/asm-mips/signal.h index d8349e4b55ee..a1f3a3fa9bd6 100644 --- a/include/asm-mips/signal.h +++ b/include/asm-mips/signal.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_SIGNAL_H | 9 | #ifndef _ASM_SIGNAL_H |
10 | #define _ASM_SIGNAL_H | 10 | #define _ASM_SIGNAL_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/types.h> | 12 | #include <linux/types.h> |
14 | 13 | ||
15 | #define _NSIG 128 | 14 | #define _NSIG 128 |
diff --git a/include/asm-mips/sim.h b/include/asm-mips/sim.h index 9c2af1b00e19..67c4fe52bb42 100644 --- a/include/asm-mips/sim.h +++ b/include/asm-mips/sim.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_SIM_H | 9 | #ifndef _ASM_SIM_H |
10 | #define _ASM_SIM_H | 10 | #define _ASM_SIM_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | #include <asm/asm-offsets.h> | 13 | #include <asm/asm-offsets.h> |
15 | 14 | ||
diff --git a/include/asm-mips/smp.h b/include/asm-mips/smp.h index e14e4b69de21..1608fd71d6f7 100644 --- a/include/asm-mips/smp.h +++ b/include/asm-mips/smp.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef __ASM_SMP_H | 11 | #ifndef __ASM_SMP_H |
12 | #define __ASM_SMP_H | 12 | #define __ASM_SMP_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | #ifdef CONFIG_SMP | 15 | #ifdef CONFIG_SMP |
17 | 16 | ||
diff --git a/include/asm-mips/sn/addrs.h b/include/asm-mips/sn/addrs.h index 2b5cef1ba37f..8fa0af6b68d2 100644 --- a/include/asm-mips/sn/addrs.h +++ b/include/asm-mips/sn/addrs.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_SN_ADDRS_H | 9 | #ifndef _ASM_SN_ADDRS_H |
10 | #define _ASM_SN_ADDRS_H | 10 | #define _ASM_SN_ADDRS_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | #ifndef __ASSEMBLY__ | 13 | #ifndef __ASSEMBLY__ |
15 | #include <linux/types.h> | 14 | #include <linux/types.h> |
@@ -27,13 +26,8 @@ | |||
27 | 26 | ||
28 | #ifndef __ASSEMBLY__ | 27 | #ifndef __ASSEMBLY__ |
29 | 28 | ||
30 | #if defined(CONFIG_SGI_IO) /* FIXME */ | ||
31 | #define PS_UINT_CAST (__psunsigned_t) | ||
32 | #define UINT64_CAST (__uint64_t) | ||
33 | #else /* CONFIG_SGI_IO */ | ||
34 | #define PS_UINT_CAST (unsigned long) | 29 | #define PS_UINT_CAST (unsigned long) |
35 | #define UINT64_CAST (unsigned long) | 30 | #define UINT64_CAST (unsigned long) |
36 | #endif /* CONFIG_SGI_IO */ | ||
37 | 31 | ||
38 | #define HUBREG_CAST (volatile hubreg_t *) | 32 | #define HUBREG_CAST (volatile hubreg_t *) |
39 | 33 | ||
@@ -253,14 +247,6 @@ | |||
253 | * for _x. | 247 | * for _x. |
254 | */ | 248 | */ |
255 | 249 | ||
256 | #ifdef _STANDALONE | ||
257 | |||
258 | /* DO NOT USE THESE DIRECTLY IN THE KERNEL. SEE BELOW. */ | ||
259 | #define LOCAL_HUB(_x) (HUBREG_CAST (IALIAS_BASE + (_x))) | ||
260 | #define REMOTE_HUB(_n, _x) (HUBREG_CAST (NODE_SWIN_BASE(_n, 1) + \ | ||
261 | 0x800000 + (_x))) | ||
262 | #endif /* _STANDALONE */ | ||
263 | |||
264 | /* | 250 | /* |
265 | * WARNING: | 251 | * WARNING: |
266 | * When certain Hub chip workaround are defined, it's not sufficient | 252 | * When certain Hub chip workaround are defined, it's not sufficient |
@@ -327,20 +313,6 @@ | |||
327 | PHYS_TO_K0(NODE_OFFSET(nasid) | ARCS_SPB_OFFSET) | 313 | PHYS_TO_K0(NODE_OFFSET(nasid) | ARCS_SPB_OFFSET) |
328 | #define ARCS_SPB_SIZE 0x0400 | 314 | #define ARCS_SPB_SIZE 0x0400 |
329 | 315 | ||
330 | #ifdef _STANDALONE | ||
331 | |||
332 | #define ARCS_TVECTOR_OFFSET 0x2800 | ||
333 | #define ARCS_PVECTOR_OFFSET 0x2c00 | ||
334 | |||
335 | /* | ||
336 | * These addresses are used by the master CPU to install the transfer | ||
337 | * and private vectors. All others use the SPB to find them. | ||
338 | */ | ||
339 | #define TVADDR (NODE_CAC_BASE(get_nasid()) + ARCS_TVECTOR_OFFSET) | ||
340 | #define PVADDR (NODE_CAC_BASE(get_nasid()) + ARCS_PVECTOR_OFFSET) | ||
341 | |||
342 | #endif /* _STANDALONE */ | ||
343 | |||
344 | #define KLDIR_OFFSET 0x2000 | 316 | #define KLDIR_OFFSET 0x2000 |
345 | #define KLDIR_ADDR(nasid) \ | 317 | #define KLDIR_ADDR(nasid) \ |
346 | TO_NODE_UNCAC((nasid), KLDIR_OFFSET) | 318 | TO_NODE_UNCAC((nasid), KLDIR_OFFSET) |
diff --git a/include/asm-mips/sn/agent.h b/include/asm-mips/sn/agent.h index d6df13aaed49..ac4ea85c3a5c 100644 --- a/include/asm-mips/sn/agent.h +++ b/include/asm-mips/sn/agent.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_SGI_SN_AGENT_H | 11 | #ifndef _ASM_SGI_SN_AGENT_H |
12 | #define _ASM_SGI_SN_AGENT_H | 12 | #define _ASM_SGI_SN_AGENT_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/topology.h> | 14 | #include <linux/topology.h> |
16 | #include <asm/sn/addrs.h> | 15 | #include <asm/sn/addrs.h> |
17 | #include <asm/sn/arch.h> | 16 | #include <asm/sn/arch.h> |
diff --git a/include/asm-mips/sn/arch.h b/include/asm-mips/sn/arch.h index d247a819de7f..51174af6ac52 100644 --- a/include/asm-mips/sn/arch.h +++ b/include/asm-mips/sn/arch.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_SN_ARCH_H | 11 | #ifndef _ASM_SN_ARCH_H |
12 | #define _ASM_SN_ARCH_H | 12 | #define _ASM_SN_ARCH_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/types.h> | 14 | #include <linux/types.h> |
16 | #include <asm/sn/types.h> | 15 | #include <asm/sn/types.h> |
17 | #ifdef CONFIG_SGI_IP27 | 16 | #ifdef CONFIG_SGI_IP27 |
diff --git a/include/asm-mips/sn/sn0/sn0_fru.h b/include/asm-mips/sn/fru.h index 82c6377c275a..b3e3606723b7 100644 --- a/include/asm-mips/sn/sn0/sn0_fru.h +++ b/include/asm-mips/sn/fru.h | |||
@@ -6,10 +6,10 @@ | |||
6 | * Derived from IRIX <sys/SN/SN0/sn0_fru.h> | 6 | * Derived from IRIX <sys/SN/SN0/sn0_fru.h> |
7 | * | 7 | * |
8 | * Copyright (C) 1992 - 1997, 1999 Silcon Graphics, Inc. | 8 | * Copyright (C) 1992 - 1997, 1999 Silcon Graphics, Inc. |
9 | * Copyright (C) 1999 Ralf Baechle (ralf@gnu.org) | 9 | * Copyright (C) 1999, 2006 Ralf Baechle (ralf@linux-mips) |
10 | */ | 10 | */ |
11 | #ifndef _ASM_SN_SN0_SN0_FRU_H | 11 | #ifndef __ASM_SN_FRU_H |
12 | #define _ASM_SN_SN0_SN0_FRU_H | 12 | #define __ASM_SN_FRU_H |
13 | 13 | ||
14 | #define MAX_DIMMS 8 /* max # of dimm banks */ | 14 | #define MAX_DIMMS 8 /* max # of dimm banks */ |
15 | #define MAX_PCIDEV 8 /* max # of pci devices on a pci bus */ | 15 | #define MAX_PCIDEV 8 /* max # of pci devices on a pci bus */ |
@@ -41,4 +41,4 @@ typedef struct kf_pci_bus_s { | |||
41 | /* confidence level that the pci dev is bad */ | 41 | /* confidence level that the pci dev is bad */ |
42 | } kf_pci_bus_t; | 42 | } kf_pci_bus_t; |
43 | 43 | ||
44 | #endif /* _ASM_SN_SN0_SN0_FRU_H */ | 44 | #endif /* __ASM_SN_FRU_H */ |
diff --git a/include/asm-mips/sn/io.h b/include/asm-mips/sn/io.h index 13326453efc9..ab2fa8cd2627 100644 --- a/include/asm-mips/sn/io.h +++ b/include/asm-mips/sn/io.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_SN_IO_H | 9 | #ifndef _ASM_SN_IO_H |
10 | #define _ASM_SN_IO_H | 10 | #define _ASM_SN_IO_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #if defined (CONFIG_SGI_IP27) | 12 | #if defined (CONFIG_SGI_IP27) |
14 | #include <asm/sn/sn0/hubio.h> | 13 | #include <asm/sn/sn0/hubio.h> |
15 | #endif | 14 | #endif |
diff --git a/include/asm-mips/sn/klconfig.h b/include/asm-mips/sn/klconfig.h index 9709ff701d9b..52238e65af8e 100644 --- a/include/asm-mips/sn/klconfig.h +++ b/include/asm-mips/sn/klconfig.h | |||
@@ -27,7 +27,6 @@ | |||
27 | * that offsets of existing fields do not change. | 27 | * that offsets of existing fields do not change. |
28 | */ | 28 | */ |
29 | 29 | ||
30 | #include <linux/config.h> | ||
31 | #include <linux/types.h> | 30 | #include <linux/types.h> |
32 | #include <asm/sn/types.h> | 31 | #include <asm/sn/types.h> |
33 | 32 | ||
@@ -37,7 +36,7 @@ | |||
37 | //#include <sys/SN/router.h> | 36 | //#include <sys/SN/router.h> |
38 | // XXX Stolen from <sys/SN/router.h>: | 37 | // XXX Stolen from <sys/SN/router.h>: |
39 | #define MAX_ROUTER_PORTS (6) /* Max. number of ports on a router */ | 38 | #define MAX_ROUTER_PORTS (6) /* Max. number of ports on a router */ |
40 | #include <asm/sn/sn0/sn0_fru.h> | 39 | #include <asm/sn/fru.h> |
41 | //#include <sys/graph.h> | 40 | //#include <sys/graph.h> |
42 | //#include <sys/xtalk/xbow.h> | 41 | //#include <sys/xtalk/xbow.h> |
43 | 42 | ||
@@ -54,32 +53,21 @@ | |||
54 | #include <asm/sn/agent.h> | 53 | #include <asm/sn/agent.h> |
55 | #include <asm/arc/types.h> | 54 | #include <asm/arc/types.h> |
56 | #include <asm/arc/hinv.h> | 55 | #include <asm/arc/hinv.h> |
57 | #if defined(CONFIG_SGI_IO) || defined(CONFIG_SGI_IP35) | 56 | #if defined(CONFIG_SGI_IP35) |
58 | // The hack file has to be before vector and after sn0_fru.... | 57 | // The hack file has to be before vector and after sn0_fru.... |
59 | #include <asm/hack.h> | 58 | #include <asm/hack.h> |
60 | #include <asm/sn/vector.h> | 59 | #include <asm/sn/vector.h> |
61 | #include <asm/xtalk/xtalk.h> | 60 | #include <asm/xtalk/xtalk.h> |
62 | #endif /* CONFIG_SGI_IO || CONFIG_SGI_IP35 */ | 61 | #endif /* CONFIG_SGI_IP35 */ |
63 | #endif /* CONFIG_SGI_IP27 || CONFIG_SGI_IP35 */ | 62 | #endif /* CONFIG_SGI_IP27 || CONFIG_SGI_IP35 */ |
64 | 63 | ||
65 | #define KLCFGINFO_MAGIC 0xbeedbabe | 64 | #define KLCFGINFO_MAGIC 0xbeedbabe |
66 | 65 | ||
67 | #ifdef FRUTEST | ||
68 | typedef u64 klconf_off_t; | ||
69 | #else | ||
70 | typedef s32 klconf_off_t; | 66 | typedef s32 klconf_off_t; |
71 | #endif | ||
72 | 67 | ||
73 | /* | 68 | /* |
74 | * Some IMPORTANT OFFSETS. These are the offsets on all NODES. | 69 | * Some IMPORTANT OFFSETS. These are the offsets on all NODES. |
75 | */ | 70 | */ |
76 | #if 0 | ||
77 | #define RAMBASE 0 | ||
78 | #define ARCSSPB_OFF 0x1000 /* shift it to sys/arcs/spb.h */ | ||
79 | |||
80 | #define OFF_HWGRAPH 0 | ||
81 | #endif | ||
82 | |||
83 | #define MAX_MODULE_ID 255 | 71 | #define MAX_MODULE_ID 255 |
84 | #define SIZE_PAD 4096 /* 4k padding for structures */ | 72 | #define SIZE_PAD 4096 /* 4k padding for structures */ |
85 | /* | 73 | /* |
@@ -134,15 +122,9 @@ typedef s32 klconf_off_t; | |||
134 | 122 | ||
135 | 123 | ||
136 | typedef struct console_s { | 124 | typedef struct console_s { |
137 | #if defined(CONFIG_SGI_IO) /* FIXME */ | ||
138 | __psunsigned_t uart_base; | ||
139 | __psunsigned_t config_base; | ||
140 | __psunsigned_t memory_base; | ||
141 | #else | ||
142 | unsigned long uart_base; | 125 | unsigned long uart_base; |
143 | unsigned long config_base; | 126 | unsigned long config_base; |
144 | unsigned long memory_base; | 127 | unsigned long memory_base; |
145 | #endif | ||
146 | short baud; | 128 | short baud; |
147 | short flag; | 129 | short flag; |
148 | int type; | 130 | int type; |
@@ -174,10 +156,6 @@ typedef struct kl_config_hdr { | |||
174 | 156 | ||
175 | 157 | ||
176 | #define KL_CONFIG_HDR(_nasid) ((kl_config_hdr_t *)(KLCONFIG_ADDR(_nasid))) | 158 | #define KL_CONFIG_HDR(_nasid) ((kl_config_hdr_t *)(KLCONFIG_ADDR(_nasid))) |
177 | #if 0 | ||
178 | #define KL_CONFIG_MALLOC_HDR(_nasid) \ | ||
179 | (KL_CONFIG_HDR(_nasid)->ch_malloc_hdr) | ||
180 | #endif | ||
181 | #define KL_CONFIG_INFO_OFFSET(_nasid) \ | 159 | #define KL_CONFIG_INFO_OFFSET(_nasid) \ |
182 | (KL_CONFIG_HDR(_nasid)->ch_board_info) | 160 | (KL_CONFIG_HDR(_nasid)->ch_board_info) |
183 | #define KL_CONFIG_INFO_SET_OFFSET(_nasid, _off) \ | 161 | #define KL_CONFIG_INFO_SET_OFFSET(_nasid, _off) \ |
@@ -197,23 +175,13 @@ typedef struct kl_config_hdr { | |||
197 | 175 | ||
198 | /* --- New Macros for the changed kl_config_hdr_t structure --- */ | 176 | /* --- New Macros for the changed kl_config_hdr_t structure --- */ |
199 | 177 | ||
200 | #if defined(CONFIG_SGI_IO) | ||
201 | #define PTR_CH_MALLOC_HDR(_k) ((klc_malloc_hdr_t *)\ | ||
202 | ((__psunsigned_t)_k + (_k->ch_malloc_hdr_off))) | ||
203 | #else | ||
204 | #define PTR_CH_MALLOC_HDR(_k) ((klc_malloc_hdr_t *)\ | 178 | #define PTR_CH_MALLOC_HDR(_k) ((klc_malloc_hdr_t *)\ |
205 | (unsigned long)_k + (_k->ch_malloc_hdr_off))) | 179 | (unsigned long)_k + (_k->ch_malloc_hdr_off))) |
206 | #endif | ||
207 | 180 | ||
208 | #define KL_CONFIG_CH_MALLOC_HDR(_n) PTR_CH_MALLOC_HDR(KL_CONFIG_HDR(_n)) | 181 | #define KL_CONFIG_CH_MALLOC_HDR(_n) PTR_CH_MALLOC_HDR(KL_CONFIG_HDR(_n)) |
209 | 182 | ||
210 | #if defined(CONFIG_SGI_IO) | ||
211 | #define PTR_CH_CONS_INFO(_k) ((console_t *)\ | ||
212 | ((__psunsigned_t)_k + (_k->ch_cons_off))) | ||
213 | #else | ||
214 | #define PTR_CH_CONS_INFO(_k) ((console_t *)\ | 183 | #define PTR_CH_CONS_INFO(_k) ((console_t *)\ |
215 | ((unsigned long)_k + (_k->ch_cons_off))) | 184 | ((unsigned long)_k + (_k->ch_cons_off))) |
216 | #endif | ||
217 | 185 | ||
218 | #define KL_CONFIG_CH_CONS_INFO(_n) PTR_CH_CONS_INFO(KL_CONFIG_HDR(_n)) | 186 | #define KL_CONFIG_CH_CONS_INFO(_n) PTR_CH_CONS_INFO(KL_CONFIG_HDR(_n)) |
219 | 187 | ||
@@ -490,14 +458,6 @@ typedef struct lboard_s { | |||
490 | #define KLCF_NUM_COMPS(_brd) ((_brd)->brd_numcompts) | 458 | #define KLCF_NUM_COMPS(_brd) ((_brd)->brd_numcompts) |
491 | #define KLCF_MODULE_ID(_brd) ((_brd)->brd_module) | 459 | #define KLCF_MODULE_ID(_brd) ((_brd)->brd_module) |
492 | 460 | ||
493 | #ifdef FRUTEST | ||
494 | |||
495 | #define KLCF_NEXT(_brd) ((_brd)->brd_next ? (lboard_t *)((_brd)->brd_next): NULL) | ||
496 | #define KLCF_COMP(_brd, _ndx) (klinfo_t *)((_brd)->brd_compts[(_ndx)]) | ||
497 | #define KLCF_COMP_ERROR(_brd, _comp) (_brd = _brd , (_comp)->errinfo) | ||
498 | |||
499 | #else | ||
500 | |||
501 | #define KLCF_NEXT(_brd) \ | 461 | #define KLCF_NEXT(_brd) \ |
502 | ((_brd)->brd_next ? \ | 462 | ((_brd)->brd_next ? \ |
503 | (lboard_t *)(NODE_OFFSET_TO_K1(NASID_GET(_brd), (_brd)->brd_next)):\ | 463 | (lboard_t *)(NODE_OFFSET_TO_K1(NASID_GET(_brd), (_brd)->brd_next)):\ |
@@ -509,8 +469,6 @@ typedef struct lboard_s { | |||
509 | #define KLCF_COMP_ERROR(_brd, _comp) \ | 469 | #define KLCF_COMP_ERROR(_brd, _comp) \ |
510 | (NODE_OFFSET_TO_K1(NASID_GET(_brd), (_comp)->errinfo)) | 470 | (NODE_OFFSET_TO_K1(NASID_GET(_brd), (_comp)->errinfo)) |
511 | 471 | ||
512 | #endif | ||
513 | |||
514 | #define KLCF_COMP_TYPE(_comp) ((_comp)->struct_type) | 472 | #define KLCF_COMP_TYPE(_comp) ((_comp)->struct_type) |
515 | #define KLCF_BRIDGE_W_ID(_comp) ((_comp)->physid) /* Widget ID */ | 473 | #define KLCF_BRIDGE_W_ID(_comp) ((_comp)->physid) /* Widget ID */ |
516 | 474 | ||
@@ -631,18 +589,6 @@ typedef struct klport_s { | |||
631 | klconf_off_t port_offset; | 589 | klconf_off_t port_offset; |
632 | } klport_t; | 590 | } klport_t; |
633 | 591 | ||
634 | #if 0 | ||
635 | /* | ||
636 | * This is very similar to the klport_s but instead of having a componant | ||
637 | * offset it has a board offset. | ||
638 | */ | ||
639 | typedef struct klxbow_port_s { | ||
640 | nasid_t port_nasid; | ||
641 | unsigned char port_flag; | ||
642 | klconf_off_t board_offset; | ||
643 | } klxbow_port_t; | ||
644 | #endif | ||
645 | |||
646 | typedef struct klcpu_s { /* CPU */ | 592 | typedef struct klcpu_s { /* CPU */ |
647 | klinfo_t cpu_info; | 593 | klinfo_t cpu_info; |
648 | unsigned short cpu_prid; /* Processor PRID value */ | 594 | unsigned short cpu_prid; /* Processor PRID value */ |
@@ -945,36 +891,6 @@ extern klcpu_t *nasid_slice_to_cpuinfo(nasid_t, int); | |||
945 | extern lboard_t *find_lboard_class(lboard_t *start, unsigned char brd_class); | 891 | extern lboard_t *find_lboard_class(lboard_t *start, unsigned char brd_class); |
946 | 892 | ||
947 | 893 | ||
948 | #if defined(CONFIG_SGI_IO) | ||
949 | extern xwidgetnum_t nodevertex_widgetnum_get(vertex_hdl_t node_vtx); | ||
950 | extern vertex_hdl_t nodevertex_xbow_peer_get(vertex_hdl_t node_vtx); | ||
951 | extern lboard_t *find_gfxpipe(int pipenum); | ||
952 | extern void setup_gfxpipe_link(vertex_hdl_t vhdl,int pipenum); | ||
953 | extern lboard_t *find_lboard_module_class(lboard_t *start, moduleid_t mod, | ||
954 | unsigned char brd_class); | ||
955 | extern lboard_t *find_nic_lboard(lboard_t *, nic_t); | ||
956 | extern lboard_t *find_nic_type_lboard(nasid_t, unsigned char, nic_t); | ||
957 | extern lboard_t *find_lboard_modslot(lboard_t *start, moduleid_t mod, slotid_t slot); | ||
958 | extern lboard_t *find_lboard_module(lboard_t *start, moduleid_t mod); | ||
959 | extern lboard_t *get_board_name(nasid_t nasid, moduleid_t mod, slotid_t slot, char *name); | ||
960 | extern int config_find_nic_router(nasid_t, nic_t, lboard_t **, klrou_t**); | ||
961 | extern int config_find_nic_hub(nasid_t, nic_t, lboard_t **, klhub_t**); | ||
962 | extern int config_find_xbow(nasid_t, lboard_t **, klxbow_t**); | ||
963 | extern klcpu_t *get_cpuinfo(cpuid_t cpu); | ||
964 | extern int update_klcfg_cpuinfo(nasid_t, int); | ||
965 | extern void board_to_path(lboard_t *brd, char *path); | ||
966 | extern moduleid_t get_module_id(nasid_t nasid); | ||
967 | extern void nic_name_convert(char *old_name, char *new_name); | ||
968 | extern int module_brds(nasid_t nasid, lboard_t **module_brds, int n); | ||
969 | extern lboard_t *brd_from_key(ulong_t key); | ||
970 | extern void device_component_canonical_name_get(lboard_t *,klinfo_t *, | ||
971 | char *); | ||
972 | extern int board_serial_number_get(lboard_t *,char *); | ||
973 | extern int is_master_baseio(nasid_t,moduleid_t,slotid_t); | ||
974 | extern nasid_t get_actual_nasid(lboard_t *brd) ; | ||
975 | extern net_vec_t klcfg_discover_route(lboard_t *, lboard_t *, int); | ||
976 | #else /* CONFIG_SGI_IO */ | ||
977 | extern klcpu_t *sn_get_cpuinfo(cpuid_t cpu); | 894 | extern klcpu_t *sn_get_cpuinfo(cpuid_t cpu); |
978 | #endif /* CONFIG_SGI_IO */ | ||
979 | 895 | ||
980 | #endif /* _ASM_SN_KLCONFIG_H */ | 896 | #endif /* _ASM_SN_KLCONFIG_H */ |
diff --git a/include/asm-mips/sn/kldir.h b/include/asm-mips/sn/kldir.h index f0efab1672ec..0573cbffc104 100644 --- a/include/asm-mips/sn/kldir.h +++ b/include/asm-mips/sn/kldir.h | |||
@@ -11,11 +11,6 @@ | |||
11 | #ifndef _ASM_SN_KLDIR_H | 11 | #ifndef _ASM_SN_KLDIR_H |
12 | #define _ASM_SN_KLDIR_H | 12 | #define _ASM_SN_KLDIR_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | |||
16 | #if defined(CONFIG_SGI_IO) | ||
17 | #include <asm/hack.h> | ||
18 | #endif | ||
19 | 14 | ||
20 | /* | 15 | /* |
21 | * The kldir memory area resides at a fixed place in each node's memory and | 16 | * The kldir memory area resides at a fixed place in each node's memory and |
@@ -136,8 +131,6 @@ | |||
136 | #define KLDIR_OFF_STRIDE 0x28 | 131 | #define KLDIR_OFF_STRIDE 0x28 |
137 | #endif /* __ASSEMBLY__ */ | 132 | #endif /* __ASSEMBLY__ */ |
138 | 133 | ||
139 | #if !defined(CONFIG_SGI_IO) | ||
140 | |||
141 | /* | 134 | /* |
142 | * This is defined here because IP27_SYMMON_STK_SIZE must be at least what | 135 | * This is defined here because IP27_SYMMON_STK_SIZE must be at least what |
143 | * we define here. Since it's set up in the prom. We can't redefine it later | 136 | * we define here. Since it's set up in the prom. We can't redefine it later |
@@ -147,7 +140,7 @@ | |||
147 | */ | 140 | */ |
148 | #define SYMMON_STACK_SIZE 0x8000 | 141 | #define SYMMON_STACK_SIZE 0x8000 |
149 | 142 | ||
150 | #if defined (PROM) || defined (SABLE) | 143 | #if defined (PROM) |
151 | 144 | ||
152 | /* | 145 | /* |
153 | * These defines are prom version dependent. No code other than the IP27 | 146 | * These defines are prom version dependent. No code other than the IP27 |
@@ -184,7 +177,7 @@ | |||
184 | #define IP27_FREEMEM_COUNT 1 | 177 | #define IP27_FREEMEM_COUNT 1 |
185 | #define IP27_FREEMEM_STRIDE 0 | 178 | #define IP27_FREEMEM_STRIDE 0 |
186 | 179 | ||
187 | #endif /* PROM || SABLE*/ | 180 | #endif /* PROM */ |
188 | /* | 181 | /* |
189 | * There will be only one of these in a partition so the IO6 must set it up. | 182 | * There will be only one of these in a partition so the IO6 must set it up. |
190 | */ | 183 | */ |
@@ -207,17 +200,11 @@ | |||
207 | #define KLDIR_ENT_SIZE 0x40 | 200 | #define KLDIR_ENT_SIZE 0x40 |
208 | #define KLDIR_MAX_ENTRIES (0x400 / 0x40) | 201 | #define KLDIR_MAX_ENTRIES (0x400 / 0x40) |
209 | 202 | ||
210 | #endif /* !CONFIG_SGI_IO */ | ||
211 | |||
212 | #ifndef __ASSEMBLY__ | 203 | #ifndef __ASSEMBLY__ |
213 | typedef struct kldir_ent_s { | 204 | typedef struct kldir_ent_s { |
214 | u64 magic; /* Indicates validity of entry */ | 205 | u64 magic; /* Indicates validity of entry */ |
215 | off_t offset; /* Offset from start of node space */ | 206 | off_t offset; /* Offset from start of node space */ |
216 | #if defined(CONFIG_SGI_IO) /* FIXME */ | ||
217 | __psunsigned_t pointer; /* Pointer to area in some cases */ | ||
218 | #else | ||
219 | unsigned long pointer; /* Pointer to area in some cases */ | 207 | unsigned long pointer; /* Pointer to area in some cases */ |
220 | #endif | ||
221 | size_t size; /* Size in bytes */ | 208 | size_t size; /* Size in bytes */ |
222 | u64 count; /* Repeat count if array, 1 if not */ | 209 | u64 count; /* Repeat count if array, 1 if not */ |
223 | size_t stride; /* Stride if array, 0 if not */ | 210 | size_t stride; /* Stride if array, 0 if not */ |
@@ -227,22 +214,4 @@ typedef struct kldir_ent_s { | |||
227 | } kldir_ent_t; | 214 | } kldir_ent_t; |
228 | #endif /* !__ASSEMBLY__ */ | 215 | #endif /* !__ASSEMBLY__ */ |
229 | 216 | ||
230 | #if defined(CONFIG_SGI_IO) | ||
231 | |||
232 | #define KLDIR_ENT_SIZE 0x40 | ||
233 | #define KLDIR_MAX_ENTRIES (0x400 / 0x40) | ||
234 | |||
235 | /* | ||
236 | * The actual offsets of each memory area are machine-dependent | ||
237 | */ | ||
238 | #ifdef CONFIG_SGI_IP27 | ||
239 | // Not yet #include <asm/sn/sn0/kldir.h> | ||
240 | #elif defined(CONFIG_SGI_IP35) | ||
241 | #include <asm/sn/sn1/kldir.h> | ||
242 | #else | ||
243 | #error "kldir.h is currently defined for IP27 and IP35 platforms only" | ||
244 | #endif | ||
245 | |||
246 | #endif /* CONFIG_SGI_IO */ | ||
247 | |||
248 | #endif /* _ASM_SN_KLDIR_H */ | 217 | #endif /* _ASM_SN_KLDIR_H */ |
diff --git a/include/asm-mips/sn/launch.h b/include/asm-mips/sn/launch.h index b67699c0c475..b7c2226312c6 100644 --- a/include/asm-mips/sn/launch.h +++ b/include/asm-mips/sn/launch.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_SN_LAUNCH_H | 9 | #ifndef _ASM_SN_LAUNCH_H |
10 | #define _ASM_SN_LAUNCH_H | 10 | #define _ASM_SN_LAUNCH_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <asm/sn/types.h> | 12 | #include <asm/sn/types.h> |
14 | #include <asm/sn/addrs.h> | 13 | #include <asm/sn/addrs.h> |
15 | 14 | ||
diff --git a/include/asm-mips/sn/mapped_kernel.h b/include/asm-mips/sn/mapped_kernel.h index 59edb20f8ec5..c3dd5d0d525f 100644 --- a/include/asm-mips/sn/mapped_kernel.h +++ b/include/asm-mips/sn/mapped_kernel.h | |||
@@ -20,7 +20,6 @@ | |||
20 | * code. So no jumps can be done before we have switched to using | 20 | * code. So no jumps can be done before we have switched to using |
21 | * cksseg addresses. | 21 | * cksseg addresses. |
22 | */ | 22 | */ |
23 | #include <linux/config.h> | ||
24 | #include <asm/addrspace.h> | 23 | #include <asm/addrspace.h> |
25 | 24 | ||
26 | #define REP_BASE CAC_BASE | 25 | #define REP_BASE CAC_BASE |
diff --git a/include/asm-mips/sn/sn0/addrs.h b/include/asm-mips/sn/sn0/addrs.h index 398815639fb8..9e8cc52910f6 100644 --- a/include/asm-mips/sn/sn0/addrs.h +++ b/include/asm-mips/sn/sn0/addrs.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_SN_SN0_ADDRS_H | 11 | #ifndef _ASM_SN_SN0_ADDRS_H |
12 | #define _ASM_SN_SN0_ADDRS_H | 12 | #define _ASM_SN_SN0_ADDRS_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | /* | 15 | /* |
17 | * SN0 (on a T5) Address map | 16 | * SN0 (on a T5) Address map |
@@ -49,7 +48,7 @@ | |||
49 | * so for now we just use defines bracketed by an ifdef. | 48 | * so for now we just use defines bracketed by an ifdef. |
50 | */ | 49 | */ |
51 | 50 | ||
52 | #ifdef CONFIG_SGI_SN0_N_MODE | 51 | #ifdef CONFIG_SGI_SN_N_MODE |
53 | 52 | ||
54 | #define NODE_SIZE_BITS 31 | 53 | #define NODE_SIZE_BITS 31 |
55 | #define BWIN_SIZE_BITS 28 | 54 | #define BWIN_SIZE_BITS 28 |
@@ -63,7 +62,7 @@ | |||
63 | #define BDDIR_UPPER_MASK (UINT64_CAST 0x7ffff << 10) | 62 | #define BDDIR_UPPER_MASK (UINT64_CAST 0x7ffff << 10) |
64 | #define BDECC_UPPER_MASK (UINT64_CAST 0x3ffffff << 3) | 63 | #define BDECC_UPPER_MASK (UINT64_CAST 0x3ffffff << 3) |
65 | 64 | ||
66 | #else /* !defined(CONFIG_SGI_SN0_N_MODE), assume that M-mode is desired */ | 65 | #else /* !defined(CONFIG_SGI_SN_N_MODE), assume that M-mode is desired */ |
67 | 66 | ||
68 | #define NODE_SIZE_BITS 32 | 67 | #define NODE_SIZE_BITS 32 |
69 | #define BWIN_SIZE_BITS 29 | 68 | #define BWIN_SIZE_BITS 29 |
@@ -77,7 +76,7 @@ | |||
77 | #define BDDIR_UPPER_MASK (UINT64_CAST 0xfffff << 10) | 76 | #define BDDIR_UPPER_MASK (UINT64_CAST 0xfffff << 10) |
78 | #define BDECC_UPPER_MASK (UINT64_CAST 0x7ffffff << 3) | 77 | #define BDECC_UPPER_MASK (UINT64_CAST 0x7ffffff << 3) |
79 | 78 | ||
80 | #endif /* !defined(CONFIG_SGI_SN0_N_MODE) */ | 79 | #endif /* !defined(CONFIG_SGI_SN_N_MODE) */ |
81 | 80 | ||
82 | #define NODE_ADDRSPACE_SIZE (UINT64_CAST 1 << NODE_SIZE_BITS) | 81 | #define NODE_ADDRSPACE_SIZE (UINT64_CAST 1 << NODE_SIZE_BITS) |
83 | 82 | ||
@@ -85,15 +84,15 @@ | |||
85 | #define NASID_GET(_pa) (int) ((UINT64_CAST (_pa) >> \ | 84 | #define NASID_GET(_pa) (int) ((UINT64_CAST (_pa) >> \ |
86 | NASID_SHFT) & NASID_BITMASK) | 85 | NASID_SHFT) & NASID_BITMASK) |
87 | 86 | ||
88 | #if !defined(__ASSEMBLY__) && !defined(_STANDALONE) | 87 | #if !defined(__ASSEMBLY__) |
89 | 88 | ||
90 | #define NODE_SWIN_BASE(nasid, widget) \ | 89 | #define NODE_SWIN_BASE(nasid, widget) \ |
91 | ((widget == 0) ? NODE_BWIN_BASE((nasid), SWIN0_BIGWIN) \ | 90 | ((widget == 0) ? NODE_BWIN_BASE((nasid), SWIN0_BIGWIN) \ |
92 | : RAW_NODE_SWIN_BASE(nasid, widget)) | 91 | : RAW_NODE_SWIN_BASE(nasid, widget)) |
93 | #else /* __ASSEMBLY__ || _STANDALONE */ | 92 | #else /* __ASSEMBLY__ */ |
94 | #define NODE_SWIN_BASE(nasid, widget) \ | 93 | #define NODE_SWIN_BASE(nasid, widget) \ |
95 | (NODE_IO_BASE(nasid) + (UINT64_CAST (widget) << SWIN_SIZE_BITS)) | 94 | (NODE_IO_BASE(nasid) + (UINT64_CAST (widget) << SWIN_SIZE_BITS)) |
96 | #endif /* __ASSEMBLY__ || _STANDALONE */ | 95 | #endif /* __ASSEMBLY__ */ |
97 | 96 | ||
98 | /* | 97 | /* |
99 | * The following definitions pertain to the IO special address | 98 | * The following definitions pertain to the IO special address |
@@ -143,12 +142,7 @@ | |||
143 | #define SN0_WIDGET_BASE(_nasid, _wid) (NODE_SWIN_BASE((_nasid), (_wid))) | 142 | #define SN0_WIDGET_BASE(_nasid, _wid) (NODE_SWIN_BASE((_nasid), (_wid))) |
144 | 143 | ||
145 | /* Turn on sable logging for the processors whose bits are set. */ | 144 | /* Turn on sable logging for the processors whose bits are set. */ |
146 | #ifdef SABLE | ||
147 | #define SABLE_LOG_TRIGGER(_map) \ | ||
148 | *((volatile hubreg_t *)(IO_BASE + 0x17ffff0)) = (_map) | ||
149 | #else | ||
150 | #define SABLE_LOG_TRIGGER(_map) | 145 | #define SABLE_LOG_TRIGGER(_map) |
151 | #endif /* SABLE */ | ||
152 | 146 | ||
153 | #ifndef __ASSEMBLY__ | 147 | #ifndef __ASSEMBLY__ |
154 | #define KERN_NMI_ADDR(nasid, slice) \ | 148 | #define KERN_NMI_ADDR(nasid, slice) \ |
@@ -281,76 +275,6 @@ | |||
281 | 275 | ||
282 | #define _ARCSPROM | 276 | #define _ARCSPROM |
283 | 277 | ||
284 | #ifdef _STANDALONE | ||
285 | |||
286 | /* | ||
287 | * The PROM needs to pass the device base address and the | ||
288 | * device pci cfg space address to the device drivers during | ||
289 | * install. The COMPONENT->Key field is used for this purpose. | ||
290 | * Macros needed by SN0 device drivers to convert the | ||
291 | * COMPONENT->Key field to the respective base address. | ||
292 | * Key field looks as follows: | ||
293 | * | ||
294 | * +----------------------------------------------------+ | ||
295 | * |devnasid | widget |pciid |hubwidid|hstnasid | adap | | ||
296 | * | 2 | 1 | 1 | 1 | 2 | 1 | | ||
297 | * +----------------------------------------------------+ | ||
298 | * | | | | | | | | ||
299 | * 64 48 40 32 24 8 0 | ||
300 | * | ||
301 | * These are used by standalone drivers till the io infrastructure | ||
302 | * is in place. | ||
303 | */ | ||
304 | |||
305 | #ifndef __ASSEMBLY__ | ||
306 | |||
307 | #define uchar unsigned char | ||
308 | |||
309 | #define KEY_DEVNASID_SHFT 48 | ||
310 | #define KEY_WIDID_SHFT 40 | ||
311 | #define KEY_PCIID_SHFT 32 | ||
312 | #define KEY_HUBWID_SHFT 24 | ||
313 | #define KEY_HSTNASID_SHFT 8 | ||
314 | |||
315 | #define MK_SN0_KEY(nasid, widid, pciid) \ | ||
316 | ((((__psunsigned_t)nasid)<< KEY_DEVNASID_SHFT |\ | ||
317 | ((__psunsigned_t)widid) << KEY_WIDID_SHFT) |\ | ||
318 | ((__psunsigned_t)pciid) << KEY_PCIID_SHFT) | ||
319 | |||
320 | #define ADD_HUBWID_KEY(key,hubwid)\ | ||
321 | (key|=((__psunsigned_t)hubwid << KEY_HUBWID_SHFT)) | ||
322 | |||
323 | #define ADD_HSTNASID_KEY(key,hstnasid)\ | ||
324 | (key|=((__psunsigned_t)hstnasid << KEY_HSTNASID_SHFT)) | ||
325 | |||
326 | #define GET_DEVNASID_FROM_KEY(key) ((short)(key >> KEY_DEVNASID_SHFT)) | ||
327 | #define GET_WIDID_FROM_KEY(key) ((uchar)(key >> KEY_WIDID_SHFT)) | ||
328 | #define GET_PCIID_FROM_KEY(key) ((uchar)(key >> KEY_PCIID_SHFT)) | ||
329 | #define GET_HUBWID_FROM_KEY(key) ((uchar)(key >> KEY_HUBWID_SHFT)) | ||
330 | #define GET_HSTNASID_FROM_KEY(key) ((short)(key >> KEY_HSTNASID_SHFT)) | ||
331 | |||
332 | #define PCI_64_TARGID_SHFT 60 | ||
333 | |||
334 | #define GET_PCIBASE_FROM_KEY(key) (NODE_SWIN_BASE(GET_DEVNASID_FROM_KEY(key),\ | ||
335 | GET_WIDID_FROM_KEY(key))\ | ||
336 | | BRIDGE_DEVIO(GET_PCIID_FROM_KEY(key))) | ||
337 | |||
338 | #define GET_PCICFGBASE_FROM_KEY(key) \ | ||
339 | (NODE_SWIN_BASE(GET_DEVNASID_FROM_KEY(key),\ | ||
340 | GET_WIDID_FROM_KEY(key))\ | ||
341 | | BRIDGE_TYPE0_CFG_DEV(GET_PCIID_FROM_KEY(key))) | ||
342 | |||
343 | #define GET_WIDBASE_FROM_KEY(key) \ | ||
344 | (NODE_SWIN_BASE(GET_DEVNASID_FROM_KEY(key),\ | ||
345 | GET_WIDID_FROM_KEY(key))) | ||
346 | |||
347 | #define PUT_INSTALL_STATUS(c,s) c->Revision = s | ||
348 | #define GET_INSTALL_STATUS(c) c->Revision | ||
349 | |||
350 | #endif /* !__ASSEMBLY__ */ | ||
351 | |||
352 | #endif /* _STANDALONE */ | ||
353 | |||
354 | #if defined (HUB_ERR_STS_WAR) | 278 | #if defined (HUB_ERR_STS_WAR) |
355 | 279 | ||
356 | #define ERR_STS_WAR_REGISTER IIO_IIBUSERR | 280 | #define ERR_STS_WAR_REGISTER IIO_IIBUSERR |
diff --git a/include/asm-mips/sn/sn0/arch.h b/include/asm-mips/sn/sn0/arch.h index fb78773a5efe..f734f2007f24 100644 --- a/include/asm-mips/sn/sn0/arch.h +++ b/include/asm-mips/sn/sn0/arch.h | |||
@@ -11,9 +11,6 @@ | |||
11 | #ifndef _ASM_SN_SN0_ARCH_H | 11 | #ifndef _ASM_SN_SN0_ARCH_H |
12 | #define _ASM_SN_SN0_ARCH_H | 12 | #define _ASM_SN_SN0_ARCH_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | |||
16 | #ifndef SABLE | ||
17 | 14 | ||
18 | #ifndef SN0XXL /* 128 cpu SMP max */ | 15 | #ifndef SN0XXL /* 128 cpu SMP max */ |
19 | /* | 16 | /* |
@@ -54,25 +51,16 @@ | |||
54 | */ | 51 | */ |
55 | #define MAX_PARTITIONS MAX_REGIONS | 52 | #define MAX_PARTITIONS MAX_REGIONS |
56 | 53 | ||
57 | |||
58 | #else | ||
59 | |||
60 | #define MAX_COMPACT_NODES 4 | ||
61 | #define MAX_NASIDS 4 | ||
62 | #define MAXCPUS 8 | ||
63 | |||
64 | #endif | ||
65 | |||
66 | #define NASID_MASK_BYTES ((MAX_NASIDS + 7) / 8) | 54 | #define NASID_MASK_BYTES ((MAX_NASIDS + 7) / 8) |
67 | 55 | ||
68 | /* | 56 | /* |
69 | * Slot constants for SN0 | 57 | * Slot constants for SN0 |
70 | */ | 58 | */ |
71 | #ifdef CONFIG_SGI_SN0_N_MODE | 59 | #ifdef CONFIG_SGI_SN_N_MODE |
72 | #define MAX_MEM_SLOTS 16 /* max slots per node */ | 60 | #define MAX_MEM_SLOTS 16 /* max slots per node */ |
73 | #else /* !CONFIG_SGI_SN0_N_MODE, assume M_MODE */ | 61 | #else /* !CONFIG_SGI_SN_N_MODE, assume CONFIG_SGI_SN_M_MODE */ |
74 | #define MAX_MEM_SLOTS 32 /* max slots per node */ | 62 | #define MAX_MEM_SLOTS 32 /* max slots per node */ |
75 | #endif /* defined(N_MODE) */ | 63 | #endif /* CONFIG_SGI_SN_M_MODE */ |
76 | 64 | ||
77 | #define SLOT_SHIFT (27) | 65 | #define SLOT_SHIFT (27) |
78 | #define SLOT_MIN_MEM_SIZE (32*1024*1024) | 66 | #define SLOT_MIN_MEM_SIZE (32*1024*1024) |
diff --git a/include/asm-mips/sn/sn0/hub.h b/include/asm-mips/sn/sn0/hub.h index f5dbba6f4610..3e228f8e7969 100644 --- a/include/asm-mips/sn/sn0/hub.h +++ b/include/asm-mips/sn/sn0/hub.h | |||
@@ -31,10 +31,6 @@ | |||
31 | #include <asm/sn/sn0/hubni.h> | 31 | #include <asm/sn/sn0/hubni.h> |
32 | //#include <asm/sn/sn0/hubcore.h> | 32 | //#include <asm/sn/sn0/hubcore.h> |
33 | 33 | ||
34 | #ifdef SABLE | ||
35 | #define IP27_NO_HUBUART_INT 1 | ||
36 | #endif | ||
37 | |||
38 | /* Translation of uncached attributes */ | 34 | /* Translation of uncached attributes */ |
39 | #define UATTR_HSPEC 0 | 35 | #define UATTR_HSPEC 0 |
40 | #define UATTR_IO 1 | 36 | #define UATTR_IO 1 |
diff --git a/include/asm-mips/sn/sn0/hubio.h b/include/asm-mips/sn/sn0/hubio.h index f314da21b970..ef91b3363554 100644 --- a/include/asm-mips/sn/sn0/hubio.h +++ b/include/asm-mips/sn/sn0/hubio.h | |||
@@ -486,22 +486,6 @@ typedef union h1_icrba_u { | |||
486 | #define ICRBN_A_CERR_SHFT 54 | 486 | #define ICRBN_A_CERR_SHFT 54 |
487 | #define ICRBN_A_ERR_MASK 0x3ff | 487 | #define ICRBN_A_ERR_MASK 0x3ff |
488 | 488 | ||
489 | #if 0 /* Disabled, this causes namespace polution and break allmodconfig */ | ||
490 | /* | ||
491 | * Easy access macros. | ||
492 | */ | ||
493 | #define a_error icrba_fields_s.error | ||
494 | #define a_ecode icrba_fields_s.ecode | ||
495 | #define a_lnetuce icrba_fields_s.lnetuce | ||
496 | #define a_mark icrba_fields_s.mark | ||
497 | #define a_xerr icrba_fields_s.xerr | ||
498 | #define a_sidn icrba_fields_s.sidn | ||
499 | #define a_tnum icrba_fields_s.tnum | ||
500 | #define a_addr icrba_fields_s.addr | ||
501 | #define a_valid icrba_fields_s.valid | ||
502 | #define a_iow icrba_fields_s.iow | ||
503 | #endif | ||
504 | |||
505 | #endif /* !__ASSEMBLY__ */ | 489 | #endif /* !__ASSEMBLY__ */ |
506 | 490 | ||
507 | #define IIO_ICRB_ADDR_SHFT 2 /* Shift to get proper address */ | 491 | #define IIO_ICRB_ADDR_SHFT 2 /* Shift to get proper address */ |
diff --git a/include/asm-mips/sn/sn0/hubmd.h b/include/asm-mips/sn/sn0/hubmd.h index a66def4e0ba0..14c225d80664 100644 --- a/include/asm-mips/sn/sn0/hubmd.h +++ b/include/asm-mips/sn/sn0/hubmd.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_SN_SN0_HUBMD_H | 11 | #ifndef _ASM_SN_SN0_HUBMD_H |
12 | #define _ASM_SN_SN0_HUBMD_H | 12 | #define _ASM_SN_SN0_HUBMD_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | /* | 15 | /* |
17 | * Hub Memory/Directory interface registers | 16 | * Hub Memory/Directory interface registers |
@@ -92,7 +91,7 @@ | |||
92 | #define MD_UREG1_14 0x2200f0 /* uController/UART 1 register */ | 91 | #define MD_UREG1_14 0x2200f0 /* uController/UART 1 register */ |
93 | #define MD_UREG1_15 0x2200f8 /* uController/UART 1 register */ | 92 | #define MD_UREG1_15 0x2200f8 /* uController/UART 1 register */ |
94 | 93 | ||
95 | #ifdef CONFIG_SGI_SN0_N_MODE | 94 | #ifdef CONFIG_SGI_SN_N_MODE |
96 | #define MD_MEM_BANKS 4 /* 4 banks of memory max in N mode */ | 95 | #define MD_MEM_BANKS 4 /* 4 banks of memory max in N mode */ |
97 | #else | 96 | #else |
98 | #define MD_MEM_BANKS 8 /* 8 banks of memory max in M mode */ | 97 | #define MD_MEM_BANKS 8 /* 8 banks of memory max in M mode */ |
diff --git a/include/asm-mips/sn/sn0/hubpi.h b/include/asm-mips/sn/sn0/hubpi.h index 355bba8552e3..e39f5f9da040 100644 --- a/include/asm-mips/sn/sn0/hubpi.h +++ b/include/asm-mips/sn/sn0/hubpi.h | |||
@@ -398,24 +398,6 @@ typedef u64 rtc_time_t; | |||
398 | 398 | ||
399 | /* PI_RT_FILTER_CTRL mask and shift definitions */ | 399 | /* PI_RT_FILTER_CTRL mask and shift definitions */ |
400 | 400 | ||
401 | #if 0 | ||
402 | /* | ||
403 | * XXX - This register's definition has changed, but it's only implemented | ||
404 | * in Hub 2. | ||
405 | */ | ||
406 | #define PRFC_DROP_COUNT_SHFT 27 | ||
407 | #define PRFC_DROP_COUNT_MASK (UINT64_CAST 0x3ff << 27) | ||
408 | #define PRFC_DROP_CTR_SHFT 18 | ||
409 | #define PRFC_DROP_CTR_MASK (UINT64_CAST 0x1ff << 18) | ||
410 | #define PRFC_MASK_ENABLE_SHFT 10 | ||
411 | #define PRFC_MASK_ENABLE_MASK (UINT64_CAST 0x7f << 10) | ||
412 | #define PRFC_MASK_CTR_SHFT 2 | ||
413 | #define PRFC_MASK_CTR_MASK (UINT64_CAST 0xff << 2) | ||
414 | #define PRFC_OFFSET_SHFT 0 | ||
415 | #define PRFC_OFFSET_MASK (UINT64_CAST 3) | ||
416 | #endif /* 0 */ | ||
417 | |||
418 | |||
419 | /* | 401 | /* |
420 | * Bits for NACK_CNT_A/B and NACK_CMP | 402 | * Bits for NACK_CNT_A/B and NACK_CMP |
421 | */ | 403 | */ |
diff --git a/include/asm-mips/sn/sn0/ip27.h b/include/asm-mips/sn/sn0/ip27.h index ade0e974dd78..3c97e0855c8d 100644 --- a/include/asm-mips/sn/sn0/ip27.h +++ b/include/asm-mips/sn/sn0/ip27.h | |||
@@ -6,7 +6,7 @@ | |||
6 | * Derived from IRIX <sys/SN/SN0/IP27.h>. | 6 | * Derived from IRIX <sys/SN/SN0/IP27.h>. |
7 | * | 7 | * |
8 | * Copyright (C) 1992 - 1997, 1999 Silicon Graphics, Inc. | 8 | * Copyright (C) 1992 - 1997, 1999 Silicon Graphics, Inc. |
9 | * Copyright (C) 1999 by Ralf Baechle | 9 | * Copyright (C) 1999, 2006 by Ralf Baechle |
10 | */ | 10 | */ |
11 | #ifndef _ASM_SN_SN0_IP27_H | 11 | #ifndef _ASM_SN_SN0_IP27_H |
12 | #define _ASM_SN_SN0_IP27_H | 12 | #define _ASM_SN_SN0_IP27_H |
@@ -82,11 +82,4 @@ | |||
82 | #define SEND_NMI(_nasid, _slice) \ | 82 | #define SEND_NMI(_nasid, _slice) \ |
83 | REMOTE_HUB_S((_nasid), (PI_NMI_A + ((_slice) * PI_NMI_OFFSET)), 1) | 83 | REMOTE_HUB_S((_nasid), (PI_NMI_A + ((_slice) * PI_NMI_OFFSET)), 1) |
84 | 84 | ||
85 | /* Sanity hazzard ... Below all the Origin hacks are following. */ | ||
86 | |||
87 | #define SN00_BRIDGE 0x9200000008000000 | ||
88 | #define SN00I_BRIDGE0 0x920000000b000000 | ||
89 | #define SN00I_BRIDGE1 0x920000000e000000 | ||
90 | #define SN00I_BRIDGE2 0x920000000f000000 | ||
91 | |||
92 | #endif /* _ASM_SN_SN0_IP27_H */ | 85 | #endif /* _ASM_SN_SN0_IP27_H */ |
diff --git a/include/asm-mips/sni.h b/include/asm-mips/sni.h index b3bc698dfdee..b9ba54d0dd35 100644 --- a/include/asm-mips/sni.h +++ b/include/asm-mips/sni.h | |||
@@ -15,9 +15,6 @@ | |||
15 | /* | 15 | /* |
16 | * ASIC PCI registers for little endian configuration. | 16 | * ASIC PCI registers for little endian configuration. |
17 | */ | 17 | */ |
18 | #ifndef __MIPSEL__ | ||
19 | #error "Fix me for big endian" | ||
20 | #endif | ||
21 | #define PCIMT_UCONF 0xbfff0000 | 18 | #define PCIMT_UCONF 0xbfff0000 |
22 | #define PCIMT_IOADTIMEOUT2 0xbfff0008 | 19 | #define PCIMT_IOADTIMEOUT2 0xbfff0008 |
23 | #define PCIMT_IOMEMCONF 0xbfff0010 | 20 | #define PCIMT_IOMEMCONF 0xbfff0010 |
@@ -51,9 +48,9 @@ | |||
51 | #define PCIMT_PCI_CONF 0xbfff0100 | 48 | #define PCIMT_PCI_CONF 0xbfff0100 |
52 | 49 | ||
53 | /* | 50 | /* |
54 | * Data port for the PCI bus. | 51 | * Data port for the PCI bus in IO space |
55 | */ | 52 | */ |
56 | #define PCIMT_CONFIG_DATA 0xb4000cfc | 53 | #define PCIMT_CONFIG_DATA 0x0cfc |
57 | 54 | ||
58 | /* | 55 | /* |
59 | * Board specific registers | 56 | * Board specific registers |
diff --git a/include/asm-mips/stackframe.h b/include/asm-mips/stackframe.h index c4856a874965..513aa5133830 100644 --- a/include/asm-mips/stackframe.h +++ b/include/asm-mips/stackframe.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASM_STACKFRAME_H | 10 | #ifndef _ASM_STACKFRAME_H |
11 | #define _ASM_STACKFRAME_H | 11 | #define _ASM_STACKFRAME_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/threads.h> | 13 | #include <linux/threads.h> |
15 | 14 | ||
16 | #include <asm/asm.h> | 15 | #include <asm/asm.h> |
diff --git a/include/asm-mips/string.h b/include/asm-mips/string.h index 907da600fddd..436e3ad352d9 100644 --- a/include/asm-mips/string.h +++ b/include/asm-mips/string.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASM_STRING_H | 10 | #ifndef _ASM_STRING_H |
11 | #define _ASM_STRING_H | 11 | #define _ASM_STRING_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | /* | 14 | /* |
16 | * Most of the inline functions are rather naive implementations so I just | 15 | * Most of the inline functions are rather naive implementations so I just |
diff --git a/include/asm-mips/system.h b/include/asm-mips/system.h index 261f71d16a07..130333d7c4ee 100644 --- a/include/asm-mips/system.h +++ b/include/asm-mips/system.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef _ASM_SYSTEM_H | 12 | #ifndef _ASM_SYSTEM_H |
13 | #define _ASM_SYSTEM_H | 13 | #define _ASM_SYSTEM_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <linux/types.h> | 15 | #include <linux/types.h> |
17 | 16 | ||
18 | #include <asm/addrspace.h> | 17 | #include <asm/addrspace.h> |
diff --git a/include/asm-mips/thread_info.h b/include/asm-mips/thread_info.h index f8d97dafd2f4..ae8ada5b42a9 100644 --- a/include/asm-mips/thread_info.h +++ b/include/asm-mips/thread_info.h | |||
@@ -9,7 +9,6 @@ | |||
9 | 9 | ||
10 | #ifdef __KERNEL__ | 10 | #ifdef __KERNEL__ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | #ifndef __ASSEMBLY__ | 13 | #ifndef __ASSEMBLY__ |
15 | 14 | ||
diff --git a/include/asm-mips/tlbflush.h b/include/asm-mips/tlbflush.h index bb4ae3cdcbf1..276be77c3e85 100644 --- a/include/asm-mips/tlbflush.h +++ b/include/asm-mips/tlbflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_TLBFLUSH_H | 1 | #ifndef __ASM_TLBFLUSH_H |
2 | #define __ASM_TLBFLUSH_H | 2 | #define __ASM_TLBFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | 5 | ||
7 | /* | 6 | /* |
diff --git a/include/asm-mips/tx4927/toshiba_rbtx4927.h b/include/asm-mips/tx4927/toshiba_rbtx4927.h index 6ce1e9475f99..94bef03d9635 100644 --- a/include/asm-mips/tx4927/toshiba_rbtx4927.h +++ b/include/asm-mips/tx4927/toshiba_rbtx4927.h | |||
@@ -27,7 +27,6 @@ | |||
27 | #ifndef __ASM_TX4927_TOSHIBA_RBTX4927_H | 27 | #ifndef __ASM_TX4927_TOSHIBA_RBTX4927_H |
28 | #define __ASM_TX4927_TOSHIBA_RBTX4927_H | 28 | #define __ASM_TX4927_TOSHIBA_RBTX4927_H |
29 | 29 | ||
30 | #include <linux/config.h> | ||
31 | #include <asm/tx4927/tx4927.h> | 30 | #include <asm/tx4927/tx4927.h> |
32 | #include <asm/tx4927/tx4927_mips.h> | 31 | #include <asm/tx4927/tx4927_mips.h> |
33 | #ifdef CONFIG_PCI | 32 | #ifdef CONFIG_PCI |
diff --git a/include/asm-mips/types.h b/include/asm-mips/types.h index cd2813d8e136..2b52e180c6f2 100644 --- a/include/asm-mips/types.h +++ b/include/asm-mips/types.h | |||
@@ -52,7 +52,6 @@ typedef unsigned long long __u64; | |||
52 | 52 | ||
53 | #ifndef __ASSEMBLY__ | 53 | #ifndef __ASSEMBLY__ |
54 | 54 | ||
55 | #include <linux/config.h> | ||
56 | 55 | ||
57 | typedef __signed char s8; | 56 | typedef __signed char s8; |
58 | typedef unsigned char u8; | 57 | typedef unsigned char u8; |
diff --git a/include/asm-mips/uaccess.h b/include/asm-mips/uaccess.h index b96f3e0f3933..1cdd4eeb2f73 100644 --- a/include/asm-mips/uaccess.h +++ b/include/asm-mips/uaccess.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_UACCESS_H | 9 | #ifndef _ASM_UACCESS_H |
10 | #define _ASM_UACCESS_H | 10 | #define _ASM_UACCESS_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/kernel.h> | 12 | #include <linux/kernel.h> |
14 | #include <linux/errno.h> | 13 | #include <linux/errno.h> |
15 | #include <linux/thread_info.h> | 14 | #include <linux/thread_info.h> |
diff --git a/include/asm-mips/unistd.h b/include/asm-mips/unistd.h index 1068fe9a0a58..8bb0bb9b2e68 100644 --- a/include/asm-mips/unistd.h +++ b/include/asm-mips/unistd.h | |||
@@ -905,6 +905,8 @@ | |||
905 | #define __NR_N32_Linux 6000 | 905 | #define __NR_N32_Linux 6000 |
906 | #define __NR_N32_Linux_syscalls 268 | 906 | #define __NR_N32_Linux_syscalls 268 |
907 | 907 | ||
908 | #ifdef __KERNEL__ | ||
909 | |||
908 | #ifndef __ASSEMBLY__ | 910 | #ifndef __ASSEMBLY__ |
909 | 911 | ||
910 | /* XXX - _foo needs to be __foo, while __NR_bar could be _NR_bar. */ | 912 | /* XXX - _foo needs to be __foo, while __NR_bar could be _NR_bar. */ |
@@ -1168,9 +1170,6 @@ type name (atype a,btype b,ctype c,dtype d,etype e,ftype f) \ | |||
1168 | 1170 | ||
1169 | #endif /* (_MIPS_SIM == _MIPS_SIM_NABI32) || (_MIPS_SIM == _MIPS_SIM_ABI64) */ | 1171 | #endif /* (_MIPS_SIM == _MIPS_SIM_NABI32) || (_MIPS_SIM == _MIPS_SIM_ABI64) */ |
1170 | 1172 | ||
1171 | #ifdef __KERNEL__ | ||
1172 | |||
1173 | #include <linux/config.h> | ||
1174 | 1173 | ||
1175 | #define __ARCH_WANT_IPC_PARSE_VERSION | 1174 | #define __ARCH_WANT_IPC_PARSE_VERSION |
1176 | #define __ARCH_WANT_OLD_READDIR | 1175 | #define __ARCH_WANT_OLD_READDIR |
@@ -1197,7 +1196,6 @@ type name (atype a,btype b,ctype c,dtype d,etype e,ftype f) \ | |||
1197 | # ifdef CONFIG_MIPS32_O32 | 1196 | # ifdef CONFIG_MIPS32_O32 |
1198 | # define __ARCH_WANT_COMPAT_SYS_TIME | 1197 | # define __ARCH_WANT_COMPAT_SYS_TIME |
1199 | # endif | 1198 | # endif |
1200 | #endif | ||
1201 | 1199 | ||
1202 | #ifdef __KERNEL_SYSCALLS__ | 1200 | #ifdef __KERNEL_SYSCALLS__ |
1203 | 1201 | ||
@@ -1248,4 +1246,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
1248 | */ | 1246 | */ |
1249 | #define cond_syscall(x) asm(".weak\t" #x "\n" #x "\t=\tsys_ni_syscall") | 1247 | #define cond_syscall(x) asm(".weak\t" #x "\n" #x "\t=\tsys_ni_syscall") |
1250 | 1248 | ||
1249 | #endif /* __KERNEL__ */ | ||
1251 | #endif /* _ASM_UNISTD_H */ | 1250 | #endif /* _ASM_UNISTD_H */ |
diff --git a/include/asm-mips/vga.h b/include/asm-mips/vga.h index 34755c0a6398..c1dd0b10bc27 100644 --- a/include/asm-mips/vga.h +++ b/include/asm-mips/vga.h | |||
@@ -13,7 +13,7 @@ | |||
13 | * access the videoram directly without any black magic. | 13 | * access the videoram directly without any black magic. |
14 | */ | 14 | */ |
15 | 15 | ||
16 | #define VGA_MAP_MEM(x) (0xb0000000L + (unsigned long)(x)) | 16 | #define VGA_MAP_MEM(x,s) (0xb0000000L + (unsigned long)(x)) |
17 | 17 | ||
18 | #define vga_readb(x) (*(x)) | 18 | #define vga_readb(x) (*(x)) |
19 | #define vga_writeb(x,y) (*(y) = (x)) | 19 | #define vga_writeb(x,y) (*(y) = (x)) |
diff --git a/include/asm-mips/vr41xx/vrc4173.h b/include/asm-mips/vr41xx/vrc4173.h index 4d41a9c091d4..96fdcd54cec7 100644 --- a/include/asm-mips/vr41xx/vrc4173.h +++ b/include/asm-mips/vr41xx/vrc4173.h | |||
@@ -24,7 +24,6 @@ | |||
24 | #ifndef __NEC_VRC4173_H | 24 | #ifndef __NEC_VRC4173_H |
25 | #define __NEC_VRC4173_H | 25 | #define __NEC_VRC4173_H |
26 | 26 | ||
27 | #include <linux/config.h> | ||
28 | #include <asm/io.h> | 27 | #include <asm/io.h> |
29 | 28 | ||
30 | /* | 29 | /* |
diff --git a/include/asm-mips/war.h b/include/asm-mips/war.h index ad374bd3f130..3ac146c019c9 100644 --- a/include/asm-mips/war.h +++ b/include/asm-mips/war.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef _ASM_WAR_H | 8 | #ifndef _ASM_WAR_H |
9 | #define _ASM_WAR_H | 9 | #define _ASM_WAR_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | 11 | ||
13 | /* | 12 | /* |
14 | * Another R4600 erratum. Due to the lack of errata information the exact | 13 | * Another R4600 erratum. Due to the lack of errata information the exact |
@@ -172,7 +171,8 @@ | |||
172 | * On the RM9000 there is a problem which makes the CreateDirtyExclusive | 171 | * On the RM9000 there is a problem which makes the CreateDirtyExclusive |
173 | * cache operation unusable on SMP systems. | 172 | * cache operation unusable on SMP systems. |
174 | */ | 173 | */ |
175 | #if defined(CONFIG_MOMENCO_JAGUAR_ATX) || defined(CONFIG_PMC_YOSEMITE) | 174 | #if defined(CONFIG_MOMENCO_JAGUAR_ATX) || defined(CONFIG_PMC_YOSEMITE) || \ |
175 | defined(CONFIG_BASLER_EXCITE) | ||
176 | #define RM9000_CDEX_SMP_WAR 1 | 176 | #define RM9000_CDEX_SMP_WAR 1 |
177 | #endif | 177 | #endif |
178 | 178 | ||
@@ -182,7 +182,7 @@ | |||
182 | * being fetched may case spurious exceptions. | 182 | * being fetched may case spurious exceptions. |
183 | */ | 183 | */ |
184 | #if defined(CONFIG_MOMENCO_JAGUAR_ATX) || defined(CONFIG_MOMENCO_OCELOT_3) || \ | 184 | #if defined(CONFIG_MOMENCO_JAGUAR_ATX) || defined(CONFIG_MOMENCO_OCELOT_3) || \ |
185 | defined(CONFIG_PMC_YOSEMITE) | 185 | defined(CONFIG_PMC_YOSEMITE) || defined(CONFIG_BASLER_EXCITE) |
186 | #define ICACHE_REFILLS_WORKAROUND_WAR 1 | 186 | #define ICACHE_REFILLS_WORKAROUND_WAR 1 |
187 | #endif | 187 | #endif |
188 | 188 | ||
diff --git a/include/asm-mips/wbflush.h b/include/asm-mips/wbflush.h index c3bef50f37a8..eadc0ac47e24 100644 --- a/include/asm-mips/wbflush.h +++ b/include/asm-mips/wbflush.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_WBFLUSH_H | 11 | #ifndef _ASM_WBFLUSH_H |
12 | #define _ASM_WBFLUSH_H | 12 | #define _ASM_WBFLUSH_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | #ifdef CONFIG_CPU_HAS_WB | 15 | #ifdef CONFIG_CPU_HAS_WB |
17 | 16 | ||
diff --git a/include/asm-parisc/atomic.h b/include/asm-parisc/atomic.h index 403ea97316cf..48bf9b8ab8ff 100644 --- a/include/asm-parisc/atomic.h +++ b/include/asm-parisc/atomic.h | |||
@@ -5,7 +5,6 @@ | |||
5 | #ifndef _ASM_PARISC_ATOMIC_H_ | 5 | #ifndef _ASM_PARISC_ATOMIC_H_ |
6 | #define _ASM_PARISC_ATOMIC_H_ | 6 | #define _ASM_PARISC_ATOMIC_H_ |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | #include <linux/types.h> | 8 | #include <linux/types.h> |
10 | #include <asm/system.h> | 9 | #include <asm/system.h> |
11 | 10 | ||
diff --git a/include/asm-parisc/cache.h b/include/asm-parisc/cache.h index c831665473cb..7d22fa206fc4 100644 --- a/include/asm-parisc/cache.h +++ b/include/asm-parisc/cache.h | |||
@@ -5,7 +5,6 @@ | |||
5 | #ifndef __ARCH_PARISC_CACHE_H | 5 | #ifndef __ARCH_PARISC_CACHE_H |
6 | #define __ARCH_PARISC_CACHE_H | 6 | #define __ARCH_PARISC_CACHE_H |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | 8 | ||
10 | /* | 9 | /* |
11 | * PA 2.0 processors have 64-byte cachelines; PA 1.1 processors have | 10 | * PA 2.0 processors have 64-byte cachelines; PA 1.1 processors have |
diff --git a/include/asm-parisc/cacheflush.h b/include/asm-parisc/cacheflush.h index 76b6b7d6046a..0b459cdfbd6f 100644 --- a/include/asm-parisc/cacheflush.h +++ b/include/asm-parisc/cacheflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _PARISC_CACHEFLUSH_H | 1 | #ifndef _PARISC_CACHEFLUSH_H |
2 | #define _PARISC_CACHEFLUSH_H | 2 | #define _PARISC_CACHEFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | #include <asm/cache.h> /* for flush_user_dcache_range_asm() proto */ | 5 | #include <asm/cache.h> /* for flush_user_dcache_range_asm() proto */ |
7 | 6 | ||
diff --git a/include/asm-parisc/dma-mapping.h b/include/asm-parisc/dma-mapping.h index 74d4ac6f2151..1e387e1dad30 100644 --- a/include/asm-parisc/dma-mapping.h +++ b/include/asm-parisc/dma-mapping.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _PARISC_DMA_MAPPING_H | 1 | #ifndef _PARISC_DMA_MAPPING_H |
2 | #define _PARISC_DMA_MAPPING_H | 2 | #define _PARISC_DMA_MAPPING_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | #include <asm/cacheflush.h> | 5 | #include <asm/cacheflush.h> |
7 | #include <asm/scatterlist.h> | 6 | #include <asm/scatterlist.h> |
diff --git a/include/asm-parisc/dma.h b/include/asm-parisc/dma.h index 31fd10df43a7..9979c3cb3745 100644 --- a/include/asm-parisc/dma.h +++ b/include/asm-parisc/dma.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _ASM_DMA_H | 9 | #ifndef _ASM_DMA_H |
10 | #define _ASM_DMA_H | 10 | #define _ASM_DMA_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <asm/io.h> /* need byte IO */ | 12 | #include <asm/io.h> /* need byte IO */ |
14 | #include <asm/system.h> | 13 | #include <asm/system.h> |
15 | 14 | ||
diff --git a/include/asm-parisc/io.h b/include/asm-parisc/io.h index 244f6b8883f4..b9eb245b8874 100644 --- a/include/asm-parisc/io.h +++ b/include/asm-parisc/io.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_IO_H | 1 | #ifndef _ASM_IO_H |
2 | #define _ASM_IO_H | 2 | #define _ASM_IO_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/types.h> | 4 | #include <linux/types.h> |
6 | #include <asm/pgtable.h> | 5 | #include <asm/pgtable.h> |
7 | 6 | ||
diff --git a/include/asm-parisc/irq.h b/include/asm-parisc/irq.h index b0a30e2c9813..377ba90c7d02 100644 --- a/include/asm-parisc/irq.h +++ b/include/asm-parisc/irq.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef _ASM_PARISC_IRQ_H | 7 | #ifndef _ASM_PARISC_IRQ_H |
8 | #define _ASM_PARISC_IRQ_H | 8 | #define _ASM_PARISC_IRQ_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <linux/cpumask.h> | 10 | #include <linux/cpumask.h> |
12 | #include <asm/types.h> | 11 | #include <asm/types.h> |
13 | 12 | ||
diff --git a/include/asm-parisc/kmap_types.h b/include/asm-parisc/kmap_types.h index 6886a0c3fedf..806aae3c5338 100644 --- a/include/asm-parisc/kmap_types.h +++ b/include/asm-parisc/kmap_types.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_KMAP_TYPES_H | 1 | #ifndef _ASM_KMAP_TYPES_H |
2 | #define _ASM_KMAP_TYPES_H | 2 | #define _ASM_KMAP_TYPES_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_DEBUG_HIGHMEM | 5 | #ifdef CONFIG_DEBUG_HIGHMEM |
7 | # define D(n) __KM_FENCE_##n , | 6 | # define D(n) __KM_FENCE_##n , |
diff --git a/include/asm-parisc/page.h b/include/asm-parisc/page.h index c0dd461fb8f1..0695bc958d56 100644 --- a/include/asm-parisc/page.h +++ b/include/asm-parisc/page.h | |||
@@ -10,7 +10,6 @@ | |||
10 | 10 | ||
11 | 11 | ||
12 | #ifdef __KERNEL__ | 12 | #ifdef __KERNEL__ |
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | #if defined(CONFIG_PARISC_PAGE_SIZE_4KB) | 14 | #if defined(CONFIG_PARISC_PAGE_SIZE_4KB) |
16 | # define PAGE_SHIFT 12 /* 4k */ | 15 | # define PAGE_SHIFT 12 /* 4k */ |
diff --git a/include/asm-parisc/param.h b/include/asm-parisc/param.h index f4694d452dd6..07cb9b93cfe2 100644 --- a/include/asm-parisc/param.h +++ b/include/asm-parisc/param.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define _ASMPARISC_PARAM_H | 2 | #define _ASMPARISC_PARAM_H |
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | #include <linux/config.h> | ||
6 | # ifdef CONFIG_PA20 | 5 | # ifdef CONFIG_PA20 |
7 | # define HZ 1000 /* Faster machines */ | 6 | # define HZ 1000 /* Faster machines */ |
8 | # else | 7 | # else |
diff --git a/include/asm-parisc/pci.h b/include/asm-parisc/pci.h index 77bbafb7f73e..8b631f47eb25 100644 --- a/include/asm-parisc/pci.h +++ b/include/asm-parisc/pci.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_PARISC_PCI_H | 1 | #ifndef __ASM_PARISC_PCI_H |
2 | #define __ASM_PARISC_PCI_H | 2 | #define __ASM_PARISC_PCI_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/scatterlist.h> | 4 | #include <asm/scatterlist.h> |
6 | 5 | ||
7 | 6 | ||
diff --git a/include/asm-parisc/pdc.h b/include/asm-parisc/pdc.h index 0a3face6c480..08364f957e7a 100644 --- a/include/asm-parisc/pdc.h +++ b/include/asm-parisc/pdc.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _PARISC_PDC_H | 1 | #ifndef _PARISC_PDC_H |
2 | #define _PARISC_PDC_H | 2 | #define _PARISC_PDC_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * PDC return values ... | 6 | * PDC return values ... |
diff --git a/include/asm-parisc/pgtable.h b/include/asm-parisc/pgtable.h index aec089eb8b85..b6bcc672ba80 100644 --- a/include/asm-parisc/pgtable.h +++ b/include/asm-parisc/pgtable.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #include <asm-generic/4level-fixup.h> | 4 | #include <asm-generic/4level-fixup.h> |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <asm/fixmap.h> | 6 | #include <asm/fixmap.h> |
8 | 7 | ||
9 | #ifndef __ASSEMBLY__ | 8 | #ifndef __ASSEMBLY__ |
diff --git a/include/asm-parisc/processor.h b/include/asm-parisc/processor.h index 89f2f1c16c12..ca49dc91f4fc 100644 --- a/include/asm-parisc/processor.h +++ b/include/asm-parisc/processor.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #define __ASM_PARISC_PROCESSOR_H | 9 | #define __ASM_PARISC_PROCESSOR_H |
10 | 10 | ||
11 | #ifndef __ASSEMBLY__ | 11 | #ifndef __ASSEMBLY__ |
12 | #include <linux/config.h> | ||
13 | #include <linux/threads.h> | 12 | #include <linux/threads.h> |
14 | #include <linux/spinlock_types.h> | 13 | #include <linux/spinlock_types.h> |
15 | 14 | ||
diff --git a/include/asm-parisc/psw.h b/include/asm-parisc/psw.h index 4334d6ca2add..5a3e23c9ce63 100644 --- a/include/asm-parisc/psw.h +++ b/include/asm-parisc/psw.h | |||
@@ -1,6 +1,5 @@ | |||
1 | #ifndef _PARISC_PSW_H | 1 | #ifndef _PARISC_PSW_H |
2 | 2 | ||
3 | #include <linux/config.h> | ||
4 | 3 | ||
5 | #define PSW_I 0x00000001 | 4 | #define PSW_I 0x00000001 |
6 | #define PSW_D 0x00000002 | 5 | #define PSW_D 0x00000002 |
diff --git a/include/asm-parisc/smp.h b/include/asm-parisc/smp.h index dbdbd2e9fdf9..d4c0e26afcd1 100644 --- a/include/asm-parisc/smp.h +++ b/include/asm-parisc/smp.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_SMP_H | 1 | #ifndef __ASM_SMP_H |
2 | #define __ASM_SMP_H | 2 | #define __ASM_SMP_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #if defined(CONFIG_SMP) | 5 | #if defined(CONFIG_SMP) |
7 | 6 | ||
diff --git a/include/asm-parisc/system.h b/include/asm-parisc/system.h index a5a973c0c07f..863876134b2c 100644 --- a/include/asm-parisc/system.h +++ b/include/asm-parisc/system.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __PARISC_SYSTEM_H | 1 | #ifndef __PARISC_SYSTEM_H |
2 | #define __PARISC_SYSTEM_H | 2 | #define __PARISC_SYSTEM_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/psw.h> | 4 | #include <asm/psw.h> |
6 | 5 | ||
7 | /* The program status word as bitfields. */ | 6 | /* The program status word as bitfields. */ |
diff --git a/include/asm-parisc/tlbflush.h b/include/asm-parisc/tlbflush.h index 825994a90e2d..f662e837dea1 100644 --- a/include/asm-parisc/tlbflush.h +++ b/include/asm-parisc/tlbflush.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | /* TLB flushing routines.... */ | 4 | /* TLB flushing routines.... */ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <linux/mm.h> | 6 | #include <linux/mm.h> |
8 | #include <asm/mmu_context.h> | 7 | #include <asm/mmu_context.h> |
9 | 8 | ||
diff --git a/include/asm-parisc/unistd.h b/include/asm-parisc/unistd.h index 0e1a30be2e30..12b867238a47 100644 --- a/include/asm-parisc/unistd.h +++ b/include/asm-parisc/unistd.h | |||
@@ -792,6 +792,7 @@ | |||
792 | #define HPUX_GATEWAY_ADDR 0xC0000004 | 792 | #define HPUX_GATEWAY_ADDR 0xC0000004 |
793 | #define LINUX_GATEWAY_ADDR 0x100 | 793 | #define LINUX_GATEWAY_ADDR 0x100 |
794 | 794 | ||
795 | #ifdef __KERNEL__ | ||
795 | #ifndef __ASSEMBLY__ | 796 | #ifndef __ASSEMBLY__ |
796 | 797 | ||
797 | #define SYS_ify(syscall_name) __NR_##syscall_name | 798 | #define SYS_ify(syscall_name) __NR_##syscall_name |
@@ -934,7 +935,6 @@ type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4, type5 arg5) \ | |||
934 | return K_INLINE_SYSCALL(name, 5, arg1, arg2, arg3, arg4, arg5); \ | 935 | return K_INLINE_SYSCALL(name, 5, arg1, arg2, arg3, arg4, arg5); \ |
935 | } | 936 | } |
936 | 937 | ||
937 | #ifdef __KERNEL__ | ||
938 | #define __ARCH_WANT_OLD_READDIR | 938 | #define __ARCH_WANT_OLD_READDIR |
939 | #define __ARCH_WANT_STAT64 | 939 | #define __ARCH_WANT_STAT64 |
940 | #define __ARCH_WANT_SYS_ALARM | 940 | #define __ARCH_WANT_SYS_ALARM |
@@ -956,7 +956,6 @@ type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4, type5 arg5) \ | |||
956 | #define __ARCH_WANT_SYS_SIGPENDING | 956 | #define __ARCH_WANT_SYS_SIGPENDING |
957 | #define __ARCH_WANT_SYS_SIGPROCMASK | 957 | #define __ARCH_WANT_SYS_SIGPROCMASK |
958 | #define __ARCH_WANT_SYS_RT_SIGACTION | 958 | #define __ARCH_WANT_SYS_RT_SIGACTION |
959 | #endif | ||
960 | 959 | ||
961 | /* mmap & mmap2 take 6 arguments */ | 960 | /* mmap & mmap2 take 6 arguments */ |
962 | #define _syscall6(type,name,type1,arg1,type2,arg2,type3,arg3,type4,arg4,type5,arg5,type6,arg6) \ | 961 | #define _syscall6(type,name,type1,arg1,type2,arg2,type3,arg3,type4,arg4,type5,arg5,type6,arg6) \ |
@@ -1056,4 +1055,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
1056 | */ | 1055 | */ |
1057 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 1056 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
1058 | 1057 | ||
1058 | #endif /* __KERNEL__ */ | ||
1059 | #endif /* _ASM_PARISC_UNISTD_H_ */ | 1059 | #endif /* _ASM_PARISC_UNISTD_H_ */ |
diff --git a/include/asm-powerpc/abs_addr.h b/include/asm-powerpc/abs_addr.h index c5c3259e0f86..4aa220718b19 100644 --- a/include/asm-powerpc/abs_addr.h +++ b/include/asm-powerpc/abs_addr.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define _ASM_POWERPC_ABS_ADDR_H | 2 | #define _ASM_POWERPC_ABS_ADDR_H |
3 | #ifdef __KERNEL__ | 3 | #ifdef __KERNEL__ |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | 5 | ||
7 | /* | 6 | /* |
8 | * c 2001 PPC 64 Team, IBM Corp | 7 | * c 2001 PPC 64 Team, IBM Corp |
diff --git a/include/asm-powerpc/cache.h b/include/asm-powerpc/cache.h index 6379c2df5c40..642be62cf393 100644 --- a/include/asm-powerpc/cache.h +++ b/include/asm-powerpc/cache.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | /* bytes per L1 cache line */ | 7 | /* bytes per L1 cache line */ |
9 | #if defined(CONFIG_8xx) || defined(CONFIG_403GCX) | 8 | #if defined(CONFIG_8xx) || defined(CONFIG_403GCX) |
diff --git a/include/asm-powerpc/dma-mapping.h b/include/asm-powerpc/dma-mapping.h index 2ac63f569592..2ab9baf78bb4 100644 --- a/include/asm-powerpc/dma-mapping.h +++ b/include/asm-powerpc/dma-mapping.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #define _ASM_DMA_MAPPING_H | 8 | #define _ASM_DMA_MAPPING_H |
9 | #ifdef __KERNEL__ | 9 | #ifdef __KERNEL__ |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #include <linux/types.h> | 11 | #include <linux/types.h> |
13 | #include <linux/cache.h> | 12 | #include <linux/cache.h> |
14 | /* need struct page definitions */ | 13 | /* need struct page definitions */ |
diff --git a/include/asm-powerpc/dma.h b/include/asm-powerpc/dma.h index 4bb57fe37097..7a4374bdbef4 100644 --- a/include/asm-powerpc/dma.h +++ b/include/asm-powerpc/dma.h | |||
@@ -22,7 +22,6 @@ | |||
22 | * with a grain of salt. | 22 | * with a grain of salt. |
23 | */ | 23 | */ |
24 | 24 | ||
25 | #include <linux/config.h> | ||
26 | #include <asm/io.h> | 25 | #include <asm/io.h> |
27 | #include <linux/spinlock.h> | 26 | #include <linux/spinlock.h> |
28 | #include <asm/system.h> | 27 | #include <asm/system.h> |
diff --git a/include/asm-powerpc/eeh.h b/include/asm-powerpc/eeh.h index 868c7139dbff..e9c86b1eedab 100644 --- a/include/asm-powerpc/eeh.h +++ b/include/asm-powerpc/eeh.h | |||
@@ -21,7 +21,6 @@ | |||
21 | #define _PPC64_EEH_H | 21 | #define _PPC64_EEH_H |
22 | #ifdef __KERNEL__ | 22 | #ifdef __KERNEL__ |
23 | 23 | ||
24 | #include <linux/config.h> | ||
25 | #include <linux/init.h> | 24 | #include <linux/init.h> |
26 | #include <linux/list.h> | 25 | #include <linux/list.h> |
27 | #include <linux/string.h> | 26 | #include <linux/string.h> |
diff --git a/include/asm-powerpc/elf.h b/include/asm-powerpc/elf.h index 94d228f9c6ac..99c18b71aa82 100644 --- a/include/asm-powerpc/elf.h +++ b/include/asm-powerpc/elf.h | |||
@@ -3,14 +3,14 @@ | |||
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | #include <linux/sched.h> /* for task_struct */ | 5 | #include <linux/sched.h> /* for task_struct */ |
6 | #include <asm/page.h> | ||
7 | #include <asm/string.h> | ||
6 | #endif | 8 | #endif |
7 | 9 | ||
8 | #include <asm/types.h> | 10 | #include <asm/types.h> |
9 | #include <asm/ptrace.h> | 11 | #include <asm/ptrace.h> |
10 | #include <asm/cputable.h> | 12 | #include <asm/cputable.h> |
11 | #include <asm/auxvec.h> | 13 | #include <asm/auxvec.h> |
12 | #include <asm/page.h> | ||
13 | #include <asm/string.h> | ||
14 | 14 | ||
15 | /* PowerPC relocations defined by the ABIs */ | 15 | /* PowerPC relocations defined by the ABIs */ |
16 | #define R_PPC_NONE 0 | 16 | #define R_PPC_NONE 0 |
@@ -129,7 +129,7 @@ typedef elf_greg_t32 elf_gregset_t32[ELF_NGREG]; | |||
129 | /* Assumption: ELF_ARCH == EM_PPC and ELF_CLASS == ELFCLASS32 */ | 129 | /* Assumption: ELF_ARCH == EM_PPC and ELF_CLASS == ELFCLASS32 */ |
130 | typedef elf_greg_t32 elf_greg_t; | 130 | typedef elf_greg_t32 elf_greg_t; |
131 | typedef elf_gregset_t32 elf_gregset_t; | 131 | typedef elf_gregset_t32 elf_gregset_t; |
132 | # define elf_addr_t u32 | 132 | # define elf_addr_t __u32 |
133 | #endif /* ELF_ARCH */ | 133 | #endif /* ELF_ARCH */ |
134 | 134 | ||
135 | /* Floating point registers */ | 135 | /* Floating point registers */ |
@@ -161,6 +161,7 @@ typedef elf_vrreg_t elf_vrregset_t[ELF_NVRREG]; | |||
161 | typedef elf_vrreg_t elf_vrregset_t32[ELF_NVRREG32]; | 161 | typedef elf_vrreg_t elf_vrregset_t32[ELF_NVRREG32]; |
162 | #endif | 162 | #endif |
163 | 163 | ||
164 | #ifdef __KERNEL__ | ||
164 | /* | 165 | /* |
165 | * This is used to ensure we don't load something for the wrong architecture. | 166 | * This is used to ensure we don't load something for the wrong architecture. |
166 | */ | 167 | */ |
@@ -176,8 +177,6 @@ typedef elf_vrreg_t elf_vrregset_t32[ELF_NVRREG32]; | |||
176 | 177 | ||
177 | #define ELF_ET_DYN_BASE (0x08000000) | 178 | #define ELF_ET_DYN_BASE (0x08000000) |
178 | 179 | ||
179 | #ifdef __KERNEL__ | ||
180 | |||
181 | /* Common routine for both 32-bit and 64-bit processes */ | 180 | /* Common routine for both 32-bit and 64-bit processes */ |
182 | static inline void ppc_elf_core_copy_regs(elf_gregset_t elf_regs, | 181 | static inline void ppc_elf_core_copy_regs(elf_gregset_t elf_regs, |
183 | struct pt_regs *regs) | 182 | struct pt_regs *regs) |
diff --git a/include/asm-powerpc/floppy.h b/include/asm-powerpc/floppy.h index 608164c39efb..7e2d169ee856 100644 --- a/include/asm-powerpc/floppy.h +++ b/include/asm-powerpc/floppy.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #define __ASM_POWERPC_FLOPPY_H | 11 | #define __ASM_POWERPC_FLOPPY_H |
12 | #ifdef __KERNEL__ | 12 | #ifdef __KERNEL__ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <asm/machdep.h> | 14 | #include <asm/machdep.h> |
16 | 15 | ||
17 | #define fd_inb(port) inb_p(port) | 16 | #define fd_inb(port) inb_p(port) |
diff --git a/include/asm-powerpc/hw_irq.h b/include/asm-powerpc/hw_irq.h index 26b89d859c56..ce0f7db63c16 100644 --- a/include/asm-powerpc/hw_irq.h +++ b/include/asm-powerpc/hw_irq.h | |||
@@ -6,7 +6,6 @@ | |||
6 | 6 | ||
7 | #ifdef __KERNEL__ | 7 | #ifdef __KERNEL__ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <linux/errno.h> | 9 | #include <linux/errno.h> |
11 | #include <asm/ptrace.h> | 10 | #include <asm/ptrace.h> |
12 | #include <asm/processor.h> | 11 | #include <asm/processor.h> |
diff --git a/include/asm-powerpc/ide.h b/include/asm-powerpc/ide.h index da5f640480cf..b09b42af6a1e 100644 --- a/include/asm-powerpc/ide.h +++ b/include/asm-powerpc/ide.h | |||
@@ -22,7 +22,6 @@ | |||
22 | #endif | 22 | #endif |
23 | 23 | ||
24 | #ifndef __powerpc64__ | 24 | #ifndef __powerpc64__ |
25 | #include <linux/config.h> | ||
26 | #include <linux/hdreg.h> | 25 | #include <linux/hdreg.h> |
27 | #include <linux/ioport.h> | 26 | #include <linux/ioport.h> |
28 | #include <asm/io.h> | 27 | #include <asm/io.h> |
diff --git a/include/asm-powerpc/iommu.h b/include/asm-powerpc/iommu.h index 18ca29e9105a..2acf7b29ef06 100644 --- a/include/asm-powerpc/iommu.h +++ b/include/asm-powerpc/iommu.h | |||
@@ -22,7 +22,6 @@ | |||
22 | #define _ASM_IOMMU_H | 22 | #define _ASM_IOMMU_H |
23 | #ifdef __KERNEL__ | 23 | #ifdef __KERNEL__ |
24 | 24 | ||
25 | #include <linux/config.h> | ||
26 | #include <asm/types.h> | 25 | #include <asm/types.h> |
27 | #include <linux/spinlock.h> | 26 | #include <linux/spinlock.h> |
28 | #include <linux/device.h> | 27 | #include <linux/device.h> |
diff --git a/include/asm-powerpc/irq.h b/include/asm-powerpc/irq.h index 7bc6d73b2823..1e9f25330307 100644 --- a/include/asm-powerpc/irq.h +++ b/include/asm-powerpc/irq.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * 2 of the License, or (at your option) any later version. | 9 | * 2 of the License, or (at your option) any later version. |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/threads.h> | 12 | #include <linux/threads.h> |
14 | 13 | ||
15 | #include <asm/types.h> | 14 | #include <asm/types.h> |
diff --git a/include/asm-powerpc/iseries/iseries_io.h b/include/asm-powerpc/iseries/iseries_io.h index 496aa852b617..f29009bd63c9 100644 --- a/include/asm-powerpc/iseries/iseries_io.h +++ b/include/asm-powerpc/iseries/iseries_io.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_POWERPC_ISERIES_ISERIES_IO_H | 1 | #ifndef _ASM_POWERPC_ISERIES_ISERIES_IO_H |
2 | #define _ASM_POWERPC_ISERIES_ISERIES_IO_H | 2 | #define _ASM_POWERPC_ISERIES_ISERIES_IO_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_PPC_ISERIES | 5 | #ifdef CONFIG_PPC_ISERIES |
7 | #include <linux/types.h> | 6 | #include <linux/types.h> |
diff --git a/include/asm-powerpc/machdep.h b/include/asm-powerpc/machdep.h index 0f9254c18914..3e7d37aa4a6d 100644 --- a/include/asm-powerpc/machdep.h +++ b/include/asm-powerpc/machdep.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * 2 of the License, or (at your option) any later version. | 9 | * 2 of the License, or (at your option) any later version. |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/seq_file.h> | 12 | #include <linux/seq_file.h> |
14 | #include <linux/init.h> | 13 | #include <linux/init.h> |
15 | #include <linux/dma-mapping.h> | 14 | #include <linux/dma-mapping.h> |
diff --git a/include/asm-powerpc/mmzone.h b/include/asm-powerpc/mmzone.h index 88d70bae7769..d484ca94cb7c 100644 --- a/include/asm-powerpc/mmzone.h +++ b/include/asm-powerpc/mmzone.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #define _ASM_MMZONE_H_ | 8 | #define _ASM_MMZONE_H_ |
9 | #ifdef __KERNEL__ | 9 | #ifdef __KERNEL__ |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | 11 | ||
13 | /* | 12 | /* |
14 | * generic non-linear memory support: | 13 | * generic non-linear memory support: |
diff --git a/include/asm-powerpc/paca.h b/include/asm-powerpc/paca.h index 706325f99a84..3c6f644d49b4 100644 --- a/include/asm-powerpc/paca.h +++ b/include/asm-powerpc/paca.h | |||
@@ -16,7 +16,6 @@ | |||
16 | #define _ASM_POWERPC_PACA_H | 16 | #define _ASM_POWERPC_PACA_H |
17 | #ifdef __KERNEL__ | 17 | #ifdef __KERNEL__ |
18 | 18 | ||
19 | #include <linux/config.h> | ||
20 | #include <asm/types.h> | 19 | #include <asm/types.h> |
21 | #include <asm/lppaca.h> | 20 | #include <asm/lppaca.h> |
22 | #include <asm/mmu.h> | 21 | #include <asm/mmu.h> |
diff --git a/include/asm-powerpc/page.h b/include/asm-powerpc/page.h index 2fbecebe1c92..f0469b961359 100644 --- a/include/asm-powerpc/page.h +++ b/include/asm-powerpc/page.h | |||
@@ -11,7 +11,6 @@ | |||
11 | */ | 11 | */ |
12 | 12 | ||
13 | #ifdef __KERNEL__ | 13 | #ifdef __KERNEL__ |
14 | #include <linux/config.h> | ||
15 | #include <asm/asm-compat.h> | 14 | #include <asm/asm-compat.h> |
16 | 15 | ||
17 | /* | 16 | /* |
diff --git a/include/asm-powerpc/pgtable.h b/include/asm-powerpc/pgtable.h index e9f1f4627e6b..964e312a1ffc 100644 --- a/include/asm-powerpc/pgtable.h +++ b/include/asm-powerpc/pgtable.h | |||
@@ -12,7 +12,6 @@ | |||
12 | */ | 12 | */ |
13 | 13 | ||
14 | #ifndef __ASSEMBLY__ | 14 | #ifndef __ASSEMBLY__ |
15 | #include <linux/config.h> | ||
16 | #include <linux/stddef.h> | 15 | #include <linux/stddef.h> |
17 | #include <asm/processor.h> /* For TASK_SIZE */ | 16 | #include <asm/processor.h> /* For TASK_SIZE */ |
18 | #include <asm/mmu.h> | 17 | #include <asm/mmu.h> |
diff --git a/include/asm-powerpc/ppc_asm.h b/include/asm-powerpc/ppc_asm.h index dd1c0a913d5f..a940cfe040da 100644 --- a/include/asm-powerpc/ppc_asm.h +++ b/include/asm-powerpc/ppc_asm.h | |||
@@ -5,7 +5,6 @@ | |||
5 | #define _ASM_POWERPC_PPC_ASM_H | 5 | #define _ASM_POWERPC_PPC_ASM_H |
6 | 6 | ||
7 | #include <linux/stringify.h> | 7 | #include <linux/stringify.h> |
8 | #include <linux/config.h> | ||
9 | #include <asm/asm-compat.h> | 8 | #include <asm/asm-compat.h> |
10 | 9 | ||
11 | #ifndef __ASSEMBLY__ | 10 | #ifndef __ASSEMBLY__ |
diff --git a/include/asm-powerpc/prom.h b/include/asm-powerpc/prom.h index 97ef1cd71a4d..f4e2ca6fd53f 100644 --- a/include/asm-powerpc/prom.h +++ b/include/asm-powerpc/prom.h | |||
@@ -15,7 +15,6 @@ | |||
15 | * as published by the Free Software Foundation; either version | 15 | * as published by the Free Software Foundation; either version |
16 | * 2 of the License, or (at your option) any later version. | 16 | * 2 of the License, or (at your option) any later version. |
17 | */ | 17 | */ |
18 | #include <linux/config.h> | ||
19 | #include <linux/types.h> | 18 | #include <linux/types.h> |
20 | #include <linux/proc_fs.h> | 19 | #include <linux/proc_fs.h> |
21 | #include <asm/atomic.h> | 20 | #include <asm/atomic.h> |
diff --git a/include/asm-powerpc/smp.h b/include/asm-powerpc/smp.h index 4a716f707cf6..068f119aa298 100644 --- a/include/asm-powerpc/smp.h +++ b/include/asm-powerpc/smp.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #define _ASM_POWERPC_SMP_H | 17 | #define _ASM_POWERPC_SMP_H |
18 | #ifdef __KERNEL__ | 18 | #ifdef __KERNEL__ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <linux/threads.h> | 20 | #include <linux/threads.h> |
22 | #include <linux/cpumask.h> | 21 | #include <linux/cpumask.h> |
23 | #include <linux/kernel.h> | 22 | #include <linux/kernel.h> |
diff --git a/include/asm-powerpc/smu.h b/include/asm-powerpc/smu.h index 2dc93632f210..51e65fc46a03 100644 --- a/include/asm-powerpc/smu.h +++ b/include/asm-powerpc/smu.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * Definitions for talking to the SMU chip in newer G5 PowerMacs | 5 | * Definitions for talking to the SMU chip in newer G5 PowerMacs |
6 | */ | 6 | */ |
7 | #ifdef __KERNEL__ | 7 | #ifdef __KERNEL__ |
8 | #include <linux/config.h> | ||
9 | #include <linux/list.h> | 8 | #include <linux/list.h> |
10 | #endif | 9 | #endif |
11 | #include <linux/types.h> | 10 | #include <linux/types.h> |
diff --git a/include/asm-powerpc/spu.h b/include/asm-powerpc/spu.h index 7cfcff3ef027..95713f397357 100644 --- a/include/asm-powerpc/spu.h +++ b/include/asm-powerpc/spu.h | |||
@@ -24,7 +24,6 @@ | |||
24 | #define _SPU_H | 24 | #define _SPU_H |
25 | #ifdef __KERNEL__ | 25 | #ifdef __KERNEL__ |
26 | 26 | ||
27 | #include <linux/config.h> | ||
28 | #include <linux/kref.h> | 27 | #include <linux/kref.h> |
29 | #include <linux/workqueue.h> | 28 | #include <linux/workqueue.h> |
30 | 29 | ||
diff --git a/include/asm-powerpc/thread_info.h b/include/asm-powerpc/thread_info.h index 88b553c6b26c..d339e2e88b11 100644 --- a/include/asm-powerpc/thread_info.h +++ b/include/asm-powerpc/thread_info.h | |||
@@ -21,7 +21,6 @@ | |||
21 | #define THREAD_SIZE (1 << THREAD_SHIFT) | 21 | #define THREAD_SIZE (1 << THREAD_SHIFT) |
22 | 22 | ||
23 | #ifndef __ASSEMBLY__ | 23 | #ifndef __ASSEMBLY__ |
24 | #include <linux/config.h> | ||
25 | #include <linux/cache.h> | 24 | #include <linux/cache.h> |
26 | #include <asm/processor.h> | 25 | #include <asm/processor.h> |
27 | #include <asm/page.h> | 26 | #include <asm/page.h> |
diff --git a/include/asm-powerpc/time.h b/include/asm-powerpc/time.h index 912118db13ae..4463148c659f 100644 --- a/include/asm-powerpc/time.h +++ b/include/asm-powerpc/time.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #define __POWERPC_TIME_H | 14 | #define __POWERPC_TIME_H |
15 | 15 | ||
16 | #ifdef __KERNEL__ | 16 | #ifdef __KERNEL__ |
17 | #include <linux/config.h> | ||
18 | #include <linux/types.h> | 17 | #include <linux/types.h> |
19 | #include <linux/percpu.h> | 18 | #include <linux/percpu.h> |
20 | 19 | ||
diff --git a/include/asm-powerpc/timex.h b/include/asm-powerpc/timex.h index c02d15aced91..3b9a8e786806 100644 --- a/include/asm-powerpc/timex.h +++ b/include/asm-powerpc/timex.h | |||
@@ -7,7 +7,6 @@ | |||
7 | * PowerPC architecture timex specifications | 7 | * PowerPC architecture timex specifications |
8 | */ | 8 | */ |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <asm/cputable.h> | 10 | #include <asm/cputable.h> |
12 | 11 | ||
13 | #define CLOCK_TICK_RATE 1024000 /* Underlying HZ */ | 12 | #define CLOCK_TICK_RATE 1024000 /* Underlying HZ */ |
diff --git a/include/asm-powerpc/tlb.h b/include/asm-powerpc/tlb.h index 601a53cf96d5..4e2a834683fb 100644 --- a/include/asm-powerpc/tlb.h +++ b/include/asm-powerpc/tlb.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #define _ASM_POWERPC_TLB_H | 13 | #define _ASM_POWERPC_TLB_H |
14 | #ifdef __KERNEL__ | 14 | #ifdef __KERNEL__ |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #ifndef __powerpc64__ | 16 | #ifndef __powerpc64__ |
18 | #include <asm/pgtable.h> | 17 | #include <asm/pgtable.h> |
19 | #endif | 18 | #endif |
diff --git a/include/asm-powerpc/tlbflush.h b/include/asm-powerpc/tlbflush.h index a2998eee37bb..93c7d0c7230f 100644 --- a/include/asm-powerpc/tlbflush.h +++ b/include/asm-powerpc/tlbflush.h | |||
@@ -17,7 +17,6 @@ | |||
17 | */ | 17 | */ |
18 | #ifdef __KERNEL__ | 18 | #ifdef __KERNEL__ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | 20 | ||
22 | struct mm_struct; | 21 | struct mm_struct; |
23 | 22 | ||
diff --git a/include/asm-powerpc/topology.h b/include/asm-powerpc/topology.h index 87362a05542b..19c575f39164 100644 --- a/include/asm-powerpc/topology.h +++ b/include/asm-powerpc/topology.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define _ASM_POWERPC_TOPOLOGY_H | 2 | #define _ASM_POWERPC_TOPOLOGY_H |
3 | #ifdef __KERNEL__ | 3 | #ifdef __KERNEL__ |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | 5 | ||
7 | struct sys_device; | 6 | struct sys_device; |
8 | struct device_node; | 7 | struct device_node; |
diff --git a/include/asm-powerpc/types.h b/include/asm-powerpc/types.h index baabba96e313..d6fb56b80453 100644 --- a/include/asm-powerpc/types.h +++ b/include/asm-powerpc/types.h | |||
@@ -64,7 +64,6 @@ typedef struct { | |||
64 | 64 | ||
65 | #ifndef __ASSEMBLY__ | 65 | #ifndef __ASSEMBLY__ |
66 | 66 | ||
67 | #include <linux/config.h> | ||
68 | 67 | ||
69 | typedef signed char s8; | 68 | typedef signed char s8; |
70 | typedef unsigned char u8; | 69 | typedef unsigned char u8; |
diff --git a/include/asm-powerpc/unistd.h b/include/asm-powerpc/unistd.h index edde2462bf52..eb66eae6616f 100644 --- a/include/asm-powerpc/unistd.h +++ b/include/asm-powerpc/unistd.h | |||
@@ -324,12 +324,12 @@ | |||
324 | #define __NR_get_robust_list 299 | 324 | #define __NR_get_robust_list 299 |
325 | #define __NR_set_robust_list 300 | 325 | #define __NR_set_robust_list 300 |
326 | 326 | ||
327 | #ifdef __KERNEL__ | ||
328 | |||
327 | #define __NR_syscalls 301 | 329 | #define __NR_syscalls 301 |
328 | 330 | ||
329 | #ifdef __KERNEL__ | ||
330 | #define __NR__exit __NR_exit | 331 | #define __NR__exit __NR_exit |
331 | #define NR_syscalls __NR_syscalls | 332 | #define NR_syscalls __NR_syscalls |
332 | #endif | ||
333 | 333 | ||
334 | #ifndef __ASSEMBLY__ | 334 | #ifndef __ASSEMBLY__ |
335 | 335 | ||
@@ -441,9 +441,7 @@ type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4, type5 arg5, type6 arg6 | |||
441 | __syscall_nr(6, type, name, arg1, arg2, arg3, arg4, arg5, arg6); \ | 441 | __syscall_nr(6, type, name, arg1, arg2, arg3, arg4, arg5, arg6); \ |
442 | } | 442 | } |
443 | 443 | ||
444 | #ifdef __KERNEL__ | ||
445 | 444 | ||
446 | #include <linux/config.h> | ||
447 | #include <linux/types.h> | 445 | #include <linux/types.h> |
448 | #include <linux/compiler.h> | 446 | #include <linux/compiler.h> |
449 | #include <linux/linkage.h> | 447 | #include <linux/linkage.h> |
@@ -499,8 +497,8 @@ extern int execve(const char *file, char **argv, char **envp); | |||
499 | #define cond_syscall(x) asm(".weak\t." #x "\n\t.set\t." #x ",.sys_ni_syscall") | 497 | #define cond_syscall(x) asm(".weak\t." #x "\n\t.set\t." #x ",.sys_ni_syscall") |
500 | #endif | 498 | #endif |
501 | 499 | ||
502 | #endif /* __KERNEL__ */ | ||
503 | 500 | ||
504 | #endif /* __ASSEMBLY__ */ | 501 | #endif /* __ASSEMBLY__ */ |
502 | #endif /* __KERNEL__ */ | ||
505 | 503 | ||
506 | #endif /* _ASM_PPC_UNISTD_H_ */ | 504 | #endif /* _ASM_PPC_UNISTD_H_ */ |
diff --git a/include/asm-powerpc/vga.h b/include/asm-powerpc/vga.h index f8d350aabf1a..a2eac409c1ec 100644 --- a/include/asm-powerpc/vga.h +++ b/include/asm-powerpc/vga.h | |||
@@ -12,7 +12,6 @@ | |||
12 | 12 | ||
13 | #include <asm/io.h> | 13 | #include <asm/io.h> |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | #if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_MDA_CONSOLE) | 16 | #if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_MDA_CONSOLE) |
18 | 17 | ||
@@ -42,9 +41,9 @@ static inline u16 scr_readw(volatile const u16 *addr) | |||
42 | extern unsigned long vgacon_remap_base; | 41 | extern unsigned long vgacon_remap_base; |
43 | 42 | ||
44 | #ifdef __powerpc64__ | 43 | #ifdef __powerpc64__ |
45 | #define VGA_MAP_MEM(x) ((unsigned long) ioremap((x), 0)) | 44 | #define VGA_MAP_MEM(x,s) ((unsigned long) ioremap((x), s)) |
46 | #else | 45 | #else |
47 | #define VGA_MAP_MEM(x) (x + vgacon_remap_base) | 46 | #define VGA_MAP_MEM(x,s) (x + vgacon_remap_base) |
48 | #endif | 47 | #endif |
49 | 48 | ||
50 | #define vga_readb(x) (*(x)) | 49 | #define vga_readb(x) (*(x)) |
diff --git a/include/asm-powerpc/vio.h b/include/asm-powerpc/vio.h index 0544ece51761..be14c59846f9 100644 --- a/include/asm-powerpc/vio.h +++ b/include/asm-powerpc/vio.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #define _ASM_POWERPC_VIO_H | 15 | #define _ASM_POWERPC_VIO_H |
16 | #ifdef __KERNEL__ | 16 | #ifdef __KERNEL__ |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | #include <linux/init.h> | 18 | #include <linux/init.h> |
20 | #include <linux/errno.h> | 19 | #include <linux/errno.h> |
21 | #include <linux/device.h> | 20 | #include <linux/device.h> |
diff --git a/include/asm-ppc/amigahw.h b/include/asm-ppc/amigahw.h index 8c98945e7dc1..90fd1274d727 100644 --- a/include/asm-ppc/amigahw.h +++ b/include/asm-ppc/amigahw.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #ifndef __ASMPPC_AMIGAHW_H | 2 | #ifndef __ASMPPC_AMIGAHW_H |
3 | #define __ASMPPC_AMIGAHW_H | 3 | #define __ASMPPC_AMIGAHW_H |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | #include <asm-m68k/amigahw.h> | 5 | #include <asm-m68k/amigahw.h> |
7 | 6 | ||
8 | #undef CHIP_PHYSADDR | 7 | #undef CHIP_PHYSADDR |
diff --git a/include/asm-ppc/bootinfo.h b/include/asm-ppc/bootinfo.h index 93d955c70d65..2ace4a74f263 100644 --- a/include/asm-ppc/bootinfo.h +++ b/include/asm-ppc/bootinfo.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _PPC_BOOTINFO_H | 9 | #ifndef _PPC_BOOTINFO_H |
10 | #define _PPC_BOOTINFO_H | 10 | #define _PPC_BOOTINFO_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <asm/page.h> | 12 | #include <asm/page.h> |
14 | 13 | ||
15 | #if defined(CONFIG_APUS) && !defined(__BOOTER__) | 14 | #if defined(CONFIG_APUS) && !defined(__BOOTER__) |
diff --git a/include/asm-ppc/commproc.h b/include/asm-ppc/commproc.h index 31f362966a58..3247bea5fc2b 100644 --- a/include/asm-ppc/commproc.h +++ b/include/asm-ppc/commproc.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #ifndef __CPM_8XX__ | 17 | #ifndef __CPM_8XX__ |
18 | #define __CPM_8XX__ | 18 | #define __CPM_8XX__ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <asm/8xx_immap.h> | 20 | #include <asm/8xx_immap.h> |
22 | #include <asm/ptrace.h> | 21 | #include <asm/ptrace.h> |
23 | 22 | ||
diff --git a/include/asm-ppc/ibm403.h b/include/asm-ppc/ibm403.h index bf6efa0417ab..c9c5d539cfdb 100644 --- a/include/asm-ppc/ibm403.h +++ b/include/asm-ppc/ibm403.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef __ASM_IBM403_H__ | 12 | #ifndef __ASM_IBM403_H__ |
13 | #define __ASM_IBM403_H__ | 13 | #define __ASM_IBM403_H__ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | #if defined(CONFIG_403GCX) | 16 | #if defined(CONFIG_403GCX) |
18 | 17 | ||
diff --git a/include/asm-ppc/ibm44x.h b/include/asm-ppc/ibm44x.h index 3acc382cc83f..7818b54b6e37 100644 --- a/include/asm-ppc/ibm44x.h +++ b/include/asm-ppc/ibm44x.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #ifndef __ASM_IBM44x_H__ | 17 | #ifndef __ASM_IBM44x_H__ |
18 | #define __ASM_IBM44x_H__ | 18 | #define __ASM_IBM44x_H__ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | 20 | ||
22 | #ifndef NR_BOARD_IRQS | 21 | #ifndef NR_BOARD_IRQS |
23 | #define NR_BOARD_IRQS 0 | 22 | #define NR_BOARD_IRQS 0 |
diff --git a/include/asm-ppc/ibm4xx.h b/include/asm-ppc/ibm4xx.h index 38f99710752b..cf62b69cb69a 100644 --- a/include/asm-ppc/ibm4xx.h +++ b/include/asm-ppc/ibm4xx.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #ifndef __ASM_IBM4XX_H__ | 14 | #ifndef __ASM_IBM4XX_H__ |
15 | #define __ASM_IBM4XX_H__ | 15 | #define __ASM_IBM4XX_H__ |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | #include <asm/types.h> | 17 | #include <asm/types.h> |
19 | 18 | ||
20 | #ifdef CONFIG_40x | 19 | #ifdef CONFIG_40x |
diff --git a/include/asm-ppc/io.h b/include/asm-ppc/io.h index b919d8fb7d98..89c6f1bc3aab 100644 --- a/include/asm-ppc/io.h +++ b/include/asm-ppc/io.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #ifndef _PPC_IO_H | 2 | #ifndef _PPC_IO_H |
3 | #define _PPC_IO_H | 3 | #define _PPC_IO_H |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | #include <linux/string.h> | 5 | #include <linux/string.h> |
7 | #include <linux/types.h> | 6 | #include <linux/types.h> |
8 | 7 | ||
diff --git a/include/asm-ppc/machdep.h b/include/asm-ppc/machdep.h index e1a0a7b213d7..da7746738aee 100644 --- a/include/asm-ppc/machdep.h +++ b/include/asm-ppc/machdep.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #ifndef _PPC_MACHDEP_H | 2 | #ifndef _PPC_MACHDEP_H |
3 | #define _PPC_MACHDEP_H | 3 | #define _PPC_MACHDEP_H |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | #include <linux/init.h> | 5 | #include <linux/init.h> |
7 | #include <linux/kexec.h> | 6 | #include <linux/kexec.h> |
8 | 7 | ||
diff --git a/include/asm-ppc/mmu.h b/include/asm-ppc/mmu.h index 9205db404c7a..0a70b05b3afb 100644 --- a/include/asm-ppc/mmu.h +++ b/include/asm-ppc/mmu.h | |||
@@ -6,7 +6,6 @@ | |||
6 | #ifndef _PPC_MMU_H_ | 6 | #ifndef _PPC_MMU_H_ |
7 | #define _PPC_MMU_H_ | 7 | #define _PPC_MMU_H_ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | #ifndef __ASSEMBLY__ | 10 | #ifndef __ASSEMBLY__ |
12 | 11 | ||
diff --git a/include/asm-ppc/mmu_context.h b/include/asm-ppc/mmu_context.h index 4f152cca13c1..94f2bf71310d 100644 --- a/include/asm-ppc/mmu_context.h +++ b/include/asm-ppc/mmu_context.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #ifndef __PPC_MMU_CONTEXT_H | 2 | #ifndef __PPC_MMU_CONTEXT_H |
3 | #define __PPC_MMU_CONTEXT_H | 3 | #define __PPC_MMU_CONTEXT_H |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | #include <asm/atomic.h> | 5 | #include <asm/atomic.h> |
7 | #include <asm/bitops.h> | 6 | #include <asm/bitops.h> |
8 | #include <asm/mmu.h> | 7 | #include <asm/mmu.h> |
diff --git a/include/asm-ppc/mpc8260.h b/include/asm-ppc/mpc8260.h index 6ba69a86b9dd..4b93481e7679 100644 --- a/include/asm-ppc/mpc8260.h +++ b/include/asm-ppc/mpc8260.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef __ASM_PPC_MPC8260_H__ | 8 | #ifndef __ASM_PPC_MPC8260_H__ |
9 | #define __ASM_PPC_MPC8260_H__ | 9 | #define __ASM_PPC_MPC8260_H__ |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | 11 | ||
13 | #ifdef CONFIG_8260 | 12 | #ifdef CONFIG_8260 |
14 | 13 | ||
diff --git a/include/asm-ppc/mpc83xx.h b/include/asm-ppc/mpc83xx.h index 3c23fc43bfbc..02ed2c325714 100644 --- a/include/asm-ppc/mpc83xx.h +++ b/include/asm-ppc/mpc83xx.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #ifndef __ASM_MPC83xx_H__ | 17 | #ifndef __ASM_MPC83xx_H__ |
18 | #define __ASM_MPC83xx_H__ | 18 | #define __ASM_MPC83xx_H__ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <asm/mmu.h> | 20 | #include <asm/mmu.h> |
22 | 21 | ||
23 | #ifdef CONFIG_83xx | 22 | #ifdef CONFIG_83xx |
diff --git a/include/asm-ppc/mpc85xx.h b/include/asm-ppc/mpc85xx.h index f47002a60edf..c25bdd9debf8 100644 --- a/include/asm-ppc/mpc85xx.h +++ b/include/asm-ppc/mpc85xx.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #ifndef __ASM_MPC85xx_H__ | 17 | #ifndef __ASM_MPC85xx_H__ |
18 | #define __ASM_MPC85xx_H__ | 18 | #define __ASM_MPC85xx_H__ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <asm/mmu.h> | 20 | #include <asm/mmu.h> |
22 | 21 | ||
23 | #ifdef CONFIG_85xx | 22 | #ifdef CONFIG_85xx |
diff --git a/include/asm-ppc/mpc8xx.h b/include/asm-ppc/mpc8xx.h index 3515a7fa6c89..adcce33f20ae 100644 --- a/include/asm-ppc/mpc8xx.h +++ b/include/asm-ppc/mpc8xx.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef __CONFIG_8xx_DEFS | 8 | #ifndef __CONFIG_8xx_DEFS |
9 | #define __CONFIG_8xx_DEFS | 9 | #define __CONFIG_8xx_DEFS |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | 11 | ||
13 | #ifdef CONFIG_8xx | 12 | #ifdef CONFIG_8xx |
14 | 13 | ||
diff --git a/include/asm-ppc/mv64x60.h b/include/asm-ppc/mv64x60.h index 4f2405b83612..663edbee3e91 100644 --- a/include/asm-ppc/mv64x60.h +++ b/include/asm-ppc/mv64x60.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #include <linux/init.h> | 17 | #include <linux/init.h> |
18 | #include <linux/pci.h> | 18 | #include <linux/pci.h> |
19 | #include <linux/slab.h> | 19 | #include <linux/slab.h> |
20 | #include <linux/config.h> | ||
21 | 20 | ||
22 | #include <asm/byteorder.h> | 21 | #include <asm/byteorder.h> |
23 | #include <asm/io.h> | 22 | #include <asm/io.h> |
diff --git a/include/asm-ppc/ocp.h b/include/asm-ppc/ocp.h index 983116f59d90..3be5d760ffcd 100644 --- a/include/asm-ppc/ocp.h +++ b/include/asm-ppc/ocp.h | |||
@@ -26,7 +26,6 @@ | |||
26 | 26 | ||
27 | #include <linux/init.h> | 27 | #include <linux/init.h> |
28 | #include <linux/list.h> | 28 | #include <linux/list.h> |
29 | #include <linux/config.h> | ||
30 | #include <linux/devfs_fs_kernel.h> | 29 | #include <linux/devfs_fs_kernel.h> |
31 | #include <linux/device.h> | 30 | #include <linux/device.h> |
32 | 31 | ||
diff --git a/include/asm-ppc/open_pic.h b/include/asm-ppc/open_pic.h index ec2f46629ca2..a4fe962d9f73 100644 --- a/include/asm-ppc/open_pic.h +++ b/include/asm-ppc/open_pic.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef _PPC_KERNEL_OPEN_PIC_H | 12 | #ifndef _PPC_KERNEL_OPEN_PIC_H |
13 | #define _PPC_KERNEL_OPEN_PIC_H | 13 | #define _PPC_KERNEL_OPEN_PIC_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <linux/irq.h> | 15 | #include <linux/irq.h> |
17 | 16 | ||
18 | #define OPENPIC_SIZE 0x40000 | 17 | #define OPENPIC_SIZE 0x40000 |
diff --git a/include/asm-ppc/page.h b/include/asm-ppc/page.h index 0fb68a0b0181..0b19af82507f 100644 --- a/include/asm-ppc/page.h +++ b/include/asm-ppc/page.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _PPC_PAGE_H | 1 | #ifndef _PPC_PAGE_H |
2 | #define _PPC_PAGE_H | 2 | #define _PPC_PAGE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/asm-compat.h> | 4 | #include <asm/asm-compat.h> |
6 | 5 | ||
7 | /* PAGE_SHIFT determines the page size */ | 6 | /* PAGE_SHIFT determines the page size */ |
@@ -15,7 +14,6 @@ | |||
15 | #define PAGE_MASK (~((1 << PAGE_SHIFT) - 1)) | 14 | #define PAGE_MASK (~((1 << PAGE_SHIFT) - 1)) |
16 | 15 | ||
17 | #ifdef __KERNEL__ | 16 | #ifdef __KERNEL__ |
18 | #include <linux/config.h> | ||
19 | 17 | ||
20 | /* This must match what is in arch/ppc/Makefile */ | 18 | /* This must match what is in arch/ppc/Makefile */ |
21 | #define PAGE_OFFSET CONFIG_KERNEL_START | 19 | #define PAGE_OFFSET CONFIG_KERNEL_START |
diff --git a/include/asm-ppc/pc_serial.h b/include/asm-ppc/pc_serial.h index 8f994f9f8857..81a2d0fdaf00 100644 --- a/include/asm-ppc/pc_serial.h +++ b/include/asm-ppc/pc_serial.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * anyone using any of those on a PPC platform. -- paulus | 9 | * anyone using any of those on a PPC platform. -- paulus |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | /* | 13 | /* |
15 | * This assumes you have a 1.8432 MHz clock for your UART. | 14 | * This assumes you have a 1.8432 MHz clock for your UART. |
diff --git a/include/asm-ppc/pgalloc.h b/include/asm-ppc/pgalloc.h index bdefd1c4a558..44d88a98e87c 100644 --- a/include/asm-ppc/pgalloc.h +++ b/include/asm-ppc/pgalloc.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #ifndef _PPC_PGALLOC_H | 2 | #ifndef _PPC_PGALLOC_H |
3 | #define _PPC_PGALLOC_H | 3 | #define _PPC_PGALLOC_H |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | #include <linux/threads.h> | 5 | #include <linux/threads.h> |
7 | 6 | ||
8 | extern void __bad_pte(pmd_t *pmd); | 7 | extern void __bad_pte(pmd_t *pmd); |
diff --git a/include/asm-ppc/pgtable.h b/include/asm-ppc/pgtable.h index 570b355162fa..9cb83679836c 100644 --- a/include/asm-ppc/pgtable.h +++ b/include/asm-ppc/pgtable.h | |||
@@ -4,7 +4,6 @@ | |||
4 | 4 | ||
5 | #include <asm-generic/4level-fixup.h> | 5 | #include <asm-generic/4level-fixup.h> |
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | #ifndef __ASSEMBLY__ | 8 | #ifndef __ASSEMBLY__ |
10 | #include <linux/sched.h> | 9 | #include <linux/sched.h> |
diff --git a/include/asm-ppc/ppc4xx_dma.h b/include/asm-ppc/ppc4xx_dma.h index 46a086fff816..935d1e05366b 100644 --- a/include/asm-ppc/ppc4xx_dma.h +++ b/include/asm-ppc/ppc4xx_dma.h | |||
@@ -24,7 +24,6 @@ | |||
24 | #ifndef __ASMPPC_PPC4xx_DMA_H | 24 | #ifndef __ASMPPC_PPC4xx_DMA_H |
25 | #define __ASMPPC_PPC4xx_DMA_H | 25 | #define __ASMPPC_PPC4xx_DMA_H |
26 | 26 | ||
27 | #include <linux/config.h> | ||
28 | #include <linux/types.h> | 27 | #include <linux/types.h> |
29 | #include <asm/mmu.h> | 28 | #include <asm/mmu.h> |
30 | #include <asm/ibm4xx.h> | 29 | #include <asm/ibm4xx.h> |
diff --git a/include/asm-ppc/ppc4xx_pic.h b/include/asm-ppc/ppc4xx_pic.h index c16c7f81cfd8..e44261206f8b 100644 --- a/include/asm-ppc/ppc4xx_pic.h +++ b/include/asm-ppc/ppc4xx_pic.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #ifndef __PPC4XX_PIC_H__ | 17 | #ifndef __PPC4XX_PIC_H__ |
18 | #define __PPC4XX_PIC_H__ | 18 | #define __PPC4XX_PIC_H__ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <linux/types.h> | 20 | #include <linux/types.h> |
22 | #include <linux/irq.h> | 21 | #include <linux/irq.h> |
23 | 22 | ||
diff --git a/include/asm-ppc/serial.h b/include/asm-ppc/serial.h index b74af5461564..8a59f8871f32 100644 --- a/include/asm-ppc/serial.h +++ b/include/asm-ppc/serial.h | |||
@@ -6,7 +6,6 @@ | |||
6 | #ifndef __ASM_SERIAL_H__ | 6 | #ifndef __ASM_SERIAL_H__ |
7 | #define __ASM_SERIAL_H__ | 7 | #define __ASM_SERIAL_H__ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | #if defined(CONFIG_EV64260) | 10 | #if defined(CONFIG_EV64260) |
12 | #include <platforms/ev64260.h> | 11 | #include <platforms/ev64260.h> |
diff --git a/include/asm-ppc/smp.h b/include/asm-ppc/smp.h index 30e9268a888c..0b7fa89589df 100644 --- a/include/asm-ppc/smp.h +++ b/include/asm-ppc/smp.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _PPC_SMP_H | 10 | #ifndef _PPC_SMP_H |
11 | #define _PPC_SMP_H | 11 | #define _PPC_SMP_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/kernel.h> | 13 | #include <linux/kernel.h> |
15 | #include <linux/bitops.h> | 14 | #include <linux/bitops.h> |
16 | #include <linux/errno.h> | 15 | #include <linux/errno.h> |
diff --git a/include/asm-ppc/time.h b/include/asm-ppc/time.h index c86112323c9f..f7eadf6ac806 100644 --- a/include/asm-ppc/time.h +++ b/include/asm-ppc/time.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef __ASM_TIME_H__ | 9 | #ifndef __ASM_TIME_H__ |
10 | #define __ASM_TIME_H__ | 10 | #define __ASM_TIME_H__ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/types.h> | 12 | #include <linux/types.h> |
14 | #include <linux/rtc.h> | 13 | #include <linux/rtc.h> |
15 | #include <linux/threads.h> | 14 | #include <linux/threads.h> |
diff --git a/include/asm-s390/bitops.h b/include/asm-s390/bitops.h index ca092ffb7a95..4d2b126ba159 100644 --- a/include/asm-s390/bitops.h +++ b/include/asm-s390/bitops.h | |||
@@ -12,7 +12,6 @@ | |||
12 | * Copyright (C) 1992, Linus Torvalds | 12 | * Copyright (C) 1992, Linus Torvalds |
13 | * | 13 | * |
14 | */ | 14 | */ |
15 | #include <linux/config.h> | ||
16 | #include <linux/compiler.h> | 15 | #include <linux/compiler.h> |
17 | 16 | ||
18 | /* | 17 | /* |
diff --git a/include/asm-s390/cmb.h b/include/asm-s390/cmb.h index dae1dd4fb937..2d09950a9c11 100644 --- a/include/asm-s390/cmb.h +++ b/include/asm-s390/cmb.h | |||
@@ -47,7 +47,7 @@ struct cmbdata { | |||
47 | /* reset channel measurement block */ | 47 | /* reset channel measurement block */ |
48 | #define BIODASDRESETCMB _IO(DASD_IOCTL_LETTER,34) | 48 | #define BIODASDRESETCMB _IO(DASD_IOCTL_LETTER,34) |
49 | /* read channel measurement data */ | 49 | /* read channel measurement data */ |
50 | #define BIODASDREADCMB _IOWR(DASD_IOCTL_LETTER,32,u64) | 50 | #define BIODASDREADCMB _IOWR(DASD_IOCTL_LETTER,32,__u64) |
51 | /* read channel measurement data */ | 51 | /* read channel measurement data */ |
52 | #define BIODASDREADALLCMB _IOWR(DASD_IOCTL_LETTER,33,struct cmbdata) | 52 | #define BIODASDREADALLCMB _IOWR(DASD_IOCTL_LETTER,33,struct cmbdata) |
53 | 53 | ||
diff --git a/include/asm-s390/debug.h b/include/asm-s390/debug.h index 23450ed4b571..7f1ef99fd1e1 100644 --- a/include/asm-s390/debug.h +++ b/include/asm-s390/debug.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef DEBUG_H | 9 | #ifndef DEBUG_H |
10 | #define DEBUG_H | 10 | #define DEBUG_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/fs.h> | 12 | #include <linux/fs.h> |
14 | #include <linux/string.h> | 13 | #include <linux/string.h> |
15 | 14 | ||
diff --git a/include/asm-s390/hardirq.h b/include/asm-s390/hardirq.h index 6792c559a124..e84b7ef54aac 100644 --- a/include/asm-s390/hardirq.h +++ b/include/asm-s390/hardirq.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef __ASM_HARDIRQ_H | 12 | #ifndef __ASM_HARDIRQ_H |
13 | #define __ASM_HARDIRQ_H | 13 | #define __ASM_HARDIRQ_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <linux/threads.h> | 15 | #include <linux/threads.h> |
17 | #include <linux/sched.h> | 16 | #include <linux/sched.h> |
18 | #include <linux/cache.h> | 17 | #include <linux/cache.h> |
diff --git a/include/asm-s390/idals.h b/include/asm-s390/idals.h index 8038858b86bb..e82c10efe65a 100644 --- a/include/asm-s390/idals.h +++ b/include/asm-s390/idals.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef _S390_IDALS_H | 13 | #ifndef _S390_IDALS_H |
14 | #define _S390_IDALS_H | 14 | #define _S390_IDALS_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/errno.h> | 16 | #include <linux/errno.h> |
18 | #include <linux/err.h> | 17 | #include <linux/err.h> |
19 | #include <linux/types.h> | 18 | #include <linux/types.h> |
diff --git a/include/asm-s390/io.h b/include/asm-s390/io.h index b05825dd16d7..d4614b35f423 100644 --- a/include/asm-s390/io.h +++ b/include/asm-s390/io.h | |||
@@ -86,20 +86,25 @@ extern void iounmap(void *addr); | |||
86 | #define readb(addr) (*(volatile unsigned char *) __io_virt(addr)) | 86 | #define readb(addr) (*(volatile unsigned char *) __io_virt(addr)) |
87 | #define readw(addr) (*(volatile unsigned short *) __io_virt(addr)) | 87 | #define readw(addr) (*(volatile unsigned short *) __io_virt(addr)) |
88 | #define readl(addr) (*(volatile unsigned int *) __io_virt(addr)) | 88 | #define readl(addr) (*(volatile unsigned int *) __io_virt(addr)) |
89 | #define readq(addr) (*(volatile unsigned long long *) __io_virt(addr)) | ||
89 | 90 | ||
90 | #define readb_relaxed(addr) readb(addr) | 91 | #define readb_relaxed(addr) readb(addr) |
91 | #define readw_relaxed(addr) readw(addr) | 92 | #define readw_relaxed(addr) readw(addr) |
92 | #define readl_relaxed(addr) readl(addr) | 93 | #define readl_relaxed(addr) readl(addr) |
94 | #define readq_relaxed(addr) readq(addr) | ||
93 | #define __raw_readb readb | 95 | #define __raw_readb readb |
94 | #define __raw_readw readw | 96 | #define __raw_readw readw |
95 | #define __raw_readl readl | 97 | #define __raw_readl readl |
98 | #define __raw_readq readq | ||
96 | 99 | ||
97 | #define writeb(b,addr) (*(volatile unsigned char *) __io_virt(addr) = (b)) | 100 | #define writeb(b,addr) (*(volatile unsigned char *) __io_virt(addr) = (b)) |
98 | #define writew(b,addr) (*(volatile unsigned short *) __io_virt(addr) = (b)) | 101 | #define writew(b,addr) (*(volatile unsigned short *) __io_virt(addr) = (b)) |
99 | #define writel(b,addr) (*(volatile unsigned int *) __io_virt(addr) = (b)) | 102 | #define writel(b,addr) (*(volatile unsigned int *) __io_virt(addr) = (b)) |
103 | #define writeq(b,addr) (*(volatile unsigned long long *) __io_virt(addr) = (b)) | ||
100 | #define __raw_writeb writeb | 104 | #define __raw_writeb writeb |
101 | #define __raw_writew writew | 105 | #define __raw_writew writew |
102 | #define __raw_writel writel | 106 | #define __raw_writel writel |
107 | #define __raw_writeq writeq | ||
103 | 108 | ||
104 | #define memset_io(a,b,c) memset(__io_virt(a),(b),(c)) | 109 | #define memset_io(a,b,c) memset(__io_virt(a),(b),(c)) |
105 | #define memcpy_fromio(a,b,c) memcpy((a),__io_virt(b),(c)) | 110 | #define memcpy_fromio(a,b,c) memcpy((a),__io_virt(b),(c)) |
diff --git a/include/asm-s390/local.h b/include/asm-s390/local.h index cf8189009c30..86745a1b29bb 100644 --- a/include/asm-s390/local.h +++ b/include/asm-s390/local.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_LOCAL_H | 1 | #ifndef _ASM_LOCAL_H |
2 | #define _ASM_LOCAL_H | 2 | #define _ASM_LOCAL_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/percpu.h> | 4 | #include <linux/percpu.h> |
6 | #include <asm/atomic.h> | 5 | #include <asm/atomic.h> |
7 | 6 | ||
diff --git a/include/asm-s390/lowcore.h b/include/asm-s390/lowcore.h index bea727904287..596c8b172104 100644 --- a/include/asm-s390/lowcore.h +++ b/include/asm-s390/lowcore.h | |||
@@ -124,7 +124,6 @@ | |||
124 | 124 | ||
125 | #ifndef __ASSEMBLY__ | 125 | #ifndef __ASSEMBLY__ |
126 | 126 | ||
127 | #include <linux/config.h> | ||
128 | #include <asm/processor.h> | 127 | #include <asm/processor.h> |
129 | #include <linux/types.h> | 128 | #include <linux/types.h> |
130 | #include <asm/sigp.h> | 129 | #include <asm/sigp.h> |
diff --git a/include/asm-s390/page.h b/include/asm-s390/page.h index 3b1138ac7e79..b2628dc5c490 100644 --- a/include/asm-s390/page.h +++ b/include/asm-s390/page.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _S390_PAGE_H | 9 | #ifndef _S390_PAGE_H |
10 | #define _S390_PAGE_H | 10 | #define _S390_PAGE_H |
11 | 11 | ||
12 | #include <asm/setup.h> | ||
13 | #include <asm/types.h> | 12 | #include <asm/types.h> |
14 | 13 | ||
15 | /* PAGE_SHIFT determines the page size */ | 14 | /* PAGE_SHIFT determines the page size */ |
@@ -20,6 +19,7 @@ | |||
20 | #define PAGE_DEFAULT_KEY (PAGE_DEFAULT_ACC << 4) | 19 | #define PAGE_DEFAULT_KEY (PAGE_DEFAULT_ACC << 4) |
21 | 20 | ||
22 | #ifdef __KERNEL__ | 21 | #ifdef __KERNEL__ |
22 | #include <asm/setup.h> | ||
23 | #ifndef __ASSEMBLY__ | 23 | #ifndef __ASSEMBLY__ |
24 | 24 | ||
25 | #ifndef __s390x__ | 25 | #ifndef __s390x__ |
@@ -189,9 +189,9 @@ page_get_storage_key(unsigned long addr) | |||
189 | #define VM_DATA_DEFAULT_FLAGS (VM_READ | VM_WRITE | VM_EXEC | \ | 189 | #define VM_DATA_DEFAULT_FLAGS (VM_READ | VM_WRITE | VM_EXEC | \ |
190 | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) | 190 | VM_MAYREAD | VM_MAYWRITE | VM_MAYEXEC) |
191 | 191 | ||
192 | #endif /* __KERNEL__ */ | ||
193 | |||
194 | #include <asm-generic/memory_model.h> | 192 | #include <asm-generic/memory_model.h> |
195 | #include <asm-generic/page.h> | 193 | #include <asm-generic/page.h> |
196 | 194 | ||
195 | #endif /* __KERNEL__ */ | ||
196 | |||
197 | #endif /* _S390_PAGE_H */ | 197 | #endif /* _S390_PAGE_H */ |
diff --git a/include/asm-s390/pgalloc.h b/include/asm-s390/pgalloc.h index e28aaf28e4a8..3002fda89d33 100644 --- a/include/asm-s390/pgalloc.h +++ b/include/asm-s390/pgalloc.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef _S390_PGALLOC_H | 13 | #ifndef _S390_PGALLOC_H |
14 | #define _S390_PGALLOC_H | 14 | #define _S390_PGALLOC_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/threads.h> | 16 | #include <linux/threads.h> |
18 | #include <linux/gfp.h> | 17 | #include <linux/gfp.h> |
19 | #include <linux/mm.h> | 18 | #include <linux/mm.h> |
diff --git a/include/asm-s390/posix_types.h b/include/asm-s390/posix_types.h index 61788de3c0c3..b94c98856e12 100644 --- a/include/asm-s390/posix_types.h +++ b/include/asm-s390/posix_types.h | |||
@@ -76,24 +76,36 @@ typedef struct { | |||
76 | } __kernel_fsid_t; | 76 | } __kernel_fsid_t; |
77 | 77 | ||
78 | 78 | ||
79 | #if defined(__KERNEL__) || !defined(__GLIBC__) || (__GLIBC__ < 2) | 79 | #ifdef __KERNEL__ |
80 | 80 | ||
81 | #ifndef _S390_BITOPS_H | 81 | #undef __FD_SET |
82 | #include <asm/bitops.h> | 82 | static inline void __FD_SET(unsigned long fd, __kernel_fd_set *fdsetp) |
83 | #endif | 83 | { |
84 | 84 | unsigned long _tmp = fd / __NFDBITS; | |
85 | #undef __FD_SET | 85 | unsigned long _rem = fd % __NFDBITS; |
86 | #define __FD_SET(fd,fdsetp) set_bit((fd),(fdsetp)->fds_bits) | 86 | fdsetp->fds_bits[_tmp] |= (1UL<<_rem); |
87 | 87 | } | |
88 | #undef __FD_CLR | 88 | |
89 | #define __FD_CLR(fd,fdsetp) clear_bit((fd),(fdsetp)->fds_bits) | 89 | #undef __FD_CLR |
90 | 90 | static inline void __FD_CLR(unsigned long fd, __kernel_fd_set *fdsetp) | |
91 | #undef __FD_ISSET | 91 | { |
92 | #define __FD_ISSET(fd,fdsetp) test_bit((fd),(fdsetp)->fds_bits) | 92 | unsigned long _tmp = fd / __NFDBITS; |
93 | unsigned long _rem = fd % __NFDBITS; | ||
94 | fdsetp->fds_bits[_tmp] &= ~(1UL<<_rem); | ||
95 | } | ||
96 | |||
97 | #undef __FD_ISSET | ||
98 | static inline int __FD_ISSET(unsigned long fd, const __kernel_fd_set *fdsetp) | ||
99 | { | ||
100 | unsigned long _tmp = fd / __NFDBITS; | ||
101 | unsigned long _rem = fd % __NFDBITS; | ||
102 | return (fdsetp->fds_bits[_tmp] & (1UL<<_rem)) != 0; | ||
103 | } | ||
93 | 104 | ||
94 | #undef __FD_ZERO | 105 | #undef __FD_ZERO |
95 | #define __FD_ZERO(fdsetp) (memset ((fdsetp), 0, sizeof(*(fd_set *)(fdsetp)))) | 106 | #define __FD_ZERO(fdsetp) \ |
107 | ((void) memset ((__ptr_t) (fdsetp), 0, sizeof (__kernel_fd_set))) | ||
96 | 108 | ||
97 | #endif /* defined(__KERNEL__) || !defined(__GLIBC__) || (__GLIBC__ < 2)*/ | 109 | #endif /* __KERNEL__ */ |
98 | 110 | ||
99 | #endif | 111 | #endif |
diff --git a/include/asm-s390/ptrace.h b/include/asm-s390/ptrace.h index a949cc077cc7..4d75d77b0f99 100644 --- a/include/asm-s390/ptrace.h +++ b/include/asm-s390/ptrace.h | |||
@@ -181,11 +181,8 @@ | |||
181 | #define PTRACE_OLDSETOPTIONS 21 | 181 | #define PTRACE_OLDSETOPTIONS 21 |
182 | 182 | ||
183 | #ifndef __ASSEMBLY__ | 183 | #ifndef __ASSEMBLY__ |
184 | #include <linux/config.h> | ||
185 | #include <linux/stddef.h> | 184 | #include <linux/stddef.h> |
186 | #include <linux/types.h> | 185 | #include <linux/types.h> |
187 | #include <asm/setup.h> | ||
188 | #include <asm/page.h> | ||
189 | 186 | ||
190 | typedef union | 187 | typedef union |
191 | { | 188 | { |
@@ -301,6 +298,9 @@ typedef struct | |||
301 | } s390_regs; | 298 | } s390_regs; |
302 | 299 | ||
303 | #ifdef __KERNEL__ | 300 | #ifdef __KERNEL__ |
301 | #include <asm/setup.h> | ||
302 | #include <asm/page.h> | ||
303 | |||
304 | /* | 304 | /* |
305 | * The pt_regs struct defines the way the registers are stored on | 305 | * The pt_regs struct defines the way the registers are stored on |
306 | * the stack during a system call. | 306 | * the stack during a system call. |
diff --git a/include/asm-s390/sfp-machine.h b/include/asm-s390/sfp-machine.h index 3c79b5384f44..de69dfa46fbb 100644 --- a/include/asm-s390/sfp-machine.h +++ b/include/asm-s390/sfp-machine.h | |||
@@ -25,7 +25,6 @@ | |||
25 | #ifndef _SFP_MACHINE_H | 25 | #ifndef _SFP_MACHINE_H |
26 | #define _SFP_MACHINE_H | 26 | #define _SFP_MACHINE_H |
27 | 27 | ||
28 | #include <linux/config.h> | ||
29 | 28 | ||
30 | #define _FP_W_TYPE_SIZE 32 | 29 | #define _FP_W_TYPE_SIZE 32 |
31 | #define _FP_W_TYPE unsigned long | 30 | #define _FP_W_TYPE unsigned long |
diff --git a/include/asm-s390/smp.h b/include/asm-s390/smp.h index 444dae5912e6..657646054c5e 100644 --- a/include/asm-s390/smp.h +++ b/include/asm-s390/smp.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef __ASM_SMP_H | 10 | #ifndef __ASM_SMP_H |
11 | #define __ASM_SMP_H | 11 | #define __ASM_SMP_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/threads.h> | 13 | #include <linux/threads.h> |
15 | #include <linux/cpumask.h> | 14 | #include <linux/cpumask.h> |
16 | #include <linux/bitops.h> | 15 | #include <linux/bitops.h> |
diff --git a/include/asm-s390/system.h b/include/asm-s390/system.h index 6a89dbb03c1e..71a0732cd518 100644 --- a/include/asm-s390/system.h +++ b/include/asm-s390/system.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef __ASM_SYSTEM_H | 11 | #ifndef __ASM_SYSTEM_H |
12 | #define __ASM_SYSTEM_H | 12 | #define __ASM_SYSTEM_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/kernel.h> | 14 | #include <linux/kernel.h> |
16 | #include <asm/types.h> | 15 | #include <asm/types.h> |
17 | #include <asm/ptrace.h> | 16 | #include <asm/ptrace.h> |
diff --git a/include/asm-s390/tlbflush.h b/include/asm-s390/tlbflush.h index 1bb73b0e61fa..73cd85bebfb2 100644 --- a/include/asm-s390/tlbflush.h +++ b/include/asm-s390/tlbflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _S390_TLBFLUSH_H | 1 | #ifndef _S390_TLBFLUSH_H |
2 | #define _S390_TLBFLUSH_H | 2 | #define _S390_TLBFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | #include <asm/processor.h> | 5 | #include <asm/processor.h> |
7 | 6 | ||
diff --git a/include/asm-s390/types.h b/include/asm-s390/types.h index 5738ad63537c..ae2951cc83ac 100644 --- a/include/asm-s390/types.h +++ b/include/asm-s390/types.h | |||
@@ -58,7 +58,6 @@ typedef __signed__ long saddr_t; | |||
58 | 58 | ||
59 | #ifndef __ASSEMBLY__ | 59 | #ifndef __ASSEMBLY__ |
60 | 60 | ||
61 | #include <linux/config.h> | ||
62 | 61 | ||
63 | typedef signed char s8; | 62 | typedef signed char s8; |
64 | typedef unsigned char u8; | 63 | typedef unsigned char u8; |
diff --git a/include/asm-s390/unistd.h b/include/asm-s390/unistd.h index 41c2792ff6b0..e21443d3ea1d 100644 --- a/include/asm-s390/unistd.h +++ b/include/asm-s390/unistd.h | |||
@@ -392,6 +392,8 @@ | |||
392 | 392 | ||
393 | #endif | 393 | #endif |
394 | 394 | ||
395 | #ifdef __KERNEL__ | ||
396 | |||
395 | /* user-visible error numbers are in the range -1 - -122: see <asm-s390/errno.h> */ | 397 | /* user-visible error numbers are in the range -1 - -122: see <asm-s390/errno.h> */ |
396 | 398 | ||
397 | #define __syscall_return(type, res) \ | 399 | #define __syscall_return(type, res) \ |
@@ -546,7 +548,6 @@ type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4, \ | |||
546 | __syscall_return(type,__res); \ | 548 | __syscall_return(type,__res); \ |
547 | } | 549 | } |
548 | 550 | ||
549 | #ifdef __KERNEL__ | ||
550 | #define __ARCH_WANT_IPC_PARSE_VERSION | 551 | #define __ARCH_WANT_IPC_PARSE_VERSION |
551 | #define __ARCH_WANT_OLD_READDIR | 552 | #define __ARCH_WANT_OLD_READDIR |
552 | #define __ARCH_WANT_SYS_ALARM | 553 | #define __ARCH_WANT_SYS_ALARM |
@@ -573,11 +574,9 @@ type name(type1 arg1, type2 arg2, type3 arg3, type4 arg4, \ | |||
573 | # define __ARCH_WANT_COMPAT_SYS_TIME | 574 | # define __ARCH_WANT_COMPAT_SYS_TIME |
574 | # define __ARCH_WANT_COMPAT_SYS_RT_SIGSUSPEND | 575 | # define __ARCH_WANT_COMPAT_SYS_RT_SIGSUSPEND |
575 | # endif | 576 | # endif |
576 | #endif | ||
577 | 577 | ||
578 | #ifdef __KERNEL_SYSCALLS__ | 578 | #ifdef __KERNEL_SYSCALLS__ |
579 | 579 | ||
580 | #include <linux/config.h> | ||
581 | #include <linux/compiler.h> | 580 | #include <linux/compiler.h> |
582 | #include <linux/types.h> | 581 | #include <linux/types.h> |
583 | #include <asm/ptrace.h> | 582 | #include <asm/ptrace.h> |
@@ -625,7 +624,7 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
625 | struct sigaction __user *oact, | 624 | struct sigaction __user *oact, |
626 | size_t sigsetsize); | 625 | size_t sigsetsize); |
627 | 626 | ||
628 | #endif | 627 | #endif /* __KERNEL_SYSCALLS__ */ |
629 | 628 | ||
630 | /* | 629 | /* |
631 | * "Conditional" syscalls | 630 | * "Conditional" syscalls |
@@ -635,4 +634,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
635 | */ | 634 | */ |
636 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 635 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
637 | 636 | ||
637 | #endif /* __KERNEL__ */ | ||
638 | #endif /* _ASM_S390_UNISTD_H_ */ | 638 | #endif /* _ASM_S390_UNISTD_H_ */ |
diff --git a/include/asm-s390/vtoc.h b/include/asm-s390/vtoc.h index d1de5b7ebb0b..3a5267d90d29 100644 --- a/include/asm-s390/vtoc.h +++ b/include/asm-s390/vtoc.h | |||
@@ -177,27 +177,27 @@ struct vtoc_format7_label | |||
177 | } __attribute__ ((packed)); | 177 | } __attribute__ ((packed)); |
178 | 178 | ||
179 | struct vtoc_cms_label { | 179 | struct vtoc_cms_label { |
180 | u8 label_id[4]; /* Label identifier */ | 180 | __u8 label_id[4]; /* Label identifier */ |
181 | u8 vol_id[6]; /* Volid */ | 181 | __u8 vol_id[6]; /* Volid */ |
182 | u16 version_id; /* Version identifier */ | 182 | __u16 version_id; /* Version identifier */ |
183 | u32 block_size; /* Disk block size */ | 183 | __u32 block_size; /* Disk block size */ |
184 | u32 origin_ptr; /* Disk origin pointer */ | 184 | __u32 origin_ptr; /* Disk origin pointer */ |
185 | u32 usable_count; /* Number of usable cylinders/blocks */ | 185 | __u32 usable_count; /* Number of usable cylinders/blocks */ |
186 | u32 formatted_count; /* Maximum number of formatted cylinders/ | 186 | __u32 formatted_count; /* Maximum number of formatted cylinders/ |
187 | * blocks */ | 187 | * blocks */ |
188 | u32 block_count; /* Disk size in CMS blocks */ | 188 | __u32 block_count; /* Disk size in CMS blocks */ |
189 | u32 used_count; /* Number of CMS blocks in use */ | 189 | __u32 used_count; /* Number of CMS blocks in use */ |
190 | u32 fst_size; /* File Status Table (FST) size */ | 190 | __u32 fst_size; /* File Status Table (FST) size */ |
191 | u32 fst_count; /* Number of FSTs per CMS block */ | 191 | __u32 fst_count; /* Number of FSTs per CMS block */ |
192 | u8 format_date[6]; /* Disk FORMAT date */ | 192 | __u8 format_date[6]; /* Disk FORMAT date */ |
193 | u8 reserved1[2]; | 193 | __u8 reserved1[2]; |
194 | u32 disk_offset; /* Disk offset when reserved*/ | 194 | __u32 disk_offset; /* Disk offset when reserved*/ |
195 | u32 map_block; /* Allocation Map Block with next hole */ | 195 | __u32 map_block; /* Allocation Map Block with next hole */ |
196 | u32 hblk_disp; /* Displacement into HBLK data of next hole */ | 196 | __u32 hblk_disp; /* Displacement into HBLK data of next hole */ |
197 | u32 user_disp; /* Displacement into user part of Allocation | 197 | __u32 user_disp; /* Displacement into user part of Allocation |
198 | * map */ | 198 | * map */ |
199 | u8 reserved2[4]; | 199 | __u8 reserved2[4]; |
200 | u8 segment_name[8]; /* Name of shared segment */ | 200 | __u8 segment_name[8]; /* Name of shared segment */ |
201 | } __attribute__ ((packed)); | 201 | } __attribute__ ((packed)); |
202 | 202 | ||
203 | #endif /* _ASM_S390_VTOC_H */ | 203 | #endif /* _ASM_S390_VTOC_H */ |
diff --git a/include/asm-s390/z90crypt.h b/include/asm-s390/z90crypt.h new file mode 100644 index 000000000000..31a2439b07bd --- /dev/null +++ b/include/asm-s390/z90crypt.h | |||
@@ -0,0 +1,212 @@ | |||
1 | /* | ||
2 | * include/asm-s390/z90crypt.h | ||
3 | * | ||
4 | * z90crypt 1.3.3 (user-visible header) | ||
5 | * | ||
6 | * Copyright (C) 2001, 2005 IBM Corporation | ||
7 | * Author(s): Robert Burroughs | ||
8 | * Eric Rossman (edrossma@us.ibm.com) | ||
9 | * | ||
10 | * Hotplug & misc device support: Jochen Roehrig (roehrig@de.ibm.com) | ||
11 | * | ||
12 | * This program is free software; you can redistribute it and/or modify | ||
13 | * it under the terms of the GNU General Public License as published by | ||
14 | * the Free Software Foundation; either version 2, or (at your option) | ||
15 | * any later version. | ||
16 | * | ||
17 | * This program is distributed in the hope that it will be useful, | ||
18 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
19 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
20 | * GNU General Public License for more details. | ||
21 | * | ||
22 | * You should have received a copy of the GNU General Public License | ||
23 | * along with this program; if not, write to the Free Software | ||
24 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. | ||
25 | */ | ||
26 | |||
27 | #ifndef __ASM_S390_Z90CRYPT_H | ||
28 | #define __ASM_S390_Z90CRYPT_H | ||
29 | #include <linux/ioctl.h> | ||
30 | |||
31 | #define z90crypt_VERSION 1 | ||
32 | #define z90crypt_RELEASE 3 // 2 = PCIXCC, 3 = rewrite for coding standards | ||
33 | #define z90crypt_VARIANT 3 // 3 = CEX2A support | ||
34 | |||
35 | /** | ||
36 | * struct ica_rsa_modexpo | ||
37 | * | ||
38 | * Requirements: | ||
39 | * - outputdatalength is at least as large as inputdatalength. | ||
40 | * - All key parts are right justified in their fields, padded on | ||
41 | * the left with zeroes. | ||
42 | * - length(b_key) = inputdatalength | ||
43 | * - length(n_modulus) = inputdatalength | ||
44 | */ | ||
45 | struct ica_rsa_modexpo { | ||
46 | char __user * inputdata; | ||
47 | unsigned int inputdatalength; | ||
48 | char __user * outputdata; | ||
49 | unsigned int outputdatalength; | ||
50 | char __user * b_key; | ||
51 | char __user * n_modulus; | ||
52 | }; | ||
53 | |||
54 | /** | ||
55 | * struct ica_rsa_modexpo_crt | ||
56 | * | ||
57 | * Requirements: | ||
58 | * - inputdatalength is even. | ||
59 | * - outputdatalength is at least as large as inputdatalength. | ||
60 | * - All key parts are right justified in their fields, padded on | ||
61 | * the left with zeroes. | ||
62 | * - length(bp_key) = inputdatalength/2 + 8 | ||
63 | * - length(bq_key) = inputdatalength/2 | ||
64 | * - length(np_key) = inputdatalength/2 + 8 | ||
65 | * - length(nq_key) = inputdatalength/2 | ||
66 | * - length(u_mult_inv) = inputdatalength/2 + 8 | ||
67 | */ | ||
68 | struct ica_rsa_modexpo_crt { | ||
69 | char __user * inputdata; | ||
70 | unsigned int inputdatalength; | ||
71 | char __user * outputdata; | ||
72 | unsigned int outputdatalength; | ||
73 | char __user * bp_key; | ||
74 | char __user * bq_key; | ||
75 | char __user * np_prime; | ||
76 | char __user * nq_prime; | ||
77 | char __user * u_mult_inv; | ||
78 | }; | ||
79 | |||
80 | #define Z90_IOCTL_MAGIC 'z' // NOTE: Need to allocate from linux folks | ||
81 | |||
82 | /** | ||
83 | * Interface notes: | ||
84 | * | ||
85 | * The ioctl()s which are implemented (along with relevant details) | ||
86 | * are: | ||
87 | * | ||
88 | * ICARSAMODEXPO | ||
89 | * Perform an RSA operation using a Modulus-Exponent pair | ||
90 | * This takes an ica_rsa_modexpo struct as its arg. | ||
91 | * | ||
92 | * NOTE: please refer to the comments preceding this structure | ||
93 | * for the implementation details for the contents of the | ||
94 | * block | ||
95 | * | ||
96 | * ICARSACRT | ||
97 | * Perform an RSA operation using a Chinese-Remainder Theorem key | ||
98 | * This takes an ica_rsa_modexpo_crt struct as its arg. | ||
99 | * | ||
100 | * NOTE: please refer to the comments preceding this structure | ||
101 | * for the implementation details for the contents of the | ||
102 | * block | ||
103 | * | ||
104 | * Z90STAT_TOTALCOUNT | ||
105 | * Return an integer count of all device types together. | ||
106 | * | ||
107 | * Z90STAT_PCICACOUNT | ||
108 | * Return an integer count of all PCICAs. | ||
109 | * | ||
110 | * Z90STAT_PCICCCOUNT | ||
111 | * Return an integer count of all PCICCs. | ||
112 | * | ||
113 | * Z90STAT_PCIXCCMCL2COUNT | ||
114 | * Return an integer count of all MCL2 PCIXCCs. | ||
115 | * | ||
116 | * Z90STAT_PCIXCCMCL3COUNT | ||
117 | * Return an integer count of all MCL3 PCIXCCs. | ||
118 | * | ||
119 | * Z90STAT_CEX2CCOUNT | ||
120 | * Return an integer count of all CEX2Cs. | ||
121 | * | ||
122 | * Z90STAT_CEX2ACOUNT | ||
123 | * Return an integer count of all CEX2As. | ||
124 | * | ||
125 | * Z90STAT_REQUESTQ_COUNT | ||
126 | * Return an integer count of the number of entries waiting to be | ||
127 | * sent to a device. | ||
128 | * | ||
129 | * Z90STAT_PENDINGQ_COUNT | ||
130 | * Return an integer count of the number of entries sent to a | ||
131 | * device awaiting the reply. | ||
132 | * | ||
133 | * Z90STAT_TOTALOPEN_COUNT | ||
134 | * Return an integer count of the number of open file handles. | ||
135 | * | ||
136 | * Z90STAT_DOMAIN_INDEX | ||
137 | * Return the integer value of the Cryptographic Domain. | ||
138 | * | ||
139 | * Z90STAT_STATUS_MASK | ||
140 | * Return an 64 element array of unsigned chars for the status of | ||
141 | * all devices. | ||
142 | * 0x01: PCICA | ||
143 | * 0x02: PCICC | ||
144 | * 0x03: PCIXCC_MCL2 | ||
145 | * 0x04: PCIXCC_MCL3 | ||
146 | * 0x05: CEX2C | ||
147 | * 0x06: CEX2A | ||
148 | * 0x0d: device is disabled via the proc filesystem | ||
149 | * | ||
150 | * Z90STAT_QDEPTH_MASK | ||
151 | * Return an 64 element array of unsigned chars for the queue | ||
152 | * depth of all devices. | ||
153 | * | ||
154 | * Z90STAT_PERDEV_REQCNT | ||
155 | * Return an 64 element array of unsigned integers for the number | ||
156 | * of successfully completed requests per device since the device | ||
157 | * was detected and made available. | ||
158 | * | ||
159 | * ICAZ90STATUS (deprecated) | ||
160 | * Return some device driver status in a ica_z90_status struct | ||
161 | * This takes an ica_z90_status struct as its arg. | ||
162 | * | ||
163 | * NOTE: this ioctl() is deprecated, and has been replaced with | ||
164 | * single ioctl()s for each type of status being requested | ||
165 | * | ||
166 | * Z90STAT_PCIXCCCOUNT (deprecated) | ||
167 | * Return an integer count of all PCIXCCs (MCL2 + MCL3). | ||
168 | * This is DEPRECATED now that MCL3 PCIXCCs are treated differently from | ||
169 | * MCL2 PCIXCCs. | ||
170 | * | ||
171 | * Z90QUIESCE (not recommended) | ||
172 | * Quiesce the driver. This is intended to stop all new | ||
173 | * requests from being processed. Its use is NOT recommended, | ||
174 | * except in circumstances where there is no other way to stop | ||
175 | * callers from accessing the driver. Its original use was to | ||
176 | * allow the driver to be "drained" of work in preparation for | ||
177 | * a system shutdown. | ||
178 | * | ||
179 | * NOTE: once issued, this ban on new work cannot be undone | ||
180 | * except by unloading and reloading the driver. | ||
181 | */ | ||
182 | |||
183 | /** | ||
184 | * Supported ioctl calls | ||
185 | */ | ||
186 | #define ICARSAMODEXPO _IOC(_IOC_READ|_IOC_WRITE, Z90_IOCTL_MAGIC, 0x05, 0) | ||
187 | #define ICARSACRT _IOC(_IOC_READ|_IOC_WRITE, Z90_IOCTL_MAGIC, 0x06, 0) | ||
188 | |||
189 | /* DEPRECATED status calls (bound for removal at some point) */ | ||
190 | #define ICAZ90STATUS _IOR(Z90_IOCTL_MAGIC, 0x10, struct ica_z90_status) | ||
191 | #define Z90STAT_PCIXCCCOUNT _IOR(Z90_IOCTL_MAGIC, 0x43, int) | ||
192 | |||
193 | /* unrelated to ICA callers */ | ||
194 | #define Z90QUIESCE _IO(Z90_IOCTL_MAGIC, 0x11) | ||
195 | |||
196 | /* New status calls */ | ||
197 | #define Z90STAT_TOTALCOUNT _IOR(Z90_IOCTL_MAGIC, 0x40, int) | ||
198 | #define Z90STAT_PCICACOUNT _IOR(Z90_IOCTL_MAGIC, 0x41, int) | ||
199 | #define Z90STAT_PCICCCOUNT _IOR(Z90_IOCTL_MAGIC, 0x42, int) | ||
200 | #define Z90STAT_PCIXCCMCL2COUNT _IOR(Z90_IOCTL_MAGIC, 0x4b, int) | ||
201 | #define Z90STAT_PCIXCCMCL3COUNT _IOR(Z90_IOCTL_MAGIC, 0x4c, int) | ||
202 | #define Z90STAT_CEX2CCOUNT _IOR(Z90_IOCTL_MAGIC, 0x4d, int) | ||
203 | #define Z90STAT_CEX2ACOUNT _IOR(Z90_IOCTL_MAGIC, 0x4e, int) | ||
204 | #define Z90STAT_REQUESTQ_COUNT _IOR(Z90_IOCTL_MAGIC, 0x44, int) | ||
205 | #define Z90STAT_PENDINGQ_COUNT _IOR(Z90_IOCTL_MAGIC, 0x45, int) | ||
206 | #define Z90STAT_TOTALOPEN_COUNT _IOR(Z90_IOCTL_MAGIC, 0x46, int) | ||
207 | #define Z90STAT_DOMAIN_INDEX _IOR(Z90_IOCTL_MAGIC, 0x47, int) | ||
208 | #define Z90STAT_STATUS_MASK _IOR(Z90_IOCTL_MAGIC, 0x48, char[64]) | ||
209 | #define Z90STAT_QDEPTH_MASK _IOR(Z90_IOCTL_MAGIC, 0x49, char[64]) | ||
210 | #define Z90STAT_PERDEV_REQCNT _IOR(Z90_IOCTL_MAGIC, 0x4a, int[64]) | ||
211 | |||
212 | #endif /* __ASM_S390_Z90CRYPT_H */ | ||
diff --git a/include/asm-sh/bug.h b/include/asm-sh/bug.h index 70508a360cd6..1b4fc52a59e8 100644 --- a/include/asm-sh/bug.h +++ b/include/asm-sh/bug.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_SH_BUG_H | 1 | #ifndef __ASM_SH_BUG_H |
2 | #define __ASM_SH_BUG_H | 2 | #define __ASM_SH_BUG_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_BUG | 5 | #ifdef CONFIG_BUG |
7 | /* | 6 | /* |
diff --git a/include/asm-sh/checksum.h b/include/asm-sh/checksum.h index 5ebd0f24299e..fa03b30c4269 100644 --- a/include/asm-sh/checksum.h +++ b/include/asm-sh/checksum.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * Copyright (C) 1999 by Kaz Kojima & Niibe Yutaka | 9 | * Copyright (C) 1999 by Kaz Kojima & Niibe Yutaka |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/in6.h> | 12 | #include <linux/in6.h> |
14 | 13 | ||
15 | /* | 14 | /* |
diff --git a/include/asm-sh/dma-mapping.h b/include/asm-sh/dma-mapping.h index 48f1f42c5d14..124968f9866e 100644 --- a/include/asm-sh/dma-mapping.h +++ b/include/asm-sh/dma-mapping.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_SH_DMA_MAPPING_H | 1 | #ifndef __ASM_SH_DMA_MAPPING_H |
2 | #define __ASM_SH_DMA_MAPPING_H | 2 | #define __ASM_SH_DMA_MAPPING_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | #include <asm/scatterlist.h> | 5 | #include <asm/scatterlist.h> |
7 | #include <asm/cacheflush.h> | 6 | #include <asm/cacheflush.h> |
diff --git a/include/asm-sh/dma.h b/include/asm-sh/dma.h index a118a0d43053..e62a6d0ed932 100644 --- a/include/asm-sh/dma.h +++ b/include/asm-sh/dma.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #define __ASM_SH_DMA_H | 11 | #define __ASM_SH_DMA_H |
12 | #ifdef __KERNEL__ | 12 | #ifdef __KERNEL__ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/spinlock.h> | 14 | #include <linux/spinlock.h> |
16 | #include <linux/wait.h> | 15 | #include <linux/wait.h> |
17 | #include <linux/sysdev.h> | 16 | #include <linux/sysdev.h> |
diff --git a/include/asm-sh/fixmap.h b/include/asm-sh/fixmap.h index 509224bdba28..412bccaa07e6 100644 --- a/include/asm-sh/fixmap.h +++ b/include/asm-sh/fixmap.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef _ASM_FIXMAP_H | 13 | #ifndef _ASM_FIXMAP_H |
14 | #define _ASM_FIXMAP_H | 14 | #define _ASM_FIXMAP_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/kernel.h> | 16 | #include <linux/kernel.h> |
18 | #include <asm/page.h> | 17 | #include <asm/page.h> |
19 | #ifdef CONFIG_HIGHMEM | 18 | #ifdef CONFIG_HIGHMEM |
diff --git a/include/asm-sh/hardirq.h b/include/asm-sh/hardirq.h index f2fdf0f760e5..715ee237fc77 100644 --- a/include/asm-sh/hardirq.h +++ b/include/asm-sh/hardirq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_SH_HARDIRQ_H | 1 | #ifndef __ASM_SH_HARDIRQ_H |
2 | #define __ASM_SH_HARDIRQ_H | 2 | #define __ASM_SH_HARDIRQ_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/threads.h> | 4 | #include <linux/threads.h> |
6 | #include <linux/irq.h> | 5 | #include <linux/irq.h> |
7 | 6 | ||
diff --git a/include/asm-sh/hd64461/hd64461.h b/include/asm-sh/hd64461/hd64461.h index c457ca277a42..87f13d24c630 100644 --- a/include/asm-sh/hd64461/hd64461.h +++ b/include/asm-sh/hd64461/hd64461.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * Copyright (C) 2000 YAEGASHI Takeshi | 5 | * Copyright (C) 2000 YAEGASHI Takeshi |
6 | * Hitachi HD64461 companion chip support | 6 | * Hitachi HD64461 companion chip support |
7 | */ | 7 | */ |
8 | #include <linux/config.h> | ||
9 | 8 | ||
10 | /* Constants for PCMCIA mappings */ | 9 | /* Constants for PCMCIA mappings */ |
11 | #define HD64461_PCC_WINDOW 0x01000000 | 10 | #define HD64461_PCC_WINDOW 0x01000000 |
diff --git a/include/asm-sh/hd64465/hd64465.h b/include/asm-sh/hd64465/hd64465.h index c672032b72c9..cfd0e803d2a2 100644 --- a/include/asm-sh/hd64465/hd64465.h +++ b/include/asm-sh/hd64465/hd64465.h | |||
@@ -11,7 +11,6 @@ | |||
11 | * Derived from <asm/hd64461.h> which bore the message: | 11 | * Derived from <asm/hd64461.h> which bore the message: |
12 | * Copyright (C) 2000 YAEGASHI Takeshi | 12 | * Copyright (C) 2000 YAEGASHI Takeshi |
13 | */ | 13 | */ |
14 | #include <linux/config.h> | ||
15 | #include <asm/io.h> | 14 | #include <asm/io.h> |
16 | #include <asm/irq.h> | 15 | #include <asm/irq.h> |
17 | 16 | ||
diff --git a/include/asm-sh/ide.h b/include/asm-sh/ide.h index 711dad4cb48b..9f8e9142dc33 100644 --- a/include/asm-sh/ide.h +++ b/include/asm-sh/ide.h | |||
@@ -14,7 +14,6 @@ | |||
14 | 14 | ||
15 | #ifdef __KERNEL__ | 15 | #ifdef __KERNEL__ |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | 17 | ||
19 | #define ide_default_io_ctl(base) (0) | 18 | #define ide_default_io_ctl(base) (0) |
20 | 19 | ||
diff --git a/include/asm-sh/io.h b/include/asm-sh/io.h index 2c3afe71323d..894e64b2d5f0 100644 --- a/include/asm-sh/io.h +++ b/include/asm-sh/io.h | |||
@@ -23,7 +23,6 @@ | |||
23 | * inb by default expands to _inb, but the machine specific code may | 23 | * inb by default expands to _inb, but the machine specific code may |
24 | * define it to __inb if it chooses. | 24 | * define it to __inb if it chooses. |
25 | */ | 25 | */ |
26 | #include <linux/config.h> | ||
27 | #include <asm/cache.h> | 26 | #include <asm/cache.h> |
28 | #include <asm/system.h> | 27 | #include <asm/system.h> |
29 | #include <asm/addrspace.h> | 28 | #include <asm/addrspace.h> |
diff --git a/include/asm-sh/irq.h b/include/asm-sh/irq.h index 42b8394c04ed..611e67cd0627 100644 --- a/include/asm-sh/irq.h +++ b/include/asm-sh/irq.h | |||
@@ -11,7 +11,6 @@ | |||
11 | * | 11 | * |
12 | */ | 12 | */ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <asm/machvec.h> | 14 | #include <asm/machvec.h> |
16 | #include <asm/ptrace.h> /* for pt_regs */ | 15 | #include <asm/ptrace.h> /* for pt_regs */ |
17 | 16 | ||
diff --git a/include/asm-sh/keyboard.h b/include/asm-sh/keyboard.h index 1103df003243..31dcc4fa5f28 100644 --- a/include/asm-sh/keyboard.h +++ b/include/asm-sh/keyboard.h | |||
@@ -5,7 +5,6 @@ | |||
5 | */ | 5 | */ |
6 | 6 | ||
7 | #include <linux/kd.h> | 7 | #include <linux/kd.h> |
8 | #include <linux/config.h> | ||
9 | #include <asm/machvec.h> | 8 | #include <asm/machvec.h> |
10 | 9 | ||
11 | #ifdef CONFIG_SH_MPC1211 | 10 | #ifdef CONFIG_SH_MPC1211 |
diff --git a/include/asm-sh/kmap_types.h b/include/asm-sh/kmap_types.h index 2492ba07148f..84d565c696be 100644 --- a/include/asm-sh/kmap_types.h +++ b/include/asm-sh/kmap_types.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | /* Dummy header just to define km_type. */ | 4 | /* Dummy header just to define km_type. */ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | #ifdef CONFIG_DEBUG_HIGHMEM | 7 | #ifdef CONFIG_DEBUG_HIGHMEM |
9 | # define D(n) __KM_FENCE_##n , | 8 | # define D(n) __KM_FENCE_##n , |
diff --git a/include/asm-sh/machvec.h b/include/asm-sh/machvec.h index 550c50a7359e..550501fa4fed 100644 --- a/include/asm-sh/machvec.h +++ b/include/asm-sh/machvec.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _ASM_SH_MACHVEC_H | 10 | #ifndef _ASM_SH_MACHVEC_H |
11 | #define _ASM_SH_MACHVEC_H 1 | 11 | #define _ASM_SH_MACHVEC_H 1 |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/types.h> | 13 | #include <linux/types.h> |
15 | #include <linux/time.h> | 14 | #include <linux/time.h> |
16 | 15 | ||
diff --git a/include/asm-sh/machvec_init.h b/include/asm-sh/machvec_init.h index 9e7de808f7f8..e397798ebd94 100644 --- a/include/asm-sh/machvec_init.h +++ b/include/asm-sh/machvec_init.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef __SH_MACHVEC_INIT_H | 12 | #ifndef __SH_MACHVEC_INIT_H |
13 | #define __SH_MACHVEC_INIT_H | 13 | #define __SH_MACHVEC_INIT_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | /* | 16 | /* |
18 | * In a GENERIC kernel, we have lots of these vectors floating about, | 17 | * In a GENERIC kernel, we have lots of these vectors floating about, |
diff --git a/include/asm-sh/mpc1211/dma.h b/include/asm-sh/mpc1211/dma.h index 0a2fdab3e454..e506d1aaa0d0 100644 --- a/include/asm-sh/mpc1211/dma.h +++ b/include/asm-sh/mpc1211/dma.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef _ASM_MPC1211_DMA_H | 8 | #ifndef _ASM_MPC1211_DMA_H |
9 | #define _ASM_MPC1211_DMA_H | 9 | #define _ASM_MPC1211_DMA_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #include <linux/spinlock.h> /* And spinlocks */ | 11 | #include <linux/spinlock.h> /* And spinlocks */ |
13 | #include <asm/io.h> /* need byte IO */ | 12 | #include <asm/io.h> /* need byte IO */ |
14 | #include <linux/delay.h> | 13 | #include <linux/delay.h> |
diff --git a/include/asm-sh/overdrive/overdrive.h b/include/asm-sh/overdrive/overdrive.h index aa62ae68c55c..fc746c244f83 100644 --- a/include/asm-sh/overdrive/overdrive.h +++ b/include/asm-sh/overdrive/overdrive.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * | 6 | * |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | #ifndef __OVERDRIVE_H__ | 10 | #ifndef __OVERDRIVE_H__ |
12 | #define __OVERDRIVE_H__ | 11 | #define __OVERDRIVE_H__ |
diff --git a/include/asm-sh/page.h b/include/asm-sh/page.h index 9c89287c3e56..a5559e38744e 100644 --- a/include/asm-sh/page.h +++ b/include/asm-sh/page.h | |||
@@ -13,7 +13,6 @@ | |||
13 | [ P4 control ] 0xE0000000 | 13 | [ P4 control ] 0xE0000000 |
14 | */ | 14 | */ |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | /* PAGE_SHIFT determines the page size */ | 17 | /* PAGE_SHIFT determines the page size */ |
19 | #define PAGE_SHIFT 12 | 18 | #define PAGE_SHIFT 12 |
diff --git a/include/asm-sh/pgtable.h b/include/asm-sh/pgtable.h index bb0efb31a8cb..dcd23a03683d 100644 --- a/include/asm-sh/pgtable.h +++ b/include/asm-sh/pgtable.h | |||
@@ -8,7 +8,6 @@ | |||
8 | * Copyright (C) 2002, 2003, 2004 Paul Mundt | 8 | * Copyright (C) 2002, 2003, 2004 Paul Mundt |
9 | */ | 9 | */ |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #include <asm/pgtable-2level.h> | 11 | #include <asm/pgtable-2level.h> |
13 | 12 | ||
14 | /* | 13 | /* |
diff --git a/include/asm-sh/serial.h b/include/asm-sh/serial.h index f51e232d5cd9..8734590d27e8 100644 --- a/include/asm-sh/serial.h +++ b/include/asm-sh/serial.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef _ASM_SERIAL_H | 7 | #ifndef _ASM_SERIAL_H |
8 | #define _ASM_SERIAL_H | 8 | #define _ASM_SERIAL_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <linux/kernel.h> | 10 | #include <linux/kernel.h> |
12 | 11 | ||
13 | #ifdef CONFIG_SH_EC3104 | 12 | #ifdef CONFIG_SH_EC3104 |
diff --git a/include/asm-sh/smp.h b/include/asm-sh/smp.h index f19a8b3b69a6..f57c4fe9692a 100644 --- a/include/asm-sh/smp.h +++ b/include/asm-sh/smp.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef __ASM_SH_SMP_H | 10 | #ifndef __ASM_SH_SMP_H |
11 | #define __ASM_SH_SMP_H | 11 | #define __ASM_SH_SMP_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/bitops.h> | 13 | #include <linux/bitops.h> |
15 | #include <linux/cpumask.h> | 14 | #include <linux/cpumask.h> |
16 | 15 | ||
diff --git a/include/asm-sh/system.h b/include/asm-sh/system.h index bb0330499bdf..b752e5cbb830 100644 --- a/include/asm-sh/system.h +++ b/include/asm-sh/system.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * Copyright (C) 2002 Paul Mundt | 6 | * Copyright (C) 2002 Paul Mundt |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | /* | 10 | /* |
12 | * switch_to() should switch tasks to task nr n, first | 11 | * switch_to() should switch tasks to task nr n, first |
diff --git a/include/asm-sh/types.h b/include/asm-sh/types.h index 488552f43b2a..3c09dd4ca31c 100644 --- a/include/asm-sh/types.h +++ b/include/asm-sh/types.h | |||
@@ -35,7 +35,6 @@ typedef unsigned long long __u64; | |||
35 | 35 | ||
36 | #ifndef __ASSEMBLY__ | 36 | #ifndef __ASSEMBLY__ |
37 | 37 | ||
38 | #include <linux/config.h> | ||
39 | 38 | ||
40 | typedef __signed__ char s8; | 39 | typedef __signed__ char s8; |
41 | typedef unsigned char u8; | 40 | typedef unsigned char u8; |
diff --git a/include/asm-sh/unistd.h b/include/asm-sh/unistd.h index 05520cebda12..76b5430cb458 100644 --- a/include/asm-sh/unistd.h +++ b/include/asm-sh/unistd.h | |||
@@ -304,6 +304,8 @@ | |||
304 | 304 | ||
305 | #define NR_syscalls 293 | 305 | #define NR_syscalls 293 |
306 | 306 | ||
307 | #ifdef __KERNEL__ | ||
308 | |||
307 | /* user-visible error numbers are in the range -1 - -124: see <asm-sh/errno.h> */ | 309 | /* user-visible error numbers are in the range -1 - -124: see <asm-sh/errno.h> */ |
308 | 310 | ||
309 | #define __syscall_return(type, res) \ | 311 | #define __syscall_return(type, res) \ |
@@ -420,7 +422,6 @@ __asm__ __volatile__ ("trapa #0x16" \ | |||
420 | __syscall_return(type,__sc0); \ | 422 | __syscall_return(type,__sc0); \ |
421 | } | 423 | } |
422 | 424 | ||
423 | #ifdef __KERNEL__ | ||
424 | #define __ARCH_WANT_IPC_PARSE_VERSION | 425 | #define __ARCH_WANT_IPC_PARSE_VERSION |
425 | #define __ARCH_WANT_OLD_READDIR | 426 | #define __ARCH_WANT_OLD_READDIR |
426 | #define __ARCH_WANT_OLD_STAT | 427 | #define __ARCH_WANT_OLD_STAT |
@@ -443,7 +444,6 @@ __syscall_return(type,__sc0); \ | |||
443 | #define __ARCH_WANT_SYS_SIGPENDING | 444 | #define __ARCH_WANT_SYS_SIGPENDING |
444 | #define __ARCH_WANT_SYS_SIGPROCMASK | 445 | #define __ARCH_WANT_SYS_SIGPROCMASK |
445 | #define __ARCH_WANT_SYS_RT_SIGACTION | 446 | #define __ARCH_WANT_SYS_RT_SIGACTION |
446 | #endif | ||
447 | 447 | ||
448 | #ifdef __KERNEL_SYSCALLS__ | 448 | #ifdef __KERNEL_SYSCALLS__ |
449 | 449 | ||
@@ -513,7 +513,7 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
513 | struct sigaction __user *oact, | 513 | struct sigaction __user *oact, |
514 | size_t sigsetsize); | 514 | size_t sigsetsize); |
515 | 515 | ||
516 | #endif | 516 | #endif /* __KERNEL_SYSCALLS__ */ |
517 | 517 | ||
518 | /* | 518 | /* |
519 | * "Conditional" syscalls | 519 | * "Conditional" syscalls |
@@ -525,4 +525,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
525 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 525 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
526 | #endif | 526 | #endif |
527 | 527 | ||
528 | #endif /* __KERNEL__ */ | ||
528 | #endif /* __ASM_SH_UNISTD_H */ | 529 | #endif /* __ASM_SH_UNISTD_H */ |
diff --git a/include/asm-sh/watchdog.h b/include/asm-sh/watchdog.h index f0cf4be21655..09ca41972a11 100644 --- a/include/asm-sh/watchdog.h +++ b/include/asm-sh/watchdog.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifdef __KERNEL__ | 13 | #ifdef __KERNEL__ |
14 | 14 | ||
15 | #include <linux/types.h> | 15 | #include <linux/types.h> |
16 | #include <linux/config.h> | ||
17 | #include <asm/cpu/watchdog.h> | 16 | #include <asm/cpu/watchdog.h> |
18 | #include <asm/io.h> | 17 | #include <asm/io.h> |
19 | 18 | ||
diff --git a/include/asm-sh64/bug.h b/include/asm-sh64/bug.h index 5d659ec28e10..81f722efeb63 100644 --- a/include/asm-sh64/bug.h +++ b/include/asm-sh64/bug.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_SH64_BUG_H | 1 | #ifndef __ASM_SH64_BUG_H |
2 | #define __ASM_SH64_BUG_H | 2 | #define __ASM_SH64_BUG_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * Tell the user there is some problem, then force a segfault (in process | 6 | * Tell the user there is some problem, then force a segfault (in process |
diff --git a/include/asm-sh64/dma-mapping.h b/include/asm-sh64/dma-mapping.h index cc9a2e86f5b4..a74a49e47922 100644 --- a/include/asm-sh64/dma-mapping.h +++ b/include/asm-sh64/dma-mapping.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_SH_DMA_MAPPING_H | 1 | #ifndef __ASM_SH_DMA_MAPPING_H |
2 | #define __ASM_SH_DMA_MAPPING_H | 2 | #define __ASM_SH_DMA_MAPPING_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | #include <asm/scatterlist.h> | 5 | #include <asm/scatterlist.h> |
7 | #include <asm/io.h> | 6 | #include <asm/io.h> |
diff --git a/include/asm-sh64/hardirq.h b/include/asm-sh64/hardirq.h index ad2330e41fd5..555fd7a35108 100644 --- a/include/asm-sh64/hardirq.h +++ b/include/asm-sh64/hardirq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_SH64_HARDIRQ_H | 1 | #ifndef __ASM_SH64_HARDIRQ_H |
2 | #define __ASM_SH64_HARDIRQ_H | 2 | #define __ASM_SH64_HARDIRQ_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/threads.h> | 4 | #include <linux/threads.h> |
6 | #include <linux/irq.h> | 5 | #include <linux/irq.h> |
7 | 6 | ||
diff --git a/include/asm-sh64/ide.h b/include/asm-sh64/ide.h index 852f50afe39c..c9d84d5f772e 100644 --- a/include/asm-sh64/ide.h +++ b/include/asm-sh64/ide.h | |||
@@ -15,7 +15,6 @@ | |||
15 | 15 | ||
16 | #ifdef __KERNEL__ | 16 | #ifdef __KERNEL__ |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | 18 | ||
20 | /* Without this, the initialisation of PCI IDE cards end up calling | 19 | /* Without this, the initialisation of PCI IDE cards end up calling |
21 | * ide_init_hwif_ports, which won't work. */ | 20 | * ide_init_hwif_ports, which won't work. */ |
diff --git a/include/asm-sh64/irq.h b/include/asm-sh64/irq.h index f815b43df845..1ca49e29288a 100644 --- a/include/asm-sh64/irq.h +++ b/include/asm-sh64/irq.h | |||
@@ -12,7 +12,6 @@ | |||
12 | * | 12 | * |
13 | */ | 13 | */ |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | /* | 16 | /* |
18 | * Encoded IRQs are not considered worth to be supported. | 17 | * Encoded IRQs are not considered worth to be supported. |
diff --git a/include/asm-sh64/mmu_context.h b/include/asm-sh64/mmu_context.h index 991cfda4cdf6..8c860dab2d0e 100644 --- a/include/asm-sh64/mmu_context.h +++ b/include/asm-sh64/mmu_context.h | |||
@@ -26,7 +26,6 @@ | |||
26 | */ | 26 | */ |
27 | extern unsigned long mmu_context_cache; | 27 | extern unsigned long mmu_context_cache; |
28 | 28 | ||
29 | #include <linux/config.h> | ||
30 | #include <asm/page.h> | 29 | #include <asm/page.h> |
31 | 30 | ||
32 | 31 | ||
diff --git a/include/asm-sh64/page.h b/include/asm-sh64/page.h index e4937cdabebd..34fb34754ae6 100644 --- a/include/asm-sh64/page.h +++ b/include/asm-sh64/page.h | |||
@@ -17,7 +17,6 @@ | |||
17 | * | 17 | * |
18 | */ | 18 | */ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | 20 | ||
22 | /* PAGE_SHIFT determines the page size */ | 21 | /* PAGE_SHIFT determines the page size */ |
23 | #define PAGE_SHIFT 12 | 22 | #define PAGE_SHIFT 12 |
diff --git a/include/asm-sh64/param.h b/include/asm-sh64/param.h index d18cc87c1a80..f409adb41540 100644 --- a/include/asm-sh64/param.h +++ b/include/asm-sh64/param.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef __ASM_SH64_PARAM_H | 12 | #ifndef __ASM_SH64_PARAM_H |
13 | #define __ASM_SH64_PARAM_H | 13 | #define __ASM_SH64_PARAM_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | 15 | ||
17 | #ifdef __KERNEL__ | 16 | #ifdef __KERNEL__ |
18 | # ifdef CONFIG_SH_WDT | 17 | # ifdef CONFIG_SH_WDT |
diff --git a/include/asm-sh64/pgtable.h b/include/asm-sh64/pgtable.h index 57af6b3eb271..54c7821893f5 100644 --- a/include/asm-sh64/pgtable.h +++ b/include/asm-sh64/pgtable.h | |||
@@ -22,7 +22,6 @@ | |||
22 | #include <asm/processor.h> | 22 | #include <asm/processor.h> |
23 | #include <asm/page.h> | 23 | #include <asm/page.h> |
24 | #include <linux/threads.h> | 24 | #include <linux/threads.h> |
25 | #include <linux/config.h> | ||
26 | 25 | ||
27 | struct vm_area_struct; | 26 | struct vm_area_struct; |
28 | 27 | ||
diff --git a/include/asm-sh64/system.h b/include/asm-sh64/system.h index 3002e988180c..7606f6e1f01e 100644 --- a/include/asm-sh64/system.h +++ b/include/asm-sh64/system.h | |||
@@ -14,7 +14,6 @@ | |||
14 | * | 14 | * |
15 | */ | 15 | */ |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | #include <asm/registers.h> | 17 | #include <asm/registers.h> |
19 | #include <asm/processor.h> | 18 | #include <asm/processor.h> |
20 | 19 | ||
diff --git a/include/asm-sh64/unistd.h b/include/asm-sh64/unistd.h index 1f8f394ae371..9a1590fffc15 100644 --- a/include/asm-sh64/unistd.h +++ b/include/asm-sh64/unistd.h | |||
@@ -344,6 +344,8 @@ | |||
344 | #define __NR_inotify_add_watch 319 | 344 | #define __NR_inotify_add_watch 319 |
345 | #define __NR_inotify_rm_watch 320 | 345 | #define __NR_inotify_rm_watch 320 |
346 | 346 | ||
347 | #ifdef __KERNEL__ | ||
348 | |||
347 | #define NR_syscalls 321 | 349 | #define NR_syscalls 321 |
348 | 350 | ||
349 | /* user-visible error numbers are in the range -1 - -125: see <asm-sh64/errno.h> */ | 351 | /* user-visible error numbers are in the range -1 - -125: see <asm-sh64/errno.h> */ |
@@ -486,7 +488,6 @@ __asm__ __volatile__ ("!dummy %0 %1 %2 %3 %4 %5 %6" \ | |||
486 | __syscall_return(type,__sc0); \ | 488 | __syscall_return(type,__sc0); \ |
487 | } | 489 | } |
488 | 490 | ||
489 | #ifdef __KERNEL__ | ||
490 | #define __ARCH_WANT_IPC_PARSE_VERSION | 491 | #define __ARCH_WANT_IPC_PARSE_VERSION |
491 | #define __ARCH_WANT_OLD_READDIR | 492 | #define __ARCH_WANT_OLD_READDIR |
492 | #define __ARCH_WANT_OLD_STAT | 493 | #define __ARCH_WANT_OLD_STAT |
@@ -509,7 +510,6 @@ __syscall_return(type,__sc0); \ | |||
509 | #define __ARCH_WANT_SYS_SIGPENDING | 510 | #define __ARCH_WANT_SYS_SIGPENDING |
510 | #define __ARCH_WANT_SYS_SIGPROCMASK | 511 | #define __ARCH_WANT_SYS_SIGPROCMASK |
511 | #define __ARCH_WANT_SYS_RT_SIGACTION | 512 | #define __ARCH_WANT_SYS_RT_SIGACTION |
512 | #endif | ||
513 | 513 | ||
514 | #ifdef __KERNEL_SYSCALLS__ | 514 | #ifdef __KERNEL_SYSCALLS__ |
515 | 515 | ||
@@ -550,7 +550,7 @@ static inline pid_t wait(int * wait_stat) | |||
550 | { | 550 | { |
551 | return waitpid(-1,wait_stat,0); | 551 | return waitpid(-1,wait_stat,0); |
552 | } | 552 | } |
553 | #endif | 553 | #endif /* __KERNEL_SYSCALLS__ */ |
554 | 554 | ||
555 | /* | 555 | /* |
556 | * "Conditional" syscalls | 556 | * "Conditional" syscalls |
@@ -562,4 +562,5 @@ static inline pid_t wait(int * wait_stat) | |||
562 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 562 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
563 | #endif | 563 | #endif |
564 | 564 | ||
565 | #endif /* __KERNEL__ */ | ||
565 | #endif /* __ASM_SH64_UNISTD_H */ | 566 | #endif /* __ASM_SH64_UNISTD_H */ |
diff --git a/include/asm-sparc/asmmacro.h b/include/asm-sparc/asmmacro.h index 0d4b65bd252b..a619a4d97aae 100644 --- a/include/asm-sparc/asmmacro.h +++ b/include/asm-sparc/asmmacro.h | |||
@@ -6,7 +6,6 @@ | |||
6 | #ifndef _SPARC_ASMMACRO_H | 6 | #ifndef _SPARC_ASMMACRO_H |
7 | #define _SPARC_ASMMACRO_H | 7 | #define _SPARC_ASMMACRO_H |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <asm/btfixup.h> | 9 | #include <asm/btfixup.h> |
11 | #include <asm/asi.h> | 10 | #include <asm/asi.h> |
12 | 11 | ||
diff --git a/include/asm-sparc/atomic.h b/include/asm-sparc/atomic.h index e1033170bd3a..731fa56e0c37 100644 --- a/include/asm-sparc/atomic.h +++ b/include/asm-sparc/atomic.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef __ARCH_SPARC_ATOMIC__ | 10 | #ifndef __ARCH_SPARC_ATOMIC__ |
11 | #define __ARCH_SPARC_ATOMIC__ | 11 | #define __ARCH_SPARC_ATOMIC__ |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | 13 | ||
15 | typedef struct { volatile int counter; } atomic_t; | 14 | typedef struct { volatile int counter; } atomic_t; |
16 | 15 | ||
diff --git a/include/asm-sparc/bugs.h b/include/asm-sparc/bugs.h index e652f89e0eff..a0f939beeea1 100644 --- a/include/asm-sparc/bugs.h +++ b/include/asm-sparc/bugs.h | |||
@@ -5,7 +5,6 @@ | |||
5 | */ | 5 | */ |
6 | 6 | ||
7 | #include <asm/cpudata.h> | 7 | #include <asm/cpudata.h> |
8 | #include <linux/config.h> | ||
9 | 8 | ||
10 | extern unsigned long loops_per_jiffy; | 9 | extern unsigned long loops_per_jiffy; |
11 | 10 | ||
diff --git a/include/asm-sparc/cacheflush.h b/include/asm-sparc/cacheflush.h index 4901217008c0..fc632f811cd8 100644 --- a/include/asm-sparc/cacheflush.h +++ b/include/asm-sparc/cacheflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _SPARC_CACHEFLUSH_H | 1 | #ifndef _SPARC_CACHEFLUSH_H |
2 | #define _SPARC_CACHEFLUSH_H | 2 | #define _SPARC_CACHEFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> /* Common for other includes */ | 4 | #include <linux/mm.h> /* Common for other includes */ |
6 | // #include <linux/kernel.h> from pgalloc.h | 5 | // #include <linux/kernel.h> from pgalloc.h |
7 | // #include <linux/sched.h> from pgalloc.h | 6 | // #include <linux/sched.h> from pgalloc.h |
diff --git a/include/asm-sparc/delay.h b/include/asm-sparc/delay.h index 7ec8e9f7ad4f..48aa70eef997 100644 --- a/include/asm-sparc/delay.h +++ b/include/asm-sparc/delay.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef __SPARC_DELAY_H | 7 | #ifndef __SPARC_DELAY_H |
8 | #define __SPARC_DELAY_H | 8 | #define __SPARC_DELAY_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <asm/cpudata.h> | 10 | #include <asm/cpudata.h> |
12 | 11 | ||
13 | static inline void __delay(unsigned long loops) | 12 | static inline void __delay(unsigned long loops) |
diff --git a/include/asm-sparc/dma-mapping.h b/include/asm-sparc/dma-mapping.h index d7c3b0f0a901..6db83dc93cb7 100644 --- a/include/asm-sparc/dma-mapping.h +++ b/include/asm-sparc/dma-mapping.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_SPARC_DMA_MAPPING_H | 1 | #ifndef _ASM_SPARC_DMA_MAPPING_H |
2 | #define _ASM_SPARC_DMA_MAPPING_H | 2 | #define _ASM_SPARC_DMA_MAPPING_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_PCI | 5 | #ifdef CONFIG_PCI |
7 | #include <asm-generic/dma-mapping.h> | 6 | #include <asm-generic/dma-mapping.h> |
diff --git a/include/asm-sparc/dma.h b/include/asm-sparc/dma.h index 8ec206aa5f2e..407b3614468a 100644 --- a/include/asm-sparc/dma.h +++ b/include/asm-sparc/dma.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef _ASM_SPARC_DMA_H | 7 | #ifndef _ASM_SPARC_DMA_H |
8 | #define _ASM_SPARC_DMA_H | 8 | #define _ASM_SPARC_DMA_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <linux/kernel.h> | 10 | #include <linux/kernel.h> |
12 | #include <linux/types.h> | 11 | #include <linux/types.h> |
13 | 12 | ||
diff --git a/include/asm-sparc/elf.h b/include/asm-sparc/elf.h index 4a71d7c1eace..83a3dd15a6ed 100644 --- a/include/asm-sparc/elf.h +++ b/include/asm-sparc/elf.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * ELF register definitions.. | 6 | * ELF register definitions.. |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <asm/ptrace.h> | 9 | #include <asm/ptrace.h> |
11 | 10 | ||
12 | #ifdef __KERNEL__ | 11 | #ifdef __KERNEL__ |
diff --git a/include/asm-sparc/fixmap.h b/include/asm-sparc/fixmap.h index 9de52b4d2cfb..f18fc0755adf 100644 --- a/include/asm-sparc/fixmap.h +++ b/include/asm-sparc/fixmap.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef _ASM_FIXMAP_H | 13 | #ifndef _ASM_FIXMAP_H |
14 | #define _ASM_FIXMAP_H | 14 | #define _ASM_FIXMAP_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/kernel.h> | 16 | #include <linux/kernel.h> |
18 | #include <asm/page.h> | 17 | #include <asm/page.h> |
19 | #ifdef CONFIG_HIGHMEM | 18 | #ifdef CONFIG_HIGHMEM |
diff --git a/include/asm-sparc/hardirq.h b/include/asm-sparc/hardirq.h index 2a668c479f68..4f63ed8df551 100644 --- a/include/asm-sparc/hardirq.h +++ b/include/asm-sparc/hardirq.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef __SPARC_HARDIRQ_H | 7 | #ifndef __SPARC_HARDIRQ_H |
8 | #define __SPARC_HARDIRQ_H | 8 | #define __SPARC_HARDIRQ_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <linux/threads.h> | 10 | #include <linux/threads.h> |
12 | #include <linux/spinlock.h> | 11 | #include <linux/spinlock.h> |
13 | #include <linux/cache.h> | 12 | #include <linux/cache.h> |
diff --git a/include/asm-sparc/ide.h b/include/asm-sparc/ide.h index 64d810385ea4..a6d735a1310e 100644 --- a/include/asm-sparc/ide.h +++ b/include/asm-sparc/ide.h | |||
@@ -11,7 +11,6 @@ | |||
11 | 11 | ||
12 | #ifdef __KERNEL__ | 12 | #ifdef __KERNEL__ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <asm/pgtable.h> | 14 | #include <asm/pgtable.h> |
16 | #include <asm/io.h> | 15 | #include <asm/io.h> |
17 | #include <asm/psr.h> | 16 | #include <asm/psr.h> |
diff --git a/include/asm-sparc/irq.h b/include/asm-sparc/irq.h index cee356b0dae3..f2d64537e29d 100644 --- a/include/asm-sparc/irq.h +++ b/include/asm-sparc/irq.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef _SPARC_IRQ_H | 7 | #ifndef _SPARC_IRQ_H |
8 | #define _SPARC_IRQ_H | 8 | #define _SPARC_IRQ_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <linux/linkage.h> | 10 | #include <linux/linkage.h> |
12 | #include <linux/threads.h> /* For NR_CPUS */ | 11 | #include <linux/threads.h> /* For NR_CPUS */ |
13 | #include <linux/interrupt.h> | 12 | #include <linux/interrupt.h> |
@@ -17,8 +16,6 @@ | |||
17 | 16 | ||
18 | #define __irq_ino(irq) irq | 17 | #define __irq_ino(irq) irq |
19 | #define __irq_pil(irq) irq | 18 | #define __irq_pil(irq) irq |
20 | BTFIXUPDEF_CALL(char *, __irq_itoa, unsigned int) | ||
21 | #define __irq_itoa(irq) BTFIXUP_CALL(__irq_itoa)(irq) | ||
22 | 19 | ||
23 | #define NR_IRQS 16 | 20 | #define NR_IRQS 16 |
24 | 21 | ||
diff --git a/include/asm-sparc/mostek.h b/include/asm-sparc/mostek.h index 59b86bc793bf..bd92a78f4937 100644 --- a/include/asm-sparc/mostek.h +++ b/include/asm-sparc/mostek.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _SPARC_MOSTEK_H | 9 | #ifndef _SPARC_MOSTEK_H |
10 | #define _SPARC_MOSTEK_H | 10 | #define _SPARC_MOSTEK_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <asm/idprom.h> | 12 | #include <asm/idprom.h> |
14 | #include <asm/io.h> | 13 | #include <asm/io.h> |
15 | 14 | ||
diff --git a/include/asm-sparc/page.h b/include/asm-sparc/page.h index ec3274b7ddf4..5bab8a7c25ce 100644 --- a/include/asm-sparc/page.h +++ b/include/asm-sparc/page.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef _SPARC_PAGE_H | 8 | #ifndef _SPARC_PAGE_H |
9 | #define _SPARC_PAGE_H | 9 | #define _SPARC_PAGE_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #ifdef CONFIG_SUN4 | 11 | #ifdef CONFIG_SUN4 |
13 | #define PAGE_SHIFT 13 | 12 | #define PAGE_SHIFT 13 |
14 | #else | 13 | #else |
diff --git a/include/asm-sparc/pgalloc.h b/include/asm-sparc/pgalloc.h index 126800acd10d..a449cd4912d1 100644 --- a/include/asm-sparc/pgalloc.h +++ b/include/asm-sparc/pgalloc.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #ifndef _SPARC_PGALLOC_H | 2 | #ifndef _SPARC_PGALLOC_H |
3 | #define _SPARC_PGALLOC_H | 3 | #define _SPARC_PGALLOC_H |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | #include <linux/kernel.h> | 5 | #include <linux/kernel.h> |
7 | #include <linux/sched.h> | 6 | #include <linux/sched.h> |
8 | 7 | ||
diff --git a/include/asm-sparc/pgtable.h b/include/asm-sparc/pgtable.h index 9eea8f4d41f0..226c6475c9a2 100644 --- a/include/asm-sparc/pgtable.h +++ b/include/asm-sparc/pgtable.h | |||
@@ -11,7 +11,6 @@ | |||
11 | 11 | ||
12 | #include <asm-generic/4level-fixup.h> | 12 | #include <asm-generic/4level-fixup.h> |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/spinlock.h> | 14 | #include <linux/spinlock.h> |
16 | #include <linux/swap.h> | 15 | #include <linux/swap.h> |
17 | #include <asm/types.h> | 16 | #include <asm/types.h> |
diff --git a/include/asm-sparc/sfp-machine.h b/include/asm-sparc/sfp-machine.h index b4ca2d94bf08..ecfc86a4a725 100644 --- a/include/asm-sparc/sfp-machine.h +++ b/include/asm-sparc/sfp-machine.h | |||
@@ -25,7 +25,6 @@ | |||
25 | #ifndef _SFP_MACHINE_H | 25 | #ifndef _SFP_MACHINE_H |
26 | #define _SFP_MACHINE_H | 26 | #define _SFP_MACHINE_H |
27 | 27 | ||
28 | #include <linux/config.h> | ||
29 | 28 | ||
30 | #define _FP_W_TYPE_SIZE 32 | 29 | #define _FP_W_TYPE_SIZE 32 |
31 | #define _FP_W_TYPE unsigned long | 30 | #define _FP_W_TYPE unsigned long |
diff --git a/include/asm-sparc/smp.h b/include/asm-sparc/smp.h index 98c46e3fbe8a..b9da9a600e35 100644 --- a/include/asm-sparc/smp.h +++ b/include/asm-sparc/smp.h | |||
@@ -6,7 +6,6 @@ | |||
6 | #ifndef _SPARC_SMP_H | 6 | #ifndef _SPARC_SMP_H |
7 | #define _SPARC_SMP_H | 7 | #define _SPARC_SMP_H |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <linux/threads.h> | 9 | #include <linux/threads.h> |
11 | #include <asm/head.h> | 10 | #include <asm/head.h> |
12 | #include <asm/btfixup.h> | 11 | #include <asm/btfixup.h> |
@@ -146,6 +145,8 @@ static inline int hard_smp_processor_id(void) | |||
146 | #define prof_multiplier(__cpu) cpu_data(__cpu).multiplier | 145 | #define prof_multiplier(__cpu) cpu_data(__cpu).multiplier |
147 | #define prof_counter(__cpu) cpu_data(__cpu).counter | 146 | #define prof_counter(__cpu) cpu_data(__cpu).counter |
148 | 147 | ||
148 | void smp_setup_cpu_possible_map(void); | ||
149 | |||
149 | #endif /* !(__ASSEMBLY__) */ | 150 | #endif /* !(__ASSEMBLY__) */ |
150 | 151 | ||
151 | /* Sparc specific messages. */ | 152 | /* Sparc specific messages. */ |
@@ -162,7 +163,11 @@ static inline int hard_smp_processor_id(void) | |||
162 | #define MBOX_IDLECPU2 0xFD | 163 | #define MBOX_IDLECPU2 0xFD |
163 | #define MBOX_STOPCPU2 0xFE | 164 | #define MBOX_STOPCPU2 0xFE |
164 | 165 | ||
165 | #endif /* SMP */ | 166 | #else /* SMP */ |
167 | |||
168 | #define smp_setup_cpu_possible_map() do { } while (0) | ||
169 | |||
170 | #endif /* !(SMP) */ | ||
166 | 171 | ||
167 | #define NO_PROC_ID 0xFF | 172 | #define NO_PROC_ID 0xFF |
168 | 173 | ||
diff --git a/include/asm-sparc/spinlock.h b/include/asm-sparc/spinlock.h index 3350c90c7869..1c75474ba1df 100644 --- a/include/asm-sparc/spinlock.h +++ b/include/asm-sparc/spinlock.h | |||
@@ -154,6 +154,9 @@ static inline int __raw_write_trylock(raw_rwlock_t *rw) | |||
154 | #define __raw_spin_lock_flags(lock, flags) __raw_spin_lock(lock) | 154 | #define __raw_spin_lock_flags(lock, flags) __raw_spin_lock(lock) |
155 | #define __raw_read_trylock(lock) generic__raw_read_trylock(lock) | 155 | #define __raw_read_trylock(lock) generic__raw_read_trylock(lock) |
156 | 156 | ||
157 | #define __raw_read_can_lock(rw) (!((rw)->lock & 0xff)) | ||
158 | #define __raw_write_can_lock(rw) (!(rw)->lock) | ||
159 | |||
157 | #endif /* !(__ASSEMBLY__) */ | 160 | #endif /* !(__ASSEMBLY__) */ |
158 | 161 | ||
159 | #endif /* __SPARC_SPINLOCK_H */ | 162 | #endif /* __SPARC_SPINLOCK_H */ |
diff --git a/include/asm-sparc/system.h b/include/asm-sparc/system.h index 58dd162927bb..cb7dda1e5e91 100644 --- a/include/asm-sparc/system.h +++ b/include/asm-sparc/system.h | |||
@@ -1,10 +1,8 @@ | |||
1 | /* $Id: system.h,v 1.86 2001/10/30 04:57:10 davem Exp $ */ | 1 | /* $Id: system.h,v 1.86 2001/10/30 04:57:10 davem Exp $ */ |
2 | #include <linux/config.h> | ||
3 | 2 | ||
4 | #ifndef __SPARC_SYSTEM_H | 3 | #ifndef __SPARC_SYSTEM_H |
5 | #define __SPARC_SYSTEM_H | 4 | #define __SPARC_SYSTEM_H |
6 | 5 | ||
7 | #include <linux/config.h> | ||
8 | #include <linux/kernel.h> | 6 | #include <linux/kernel.h> |
9 | #include <linux/threads.h> /* NR_CPUS */ | 7 | #include <linux/threads.h> /* NR_CPUS */ |
10 | #include <linux/thread_info.h> | 8 | #include <linux/thread_info.h> |
diff --git a/include/asm-sparc/timer.h b/include/asm-sparc/timer.h index b16eb739dddb..cb1fa1d1f184 100644 --- a/include/asm-sparc/timer.h +++ b/include/asm-sparc/timer.h | |||
@@ -4,7 +4,6 @@ | |||
4 | * Copyright (C) 1995 David S. Miller (davem@caip.rutgers.edu) | 4 | * Copyright (C) 1995 David S. Miller (davem@caip.rutgers.edu) |
5 | */ | 5 | */ |
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | #ifndef _SPARC_TIMER_H | 8 | #ifndef _SPARC_TIMER_H |
10 | #define _SPARC_TIMER_H | 9 | #define _SPARC_TIMER_H |
diff --git a/include/asm-sparc/tlbflush.h b/include/asm-sparc/tlbflush.h index 5643ca31ead9..4a3b66618e75 100644 --- a/include/asm-sparc/tlbflush.h +++ b/include/asm-sparc/tlbflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _SPARC_TLBFLUSH_H | 1 | #ifndef _SPARC_TLBFLUSH_H |
2 | #define _SPARC_TLBFLUSH_H | 2 | #define _SPARC_TLBFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | // #include <asm/processor.h> | 5 | // #include <asm/processor.h> |
7 | 6 | ||
diff --git a/include/asm-sparc/unistd.h b/include/asm-sparc/unistd.h index 45a576507785..2553762465ca 100644 --- a/include/asm-sparc/unistd.h +++ b/include/asm-sparc/unistd.h | |||
@@ -319,6 +319,7 @@ | |||
319 | #define __NR_set_robust_list 300 | 319 | #define __NR_set_robust_list 300 |
320 | #define __NR_get_robust_list 301 | 320 | #define __NR_get_robust_list 301 |
321 | 321 | ||
322 | #ifdef __KERNEL__ | ||
322 | /* WARNING: You MAY NOT add syscall numbers larger than 301, since | 323 | /* WARNING: You MAY NOT add syscall numbers larger than 301, since |
323 | * all of the syscall tables in the Sparc kernel are | 324 | * all of the syscall tables in the Sparc kernel are |
324 | * sized to have 301 entries (starting at zero). Therefore | 325 | * sized to have 301 entries (starting at zero). Therefore |
@@ -455,7 +456,6 @@ errno = -__res; \ | |||
455 | return -1; \ | 456 | return -1; \ |
456 | } | 457 | } |
457 | 458 | ||
458 | #ifdef __KERNEL__ | ||
459 | #define __ARCH_WANT_IPC_PARSE_VERSION | 459 | #define __ARCH_WANT_IPC_PARSE_VERSION |
460 | #define __ARCH_WANT_OLD_READDIR | 460 | #define __ARCH_WANT_OLD_READDIR |
461 | #define __ARCH_WANT_STAT64 | 461 | #define __ARCH_WANT_STAT64 |
@@ -477,7 +477,6 @@ return -1; \ | |||
477 | #define __ARCH_WANT_SYS_SIGPENDING | 477 | #define __ARCH_WANT_SYS_SIGPENDING |
478 | #define __ARCH_WANT_SYS_SIGPROCMASK | 478 | #define __ARCH_WANT_SYS_SIGPROCMASK |
479 | #define __ARCH_WANT_SYS_RT_SIGSUSPEND | 479 | #define __ARCH_WANT_SYS_RT_SIGSUSPEND |
480 | #endif | ||
481 | 480 | ||
482 | #ifdef __KERNEL_SYSCALLS__ | 481 | #ifdef __KERNEL_SYSCALLS__ |
483 | 482 | ||
@@ -534,4 +533,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
534 | */ | 533 | */ |
535 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 534 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
536 | 535 | ||
536 | #endif /* __KERNEL__ */ | ||
537 | #endif /* _SPARC_UNISTD_H */ | 537 | #endif /* _SPARC_UNISTD_H */ |
diff --git a/include/asm-sparc/vac-ops.h b/include/asm-sparc/vac-ops.h index 9e0172323042..ab6f53b913ea 100644 --- a/include/asm-sparc/vac-ops.h +++ b/include/asm-sparc/vac-ops.h | |||
@@ -8,7 +8,6 @@ | |||
8 | * Copyright (C) 1994, David S. Miller (davem@caip.rutgers.edu) | 8 | * Copyright (C) 1994, David S. Miller (davem@caip.rutgers.edu) |
9 | */ | 9 | */ |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #include <asm/sysen.h> | 11 | #include <asm/sysen.h> |
13 | #include <asm/contregs.h> | 12 | #include <asm/contregs.h> |
14 | #include <asm/asi.h> | 13 | #include <asm/asi.h> |
diff --git a/include/asm-sparc/winmacro.h b/include/asm-sparc/winmacro.h index 557257eef3f9..096f3d3d90c3 100644 --- a/include/asm-sparc/winmacro.h +++ b/include/asm-sparc/winmacro.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef _SPARC_WINMACRO_H | 7 | #ifndef _SPARC_WINMACRO_H |
8 | #define _SPARC_WINMACRO_H | 8 | #define _SPARC_WINMACRO_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <asm/ptrace.h> | 10 | #include <asm/ptrace.h> |
12 | 11 | ||
13 | /* Store the register window onto the 8-byte aligned area starting | 12 | /* Store the register window onto the 8-byte aligned area starting |
diff --git a/include/asm-sparc64/atomic.h b/include/asm-sparc64/atomic.h index 468eb48d8142..2f0bec26a695 100644 --- a/include/asm-sparc64/atomic.h +++ b/include/asm-sparc64/atomic.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef __ARCH_SPARC64_ATOMIC__ | 8 | #ifndef __ARCH_SPARC64_ATOMIC__ |
9 | #define __ARCH_SPARC64_ATOMIC__ | 9 | #define __ARCH_SPARC64_ATOMIC__ |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #include <linux/types.h> | 11 | #include <linux/types.h> |
13 | 12 | ||
14 | typedef struct { volatile int counter; } atomic_t; | 13 | typedef struct { volatile int counter; } atomic_t; |
diff --git a/include/asm-sparc64/bitops.h b/include/asm-sparc64/bitops.h index 71944b0f09de..3d5e1af84723 100644 --- a/include/asm-sparc64/bitops.h +++ b/include/asm-sparc64/bitops.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef _SPARC64_BITOPS_H | 7 | #ifndef _SPARC64_BITOPS_H |
8 | #define _SPARC64_BITOPS_H | 8 | #define _SPARC64_BITOPS_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <linux/compiler.h> | 10 | #include <linux/compiler.h> |
12 | #include <asm/byteorder.h> | 11 | #include <asm/byteorder.h> |
13 | 12 | ||
diff --git a/include/asm-sparc64/bugs.h b/include/asm-sparc64/bugs.h index 360dd04ed8e4..120422fdb02f 100644 --- a/include/asm-sparc64/bugs.h +++ b/include/asm-sparc64/bugs.h | |||
@@ -4,7 +4,6 @@ | |||
4 | * Copyright (C) 1996 David S. Miller (davem@caip.rutgers.edu) | 4 | * Copyright (C) 1996 David S. Miller (davem@caip.rutgers.edu) |
5 | */ | 5 | */ |
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | extern unsigned long loops_per_jiffy; | 8 | extern unsigned long loops_per_jiffy; |
10 | 9 | ||
diff --git a/include/asm-sparc64/cacheflush.h b/include/asm-sparc64/cacheflush.h index b3f61659ba81..745d1ab60371 100644 --- a/include/asm-sparc64/cacheflush.h +++ b/include/asm-sparc64/cacheflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _SPARC64_CACHEFLUSH_H | 1 | #ifndef _SPARC64_CACHEFLUSH_H |
2 | #define _SPARC64_CACHEFLUSH_H | 2 | #define _SPARC64_CACHEFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/page.h> | 4 | #include <asm/page.h> |
6 | 5 | ||
7 | #ifndef __ASSEMBLY__ | 6 | #ifndef __ASSEMBLY__ |
diff --git a/include/asm-sparc64/cpudata.h b/include/asm-sparc64/cpudata.h index 9d6a6dbaf126..f2cc9411b4c7 100644 --- a/include/asm-sparc64/cpudata.h +++ b/include/asm-sparc64/cpudata.h | |||
@@ -74,8 +74,10 @@ struct trap_per_cpu { | |||
74 | unsigned long tsb_huge; | 74 | unsigned long tsb_huge; |
75 | unsigned long tsb_huge_temp; | 75 | unsigned long tsb_huge_temp; |
76 | 76 | ||
77 | /* Dcache line 8: Unused, needed to keep trap_block a power-of-2 in size. */ | 77 | /* Dcache line 8: IRQ work list, and keep trap_block a power-of-2 in size. */ |
78 | unsigned long __pad2[4]; | 78 | unsigned int irq_worklist; |
79 | unsigned int __pad1; | ||
80 | unsigned long __pad2[3]; | ||
79 | } __attribute__((aligned(64))); | 81 | } __attribute__((aligned(64))); |
80 | extern struct trap_per_cpu trap_block[NR_CPUS]; | 82 | extern struct trap_per_cpu trap_block[NR_CPUS]; |
81 | extern void init_cur_cpu_trap(struct thread_info *); | 83 | extern void init_cur_cpu_trap(struct thread_info *); |
@@ -119,6 +121,7 @@ extern struct sun4v_2insn_patch_entry __sun4v_2insn_patch, | |||
119 | #define TRAP_PER_CPU_CPU_LIST_PA 0xc8 | 121 | #define TRAP_PER_CPU_CPU_LIST_PA 0xc8 |
120 | #define TRAP_PER_CPU_TSB_HUGE 0xd0 | 122 | #define TRAP_PER_CPU_TSB_HUGE 0xd0 |
121 | #define TRAP_PER_CPU_TSB_HUGE_TEMP 0xd8 | 123 | #define TRAP_PER_CPU_TSB_HUGE_TEMP 0xd8 |
124 | #define TRAP_PER_CPU_IRQ_WORKLIST 0xe0 | ||
122 | 125 | ||
123 | #define TRAP_BLOCK_SZ_SHIFT 8 | 126 | #define TRAP_BLOCK_SZ_SHIFT 8 |
124 | 127 | ||
@@ -171,11 +174,8 @@ extern struct sun4v_2insn_patch_entry __sun4v_2insn_patch, | |||
171 | 174 | ||
172 | /* Clobbers TMP, loads local processor's IRQ work area into DEST. */ | 175 | /* Clobbers TMP, loads local processor's IRQ work area into DEST. */ |
173 | #define TRAP_LOAD_IRQ_WORK(DEST, TMP) \ | 176 | #define TRAP_LOAD_IRQ_WORK(DEST, TMP) \ |
174 | __GET_CPUID(TMP) \ | 177 | TRAP_LOAD_TRAP_BLOCK(DEST, TMP) \ |
175 | sethi %hi(__irq_work), DEST; \ | 178 | add DEST, TRAP_PER_CPU_IRQ_WORKLIST, DEST; |
176 | sllx TMP, 6, TMP; \ | ||
177 | or DEST, %lo(__irq_work), DEST; \ | ||
178 | add DEST, TMP, DEST; | ||
179 | 179 | ||
180 | /* Clobbers TMP, loads DEST with current thread info pointer. */ | 180 | /* Clobbers TMP, loads DEST with current thread info pointer. */ |
181 | #define TRAP_LOAD_THREAD_REG(DEST, TMP) \ | 181 | #define TRAP_LOAD_THREAD_REG(DEST, TMP) \ |
@@ -211,9 +211,10 @@ extern struct sun4v_2insn_patch_entry __sun4v_2insn_patch, | |||
211 | TRAP_LOAD_TRAP_BLOCK(DEST, TMP) \ | 211 | TRAP_LOAD_TRAP_BLOCK(DEST, TMP) \ |
212 | ldx [DEST + TRAP_PER_CPU_PGD_PADDR], DEST; | 212 | ldx [DEST + TRAP_PER_CPU_PGD_PADDR], DEST; |
213 | 213 | ||
214 | /* Clobbers TMP, loads local processor's IRQ work area into DEST. */ | ||
214 | #define TRAP_LOAD_IRQ_WORK(DEST, TMP) \ | 215 | #define TRAP_LOAD_IRQ_WORK(DEST, TMP) \ |
215 | sethi %hi(__irq_work), DEST; \ | 216 | TRAP_LOAD_TRAP_BLOCK(DEST, TMP) \ |
216 | or DEST, %lo(__irq_work), DEST; | 217 | add DEST, TRAP_PER_CPU_IRQ_WORKLIST, DEST; |
217 | 218 | ||
218 | #define TRAP_LOAD_THREAD_REG(DEST, TMP) \ | 219 | #define TRAP_LOAD_THREAD_REG(DEST, TMP) \ |
219 | TRAP_LOAD_TRAP_BLOCK(DEST, TMP) \ | 220 | TRAP_LOAD_TRAP_BLOCK(DEST, TMP) \ |
diff --git a/include/asm-sparc64/delay.h b/include/asm-sparc64/delay.h index 2901ea0c342d..a4aae6f80627 100644 --- a/include/asm-sparc64/delay.h +++ b/include/asm-sparc64/delay.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef __SPARC64_DELAY_H | 11 | #ifndef __SPARC64_DELAY_H |
12 | #define __SPARC64_DELAY_H | 12 | #define __SPARC64_DELAY_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/param.h> | 14 | #include <linux/param.h> |
16 | #include <asm/cpudata.h> | 15 | #include <asm/cpudata.h> |
17 | 16 | ||
diff --git a/include/asm-sparc64/dma-mapping.h b/include/asm-sparc64/dma-mapping.h index a8d39f23d43b..3c2b5bc8650b 100644 --- a/include/asm-sparc64/dma-mapping.h +++ b/include/asm-sparc64/dma-mapping.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_SPARC64_DMA_MAPPING_H | 1 | #ifndef _ASM_SPARC64_DMA_MAPPING_H |
2 | #define _ASM_SPARC64_DMA_MAPPING_H | 2 | #define _ASM_SPARC64_DMA_MAPPING_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_PCI | 5 | #ifdef CONFIG_PCI |
7 | 6 | ||
diff --git a/include/asm-sparc64/dma.h b/include/asm-sparc64/dma.h index 1aab3c8dce2b..27f65972b3bb 100644 --- a/include/asm-sparc64/dma.h +++ b/include/asm-sparc64/dma.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef _ASM_SPARC64_DMA_H | 7 | #ifndef _ASM_SPARC64_DMA_H |
8 | #define _ASM_SPARC64_DMA_H | 8 | #define _ASM_SPARC64_DMA_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <linux/kernel.h> | 10 | #include <linux/kernel.h> |
12 | #include <linux/types.h> | 11 | #include <linux/types.h> |
13 | #include <linux/spinlock.h> | 12 | #include <linux/spinlock.h> |
diff --git a/include/asm-sparc64/floppy.h b/include/asm-sparc64/floppy.h index 6a95d5d0c576..07ccd6f04b52 100644 --- a/include/asm-sparc64/floppy.h +++ b/include/asm-sparc64/floppy.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef __ASM_SPARC64_FLOPPY_H | 10 | #ifndef __ASM_SPARC64_FLOPPY_H |
11 | #define __ASM_SPARC64_FLOPPY_H | 11 | #define __ASM_SPARC64_FLOPPY_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/init.h> | 13 | #include <linux/init.h> |
15 | 14 | ||
16 | #include <asm/page.h> | 15 | #include <asm/page.h> |
diff --git a/include/asm-sparc64/hardirq.h b/include/asm-sparc64/hardirq.h index f0cf71376ec5..7c29fd1a87aa 100644 --- a/include/asm-sparc64/hardirq.h +++ b/include/asm-sparc64/hardirq.h | |||
@@ -12,6 +12,8 @@ | |||
12 | #define local_softirq_pending() \ | 12 | #define local_softirq_pending() \ |
13 | (local_cpu_data().__softirq_pending) | 13 | (local_cpu_data().__softirq_pending) |
14 | 14 | ||
15 | void ack_bad_irq(unsigned int irq); | ||
16 | |||
15 | #define HARDIRQ_BITS 8 | 17 | #define HARDIRQ_BITS 8 |
16 | 18 | ||
17 | #endif /* !(__SPARC64_HARDIRQ_H) */ | 19 | #endif /* !(__SPARC64_HARDIRQ_H) */ |
diff --git a/include/asm-sparc64/hw_irq.h b/include/asm-sparc64/hw_irq.h index 153cae2ddaee..599b3b073450 100644 --- a/include/asm-sparc64/hw_irq.h +++ b/include/asm-sparc64/hw_irq.h | |||
@@ -1,6 +1,6 @@ | |||
1 | #ifndef __ASM_SPARC64_HW_IRQ_H | 1 | #ifndef __ASM_SPARC64_HW_IRQ_H |
2 | #define __ASM_SPARC64_HW_IRQ_H | 2 | #define __ASM_SPARC64_HW_IRQ_H |
3 | 3 | ||
4 | /* Dummy include. */ | 4 | extern void hw_resend_irq(struct hw_interrupt_type *handler, unsigned int virt_irq); |
5 | 5 | ||
6 | #endif | 6 | #endif |
diff --git a/include/asm-sparc64/ide.h b/include/asm-sparc64/ide.h index c393f815b0be..55149cf933c2 100644 --- a/include/asm-sparc64/ide.h +++ b/include/asm-sparc64/ide.h | |||
@@ -10,7 +10,6 @@ | |||
10 | 10 | ||
11 | #ifdef __KERNEL__ | 11 | #ifdef __KERNEL__ |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <asm/pgalloc.h> | 13 | #include <asm/pgalloc.h> |
15 | #include <asm/io.h> | 14 | #include <asm/io.h> |
16 | #include <asm/spitfire.h> | 15 | #include <asm/spitfire.h> |
diff --git a/include/asm-sparc64/irq.h b/include/asm-sparc64/irq.h index de33d6e1afb5..905e59b4a737 100644 --- a/include/asm-sparc64/irq.h +++ b/include/asm-sparc64/irq.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef _SPARC64_IRQ_H | 8 | #ifndef _SPARC64_IRQ_H |
9 | #define _SPARC64_IRQ_H | 9 | #define _SPARC64_IRQ_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #include <linux/linkage.h> | 11 | #include <linux/linkage.h> |
13 | #include <linux/kernel.h> | 12 | #include <linux/kernel.h> |
14 | #include <linux/errno.h> | 13 | #include <linux/errno.h> |
@@ -16,58 +15,6 @@ | |||
16 | #include <asm/pil.h> | 15 | #include <asm/pil.h> |
17 | #include <asm/ptrace.h> | 16 | #include <asm/ptrace.h> |
18 | 17 | ||
19 | struct ino_bucket; | ||
20 | |||
21 | #define MAX_IRQ_DESC_ACTION 4 | ||
22 | |||
23 | struct irq_desc { | ||
24 | void (*pre_handler)(struct ino_bucket *, void *, void *); | ||
25 | void *pre_handler_arg1; | ||
26 | void *pre_handler_arg2; | ||
27 | u32 action_active_mask; | ||
28 | struct irqaction action[MAX_IRQ_DESC_ACTION]; | ||
29 | }; | ||
30 | |||
31 | /* You should not mess with this directly. That's the job of irq.c. | ||
32 | * | ||
33 | * If you make changes here, please update hand coded assembler of | ||
34 | * the vectored interrupt trap handler in entry.S -DaveM | ||
35 | * | ||
36 | * This is currently one DCACHE line, two buckets per L2 cache | ||
37 | * line. Keep this in mind please. | ||
38 | */ | ||
39 | struct ino_bucket { | ||
40 | /* Next handler in per-CPU PIL worklist. We know that | ||
41 | * bucket pointers have the high 32-bits clear, so to | ||
42 | * save space we only store the bits we need. | ||
43 | */ | ||
44 | /*0x00*/unsigned int irq_chain; | ||
45 | |||
46 | /* PIL to schedule this IVEC at. */ | ||
47 | /*0x04*/unsigned char pil; | ||
48 | |||
49 | /* If an IVEC arrives while irq_info is NULL, we | ||
50 | * set this to notify request_irq() about the event. | ||
51 | */ | ||
52 | /*0x05*/unsigned char pending; | ||
53 | |||
54 | /* Miscellaneous flags. */ | ||
55 | /*0x06*/unsigned char flags; | ||
56 | |||
57 | /* Currently unused. */ | ||
58 | /*0x07*/unsigned char __pad; | ||
59 | |||
60 | /* Reference to IRQ descriptor for this bucket. */ | ||
61 | /*0x08*/struct irq_desc *irq_info; | ||
62 | |||
63 | /* Sun5 Interrupt Clear Register. */ | ||
64 | /*0x10*/unsigned long iclr; | ||
65 | |||
66 | /* Sun5 Interrupt Mapping Register. */ | ||
67 | /*0x18*/unsigned long imap; | ||
68 | |||
69 | }; | ||
70 | |||
71 | /* IMAP/ICLR register defines */ | 18 | /* IMAP/ICLR register defines */ |
72 | #define IMAP_VALID 0x80000000 /* IRQ Enabled */ | 19 | #define IMAP_VALID 0x80000000 /* IRQ Enabled */ |
73 | #define IMAP_TID_UPA 0x7c000000 /* UPA TargetID */ | 20 | #define IMAP_TID_UPA 0x7c000000 /* UPA TargetID */ |
@@ -85,36 +32,20 @@ struct ino_bucket { | |||
85 | #define ICLR_TRANSMIT 0x00000001 /* Transmit state */ | 32 | #define ICLR_TRANSMIT 0x00000001 /* Transmit state */ |
86 | #define ICLR_PENDING 0x00000003 /* Pending state */ | 33 | #define ICLR_PENDING 0x00000003 /* Pending state */ |
87 | 34 | ||
88 | /* Only 8-bits are available, be careful. -DaveM */ | 35 | /* The largest number of unique interrupt sources we support. |
89 | #define IBF_PCI 0x02 /* PSYCHO/SABRE/SCHIZO PCI interrupt. */ | 36 | * If this needs to ever be larger than 255, you need to change |
90 | #define IBF_ACTIVE 0x04 /* Interrupt is active and has a handler.*/ | 37 | * the type of ino_bucket->virt_irq as appropriate. |
91 | #define IBF_INPROGRESS 0x10 /* IRQ is being serviced. */ | 38 | * |
92 | 39 | * ino_bucket->virt_irq allocation is made during {sun4v_,}build_irq(). | |
93 | #define NUM_IVECS (IMAP_INR + 1) | 40 | */ |
94 | extern struct ino_bucket ivector_table[NUM_IVECS]; | 41 | #define NR_IRQS 255 |
95 | |||
96 | #define __irq_ino(irq) \ | ||
97 | (((struct ino_bucket *)(unsigned long)(irq)) - &ivector_table[0]) | ||
98 | #define __irq_pil(irq) ((struct ino_bucket *)(unsigned long)(irq))->pil | ||
99 | #define __bucket(irq) ((struct ino_bucket *)(unsigned long)(irq)) | ||
100 | #define __irq(bucket) ((unsigned int)(unsigned long)(bucket)) | ||
101 | |||
102 | static __inline__ char *__irq_itoa(unsigned int irq) | ||
103 | { | ||
104 | static char buff[16]; | ||
105 | |||
106 | sprintf(buff, "%d,%x", __irq_pil(irq), (unsigned int)__irq_ino(irq)); | ||
107 | return buff; | ||
108 | } | ||
109 | |||
110 | #define NR_IRQS 16 | ||
111 | 42 | ||
43 | extern void irq_install_pre_handler(int virt_irq, | ||
44 | void (*func)(unsigned int, void *, void *), | ||
45 | void *arg1, void *arg2); | ||
112 | #define irq_canonicalize(irq) (irq) | 46 | #define irq_canonicalize(irq) (irq) |
113 | extern void disable_irq(unsigned int); | 47 | extern unsigned int build_irq(int inofixup, unsigned long iclr, unsigned long imap); |
114 | #define disable_irq_nosync disable_irq | 48 | extern unsigned int sun4v_build_irq(u32 devhandle, unsigned int devino); |
115 | extern void enable_irq(unsigned int); | ||
116 | extern unsigned int build_irq(int pil, int inofixup, unsigned long iclr, unsigned long imap); | ||
117 | extern unsigned int sun4v_build_irq(u32 devhandle, unsigned int devino, int pil, unsigned char flags); | ||
118 | extern unsigned int sbus_build_irq(void *sbus, unsigned int ino); | 49 | extern unsigned int sbus_build_irq(void *sbus, unsigned int ino); |
119 | 50 | ||
120 | static __inline__ void set_softint(unsigned long bits) | 51 | static __inline__ void set_softint(unsigned long bits) |
@@ -140,8 +71,4 @@ static __inline__ unsigned long get_softint(void) | |||
140 | return retval; | 71 | return retval; |
141 | } | 72 | } |
142 | 73 | ||
143 | struct irqaction; | ||
144 | struct pt_regs; | ||
145 | int handle_IRQ_event(unsigned int, struct pt_regs *, struct irqaction *); | ||
146 | |||
147 | #endif | 74 | #endif |
diff --git a/include/asm-sparc64/kprobes.h b/include/asm-sparc64/kprobes.h index e4efe652b54b..e9bb26f770ed 100644 --- a/include/asm-sparc64/kprobes.h +++ b/include/asm-sparc64/kprobes.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _SPARC64_KPROBES_H | 1 | #ifndef _SPARC64_KPROBES_H |
2 | #define _SPARC64_KPROBES_H | 2 | #define _SPARC64_KPROBES_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/types.h> | 4 | #include <linux/types.h> |
6 | #include <linux/percpu.h> | 5 | #include <linux/percpu.h> |
7 | 6 | ||
diff --git a/include/asm-sparc64/mc146818rtc.h b/include/asm-sparc64/mc146818rtc.h index 75bd572b35fe..e9c0fcc25c6f 100644 --- a/include/asm-sparc64/mc146818rtc.h +++ b/include/asm-sparc64/mc146818rtc.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #ifndef __ASM_SPARC64_MC146818RTC_H | 4 | #ifndef __ASM_SPARC64_MC146818RTC_H |
5 | #define __ASM_SPARC64_MC146818RTC_H | 5 | #define __ASM_SPARC64_MC146818RTC_H |
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | #include <asm/io.h> | 7 | #include <asm/io.h> |
9 | 8 | ||
10 | #ifndef RTC_PORT | 9 | #ifndef RTC_PORT |
diff --git a/include/asm-sparc64/mmu.h b/include/asm-sparc64/mmu.h index 2d4f2ea9568a..70af4b6ce136 100644 --- a/include/asm-sparc64/mmu.h +++ b/include/asm-sparc64/mmu.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __MMU_H | 1 | #ifndef __MMU_H |
2 | #define __MMU_H | 2 | #define __MMU_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/page.h> | 4 | #include <asm/page.h> |
6 | #include <asm/const.h> | 5 | #include <asm/const.h> |
7 | #include <asm/hypervisor.h> | 6 | #include <asm/hypervisor.h> |
diff --git a/include/asm-sparc64/oplib.h b/include/asm-sparc64/oplib.h index c754676e13ef..dea3e73f0955 100644 --- a/include/asm-sparc64/oplib.h +++ b/include/asm-sparc64/oplib.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef __SPARC64_OPLIB_H | 9 | #ifndef __SPARC64_OPLIB_H |
10 | #define __SPARC64_OPLIB_H | 10 | #define __SPARC64_OPLIB_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <asm/openprom.h> | 12 | #include <asm/openprom.h> |
14 | 13 | ||
15 | /* OBP version string. */ | 14 | /* OBP version string. */ |
diff --git a/include/asm-sparc64/page.h b/include/asm-sparc64/page.h index aabb21906724..fdf0ceb76028 100644 --- a/include/asm-sparc64/page.h +++ b/include/asm-sparc64/page.h | |||
@@ -3,7 +3,6 @@ | |||
3 | #ifndef _SPARC64_PAGE_H | 3 | #ifndef _SPARC64_PAGE_H |
4 | #define _SPARC64_PAGE_H | 4 | #define _SPARC64_PAGE_H |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <asm/const.h> | 6 | #include <asm/const.h> |
8 | 7 | ||
9 | #if defined(CONFIG_SPARC64_PAGE_SIZE_8KB) | 8 | #if defined(CONFIG_SPARC64_PAGE_SIZE_8KB) |
diff --git a/include/asm-sparc64/param.h b/include/asm-sparc64/param.h index a1cd4974630b..f0125cf5a9df 100644 --- a/include/asm-sparc64/param.h +++ b/include/asm-sparc64/param.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASMSPARC64_PARAM_H | 1 | #ifndef _ASMSPARC64_PARAM_H |
2 | #define _ASMSPARC64_PARAM_H | 2 | #define _ASMSPARC64_PARAM_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef __KERNEL__ | 5 | #ifdef __KERNEL__ |
7 | # define HZ CONFIG_HZ /* Internal kernel timer frequency */ | 6 | # define HZ CONFIG_HZ /* Internal kernel timer frequency */ |
diff --git a/include/asm-sparc64/pgalloc.h b/include/asm-sparc64/pgalloc.h index 12e4a273bd43..010f9cd0a672 100644 --- a/include/asm-sparc64/pgalloc.h +++ b/include/asm-sparc64/pgalloc.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #ifndef _SPARC64_PGALLOC_H | 2 | #ifndef _SPARC64_PGALLOC_H |
3 | #define _SPARC64_PGALLOC_H | 3 | #define _SPARC64_PGALLOC_H |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | #include <linux/kernel.h> | 5 | #include <linux/kernel.h> |
7 | #include <linux/sched.h> | 6 | #include <linux/sched.h> |
8 | #include <linux/mm.h> | 7 | #include <linux/mm.h> |
diff --git a/include/asm-sparc64/pgtable.h b/include/asm-sparc64/pgtable.h index cd464f469a2c..4e218814bb3c 100644 --- a/include/asm-sparc64/pgtable.h +++ b/include/asm-sparc64/pgtable.h | |||
@@ -14,7 +14,6 @@ | |||
14 | 14 | ||
15 | #include <asm-generic/pgtable-nopud.h> | 15 | #include <asm-generic/pgtable-nopud.h> |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | #include <linux/compiler.h> | 17 | #include <linux/compiler.h> |
19 | #include <asm/types.h> | 18 | #include <asm/types.h> |
20 | #include <asm/spitfire.h> | 19 | #include <asm/spitfire.h> |
diff --git a/include/asm-sparc64/pil.h b/include/asm-sparc64/pil.h index 79f827eb3f5d..72927749aebf 100644 --- a/include/asm-sparc64/pil.h +++ b/include/asm-sparc64/pil.h | |||
@@ -5,9 +5,9 @@ | |||
5 | /* To avoid some locking problems, we hard allocate certain PILs | 5 | /* To avoid some locking problems, we hard allocate certain PILs |
6 | * for SMP cross call messages that must do a etrap/rtrap. | 6 | * for SMP cross call messages that must do a etrap/rtrap. |
7 | * | 7 | * |
8 | * A cli() does not block the cross call delivery, so when SMP | 8 | * A local_irq_disable() does not block the cross call delivery, so |
9 | * locking is an issue we reschedule the event into a PIL interrupt | 9 | * when SMP locking is an issue we reschedule the event into a PIL |
10 | * which is blocked by cli(). | 10 | * interrupt which is blocked by local_irq_disable(). |
11 | * | 11 | * |
12 | * In fact any XCALL which has to etrap/rtrap has a problem because | 12 | * In fact any XCALL which has to etrap/rtrap has a problem because |
13 | * it is difficult to prevent rtrap from running BH's, and that would | 13 | * it is difficult to prevent rtrap from running BH's, and that would |
@@ -17,6 +17,7 @@ | |||
17 | #define PIL_SMP_RECEIVE_SIGNAL 2 | 17 | #define PIL_SMP_RECEIVE_SIGNAL 2 |
18 | #define PIL_SMP_CAPTURE 3 | 18 | #define PIL_SMP_CAPTURE 3 |
19 | #define PIL_SMP_CTX_NEW_VERSION 4 | 19 | #define PIL_SMP_CTX_NEW_VERSION 4 |
20 | #define PIL_DEVICE_IRQ 5 | ||
20 | 21 | ||
21 | #ifndef __ASSEMBLY__ | 22 | #ifndef __ASSEMBLY__ |
22 | #define PIL_RESERVED(PIL) ((PIL) == PIL_SMP_CALL_FUNC || \ | 23 | #define PIL_RESERVED(PIL) ((PIL) == PIL_SMP_CALL_FUNC || \ |
diff --git a/include/asm-sparc64/processor.h b/include/asm-sparc64/processor.h index c6896b88283e..66dd2fa0e319 100644 --- a/include/asm-sparc64/processor.h +++ b/include/asm-sparc64/processor.h | |||
@@ -13,7 +13,6 @@ | |||
13 | */ | 13 | */ |
14 | #define current_text_addr() ({ void *pc; __asm__("rd %%pc, %0" : "=r" (pc)); pc; }) | 14 | #define current_text_addr() ({ void *pc; __asm__("rd %%pc, %0" : "=r" (pc)); pc; }) |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <asm/asi.h> | 16 | #include <asm/asi.h> |
18 | #include <asm/a.out.h> | 17 | #include <asm/a.out.h> |
19 | #include <asm/pstate.h> | 18 | #include <asm/pstate.h> |
diff --git a/include/asm-sparc64/siginfo.h b/include/asm-sparc64/siginfo.h index df17e47abc1c..c96e6c30f8b0 100644 --- a/include/asm-sparc64/siginfo.h +++ b/include/asm-sparc64/siginfo.h | |||
@@ -11,7 +11,6 @@ | |||
11 | 11 | ||
12 | #ifdef __KERNEL__ | 12 | #ifdef __KERNEL__ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/compat.h> | 14 | #include <linux/compat.h> |
16 | 15 | ||
17 | #ifdef CONFIG_COMPAT | 16 | #ifdef CONFIG_COMPAT |
diff --git a/include/asm-sparc64/signal.h b/include/asm-sparc64/signal.h index e3059bb4a465..fdc42a14d4e6 100644 --- a/include/asm-sparc64/signal.h +++ b/include/asm-sparc64/signal.h | |||
@@ -6,7 +6,6 @@ | |||
6 | 6 | ||
7 | #ifdef __KERNEL__ | 7 | #ifdef __KERNEL__ |
8 | #ifndef __ASSEMBLY__ | 8 | #ifndef __ASSEMBLY__ |
9 | #include <linux/config.h> | ||
10 | #include <linux/personality.h> | 9 | #include <linux/personality.h> |
11 | #include <linux/types.h> | 10 | #include <linux/types.h> |
12 | #include <linux/compat.h> | 11 | #include <linux/compat.h> |
diff --git a/include/asm-sparc64/smp.h b/include/asm-sparc64/smp.h index 89d86ecaab24..388249b751c3 100644 --- a/include/asm-sparc64/smp.h +++ b/include/asm-sparc64/smp.h | |||
@@ -6,7 +6,6 @@ | |||
6 | #ifndef _SPARC64_SMP_H | 6 | #ifndef _SPARC64_SMP_H |
7 | #define _SPARC64_SMP_H | 7 | #define _SPARC64_SMP_H |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <linux/threads.h> | 9 | #include <linux/threads.h> |
11 | #include <asm/asi.h> | 10 | #include <asm/asi.h> |
12 | #include <asm/starfire.h> | 11 | #include <asm/starfire.h> |
diff --git a/include/asm-sparc64/spinlock.h b/include/asm-sparc64/spinlock.h index 508c416e9d6a..bd5ffc76bc7e 100644 --- a/include/asm-sparc64/spinlock.h +++ b/include/asm-sparc64/spinlock.h | |||
@@ -6,7 +6,6 @@ | |||
6 | #ifndef __SPARC64_SPINLOCK_H | 6 | #ifndef __SPARC64_SPINLOCK_H |
7 | #define __SPARC64_SPINLOCK_H | 7 | #define __SPARC64_SPINLOCK_H |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <linux/threads.h> /* For NR_CPUS */ | 9 | #include <linux/threads.h> /* For NR_CPUS */ |
11 | 10 | ||
12 | #ifndef __ASSEMBLY__ | 11 | #ifndef __ASSEMBLY__ |
diff --git a/include/asm-sparc64/system.h b/include/asm-sparc64/system.h index a18ec87a52c1..4ca68600c670 100644 --- a/include/asm-sparc64/system.h +++ b/include/asm-sparc64/system.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #ifndef __SPARC64_SYSTEM_H | 2 | #ifndef __SPARC64_SYSTEM_H |
3 | #define __SPARC64_SYSTEM_H | 3 | #define __SPARC64_SYSTEM_H |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | #include <asm/ptrace.h> | 5 | #include <asm/ptrace.h> |
7 | #include <asm/processor.h> | 6 | #include <asm/processor.h> |
8 | #include <asm/visasm.h> | 7 | #include <asm/visasm.h> |
diff --git a/include/asm-sparc64/timer.h b/include/asm-sparc64/timer.h index edc8e08c3a39..d435594df786 100644 --- a/include/asm-sparc64/timer.h +++ b/include/asm-sparc64/timer.h | |||
@@ -9,7 +9,6 @@ | |||
9 | 9 | ||
10 | #include <linux/types.h> | 10 | #include <linux/types.h> |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | struct sparc64_tick_ops { | 13 | struct sparc64_tick_ops { |
15 | void (*init_tick)(unsigned long); | 14 | void (*init_tick)(unsigned long); |
diff --git a/include/asm-sparc64/tlb.h b/include/asm-sparc64/tlb.h index 61c01882b562..7af1e1109c49 100644 --- a/include/asm-sparc64/tlb.h +++ b/include/asm-sparc64/tlb.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _SPARC64_TLB_H | 1 | #ifndef _SPARC64_TLB_H |
2 | #define _SPARC64_TLB_H | 2 | #define _SPARC64_TLB_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/swap.h> | 4 | #include <linux/swap.h> |
6 | #include <asm/pgalloc.h> | 5 | #include <asm/pgalloc.h> |
7 | #include <asm/tlbflush.h> | 6 | #include <asm/tlbflush.h> |
diff --git a/include/asm-sparc64/tlbflush.h b/include/asm-sparc64/tlbflush.h index e3a7c453b500..3487328570ed 100644 --- a/include/asm-sparc64/tlbflush.h +++ b/include/asm-sparc64/tlbflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _SPARC64_TLBFLUSH_H | 1 | #ifndef _SPARC64_TLBFLUSH_H |
2 | #define _SPARC64_TLBFLUSH_H | 2 | #define _SPARC64_TLBFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | #include <asm/mmu_context.h> | 5 | #include <asm/mmu_context.h> |
7 | 6 | ||
diff --git a/include/asm-sparc64/ttable.h b/include/asm-sparc64/ttable.h index 2d5e3c464df5..f2352606a79f 100644 --- a/include/asm-sparc64/ttable.h +++ b/include/asm-sparc64/ttable.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #ifndef _SPARC64_TTABLE_H | 2 | #ifndef _SPARC64_TTABLE_H |
3 | #define _SPARC64_TTABLE_H | 3 | #define _SPARC64_TTABLE_H |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | #include <asm/utrap.h> | 5 | #include <asm/utrap.h> |
7 | 6 | ||
8 | #ifdef __ASSEMBLY__ | 7 | #ifdef __ASSEMBLY__ |
diff --git a/include/asm-sparc64/unistd.h b/include/asm-sparc64/unistd.h index 998ef4ab0e06..badc73fdcb97 100644 --- a/include/asm-sparc64/unistd.h +++ b/include/asm-sparc64/unistd.h | |||
@@ -321,6 +321,7 @@ | |||
321 | #define __NR_set_robust_list 300 | 321 | #define __NR_set_robust_list 300 |
322 | #define __NR_get_robust_list 301 | 322 | #define __NR_get_robust_list 301 |
323 | 323 | ||
324 | #ifdef __KERNEL__ | ||
324 | /* WARNING: You MAY NOT add syscall numbers larger than 301, since | 325 | /* WARNING: You MAY NOT add syscall numbers larger than 301, since |
325 | * all of the syscall tables in the Sparc kernel are | 326 | * all of the syscall tables in the Sparc kernel are |
326 | * sized to have 301 entries (starting at zero). Therefore | 327 | * sized to have 301 entries (starting at zero). Therefore |
@@ -487,7 +488,6 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
487 | 488 | ||
488 | #endif /* __KERNEL_SYSCALLS__ */ | 489 | #endif /* __KERNEL_SYSCALLS__ */ |
489 | 490 | ||
490 | #ifdef __KERNEL__ | ||
491 | /* sysconf options, for SunOS compatibility */ | 491 | /* sysconf options, for SunOS compatibility */ |
492 | #define _SC_ARG_MAX 1 | 492 | #define _SC_ARG_MAX 1 |
493 | #define _SC_CHILD_MAX 2 | 493 | #define _SC_CHILD_MAX 2 |
@@ -521,7 +521,6 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
521 | #define __ARCH_WANT_SYS_SIGPROCMASK | 521 | #define __ARCH_WANT_SYS_SIGPROCMASK |
522 | #define __ARCH_WANT_SYS_RT_SIGSUSPEND | 522 | #define __ARCH_WANT_SYS_RT_SIGSUSPEND |
523 | #define __ARCH_WANT_COMPAT_SYS_RT_SIGSUSPEND | 523 | #define __ARCH_WANT_COMPAT_SYS_RT_SIGSUSPEND |
524 | #endif | ||
525 | 524 | ||
526 | /* | 525 | /* |
527 | * "Conditional" syscalls | 526 | * "Conditional" syscalls |
@@ -531,4 +530,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
531 | */ | 530 | */ |
532 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 531 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
533 | 532 | ||
533 | #endif /* __KERNEL__ */ | ||
534 | #endif /* _SPARC64_UNISTD_H */ | 534 | #endif /* _SPARC64_UNISTD_H */ |
diff --git a/include/asm-sparc64/vga.h b/include/asm-sparc64/vga.h index 9c57eb363b40..c69d5b2ba19a 100644 --- a/include/asm-sparc64/vga.h +++ b/include/asm-sparc64/vga.h | |||
@@ -28,6 +28,6 @@ static inline u16 scr_readw(const u16 *addr) | |||
28 | return *addr; | 28 | return *addr; |
29 | } | 29 | } |
30 | 30 | ||
31 | #define VGA_MAP_MEM(x) (x) | 31 | #define VGA_MAP_MEM(x,s) (x) |
32 | 32 | ||
33 | #endif | 33 | #endif |
diff --git a/include/asm-um/a.out.h b/include/asm-um/a.out.h index 7c26265e1d7a..50cee7b296f4 100644 --- a/include/asm-um/a.out.h +++ b/include/asm-um/a.out.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __UM_A_OUT_H | 1 | #ifndef __UM_A_OUT_H |
2 | #define __UM_A_OUT_H | 2 | #define __UM_A_OUT_H |
3 | 3 | ||
4 | #include "linux/config.h" | ||
5 | #include "asm/arch/a.out.h" | 4 | #include "asm/arch/a.out.h" |
6 | #include "choose-mode.h" | 5 | #include "choose-mode.h" |
7 | 6 | ||
diff --git a/include/asm-um/cache.h b/include/asm-um/cache.h index 3d0587075521..19e1bdd67416 100644 --- a/include/asm-um/cache.h +++ b/include/asm-um/cache.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __UM_CACHE_H | 1 | #ifndef __UM_CACHE_H |
2 | #define __UM_CACHE_H | 2 | #define __UM_CACHE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #if defined(CONFIG_UML_X86) && !defined(CONFIG_64BIT) | 5 | #if defined(CONFIG_UML_X86) && !defined(CONFIG_64BIT) |
7 | # define L1_CACHE_SHIFT (CONFIG_X86_L1_CACHE_SHIFT) | 6 | # define L1_CACHE_SHIFT (CONFIG_X86_L1_CACHE_SHIFT) |
diff --git a/include/asm-um/elf-ppc.h b/include/asm-um/elf-ppc.h index 2998cf925042..99711134e477 100644 --- a/include/asm-um/elf-ppc.h +++ b/include/asm-um/elf-ppc.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __UM_ELF_PPC_H | 1 | #ifndef __UM_ELF_PPC_H |
2 | #define __UM_ELF_PPC_H | 2 | #define __UM_ELF_PPC_H |
3 | 3 | ||
4 | #include "linux/config.h" | ||
5 | 4 | ||
6 | extern long elf_aux_hwcap; | 5 | extern long elf_aux_hwcap; |
7 | #define ELF_HWCAP (elf_aux_hwcap) | 6 | #define ELF_HWCAP (elf_aux_hwcap) |
diff --git a/include/asm-um/fixmap.h b/include/asm-um/fixmap.h index ae0ca3932d50..d352a35cfafb 100644 --- a/include/asm-um/fixmap.h +++ b/include/asm-um/fixmap.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __UM_FIXMAP_H | 1 | #ifndef __UM_FIXMAP_H |
2 | #define __UM_FIXMAP_H | 2 | #define __UM_FIXMAP_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/kmap_types.h> | 4 | #include <asm/kmap_types.h> |
6 | #include <asm/archparam.h> | 5 | #include <asm/archparam.h> |
7 | #include <asm/elf.h> | 6 | #include <asm/elf.h> |
diff --git a/include/asm-um/hardirq.h b/include/asm-um/hardirq.h index 1224b2690a23..313ebb8a2566 100644 --- a/include/asm-um/hardirq.h +++ b/include/asm-um/hardirq.h | |||
@@ -3,7 +3,6 @@ | |||
3 | #ifndef __ASM_UM_HARDIRQ_H | 3 | #ifndef __ASM_UM_HARDIRQ_H |
4 | #define __ASM_UM_HARDIRQ_H | 4 | #define __ASM_UM_HARDIRQ_H |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <linux/threads.h> | 6 | #include <linux/threads.h> |
8 | #include <linux/irq.h> | 7 | #include <linux/irq.h> |
9 | 8 | ||
diff --git a/include/asm-um/linkage.h b/include/asm-um/linkage.h index e3d62dcbd356..78b862472b36 100644 --- a/include/asm-um/linkage.h +++ b/include/asm-um/linkage.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #include "asm/arch/linkage.h" | 4 | #include "asm/arch/linkage.h" |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | /* <linux/linkage.h> will pick sane defaults */ | 7 | /* <linux/linkage.h> will pick sane defaults */ |
9 | #ifdef CONFIG_GPROF | 8 | #ifdef CONFIG_GPROF |
diff --git a/include/asm-um/mmu_context.h b/include/asm-um/mmu_context.h index 9a0e48eb542e..f709c784bf12 100644 --- a/include/asm-um/mmu_context.h +++ b/include/asm-um/mmu_context.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #define __UM_MMU_CONTEXT_H | 7 | #define __UM_MMU_CONTEXT_H |
8 | 8 | ||
9 | #include "linux/sched.h" | 9 | #include "linux/sched.h" |
10 | #include "linux/config.h" | ||
11 | #include "choose-mode.h" | 10 | #include "choose-mode.h" |
12 | #include "um_mmu.h" | 11 | #include "um_mmu.h" |
13 | 12 | ||
diff --git a/include/asm-um/page.h b/include/asm-um/page.h index 41364330aff1..4296d3135aa9 100644 --- a/include/asm-um/page.h +++ b/include/asm-um/page.h | |||
@@ -9,7 +9,6 @@ | |||
9 | 9 | ||
10 | struct page; | 10 | struct page; |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <asm/vm-flags.h> | 12 | #include <asm/vm-flags.h> |
14 | 13 | ||
15 | /* PAGE_SHIFT determines the page size */ | 14 | /* PAGE_SHIFT determines the page size */ |
diff --git a/include/asm-um/pgalloc.h b/include/asm-um/pgalloc.h index ea49411236dc..34ab268ef40e 100644 --- a/include/asm-um/pgalloc.h +++ b/include/asm-um/pgalloc.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef __UM_PGALLOC_H | 8 | #ifndef __UM_PGALLOC_H |
9 | #define __UM_PGALLOC_H | 9 | #define __UM_PGALLOC_H |
10 | 10 | ||
11 | #include "linux/config.h" | ||
12 | #include "linux/mm.h" | 11 | #include "linux/mm.h" |
13 | #include "asm/fixmap.h" | 12 | #include "asm/fixmap.h" |
14 | 13 | ||
diff --git a/include/asm-um/processor-generic.h b/include/asm-um/processor-generic.h index da07a69ce82a..824c28896382 100644 --- a/include/asm-um/processor-generic.h +++ b/include/asm-um/processor-generic.h | |||
@@ -10,7 +10,6 @@ struct pt_regs; | |||
10 | 10 | ||
11 | struct task_struct; | 11 | struct task_struct; |
12 | 12 | ||
13 | #include "linux/config.h" | ||
14 | #include "asm/ptrace.h" | 13 | #include "asm/ptrace.h" |
15 | #include "choose-mode.h" | 14 | #include "choose-mode.h" |
16 | #include "registers.h" | 15 | #include "registers.h" |
diff --git a/include/asm-um/ptrace-generic.h b/include/asm-um/ptrace-generic.h index 503484305e67..a36f5371b36b 100644 --- a/include/asm-um/ptrace-generic.h +++ b/include/asm-um/ptrace-generic.h | |||
@@ -8,7 +8,6 @@ | |||
8 | 8 | ||
9 | #ifndef __ASSEMBLY__ | 9 | #ifndef __ASSEMBLY__ |
10 | 10 | ||
11 | #include "linux/config.h" | ||
12 | 11 | ||
13 | #define pt_regs pt_regs_subarch | 12 | #define pt_regs pt_regs_subarch |
14 | #define show_regs show_regs_subarch | 13 | #define show_regs show_regs_subarch |
diff --git a/include/asm-um/smp.h b/include/asm-um/smp.h index aeda6657f366..ca552261ed1f 100644 --- a/include/asm-um/smp.h +++ b/include/asm-um/smp.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #ifdef CONFIG_SMP | 4 | #ifdef CONFIG_SMP |
5 | 5 | ||
6 | #include "linux/config.h" | ||
7 | #include "linux/bitops.h" | 6 | #include "linux/bitops.h" |
8 | #include "asm/current.h" | 7 | #include "asm/current.h" |
9 | #include "linux/cpumask.h" | 8 | #include "linux/cpumask.h" |
diff --git a/include/asm-um/thread_info.h b/include/asm-um/thread_info.h index f166b9837c6a..261e2f4528f6 100644 --- a/include/asm-um/thread_info.h +++ b/include/asm-um/thread_info.h | |||
@@ -8,7 +8,6 @@ | |||
8 | 8 | ||
9 | #ifndef __ASSEMBLY__ | 9 | #ifndef __ASSEMBLY__ |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #include <asm/processor.h> | 11 | #include <asm/processor.h> |
13 | #include <asm/types.h> | 12 | #include <asm/types.h> |
14 | 13 | ||
diff --git a/include/asm-v850/atomic.h b/include/asm-v850/atomic.h index 166df00457ea..e4e57de08f73 100644 --- a/include/asm-v850/atomic.h +++ b/include/asm-v850/atomic.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #ifndef __V850_ATOMIC_H__ | 14 | #ifndef __V850_ATOMIC_H__ |
15 | #define __V850_ATOMIC_H__ | 15 | #define __V850_ATOMIC_H__ |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | 17 | ||
19 | #include <asm/system.h> | 18 | #include <asm/system.h> |
20 | 19 | ||
diff --git a/include/asm-v850/bitops.h b/include/asm-v850/bitops.h index 1f6fd5ab4177..1fa99baf4e25 100644 --- a/include/asm-v850/bitops.h +++ b/include/asm-v850/bitops.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #define __V850_BITOPS_H__ | 14 | #define __V850_BITOPS_H__ |
15 | 15 | ||
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | #include <linux/compiler.h> /* unlikely */ | 17 | #include <linux/compiler.h> /* unlikely */ |
19 | #include <asm/byteorder.h> /* swab32 */ | 18 | #include <asm/byteorder.h> /* swab32 */ |
20 | #include <asm/system.h> /* interrupt enable/disable */ | 19 | #include <asm/system.h> /* interrupt enable/disable */ |
diff --git a/include/asm-v850/dma-mapping.h b/include/asm-v850/dma-mapping.h index c63fb50ec9ef..1cc42c603a1b 100644 --- a/include/asm-v850/dma-mapping.h +++ b/include/asm-v850/dma-mapping.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __V850_DMA_MAPPING_H__ | 1 | #ifndef __V850_DMA_MAPPING_H__ |
2 | #define __V850_DMA_MAPPING_H__ | 2 | #define __V850_DMA_MAPPING_H__ |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_PCI | 5 | #ifdef CONFIG_PCI |
7 | #include <asm-generic/dma-mapping.h> | 6 | #include <asm-generic/dma-mapping.h> |
diff --git a/include/asm-v850/hardirq.h b/include/asm-v850/hardirq.h index d98488cd5af1..04e20127c5af 100644 --- a/include/asm-v850/hardirq.h +++ b/include/asm-v850/hardirq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __V850_HARDIRQ_H__ | 1 | #ifndef __V850_HARDIRQ_H__ |
2 | #define __V850_HARDIRQ_H__ | 2 | #define __V850_HARDIRQ_H__ |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/threads.h> | 4 | #include <linux/threads.h> |
6 | #include <linux/cache.h> | 5 | #include <linux/cache.h> |
7 | 6 | ||
diff --git a/include/asm-v850/machdep.h b/include/asm-v850/machdep.h index 98d8bf63970e..f1e3b8b91508 100644 --- a/include/asm-v850/machdep.h +++ b/include/asm-v850/machdep.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #ifndef __V850_MACHDEP_H__ | 14 | #ifndef __V850_MACHDEP_H__ |
15 | #define __V850_MACHDEP_H__ | 15 | #define __V850_MACHDEP_H__ |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | 17 | ||
19 | /* chips */ | 18 | /* chips */ |
20 | #ifdef CONFIG_V850E_MA1 | 19 | #ifdef CONFIG_V850E_MA1 |
diff --git a/include/asm-v850/pgtable.h b/include/asm-v850/pgtable.h index 3cf8775ce85f..1ea2a900f0f8 100644 --- a/include/asm-v850/pgtable.h +++ b/include/asm-v850/pgtable.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #include <asm-generic/4level-fixup.h> | 4 | #include <asm-generic/4level-fixup.h> |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | #include <asm/page.h> | 6 | #include <asm/page.h> |
8 | 7 | ||
9 | 8 | ||
diff --git a/include/asm-v850/processor.h b/include/asm-v850/processor.h index 2d31308935a0..6965b66ccaed 100644 --- a/include/asm-v850/processor.h +++ b/include/asm-v850/processor.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #ifndef __V850_PROCESSOR_H__ | 14 | #ifndef __V850_PROCESSOR_H__ |
15 | #define __V850_PROCESSOR_H__ | 15 | #define __V850_PROCESSOR_H__ |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | #ifndef __ASSEMBLY__ /* <linux/thread_info.h> is not asm-safe. */ | 17 | #ifndef __ASSEMBLY__ /* <linux/thread_info.h> is not asm-safe. */ |
19 | #include <linux/thread_info.h> | 18 | #include <linux/thread_info.h> |
20 | #endif | 19 | #endif |
diff --git a/include/asm-v850/serial.h b/include/asm-v850/serial.h index 8c2a609ba2b0..36d8f4cbbf39 100644 --- a/include/asm-v850/serial.h +++ b/include/asm-v850/serial.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * Copyright (C) 1999 by Ralf Baechle | 6 | * Copyright (C) 1999 by Ralf Baechle |
7 | * Copyright (C) 1999, 2000 Silicon Graphics, Inc. | 7 | * Copyright (C) 1999, 2000 Silicon Graphics, Inc. |
8 | */ | 8 | */ |
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | #ifdef CONFIG_RTE_CB_ME2 | 10 | #ifdef CONFIG_RTE_CB_ME2 |
12 | 11 | ||
diff --git a/include/asm-v850/unistd.h b/include/asm-v850/unistd.h index 82460a7bb233..bcb44bfe577a 100644 --- a/include/asm-v850/unistd.h +++ b/include/asm-v850/unistd.h | |||
@@ -14,8 +14,6 @@ | |||
14 | #ifndef __V850_UNISTD_H__ | 14 | #ifndef __V850_UNISTD_H__ |
15 | #define __V850_UNISTD_H__ | 15 | #define __V850_UNISTD_H__ |
16 | 16 | ||
17 | #include <asm/clinkage.h> | ||
18 | |||
19 | #define __NR_restart_syscall 0 | 17 | #define __NR_restart_syscall 0 |
20 | #define __NR_exit 1 | 18 | #define __NR_exit 1 |
21 | #define __NR_fork 2 | 19 | #define __NR_fork 2 |
@@ -237,10 +235,9 @@ | |||
237 | except the syscall number (r12). */ | 235 | except the syscall number (r12). */ |
238 | #define SYSCALL_SHORT_CLOBBERS SYSCALL_CLOBBERS, "r13", "r14" | 236 | #define SYSCALL_SHORT_CLOBBERS SYSCALL_CLOBBERS, "r13", "r14" |
239 | 237 | ||
238 | #ifdef __KERNEL__ | ||
240 | 239 | ||
241 | /* User programs sometimes end up including this header file | 240 | #include <asm/clinkage.h> |
242 | (indirectly, via uClibc header files), so I'm a bit nervous just | ||
243 | including <linux/compiler.h>. */ | ||
244 | 241 | ||
245 | #define __syscall_return(type, res) \ | 242 | #define __syscall_return(type, res) \ |
246 | do { \ | 243 | do { \ |
@@ -368,7 +365,6 @@ type name (atype a, btype b, ctype c, dtype d, etype e, ftype f) \ | |||
368 | } | 365 | } |
369 | 366 | ||
370 | 367 | ||
371 | #ifdef __KERNEL__ | ||
372 | #define __ARCH_WANT_IPC_PARSE_VERSION | 368 | #define __ARCH_WANT_IPC_PARSE_VERSION |
373 | #define __ARCH_WANT_OLD_READDIR | 369 | #define __ARCH_WANT_OLD_READDIR |
374 | #define __ARCH_WANT_STAT64 | 370 | #define __ARCH_WANT_STAT64 |
@@ -389,7 +385,6 @@ type name (atype a, btype b, ctype c, dtype d, etype e, ftype f) \ | |||
389 | #define __ARCH_WANT_SYS_SIGPENDING | 385 | #define __ARCH_WANT_SYS_SIGPENDING |
390 | #define __ARCH_WANT_SYS_SIGPROCMASK | 386 | #define __ARCH_WANT_SYS_SIGPROCMASK |
391 | #define __ARCH_WANT_SYS_RT_SIGACTION | 387 | #define __ARCH_WANT_SYS_RT_SIGACTION |
392 | #endif | ||
393 | 388 | ||
394 | #ifdef __KERNEL_SYSCALLS__ | 389 | #ifdef __KERNEL_SYSCALLS__ |
395 | 390 | ||
@@ -440,7 +435,7 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
440 | struct sigaction __user *oact, | 435 | struct sigaction __user *oact, |
441 | size_t sigsetsize); | 436 | size_t sigsetsize); |
442 | 437 | ||
443 | #endif | 438 | #endif /* __KERNEL_SYSCALLS__ */ |
444 | 439 | ||
445 | /* | 440 | /* |
446 | * "Conditional" syscalls | 441 | * "Conditional" syscalls |
@@ -455,4 +450,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
455 | void name (void) __attribute__ ((weak, alias ("sys_ni_syscall"))); | 450 | void name (void) __attribute__ ((weak, alias ("sys_ni_syscall"))); |
456 | #endif | 451 | #endif |
457 | 452 | ||
453 | #endif /* __KERNEL__ */ | ||
458 | #endif /* __V850_UNISTD_H__ */ | 454 | #endif /* __V850_UNISTD_H__ */ |
diff --git a/include/asm-v850/v850e_uart.h b/include/asm-v850/v850e_uart.h index 5930d5990b19..5182fb4cc989 100644 --- a/include/asm-v850/v850e_uart.h +++ b/include/asm-v850/v850e_uart.h | |||
@@ -19,7 +19,6 @@ | |||
19 | #ifndef __V850_V850E_UART_H__ | 19 | #ifndef __V850_V850E_UART_H__ |
20 | #define __V850_V850E_UART_H__ | 20 | #define __V850_V850E_UART_H__ |
21 | 21 | ||
22 | #include <linux/config.h> | ||
23 | #include <linux/termios.h> | 22 | #include <linux/termios.h> |
24 | 23 | ||
25 | #include <asm/v850e_utils.h> | 24 | #include <asm/v850e_utils.h> |
diff --git a/include/asm-x86_64/apic.h b/include/asm-x86_64/apic.h index bdbd8935612a..a731be2204d2 100644 --- a/include/asm-x86_64/apic.h +++ b/include/asm-x86_64/apic.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_APIC_H | 1 | #ifndef __ASM_APIC_H |
2 | #define __ASM_APIC_H | 2 | #define __ASM_APIC_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/pm.h> | 4 | #include <linux/pm.h> |
6 | #include <asm/fixmap.h> | 5 | #include <asm/fixmap.h> |
7 | #include <asm/apicdef.h> | 6 | #include <asm/apicdef.h> |
diff --git a/include/asm-x86_64/atomic.h b/include/asm-x86_64/atomic.h index cecbf7baa6aa..bd3fa67ed835 100644 --- a/include/asm-x86_64/atomic.h +++ b/include/asm-x86_64/atomic.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ARCH_X86_64_ATOMIC__ | 1 | #ifndef __ARCH_X86_64_ATOMIC__ |
2 | #define __ARCH_X86_64_ATOMIC__ | 2 | #define __ARCH_X86_64_ATOMIC__ |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/types.h> | 4 | #include <asm/types.h> |
6 | 5 | ||
7 | /* atomic_t should be 32 bit signed type */ | 6 | /* atomic_t should be 32 bit signed type */ |
diff --git a/include/asm-x86_64/bitops.h b/include/asm-x86_64/bitops.h index 79212128d0f7..e9bf933d25d0 100644 --- a/include/asm-x86_64/bitops.h +++ b/include/asm-x86_64/bitops.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * Copyright 1992, Linus Torvalds. | 5 | * Copyright 1992, Linus Torvalds. |
6 | */ | 6 | */ |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | 8 | ||
10 | #ifdef CONFIG_SMP | 9 | #ifdef CONFIG_SMP |
11 | #define LOCK_PREFIX "lock ; " | 10 | #define LOCK_PREFIX "lock ; " |
diff --git a/include/asm-x86_64/bugs.h b/include/asm-x86_64/bugs.h index 59bc68925d0f..d86c5dd689fa 100644 --- a/include/asm-x86_64/bugs.h +++ b/include/asm-x86_64/bugs.h | |||
@@ -10,7 +10,6 @@ | |||
10 | * void check_bugs(void); | 10 | * void check_bugs(void); |
11 | */ | 11 | */ |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <asm/processor.h> | 13 | #include <asm/processor.h> |
15 | #include <asm/i387.h> | 14 | #include <asm/i387.h> |
16 | #include <asm/msr.h> | 15 | #include <asm/msr.h> |
diff --git a/include/asm-x86_64/cache.h b/include/asm-x86_64/cache.h index f8dff1c67538..ed8a9d25272d 100644 --- a/include/asm-x86_64/cache.h +++ b/include/asm-x86_64/cache.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #ifndef __ARCH_X8664_CACHE_H | 4 | #ifndef __ARCH_X8664_CACHE_H |
5 | #define __ARCH_X8664_CACHE_H | 5 | #define __ARCH_X8664_CACHE_H |
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | /* L1 cache line size */ | 8 | /* L1 cache line size */ |
10 | #define L1_CACHE_SHIFT (CONFIG_X86_L1_CACHE_SHIFT) | 9 | #define L1_CACHE_SHIFT (CONFIG_X86_L1_CACHE_SHIFT) |
diff --git a/include/asm-x86_64/calling.h b/include/asm-x86_64/calling.h index fc2c5a6c262a..6f4f63af96e1 100644 --- a/include/asm-x86_64/calling.h +++ b/include/asm-x86_64/calling.h | |||
@@ -2,7 +2,6 @@ | |||
2 | * Some macros to handle stack frames in assembly. | 2 | * Some macros to handle stack frames in assembly. |
3 | */ | 3 | */ |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | 5 | ||
7 | #define R15 0 | 6 | #define R15 0 |
8 | #define R14 8 | 7 | #define R14 8 |
diff --git a/include/asm-x86_64/dma-mapping.h b/include/asm-x86_64/dma-mapping.h index 49a81a66516e..498f66df36b9 100644 --- a/include/asm-x86_64/dma-mapping.h +++ b/include/asm-x86_64/dma-mapping.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * documentation. | 6 | * documentation. |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | #include <asm/scatterlist.h> | 10 | #include <asm/scatterlist.h> |
12 | #include <asm/io.h> | 11 | #include <asm/io.h> |
diff --git a/include/asm-x86_64/dma.h b/include/asm-x86_64/dma.h index 6f2a817b6a7c..c556208d3dd7 100644 --- a/include/asm-x86_64/dma.h +++ b/include/asm-x86_64/dma.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef _ASM_DMA_H | 8 | #ifndef _ASM_DMA_H |
9 | #define _ASM_DMA_H | 9 | #define _ASM_DMA_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #include <linux/spinlock.h> /* And spinlocks */ | 11 | #include <linux/spinlock.h> /* And spinlocks */ |
13 | #include <asm/io.h> /* need byte IO */ | 12 | #include <asm/io.h> /* need byte IO */ |
14 | #include <linux/delay.h> | 13 | #include <linux/delay.h> |
diff --git a/include/asm-x86_64/dwarf2.h b/include/asm-x86_64/dwarf2.h index 07654bd155bf..0744db777676 100644 --- a/include/asm-x86_64/dwarf2.h +++ b/include/asm-x86_64/dwarf2.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _DWARF2_H | 1 | #ifndef _DWARF2_H |
2 | #define _DWARF2_H 1 | 2 | #define _DWARF2_H 1 |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifndef __ASSEMBLY__ | 5 | #ifndef __ASSEMBLY__ |
7 | #warning "asm/dwarf2.h should be only included in pure assembly files" | 6 | #warning "asm/dwarf2.h should be only included in pure assembly files" |
diff --git a/include/asm-x86_64/fixmap.h b/include/asm-x86_64/fixmap.h index 7b286bd21d1d..0b4ffbd1a125 100644 --- a/include/asm-x86_64/fixmap.h +++ b/include/asm-x86_64/fixmap.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _ASM_FIXMAP_H | 11 | #ifndef _ASM_FIXMAP_H |
12 | #define _ASM_FIXMAP_H | 12 | #define _ASM_FIXMAP_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/kernel.h> | 14 | #include <linux/kernel.h> |
16 | #include <asm/apicdef.h> | 15 | #include <asm/apicdef.h> |
17 | #include <asm/page.h> | 16 | #include <asm/page.h> |
diff --git a/include/asm-x86_64/hardirq.h b/include/asm-x86_64/hardirq.h index 8689951e3503..64a65ce2f41f 100644 --- a/include/asm-x86_64/hardirq.h +++ b/include/asm-x86_64/hardirq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_HARDIRQ_H | 1 | #ifndef __ASM_HARDIRQ_H |
2 | #define __ASM_HARDIRQ_H | 2 | #define __ASM_HARDIRQ_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/threads.h> | 4 | #include <linux/threads.h> |
6 | #include <linux/irq.h> | 5 | #include <linux/irq.h> |
7 | #include <asm/pda.h> | 6 | #include <asm/pda.h> |
diff --git a/include/asm-x86_64/hw_irq.h b/include/asm-x86_64/hw_irq.h index 0df1715dee71..3de96fd86a70 100644 --- a/include/asm-x86_64/hw_irq.h +++ b/include/asm-x86_64/hw_irq.h | |||
@@ -17,7 +17,6 @@ | |||
17 | */ | 17 | */ |
18 | 18 | ||
19 | #ifndef __ASSEMBLY__ | 19 | #ifndef __ASSEMBLY__ |
20 | #include <linux/config.h> | ||
21 | #include <asm/atomic.h> | 20 | #include <asm/atomic.h> |
22 | #include <asm/irq.h> | 21 | #include <asm/irq.h> |
23 | #include <linux/profile.h> | 22 | #include <linux/profile.h> |
diff --git a/include/asm-x86_64/ia32.h b/include/asm-x86_64/ia32.h index e6b7f2234e43..0190b7c4e319 100644 --- a/include/asm-x86_64/ia32.h +++ b/include/asm-x86_64/ia32.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_X86_64_IA32_H | 1 | #ifndef _ASM_X86_64_IA32_H |
2 | #define _ASM_X86_64_IA32_H | 2 | #define _ASM_X86_64_IA32_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_IA32_EMULATION | 5 | #ifdef CONFIG_IA32_EMULATION |
7 | 6 | ||
diff --git a/include/asm-x86_64/io.h b/include/asm-x86_64/io.h index a05da8a50bfd..70e91fe76344 100644 --- a/include/asm-x86_64/io.h +++ b/include/asm-x86_64/io.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_IO_H | 1 | #ifndef _ASM_IO_H |
2 | #define _ASM_IO_H | 2 | #define _ASM_IO_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * This file contains the definitions for the x86 IO instructions | 6 | * This file contains the definitions for the x86 IO instructions |
diff --git a/include/asm-x86_64/io_apic.h b/include/asm-x86_64/io_apic.h index 52484e82c641..fb7a0909a174 100644 --- a/include/asm-x86_64/io_apic.h +++ b/include/asm-x86_64/io_apic.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_IO_APIC_H | 1 | #ifndef __ASM_IO_APIC_H |
2 | #define __ASM_IO_APIC_H | 2 | #define __ASM_IO_APIC_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/types.h> | 4 | #include <asm/types.h> |
6 | #include <asm/mpspec.h> | 5 | #include <asm/mpspec.h> |
7 | 6 | ||
diff --git a/include/asm-x86_64/mmu_context.h b/include/asm-x86_64/mmu_context.h index 19f0c83d0792..af03b9f852d6 100644 --- a/include/asm-x86_64/mmu_context.h +++ b/include/asm-x86_64/mmu_context.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __X86_64_MMU_CONTEXT_H | 1 | #ifndef __X86_64_MMU_CONTEXT_H |
2 | #define __X86_64_MMU_CONTEXT_H | 2 | #define __X86_64_MMU_CONTEXT_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/desc.h> | 4 | #include <asm/desc.h> |
6 | #include <asm/atomic.h> | 5 | #include <asm/atomic.h> |
7 | #include <asm/pgalloc.h> | 6 | #include <asm/pgalloc.h> |
diff --git a/include/asm-x86_64/mmzone.h b/include/asm-x86_64/mmzone.h index 6944e7122df5..70bb9969766e 100644 --- a/include/asm-x86_64/mmzone.h +++ b/include/asm-x86_64/mmzone.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #ifndef _ASM_X86_64_MMZONE_H | 4 | #ifndef _ASM_X86_64_MMZONE_H |
5 | #define _ASM_X86_64_MMZONE_H 1 | 5 | #define _ASM_X86_64_MMZONE_H 1 |
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | #ifdef CONFIG_NUMA | 8 | #ifdef CONFIG_NUMA |
10 | 9 | ||
diff --git a/include/asm-x86_64/msi.h b/include/asm-x86_64/msi.h index 356e0e82f50b..3ad2346624b2 100644 --- a/include/asm-x86_64/msi.h +++ b/include/asm-x86_64/msi.h | |||
@@ -10,7 +10,15 @@ | |||
10 | #include <asm/mach_apic.h> | 10 | #include <asm/mach_apic.h> |
11 | #include <asm/smp.h> | 11 | #include <asm/smp.h> |
12 | 12 | ||
13 | #define LAST_DEVICE_VECTOR 232 | 13 | #define LAST_DEVICE_VECTOR (FIRST_SYSTEM_VECTOR - 1) |
14 | #define MSI_TARGET_CPU_SHIFT 12 | 14 | #define MSI_TARGET_CPU_SHIFT 12 |
15 | 15 | ||
16 | extern struct msi_ops msi_apic_ops; | ||
17 | |||
18 | static inline int msi_arch_init(void) | ||
19 | { | ||
20 | msi_register(&msi_apic_ops); | ||
21 | return 0; | ||
22 | } | ||
23 | |||
16 | #endif /* ASM_MSI_H */ | 24 | #endif /* ASM_MSI_H */ |
diff --git a/include/asm-x86_64/mtrr.h b/include/asm-x86_64/mtrr.h index 66ac1c0f27e1..d6135b2549bf 100644 --- a/include/asm-x86_64/mtrr.h +++ b/include/asm-x86_64/mtrr.h | |||
@@ -23,9 +23,7 @@ | |||
23 | #ifndef _LINUX_MTRR_H | 23 | #ifndef _LINUX_MTRR_H |
24 | #define _LINUX_MTRR_H | 24 | #define _LINUX_MTRR_H |
25 | 25 | ||
26 | #include <linux/config.h> | ||
27 | #include <linux/ioctl.h> | 26 | #include <linux/ioctl.h> |
28 | #include <linux/compat.h> | ||
29 | 27 | ||
30 | #define MTRR_IOCTL_BASE 'M' | 28 | #define MTRR_IOCTL_BASE 'M' |
31 | 29 | ||
@@ -102,11 +100,10 @@ static __inline__ int mtrr_del_page (int reg, unsigned long base, | |||
102 | return -ENODEV; | 100 | return -ENODEV; |
103 | } | 101 | } |
104 | 102 | ||
105 | # endif | 103 | #endif /* CONFIG_MTRR */ |
106 | |||
107 | #endif | ||
108 | 104 | ||
109 | #ifdef CONFIG_COMPAT | 105 | #ifdef CONFIG_COMPAT |
106 | #include <linux/compat.h> | ||
110 | 107 | ||
111 | struct mtrr_sentry32 | 108 | struct mtrr_sentry32 |
112 | { | 109 | { |
@@ -138,4 +135,6 @@ struct mtrr_gentry32 | |||
138 | 135 | ||
139 | #endif /* CONFIG_COMPAT */ | 136 | #endif /* CONFIG_COMPAT */ |
140 | 137 | ||
138 | #endif /* __KERNEL__ */ | ||
139 | |||
141 | #endif /* _LINUX_MTRR_H */ | 140 | #endif /* _LINUX_MTRR_H */ |
diff --git a/include/asm-x86_64/page.h b/include/asm-x86_64/page.h index 408185bac351..f7bf875aae40 100644 --- a/include/asm-x86_64/page.h +++ b/include/asm-x86_64/page.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _X86_64_PAGE_H | 1 | #ifndef _X86_64_PAGE_H |
2 | #define _X86_64_PAGE_H | 2 | #define _X86_64_PAGE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* PAGE_SHIFT determines the page size */ | 5 | /* PAGE_SHIFT determines the page size */ |
7 | #define PAGE_SHIFT 12 | 6 | #define PAGE_SHIFT 12 |
@@ -136,9 +135,9 @@ typedef struct { unsigned long pgprot; } pgprot_t; | |||
136 | 135 | ||
137 | #define __HAVE_ARCH_GATE_AREA 1 | 136 | #define __HAVE_ARCH_GATE_AREA 1 |
138 | 137 | ||
139 | #endif /* __KERNEL__ */ | ||
140 | |||
141 | #include <asm-generic/memory_model.h> | 138 | #include <asm-generic/memory_model.h> |
142 | #include <asm-generic/page.h> | 139 | #include <asm-generic/page.h> |
143 | 140 | ||
141 | #endif /* __KERNEL__ */ | ||
142 | |||
144 | #endif /* _X86_64_PAGE_H */ | 143 | #endif /* _X86_64_PAGE_H */ |
diff --git a/include/asm-x86_64/param.h b/include/asm-x86_64/param.h index 5956b23b57c2..a728786c3c7c 100644 --- a/include/asm-x86_64/param.h +++ b/include/asm-x86_64/param.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define _ASMx86_64_PARAM_H | 2 | #define _ASMx86_64_PARAM_H |
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | # include <linux/config.h> | ||
6 | # define HZ CONFIG_HZ /* Internal kernel timer frequency */ | 5 | # define HZ CONFIG_HZ /* Internal kernel timer frequency */ |
7 | # define USER_HZ 100 /* .. some user interfaces are in "ticks */ | 6 | # define USER_HZ 100 /* .. some user interfaces are in "ticks */ |
8 | #define CLOCKS_PER_SEC (USER_HZ) /* like times() */ | 7 | #define CLOCKS_PER_SEC (USER_HZ) /* like times() */ |
diff --git a/include/asm-x86_64/pci.h b/include/asm-x86_64/pci.h index 8a05af264d18..2db0620d5449 100644 --- a/include/asm-x86_64/pci.h +++ b/include/asm-x86_64/pci.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __x8664_PCI_H | 1 | #ifndef __x8664_PCI_H |
2 | #define __x8664_PCI_H | 2 | #define __x8664_PCI_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/io.h> | 4 | #include <asm/io.h> |
6 | 5 | ||
7 | #ifdef __KERNEL__ | 6 | #ifdef __KERNEL__ |
diff --git a/include/asm-x86_64/processor.h b/include/asm-x86_64/processor.h index 37a3ec433ee5..3061a38a3b1d 100644 --- a/include/asm-x86_64/processor.h +++ b/include/asm-x86_64/processor.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #include <asm/types.h> | 12 | #include <asm/types.h> |
13 | #include <asm/sigcontext.h> | 13 | #include <asm/sigcontext.h> |
14 | #include <asm/cpufeature.h> | 14 | #include <asm/cpufeature.h> |
15 | #include <linux/config.h> | ||
16 | #include <linux/threads.h> | 15 | #include <linux/threads.h> |
17 | #include <asm/msr.h> | 16 | #include <asm/msr.h> |
18 | #include <asm/current.h> | 17 | #include <asm/current.h> |
diff --git a/include/asm-x86_64/serial.h b/include/asm-x86_64/serial.h index dc752eafa681..b0496e0d72a6 100644 --- a/include/asm-x86_64/serial.h +++ b/include/asm-x86_64/serial.h | |||
@@ -2,7 +2,6 @@ | |||
2 | * include/asm-x86_64/serial.h | 2 | * include/asm-x86_64/serial.h |
3 | */ | 3 | */ |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | 5 | ||
7 | /* | 6 | /* |
8 | * This assumes you have a 1.8432 MHz clock for your UART. | 7 | * This assumes you have a 1.8432 MHz clock for your UART. |
diff --git a/include/asm-x86_64/smp.h b/include/asm-x86_64/smp.h index a4fdaeb5c397..7686b9b25aef 100644 --- a/include/asm-x86_64/smp.h +++ b/include/asm-x86_64/smp.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * We need the APIC definitions automatically as part of 'smp.h' | 5 | * We need the APIC definitions automatically as part of 'smp.h' |
6 | */ | 6 | */ |
7 | #ifndef __ASSEMBLY__ | 7 | #ifndef __ASSEMBLY__ |
8 | #include <linux/config.h> | ||
9 | #include <linux/threads.h> | 8 | #include <linux/threads.h> |
10 | #include <linux/cpumask.h> | 9 | #include <linux/cpumask.h> |
11 | #include <linux/bitops.h> | 10 | #include <linux/bitops.h> |
diff --git a/include/asm-x86_64/spinlock.h b/include/asm-x86_64/spinlock.h index fe484a699cc3..5d8a5e3589ff 100644 --- a/include/asm-x86_64/spinlock.h +++ b/include/asm-x86_64/spinlock.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #include <asm/atomic.h> | 4 | #include <asm/atomic.h> |
5 | #include <asm/rwlock.h> | 5 | #include <asm/rwlock.h> |
6 | #include <asm/page.h> | 6 | #include <asm/page.h> |
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | /* | 8 | /* |
10 | * Your basic SMP spinlocks, allowing only a single CPU anywhere | 9 | * Your basic SMP spinlocks, allowing only a single CPU anywhere |
diff --git a/include/asm-x86_64/swiotlb.h b/include/asm-x86_64/swiotlb.h index 60757efd1353..5f9a01805821 100644 --- a/include/asm-x86_64/swiotlb.h +++ b/include/asm-x86_64/swiotlb.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_SWIOTLB_H | 1 | #ifndef _ASM_SWIOTLB_H |
2 | #define _ASM_SWTIOLB_H 1 | 2 | #define _ASM_SWTIOLB_H 1 |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #include <asm/dma-mapping.h> | 5 | #include <asm/dma-mapping.h> |
7 | 6 | ||
diff --git a/include/asm-x86_64/system.h b/include/asm-x86_64/system.h index 397598980228..f48e0dad8b3d 100644 --- a/include/asm-x86_64/system.h +++ b/include/asm-x86_64/system.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __ASM_SYSTEM_H | 1 | #ifndef __ASM_SYSTEM_H |
2 | #define __ASM_SYSTEM_H | 2 | #define __ASM_SYSTEM_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/kernel.h> | 4 | #include <linux/kernel.h> |
6 | #include <asm/segment.h> | 5 | #include <asm/segment.h> |
7 | 6 | ||
diff --git a/include/asm-x86_64/tlbflush.h b/include/asm-x86_64/tlbflush.h index 4a9c20ea9b10..d16d5b60f419 100644 --- a/include/asm-x86_64/tlbflush.h +++ b/include/asm-x86_64/tlbflush.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _X8664_TLBFLUSH_H | 1 | #ifndef _X8664_TLBFLUSH_H |
2 | #define _X8664_TLBFLUSH_H | 2 | #define _X8664_TLBFLUSH_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | #include <asm/processor.h> | 5 | #include <asm/processor.h> |
7 | 6 | ||
diff --git a/include/asm-x86_64/topology.h b/include/asm-x86_64/topology.h index 9db54e9d17bb..80c4e44d011c 100644 --- a/include/asm-x86_64/topology.h +++ b/include/asm-x86_64/topology.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _ASM_X86_64_TOPOLOGY_H | 1 | #ifndef _ASM_X86_64_TOPOLOGY_H |
2 | #define _ASM_X86_64_TOPOLOGY_H | 2 | #define _ASM_X86_64_TOPOLOGY_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_NUMA | 5 | #ifdef CONFIG_NUMA |
7 | 6 | ||
diff --git a/include/asm-x86_64/uaccess.h b/include/asm-x86_64/uaccess.h index bddffcb591b8..1e1fa003daa3 100644 --- a/include/asm-x86_64/uaccess.h +++ b/include/asm-x86_64/uaccess.h | |||
@@ -4,7 +4,6 @@ | |||
4 | /* | 4 | /* |
5 | * User space memory access functions | 5 | * User space memory access functions |
6 | */ | 6 | */ |
7 | #include <linux/config.h> | ||
8 | #include <linux/compiler.h> | 7 | #include <linux/compiler.h> |
9 | #include <linux/errno.h> | 8 | #include <linux/errno.h> |
10 | #include <linux/sched.h> | 9 | #include <linux/sched.h> |
diff --git a/include/asm-x86_64/unistd.h b/include/asm-x86_64/unistd.h index feb77cb8c044..0aff22bdbb21 100644 --- a/include/asm-x86_64/unistd.h +++ b/include/asm-x86_64/unistd.h | |||
@@ -618,6 +618,8 @@ __SYSCALL(__NR_sync_file_range, sys_sync_file_range) | |||
618 | #define __NR_vmsplice 278 | 618 | #define __NR_vmsplice 278 |
619 | __SYSCALL(__NR_vmsplice, sys_vmsplice) | 619 | __SYSCALL(__NR_vmsplice, sys_vmsplice) |
620 | 620 | ||
621 | #ifdef __KERNEL__ | ||
622 | |||
621 | #define __NR_syscall_max __NR_vmsplice | 623 | #define __NR_syscall_max __NR_vmsplice |
622 | 624 | ||
623 | #ifndef __NO_STUBS | 625 | #ifndef __NO_STUBS |
@@ -635,7 +637,6 @@ do { \ | |||
635 | return (type) (res); \ | 637 | return (type) (res); \ |
636 | } while (0) | 638 | } while (0) |
637 | 639 | ||
638 | #ifdef __KERNEL__ | ||
639 | #define __ARCH_WANT_OLD_READDIR | 640 | #define __ARCH_WANT_OLD_READDIR |
640 | #define __ARCH_WANT_OLD_STAT | 641 | #define __ARCH_WANT_OLD_STAT |
641 | #define __ARCH_WANT_SYS_ALARM | 642 | #define __ARCH_WANT_SYS_ALARM |
@@ -657,7 +658,6 @@ do { \ | |||
657 | #define __ARCH_WANT_SYS_RT_SIGACTION | 658 | #define __ARCH_WANT_SYS_RT_SIGACTION |
658 | #define __ARCH_WANT_SYS_TIME | 659 | #define __ARCH_WANT_SYS_TIME |
659 | #define __ARCH_WANT_COMPAT_SYS_TIME | 660 | #define __ARCH_WANT_COMPAT_SYS_TIME |
660 | #endif | ||
661 | 661 | ||
662 | #ifndef __KERNEL_SYSCALLS__ | 662 | #ifndef __KERNEL_SYSCALLS__ |
663 | 663 | ||
@@ -821,7 +821,7 @@ asmlinkage long sys_pipe(int *fildes); | |||
821 | 821 | ||
822 | #endif /* __KERNEL_SYSCALLS__ */ | 822 | #endif /* __KERNEL_SYSCALLS__ */ |
823 | 823 | ||
824 | #if !defined(__ASSEMBLY__) && defined(__KERNEL__) | 824 | #ifndef __ASSEMBLY__ |
825 | 825 | ||
826 | #include <linux/linkage.h> | 826 | #include <linux/linkage.h> |
827 | #include <linux/compiler.h> | 827 | #include <linux/compiler.h> |
@@ -848,4 +848,5 @@ asmlinkage long sys_rt_sigaction(int sig, | |||
848 | */ | 848 | */ |
849 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") | 849 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall") |
850 | 850 | ||
851 | #endif /* __KERNEL__ */ | ||
851 | #endif | 852 | #endif |
diff --git a/include/asm-x86_64/vga.h b/include/asm-x86_64/vga.h index ef0c0e50cc95..0ecf68ac03aa 100644 --- a/include/asm-x86_64/vga.h +++ b/include/asm-x86_64/vga.h | |||
@@ -12,7 +12,7 @@ | |||
12 | * access the videoram directly without any black magic. | 12 | * access the videoram directly without any black magic. |
13 | */ | 13 | */ |
14 | 14 | ||
15 | #define VGA_MAP_MEM(x) (unsigned long)phys_to_virt(x) | 15 | #define VGA_MAP_MEM(x,s) (unsigned long)phys_to_virt(x) |
16 | 16 | ||
17 | #define vga_readb(x) (*(x)) | 17 | #define vga_readb(x) (*(x)) |
18 | #define vga_writeb(x,y) (*(y) = (x)) | 18 | #define vga_writeb(x,y) (*(y) = (x)) |
diff --git a/include/asm-xtensa/atomic.h b/include/asm-xtensa/atomic.h index fe105a123924..5c2672021068 100644 --- a/include/asm-xtensa/atomic.h +++ b/include/asm-xtensa/atomic.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef _XTENSA_ATOMIC_H | 13 | #ifndef _XTENSA_ATOMIC_H |
14 | #define _XTENSA_ATOMIC_H | 14 | #define _XTENSA_ATOMIC_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/stringify.h> | 16 | #include <linux/stringify.h> |
18 | 17 | ||
19 | typedef struct { volatile int counter; } atomic_t; | 18 | typedef struct { volatile int counter; } atomic_t; |
diff --git a/include/asm-xtensa/checksum.h b/include/asm-xtensa/checksum.h index 81a797ae3abe..bdc00ae9be48 100644 --- a/include/asm-xtensa/checksum.h +++ b/include/asm-xtensa/checksum.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _XTENSA_CHECKSUM_H | 11 | #ifndef _XTENSA_CHECKSUM_H |
12 | #define _XTENSA_CHECKSUM_H | 12 | #define _XTENSA_CHECKSUM_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/in6.h> | 14 | #include <linux/in6.h> |
16 | #include <xtensa/config/core.h> | 15 | #include <xtensa/config/core.h> |
17 | 16 | ||
diff --git a/include/asm-xtensa/delay.h b/include/asm-xtensa/delay.h index 1bc601ec3621..e1d8c9e010c1 100644 --- a/include/asm-xtensa/delay.h +++ b/include/asm-xtensa/delay.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #ifndef _XTENSA_DELAY_H | 12 | #ifndef _XTENSA_DELAY_H |
13 | #define _XTENSA_DELAY_H | 13 | #define _XTENSA_DELAY_H |
14 | 14 | ||
15 | #include <linux/config.h> | ||
16 | #include <asm/processor.h> | 15 | #include <asm/processor.h> |
17 | #include <asm/param.h> | 16 | #include <asm/param.h> |
18 | 17 | ||
diff --git a/include/asm-xtensa/dma.h b/include/asm-xtensa/dma.h index 1c22b0234586..db2633f67789 100644 --- a/include/asm-xtensa/dma.h +++ b/include/asm-xtensa/dma.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _XTENSA_DMA_H | 11 | #ifndef _XTENSA_DMA_H |
12 | #define _XTENSA_DMA_H | 12 | #define _XTENSA_DMA_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <asm/io.h> /* need byte IO */ | 14 | #include <asm/io.h> /* need byte IO */ |
16 | #include <xtensa/config/core.h> | 15 | #include <xtensa/config/core.h> |
17 | 16 | ||
diff --git a/include/asm-xtensa/hardirq.h b/include/asm-xtensa/hardirq.h index aa9c1adf68d7..87cb19d1b10c 100644 --- a/include/asm-xtensa/hardirq.h +++ b/include/asm-xtensa/hardirq.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _XTENSA_HARDIRQ_H | 11 | #ifndef _XTENSA_HARDIRQ_H |
12 | #define _XTENSA_HARDIRQ_H | 12 | #define _XTENSA_HARDIRQ_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/cache.h> | 14 | #include <linux/cache.h> |
16 | #include <asm/irq.h> | 15 | #include <asm/irq.h> |
17 | 16 | ||
diff --git a/include/asm-xtensa/ide.h b/include/asm-xtensa/ide.h index b523cd4a486e..6b912742a42d 100644 --- a/include/asm-xtensa/ide.h +++ b/include/asm-xtensa/ide.h | |||
@@ -14,7 +14,6 @@ | |||
14 | 14 | ||
15 | #ifdef __KERNEL__ | 15 | #ifdef __KERNEL__ |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | 17 | ||
19 | #ifndef MAX_HWIFS | 18 | #ifndef MAX_HWIFS |
20 | # define MAX_HWIFS 1 | 19 | # define MAX_HWIFS 1 |
diff --git a/include/asm-xtensa/io.h b/include/asm-xtensa/io.h index c5c13985bbe1..556e5eed34f5 100644 --- a/include/asm-xtensa/io.h +++ b/include/asm-xtensa/io.h | |||
@@ -12,7 +12,6 @@ | |||
12 | #define _XTENSA_IO_H | 12 | #define _XTENSA_IO_H |
13 | 13 | ||
14 | #ifdef __KERNEL__ | 14 | #ifdef __KERNEL__ |
15 | #include <linux/config.h> | ||
16 | #include <asm/byteorder.h> | 15 | #include <asm/byteorder.h> |
17 | 16 | ||
18 | #include <linux/types.h> | 17 | #include <linux/types.h> |
diff --git a/include/asm-xtensa/irq.h b/include/asm-xtensa/irq.h index d984e955938f..049fde7e752d 100644 --- a/include/asm-xtensa/irq.h +++ b/include/asm-xtensa/irq.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _XTENSA_IRQ_H | 11 | #ifndef _XTENSA_IRQ_H |
12 | #define _XTENSA_IRQ_H | 12 | #define _XTENSA_IRQ_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <asm/platform/hardware.h> | 14 | #include <asm/platform/hardware.h> |
16 | 15 | ||
17 | #include <xtensa/config/core.h> | 16 | #include <xtensa/config/core.h> |
diff --git a/include/asm-xtensa/mmu_context.h b/include/asm-xtensa/mmu_context.h index 364a7b057bfa..af683a74a4ec 100644 --- a/include/asm-xtensa/mmu_context.h +++ b/include/asm-xtensa/mmu_context.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef _XTENSA_MMU_CONTEXT_H | 13 | #ifndef _XTENSA_MMU_CONTEXT_H |
14 | #define _XTENSA_MMU_CONTEXT_H | 14 | #define _XTENSA_MMU_CONTEXT_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/stringify.h> | 16 | #include <linux/stringify.h> |
18 | 17 | ||
19 | #include <asm/pgtable.h> | 18 | #include <asm/pgtable.h> |
diff --git a/include/asm-xtensa/page.h b/include/asm-xtensa/page.h index 992bac5c1258..40f4c6c3f580 100644 --- a/include/asm-xtensa/page.h +++ b/include/asm-xtensa/page.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #ifdef __KERNEL__ | 14 | #ifdef __KERNEL__ |
15 | 15 | ||
16 | #include <asm/processor.h> | 16 | #include <asm/processor.h> |
17 | #include <linux/config.h> | ||
18 | 17 | ||
19 | /* | 18 | /* |
20 | * PAGE_SHIFT determines the page size | 19 | * PAGE_SHIFT determines the page size |
diff --git a/include/asm-xtensa/pgalloc.h b/include/asm-xtensa/pgalloc.h index 734a8d060395..d56ddf2055e1 100644 --- a/include/asm-xtensa/pgalloc.h +++ b/include/asm-xtensa/pgalloc.h | |||
@@ -13,7 +13,6 @@ | |||
13 | 13 | ||
14 | #ifdef __KERNEL__ | 14 | #ifdef __KERNEL__ |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/threads.h> | 16 | #include <linux/threads.h> |
18 | #include <linux/highmem.h> | 17 | #include <linux/highmem.h> |
19 | #include <asm/processor.h> | 18 | #include <asm/processor.h> |
diff --git a/include/asm-xtensa/platform.h b/include/asm-xtensa/platform.h index 36163894bc20..48135a9718b0 100644 --- a/include/asm-xtensa/platform.h +++ b/include/asm-xtensa/platform.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef _XTENSA_PLATFORM_H | 13 | #ifndef _XTENSA_PLATFORM_H |
14 | #define _XTENSA_PLATFORM_H | 14 | #define _XTENSA_PLATFORM_H |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/types.h> | 16 | #include <linux/types.h> |
18 | #include <linux/pci.h> | 17 | #include <linux/pci.h> |
19 | 18 | ||
diff --git a/include/asm-xtensa/system.h b/include/asm-xtensa/system.h index b29f7ae6a08a..f986170bd2a1 100644 --- a/include/asm-xtensa/system.h +++ b/include/asm-xtensa/system.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _XTENSA_SYSTEM_H | 11 | #ifndef _XTENSA_SYSTEM_H |
12 | #define _XTENSA_SYSTEM_H | 12 | #define _XTENSA_SYSTEM_H |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/stringify.h> | 14 | #include <linux/stringify.h> |
16 | 15 | ||
17 | #include <asm/processor.h> | 16 | #include <asm/processor.h> |
diff --git a/include/asm-xtensa/unistd.h b/include/asm-xtensa/unistd.h index 6b39d6609d9c..5e1b99dc4ab3 100644 --- a/include/asm-xtensa/unistd.h +++ b/include/asm-xtensa/unistd.h | |||
@@ -11,8 +11,6 @@ | |||
11 | #ifndef _XTENSA_UNISTD_H | 11 | #ifndef _XTENSA_UNISTD_H |
12 | #define _XTENSA_UNISTD_H | 12 | #define _XTENSA_UNISTD_H |
13 | 13 | ||
14 | #include <linux/linkage.h> | ||
15 | |||
16 | #define __NR_spill 0 | 14 | #define __NR_spill 0 |
17 | #define __NR_exit 1 | 15 | #define __NR_exit 1 |
18 | #define __NR_read 3 | 16 | #define __NR_read 3 |
@@ -221,21 +219,9 @@ | |||
221 | #define SYSXTENSA_COUNT 5 /* count of syscall0 functions*/ | 219 | #define SYSXTENSA_COUNT 5 /* count of syscall0 functions*/ |
222 | 220 | ||
223 | #ifdef __KERNEL__ | 221 | #ifdef __KERNEL__ |
224 | #define __syscall_return(type, res) return ((type)(res)) | 222 | #include <linux/linkage.h> |
225 | #else | ||
226 | #define __syscall_return(type, res) \ | ||
227 | do { \ | ||
228 | if ((unsigned long)(res) >= (unsigned long)(-125)) { \ | ||
229 | /* Avoid using "res" which is declared to be in register r2; \ | ||
230 | * errno might expand to a function call and clobber it. */ \ | ||
231 | int __err = -(res); \ | ||
232 | errno = __err; \ | ||
233 | res = -1; \ | ||
234 | } \ | ||
235 | return (type) (res); \ | ||
236 | } while (0) | ||
237 | #endif | ||
238 | 223 | ||
224 | #define __syscall_return(type, res) return ((type)(res)) | ||
239 | 225 | ||
240 | /* Tensilica's xt-xcc compiler is much more agressive at code | 226 | /* Tensilica's xt-xcc compiler is much more agressive at code |
241 | * optimization than gcc. Multiple __asm__ statements are | 227 | * optimization than gcc. Multiple __asm__ statements are |
@@ -429,11 +415,10 @@ static __inline__ _syscall3(int,execve,const char*,file,char**,argv,char**,envp) | |||
429 | */ | 415 | */ |
430 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall"); | 416 | #define cond_syscall(x) asm(".weak\t" #x "\n\t.set\t" #x ",sys_ni_syscall"); |
431 | 417 | ||
432 | #ifdef __KERNEL__ | ||
433 | #define __ARCH_WANT_STAT64 | 418 | #define __ARCH_WANT_STAT64 |
434 | #define __ARCH_WANT_SYS_UTIME | 419 | #define __ARCH_WANT_SYS_UTIME |
435 | #define __ARCH_WANT_SYS_LLSEEK | 420 | #define __ARCH_WANT_SYS_LLSEEK |
436 | #define __ARCH_WANT_SYS_RT_SIGACTION | 421 | #define __ARCH_WANT_SYS_RT_SIGACTION |
437 | #endif | 422 | #endif /* __KERNEL__ */ |
438 | 423 | ||
439 | #endif /* _XTENSA_UNISTD_H */ | 424 | #endif /* _XTENSA_UNISTD_H */ |
diff --git a/include/asm-xtensa/vga.h b/include/asm-xtensa/vga.h index 23d82f6acb57..1fd8cab3a297 100644 --- a/include/asm-xtensa/vga.h +++ b/include/asm-xtensa/vga.h | |||
@@ -11,7 +11,7 @@ | |||
11 | #ifndef _XTENSA_VGA_H | 11 | #ifndef _XTENSA_VGA_H |
12 | #define _XTENSA_VGA_H | 12 | #define _XTENSA_VGA_H |
13 | 13 | ||
14 | #define VGA_MAP_MEM(x) (unsigned long)phys_to_virt(x) | 14 | #define VGA_MAP_MEM(x,s) (unsigned long)phys_to_virt(x) |
15 | 15 | ||
16 | #define vga_readb(x) (*(x)) | 16 | #define vga_readb(x) (*(x)) |
17 | #define vga_writeb(x,y) (*(y) = (x)) | 17 | #define vga_writeb(x,y) (*(y) = (x)) |
diff --git a/include/linux/acct.h b/include/linux/acct.h index 9a66401073fc..3d54fbcf969e 100644 --- a/include/linux/acct.h +++ b/include/linux/acct.h | |||
@@ -16,7 +16,6 @@ | |||
16 | #define _LINUX_ACCT_H | 16 | #define _LINUX_ACCT_H |
17 | 17 | ||
18 | #include <linux/types.h> | 18 | #include <linux/types.h> |
19 | #include <linux/jiffies.h> | ||
20 | 19 | ||
21 | #include <asm/param.h> | 20 | #include <asm/param.h> |
22 | #include <asm/byteorder.h> | 21 | #include <asm/byteorder.h> |
@@ -116,7 +115,6 @@ struct acct_v3 | |||
116 | 115 | ||
117 | #ifdef __KERNEL__ | 116 | #ifdef __KERNEL__ |
118 | 117 | ||
119 | #include <linux/config.h> | ||
120 | 118 | ||
121 | #ifdef CONFIG_BSD_PROCESS_ACCT | 119 | #ifdef CONFIG_BSD_PROCESS_ACCT |
122 | struct vfsmount; | 120 | struct vfsmount; |
@@ -165,6 +163,7 @@ typedef struct acct acct_t; | |||
165 | #endif /* __KERNEL */ | 163 | #endif /* __KERNEL */ |
166 | 164 | ||
167 | #ifdef __KERNEL__ | 165 | #ifdef __KERNEL__ |
166 | #include <linux/jiffies.h> | ||
168 | /* | 167 | /* |
169 | * Yet another set of HZ to *HZ helper functions. | 168 | * Yet another set of HZ to *HZ helper functions. |
170 | * See <linux/jiffies.h> for the original. | 169 | * See <linux/jiffies.h> for the original. |
diff --git a/include/linux/acpi.h b/include/linux/acpi.h index d3bc25e6d27d..1cf0b91d05bd 100644 --- a/include/linux/acpi.h +++ b/include/linux/acpi.h | |||
@@ -25,7 +25,6 @@ | |||
25 | #ifndef _LINUX_ACPI_H | 25 | #ifndef _LINUX_ACPI_H |
26 | #define _LINUX_ACPI_H | 26 | #define _LINUX_ACPI_H |
27 | 27 | ||
28 | #include <linux/config.h> | ||
29 | 28 | ||
30 | #ifdef CONFIG_ACPI | 29 | #ifdef CONFIG_ACPI |
31 | 30 | ||
diff --git a/include/linux/affs_hardblocks.h b/include/linux/affs_hardblocks.h index 3fb869939d82..f1b948c1f592 100644 --- a/include/linux/affs_hardblocks.h +++ b/include/linux/affs_hardblocks.h | |||
@@ -1,45 +1,47 @@ | |||
1 | #ifndef AFFS_HARDBLOCKS_H | 1 | #ifndef AFFS_HARDBLOCKS_H |
2 | #define AFFS_HARDBLOCKS_H | 2 | #define AFFS_HARDBLOCKS_H |
3 | 3 | ||
4 | #include <linux/types.h> | ||
5 | |||
4 | /* Just the needed definitions for the RDB of an Amiga HD. */ | 6 | /* Just the needed definitions for the RDB of an Amiga HD. */ |
5 | 7 | ||
6 | struct RigidDiskBlock { | 8 | struct RigidDiskBlock { |
7 | u32 rdb_ID; | 9 | __u32 rdb_ID; |
8 | __be32 rdb_SummedLongs; | 10 | __be32 rdb_SummedLongs; |
9 | s32 rdb_ChkSum; | 11 | __s32 rdb_ChkSum; |
10 | u32 rdb_HostID; | 12 | __u32 rdb_HostID; |
11 | __be32 rdb_BlockBytes; | 13 | __be32 rdb_BlockBytes; |
12 | u32 rdb_Flags; | 14 | __u32 rdb_Flags; |
13 | u32 rdb_BadBlockList; | 15 | __u32 rdb_BadBlockList; |
14 | __be32 rdb_PartitionList; | 16 | __be32 rdb_PartitionList; |
15 | u32 rdb_FileSysHeaderList; | 17 | __u32 rdb_FileSysHeaderList; |
16 | u32 rdb_DriveInit; | 18 | __u32 rdb_DriveInit; |
17 | u32 rdb_Reserved1[6]; | 19 | __u32 rdb_Reserved1[6]; |
18 | u32 rdb_Cylinders; | 20 | __u32 rdb_Cylinders; |
19 | u32 rdb_Sectors; | 21 | __u32 rdb_Sectors; |
20 | u32 rdb_Heads; | 22 | __u32 rdb_Heads; |
21 | u32 rdb_Interleave; | 23 | __u32 rdb_Interleave; |
22 | u32 rdb_Park; | 24 | __u32 rdb_Park; |
23 | u32 rdb_Reserved2[3]; | 25 | __u32 rdb_Reserved2[3]; |
24 | u32 rdb_WritePreComp; | 26 | __u32 rdb_WritePreComp; |
25 | u32 rdb_ReducedWrite; | 27 | __u32 rdb_ReducedWrite; |
26 | u32 rdb_StepRate; | 28 | __u32 rdb_StepRate; |
27 | u32 rdb_Reserved3[5]; | 29 | __u32 rdb_Reserved3[5]; |
28 | u32 rdb_RDBBlocksLo; | 30 | __u32 rdb_RDBBlocksLo; |
29 | u32 rdb_RDBBlocksHi; | 31 | __u32 rdb_RDBBlocksHi; |
30 | u32 rdb_LoCylinder; | 32 | __u32 rdb_LoCylinder; |
31 | u32 rdb_HiCylinder; | 33 | __u32 rdb_HiCylinder; |
32 | u32 rdb_CylBlocks; | 34 | __u32 rdb_CylBlocks; |
33 | u32 rdb_AutoParkSeconds; | 35 | __u32 rdb_AutoParkSeconds; |
34 | u32 rdb_HighRDSKBlock; | 36 | __u32 rdb_HighRDSKBlock; |
35 | u32 rdb_Reserved4; | 37 | __u32 rdb_Reserved4; |
36 | char rdb_DiskVendor[8]; | 38 | char rdb_DiskVendor[8]; |
37 | char rdb_DiskProduct[16]; | 39 | char rdb_DiskProduct[16]; |
38 | char rdb_DiskRevision[4]; | 40 | char rdb_DiskRevision[4]; |
39 | char rdb_ControllerVendor[8]; | 41 | char rdb_ControllerVendor[8]; |
40 | char rdb_ControllerProduct[16]; | 42 | char rdb_ControllerProduct[16]; |
41 | char rdb_ControllerRevision[4]; | 43 | char rdb_ControllerRevision[4]; |
42 | u32 rdb_Reserved5[10]; | 44 | __u32 rdb_Reserved5[10]; |
43 | }; | 45 | }; |
44 | 46 | ||
45 | #define IDNAME_RIGIDDISK 0x5244534B /* "RDSK" */ | 47 | #define IDNAME_RIGIDDISK 0x5244534B /* "RDSK" */ |
@@ -47,16 +49,16 @@ struct RigidDiskBlock { | |||
47 | struct PartitionBlock { | 49 | struct PartitionBlock { |
48 | __be32 pb_ID; | 50 | __be32 pb_ID; |
49 | __be32 pb_SummedLongs; | 51 | __be32 pb_SummedLongs; |
50 | s32 pb_ChkSum; | 52 | __s32 pb_ChkSum; |
51 | u32 pb_HostID; | 53 | __u32 pb_HostID; |
52 | __be32 pb_Next; | 54 | __be32 pb_Next; |
53 | u32 pb_Flags; | 55 | __u32 pb_Flags; |
54 | u32 pb_Reserved1[2]; | 56 | __u32 pb_Reserved1[2]; |
55 | u32 pb_DevFlags; | 57 | __u32 pb_DevFlags; |
56 | u8 pb_DriveName[32]; | 58 | __u8 pb_DriveName[32]; |
57 | u32 pb_Reserved2[15]; | 59 | __u32 pb_Reserved2[15]; |
58 | __be32 pb_Environment[17]; | 60 | __be32 pb_Environment[17]; |
59 | u32 pb_EReserved[15]; | 61 | __u32 pb_EReserved[15]; |
60 | }; | 62 | }; |
61 | 63 | ||
62 | #define IDNAME_PARTITION 0x50415254 /* "PART" */ | 64 | #define IDNAME_PARTITION 0x50415254 /* "PART" */ |
diff --git a/include/linux/agpgart.h b/include/linux/agpgart.h index 6d59c8efe3be..bfb8ec791b7b 100644 --- a/include/linux/agpgart.h +++ b/include/linux/agpgart.h | |||
@@ -27,8 +27,6 @@ | |||
27 | #ifndef _AGP_H | 27 | #ifndef _AGP_H |
28 | #define _AGP_H 1 | 28 | #define _AGP_H 1 |
29 | 29 | ||
30 | #include <linux/agp_backend.h> | ||
31 | |||
32 | #define AGPIOC_BASE 'A' | 30 | #define AGPIOC_BASE 'A' |
33 | #define AGPIOC_INFO _IOR (AGPIOC_BASE, 0, struct agp_info*) | 31 | #define AGPIOC_INFO _IOR (AGPIOC_BASE, 0, struct agp_info*) |
34 | #define AGPIOC_ACQUIRE _IO (AGPIOC_BASE, 1) | 32 | #define AGPIOC_ACQUIRE _IO (AGPIOC_BASE, 1) |
@@ -112,6 +110,7 @@ typedef struct _agp_unbind { | |||
112 | 110 | ||
113 | #else /* __KERNEL__ */ | 111 | #else /* __KERNEL__ */ |
114 | #include <linux/mutex.h> | 112 | #include <linux/mutex.h> |
113 | #include <linux/agp_backend.h> | ||
115 | 114 | ||
116 | #define AGPGART_MINOR 175 | 115 | #define AGPGART_MINOR 175 |
117 | 116 | ||
diff --git a/include/linux/amba/clcd.h b/include/linux/amba/clcd.h index 9cf64b1b688b..29c0448265cf 100644 --- a/include/linux/amba/clcd.h +++ b/include/linux/amba/clcd.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * License. See the file COPYING in the main directory of this archive | 9 | * License. See the file COPYING in the main directory of this archive |
10 | * for more details. | 10 | * for more details. |
11 | */ | 11 | */ |
12 | #include <linux/config.h> | ||
13 | #include <linux/fb.h> | 12 | #include <linux/fb.h> |
14 | 13 | ||
15 | /* | 14 | /* |
diff --git a/include/linux/atmdev.h b/include/linux/atmdev.h index b203ea82a0a8..1eb238affb12 100644 --- a/include/linux/atmdev.h +++ b/include/linux/atmdev.h | |||
@@ -209,7 +209,6 @@ struct atm_cirange { | |||
209 | 209 | ||
210 | #ifdef __KERNEL__ | 210 | #ifdef __KERNEL__ |
211 | 211 | ||
212 | #include <linux/config.h> | ||
213 | #include <linux/wait.h> /* wait_queue_head_t */ | 212 | #include <linux/wait.h> /* wait_queue_head_t */ |
214 | #include <linux/time.h> /* struct timeval */ | 213 | #include <linux/time.h> /* struct timeval */ |
215 | #include <linux/net.h> | 214 | #include <linux/net.h> |
diff --git a/include/linux/audit.h b/include/linux/audit.h index b74c148f14e3..e051ff9c5b50 100644 --- a/include/linux/audit.h +++ b/include/linux/audit.h | |||
@@ -24,8 +24,7 @@ | |||
24 | #ifndef _LINUX_AUDIT_H_ | 24 | #ifndef _LINUX_AUDIT_H_ |
25 | #define _LINUX_AUDIT_H_ | 25 | #define _LINUX_AUDIT_H_ |
26 | 26 | ||
27 | #include <linux/sched.h> | 27 | #include <linux/elf-em.h> |
28 | #include <linux/elf.h> | ||
29 | 28 | ||
30 | /* The netlink messages for the audit system is divided into blocks: | 29 | /* The netlink messages for the audit system is divided into blocks: |
31 | * 1000 - 1099 are for commanding the audit system | 30 | * 1000 - 1099 are for commanding the audit system |
@@ -83,7 +82,12 @@ | |||
83 | #define AUDIT_CONFIG_CHANGE 1305 /* Audit system configuration change */ | 82 | #define AUDIT_CONFIG_CHANGE 1305 /* Audit system configuration change */ |
84 | #define AUDIT_SOCKADDR 1306 /* sockaddr copied as syscall arg */ | 83 | #define AUDIT_SOCKADDR 1306 /* sockaddr copied as syscall arg */ |
85 | #define AUDIT_CWD 1307 /* Current working directory */ | 84 | #define AUDIT_CWD 1307 /* Current working directory */ |
85 | #define AUDIT_EXECVE 1309 /* execve arguments */ | ||
86 | #define AUDIT_IPC_SET_PERM 1311 /* IPC new permissions record type */ | 86 | #define AUDIT_IPC_SET_PERM 1311 /* IPC new permissions record type */ |
87 | #define AUDIT_MQ_OPEN 1312 /* POSIX MQ open record type */ | ||
88 | #define AUDIT_MQ_SENDRECV 1313 /* POSIX MQ send/receive record type */ | ||
89 | #define AUDIT_MQ_NOTIFY 1314 /* POSIX MQ notify record type */ | ||
90 | #define AUDIT_MQ_GETSETATTR 1315 /* POSIX MQ get/set attribute record type */ | ||
87 | 91 | ||
88 | #define AUDIT_AVC 1400 /* SE Linux avc denial or grant */ | 92 | #define AUDIT_AVC 1400 /* SE Linux avc denial or grant */ |
89 | #define AUDIT_SELINUX_ERR 1401 /* Internal SE Linux Errors */ | 93 | #define AUDIT_SELINUX_ERR 1401 /* Internal SE Linux Errors */ |
@@ -151,6 +155,7 @@ | |||
151 | #define AUDIT_SE_TYPE 15 /* security label type */ | 155 | #define AUDIT_SE_TYPE 15 /* security label type */ |
152 | #define AUDIT_SE_SEN 16 /* security label sensitivity label */ | 156 | #define AUDIT_SE_SEN 16 /* security label sensitivity label */ |
153 | #define AUDIT_SE_CLR 17 /* security label clearance label */ | 157 | #define AUDIT_SE_CLR 17 /* security label clearance label */ |
158 | #define AUDIT_PPID 18 | ||
154 | 159 | ||
155 | /* These are ONLY useful when checking | 160 | /* These are ONLY useful when checking |
156 | * at syscall exit time (AUDIT_AT_EXIT). */ | 161 | * at syscall exit time (AUDIT_AT_EXIT). */ |
@@ -159,6 +164,7 @@ | |||
159 | #define AUDIT_INODE 102 | 164 | #define AUDIT_INODE 102 |
160 | #define AUDIT_EXIT 103 | 165 | #define AUDIT_EXIT 103 |
161 | #define AUDIT_SUCCESS 104 /* exit >= 0; value ignored */ | 166 | #define AUDIT_SUCCESS 104 /* exit >= 0; value ignored */ |
167 | #define AUDIT_WATCH 105 | ||
162 | 168 | ||
163 | #define AUDIT_ARG0 200 | 169 | #define AUDIT_ARG0 200 |
164 | #define AUDIT_ARG1 (AUDIT_ARG0+1) | 170 | #define AUDIT_ARG1 (AUDIT_ARG0+1) |
@@ -273,16 +279,21 @@ struct audit_rule { /* for AUDIT_LIST, AUDIT_ADD, and AUDIT_DEL */ | |||
273 | }; | 279 | }; |
274 | 280 | ||
275 | #ifdef __KERNEL__ | 281 | #ifdef __KERNEL__ |
282 | #include <linux/sched.h> | ||
276 | 283 | ||
277 | struct audit_sig_info { | 284 | struct audit_sig_info { |
278 | uid_t uid; | 285 | uid_t uid; |
279 | pid_t pid; | 286 | pid_t pid; |
287 | char ctx[0]; | ||
280 | }; | 288 | }; |
281 | 289 | ||
282 | struct audit_buffer; | 290 | struct audit_buffer; |
283 | struct audit_context; | 291 | struct audit_context; |
284 | struct inode; | 292 | struct inode; |
285 | struct netlink_skb_parms; | 293 | struct netlink_skb_parms; |
294 | struct linux_binprm; | ||
295 | struct mq_attr; | ||
296 | struct mqstat; | ||
286 | 297 | ||
287 | #define AUDITSC_INVALID 0 | 298 | #define AUDITSC_INVALID 0 |
288 | #define AUDITSC_SUCCESS 1 | 299 | #define AUDITSC_SUCCESS 1 |
@@ -297,15 +308,19 @@ extern void audit_syscall_entry(int arch, | |||
297 | int major, unsigned long a0, unsigned long a1, | 308 | int major, unsigned long a0, unsigned long a1, |
298 | unsigned long a2, unsigned long a3); | 309 | unsigned long a2, unsigned long a3); |
299 | extern void audit_syscall_exit(int failed, long return_code); | 310 | extern void audit_syscall_exit(int failed, long return_code); |
300 | extern void audit_getname(const char *name); | 311 | extern void __audit_getname(const char *name); |
301 | extern void audit_putname(const char *name); | 312 | extern void audit_putname(const char *name); |
302 | extern void __audit_inode(const char *name, const struct inode *inode, unsigned flags); | 313 | extern void __audit_inode(const char *name, const struct inode *inode); |
303 | extern void __audit_inode_child(const char *dname, const struct inode *inode, | 314 | extern void __audit_inode_child(const char *dname, const struct inode *inode, |
304 | unsigned long pino); | 315 | unsigned long pino); |
305 | static inline void audit_inode(const char *name, const struct inode *inode, | 316 | static inline void audit_getname(const char *name) |
306 | unsigned flags) { | 317 | { |
307 | if (unlikely(current->audit_context)) | 318 | if (unlikely(current->audit_context)) |
308 | __audit_inode(name, inode, flags); | 319 | __audit_getname(name); |
320 | } | ||
321 | static inline void audit_inode(const char *name, const struct inode *inode) { | ||
322 | if (unlikely(current->audit_context)) | ||
323 | __audit_inode(name, inode); | ||
309 | } | 324 | } |
310 | static inline void audit_inode_child(const char *dname, | 325 | static inline void audit_inode_child(const char *dname, |
311 | const struct inode *inode, | 326 | const struct inode *inode, |
@@ -320,13 +335,61 @@ extern void auditsc_get_stamp(struct audit_context *ctx, | |||
320 | struct timespec *t, unsigned int *serial); | 335 | struct timespec *t, unsigned int *serial); |
321 | extern int audit_set_loginuid(struct task_struct *task, uid_t loginuid); | 336 | extern int audit_set_loginuid(struct task_struct *task, uid_t loginuid); |
322 | extern uid_t audit_get_loginuid(struct audit_context *ctx); | 337 | extern uid_t audit_get_loginuid(struct audit_context *ctx); |
323 | extern int audit_ipc_obj(struct kern_ipc_perm *ipcp); | 338 | extern int __audit_ipc_obj(struct kern_ipc_perm *ipcp); |
324 | extern int audit_ipc_set_perm(unsigned long qbytes, uid_t uid, gid_t gid, mode_t mode, struct kern_ipc_perm *ipcp); | 339 | extern int __audit_ipc_set_perm(unsigned long qbytes, uid_t uid, gid_t gid, mode_t mode); |
340 | extern int audit_bprm(struct linux_binprm *bprm); | ||
325 | extern int audit_socketcall(int nargs, unsigned long *args); | 341 | extern int audit_socketcall(int nargs, unsigned long *args); |
326 | extern int audit_sockaddr(int len, void *addr); | 342 | extern int audit_sockaddr(int len, void *addr); |
327 | extern int audit_avc_path(struct dentry *dentry, struct vfsmount *mnt); | 343 | extern int audit_avc_path(struct dentry *dentry, struct vfsmount *mnt); |
328 | extern void audit_signal_info(int sig, struct task_struct *t); | ||
329 | extern int audit_set_macxattr(const char *name); | 344 | extern int audit_set_macxattr(const char *name); |
345 | extern int __audit_mq_open(int oflag, mode_t mode, struct mq_attr __user *u_attr); | ||
346 | extern int __audit_mq_timedsend(mqd_t mqdes, size_t msg_len, unsigned int msg_prio, const struct timespec __user *u_abs_timeout); | ||
347 | extern int __audit_mq_timedreceive(mqd_t mqdes, size_t msg_len, unsigned int __user *u_msg_prio, const struct timespec __user *u_abs_timeout); | ||
348 | extern int __audit_mq_notify(mqd_t mqdes, const struct sigevent __user *u_notification); | ||
349 | extern int __audit_mq_getsetattr(mqd_t mqdes, struct mq_attr *mqstat); | ||
350 | |||
351 | static inline int audit_ipc_obj(struct kern_ipc_perm *ipcp) | ||
352 | { | ||
353 | if (unlikely(current->audit_context)) | ||
354 | return __audit_ipc_obj(ipcp); | ||
355 | return 0; | ||
356 | } | ||
357 | static inline int audit_ipc_set_perm(unsigned long qbytes, uid_t uid, gid_t gid, mode_t mode) | ||
358 | { | ||
359 | if (unlikely(current->audit_context)) | ||
360 | return __audit_ipc_set_perm(qbytes, uid, gid, mode); | ||
361 | return 0; | ||
362 | } | ||
363 | static inline int audit_mq_open(int oflag, mode_t mode, struct mq_attr __user *u_attr) | ||
364 | { | ||
365 | if (unlikely(current->audit_context)) | ||
366 | return __audit_mq_open(oflag, mode, u_attr); | ||
367 | return 0; | ||
368 | } | ||
369 | static inline int audit_mq_timedsend(mqd_t mqdes, size_t msg_len, unsigned int msg_prio, const struct timespec __user *u_abs_timeout) | ||
370 | { | ||
371 | if (unlikely(current->audit_context)) | ||
372 | return __audit_mq_timedsend(mqdes, msg_len, msg_prio, u_abs_timeout); | ||
373 | return 0; | ||
374 | } | ||
375 | static inline int audit_mq_timedreceive(mqd_t mqdes, size_t msg_len, unsigned int __user *u_msg_prio, const struct timespec __user *u_abs_timeout) | ||
376 | { | ||
377 | if (unlikely(current->audit_context)) | ||
378 | return __audit_mq_timedreceive(mqdes, msg_len, u_msg_prio, u_abs_timeout); | ||
379 | return 0; | ||
380 | } | ||
381 | static inline int audit_mq_notify(mqd_t mqdes, const struct sigevent __user *u_notification) | ||
382 | { | ||
383 | if (unlikely(current->audit_context)) | ||
384 | return __audit_mq_notify(mqdes, u_notification); | ||
385 | return 0; | ||
386 | } | ||
387 | static inline int audit_mq_getsetattr(mqd_t mqdes, struct mq_attr *mqstat) | ||
388 | { | ||
389 | if (unlikely(current->audit_context)) | ||
390 | return __audit_mq_getsetattr(mqdes, mqstat); | ||
391 | return 0; | ||
392 | } | ||
330 | #else | 393 | #else |
331 | #define audit_alloc(t) ({ 0; }) | 394 | #define audit_alloc(t) ({ 0; }) |
332 | #define audit_free(t) do { ; } while (0) | 395 | #define audit_free(t) do { ; } while (0) |
@@ -334,19 +397,24 @@ extern int audit_set_macxattr(const char *name); | |||
334 | #define audit_syscall_exit(f,r) do { ; } while (0) | 397 | #define audit_syscall_exit(f,r) do { ; } while (0) |
335 | #define audit_getname(n) do { ; } while (0) | 398 | #define audit_getname(n) do { ; } while (0) |
336 | #define audit_putname(n) do { ; } while (0) | 399 | #define audit_putname(n) do { ; } while (0) |
337 | #define __audit_inode(n,i,f) do { ; } while (0) | 400 | #define __audit_inode(n,i) do { ; } while (0) |
338 | #define __audit_inode_child(d,i,p) do { ; } while (0) | 401 | #define __audit_inode_child(d,i,p) do { ; } while (0) |
339 | #define audit_inode(n,i,f) do { ; } while (0) | 402 | #define audit_inode(n,i) do { ; } while (0) |
340 | #define audit_inode_child(d,i,p) do { ; } while (0) | 403 | #define audit_inode_child(d,i,p) do { ; } while (0) |
341 | #define auditsc_get_stamp(c,t,s) do { BUG(); } while (0) | 404 | #define auditsc_get_stamp(c,t,s) do { BUG(); } while (0) |
342 | #define audit_get_loginuid(c) ({ -1; }) | 405 | #define audit_get_loginuid(c) ({ -1; }) |
343 | #define audit_ipc_obj(i) ({ 0; }) | 406 | #define audit_ipc_obj(i) ({ 0; }) |
344 | #define audit_ipc_set_perm(q,u,g,m,i) ({ 0; }) | 407 | #define audit_ipc_set_perm(q,u,g,m) ({ 0; }) |
408 | #define audit_bprm(p) ({ 0; }) | ||
345 | #define audit_socketcall(n,a) ({ 0; }) | 409 | #define audit_socketcall(n,a) ({ 0; }) |
346 | #define audit_sockaddr(len, addr) ({ 0; }) | 410 | #define audit_sockaddr(len, addr) ({ 0; }) |
347 | #define audit_avc_path(dentry, mnt) ({ 0; }) | 411 | #define audit_avc_path(dentry, mnt) ({ 0; }) |
348 | #define audit_signal_info(s,t) do { ; } while (0) | ||
349 | #define audit_set_macxattr(n) do { ; } while (0) | 412 | #define audit_set_macxattr(n) do { ; } while (0) |
413 | #define audit_mq_open(o,m,a) ({ 0; }) | ||
414 | #define audit_mq_timedsend(d,l,p,t) ({ 0; }) | ||
415 | #define audit_mq_timedreceive(d,l,p,t) ({ 0; }) | ||
416 | #define audit_mq_notify(d,n) ({ 0; }) | ||
417 | #define audit_mq_getsetattr(d,s) ({ 0; }) | ||
350 | #endif | 418 | #endif |
351 | 419 | ||
352 | #ifdef CONFIG_AUDIT | 420 | #ifdef CONFIG_AUDIT |
@@ -364,8 +432,11 @@ extern void audit_log_end(struct audit_buffer *ab); | |||
364 | extern void audit_log_hex(struct audit_buffer *ab, | 432 | extern void audit_log_hex(struct audit_buffer *ab, |
365 | const unsigned char *buf, | 433 | const unsigned char *buf, |
366 | size_t len); | 434 | size_t len); |
367 | extern void audit_log_untrustedstring(struct audit_buffer *ab, | 435 | extern const char * audit_log_untrustedstring(struct audit_buffer *ab, |
368 | const char *string); | 436 | const char *string); |
437 | extern const char * audit_log_n_untrustedstring(struct audit_buffer *ab, | ||
438 | size_t n, | ||
439 | const char *string); | ||
369 | extern void audit_log_d_path(struct audit_buffer *ab, | 440 | extern void audit_log_d_path(struct audit_buffer *ab, |
370 | const char *prefix, | 441 | const char *prefix, |
371 | struct dentry *dentry, | 442 | struct dentry *dentry, |
@@ -383,8 +454,8 @@ extern int audit_receive_filter(int type, int pid, int uid, int seq, | |||
383 | #define audit_log_end(b) do { ; } while (0) | 454 | #define audit_log_end(b) do { ; } while (0) |
384 | #define audit_log_hex(a,b,l) do { ; } while (0) | 455 | #define audit_log_hex(a,b,l) do { ; } while (0) |
385 | #define audit_log_untrustedstring(a,s) do { ; } while (0) | 456 | #define audit_log_untrustedstring(a,s) do { ; } while (0) |
457 | #define audit_log_n_untrustedstring(a,n,s) do { ; } while (0) | ||
386 | #define audit_log_d_path(b,p,d,v) do { ; } while (0) | 458 | #define audit_log_d_path(b,p,d,v) do { ; } while (0) |
387 | #define audit_panic(m) do { ; } while (0) | ||
388 | #endif | 459 | #endif |
389 | #endif | 460 | #endif |
390 | #endif | 461 | #endif |
diff --git a/include/linux/blkdev.h b/include/linux/blkdev.h index 59e1259b1c40..3457e7b97363 100644 --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _LINUX_BLKDEV_H | 1 | #ifndef _LINUX_BLKDEV_H |
2 | #define _LINUX_BLKDEV_H | 2 | #define _LINUX_BLKDEV_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/major.h> | 4 | #include <linux/major.h> |
6 | #include <linux/genhd.h> | 5 | #include <linux/genhd.h> |
7 | #include <linux/list.h> | 6 | #include <linux/list.h> |
@@ -439,9 +438,6 @@ struct request_queue | |||
439 | 438 | ||
440 | #define RQ_INACTIVE (-1) | 439 | #define RQ_INACTIVE (-1) |
441 | #define RQ_ACTIVE 1 | 440 | #define RQ_ACTIVE 1 |
442 | #define RQ_SCSI_BUSY 0xffff | ||
443 | #define RQ_SCSI_DONE 0xfffe | ||
444 | #define RQ_SCSI_DISCONNECTING 0xffe0 | ||
445 | 441 | ||
446 | #define QUEUE_FLAG_CLUSTER 0 /* cluster several segments into 1 */ | 442 | #define QUEUE_FLAG_CLUSTER 0 /* cluster several segments into 1 */ |
447 | #define QUEUE_FLAG_QUEUED 1 /* uses generic tag queueing */ | 443 | #define QUEUE_FLAG_QUEUED 1 /* uses generic tag queueing */ |
diff --git a/include/linux/blkpg.h b/include/linux/blkpg.h index be5d0f4ad24c..faf8a45af210 100644 --- a/include/linux/blkpg.h +++ b/include/linux/blkpg.h | |||
@@ -24,6 +24,7 @@ | |||
24 | * | 24 | * |
25 | * For today, only the partition stuff - aeb, 990515 | 25 | * For today, only the partition stuff - aeb, 990515 |
26 | */ | 26 | */ |
27 | #include <linux/compiler.h> | ||
27 | #include <linux/ioctl.h> | 28 | #include <linux/ioctl.h> |
28 | 29 | ||
29 | #define BLKPG _IO(0x12,105) | 30 | #define BLKPG _IO(0x12,105) |
diff --git a/include/linux/blktrace_api.h b/include/linux/blktrace_api.h index b34d3e73d5ea..eb1a867ed245 100644 --- a/include/linux/blktrace_api.h +++ b/include/linux/blktrace_api.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef BLKTRACE_H | 1 | #ifndef BLKTRACE_H |
2 | #define BLKTRACE_H | 2 | #define BLKTRACE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/blkdev.h> | 4 | #include <linux/blkdev.h> |
6 | #include <linux/relay.h> | 5 | #include <linux/relay.h> |
7 | 6 | ||
diff --git a/include/linux/blockgroup_lock.h b/include/linux/blockgroup_lock.h index 0137ee5dd43c..8607312983bd 100644 --- a/include/linux/blockgroup_lock.h +++ b/include/linux/blockgroup_lock.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * Simple hashed spinlocking. | 6 | * Simple hashed spinlocking. |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <linux/spinlock.h> | 9 | #include <linux/spinlock.h> |
11 | #include <linux/cache.h> | 10 | #include <linux/cache.h> |
12 | 11 | ||
diff --git a/include/linux/cache.h b/include/linux/cache.h index cc4b3aafad9a..4552504c0228 100644 --- a/include/linux/cache.h +++ b/include/linux/cache.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define __LINUX_CACHE_H | 2 | #define __LINUX_CACHE_H |
3 | 3 | ||
4 | #include <linux/kernel.h> | 4 | #include <linux/kernel.h> |
5 | #include <linux/config.h> | ||
6 | #include <asm/cache.h> | 5 | #include <asm/cache.h> |
7 | 6 | ||
8 | #ifndef L1_CACHE_ALIGN | 7 | #ifndef L1_CACHE_ALIGN |
diff --git a/include/linux/coda.h b/include/linux/coda.h index bbc5afcd7db6..b5cf0780c51a 100644 --- a/include/linux/coda.h +++ b/include/linux/coda.h | |||
@@ -59,7 +59,6 @@ Mellon the rights to redistribute these changes without encumbrance. | |||
59 | #ifndef _CODA_HEADER_ | 59 | #ifndef _CODA_HEADER_ |
60 | #define _CODA_HEADER_ | 60 | #define _CODA_HEADER_ |
61 | 61 | ||
62 | #include <linux/config.h> | ||
63 | 62 | ||
64 | /* Catch new _KERNEL defn for NetBSD and DJGPP/__CYGWIN32__ */ | 63 | /* Catch new _KERNEL defn for NetBSD and DJGPP/__CYGWIN32__ */ |
65 | #if defined(__NetBSD__) || \ | 64 | #if defined(__NetBSD__) || \ |
diff --git a/include/linux/compat.h b/include/linux/compat.h index 6d3a654be1ae..dda1697ec753 100644 --- a/include/linux/compat.h +++ b/include/linux/compat.h | |||
@@ -4,7 +4,6 @@ | |||
4 | * These are the type definitions for the architecture specific | 4 | * These are the type definitions for the architecture specific |
5 | * syscall compatibility layer. | 5 | * syscall compatibility layer. |
6 | */ | 6 | */ |
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | #ifdef CONFIG_COMPAT | 8 | #ifdef CONFIG_COMPAT |
10 | 9 | ||
diff --git a/include/linux/compiler.h b/include/linux/compiler.h index f23d3c6fc2c0..9b4f11094937 100644 --- a/include/linux/compiler.h +++ b/include/linux/compiler.h | |||
@@ -78,6 +78,7 @@ extern void __chk_io_ptr(void __iomem *); | |||
78 | 78 | ||
79 | #endif /* __ASSEMBLY__ */ | 79 | #endif /* __ASSEMBLY__ */ |
80 | 80 | ||
81 | #ifdef __KERNEL__ | ||
81 | /* | 82 | /* |
82 | * Allow us to mark functions as 'deprecated' and have gcc emit a nice | 83 | * Allow us to mark functions as 'deprecated' and have gcc emit a nice |
83 | * warning for each use, in hopes of speeding the functions removal. | 84 | * warning for each use, in hopes of speeding the functions removal. |
@@ -127,6 +128,16 @@ extern void __chk_io_ptr(void __iomem *); | |||
127 | # define __attribute_pure__ /* unimplemented */ | 128 | # define __attribute_pure__ /* unimplemented */ |
128 | #endif | 129 | #endif |
129 | 130 | ||
131 | #ifndef noinline | ||
132 | #define noinline | ||
133 | #endif | ||
134 | |||
135 | #ifndef __always_inline | ||
136 | #define __always_inline inline | ||
137 | #endif | ||
138 | |||
139 | #endif /* __KERNEL__ */ | ||
140 | |||
130 | /* | 141 | /* |
131 | * From the GCC manual: | 142 | * From the GCC manual: |
132 | * | 143 | * |
@@ -145,12 +156,4 @@ extern void __chk_io_ptr(void __iomem *); | |||
145 | # define __attribute_const__ /* unimplemented */ | 156 | # define __attribute_const__ /* unimplemented */ |
146 | #endif | 157 | #endif |
147 | 158 | ||
148 | #ifndef noinline | ||
149 | #define noinline | ||
150 | #endif | ||
151 | |||
152 | #ifndef __always_inline | ||
153 | #define __always_inline inline | ||
154 | #endif | ||
155 | |||
156 | #endif /* __LINUX_COMPILER_H */ | 159 | #endif /* __LINUX_COMPILER_H */ |
diff --git a/include/linux/connector.h b/include/linux/connector.h index ad1a22c1c42e..4c02119c6ab9 100644 --- a/include/linux/connector.h +++ b/include/linux/connector.h | |||
@@ -34,8 +34,11 @@ | |||
34 | #define CN_VAL_PROC 0x1 | 34 | #define CN_VAL_PROC 0x1 |
35 | #define CN_IDX_CIFS 0x2 | 35 | #define CN_IDX_CIFS 0x2 |
36 | #define CN_VAL_CIFS 0x1 | 36 | #define CN_VAL_CIFS 0x1 |
37 | #define CN_W1_IDX 0x3 /* w1 communication */ | ||
38 | #define CN_W1_VAL 0x1 | ||
37 | 39 | ||
38 | #define CN_NETLINK_USERS 1 | 40 | |
41 | #define CN_NETLINK_USERS 4 | ||
39 | 42 | ||
40 | /* | 43 | /* |
41 | * Maximum connector's message size. | 44 | * Maximum connector's message size. |
diff --git a/include/linux/console.h b/include/linux/console.h index 721371382ae5..08734e660d41 100644 --- a/include/linux/console.h +++ b/include/linux/console.h | |||
@@ -117,6 +117,10 @@ extern void console_stop(struct console *); | |||
117 | extern void console_start(struct console *); | 117 | extern void console_start(struct console *); |
118 | extern int is_console_locked(void); | 118 | extern int is_console_locked(void); |
119 | 119 | ||
120 | /* Suspend and resume console messages over PM events */ | ||
121 | extern void suspend_console(void); | ||
122 | extern void resume_console(void); | ||
123 | |||
120 | /* Some debug stub to catch some of the obvious races in the VT code */ | 124 | /* Some debug stub to catch some of the obvious races in the VT code */ |
121 | #if 1 | 125 | #if 1 |
122 | #define WARN_CONSOLE_UNLOCKED() WARN_ON(!is_console_locked() && !oops_in_progress) | 126 | #define WARN_CONSOLE_UNLOCKED() WARN_ON(!is_console_locked() && !oops_in_progress) |
diff --git a/include/linux/cpufreq.h b/include/linux/cpufreq.h index 17866d7e2b71..5aa95011f7e6 100644 --- a/include/linux/cpufreq.h +++ b/include/linux/cpufreq.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #define _LINUX_CPUFREQ_H | 15 | #define _LINUX_CPUFREQ_H |
16 | 16 | ||
17 | #include <linux/mutex.h> | 17 | #include <linux/mutex.h> |
18 | #include <linux/config.h> | ||
19 | #include <linux/notifier.h> | 18 | #include <linux/notifier.h> |
20 | #include <linux/threads.h> | 19 | #include <linux/threads.h> |
21 | #include <linux/device.h> | 20 | #include <linux/device.h> |
diff --git a/include/linux/cramfs_fs.h b/include/linux/cramfs_fs.h index a8948f34b776..a41f38428c37 100644 --- a/include/linux/cramfs_fs.h +++ b/include/linux/cramfs_fs.h | |||
@@ -1,13 +1,7 @@ | |||
1 | #ifndef __CRAMFS_H | 1 | #ifndef __CRAMFS_H |
2 | #define __CRAMFS_H | 2 | #define __CRAMFS_H |
3 | 3 | ||
4 | #ifndef __KERNEL__ | 4 | #include <linux/types.h> |
5 | |||
6 | typedef unsigned char u8; | ||
7 | typedef unsigned short u16; | ||
8 | typedef unsigned int u32; | ||
9 | |||
10 | #endif | ||
11 | 5 | ||
12 | #define CRAMFS_MAGIC 0x28cd3d45 /* some random number */ | 6 | #define CRAMFS_MAGIC 0x28cd3d45 /* some random number */ |
13 | #define CRAMFS_SIGNATURE "Compressed ROMFS" | 7 | #define CRAMFS_SIGNATURE "Compressed ROMFS" |
@@ -33,9 +27,9 @@ typedef unsigned int u32; | |||
33 | * Reasonably terse representation of the inode data. | 27 | * Reasonably terse representation of the inode data. |
34 | */ | 28 | */ |
35 | struct cramfs_inode { | 29 | struct cramfs_inode { |
36 | u32 mode:CRAMFS_MODE_WIDTH, uid:CRAMFS_UID_WIDTH; | 30 | __u32 mode:CRAMFS_MODE_WIDTH, uid:CRAMFS_UID_WIDTH; |
37 | /* SIZE for device files is i_rdev */ | 31 | /* SIZE for device files is i_rdev */ |
38 | u32 size:CRAMFS_SIZE_WIDTH, gid:CRAMFS_GID_WIDTH; | 32 | __u32 size:CRAMFS_SIZE_WIDTH, gid:CRAMFS_GID_WIDTH; |
39 | /* NAMELEN is the length of the file name, divided by 4 and | 33 | /* NAMELEN is the length of the file name, divided by 4 and |
40 | rounded up. (cramfs doesn't support hard links.) */ | 34 | rounded up. (cramfs doesn't support hard links.) */ |
41 | /* OFFSET: For symlinks and non-empty regular files, this | 35 | /* OFFSET: For symlinks and non-empty regular files, this |
@@ -44,27 +38,27 @@ struct cramfs_inode { | |||
44 | see README). For non-empty directories it is the offset | 38 | see README). For non-empty directories it is the offset |
45 | (divided by 4) of the inode of the first file in that | 39 | (divided by 4) of the inode of the first file in that |
46 | directory. For anything else, offset is zero. */ | 40 | directory. For anything else, offset is zero. */ |
47 | u32 namelen:CRAMFS_NAMELEN_WIDTH, offset:CRAMFS_OFFSET_WIDTH; | 41 | __u32 namelen:CRAMFS_NAMELEN_WIDTH, offset:CRAMFS_OFFSET_WIDTH; |
48 | }; | 42 | }; |
49 | 43 | ||
50 | struct cramfs_info { | 44 | struct cramfs_info { |
51 | u32 crc; | 45 | __u32 crc; |
52 | u32 edition; | 46 | __u32 edition; |
53 | u32 blocks; | 47 | __u32 blocks; |
54 | u32 files; | 48 | __u32 files; |
55 | }; | 49 | }; |
56 | 50 | ||
57 | /* | 51 | /* |
58 | * Superblock information at the beginning of the FS. | 52 | * Superblock information at the beginning of the FS. |
59 | */ | 53 | */ |
60 | struct cramfs_super { | 54 | struct cramfs_super { |
61 | u32 magic; /* 0x28cd3d45 - random number */ | 55 | __u32 magic; /* 0x28cd3d45 - random number */ |
62 | u32 size; /* length in bytes */ | 56 | __u32 size; /* length in bytes */ |
63 | u32 flags; /* feature flags */ | 57 | __u32 flags; /* feature flags */ |
64 | u32 future; /* reserved for future use */ | 58 | __u32 future; /* reserved for future use */ |
65 | u8 signature[16]; /* "Compressed ROMFS" */ | 59 | __u8 signature[16]; /* "Compressed ROMFS" */ |
66 | struct cramfs_info fsid; /* unique filesystem info */ | 60 | struct cramfs_info fsid; /* unique filesystem info */ |
67 | u8 name[16]; /* user-defined name */ | 61 | __u8 name[16]; /* user-defined name */ |
68 | struct cramfs_inode root; /* root inode data */ | 62 | struct cramfs_inode root; /* root inode data */ |
69 | }; | 63 | }; |
70 | 64 | ||
diff --git a/include/linux/crypto.h b/include/linux/crypto.h index 0ab1bc1152ca..5a0470e36111 100644 --- a/include/linux/crypto.h +++ b/include/linux/crypto.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #ifndef _LINUX_CRYPTO_H | 17 | #ifndef _LINUX_CRYPTO_H |
18 | #define _LINUX_CRYPTO_H | 18 | #define _LINUX_CRYPTO_H |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <linux/module.h> | 20 | #include <linux/module.h> |
22 | #include <linux/kernel.h> | 21 | #include <linux/kernel.h> |
23 | #include <linux/types.h> | 22 | #include <linux/types.h> |
diff --git a/include/linux/cyclomx.h b/include/linux/cyclomx.h index 300d704bdb9a..b88f7f428e58 100644 --- a/include/linux/cyclomx.h +++ b/include/linux/cyclomx.h | |||
@@ -24,7 +24,6 @@ | |||
24 | * 1998/08/08 acme Version 0.0.1 | 24 | * 1998/08/08 acme Version 0.0.1 |
25 | */ | 25 | */ |
26 | 26 | ||
27 | #include <linux/config.h> | ||
28 | #include <linux/wanrouter.h> | 27 | #include <linux/wanrouter.h> |
29 | #include <linux/spinlock.h> | 28 | #include <linux/spinlock.h> |
30 | 29 | ||
diff --git a/include/linux/dcache.h b/include/linux/dcache.h index 836325ee0931..46d0e079735d 100644 --- a/include/linux/dcache.h +++ b/include/linux/dcache.h | |||
@@ -217,7 +217,7 @@ extern struct dentry * d_alloc_anon(struct inode *); | |||
217 | extern struct dentry * d_splice_alias(struct inode *, struct dentry *); | 217 | extern struct dentry * d_splice_alias(struct inode *, struct dentry *); |
218 | extern void shrink_dcache_sb(struct super_block *); | 218 | extern void shrink_dcache_sb(struct super_block *); |
219 | extern void shrink_dcache_parent(struct dentry *); | 219 | extern void shrink_dcache_parent(struct dentry *); |
220 | extern void shrink_dcache_anon(struct hlist_head *); | 220 | extern void shrink_dcache_anon(struct super_block *); |
221 | extern int d_invalidate(struct dentry *); | 221 | extern int d_invalidate(struct dentry *); |
222 | 222 | ||
223 | /* only used at mount-time */ | 223 | /* only used at mount-time */ |
diff --git a/include/linux/dcookies.h b/include/linux/dcookies.h index 1d68428c925d..0fe7cdf326f7 100644 --- a/include/linux/dcookies.h +++ b/include/linux/dcookies.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef DCOOKIES_H | 9 | #ifndef DCOOKIES_H |
10 | #define DCOOKIES_H | 10 | #define DCOOKIES_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | #ifdef CONFIG_PROFILING | 13 | #ifdef CONFIG_PROFILING |
15 | 14 | ||
diff --git a/include/linux/devfs_fs_kernel.h b/include/linux/devfs_fs_kernel.h index 89810e73d256..0d74a6f22abc 100644 --- a/include/linux/devfs_fs_kernel.h +++ b/include/linux/devfs_fs_kernel.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define _LINUX_DEVFS_FS_KERNEL_H | 2 | #define _LINUX_DEVFS_FS_KERNEL_H |
3 | 3 | ||
4 | #include <linux/fs.h> | 4 | #include <linux/fs.h> |
5 | #include <linux/config.h> | ||
6 | #include <linux/spinlock.h> | 5 | #include <linux/spinlock.h> |
7 | #include <linux/types.h> | 6 | #include <linux/types.h> |
8 | 7 | ||
diff --git a/include/linux/device.h b/include/linux/device.h index e8e53b9accc6..1e5f30da98bc 100644 --- a/include/linux/device.h +++ b/include/linux/device.h | |||
@@ -11,7 +11,6 @@ | |||
11 | #ifndef _DEVICE_H_ | 11 | #ifndef _DEVICE_H_ |
12 | #define _DEVICE_H_ | 12 | #define _DEVICE_H_ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/ioport.h> | 14 | #include <linux/ioport.h> |
16 | #include <linux/kobject.h> | 15 | #include <linux/kobject.h> |
17 | #include <linux/klist.h> | 16 | #include <linux/klist.h> |
@@ -61,11 +60,6 @@ extern void bus_unregister(struct bus_type * bus); | |||
61 | 60 | ||
62 | extern void bus_rescan_devices(struct bus_type * bus); | 61 | extern void bus_rescan_devices(struct bus_type * bus); |
63 | 62 | ||
64 | extern struct bus_type * get_bus(struct bus_type * bus); | ||
65 | extern void put_bus(struct bus_type * bus); | ||
66 | |||
67 | extern struct bus_type * find_bus(char * name); | ||
68 | |||
69 | /* iterator helpers for buses */ | 63 | /* iterator helpers for buses */ |
70 | 64 | ||
71 | int bus_for_each_dev(struct bus_type * bus, struct device * start, void * data, | 65 | int bus_for_each_dev(struct bus_type * bus, struct device * start, void * data, |
@@ -148,6 +142,7 @@ struct class { | |||
148 | 142 | ||
149 | struct subsystem subsys; | 143 | struct subsystem subsys; |
150 | struct list_head children; | 144 | struct list_head children; |
145 | struct list_head devices; | ||
151 | struct list_head interfaces; | 146 | struct list_head interfaces; |
152 | struct semaphore sem; /* locks both the children and interfaces lists */ | 147 | struct semaphore sem; /* locks both the children and interfaces lists */ |
153 | 148 | ||
@@ -164,9 +159,6 @@ struct class { | |||
164 | extern int class_register(struct class *); | 159 | extern int class_register(struct class *); |
165 | extern void class_unregister(struct class *); | 160 | extern void class_unregister(struct class *); |
166 | 161 | ||
167 | extern struct class * class_get(struct class *); | ||
168 | extern void class_put(struct class *); | ||
169 | |||
170 | 162 | ||
171 | struct class_attribute { | 163 | struct class_attribute { |
172 | struct attribute attr; | 164 | struct attribute attr; |
@@ -314,6 +306,7 @@ struct device { | |||
314 | struct kobject kobj; | 306 | struct kobject kobj; |
315 | char bus_id[BUS_ID_SIZE]; /* position on parent bus */ | 307 | char bus_id[BUS_ID_SIZE]; /* position on parent bus */ |
316 | struct device_attribute uevent_attr; | 308 | struct device_attribute uevent_attr; |
309 | struct device_attribute *devt_attr; | ||
317 | 310 | ||
318 | struct semaphore sem; /* semaphore to synchronize calls to | 311 | struct semaphore sem; /* semaphore to synchronize calls to |
319 | * its driver. | 312 | * its driver. |
@@ -341,6 +334,11 @@ struct device { | |||
341 | struct dma_coherent_mem *dma_mem; /* internal for coherent mem | 334 | struct dma_coherent_mem *dma_mem; /* internal for coherent mem |
342 | override */ | 335 | override */ |
343 | 336 | ||
337 | /* class_device migration path */ | ||
338 | struct list_head node; | ||
339 | struct class *class; /* optional*/ | ||
340 | dev_t devt; /* dev_t, creates the sysfs "dev" */ | ||
341 | |||
344 | void (*release)(struct device * dev); | 342 | void (*release)(struct device * dev); |
345 | }; | 343 | }; |
346 | 344 | ||
@@ -382,6 +380,13 @@ extern int device_attach(struct device * dev); | |||
382 | extern void driver_attach(struct device_driver * drv); | 380 | extern void driver_attach(struct device_driver * drv); |
383 | extern void device_reprobe(struct device *dev); | 381 | extern void device_reprobe(struct device *dev); |
384 | 382 | ||
383 | /* | ||
384 | * Easy functions for dynamically creating devices on the fly | ||
385 | */ | ||
386 | extern struct device *device_create(struct class *cls, struct device *parent, | ||
387 | dev_t devt, char *fmt, ...) | ||
388 | __attribute__((format(printf,4,5))); | ||
389 | extern void device_destroy(struct class *cls, dev_t devt); | ||
385 | 390 | ||
386 | /* | 391 | /* |
387 | * Platform "fixup" functions - allow the platform to have their say | 392 | * Platform "fixup" functions - allow the platform to have their say |
@@ -411,8 +416,9 @@ extern int firmware_register(struct subsystem *); | |||
411 | extern void firmware_unregister(struct subsystem *); | 416 | extern void firmware_unregister(struct subsystem *); |
412 | 417 | ||
413 | /* debugging and troubleshooting/diagnostic helpers. */ | 418 | /* debugging and troubleshooting/diagnostic helpers. */ |
419 | extern const char *dev_driver_string(struct device *dev); | ||
414 | #define dev_printk(level, dev, format, arg...) \ | 420 | #define dev_printk(level, dev, format, arg...) \ |
415 | printk(level "%s %s: " format , (dev)->driver ? (dev)->driver->name : "" , (dev)->bus_id , ## arg) | 421 | printk(level "%s %s: " format , dev_driver_string(dev) , (dev)->bus_id , ## arg) |
416 | 422 | ||
417 | #ifdef DEBUG | 423 | #ifdef DEBUG |
418 | #define dev_dbg(dev, format, arg...) \ | 424 | #define dev_dbg(dev, format, arg...) \ |
diff --git a/include/linux/divert.h b/include/linux/divert.h index 6919b09133d4..8fb4e9de6843 100644 --- a/include/linux/divert.h +++ b/include/linux/divert.h | |||
@@ -27,10 +27,10 @@ struct divert_blk | |||
27 | { | 27 | { |
28 | int divert; /* are we active */ | 28 | int divert; /* are we active */ |
29 | unsigned int protos; /* protocols */ | 29 | unsigned int protos; /* protocols */ |
30 | u16 tcp_dst[MAX_DIVERT_PORTS]; /* specific tcp dst ports to divert */ | 30 | __u16 tcp_dst[MAX_DIVERT_PORTS]; /* specific tcp dst ports to divert */ |
31 | u16 tcp_src[MAX_DIVERT_PORTS]; /* specific tcp src ports to divert */ | 31 | __u16 tcp_src[MAX_DIVERT_PORTS]; /* specific tcp src ports to divert */ |
32 | u16 udp_dst[MAX_DIVERT_PORTS]; /* specific udp dst ports to divert */ | 32 | __u16 udp_dst[MAX_DIVERT_PORTS]; /* specific udp dst ports to divert */ |
33 | u16 udp_src[MAX_DIVERT_PORTS]; /* specific udp src ports to divert */ | 33 | __u16 udp_src[MAX_DIVERT_PORTS]; /* specific udp src ports to divert */ |
34 | }; | 34 | }; |
35 | 35 | ||
36 | /* | 36 | /* |
@@ -40,12 +40,12 @@ struct divert_blk | |||
40 | 40 | ||
41 | typedef union _divert_cf_arg | 41 | typedef union _divert_cf_arg |
42 | { | 42 | { |
43 | s16 int16; | 43 | __s16 int16; |
44 | u16 uint16; | 44 | __u16 uint16; |
45 | s32 int32; | 45 | __s32 int32; |
46 | u32 uint32; | 46 | __u32 uint32; |
47 | s64 int64; | 47 | __s64 int64; |
48 | u64 uint64; | 48 | __u64 uint64; |
49 | void __user *ptr; | 49 | void __user *ptr; |
50 | } divert_cf_arg; | 50 | } divert_cf_arg; |
51 | 51 | ||
diff --git a/include/linux/dmaengine.h b/include/linux/dmaengine.h new file mode 100644 index 000000000000..78b236ca04f8 --- /dev/null +++ b/include/linux/dmaengine.h | |||
@@ -0,0 +1,359 @@ | |||
1 | /* | ||
2 | * Copyright(c) 2004 - 2006 Intel Corporation. All rights reserved. | ||
3 | * | ||
4 | * This program is free software; you can redistribute it and/or modify it | ||
5 | * under the terms of the GNU General Public License as published by the Free | ||
6 | * Software Foundation; either version 2 of the License, or (at your option) | ||
7 | * any later version. | ||
8 | * | ||
9 | * This program is distributed in the hope that it will be useful, but WITHOUT | ||
10 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
11 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | ||
12 | * more details. | ||
13 | * | ||
14 | * You should have received a copy of the GNU General Public License along with | ||
15 | * this program; if not, write to the Free Software Foundation, Inc., 59 | ||
16 | * Temple Place - Suite 330, Boston, MA 02111-1307, USA. | ||
17 | * | ||
18 | * The full GNU General Public License is included in this distribution in the | ||
19 | * file called COPYING. | ||
20 | */ | ||
21 | #ifndef DMAENGINE_H | ||
22 | #define DMAENGINE_H | ||
23 | #include <linux/config.h> | ||
24 | #ifdef CONFIG_DMA_ENGINE | ||
25 | |||
26 | #include <linux/device.h> | ||
27 | #include <linux/uio.h> | ||
28 | #include <linux/kref.h> | ||
29 | #include <linux/completion.h> | ||
30 | #include <linux/rcupdate.h> | ||
31 | |||
32 | /** | ||
33 | * enum dma_event - resource PNP/power managment events | ||
34 | * @DMA_RESOURCE_SUSPEND: DMA device going into low power state | ||
35 | * @DMA_RESOURCE_RESUME: DMA device returning to full power | ||
36 | * @DMA_RESOURCE_ADDED: DMA device added to the system | ||
37 | * @DMA_RESOURCE_REMOVED: DMA device removed from the system | ||
38 | */ | ||
39 | enum dma_event { | ||
40 | DMA_RESOURCE_SUSPEND, | ||
41 | DMA_RESOURCE_RESUME, | ||
42 | DMA_RESOURCE_ADDED, | ||
43 | DMA_RESOURCE_REMOVED, | ||
44 | }; | ||
45 | |||
46 | /** | ||
47 | * typedef dma_cookie_t | ||
48 | * | ||
49 | * if dma_cookie_t is >0 it's a DMA request cookie, <0 it's an error code | ||
50 | */ | ||
51 | typedef s32 dma_cookie_t; | ||
52 | |||
53 | #define dma_submit_error(cookie) ((cookie) < 0 ? 1 : 0) | ||
54 | |||
55 | /** | ||
56 | * enum dma_status - DMA transaction status | ||
57 | * @DMA_SUCCESS: transaction completed successfully | ||
58 | * @DMA_IN_PROGRESS: transaction not yet processed | ||
59 | * @DMA_ERROR: transaction failed | ||
60 | */ | ||
61 | enum dma_status { | ||
62 | DMA_SUCCESS, | ||
63 | DMA_IN_PROGRESS, | ||
64 | DMA_ERROR, | ||
65 | }; | ||
66 | |||
67 | /** | ||
68 | * struct dma_chan_percpu - the per-CPU part of struct dma_chan | ||
69 | * @refcount: local_t used for open-coded "bigref" counting | ||
70 | * @memcpy_count: transaction counter | ||
71 | * @bytes_transferred: byte counter | ||
72 | */ | ||
73 | |||
74 | struct dma_chan_percpu { | ||
75 | local_t refcount; | ||
76 | /* stats */ | ||
77 | unsigned long memcpy_count; | ||
78 | unsigned long bytes_transferred; | ||
79 | }; | ||
80 | |||
81 | /** | ||
82 | * struct dma_chan - devices supply DMA channels, clients use them | ||
83 | * @client: ptr to the client user of this chan, will be NULL when unused | ||
84 | * @device: ptr to the dma device who supplies this channel, always !NULL | ||
85 | * @cookie: last cookie value returned to client | ||
86 | * @chan_id: | ||
87 | * @class_dev: | ||
88 | * @refcount: kref, used in "bigref" slow-mode | ||
89 | * @slow_ref: | ||
90 | * @rcu: | ||
91 | * @client_node: used to add this to the client chan list | ||
92 | * @device_node: used to add this to the device chan list | ||
93 | * @local: per-cpu pointer to a struct dma_chan_percpu | ||
94 | */ | ||
95 | struct dma_chan { | ||
96 | struct dma_client *client; | ||
97 | struct dma_device *device; | ||
98 | dma_cookie_t cookie; | ||
99 | |||
100 | /* sysfs */ | ||
101 | int chan_id; | ||
102 | struct class_device class_dev; | ||
103 | |||
104 | struct kref refcount; | ||
105 | int slow_ref; | ||
106 | struct rcu_head rcu; | ||
107 | |||
108 | struct list_head client_node; | ||
109 | struct list_head device_node; | ||
110 | struct dma_chan_percpu *local; | ||
111 | }; | ||
112 | |||
113 | void dma_chan_cleanup(struct kref *kref); | ||
114 | |||
115 | static inline void dma_chan_get(struct dma_chan *chan) | ||
116 | { | ||
117 | if (unlikely(chan->slow_ref)) | ||
118 | kref_get(&chan->refcount); | ||
119 | else { | ||
120 | local_inc(&(per_cpu_ptr(chan->local, get_cpu())->refcount)); | ||
121 | put_cpu(); | ||
122 | } | ||
123 | } | ||
124 | |||
125 | static inline void dma_chan_put(struct dma_chan *chan) | ||
126 | { | ||
127 | if (unlikely(chan->slow_ref)) | ||
128 | kref_put(&chan->refcount, dma_chan_cleanup); | ||
129 | else { | ||
130 | local_dec(&(per_cpu_ptr(chan->local, get_cpu())->refcount)); | ||
131 | put_cpu(); | ||
132 | } | ||
133 | } | ||
134 | |||
135 | /* | ||
136 | * typedef dma_event_callback - function pointer to a DMA event callback | ||
137 | */ | ||
138 | typedef void (*dma_event_callback) (struct dma_client *client, | ||
139 | struct dma_chan *chan, enum dma_event event); | ||
140 | |||
141 | /** | ||
142 | * struct dma_client - info on the entity making use of DMA services | ||
143 | * @event_callback: func ptr to call when something happens | ||
144 | * @chan_count: number of chans allocated | ||
145 | * @chans_desired: number of chans requested. Can be +/- chan_count | ||
146 | * @lock: protects access to the channels list | ||
147 | * @channels: the list of DMA channels allocated | ||
148 | * @global_node: list_head for global dma_client_list | ||
149 | */ | ||
150 | struct dma_client { | ||
151 | dma_event_callback event_callback; | ||
152 | unsigned int chan_count; | ||
153 | unsigned int chans_desired; | ||
154 | |||
155 | spinlock_t lock; | ||
156 | struct list_head channels; | ||
157 | struct list_head global_node; | ||
158 | }; | ||
159 | |||
160 | /** | ||
161 | * struct dma_device - info on the entity supplying DMA services | ||
162 | * @chancnt: how many DMA channels are supported | ||
163 | * @channels: the list of struct dma_chan | ||
164 | * @global_node: list_head for global dma_device_list | ||
165 | * @refcount: | ||
166 | * @done: | ||
167 | * @dev_id: | ||
168 | * Other func ptrs: used to make use of this device's capabilities | ||
169 | */ | ||
170 | struct dma_device { | ||
171 | |||
172 | unsigned int chancnt; | ||
173 | struct list_head channels; | ||
174 | struct list_head global_node; | ||
175 | |||
176 | struct kref refcount; | ||
177 | struct completion done; | ||
178 | |||
179 | int dev_id; | ||
180 | |||
181 | int (*device_alloc_chan_resources)(struct dma_chan *chan); | ||
182 | void (*device_free_chan_resources)(struct dma_chan *chan); | ||
183 | dma_cookie_t (*device_memcpy_buf_to_buf)(struct dma_chan *chan, | ||
184 | void *dest, void *src, size_t len); | ||
185 | dma_cookie_t (*device_memcpy_buf_to_pg)(struct dma_chan *chan, | ||
186 | struct page *page, unsigned int offset, void *kdata, | ||
187 | size_t len); | ||
188 | dma_cookie_t (*device_memcpy_pg_to_pg)(struct dma_chan *chan, | ||
189 | struct page *dest_pg, unsigned int dest_off, | ||
190 | struct page *src_pg, unsigned int src_off, size_t len); | ||
191 | enum dma_status (*device_memcpy_complete)(struct dma_chan *chan, | ||
192 | dma_cookie_t cookie, dma_cookie_t *last, | ||
193 | dma_cookie_t *used); | ||
194 | void (*device_memcpy_issue_pending)(struct dma_chan *chan); | ||
195 | }; | ||
196 | |||
197 | /* --- public DMA engine API --- */ | ||
198 | |||
199 | struct dma_client *dma_async_client_register(dma_event_callback event_callback); | ||
200 | void dma_async_client_unregister(struct dma_client *client); | ||
201 | void dma_async_client_chan_request(struct dma_client *client, | ||
202 | unsigned int number); | ||
203 | |||
204 | /** | ||
205 | * dma_async_memcpy_buf_to_buf - offloaded copy between virtual addresses | ||
206 | * @chan: DMA channel to offload copy to | ||
207 | * @dest: destination address (virtual) | ||
208 | * @src: source address (virtual) | ||
209 | * @len: length | ||
210 | * | ||
211 | * Both @dest and @src must be mappable to a bus address according to the | ||
212 | * DMA mapping API rules for streaming mappings. | ||
213 | * Both @dest and @src must stay memory resident (kernel memory or locked | ||
214 | * user space pages) | ||
215 | */ | ||
216 | static inline dma_cookie_t dma_async_memcpy_buf_to_buf(struct dma_chan *chan, | ||
217 | void *dest, void *src, size_t len) | ||
218 | { | ||
219 | int cpu = get_cpu(); | ||
220 | per_cpu_ptr(chan->local, cpu)->bytes_transferred += len; | ||
221 | per_cpu_ptr(chan->local, cpu)->memcpy_count++; | ||
222 | put_cpu(); | ||
223 | |||
224 | return chan->device->device_memcpy_buf_to_buf(chan, dest, src, len); | ||
225 | } | ||
226 | |||
227 | /** | ||
228 | * dma_async_memcpy_buf_to_pg - offloaded copy | ||
229 | * @chan: DMA channel to offload copy to | ||
230 | * @page: destination page | ||
231 | * @offset: offset in page to copy to | ||
232 | * @kdata: source address (virtual) | ||
233 | * @len: length | ||
234 | * | ||
235 | * Both @page/@offset and @kdata must be mappable to a bus address according | ||
236 | * to the DMA mapping API rules for streaming mappings. | ||
237 | * Both @page/@offset and @kdata must stay memory resident (kernel memory or | ||
238 | * locked user space pages) | ||
239 | */ | ||
240 | static inline dma_cookie_t dma_async_memcpy_buf_to_pg(struct dma_chan *chan, | ||
241 | struct page *page, unsigned int offset, void *kdata, size_t len) | ||
242 | { | ||
243 | int cpu = get_cpu(); | ||
244 | per_cpu_ptr(chan->local, cpu)->bytes_transferred += len; | ||
245 | per_cpu_ptr(chan->local, cpu)->memcpy_count++; | ||
246 | put_cpu(); | ||
247 | |||
248 | return chan->device->device_memcpy_buf_to_pg(chan, page, offset, | ||
249 | kdata, len); | ||
250 | } | ||
251 | |||
252 | /** | ||
253 | * dma_async_memcpy_buf_to_pg - offloaded copy | ||
254 | * @chan: DMA channel to offload copy to | ||
255 | * @dest_page: destination page | ||
256 | * @dest_off: offset in page to copy to | ||
257 | * @src_page: source page | ||
258 | * @src_off: offset in page to copy from | ||
259 | * @len: length | ||
260 | * | ||
261 | * Both @dest_page/@dest_off and @src_page/@src_off must be mappable to a bus | ||
262 | * address according to the DMA mapping API rules for streaming mappings. | ||
263 | * Both @dest_page/@dest_off and @src_page/@src_off must stay memory resident | ||
264 | * (kernel memory or locked user space pages) | ||
265 | */ | ||
266 | static inline dma_cookie_t dma_async_memcpy_pg_to_pg(struct dma_chan *chan, | ||
267 | struct page *dest_pg, unsigned int dest_off, struct page *src_pg, | ||
268 | unsigned int src_off, size_t len) | ||
269 | { | ||
270 | int cpu = get_cpu(); | ||
271 | per_cpu_ptr(chan->local, cpu)->bytes_transferred += len; | ||
272 | per_cpu_ptr(chan->local, cpu)->memcpy_count++; | ||
273 | put_cpu(); | ||
274 | |||
275 | return chan->device->device_memcpy_pg_to_pg(chan, dest_pg, dest_off, | ||
276 | src_pg, src_off, len); | ||
277 | } | ||
278 | |||
279 | /** | ||
280 | * dma_async_memcpy_issue_pending - flush pending copies to HW | ||
281 | * @chan: | ||
282 | * | ||
283 | * This allows drivers to push copies to HW in batches, | ||
284 | * reducing MMIO writes where possible. | ||
285 | */ | ||
286 | static inline void dma_async_memcpy_issue_pending(struct dma_chan *chan) | ||
287 | { | ||
288 | return chan->device->device_memcpy_issue_pending(chan); | ||
289 | } | ||
290 | |||
291 | /** | ||
292 | * dma_async_memcpy_complete - poll for transaction completion | ||
293 | * @chan: DMA channel | ||
294 | * @cookie: transaction identifier to check status of | ||
295 | * @last: returns last completed cookie, can be NULL | ||
296 | * @used: returns last issued cookie, can be NULL | ||
297 | * | ||
298 | * If @last and @used are passed in, upon return they reflect the driver | ||
299 | * internal state and can be used with dma_async_is_complete() to check | ||
300 | * the status of multiple cookies without re-checking hardware state. | ||
301 | */ | ||
302 | static inline enum dma_status dma_async_memcpy_complete(struct dma_chan *chan, | ||
303 | dma_cookie_t cookie, dma_cookie_t *last, dma_cookie_t *used) | ||
304 | { | ||
305 | return chan->device->device_memcpy_complete(chan, cookie, last, used); | ||
306 | } | ||
307 | |||
308 | /** | ||
309 | * dma_async_is_complete - test a cookie against chan state | ||
310 | * @cookie: transaction identifier to test status of | ||
311 | * @last_complete: last know completed transaction | ||
312 | * @last_used: last cookie value handed out | ||
313 | * | ||
314 | * dma_async_is_complete() is used in dma_async_memcpy_complete() | ||
315 | * the test logic is seperated for lightweight testing of multiple cookies | ||
316 | */ | ||
317 | static inline enum dma_status dma_async_is_complete(dma_cookie_t cookie, | ||
318 | dma_cookie_t last_complete, dma_cookie_t last_used) | ||
319 | { | ||
320 | if (last_complete <= last_used) { | ||
321 | if ((cookie <= last_complete) || (cookie > last_used)) | ||
322 | return DMA_SUCCESS; | ||
323 | } else { | ||
324 | if ((cookie <= last_complete) && (cookie > last_used)) | ||
325 | return DMA_SUCCESS; | ||
326 | } | ||
327 | return DMA_IN_PROGRESS; | ||
328 | } | ||
329 | |||
330 | |||
331 | /* --- DMA device --- */ | ||
332 | |||
333 | int dma_async_device_register(struct dma_device *device); | ||
334 | void dma_async_device_unregister(struct dma_device *device); | ||
335 | |||
336 | /* --- Helper iov-locking functions --- */ | ||
337 | |||
338 | struct dma_page_list { | ||
339 | char *base_address; | ||
340 | int nr_pages; | ||
341 | struct page **pages; | ||
342 | }; | ||
343 | |||
344 | struct dma_pinned_list { | ||
345 | int nr_iovecs; | ||
346 | struct dma_page_list page_list[0]; | ||
347 | }; | ||
348 | |||
349 | struct dma_pinned_list *dma_pin_iovec_pages(struct iovec *iov, size_t len); | ||
350 | void dma_unpin_iovec_pages(struct dma_pinned_list* pinned_list); | ||
351 | |||
352 | dma_cookie_t dma_memcpy_to_iovec(struct dma_chan *chan, struct iovec *iov, | ||
353 | struct dma_pinned_list *pinned_list, unsigned char *kdata, size_t len); | ||
354 | dma_cookie_t dma_memcpy_pg_to_iovec(struct dma_chan *chan, struct iovec *iov, | ||
355 | struct dma_pinned_list *pinned_list, struct page *page, | ||
356 | unsigned int offset, size_t len); | ||
357 | |||
358 | #endif /* CONFIG_DMA_ENGINE */ | ||
359 | #endif /* DMAENGINE_H */ | ||
diff --git a/include/linux/dmi.h b/include/linux/dmi.h index 64fd6c366604..b2cd2071d432 100644 --- a/include/linux/dmi.h +++ b/include/linux/dmi.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define __DMI_H__ | 2 | #define __DMI_H__ |
3 | 3 | ||
4 | #include <linux/list.h> | 4 | #include <linux/list.h> |
5 | #include <linux/config.h> | ||
6 | 5 | ||
7 | enum dmi_field { | 6 | enum dmi_field { |
8 | DMI_NONE, | 7 | DMI_NONE, |
diff --git a/include/linux/dnotify.h b/include/linux/dnotify.h index f134a01975c7..102a902b4396 100644 --- a/include/linux/dnotify.h +++ b/include/linux/dnotify.h | |||
@@ -18,7 +18,6 @@ struct dnotify_struct { | |||
18 | 18 | ||
19 | #ifdef __KERNEL__ | 19 | #ifdef __KERNEL__ |
20 | 20 | ||
21 | #include <linux/config.h> | ||
22 | 21 | ||
23 | #ifdef CONFIG_DNOTIFY | 22 | #ifdef CONFIG_DNOTIFY |
24 | 23 | ||
diff --git a/include/linux/elf-em.h b/include/linux/elf-em.h new file mode 100644 index 000000000000..114a96d25652 --- /dev/null +++ b/include/linux/elf-em.h | |||
@@ -0,0 +1,44 @@ | |||
1 | #ifndef _LINUX_ELF_EM_H | ||
2 | #define _LINUX_ELF_EM_H | ||
3 | |||
4 | /* These constants define the various ELF target machines */ | ||
5 | #define EM_NONE 0 | ||
6 | #define EM_M32 1 | ||
7 | #define EM_SPARC 2 | ||
8 | #define EM_386 3 | ||
9 | #define EM_68K 4 | ||
10 | #define EM_88K 5 | ||
11 | #define EM_486 6 /* Perhaps disused */ | ||
12 | #define EM_860 7 | ||
13 | #define EM_MIPS 8 /* MIPS R3000 (officially, big-endian only) */ | ||
14 | #define EM_MIPS_RS4_BE 10 /* MIPS R4000 big-endian */ | ||
15 | #define EM_PARISC 15 /* HPPA */ | ||
16 | #define EM_SPARC32PLUS 18 /* Sun's "v8plus" */ | ||
17 | #define EM_PPC 20 /* PowerPC */ | ||
18 | #define EM_PPC64 21 /* PowerPC64 */ | ||
19 | #define EM_SH 42 /* SuperH */ | ||
20 | #define EM_SPARCV9 43 /* SPARC v9 64-bit */ | ||
21 | #define EM_IA_64 50 /* HP/Intel IA-64 */ | ||
22 | #define EM_X86_64 62 /* AMD x86-64 */ | ||
23 | #define EM_S390 22 /* IBM S/390 */ | ||
24 | #define EM_CRIS 76 /* Axis Communications 32-bit embedded processor */ | ||
25 | #define EM_V850 87 /* NEC v850 */ | ||
26 | #define EM_M32R 88 /* Renesas M32R */ | ||
27 | #define EM_H8_300 46 /* Renesas H8/300,300H,H8S */ | ||
28 | #define EM_FRV 0x5441 /* Fujitsu FR-V */ | ||
29 | |||
30 | /* | ||
31 | * This is an interim value that we will use until the committee comes | ||
32 | * up with a final number. | ||
33 | */ | ||
34 | #define EM_ALPHA 0x9026 | ||
35 | |||
36 | /* Bogus old v850 magic number, used by old tools. */ | ||
37 | #define EM_CYGNUS_V850 0x9080 | ||
38 | /* Bogus old m32r magic number, used by old tools. */ | ||
39 | #define EM_CYGNUS_M32R 0x9041 | ||
40 | /* This is the old interim value for S/390 architecture */ | ||
41 | #define EM_S390_OLD 0xA390 | ||
42 | |||
43 | |||
44 | #endif /* _LINUX_ELF_EM_H */ | ||
diff --git a/include/linux/elf.h b/include/linux/elf.h index d3bfacb24496..b70d1d2c8d28 100644 --- a/include/linux/elf.h +++ b/include/linux/elf.h | |||
@@ -3,6 +3,7 @@ | |||
3 | 3 | ||
4 | #include <linux/types.h> | 4 | #include <linux/types.h> |
5 | #include <linux/auxvec.h> | 5 | #include <linux/auxvec.h> |
6 | #include <linux/elf-em.h> | ||
6 | #include <asm/elf.h> | 7 | #include <asm/elf.h> |
7 | 8 | ||
8 | #ifndef elf_read_implies_exec | 9 | #ifndef elf_read_implies_exec |
@@ -55,64 +56,6 @@ typedef __s64 Elf64_Sxword; | |||
55 | #define ET_LOPROC 0xff00 | 56 | #define ET_LOPROC 0xff00 |
56 | #define ET_HIPROC 0xffff | 57 | #define ET_HIPROC 0xffff |
57 | 58 | ||
58 | /* These constants define the various ELF target machines */ | ||
59 | #define EM_NONE 0 | ||
60 | #define EM_M32 1 | ||
61 | #define EM_SPARC 2 | ||
62 | #define EM_386 3 | ||
63 | #define EM_68K 4 | ||
64 | #define EM_88K 5 | ||
65 | #define EM_486 6 /* Perhaps disused */ | ||
66 | #define EM_860 7 | ||
67 | |||
68 | #define EM_MIPS 8 /* MIPS R3000 (officially, big-endian only) */ | ||
69 | |||
70 | #define EM_MIPS_RS4_BE 10 /* MIPS R4000 big-endian */ | ||
71 | |||
72 | #define EM_PARISC 15 /* HPPA */ | ||
73 | |||
74 | #define EM_SPARC32PLUS 18 /* Sun's "v8plus" */ | ||
75 | |||
76 | #define EM_PPC 20 /* PowerPC */ | ||
77 | #define EM_PPC64 21 /* PowerPC64 */ | ||
78 | |||
79 | #define EM_SH 42 /* SuperH */ | ||
80 | |||
81 | #define EM_SPARCV9 43 /* SPARC v9 64-bit */ | ||
82 | |||
83 | #define EM_IA_64 50 /* HP/Intel IA-64 */ | ||
84 | |||
85 | #define EM_X86_64 62 /* AMD x86-64 */ | ||
86 | |||
87 | #define EM_S390 22 /* IBM S/390 */ | ||
88 | |||
89 | #define EM_CRIS 76 /* Axis Communications 32-bit embedded processor */ | ||
90 | |||
91 | #define EM_V850 87 /* NEC v850 */ | ||
92 | |||
93 | #define EM_M32R 88 /* Renesas M32R */ | ||
94 | |||
95 | #define EM_H8_300 46 /* Renesas H8/300,300H,H8S */ | ||
96 | |||
97 | /* | ||
98 | * This is an interim value that we will use until the committee comes | ||
99 | * up with a final number. | ||
100 | */ | ||
101 | #define EM_ALPHA 0x9026 | ||
102 | |||
103 | /* Bogus old v850 magic number, used by old tools. */ | ||
104 | #define EM_CYGNUS_V850 0x9080 | ||
105 | |||
106 | /* Bogus old m32r magic number, used by old tools. */ | ||
107 | #define EM_CYGNUS_M32R 0x9041 | ||
108 | |||
109 | /* | ||
110 | * This is the old interim value for S/390 architecture | ||
111 | */ | ||
112 | #define EM_S390_OLD 0xA390 | ||
113 | |||
114 | #define EM_FRV 0x5441 /* Fujitsu FR-V */ | ||
115 | |||
116 | /* This is the info that is needed to parse the dynamic section of the file */ | 59 | /* This is the info that is needed to parse the dynamic section of the file */ |
117 | #define DT_NULL 0 | 60 | #define DT_NULL 0 |
118 | #define DT_NEEDED 1 | 61 | #define DT_NEEDED 1 |
diff --git a/include/linux/errqueue.h b/include/linux/errqueue.h index 174582fedb8b..408118a07763 100644 --- a/include/linux/errqueue.h +++ b/include/linux/errqueue.h | |||
@@ -21,7 +21,6 @@ struct sock_extended_err | |||
21 | 21 | ||
22 | #ifdef __KERNEL__ | 22 | #ifdef __KERNEL__ |
23 | 23 | ||
24 | #include <linux/config.h> | ||
25 | #include <net/ip.h> | 24 | #include <net/ip.h> |
26 | #if defined(CONFIG_IPV6) || defined (CONFIG_IPV6_MODULE) | 25 | #if defined(CONFIG_IPV6) || defined (CONFIG_IPV6_MODULE) |
27 | #include <linux/ipv6.h> | 26 | #include <linux/ipv6.h> |
diff --git a/include/linux/ethtool.h b/include/linux/ethtool.h index 93535f093216..cf2abeca92a0 100644 --- a/include/linux/ethtool.h +++ b/include/linux/ethtool.h | |||
@@ -15,24 +15,24 @@ | |||
15 | 15 | ||
16 | /* This should work for both 32 and 64 bit userland. */ | 16 | /* This should work for both 32 and 64 bit userland. */ |
17 | struct ethtool_cmd { | 17 | struct ethtool_cmd { |
18 | u32 cmd; | 18 | __u32 cmd; |
19 | u32 supported; /* Features this interface supports */ | 19 | __u32 supported; /* Features this interface supports */ |
20 | u32 advertising; /* Features this interface advertises */ | 20 | __u32 advertising; /* Features this interface advertises */ |
21 | u16 speed; /* The forced speed, 10Mb, 100Mb, gigabit */ | 21 | __u16 speed; /* The forced speed, 10Mb, 100Mb, gigabit */ |
22 | u8 duplex; /* Duplex, half or full */ | 22 | __u8 duplex; /* Duplex, half or full */ |
23 | u8 port; /* Which connector port */ | 23 | __u8 port; /* Which connector port */ |
24 | u8 phy_address; | 24 | __u8 phy_address; |
25 | u8 transceiver; /* Which transceiver to use */ | 25 | __u8 transceiver; /* Which transceiver to use */ |
26 | u8 autoneg; /* Enable or disable autonegotiation */ | 26 | __u8 autoneg; /* Enable or disable autonegotiation */ |
27 | u32 maxtxpkt; /* Tx pkts before generating tx int */ | 27 | __u32 maxtxpkt; /* Tx pkts before generating tx int */ |
28 | u32 maxrxpkt; /* Rx pkts before generating rx int */ | 28 | __u32 maxrxpkt; /* Rx pkts before generating rx int */ |
29 | u32 reserved[4]; | 29 | __u32 reserved[4]; |
30 | }; | 30 | }; |
31 | 31 | ||
32 | #define ETHTOOL_BUSINFO_LEN 32 | 32 | #define ETHTOOL_BUSINFO_LEN 32 |
33 | /* these strings are set to whatever the driver author decides... */ | 33 | /* these strings are set to whatever the driver author decides... */ |
34 | struct ethtool_drvinfo { | 34 | struct ethtool_drvinfo { |
35 | u32 cmd; | 35 | __u32 cmd; |
36 | char driver[32]; /* driver short name, "tulip", "eepro100" */ | 36 | char driver[32]; /* driver short name, "tulip", "eepro100" */ |
37 | char version[32]; /* driver version string */ | 37 | char version[32]; /* driver version string */ |
38 | char fw_version[32]; /* firmware version string, if applicable */ | 38 | char fw_version[32]; /* firmware version string, if applicable */ |
@@ -40,53 +40,53 @@ struct ethtool_drvinfo { | |||
40 | /* For PCI devices, use pci_name(pci_dev). */ | 40 | /* For PCI devices, use pci_name(pci_dev). */ |
41 | char reserved1[32]; | 41 | char reserved1[32]; |
42 | char reserved2[16]; | 42 | char reserved2[16]; |
43 | u32 n_stats; /* number of u64's from ETHTOOL_GSTATS */ | 43 | __u32 n_stats; /* number of u64's from ETHTOOL_GSTATS */ |
44 | u32 testinfo_len; | 44 | __u32 testinfo_len; |
45 | u32 eedump_len; /* Size of data from ETHTOOL_GEEPROM (bytes) */ | 45 | __u32 eedump_len; /* Size of data from ETHTOOL_GEEPROM (bytes) */ |
46 | u32 regdump_len; /* Size of data from ETHTOOL_GREGS (bytes) */ | 46 | __u32 regdump_len; /* Size of data from ETHTOOL_GREGS (bytes) */ |
47 | }; | 47 | }; |
48 | 48 | ||
49 | #define SOPASS_MAX 6 | 49 | #define SOPASS_MAX 6 |
50 | /* wake-on-lan settings */ | 50 | /* wake-on-lan settings */ |
51 | struct ethtool_wolinfo { | 51 | struct ethtool_wolinfo { |
52 | u32 cmd; | 52 | __u32 cmd; |
53 | u32 supported; | 53 | __u32 supported; |
54 | u32 wolopts; | 54 | __u32 wolopts; |
55 | u8 sopass[SOPASS_MAX]; /* SecureOn(tm) password */ | 55 | __u8 sopass[SOPASS_MAX]; /* SecureOn(tm) password */ |
56 | }; | 56 | }; |
57 | 57 | ||
58 | /* for passing single values */ | 58 | /* for passing single values */ |
59 | struct ethtool_value { | 59 | struct ethtool_value { |
60 | u32 cmd; | 60 | __u32 cmd; |
61 | u32 data; | 61 | __u32 data; |
62 | }; | 62 | }; |
63 | 63 | ||
64 | /* for passing big chunks of data */ | 64 | /* for passing big chunks of data */ |
65 | struct ethtool_regs { | 65 | struct ethtool_regs { |
66 | u32 cmd; | 66 | __u32 cmd; |
67 | u32 version; /* driver-specific, indicates different chips/revs */ | 67 | __u32 version; /* driver-specific, indicates different chips/revs */ |
68 | u32 len; /* bytes */ | 68 | __u32 len; /* bytes */ |
69 | u8 data[0]; | 69 | __u8 data[0]; |
70 | }; | 70 | }; |
71 | 71 | ||
72 | /* for passing EEPROM chunks */ | 72 | /* for passing EEPROM chunks */ |
73 | struct ethtool_eeprom { | 73 | struct ethtool_eeprom { |
74 | u32 cmd; | 74 | __u32 cmd; |
75 | u32 magic; | 75 | __u32 magic; |
76 | u32 offset; /* in bytes */ | 76 | __u32 offset; /* in bytes */ |
77 | u32 len; /* in bytes */ | 77 | __u32 len; /* in bytes */ |
78 | u8 data[0]; | 78 | __u8 data[0]; |
79 | }; | 79 | }; |
80 | 80 | ||
81 | /* for configuring coalescing parameters of chip */ | 81 | /* for configuring coalescing parameters of chip */ |
82 | struct ethtool_coalesce { | 82 | struct ethtool_coalesce { |
83 | u32 cmd; /* ETHTOOL_{G,S}COALESCE */ | 83 | __u32 cmd; /* ETHTOOL_{G,S}COALESCE */ |
84 | 84 | ||
85 | /* How many usecs to delay an RX interrupt after | 85 | /* How many usecs to delay an RX interrupt after |
86 | * a packet arrives. If 0, only rx_max_coalesced_frames | 86 | * a packet arrives. If 0, only rx_max_coalesced_frames |
87 | * is used. | 87 | * is used. |
88 | */ | 88 | */ |
89 | u32 rx_coalesce_usecs; | 89 | __u32 rx_coalesce_usecs; |
90 | 90 | ||
91 | /* How many packets to delay an RX interrupt after | 91 | /* How many packets to delay an RX interrupt after |
92 | * a packet arrives. If 0, only rx_coalesce_usecs is | 92 | * a packet arrives. If 0, only rx_coalesce_usecs is |
@@ -94,21 +94,21 @@ struct ethtool_coalesce { | |||
94 | * to zero as this would cause RX interrupts to never be | 94 | * to zero as this would cause RX interrupts to never be |
95 | * generated. | 95 | * generated. |
96 | */ | 96 | */ |
97 | u32 rx_max_coalesced_frames; | 97 | __u32 rx_max_coalesced_frames; |
98 | 98 | ||
99 | /* Same as above two parameters, except that these values | 99 | /* Same as above two parameters, except that these values |
100 | * apply while an IRQ is being serviced by the host. Not | 100 | * apply while an IRQ is being serviced by the host. Not |
101 | * all cards support this feature and the values are ignored | 101 | * all cards support this feature and the values are ignored |
102 | * in that case. | 102 | * in that case. |
103 | */ | 103 | */ |
104 | u32 rx_coalesce_usecs_irq; | 104 | __u32 rx_coalesce_usecs_irq; |
105 | u32 rx_max_coalesced_frames_irq; | 105 | __u32 rx_max_coalesced_frames_irq; |
106 | 106 | ||
107 | /* How many usecs to delay a TX interrupt after | 107 | /* How many usecs to delay a TX interrupt after |
108 | * a packet is sent. If 0, only tx_max_coalesced_frames | 108 | * a packet is sent. If 0, only tx_max_coalesced_frames |
109 | * is used. | 109 | * is used. |
110 | */ | 110 | */ |
111 | u32 tx_coalesce_usecs; | 111 | __u32 tx_coalesce_usecs; |
112 | 112 | ||
113 | /* How many packets to delay a TX interrupt after | 113 | /* How many packets to delay a TX interrupt after |
114 | * a packet is sent. If 0, only tx_coalesce_usecs is | 114 | * a packet is sent. If 0, only tx_coalesce_usecs is |
@@ -116,22 +116,22 @@ struct ethtool_coalesce { | |||
116 | * to zero as this would cause TX interrupts to never be | 116 | * to zero as this would cause TX interrupts to never be |
117 | * generated. | 117 | * generated. |
118 | */ | 118 | */ |
119 | u32 tx_max_coalesced_frames; | 119 | __u32 tx_max_coalesced_frames; |
120 | 120 | ||
121 | /* Same as above two parameters, except that these values | 121 | /* Same as above two parameters, except that these values |
122 | * apply while an IRQ is being serviced by the host. Not | 122 | * apply while an IRQ is being serviced by the host. Not |
123 | * all cards support this feature and the values are ignored | 123 | * all cards support this feature and the values are ignored |
124 | * in that case. | 124 | * in that case. |
125 | */ | 125 | */ |
126 | u32 tx_coalesce_usecs_irq; | 126 | __u32 tx_coalesce_usecs_irq; |
127 | u32 tx_max_coalesced_frames_irq; | 127 | __u32 tx_max_coalesced_frames_irq; |
128 | 128 | ||
129 | /* How many usecs to delay in-memory statistics | 129 | /* How many usecs to delay in-memory statistics |
130 | * block updates. Some drivers do not have an in-memory | 130 | * block updates. Some drivers do not have an in-memory |
131 | * statistic block, and in such cases this value is ignored. | 131 | * statistic block, and in such cases this value is ignored. |
132 | * This value must not be zero. | 132 | * This value must not be zero. |
133 | */ | 133 | */ |
134 | u32 stats_block_coalesce_usecs; | 134 | __u32 stats_block_coalesce_usecs; |
135 | 135 | ||
136 | /* Adaptive RX/TX coalescing is an algorithm implemented by | 136 | /* Adaptive RX/TX coalescing is an algorithm implemented by |
137 | * some drivers to improve latency under low packet rates and | 137 | * some drivers to improve latency under low packet rates and |
@@ -140,18 +140,18 @@ struct ethtool_coalesce { | |||
140 | * not implemented by the driver causes these values to be | 140 | * not implemented by the driver causes these values to be |
141 | * silently ignored. | 141 | * silently ignored. |
142 | */ | 142 | */ |
143 | u32 use_adaptive_rx_coalesce; | 143 | __u32 use_adaptive_rx_coalesce; |
144 | u32 use_adaptive_tx_coalesce; | 144 | __u32 use_adaptive_tx_coalesce; |
145 | 145 | ||
146 | /* When the packet rate (measured in packets per second) | 146 | /* When the packet rate (measured in packets per second) |
147 | * is below pkt_rate_low, the {rx,tx}_*_low parameters are | 147 | * is below pkt_rate_low, the {rx,tx}_*_low parameters are |
148 | * used. | 148 | * used. |
149 | */ | 149 | */ |
150 | u32 pkt_rate_low; | 150 | __u32 pkt_rate_low; |
151 | u32 rx_coalesce_usecs_low; | 151 | __u32 rx_coalesce_usecs_low; |
152 | u32 rx_max_coalesced_frames_low; | 152 | __u32 rx_max_coalesced_frames_low; |
153 | u32 tx_coalesce_usecs_low; | 153 | __u32 tx_coalesce_usecs_low; |
154 | u32 tx_max_coalesced_frames_low; | 154 | __u32 tx_max_coalesced_frames_low; |
155 | 155 | ||
156 | /* When the packet rate is below pkt_rate_high but above | 156 | /* When the packet rate is below pkt_rate_high but above |
157 | * pkt_rate_low (both measured in packets per second) the | 157 | * pkt_rate_low (both measured in packets per second) the |
@@ -162,43 +162,43 @@ struct ethtool_coalesce { | |||
162 | * is above pkt_rate_high, the {rx,tx}_*_high parameters are | 162 | * is above pkt_rate_high, the {rx,tx}_*_high parameters are |
163 | * used. | 163 | * used. |
164 | */ | 164 | */ |
165 | u32 pkt_rate_high; | 165 | __u32 pkt_rate_high; |
166 | u32 rx_coalesce_usecs_high; | 166 | __u32 rx_coalesce_usecs_high; |
167 | u32 rx_max_coalesced_frames_high; | 167 | __u32 rx_max_coalesced_frames_high; |
168 | u32 tx_coalesce_usecs_high; | 168 | __u32 tx_coalesce_usecs_high; |
169 | u32 tx_max_coalesced_frames_high; | 169 | __u32 tx_max_coalesced_frames_high; |
170 | 170 | ||
171 | /* How often to do adaptive coalescing packet rate sampling, | 171 | /* How often to do adaptive coalescing packet rate sampling, |
172 | * measured in seconds. Must not be zero. | 172 | * measured in seconds. Must not be zero. |
173 | */ | 173 | */ |
174 | u32 rate_sample_interval; | 174 | __u32 rate_sample_interval; |
175 | }; | 175 | }; |
176 | 176 | ||
177 | /* for configuring RX/TX ring parameters */ | 177 | /* for configuring RX/TX ring parameters */ |
178 | struct ethtool_ringparam { | 178 | struct ethtool_ringparam { |
179 | u32 cmd; /* ETHTOOL_{G,S}RINGPARAM */ | 179 | __u32 cmd; /* ETHTOOL_{G,S}RINGPARAM */ |
180 | 180 | ||
181 | /* Read only attributes. These indicate the maximum number | 181 | /* Read only attributes. These indicate the maximum number |
182 | * of pending RX/TX ring entries the driver will allow the | 182 | * of pending RX/TX ring entries the driver will allow the |
183 | * user to set. | 183 | * user to set. |
184 | */ | 184 | */ |
185 | u32 rx_max_pending; | 185 | __u32 rx_max_pending; |
186 | u32 rx_mini_max_pending; | 186 | __u32 rx_mini_max_pending; |
187 | u32 rx_jumbo_max_pending; | 187 | __u32 rx_jumbo_max_pending; |
188 | u32 tx_max_pending; | 188 | __u32 tx_max_pending; |
189 | 189 | ||
190 | /* Values changeable by the user. The valid values are | 190 | /* Values changeable by the user. The valid values are |
191 | * in the range 1 to the "*_max_pending" counterpart above. | 191 | * in the range 1 to the "*_max_pending" counterpart above. |
192 | */ | 192 | */ |
193 | u32 rx_pending; | 193 | __u32 rx_pending; |
194 | u32 rx_mini_pending; | 194 | __u32 rx_mini_pending; |
195 | u32 rx_jumbo_pending; | 195 | __u32 rx_jumbo_pending; |
196 | u32 tx_pending; | 196 | __u32 tx_pending; |
197 | }; | 197 | }; |
198 | 198 | ||
199 | /* for configuring link flow control parameters */ | 199 | /* for configuring link flow control parameters */ |
200 | struct ethtool_pauseparam { | 200 | struct ethtool_pauseparam { |
201 | u32 cmd; /* ETHTOOL_{G,S}PAUSEPARAM */ | 201 | __u32 cmd; /* ETHTOOL_{G,S}PAUSEPARAM */ |
202 | 202 | ||
203 | /* If the link is being auto-negotiated (via ethtool_cmd.autoneg | 203 | /* If the link is being auto-negotiated (via ethtool_cmd.autoneg |
204 | * being true) the user may set 'autonet' here non-zero to have the | 204 | * being true) the user may set 'autonet' here non-zero to have the |
@@ -210,9 +210,9 @@ struct ethtool_pauseparam { | |||
210 | * then {rx,tx}_pause force the driver to use/not-use pause | 210 | * then {rx,tx}_pause force the driver to use/not-use pause |
211 | * flow control. | 211 | * flow control. |
212 | */ | 212 | */ |
213 | u32 autoneg; | 213 | __u32 autoneg; |
214 | u32 rx_pause; | 214 | __u32 rx_pause; |
215 | u32 tx_pause; | 215 | __u32 tx_pause; |
216 | }; | 216 | }; |
217 | 217 | ||
218 | #define ETH_GSTRING_LEN 32 | 218 | #define ETH_GSTRING_LEN 32 |
@@ -223,10 +223,10 @@ enum ethtool_stringset { | |||
223 | 223 | ||
224 | /* for passing string sets for data tagging */ | 224 | /* for passing string sets for data tagging */ |
225 | struct ethtool_gstrings { | 225 | struct ethtool_gstrings { |
226 | u32 cmd; /* ETHTOOL_GSTRINGS */ | 226 | __u32 cmd; /* ETHTOOL_GSTRINGS */ |
227 | u32 string_set; /* string set id e.c. ETH_SS_TEST, etc*/ | 227 | __u32 string_set; /* string set id e.c. ETH_SS_TEST, etc*/ |
228 | u32 len; /* number of strings in the string set */ | 228 | __u32 len; /* number of strings in the string set */ |
229 | u8 data[0]; | 229 | __u8 data[0]; |
230 | }; | 230 | }; |
231 | 231 | ||
232 | enum ethtool_test_flags { | 232 | enum ethtool_test_flags { |
@@ -236,26 +236,28 @@ enum ethtool_test_flags { | |||
236 | 236 | ||
237 | /* for requesting NIC test and getting results*/ | 237 | /* for requesting NIC test and getting results*/ |
238 | struct ethtool_test { | 238 | struct ethtool_test { |
239 | u32 cmd; /* ETHTOOL_TEST */ | 239 | __u32 cmd; /* ETHTOOL_TEST */ |
240 | u32 flags; /* ETH_TEST_FL_xxx */ | 240 | __u32 flags; /* ETH_TEST_FL_xxx */ |
241 | u32 reserved; | 241 | __u32 reserved; |
242 | u32 len; /* result length, in number of u64 elements */ | 242 | __u32 len; /* result length, in number of u64 elements */ |
243 | u64 data[0]; | 243 | __u64 data[0]; |
244 | }; | 244 | }; |
245 | 245 | ||
246 | /* for dumping NIC-specific statistics */ | 246 | /* for dumping NIC-specific statistics */ |
247 | struct ethtool_stats { | 247 | struct ethtool_stats { |
248 | u32 cmd; /* ETHTOOL_GSTATS */ | 248 | __u32 cmd; /* ETHTOOL_GSTATS */ |
249 | u32 n_stats; /* number of u64's being returned */ | 249 | __u32 n_stats; /* number of u64's being returned */ |
250 | u64 data[0]; | 250 | __u64 data[0]; |
251 | }; | 251 | }; |
252 | 252 | ||
253 | struct ethtool_perm_addr { | 253 | struct ethtool_perm_addr { |
254 | u32 cmd; /* ETHTOOL_GPERMADDR */ | 254 | __u32 cmd; /* ETHTOOL_GPERMADDR */ |
255 | u32 size; | 255 | __u32 size; |
256 | u8 data[0]; | 256 | __u8 data[0]; |
257 | }; | 257 | }; |
258 | 258 | ||
259 | #ifdef __KERNEL__ | ||
260 | |||
259 | struct net_device; | 261 | struct net_device; |
260 | 262 | ||
261 | /* Some generic methods drivers may use in their ethtool_ops */ | 263 | /* Some generic methods drivers may use in their ethtool_ops */ |
@@ -371,6 +373,7 @@ struct ethtool_ops { | |||
371 | u32 (*get_ufo)(struct net_device *); | 373 | u32 (*get_ufo)(struct net_device *); |
372 | int (*set_ufo)(struct net_device *, u32); | 374 | int (*set_ufo)(struct net_device *, u32); |
373 | }; | 375 | }; |
376 | #endif /* __KERNEL__ */ | ||
374 | 377 | ||
375 | /* CMDs currently supported */ | 378 | /* CMDs currently supported */ |
376 | #define ETHTOOL_GSET 0x00000001 /* Get settings. */ | 379 | #define ETHTOOL_GSET 0x00000001 /* Get settings. */ |
diff --git a/include/linux/ext2_fs.h b/include/linux/ext2_fs.h index f7bd1c7ebefb..facf34e98954 100644 --- a/include/linux/ext2_fs.h +++ b/include/linux/ext2_fs.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #define _LINUX_EXT2_FS_H | 17 | #define _LINUX_EXT2_FS_H |
18 | 18 | ||
19 | #include <linux/types.h> | 19 | #include <linux/types.h> |
20 | #include <linux/ext2_fs_sb.h> | ||
21 | 20 | ||
22 | /* | 21 | /* |
23 | * The second extended filesystem constants/structures | 22 | * The second extended filesystem constants/structures |
@@ -70,6 +69,7 @@ | |||
70 | #define EXT2_SUPER_MAGIC 0xEF53 | 69 | #define EXT2_SUPER_MAGIC 0xEF53 |
71 | 70 | ||
72 | #ifdef __KERNEL__ | 71 | #ifdef __KERNEL__ |
72 | #include <linux/ext2_fs_sb.h> | ||
73 | static inline struct ext2_sb_info *EXT2_SB(struct super_block *sb) | 73 | static inline struct ext2_sb_info *EXT2_SB(struct super_block *sb) |
74 | { | 74 | { |
75 | return sb->s_fs_info; | 75 | return sb->s_fs_info; |
diff --git a/include/linux/ext3_fs.h b/include/linux/ext3_fs.h index 3ade6a4e3bdd..757d54d8f1a5 100644 --- a/include/linux/ext3_fs.h +++ b/include/linux/ext3_fs.h | |||
@@ -17,11 +17,6 @@ | |||
17 | #define _LINUX_EXT3_FS_H | 17 | #define _LINUX_EXT3_FS_H |
18 | 18 | ||
19 | #include <linux/types.h> | 19 | #include <linux/types.h> |
20 | #include <linux/ext3_fs_i.h> | ||
21 | #include <linux/ext3_fs_sb.h> | ||
22 | |||
23 | |||
24 | struct statfs; | ||
25 | 20 | ||
26 | /* | 21 | /* |
27 | * The second extended filesystem constants/structures | 22 | * The second extended filesystem constants/structures |
@@ -487,6 +482,8 @@ struct ext3_super_block { | |||
487 | }; | 482 | }; |
488 | 483 | ||
489 | #ifdef __KERNEL__ | 484 | #ifdef __KERNEL__ |
485 | #include <linux/ext3_fs_i.h> | ||
486 | #include <linux/ext3_fs_sb.h> | ||
490 | static inline struct ext3_sb_info * EXT3_SB(struct super_block *sb) | 487 | static inline struct ext3_sb_info * EXT3_SB(struct super_block *sb) |
491 | { | 488 | { |
492 | return sb->s_fs_info; | 489 | return sb->s_fs_info; |
@@ -664,6 +661,8 @@ struct ext3_dir_entry_2 { | |||
664 | #define DX_HASH_HALF_MD4 1 | 661 | #define DX_HASH_HALF_MD4 1 |
665 | #define DX_HASH_TEA 2 | 662 | #define DX_HASH_TEA 2 |
666 | 663 | ||
664 | #ifdef __KERNEL__ | ||
665 | |||
667 | /* hash info structure used by the directory hash */ | 666 | /* hash info structure used by the directory hash */ |
668 | struct dx_hash_info | 667 | struct dx_hash_info |
669 | { | 668 | { |
@@ -675,7 +674,6 @@ struct dx_hash_info | |||
675 | 674 | ||
676 | #define EXT3_HTREE_EOF 0x7fffffff | 675 | #define EXT3_HTREE_EOF 0x7fffffff |
677 | 676 | ||
678 | #ifdef __KERNEL__ | ||
679 | /* | 677 | /* |
680 | * Control parameters used by ext3_htree_next_block | 678 | * Control parameters used by ext3_htree_next_block |
681 | */ | 679 | */ |
diff --git a/include/linux/fs.h b/include/linux/fs.h index f813bc8266aa..73c7d6f04b31 100644 --- a/include/linux/fs.h +++ b/include/linux/fs.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * structures etc. | 6 | * structures etc. |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <linux/limits.h> | 9 | #include <linux/limits.h> |
11 | #include <linux/ioctl.h> | 10 | #include <linux/ioctl.h> |
12 | 11 | ||
@@ -783,7 +782,6 @@ extern int setlease(struct file *, long, struct file_lock **); | |||
783 | extern int lease_modify(struct file_lock **, int); | 782 | extern int lease_modify(struct file_lock **, int); |
784 | extern int lock_may_read(struct inode *, loff_t start, unsigned long count); | 783 | extern int lock_may_read(struct inode *, loff_t start, unsigned long count); |
785 | extern int lock_may_write(struct inode *, loff_t start, unsigned long count); | 784 | extern int lock_may_write(struct inode *, loff_t start, unsigned long count); |
786 | extern void steal_locks(fl_owner_t from); | ||
787 | 785 | ||
788 | struct fasync_struct { | 786 | struct fasync_struct { |
789 | int magic; | 787 | int magic; |
diff --git a/include/linux/fsnotify.h b/include/linux/fsnotify.h index 11438eff4d44..cc5dec70c32c 100644 --- a/include/linux/fsnotify.h +++ b/include/linux/fsnotify.h | |||
@@ -54,19 +54,20 @@ static inline void fsnotify_move(struct inode *old_dir, struct inode *new_dir, | |||
54 | 54 | ||
55 | if (isdir) | 55 | if (isdir) |
56 | isdir = IN_ISDIR; | 56 | isdir = IN_ISDIR; |
57 | inotify_inode_queue_event(old_dir, IN_MOVED_FROM|isdir,cookie,old_name); | 57 | inotify_inode_queue_event(old_dir, IN_MOVED_FROM|isdir,cookie,old_name, |
58 | inotify_inode_queue_event(new_dir, IN_MOVED_TO|isdir, cookie, new_name); | 58 | source); |
59 | inotify_inode_queue_event(new_dir, IN_MOVED_TO|isdir, cookie, new_name, | ||
60 | source); | ||
59 | 61 | ||
60 | if (target) { | 62 | if (target) { |
61 | inotify_inode_queue_event(target, IN_DELETE_SELF, 0, NULL); | 63 | inotify_inode_queue_event(target, IN_DELETE_SELF, 0, NULL, NULL); |
62 | inotify_inode_is_dead(target); | 64 | inotify_inode_is_dead(target); |
63 | } | 65 | } |
64 | 66 | ||
65 | if (source) { | 67 | if (source) { |
66 | inotify_inode_queue_event(source, IN_MOVE_SELF, 0, NULL); | 68 | inotify_inode_queue_event(source, IN_MOVE_SELF, 0, NULL, NULL); |
67 | } | 69 | } |
68 | audit_inode_child(old_name, source, old_dir->i_ino); | 70 | audit_inode_child(new_name, source, new_dir->i_ino); |
69 | audit_inode_child(new_name, target, new_dir->i_ino); | ||
70 | } | 71 | } |
71 | 72 | ||
72 | /* | 73 | /* |
@@ -85,7 +86,7 @@ static inline void fsnotify_nameremove(struct dentry *dentry, int isdir) | |||
85 | */ | 86 | */ |
86 | static inline void fsnotify_inoderemove(struct inode *inode) | 87 | static inline void fsnotify_inoderemove(struct inode *inode) |
87 | { | 88 | { |
88 | inotify_inode_queue_event(inode, IN_DELETE_SELF, 0, NULL); | 89 | inotify_inode_queue_event(inode, IN_DELETE_SELF, 0, NULL, NULL); |
89 | inotify_inode_is_dead(inode); | 90 | inotify_inode_is_dead(inode); |
90 | } | 91 | } |
91 | 92 | ||
@@ -95,7 +96,8 @@ static inline void fsnotify_inoderemove(struct inode *inode) | |||
95 | static inline void fsnotify_create(struct inode *inode, struct dentry *dentry) | 96 | static inline void fsnotify_create(struct inode *inode, struct dentry *dentry) |
96 | { | 97 | { |
97 | inode_dir_notify(inode, DN_CREATE); | 98 | inode_dir_notify(inode, DN_CREATE); |
98 | inotify_inode_queue_event(inode, IN_CREATE, 0, dentry->d_name.name); | 99 | inotify_inode_queue_event(inode, IN_CREATE, 0, dentry->d_name.name, |
100 | dentry->d_inode); | ||
99 | audit_inode_child(dentry->d_name.name, dentry->d_inode, inode->i_ino); | 101 | audit_inode_child(dentry->d_name.name, dentry->d_inode, inode->i_ino); |
100 | } | 102 | } |
101 | 103 | ||
@@ -106,7 +108,7 @@ static inline void fsnotify_mkdir(struct inode *inode, struct dentry *dentry) | |||
106 | { | 108 | { |
107 | inode_dir_notify(inode, DN_CREATE); | 109 | inode_dir_notify(inode, DN_CREATE); |
108 | inotify_inode_queue_event(inode, IN_CREATE | IN_ISDIR, 0, | 110 | inotify_inode_queue_event(inode, IN_CREATE | IN_ISDIR, 0, |
109 | dentry->d_name.name); | 111 | dentry->d_name.name, dentry->d_inode); |
110 | audit_inode_child(dentry->d_name.name, dentry->d_inode, inode->i_ino); | 112 | audit_inode_child(dentry->d_name.name, dentry->d_inode, inode->i_ino); |
111 | } | 113 | } |
112 | 114 | ||
@@ -123,7 +125,7 @@ static inline void fsnotify_access(struct dentry *dentry) | |||
123 | 125 | ||
124 | dnotify_parent(dentry, DN_ACCESS); | 126 | dnotify_parent(dentry, DN_ACCESS); |
125 | inotify_dentry_parent_queue_event(dentry, mask, 0, dentry->d_name.name); | 127 | inotify_dentry_parent_queue_event(dentry, mask, 0, dentry->d_name.name); |
126 | inotify_inode_queue_event(inode, mask, 0, NULL); | 128 | inotify_inode_queue_event(inode, mask, 0, NULL, NULL); |
127 | } | 129 | } |
128 | 130 | ||
129 | /* | 131 | /* |
@@ -139,7 +141,7 @@ static inline void fsnotify_modify(struct dentry *dentry) | |||
139 | 141 | ||
140 | dnotify_parent(dentry, DN_MODIFY); | 142 | dnotify_parent(dentry, DN_MODIFY); |
141 | inotify_dentry_parent_queue_event(dentry, mask, 0, dentry->d_name.name); | 143 | inotify_dentry_parent_queue_event(dentry, mask, 0, dentry->d_name.name); |
142 | inotify_inode_queue_event(inode, mask, 0, NULL); | 144 | inotify_inode_queue_event(inode, mask, 0, NULL, NULL); |
143 | } | 145 | } |
144 | 146 | ||
145 | /* | 147 | /* |
@@ -154,7 +156,7 @@ static inline void fsnotify_open(struct dentry *dentry) | |||
154 | mask |= IN_ISDIR; | 156 | mask |= IN_ISDIR; |
155 | 157 | ||
156 | inotify_dentry_parent_queue_event(dentry, mask, 0, dentry->d_name.name); | 158 | inotify_dentry_parent_queue_event(dentry, mask, 0, dentry->d_name.name); |
157 | inotify_inode_queue_event(inode, mask, 0, NULL); | 159 | inotify_inode_queue_event(inode, mask, 0, NULL, NULL); |
158 | } | 160 | } |
159 | 161 | ||
160 | /* | 162 | /* |
@@ -172,7 +174,7 @@ static inline void fsnotify_close(struct file *file) | |||
172 | mask |= IN_ISDIR; | 174 | mask |= IN_ISDIR; |
173 | 175 | ||
174 | inotify_dentry_parent_queue_event(dentry, mask, 0, name); | 176 | inotify_dentry_parent_queue_event(dentry, mask, 0, name); |
175 | inotify_inode_queue_event(inode, mask, 0, NULL); | 177 | inotify_inode_queue_event(inode, mask, 0, NULL, NULL); |
176 | } | 178 | } |
177 | 179 | ||
178 | /* | 180 | /* |
@@ -187,7 +189,7 @@ static inline void fsnotify_xattr(struct dentry *dentry) | |||
187 | mask |= IN_ISDIR; | 189 | mask |= IN_ISDIR; |
188 | 190 | ||
189 | inotify_dentry_parent_queue_event(dentry, mask, 0, dentry->d_name.name); | 191 | inotify_dentry_parent_queue_event(dentry, mask, 0, dentry->d_name.name); |
190 | inotify_inode_queue_event(inode, mask, 0, NULL); | 192 | inotify_inode_queue_event(inode, mask, 0, NULL, NULL); |
191 | } | 193 | } |
192 | 194 | ||
193 | /* | 195 | /* |
@@ -234,7 +236,7 @@ static inline void fsnotify_change(struct dentry *dentry, unsigned int ia_valid) | |||
234 | if (in_mask) { | 236 | if (in_mask) { |
235 | if (S_ISDIR(inode->i_mode)) | 237 | if (S_ISDIR(inode->i_mode)) |
236 | in_mask |= IN_ISDIR; | 238 | in_mask |= IN_ISDIR; |
237 | inotify_inode_queue_event(inode, in_mask, 0, NULL); | 239 | inotify_inode_queue_event(inode, in_mask, 0, NULL, NULL); |
238 | inotify_dentry_parent_queue_event(dentry, in_mask, 0, | 240 | inotify_dentry_parent_queue_event(dentry, in_mask, 0, |
239 | dentry->d_name.name); | 241 | dentry->d_name.name); |
240 | } | 242 | } |
diff --git a/include/linux/ftape.h b/include/linux/ftape.h index 72faeec9f6e1..7e7038cba86a 100644 --- a/include/linux/ftape.h +++ b/include/linux/ftape.h | |||
@@ -35,7 +35,6 @@ | |||
35 | #include <linux/mm.h> | 35 | #include <linux/mm.h> |
36 | #endif | 36 | #endif |
37 | #include <linux/types.h> | 37 | #include <linux/types.h> |
38 | #include <linux/config.h> | ||
39 | #include <linux/mtio.h> | 38 | #include <linux/mtio.h> |
40 | 39 | ||
41 | #define FT_SECTOR(x) (x+1) /* sector offset into real sector */ | 40 | #define FT_SECTOR(x) (x+1) /* sector offset into real sector */ |
diff --git a/include/linux/gameport.h b/include/linux/gameport.h index 71e7b2847cb3..2cdba0c23957 100644 --- a/include/linux/gameport.h +++ b/include/linux/gameport.h | |||
@@ -9,6 +9,7 @@ | |||
9 | * the Free Software Foundation. | 9 | * the Free Software Foundation. |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #ifdef __KERNEL__ | ||
12 | #include <asm/io.h> | 13 | #include <asm/io.h> |
13 | #include <linux/list.h> | 14 | #include <linux/list.h> |
14 | #include <linux/mutex.h> | 15 | #include <linux/mutex.h> |
@@ -154,6 +155,8 @@ static inline void gameport_register_driver(struct gameport_driver *drv) | |||
154 | 155 | ||
155 | void gameport_unregister_driver(struct gameport_driver *drv); | 156 | void gameport_unregister_driver(struct gameport_driver *drv); |
156 | 157 | ||
158 | #endif /* __KERNEL__ */ | ||
159 | |||
157 | #define GAMEPORT_MODE_DISABLED 0 | 160 | #define GAMEPORT_MODE_DISABLED 0 |
158 | #define GAMEPORT_MODE_RAW 1 | 161 | #define GAMEPORT_MODE_RAW 1 |
159 | #define GAMEPORT_MODE_COOKED 2 | 162 | #define GAMEPORT_MODE_COOKED 2 |
@@ -169,6 +172,8 @@ void gameport_unregister_driver(struct gameport_driver *drv); | |||
169 | #define GAMEPORT_ID_VENDOR_GRAVIS 0x0009 | 172 | #define GAMEPORT_ID_VENDOR_GRAVIS 0x0009 |
170 | #define GAMEPORT_ID_VENDOR_GUILLEMOT 0x000a | 173 | #define GAMEPORT_ID_VENDOR_GUILLEMOT 0x000a |
171 | 174 | ||
175 | #ifdef __KERNEL__ | ||
176 | |||
172 | static inline void gameport_trigger(struct gameport *gameport) | 177 | static inline void gameport_trigger(struct gameport *gameport) |
173 | { | 178 | { |
174 | if (gameport->trigger) | 179 | if (gameport->trigger) |
@@ -219,4 +224,5 @@ static inline void gameport_set_poll_interval(struct gameport *gameport, unsigne | |||
219 | void gameport_start_polling(struct gameport *gameport); | 224 | void gameport_start_polling(struct gameport *gameport); |
220 | void gameport_stop_polling(struct gameport *gameport); | 225 | void gameport_stop_polling(struct gameport *gameport); |
221 | 226 | ||
227 | #endif /* __KERNEL__ */ | ||
222 | #endif | 228 | #endif |
diff --git a/include/linux/generic_serial.h b/include/linux/generic_serial.h index 652611a4bdcd..e25384561955 100644 --- a/include/linux/generic_serial.h +++ b/include/linux/generic_serial.h | |||
@@ -12,6 +12,7 @@ | |||
12 | #ifndef GENERIC_SERIAL_H | 12 | #ifndef GENERIC_SERIAL_H |
13 | #define GENERIC_SERIAL_H | 13 | #define GENERIC_SERIAL_H |
14 | 14 | ||
15 | #ifdef __KERNEL__ | ||
15 | #include <linux/mutex.h> | 16 | #include <linux/mutex.h> |
16 | 17 | ||
17 | struct real_driver { | 18 | struct real_driver { |
@@ -54,6 +55,7 @@ struct gs_port { | |||
54 | spinlock_t driver_lock; | 55 | spinlock_t driver_lock; |
55 | }; | 56 | }; |
56 | 57 | ||
58 | #endif /* __KERNEL__ */ | ||
57 | 59 | ||
58 | /* Flags */ | 60 | /* Flags */ |
59 | /* Warning: serial.h defines some ASYNC_ flags, they say they are "only" | 61 | /* Warning: serial.h defines some ASYNC_ flags, they say they are "only" |
@@ -75,7 +77,7 @@ struct gs_port { | |||
75 | #define GS_DEBUG_FLOW 0x00000020 | 77 | #define GS_DEBUG_FLOW 0x00000020 |
76 | #define GS_DEBUG_WRITE 0x00000040 | 78 | #define GS_DEBUG_WRITE 0x00000040 |
77 | 79 | ||
78 | 80 | #ifdef __KERNEL__ | |
79 | void gs_put_char(struct tty_struct *tty, unsigned char ch); | 81 | void gs_put_char(struct tty_struct *tty, unsigned char ch); |
80 | int gs_write(struct tty_struct *tty, | 82 | int gs_write(struct tty_struct *tty, |
81 | const unsigned char *buf, int count); | 83 | const unsigned char *buf, int count); |
@@ -94,5 +96,5 @@ int gs_init_port(struct gs_port *port); | |||
94 | int gs_setserial(struct gs_port *port, struct serial_struct __user *sp); | 96 | int gs_setserial(struct gs_port *port, struct serial_struct __user *sp); |
95 | int gs_getserial(struct gs_port *port, struct serial_struct __user *sp); | 97 | int gs_getserial(struct gs_port *port, struct serial_struct __user *sp); |
96 | void gs_got_break(struct gs_port *port); | 98 | void gs_got_break(struct gs_port *port); |
97 | 99 | #endif /* __KERNEL__ */ | |
98 | #endif | 100 | #endif |
diff --git a/include/linux/genhd.h b/include/linux/genhd.h index 2ef845b35175..3498a0c68184 100644 --- a/include/linux/genhd.h +++ b/include/linux/genhd.h | |||
@@ -9,13 +9,7 @@ | |||
9 | * <drew@colorado.edu> | 9 | * <drew@colorado.edu> |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/types.h> | 12 | #include <linux/types.h> |
14 | #include <linux/major.h> | ||
15 | #include <linux/device.h> | ||
16 | #include <linux/smp.h> | ||
17 | #include <linux/string.h> | ||
18 | #include <linux/fs.h> | ||
19 | 13 | ||
20 | enum { | 14 | enum { |
21 | /* These three have identical behaviour; use the second one if DOS FDISK gets | 15 | /* These three have identical behaviour; use the second one if DOS FDISK gets |
@@ -61,6 +55,12 @@ struct partition { | |||
61 | #endif | 55 | #endif |
62 | 56 | ||
63 | #ifdef __KERNEL__ | 57 | #ifdef __KERNEL__ |
58 | #include <linux/major.h> | ||
59 | #include <linux/device.h> | ||
60 | #include <linux/smp.h> | ||
61 | #include <linux/string.h> | ||
62 | #include <linux/fs.h> | ||
63 | |||
64 | struct partition { | 64 | struct partition { |
65 | unsigned char boot_ind; /* 0x80 - active */ | 65 | unsigned char boot_ind; /* 0x80 - active */ |
66 | unsigned char head; /* starting head */ | 66 | unsigned char head; /* starting head */ |
diff --git a/include/linux/gfp.h b/include/linux/gfp.h index 3ac452945a7d..cc9e60844484 100644 --- a/include/linux/gfp.h +++ b/include/linux/gfp.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #include <linux/mmzone.h> | 4 | #include <linux/mmzone.h> |
5 | #include <linux/stddef.h> | 5 | #include <linux/stddef.h> |
6 | #include <linux/linkage.h> | 6 | #include <linux/linkage.h> |
7 | #include <linux/config.h> | ||
8 | 7 | ||
9 | struct vm_area_struct; | 8 | struct vm_area_struct; |
10 | 9 | ||
diff --git a/include/linux/hardirq.h b/include/linux/hardirq.h index eab537091f2a..114ae583cca9 100644 --- a/include/linux/hardirq.h +++ b/include/linux/hardirq.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef LINUX_HARDIRQ_H | 1 | #ifndef LINUX_HARDIRQ_H |
2 | #define LINUX_HARDIRQ_H | 2 | #define LINUX_HARDIRQ_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/preempt.h> | 4 | #include <linux/preempt.h> |
6 | #include <linux/smp_lock.h> | 5 | #include <linux/smp_lock.h> |
7 | #include <asm/hardirq.h> | 6 | #include <asm/hardirq.h> |
diff --git a/include/linux/highmem.h b/include/linux/highmem.h index 892c4ea1b425..85ce7ef9a512 100644 --- a/include/linux/highmem.h +++ b/include/linux/highmem.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _LINUX_HIGHMEM_H | 1 | #ifndef _LINUX_HIGHMEM_H |
2 | #define _LINUX_HIGHMEM_H | 2 | #define _LINUX_HIGHMEM_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/fs.h> | 4 | #include <linux/fs.h> |
6 | #include <linux/mm.h> | 5 | #include <linux/mm.h> |
7 | 6 | ||
diff --git a/include/linux/highuid.h b/include/linux/highuid.h index 53ecac3905e8..434e56246f67 100644 --- a/include/linux/highuid.h +++ b/include/linux/highuid.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _LINUX_HIGHUID_H | 1 | #ifndef _LINUX_HIGHUID_H |
2 | #define _LINUX_HIGHUID_H | 2 | #define _LINUX_HIGHUID_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/types.h> | 4 | #include <linux/types.h> |
6 | 5 | ||
7 | /* | 6 | /* |
diff --git a/include/linux/hrtimer.h b/include/linux/hrtimer.h index 306acf1dc6d5..7d2a1b974c5e 100644 --- a/include/linux/hrtimer.h +++ b/include/linux/hrtimer.h | |||
@@ -127,7 +127,7 @@ extern ktime_t hrtimer_get_next_event(void); | |||
127 | 127 | ||
128 | static inline int hrtimer_active(const struct hrtimer *timer) | 128 | static inline int hrtimer_active(const struct hrtimer *timer) |
129 | { | 129 | { |
130 | return timer->node.rb_parent != HRTIMER_INACTIVE; | 130 | return rb_parent(&timer->node) != &timer->node; |
131 | } | 131 | } |
132 | 132 | ||
133 | /* Forward a hrtimer so it expires after now: */ | 133 | /* Forward a hrtimer so it expires after now: */ |
diff --git a/include/linux/i2c-algo-ite.h b/include/linux/i2c-algo-ite.h index 26a8b89855f1..0073fe96c76e 100644 --- a/include/linux/i2c-algo-ite.h +++ b/include/linux/i2c-algo-ite.h | |||
@@ -29,7 +29,7 @@ | |||
29 | #ifndef I2C_ALGO_ITE_H | 29 | #ifndef I2C_ALGO_ITE_H |
30 | #define I2C_ALGO_ITE_H 1 | 30 | #define I2C_ALGO_ITE_H 1 |
31 | 31 | ||
32 | #include <linux/i2c.h> | 32 | #include <linux/types.h> |
33 | 33 | ||
34 | /* Example of a sequential read request: | 34 | /* Example of a sequential read request: |
35 | struct i2c_iic_msg s_msg; | 35 | struct i2c_iic_msg s_msg; |
@@ -49,6 +49,9 @@ struct i2c_iic_msg { | |||
49 | char *buf; /* pointer to msg data */ | 49 | char *buf; /* pointer to msg data */ |
50 | }; | 50 | }; |
51 | 51 | ||
52 | #ifdef __KERNEL__ | ||
53 | struct i2c_adapter; | ||
54 | |||
52 | struct i2c_algo_iic_data { | 55 | struct i2c_algo_iic_data { |
53 | void *data; /* private data for lolevel routines */ | 56 | void *data; /* private data for lolevel routines */ |
54 | void (*setiic) (void *data, int ctl, int val); | 57 | void (*setiic) (void *data, int ctl, int val); |
@@ -65,5 +68,5 @@ struct i2c_algo_iic_data { | |||
65 | 68 | ||
66 | int i2c_iic_add_bus(struct i2c_adapter *); | 69 | int i2c_iic_add_bus(struct i2c_adapter *); |
67 | int i2c_iic_del_bus(struct i2c_adapter *); | 70 | int i2c_iic_del_bus(struct i2c_adapter *); |
68 | 71 | #endif /* __KERNEL__ */ | |
69 | #endif /* I2C_ALGO_ITE_H */ | 72 | #endif /* I2C_ALGO_ITE_H */ |
diff --git a/include/linux/i2c-ocores.h b/include/linux/i2c-ocores.h new file mode 100644 index 000000000000..8ed591b0887e --- /dev/null +++ b/include/linux/i2c-ocores.h | |||
@@ -0,0 +1,19 @@ | |||
1 | /* | ||
2 | * i2c-ocores.h - definitions for the i2c-ocores interface | ||
3 | * | ||
4 | * Peter Korsgaard <jacmet@sunsite.dk> | ||
5 | * | ||
6 | * This file is licensed under the terms of the GNU General Public License | ||
7 | * version 2. This program is licensed "as is" without any warranty of any | ||
8 | * kind, whether express or implied. | ||
9 | */ | ||
10 | |||
11 | #ifndef _LINUX_I2C_OCORES_H | ||
12 | #define _LINUX_I2C_OCORES_H | ||
13 | |||
14 | struct ocores_i2c_platform_data { | ||
15 | u32 regstep; /* distance between registers */ | ||
16 | u32 clock_khz; /* input clock in kHz */ | ||
17 | }; | ||
18 | |||
19 | #endif /* _LINUX_I2C_OCORES_H */ | ||
diff --git a/include/linux/i2c.h b/include/linux/i2c.h index 1635ee25918f..526ddc8eecfb 100644 --- a/include/linux/i2c.h +++ b/include/linux/i2c.h | |||
@@ -20,14 +20,15 @@ | |||
20 | Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ | 20 | Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ |
21 | /* ------------------------------------------------------------------------- */ | 21 | /* ------------------------------------------------------------------------- */ |
22 | 22 | ||
23 | /* With some changes from Kyösti Mälkki <kmalkki@cc.hut.fi> and | 23 | /* With some changes from Kyösti Mälkki <kmalkki@cc.hut.fi> and |
24 | Frodo Looijaard <frodol@dds.nl> */ | 24 | Frodo Looijaard <frodol@dds.nl> */ |
25 | 25 | ||
26 | #ifndef _LINUX_I2C_H | 26 | #ifndef _LINUX_I2C_H |
27 | #define _LINUX_I2C_H | 27 | #define _LINUX_I2C_H |
28 | 28 | ||
29 | #include <linux/module.h> | ||
30 | #include <linux/types.h> | 29 | #include <linux/types.h> |
30 | #ifdef __KERNEL__ | ||
31 | #include <linux/module.h> | ||
31 | #include <linux/i2c-id.h> | 32 | #include <linux/i2c-id.h> |
32 | #include <linux/mod_devicetable.h> | 33 | #include <linux/mod_devicetable.h> |
33 | #include <linux/device.h> /* for struct device */ | 34 | #include <linux/device.h> /* for struct device */ |
@@ -96,13 +97,13 @@ extern s32 i2c_smbus_write_word_data(struct i2c_client * client, | |||
96 | u8 command, u16 value); | 97 | u8 command, u16 value); |
97 | extern s32 i2c_smbus_write_block_data(struct i2c_client * client, | 98 | extern s32 i2c_smbus_write_block_data(struct i2c_client * client, |
98 | u8 command, u8 length, | 99 | u8 command, u8 length, |
99 | u8 *values); | 100 | const u8 *values); |
100 | /* Returns the number of read bytes */ | 101 | /* Returns the number of read bytes */ |
101 | extern s32 i2c_smbus_read_i2c_block_data(struct i2c_client * client, | 102 | extern s32 i2c_smbus_read_i2c_block_data(struct i2c_client * client, |
102 | u8 command, u8 *values); | 103 | u8 command, u8 *values); |
103 | extern s32 i2c_smbus_write_i2c_block_data(struct i2c_client * client, | 104 | extern s32 i2c_smbus_write_i2c_block_data(struct i2c_client * client, |
104 | u8 command, u8 length, | 105 | u8 command, u8 length, |
105 | u8 *values); | 106 | const u8 *values); |
106 | 107 | ||
107 | /* | 108 | /* |
108 | * A driver is capable of handling one or more physical devices present on | 109 | * A driver is capable of handling one or more physical devices present on |
@@ -354,6 +355,7 @@ static inline int i2c_adapter_id(struct i2c_adapter *adap) | |||
354 | { | 355 | { |
355 | return adap->nr; | 356 | return adap->nr; |
356 | } | 357 | } |
358 | #endif /* __KERNEL__ */ | ||
357 | 359 | ||
358 | /* | 360 | /* |
359 | * I2C Message - used for pure i2c transaction, also from /dev interface | 361 | * I2C Message - used for pure i2c transaction, also from /dev interface |
@@ -469,6 +471,7 @@ union i2c_smbus_data { | |||
469 | #define I2C_SMBUS 0x0720 /* SMBus-level access */ | 471 | #define I2C_SMBUS 0x0720 /* SMBus-level access */ |
470 | 472 | ||
471 | /* ----- I2C-DEV: char device interface stuff ------------------------- */ | 473 | /* ----- I2C-DEV: char device interface stuff ------------------------- */ |
474 | #ifdef __KERNEL__ | ||
472 | 475 | ||
473 | #define I2C_MAJOR 89 /* Device major number */ | 476 | #define I2C_MAJOR 89 /* Device major number */ |
474 | 477 | ||
@@ -646,5 +649,5 @@ static unsigned short *forces[] = { force, force_##chip1, \ | |||
646 | force_##chip6, force_##chip7, \ | 649 | force_##chip6, force_##chip7, \ |
647 | force_##chip8, NULL }; \ | 650 | force_##chip8, NULL }; \ |
648 | I2C_CLIENT_INSMOD_COMMON | 651 | I2C_CLIENT_INSMOD_COMMON |
649 | 652 | #endif /* __KERNEL__ */ | |
650 | #endif /* _LINUX_I2C_H */ | 653 | #endif /* _LINUX_I2C_H */ |
diff --git a/include/linux/i2o-dev.h b/include/linux/i2o-dev.h index 36fd18cdad28..c2519df1b6dc 100644 --- a/include/linux/i2o-dev.h +++ b/include/linux/i2o-dev.h | |||
@@ -13,7 +13,7 @@ | |||
13 | * This header file defines the I2O APIs that are available to both | 13 | * This header file defines the I2O APIs that are available to both |
14 | * the kernel and user level applications. Kernel specific structures | 14 | * the kernel and user level applications. Kernel specific structures |
15 | * are defined in i2o_osm. OSMs should include _only_ i2o_osm.h which | 15 | * are defined in i2o_osm. OSMs should include _only_ i2o_osm.h which |
16 | * automatically includs this file. | 16 | * automatically includes this file. |
17 | * | 17 | * |
18 | */ | 18 | */ |
19 | 19 | ||
@@ -23,14 +23,7 @@ | |||
23 | /* How many controllers are we allowing */ | 23 | /* How many controllers are we allowing */ |
24 | #define MAX_I2O_CONTROLLERS 32 | 24 | #define MAX_I2O_CONTROLLERS 32 |
25 | 25 | ||
26 | //#include <linux/ioctl.h> | 26 | #include <linux/ioctl.h> |
27 | #ifndef __KERNEL__ | ||
28 | |||
29 | typedef unsigned char u8; | ||
30 | typedef unsigned short u16; | ||
31 | typedef unsigned int u32; | ||
32 | |||
33 | #endif /* __KERNEL__ */ | ||
34 | 27 | ||
35 | /* | 28 | /* |
36 | * I2O Control IOCTLs and structures | 29 | * I2O Control IOCTLs and structures |
@@ -53,7 +46,7 @@ typedef unsigned int u32; | |||
53 | 46 | ||
54 | struct i2o_cmd_passthru32 { | 47 | struct i2o_cmd_passthru32 { |
55 | unsigned int iop; /* IOP unit number */ | 48 | unsigned int iop; /* IOP unit number */ |
56 | u32 msg; /* message */ | 49 | __u32 msg; /* message */ |
57 | }; | 50 | }; |
58 | 51 | ||
59 | struct i2o_cmd_passthru { | 52 | struct i2o_cmd_passthru { |
@@ -138,53 +131,53 @@ typedef struct i2o_sg_io_hdr { | |||
138 | #define I2O_BUS_UNKNOWN 0x80 | 131 | #define I2O_BUS_UNKNOWN 0x80 |
139 | 132 | ||
140 | typedef struct _i2o_pci_bus { | 133 | typedef struct _i2o_pci_bus { |
141 | u8 PciFunctionNumber; | 134 | __u8 PciFunctionNumber; |
142 | u8 PciDeviceNumber; | 135 | __u8 PciDeviceNumber; |
143 | u8 PciBusNumber; | 136 | __u8 PciBusNumber; |
144 | u8 reserved; | 137 | __u8 reserved; |
145 | u16 PciVendorID; | 138 | __u16 PciVendorID; |
146 | u16 PciDeviceID; | 139 | __u16 PciDeviceID; |
147 | } i2o_pci_bus; | 140 | } i2o_pci_bus; |
148 | 141 | ||
149 | typedef struct _i2o_local_bus { | 142 | typedef struct _i2o_local_bus { |
150 | u16 LbBaseIOPort; | 143 | __u16 LbBaseIOPort; |
151 | u16 reserved; | 144 | __u16 reserved; |
152 | u32 LbBaseMemoryAddress; | 145 | __u32 LbBaseMemoryAddress; |
153 | } i2o_local_bus; | 146 | } i2o_local_bus; |
154 | 147 | ||
155 | typedef struct _i2o_isa_bus { | 148 | typedef struct _i2o_isa_bus { |
156 | u16 IsaBaseIOPort; | 149 | __u16 IsaBaseIOPort; |
157 | u8 CSN; | 150 | __u8 CSN; |
158 | u8 reserved; | 151 | __u8 reserved; |
159 | u32 IsaBaseMemoryAddress; | 152 | __u32 IsaBaseMemoryAddress; |
160 | } i2o_isa_bus; | 153 | } i2o_isa_bus; |
161 | 154 | ||
162 | typedef struct _i2o_eisa_bus_info { | 155 | typedef struct _i2o_eisa_bus_info { |
163 | u16 EisaBaseIOPort; | 156 | __u16 EisaBaseIOPort; |
164 | u8 reserved; | 157 | __u8 reserved; |
165 | u8 EisaSlotNumber; | 158 | __u8 EisaSlotNumber; |
166 | u32 EisaBaseMemoryAddress; | 159 | __u32 EisaBaseMemoryAddress; |
167 | } i2o_eisa_bus; | 160 | } i2o_eisa_bus; |
168 | 161 | ||
169 | typedef struct _i2o_mca_bus { | 162 | typedef struct _i2o_mca_bus { |
170 | u16 McaBaseIOPort; | 163 | __u16 McaBaseIOPort; |
171 | u8 reserved; | 164 | __u8 reserved; |
172 | u8 McaSlotNumber; | 165 | __u8 McaSlotNumber; |
173 | u32 McaBaseMemoryAddress; | 166 | __u32 McaBaseMemoryAddress; |
174 | } i2o_mca_bus; | 167 | } i2o_mca_bus; |
175 | 168 | ||
176 | typedef struct _i2o_other_bus { | 169 | typedef struct _i2o_other_bus { |
177 | u16 BaseIOPort; | 170 | __u16 BaseIOPort; |
178 | u16 reserved; | 171 | __u16 reserved; |
179 | u32 BaseMemoryAddress; | 172 | __u32 BaseMemoryAddress; |
180 | } i2o_other_bus; | 173 | } i2o_other_bus; |
181 | 174 | ||
182 | typedef struct _i2o_hrt_entry { | 175 | typedef struct _i2o_hrt_entry { |
183 | u32 adapter_id; | 176 | __u32 adapter_id; |
184 | u32 parent_tid:12; | 177 | __u32 parent_tid:12; |
185 | u32 state:4; | 178 | __u32 state:4; |
186 | u32 bus_num:8; | 179 | __u32 bus_num:8; |
187 | u32 bus_type:8; | 180 | __u32 bus_type:8; |
188 | union { | 181 | union { |
189 | i2o_pci_bus pci_bus; | 182 | i2o_pci_bus pci_bus; |
190 | i2o_local_bus local_bus; | 183 | i2o_local_bus local_bus; |
@@ -196,66 +189,66 @@ typedef struct _i2o_hrt_entry { | |||
196 | } i2o_hrt_entry; | 189 | } i2o_hrt_entry; |
197 | 190 | ||
198 | typedef struct _i2o_hrt { | 191 | typedef struct _i2o_hrt { |
199 | u16 num_entries; | 192 | __u16 num_entries; |
200 | u8 entry_len; | 193 | __u8 entry_len; |
201 | u8 hrt_version; | 194 | __u8 hrt_version; |
202 | u32 change_ind; | 195 | __u32 change_ind; |
203 | i2o_hrt_entry hrt_entry[1]; | 196 | i2o_hrt_entry hrt_entry[1]; |
204 | } i2o_hrt; | 197 | } i2o_hrt; |
205 | 198 | ||
206 | typedef struct _i2o_lct_entry { | 199 | typedef struct _i2o_lct_entry { |
207 | u32 entry_size:16; | 200 | __u32 entry_size:16; |
208 | u32 tid:12; | 201 | __u32 tid:12; |
209 | u32 reserved:4; | 202 | __u32 reserved:4; |
210 | u32 change_ind; | 203 | __u32 change_ind; |
211 | u32 device_flags; | 204 | __u32 device_flags; |
212 | u32 class_id:12; | 205 | __u32 class_id:12; |
213 | u32 version:4; | 206 | __u32 version:4; |
214 | u32 vendor_id:16; | 207 | __u32 vendor_id:16; |
215 | u32 sub_class; | 208 | __u32 sub_class; |
216 | u32 user_tid:12; | 209 | __u32 user_tid:12; |
217 | u32 parent_tid:12; | 210 | __u32 parent_tid:12; |
218 | u32 bios_info:8; | 211 | __u32 bios_info:8; |
219 | u8 identity_tag[8]; | 212 | __u8 identity_tag[8]; |
220 | u32 event_capabilities; | 213 | __u32 event_capabilities; |
221 | } i2o_lct_entry; | 214 | } i2o_lct_entry; |
222 | 215 | ||
223 | typedef struct _i2o_lct { | 216 | typedef struct _i2o_lct { |
224 | u32 table_size:16; | 217 | __u32 table_size:16; |
225 | u32 boot_tid:12; | 218 | __u32 boot_tid:12; |
226 | u32 lct_ver:4; | 219 | __u32 lct_ver:4; |
227 | u32 iop_flags; | 220 | __u32 iop_flags; |
228 | u32 change_ind; | 221 | __u32 change_ind; |
229 | i2o_lct_entry lct_entry[1]; | 222 | i2o_lct_entry lct_entry[1]; |
230 | } i2o_lct; | 223 | } i2o_lct; |
231 | 224 | ||
232 | typedef struct _i2o_status_block { | 225 | typedef struct _i2o_status_block { |
233 | u16 org_id; | 226 | __u16 org_id; |
234 | u16 reserved; | 227 | __u16 reserved; |
235 | u16 iop_id:12; | 228 | __u16 iop_id:12; |
236 | u16 reserved1:4; | 229 | __u16 reserved1:4; |
237 | u16 host_unit_id; | 230 | __u16 host_unit_id; |
238 | u16 segment_number:12; | 231 | __u16 segment_number:12; |
239 | u16 i2o_version:4; | 232 | __u16 i2o_version:4; |
240 | u8 iop_state; | 233 | __u8 iop_state; |
241 | u8 msg_type; | 234 | __u8 msg_type; |
242 | u16 inbound_frame_size; | 235 | __u16 inbound_frame_size; |
243 | u8 init_code; | 236 | __u8 init_code; |
244 | u8 reserved2; | 237 | __u8 reserved2; |
245 | u32 max_inbound_frames; | 238 | __u32 max_inbound_frames; |
246 | u32 cur_inbound_frames; | 239 | __u32 cur_inbound_frames; |
247 | u32 max_outbound_frames; | 240 | __u32 max_outbound_frames; |
248 | char product_id[24]; | 241 | char product_id[24]; |
249 | u32 expected_lct_size; | 242 | __u32 expected_lct_size; |
250 | u32 iop_capabilities; | 243 | __u32 iop_capabilities; |
251 | u32 desired_mem_size; | 244 | __u32 desired_mem_size; |
252 | u32 current_mem_size; | 245 | __u32 current_mem_size; |
253 | u32 current_mem_base; | 246 | __u32 current_mem_base; |
254 | u32 desired_io_size; | 247 | __u32 desired_io_size; |
255 | u32 current_io_size; | 248 | __u32 current_io_size; |
256 | u32 current_io_base; | 249 | __u32 current_io_base; |
257 | u32 reserved3:24; | 250 | __u32 reserved3:24; |
258 | u32 cmd_status:8; | 251 | __u32 cmd_status:8; |
259 | } i2o_status_block; | 252 | } i2o_status_block; |
260 | 253 | ||
261 | /* Event indicator mask flags */ | 254 | /* Event indicator mask flags */ |
diff --git a/include/linux/ide.h b/include/linux/ide.h index a8bef1d1371c..77e66d055f5b 100644 --- a/include/linux/ide.h +++ b/include/linux/ide.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * Copyright (C) 1994-2002 Linus Torvalds & authors | 6 | * Copyright (C) 1994-2002 Linus Torvalds & authors |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <linux/init.h> | 9 | #include <linux/init.h> |
11 | #include <linux/ioport.h> | 10 | #include <linux/ioport.h> |
12 | #include <linux/hdreg.h> | 11 | #include <linux/hdreg.h> |
diff --git a/include/linux/if_fddi.h b/include/linux/if_fddi.h index 1288a161bc0b..e0a150046208 100644 --- a/include/linux/if_fddi.h +++ b/include/linux/if_fddi.h | |||
@@ -102,6 +102,7 @@ struct fddihdr | |||
102 | } hdr; | 102 | } hdr; |
103 | } __attribute__ ((packed)); | 103 | } __attribute__ ((packed)); |
104 | 104 | ||
105 | #ifdef __KERNEL__ | ||
105 | /* Define FDDI statistics structure */ | 106 | /* Define FDDI statistics structure */ |
106 | struct fddi_statistics { | 107 | struct fddi_statistics { |
107 | 108 | ||
@@ -193,5 +194,6 @@ struct fddi_statistics { | |||
193 | __u32 port_ler_flag[2]; | 194 | __u32 port_ler_flag[2]; |
194 | __u32 port_hardware_present[2]; | 195 | __u32 port_hardware_present[2]; |
195 | }; | 196 | }; |
197 | #endif /* __KERNEL__ */ | ||
196 | 198 | ||
197 | #endif /* _LINUX_IF_FDDI_H */ | 199 | #endif /* _LINUX_IF_FDDI_H */ |
diff --git a/include/linux/if_frad.h b/include/linux/if_frad.h index 395f0aad9cbf..f272a80caa3e 100644 --- a/include/linux/if_frad.h +++ b/include/linux/if_frad.h | |||
@@ -24,7 +24,6 @@ | |||
24 | #ifndef _FRAD_H_ | 24 | #ifndef _FRAD_H_ |
25 | #define _FRAD_H_ | 25 | #define _FRAD_H_ |
26 | 26 | ||
27 | #include <linux/config.h> | ||
28 | #include <linux/if.h> | 27 | #include <linux/if.h> |
29 | 28 | ||
30 | #if defined(CONFIG_DLCI) || defined(CONFIG_DLCI_MODULE) | 29 | #if defined(CONFIG_DLCI) || defined(CONFIG_DLCI_MODULE) |
diff --git a/include/linux/if_tr.h b/include/linux/if_tr.h index 5502f597cf0e..2f94cf2c7abb 100644 --- a/include/linux/if_tr.h +++ b/include/linux/if_tr.h | |||
@@ -43,7 +43,6 @@ struct trh_hdr { | |||
43 | }; | 43 | }; |
44 | 44 | ||
45 | #ifdef __KERNEL__ | 45 | #ifdef __KERNEL__ |
46 | #include <linux/config.h> | ||
47 | #include <linux/skbuff.h> | 46 | #include <linux/skbuff.h> |
48 | 47 | ||
49 | static inline struct trh_hdr *tr_hdr(const struct sk_buff *skb) | 48 | static inline struct trh_hdr *tr_hdr(const struct sk_buff *skb) |
diff --git a/include/linux/igmp.h b/include/linux/igmp.h index 28f4f3b36950..899c3d4776f3 100644 --- a/include/linux/igmp.h +++ b/include/linux/igmp.h | |||
@@ -169,7 +169,7 @@ struct ip_sf_list | |||
169 | struct ip_mc_list | 169 | struct ip_mc_list |
170 | { | 170 | { |
171 | struct in_device *interface; | 171 | struct in_device *interface; |
172 | unsigned long multiaddr; | 172 | __be32 multiaddr; |
173 | struct ip_sf_list *sources; | 173 | struct ip_sf_list *sources; |
174 | struct ip_sf_list *tomb; | 174 | struct ip_sf_list *tomb; |
175 | unsigned int sfmode; | 175 | unsigned int sfmode; |
diff --git a/include/linux/init.h b/include/linux/init.h index 93dcbe1abb4c..6667785dd1ff 100644 --- a/include/linux/init.h +++ b/include/linux/init.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _LINUX_INIT_H | 1 | #ifndef _LINUX_INIT_H |
2 | #define _LINUX_INIT_H | 2 | #define _LINUX_INIT_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/compiler.h> | 4 | #include <linux/compiler.h> |
6 | 5 | ||
7 | /* These macros are used to mark some functions or | 6 | /* These macros are used to mark some functions or |
diff --git a/include/linux/inotify.h b/include/linux/inotify.h index 09e00433c78e..d4f48c6402e6 100644 --- a/include/linux/inotify.h +++ b/include/linux/inotify.h | |||
@@ -67,20 +67,66 @@ struct inotify_event { | |||
67 | 67 | ||
68 | #include <linux/dcache.h> | 68 | #include <linux/dcache.h> |
69 | #include <linux/fs.h> | 69 | #include <linux/fs.h> |
70 | #include <linux/config.h> | 70 | |
71 | /* | ||
72 | * struct inotify_watch - represents a watch request on a specific inode | ||
73 | * | ||
74 | * h_list is protected by ih->mutex of the associated inotify_handle. | ||
75 | * i_list, mask are protected by inode->inotify_mutex of the associated inode. | ||
76 | * ih, inode, and wd are never written to once the watch is created. | ||
77 | * | ||
78 | * Callers must use the established inotify interfaces to access inotify_watch | ||
79 | * contents. The content of this structure is private to the inotify | ||
80 | * implementation. | ||
81 | */ | ||
82 | struct inotify_watch { | ||
83 | struct list_head h_list; /* entry in inotify_handle's list */ | ||
84 | struct list_head i_list; /* entry in inode's list */ | ||
85 | atomic_t count; /* reference count */ | ||
86 | struct inotify_handle *ih; /* associated inotify handle */ | ||
87 | struct inode *inode; /* associated inode */ | ||
88 | __s32 wd; /* watch descriptor */ | ||
89 | __u32 mask; /* event mask for this watch */ | ||
90 | }; | ||
91 | |||
92 | struct inotify_operations { | ||
93 | void (*handle_event)(struct inotify_watch *, u32, u32, u32, | ||
94 | const char *, struct inode *); | ||
95 | void (*destroy_watch)(struct inotify_watch *); | ||
96 | }; | ||
71 | 97 | ||
72 | #ifdef CONFIG_INOTIFY | 98 | #ifdef CONFIG_INOTIFY |
73 | 99 | ||
100 | /* Kernel API for producing events */ | ||
101 | |||
74 | extern void inotify_d_instantiate(struct dentry *, struct inode *); | 102 | extern void inotify_d_instantiate(struct dentry *, struct inode *); |
75 | extern void inotify_d_move(struct dentry *); | 103 | extern void inotify_d_move(struct dentry *); |
76 | extern void inotify_inode_queue_event(struct inode *, __u32, __u32, | 104 | extern void inotify_inode_queue_event(struct inode *, __u32, __u32, |
77 | const char *); | 105 | const char *, struct inode *); |
78 | extern void inotify_dentry_parent_queue_event(struct dentry *, __u32, __u32, | 106 | extern void inotify_dentry_parent_queue_event(struct dentry *, __u32, __u32, |
79 | const char *); | 107 | const char *); |
80 | extern void inotify_unmount_inodes(struct list_head *); | 108 | extern void inotify_unmount_inodes(struct list_head *); |
81 | extern void inotify_inode_is_dead(struct inode *); | 109 | extern void inotify_inode_is_dead(struct inode *); |
82 | extern u32 inotify_get_cookie(void); | 110 | extern u32 inotify_get_cookie(void); |
83 | 111 | ||
112 | /* Kernel Consumer API */ | ||
113 | |||
114 | extern struct inotify_handle *inotify_init(const struct inotify_operations *); | ||
115 | extern void inotify_init_watch(struct inotify_watch *); | ||
116 | extern void inotify_destroy(struct inotify_handle *); | ||
117 | extern __s32 inotify_find_watch(struct inotify_handle *, struct inode *, | ||
118 | struct inotify_watch **); | ||
119 | extern __s32 inotify_find_update_watch(struct inotify_handle *, struct inode *, | ||
120 | u32); | ||
121 | extern __s32 inotify_add_watch(struct inotify_handle *, struct inotify_watch *, | ||
122 | struct inode *, __u32); | ||
123 | extern int inotify_rm_watch(struct inotify_handle *, struct inotify_watch *); | ||
124 | extern int inotify_rm_wd(struct inotify_handle *, __u32); | ||
125 | extern void inotify_remove_watch_locked(struct inotify_handle *, | ||
126 | struct inotify_watch *); | ||
127 | extern void get_inotify_watch(struct inotify_watch *); | ||
128 | extern void put_inotify_watch(struct inotify_watch *); | ||
129 | |||
84 | #else | 130 | #else |
85 | 131 | ||
86 | static inline void inotify_d_instantiate(struct dentry *dentry, | 132 | static inline void inotify_d_instantiate(struct dentry *dentry, |
@@ -94,7 +140,8 @@ static inline void inotify_d_move(struct dentry *dentry) | |||
94 | 140 | ||
95 | static inline void inotify_inode_queue_event(struct inode *inode, | 141 | static inline void inotify_inode_queue_event(struct inode *inode, |
96 | __u32 mask, __u32 cookie, | 142 | __u32 mask, __u32 cookie, |
97 | const char *filename) | 143 | const char *filename, |
144 | struct inode *n_inode) | ||
98 | { | 145 | { |
99 | } | 146 | } |
100 | 147 | ||
@@ -117,6 +164,62 @@ static inline u32 inotify_get_cookie(void) | |||
117 | return 0; | 164 | return 0; |
118 | } | 165 | } |
119 | 166 | ||
167 | static inline struct inotify_handle *inotify_init(const struct inotify_operations *ops) | ||
168 | { | ||
169 | return ERR_PTR(-EOPNOTSUPP); | ||
170 | } | ||
171 | |||
172 | static inline void inotify_init_watch(struct inotify_watch *watch) | ||
173 | { | ||
174 | } | ||
175 | |||
176 | static inline void inotify_destroy(struct inotify_handle *ih) | ||
177 | { | ||
178 | } | ||
179 | |||
180 | static inline __s32 inotify_find_watch(struct inotify_handle *ih, struct inode *inode, | ||
181 | struct inotify_watch **watchp) | ||
182 | { | ||
183 | return -EOPNOTSUPP; | ||
184 | } | ||
185 | |||
186 | static inline __s32 inotify_find_update_watch(struct inotify_handle *ih, | ||
187 | struct inode *inode, u32 mask) | ||
188 | { | ||
189 | return -EOPNOTSUPP; | ||
190 | } | ||
191 | |||
192 | static inline __s32 inotify_add_watch(struct inotify_handle *ih, | ||
193 | struct inotify_watch *watch, | ||
194 | struct inode *inode, __u32 mask) | ||
195 | { | ||
196 | return -EOPNOTSUPP; | ||
197 | } | ||
198 | |||
199 | static inline int inotify_rm_watch(struct inotify_handle *ih, | ||
200 | struct inotify_watch *watch) | ||
201 | { | ||
202 | return -EOPNOTSUPP; | ||
203 | } | ||
204 | |||
205 | static inline int inotify_rm_wd(struct inotify_handle *ih, __u32 wd) | ||
206 | { | ||
207 | return -EOPNOTSUPP; | ||
208 | } | ||
209 | |||
210 | static inline void inotify_remove_watch_locked(struct inotify_handle *ih, | ||
211 | struct inotify_watch *watch) | ||
212 | { | ||
213 | } | ||
214 | |||
215 | static inline void get_inotify_watch(struct inotify_watch *watch) | ||
216 | { | ||
217 | } | ||
218 | |||
219 | static inline void put_inotify_watch(struct inotify_watch *watch) | ||
220 | { | ||
221 | } | ||
222 | |||
120 | #endif /* CONFIG_INOTIFY */ | 223 | #endif /* CONFIG_INOTIFY */ |
121 | 224 | ||
122 | #endif /* __KERNEL __ */ | 225 | #endif /* __KERNEL __ */ |
diff --git a/include/linux/input.h b/include/linux/input.h index ce1a756c4c30..b32c2b6e53f6 100644 --- a/include/linux/input.h +++ b/include/linux/input.h | |||
@@ -15,6 +15,7 @@ | |||
15 | #else | 15 | #else |
16 | #include <sys/time.h> | 16 | #include <sys/time.h> |
17 | #include <sys/ioctl.h> | 17 | #include <sys/ioctl.h> |
18 | #include <sys/types.h> | ||
18 | #include <asm/types.h> | 19 | #include <asm/types.h> |
19 | #endif | 20 | #endif |
20 | 21 | ||
diff --git a/include/linux/interrupt.h b/include/linux/interrupt.h index 2c08fdc2bdf7..9e0fefd7884a 100644 --- a/include/linux/interrupt.h +++ b/include/linux/interrupt.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #ifndef _LINUX_INTERRUPT_H | 2 | #ifndef _LINUX_INTERRUPT_H |
3 | #define _LINUX_INTERRUPT_H | 3 | #define _LINUX_INTERRUPT_H |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | #include <linux/kernel.h> | 5 | #include <linux/kernel.h> |
7 | #include <linux/linkage.h> | 6 | #include <linux/linkage.h> |
8 | #include <linux/bitops.h> | 7 | #include <linux/bitops.h> |
diff --git a/include/linux/io.h b/include/linux/io.h index 85533ec5aaa1..420e2fdf26f6 100644 --- a/include/linux/io.h +++ b/include/linux/io.h | |||
@@ -21,5 +21,6 @@ | |||
21 | #include <asm/io.h> | 21 | #include <asm/io.h> |
22 | 22 | ||
23 | void __iowrite32_copy(void __iomem *to, const void *from, size_t count); | 23 | void __iowrite32_copy(void __iomem *to, const void *from, size_t count); |
24 | void __iowrite64_copy(void __iomem *to, const void *from, size_t count); | ||
24 | 25 | ||
25 | #endif /* _LINUX_IO_H */ | 26 | #endif /* _LINUX_IO_H */ |
diff --git a/include/linux/ipmi.h b/include/linux/ipmi.h index 0a84b56935c2..5653b2f23b6a 100644 --- a/include/linux/ipmi.h +++ b/include/linux/ipmi.h | |||
@@ -36,7 +36,6 @@ | |||
36 | 36 | ||
37 | #include <linux/ipmi_msgdefs.h> | 37 | #include <linux/ipmi_msgdefs.h> |
38 | #include <linux/compiler.h> | 38 | #include <linux/compiler.h> |
39 | #include <linux/device.h> | ||
40 | 39 | ||
41 | /* | 40 | /* |
42 | * This file describes an interface to an IPMI driver. You have to | 41 | * This file describes an interface to an IPMI driver. You have to |
@@ -210,6 +209,7 @@ struct kernel_ipmi_msg | |||
210 | */ | 209 | */ |
211 | #include <linux/list.h> | 210 | #include <linux/list.h> |
212 | #include <linux/module.h> | 211 | #include <linux/module.h> |
212 | #include <linux/device.h> | ||
213 | 213 | ||
214 | #ifdef CONFIG_PROC_FS | 214 | #ifdef CONFIG_PROC_FS |
215 | #include <linux/proc_fs.h> | 215 | #include <linux/proc_fs.h> |
diff --git a/include/linux/ipv6.h b/include/linux/ipv6.h index 1263d8cb3c18..297853c841b4 100644 --- a/include/linux/ipv6.h +++ b/include/linux/ipv6.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _IPV6_H | 1 | #ifndef _IPV6_H |
2 | #define _IPV6_H | 2 | #define _IPV6_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/in6.h> | 4 | #include <linux/in6.h> |
6 | #include <asm/byteorder.h> | 5 | #include <asm/byteorder.h> |
7 | 6 | ||
diff --git a/include/linux/irq.h b/include/linux/irq.h index ee2a82a572f7..42c9cd562860 100644 --- a/include/linux/irq.h +++ b/include/linux/irq.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * Thanks. --rmk | 9 | * Thanks. --rmk |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/smp.h> | 12 | #include <linux/smp.h> |
14 | 13 | ||
15 | #if !defined(CONFIG_S390) | 14 | #if !defined(CONFIG_S390) |
diff --git a/include/linux/irq_cpustat.h b/include/linux/irq_cpustat.h index af93505ec2ec..77e4bac29287 100644 --- a/include/linux/irq_cpustat.h +++ b/include/linux/irq_cpustat.h | |||
@@ -9,7 +9,6 @@ | |||
9 | * Keith Owens <kaos@ocs.com.au> July 2000. | 9 | * Keith Owens <kaos@ocs.com.au> July 2000. |
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | /* | 13 | /* |
15 | * Simple wrappers reducing source bloat. Define all irq_stat fields | 14 | * Simple wrappers reducing source bloat. Define all irq_stat fields |
diff --git a/include/linux/isa.h b/include/linux/isa.h new file mode 100644 index 000000000000..1b855335cb11 --- /dev/null +++ b/include/linux/isa.h | |||
@@ -0,0 +1,28 @@ | |||
1 | /* | ||
2 | * ISA bus. | ||
3 | */ | ||
4 | |||
5 | #ifndef __LINUX_ISA_H | ||
6 | #define __LINUX_ISA_H | ||
7 | |||
8 | #include <linux/device.h> | ||
9 | #include <linux/kernel.h> | ||
10 | |||
11 | struct isa_driver { | ||
12 | int (*match)(struct device *, unsigned int); | ||
13 | int (*probe)(struct device *, unsigned int); | ||
14 | int (*remove)(struct device *, unsigned int); | ||
15 | void (*shutdown)(struct device *, unsigned int); | ||
16 | int (*suspend)(struct device *, unsigned int, pm_message_t); | ||
17 | int (*resume)(struct device *, unsigned int); | ||
18 | |||
19 | struct device_driver driver; | ||
20 | struct device *devices; | ||
21 | }; | ||
22 | |||
23 | #define to_isa_driver(x) container_of((x), struct isa_driver, driver) | ||
24 | |||
25 | int isa_register_driver(struct isa_driver *, unsigned int); | ||
26 | void isa_unregister_driver(struct isa_driver *); | ||
27 | |||
28 | #endif /* __LINUX_ISA_H */ | ||
diff --git a/include/linux/isapnp.h b/include/linux/isapnp.h index 26c64c286f42..1e8728a9ee8a 100644 --- a/include/linux/isapnp.h +++ b/include/linux/isapnp.h | |||
@@ -22,7 +22,6 @@ | |||
22 | #ifndef LINUX_ISAPNP_H | 22 | #ifndef LINUX_ISAPNP_H |
23 | #define LINUX_ISAPNP_H | 23 | #define LINUX_ISAPNP_H |
24 | 24 | ||
25 | #include <linux/config.h> | ||
26 | #include <linux/errno.h> | 25 | #include <linux/errno.h> |
27 | #include <linux/pnp.h> | 26 | #include <linux/pnp.h> |
28 | 27 | ||
diff --git a/include/linux/isdn.h b/include/linux/isdn.h index 53eaee96065b..62991148d5a5 100644 --- a/include/linux/isdn.h +++ b/include/linux/isdn.h | |||
@@ -146,7 +146,6 @@ typedef struct { | |||
146 | 146 | ||
147 | #ifdef __KERNEL__ | 147 | #ifdef __KERNEL__ |
148 | 148 | ||
149 | #include <linux/config.h> | ||
150 | #include <linux/errno.h> | 149 | #include <linux/errno.h> |
151 | #include <linux/fs.h> | 150 | #include <linux/fs.h> |
152 | #include <linux/major.h> | 151 | #include <linux/major.h> |
diff --git a/include/linux/isdn/tpam.h b/include/linux/isdn/tpam.h index 9f65bea49d11..d18dd0dc570d 100644 --- a/include/linux/isdn/tpam.h +++ b/include/linux/isdn/tpam.h | |||
@@ -26,7 +26,6 @@ | |||
26 | #define _TPAM_H_ | 26 | #define _TPAM_H_ |
27 | 27 | ||
28 | #include <linux/types.h> | 28 | #include <linux/types.h> |
29 | #include <linux/pci.h> | ||
30 | 29 | ||
31 | /* IOCTL commands */ | 30 | /* IOCTL commands */ |
32 | #define TPAM_CMD_DSPLOAD 0x0001 | 31 | #define TPAM_CMD_DSPLOAD 0x0001 |
diff --git a/include/linux/isdn_ppp.h b/include/linux/isdn_ppp.h index 26b00a76e135..8687a7dc0632 100644 --- a/include/linux/isdn_ppp.h +++ b/include/linux/isdn_ppp.h | |||
@@ -67,7 +67,6 @@ struct isdn_ppp_comp_data { | |||
67 | #ifdef __KERNEL__ | 67 | #ifdef __KERNEL__ |
68 | 68 | ||
69 | 69 | ||
70 | #include <linux/config.h> | ||
71 | 70 | ||
72 | #ifdef CONFIG_IPPP_FILTER | 71 | #ifdef CONFIG_IPPP_FILTER |
73 | #include <linux/filter.h> | 72 | #include <linux/filter.h> |
diff --git a/include/linux/isdnif.h b/include/linux/isdnif.h index 04e10f9f14f8..b9b5a684ed69 100644 --- a/include/linux/isdnif.h +++ b/include/linux/isdnif.h | |||
@@ -54,7 +54,6 @@ | |||
54 | 54 | ||
55 | #ifdef __KERNEL__ | 55 | #ifdef __KERNEL__ |
56 | 56 | ||
57 | #include <linux/config.h> | ||
58 | #include <linux/skbuff.h> | 57 | #include <linux/skbuff.h> |
59 | 58 | ||
60 | /***************************************************************************/ | 59 | /***************************************************************************/ |
diff --git a/include/linux/jffs2.h b/include/linux/jffs2.h index cf792bb3c726..c6f70660b371 100644 --- a/include/linux/jffs2.h +++ b/include/linux/jffs2.h | |||
@@ -65,6 +65,18 @@ | |||
65 | 65 | ||
66 | #define JFFS2_NODETYPE_SUMMARY (JFFS2_FEATURE_RWCOMPAT_DELETE | JFFS2_NODE_ACCURATE | 6) | 66 | #define JFFS2_NODETYPE_SUMMARY (JFFS2_FEATURE_RWCOMPAT_DELETE | JFFS2_NODE_ACCURATE | 6) |
67 | 67 | ||
68 | #define JFFS2_NODETYPE_XATTR (JFFS2_FEATURE_INCOMPAT | JFFS2_NODE_ACCURATE | 8) | ||
69 | #define JFFS2_NODETYPE_XREF (JFFS2_FEATURE_INCOMPAT | JFFS2_NODE_ACCURATE | 9) | ||
70 | |||
71 | /* XATTR Related */ | ||
72 | #define JFFS2_XPREFIX_USER 1 /* for "user." */ | ||
73 | #define JFFS2_XPREFIX_SECURITY 2 /* for "security." */ | ||
74 | #define JFFS2_XPREFIX_ACL_ACCESS 3 /* for "system.posix_acl_access" */ | ||
75 | #define JFFS2_XPREFIX_ACL_DEFAULT 4 /* for "system.posix_acl_default" */ | ||
76 | #define JFFS2_XPREFIX_TRUSTED 5 /* for "trusted.*" */ | ||
77 | |||
78 | #define JFFS2_ACL_VERSION 0x0001 | ||
79 | |||
68 | // Maybe later... | 80 | // Maybe later... |
69 | //#define JFFS2_NODETYPE_CHECKPOINT (JFFS2_FEATURE_RWCOMPAT_DELETE | JFFS2_NODE_ACCURATE | 3) | 81 | //#define JFFS2_NODETYPE_CHECKPOINT (JFFS2_FEATURE_RWCOMPAT_DELETE | JFFS2_NODE_ACCURATE | 3) |
70 | //#define JFFS2_NODETYPE_OPTIONS (JFFS2_FEATURE_RWCOMPAT_COPY | JFFS2_NODE_ACCURATE | 4) | 82 | //#define JFFS2_NODETYPE_OPTIONS (JFFS2_FEATURE_RWCOMPAT_COPY | JFFS2_NODE_ACCURATE | 4) |
@@ -82,11 +94,11 @@ | |||
82 | 94 | ||
83 | typedef struct { | 95 | typedef struct { |
84 | uint32_t v32; | 96 | uint32_t v32; |
85 | } __attribute__((packed)) jint32_t; | 97 | } __attribute__((packed)) jint32_t; |
86 | 98 | ||
87 | typedef struct { | 99 | typedef struct { |
88 | uint32_t m; | 100 | uint32_t m; |
89 | } __attribute__((packed)) jmode_t; | 101 | } __attribute__((packed)) jmode_t; |
90 | 102 | ||
91 | typedef struct { | 103 | typedef struct { |
92 | uint16_t v16; | 104 | uint16_t v16; |
@@ -99,7 +111,7 @@ struct jffs2_unknown_node | |||
99 | jint16_t nodetype; | 111 | jint16_t nodetype; |
100 | jint32_t totlen; /* So we can skip over nodes we don't grok */ | 112 | jint32_t totlen; /* So we can skip over nodes we don't grok */ |
101 | jint32_t hdr_crc; | 113 | jint32_t hdr_crc; |
102 | } __attribute__((packed)); | 114 | }; |
103 | 115 | ||
104 | struct jffs2_raw_dirent | 116 | struct jffs2_raw_dirent |
105 | { | 117 | { |
@@ -117,7 +129,7 @@ struct jffs2_raw_dirent | |||
117 | jint32_t node_crc; | 129 | jint32_t node_crc; |
118 | jint32_t name_crc; | 130 | jint32_t name_crc; |
119 | uint8_t name[0]; | 131 | uint8_t name[0]; |
120 | } __attribute__((packed)); | 132 | }; |
121 | 133 | ||
122 | /* The JFFS2 raw inode structure: Used for storage on physical media. */ | 134 | /* The JFFS2 raw inode structure: Used for storage on physical media. */ |
123 | /* The uid, gid, atime, mtime and ctime members could be longer, but | 135 | /* The uid, gid, atime, mtime and ctime members could be longer, but |
@@ -149,6 +161,32 @@ struct jffs2_raw_inode | |||
149 | jint32_t data_crc; /* CRC for the (compressed) data. */ | 161 | jint32_t data_crc; /* CRC for the (compressed) data. */ |
150 | jint32_t node_crc; /* CRC for the raw inode (excluding data) */ | 162 | jint32_t node_crc; /* CRC for the raw inode (excluding data) */ |
151 | uint8_t data[0]; | 163 | uint8_t data[0]; |
164 | }; | ||
165 | |||
166 | struct jffs2_raw_xattr { | ||
167 | jint16_t magic; | ||
168 | jint16_t nodetype; /* = JFFS2_NODETYPE_XATTR */ | ||
169 | jint32_t totlen; | ||
170 | jint32_t hdr_crc; | ||
171 | jint32_t xid; /* XATTR identifier number */ | ||
172 | jint32_t version; | ||
173 | uint8_t xprefix; | ||
174 | uint8_t name_len; | ||
175 | jint16_t value_len; | ||
176 | jint32_t data_crc; | ||
177 | jint32_t node_crc; | ||
178 | uint8_t data[0]; | ||
179 | } __attribute__((packed)); | ||
180 | |||
181 | struct jffs2_raw_xref | ||
182 | { | ||
183 | jint16_t magic; | ||
184 | jint16_t nodetype; /* = JFFS2_NODETYPE_XREF */ | ||
185 | jint32_t totlen; | ||
186 | jint32_t hdr_crc; | ||
187 | jint32_t ino; /* inode number */ | ||
188 | jint32_t xid; /* XATTR identifier number */ | ||
189 | jint32_t node_crc; | ||
152 | } __attribute__((packed)); | 190 | } __attribute__((packed)); |
153 | 191 | ||
154 | struct jffs2_raw_summary | 192 | struct jffs2_raw_summary |
@@ -163,14 +201,22 @@ struct jffs2_raw_summary | |||
163 | jint32_t sum_crc; /* summary information crc */ | 201 | jint32_t sum_crc; /* summary information crc */ |
164 | jint32_t node_crc; /* node crc */ | 202 | jint32_t node_crc; /* node crc */ |
165 | jint32_t sum[0]; /* inode summary info */ | 203 | jint32_t sum[0]; /* inode summary info */ |
166 | } __attribute__((packed)); | 204 | }; |
167 | 205 | ||
168 | union jffs2_node_union | 206 | union jffs2_node_union |
169 | { | 207 | { |
170 | struct jffs2_raw_inode i; | 208 | struct jffs2_raw_inode i; |
171 | struct jffs2_raw_dirent d; | 209 | struct jffs2_raw_dirent d; |
210 | struct jffs2_raw_xattr x; | ||
211 | struct jffs2_raw_xref r; | ||
172 | struct jffs2_raw_summary s; | 212 | struct jffs2_raw_summary s; |
173 | struct jffs2_unknown_node u; | 213 | struct jffs2_unknown_node u; |
174 | }; | 214 | }; |
175 | 215 | ||
216 | /* Data payload for device nodes. */ | ||
217 | union jffs2_device_node { | ||
218 | jint16_t old; | ||
219 | jint32_t new; | ||
220 | }; | ||
221 | |||
176 | #endif /* __LINUX_JFFS2_H__ */ | 222 | #endif /* __LINUX_JFFS2_H__ */ |
diff --git a/include/linux/jffs2_fs_i.h b/include/linux/jffs2_fs_i.h deleted file mode 100644 index ad565bf9dcc1..000000000000 --- a/include/linux/jffs2_fs_i.h +++ /dev/null | |||
@@ -1,50 +0,0 @@ | |||
1 | /* $Id: jffs2_fs_i.h,v 1.19 2005/11/07 11:14:52 gleixner Exp $ */ | ||
2 | |||
3 | #ifndef _JFFS2_FS_I | ||
4 | #define _JFFS2_FS_I | ||
5 | |||
6 | #include <linux/version.h> | ||
7 | #include <linux/rbtree.h> | ||
8 | #include <asm/semaphore.h> | ||
9 | |||
10 | struct jffs2_inode_info { | ||
11 | /* We need an internal mutex similar to inode->i_mutex. | ||
12 | Unfortunately, we can't used the existing one, because | ||
13 | either the GC would deadlock, or we'd have to release it | ||
14 | before letting GC proceed. Or we'd have to put ugliness | ||
15 | into the GC code so it didn't attempt to obtain the i_mutex | ||
16 | for the inode(s) which are already locked */ | ||
17 | struct semaphore sem; | ||
18 | |||
19 | /* The highest (datanode) version number used for this ino */ | ||
20 | uint32_t highest_version; | ||
21 | |||
22 | /* List of data fragments which make up the file */ | ||
23 | struct rb_root fragtree; | ||
24 | |||
25 | /* There may be one datanode which isn't referenced by any of the | ||
26 | above fragments, if it contains a metadata update but no actual | ||
27 | data - or if this is a directory inode */ | ||
28 | /* This also holds the _only_ dnode for symlinks/device nodes, | ||
29 | etc. */ | ||
30 | struct jffs2_full_dnode *metadata; | ||
31 | |||
32 | /* Directory entries */ | ||
33 | struct jffs2_full_dirent *dents; | ||
34 | |||
35 | /* The target path if this is the inode of a symlink */ | ||
36 | unsigned char *target; | ||
37 | |||
38 | /* Some stuff we just have to keep in-core at all times, for each inode. */ | ||
39 | struct jffs2_inode_cache *inocache; | ||
40 | |||
41 | uint16_t flags; | ||
42 | uint8_t usercompr; | ||
43 | #if !defined (__ECOS) | ||
44 | #if LINUX_VERSION_CODE > KERNEL_VERSION(2,5,2) | ||
45 | struct inode vfs_inode; | ||
46 | #endif | ||
47 | #endif | ||
48 | }; | ||
49 | |||
50 | #endif /* _JFFS2_FS_I */ | ||
diff --git a/include/linux/jffs2_fs_sb.h b/include/linux/jffs2_fs_sb.h deleted file mode 100644 index 4bcfb5570221..000000000000 --- a/include/linux/jffs2_fs_sb.h +++ /dev/null | |||
@@ -1,122 +0,0 @@ | |||
1 | /* $Id: jffs2_fs_sb.h,v 1.54 2005/09/21 13:37:34 dedekind Exp $ */ | ||
2 | |||
3 | #ifndef _JFFS2_FS_SB | ||
4 | #define _JFFS2_FS_SB | ||
5 | |||
6 | #include <linux/types.h> | ||
7 | #include <linux/spinlock.h> | ||
8 | #include <linux/workqueue.h> | ||
9 | #include <linux/completion.h> | ||
10 | #include <asm/semaphore.h> | ||
11 | #include <linux/timer.h> | ||
12 | #include <linux/wait.h> | ||
13 | #include <linux/list.h> | ||
14 | #include <linux/rwsem.h> | ||
15 | |||
16 | #define JFFS2_SB_FLAG_RO 1 | ||
17 | #define JFFS2_SB_FLAG_SCANNING 2 /* Flash scanning is in progress */ | ||
18 | #define JFFS2_SB_FLAG_BUILDING 4 /* File system building is in progress */ | ||
19 | |||
20 | struct jffs2_inodirty; | ||
21 | |||
22 | /* A struct for the overall file system control. Pointers to | ||
23 | jffs2_sb_info structs are named `c' in the source code. | ||
24 | Nee jffs_control | ||
25 | */ | ||
26 | struct jffs2_sb_info { | ||
27 | struct mtd_info *mtd; | ||
28 | |||
29 | uint32_t highest_ino; | ||
30 | uint32_t checked_ino; | ||
31 | |||
32 | unsigned int flags; | ||
33 | |||
34 | struct task_struct *gc_task; /* GC task struct */ | ||
35 | struct completion gc_thread_start; /* GC thread start completion */ | ||
36 | struct completion gc_thread_exit; /* GC thread exit completion port */ | ||
37 | |||
38 | struct semaphore alloc_sem; /* Used to protect all the following | ||
39 | fields, and also to protect against | ||
40 | out-of-order writing of nodes. And GC. */ | ||
41 | uint32_t cleanmarker_size; /* Size of an _inline_ CLEANMARKER | ||
42 | (i.e. zero for OOB CLEANMARKER */ | ||
43 | |||
44 | uint32_t flash_size; | ||
45 | uint32_t used_size; | ||
46 | uint32_t dirty_size; | ||
47 | uint32_t wasted_size; | ||
48 | uint32_t free_size; | ||
49 | uint32_t erasing_size; | ||
50 | uint32_t bad_size; | ||
51 | uint32_t sector_size; | ||
52 | uint32_t unchecked_size; | ||
53 | |||
54 | uint32_t nr_free_blocks; | ||
55 | uint32_t nr_erasing_blocks; | ||
56 | |||
57 | /* Number of free blocks there must be before we... */ | ||
58 | uint8_t resv_blocks_write; /* ... allow a normal filesystem write */ | ||
59 | uint8_t resv_blocks_deletion; /* ... allow a normal filesystem deletion */ | ||
60 | uint8_t resv_blocks_gctrigger; /* ... wake up the GC thread */ | ||
61 | uint8_t resv_blocks_gcbad; /* ... pick a block from the bad_list to GC */ | ||
62 | uint8_t resv_blocks_gcmerge; /* ... merge pages when garbage collecting */ | ||
63 | |||
64 | uint32_t nospc_dirty_size; | ||
65 | |||
66 | uint32_t nr_blocks; | ||
67 | struct jffs2_eraseblock *blocks; /* The whole array of blocks. Used for getting blocks | ||
68 | * from the offset (blocks[ofs / sector_size]) */ | ||
69 | struct jffs2_eraseblock *nextblock; /* The block we're currently filling */ | ||
70 | |||
71 | struct jffs2_eraseblock *gcblock; /* The block we're currently garbage-collecting */ | ||
72 | |||
73 | struct list_head clean_list; /* Blocks 100% full of clean data */ | ||
74 | struct list_head very_dirty_list; /* Blocks with lots of dirty space */ | ||
75 | struct list_head dirty_list; /* Blocks with some dirty space */ | ||
76 | struct list_head erasable_list; /* Blocks which are completely dirty, and need erasing */ | ||
77 | struct list_head erasable_pending_wbuf_list; /* Blocks which need erasing but only after the current wbuf is flushed */ | ||
78 | struct list_head erasing_list; /* Blocks which are currently erasing */ | ||
79 | struct list_head erase_pending_list; /* Blocks which need erasing now */ | ||
80 | struct list_head erase_complete_list; /* Blocks which are erased and need the clean marker written to them */ | ||
81 | struct list_head free_list; /* Blocks which are free and ready to be used */ | ||
82 | struct list_head bad_list; /* Bad blocks. */ | ||
83 | struct list_head bad_used_list; /* Bad blocks with valid data in. */ | ||
84 | |||
85 | spinlock_t erase_completion_lock; /* Protect free_list and erasing_list | ||
86 | against erase completion handler */ | ||
87 | wait_queue_head_t erase_wait; /* For waiting for erases to complete */ | ||
88 | |||
89 | wait_queue_head_t inocache_wq; | ||
90 | struct jffs2_inode_cache **inocache_list; | ||
91 | spinlock_t inocache_lock; | ||
92 | |||
93 | /* Sem to allow jffs2_garbage_collect_deletion_dirent to | ||
94 | drop the erase_completion_lock while it's holding a pointer | ||
95 | to an obsoleted node. I don't like this. Alternatives welcomed. */ | ||
96 | struct semaphore erase_free_sem; | ||
97 | |||
98 | uint32_t wbuf_pagesize; /* 0 for NOR and other flashes with no wbuf */ | ||
99 | |||
100 | #ifdef CONFIG_JFFS2_FS_WRITEBUFFER | ||
101 | /* Write-behind buffer for NAND flash */ | ||
102 | unsigned char *wbuf; | ||
103 | uint32_t wbuf_ofs; | ||
104 | uint32_t wbuf_len; | ||
105 | struct jffs2_inodirty *wbuf_inodes; | ||
106 | |||
107 | struct rw_semaphore wbuf_sem; /* Protects the write buffer */ | ||
108 | |||
109 | /* Information about out-of-band area usage... */ | ||
110 | struct nand_oobinfo *oobinfo; | ||
111 | uint32_t badblock_pos; | ||
112 | uint32_t fsdata_pos; | ||
113 | uint32_t fsdata_len; | ||
114 | #endif | ||
115 | |||
116 | struct jffs2_summary *summary; /* Summary information */ | ||
117 | |||
118 | /* OS-private pointer for getting back to master superblock info */ | ||
119 | void *os_priv; | ||
120 | }; | ||
121 | |||
122 | #endif /* _JFFS2_FB_SB */ | ||
diff --git a/include/linux/joystick.h b/include/linux/joystick.h index 5fd20ddd7ae3..e2d3a18af456 100644 --- a/include/linux/joystick.h +++ b/include/linux/joystick.h | |||
@@ -111,25 +111,25 @@ struct js_corr { | |||
111 | #define JS_SET_ALL 8 | 111 | #define JS_SET_ALL 8 |
112 | 112 | ||
113 | struct JS_DATA_TYPE { | 113 | struct JS_DATA_TYPE { |
114 | int32_t buttons; | 114 | __s32 buttons; |
115 | int32_t x; | 115 | __s32 x; |
116 | int32_t y; | 116 | __s32 y; |
117 | }; | 117 | }; |
118 | 118 | ||
119 | struct JS_DATA_SAVE_TYPE_32 { | 119 | struct JS_DATA_SAVE_TYPE_32 { |
120 | int32_t JS_TIMEOUT; | 120 | __s32 JS_TIMEOUT; |
121 | int32_t BUSY; | 121 | __s32 BUSY; |
122 | int32_t JS_EXPIRETIME; | 122 | __s32 JS_EXPIRETIME; |
123 | int32_t JS_TIMELIMIT; | 123 | __s32 JS_TIMELIMIT; |
124 | struct JS_DATA_TYPE JS_SAVE; | 124 | struct JS_DATA_TYPE JS_SAVE; |
125 | struct JS_DATA_TYPE JS_CORR; | 125 | struct JS_DATA_TYPE JS_CORR; |
126 | }; | 126 | }; |
127 | 127 | ||
128 | struct JS_DATA_SAVE_TYPE_64 { | 128 | struct JS_DATA_SAVE_TYPE_64 { |
129 | int32_t JS_TIMEOUT; | 129 | __s32 JS_TIMEOUT; |
130 | int32_t BUSY; | 130 | __s32 BUSY; |
131 | int64_t JS_EXPIRETIME; | 131 | __s64 JS_EXPIRETIME; |
132 | int64_t JS_TIMELIMIT; | 132 | __s64 JS_TIMELIMIT; |
133 | struct JS_DATA_TYPE JS_SAVE; | 133 | struct JS_DATA_TYPE JS_SAVE; |
134 | struct JS_DATA_TYPE JS_CORR; | 134 | struct JS_DATA_TYPE JS_CORR; |
135 | }; | 135 | }; |
diff --git a/include/linux/kallsyms.h b/include/linux/kallsyms.h index 9bbd04092365..54e2549f96ba 100644 --- a/include/linux/kallsyms.h +++ b/include/linux/kallsyms.h | |||
@@ -5,7 +5,6 @@ | |||
5 | #ifndef _LINUX_KALLSYMS_H | 5 | #ifndef _LINUX_KALLSYMS_H |
6 | #define _LINUX_KALLSYMS_H | 6 | #define _LINUX_KALLSYMS_H |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | 8 | ||
10 | #define KSYM_NAME_LEN 127 | 9 | #define KSYM_NAME_LEN 127 |
11 | 10 | ||
diff --git a/include/linux/kernel_stat.h b/include/linux/kernel_stat.h index b46249082cca..43e895f1cabe 100644 --- a/include/linux/kernel_stat.h +++ b/include/linux/kernel_stat.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _LINUX_KERNEL_STAT_H | 1 | #ifndef _LINUX_KERNEL_STAT_H |
2 | #define _LINUX_KERNEL_STAT_H | 2 | #define _LINUX_KERNEL_STAT_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/irq.h> | 4 | #include <asm/irq.h> |
6 | #include <linux/smp.h> | 5 | #include <linux/smp.h> |
7 | #include <linux/threads.h> | 6 | #include <linux/threads.h> |
diff --git a/include/linux/key.h b/include/linux/key.h index cbf464ad9589..e81ebf910d0b 100644 --- a/include/linux/key.h +++ b/include/linux/key.h | |||
@@ -205,6 +205,11 @@ struct key_type { | |||
205 | /* match a key against a description */ | 205 | /* match a key against a description */ |
206 | int (*match)(const struct key *key, const void *desc); | 206 | int (*match)(const struct key *key, const void *desc); |
207 | 207 | ||
208 | /* clear some of the data from a key on revokation (optional) | ||
209 | * - the key's semaphore will be write-locked by the caller | ||
210 | */ | ||
211 | void (*revoke)(struct key *key); | ||
212 | |||
208 | /* clear the data from a key (optional) */ | 213 | /* clear the data from a key (optional) */ |
209 | void (*destroy)(struct key *key); | 214 | void (*destroy)(struct key *key); |
210 | 215 | ||
@@ -241,8 +246,9 @@ extern void unregister_key_type(struct key_type *ktype); | |||
241 | 246 | ||
242 | extern struct key *key_alloc(struct key_type *type, | 247 | extern struct key *key_alloc(struct key_type *type, |
243 | const char *desc, | 248 | const char *desc, |
244 | uid_t uid, gid_t gid, key_perm_t perm, | 249 | uid_t uid, gid_t gid, |
245 | int not_in_quota); | 250 | struct task_struct *ctx, |
251 | key_perm_t perm, int not_in_quota); | ||
246 | extern int key_payload_reserve(struct key *key, size_t datalen); | 252 | extern int key_payload_reserve(struct key *key, size_t datalen); |
247 | extern int key_instantiate_and_link(struct key *key, | 253 | extern int key_instantiate_and_link(struct key *key, |
248 | const void *data, | 254 | const void *data, |
@@ -292,7 +298,9 @@ extern int key_unlink(struct key *keyring, | |||
292 | struct key *key); | 298 | struct key *key); |
293 | 299 | ||
294 | extern struct key *keyring_alloc(const char *description, uid_t uid, gid_t gid, | 300 | extern struct key *keyring_alloc(const char *description, uid_t uid, gid_t gid, |
295 | int not_in_quota, struct key *dest); | 301 | struct task_struct *ctx, |
302 | int not_in_quota, | ||
303 | struct key *dest); | ||
296 | 304 | ||
297 | extern int keyring_clear(struct key *keyring); | 305 | extern int keyring_clear(struct key *keyring); |
298 | 306 | ||
@@ -313,7 +321,8 @@ extern void keyring_replace_payload(struct key *key, void *replacement); | |||
313 | * the userspace interface | 321 | * the userspace interface |
314 | */ | 322 | */ |
315 | extern struct key root_user_keyring, root_session_keyring; | 323 | extern struct key root_user_keyring, root_session_keyring; |
316 | extern int alloc_uid_keyring(struct user_struct *user); | 324 | extern int alloc_uid_keyring(struct user_struct *user, |
325 | struct task_struct *ctx); | ||
317 | extern void switch_uid_keyring(struct user_struct *new_user); | 326 | extern void switch_uid_keyring(struct user_struct *new_user); |
318 | extern int copy_keys(unsigned long clone_flags, struct task_struct *tsk); | 327 | extern int copy_keys(unsigned long clone_flags, struct task_struct *tsk); |
319 | extern int copy_thread_group_keys(struct task_struct *tsk); | 328 | extern int copy_thread_group_keys(struct task_struct *tsk); |
@@ -342,7 +351,7 @@ extern void key_init(void); | |||
342 | #define make_key_ref(k) ({ NULL; }) | 351 | #define make_key_ref(k) ({ NULL; }) |
343 | #define key_ref_to_ptr(k) ({ NULL; }) | 352 | #define key_ref_to_ptr(k) ({ NULL; }) |
344 | #define is_key_possessed(k) 0 | 353 | #define is_key_possessed(k) 0 |
345 | #define alloc_uid_keyring(u) 0 | 354 | #define alloc_uid_keyring(u,c) 0 |
346 | #define switch_uid_keyring(u) do { } while(0) | 355 | #define switch_uid_keyring(u) do { } while(0) |
347 | #define __install_session_keyring(t, k) ({ NULL; }) | 356 | #define __install_session_keyring(t, k) ({ NULL; }) |
348 | #define copy_keys(f,t) 0 | 357 | #define copy_keys(f,t) 0 |
@@ -355,6 +364,10 @@ extern void key_init(void); | |||
355 | #define key_fsgid_changed(t) do { } while(0) | 364 | #define key_fsgid_changed(t) do { } while(0) |
356 | #define key_init() do { } while(0) | 365 | #define key_init() do { } while(0) |
357 | 366 | ||
367 | /* Initial keyrings */ | ||
368 | extern struct key root_user_keyring; | ||
369 | extern struct key root_session_keyring; | ||
370 | |||
358 | #endif /* CONFIG_KEYS */ | 371 | #endif /* CONFIG_KEYS */ |
359 | #endif /* __KERNEL__ */ | 372 | #endif /* __KERNEL__ */ |
360 | #endif /* _LINUX_KEY_H */ | 373 | #endif /* _LINUX_KEY_H */ |
diff --git a/include/linux/kmod.h b/include/linux/kmod.h index e4a231549407..0db22a1ab474 100644 --- a/include/linux/kmod.h +++ b/include/linux/kmod.h | |||
@@ -20,7 +20,6 @@ | |||
20 | */ | 20 | */ |
21 | 21 | ||
22 | #include <linux/stddef.h> | 22 | #include <linux/stddef.h> |
23 | #include <linux/config.h> | ||
24 | #include <linux/errno.h> | 23 | #include <linux/errno.h> |
25 | #include <linux/compiler.h> | 24 | #include <linux/compiler.h> |
26 | 25 | ||
diff --git a/include/linux/kobject.h b/include/linux/kobject.h index c187c53cecd0..2d229327959e 100644 --- a/include/linux/kobject.h +++ b/include/linux/kobject.h | |||
@@ -190,6 +190,8 @@ struct subsystem _varname##_subsys = { \ | |||
190 | 190 | ||
191 | /* The global /sys/kernel/ subsystem for people to chain off of */ | 191 | /* The global /sys/kernel/ subsystem for people to chain off of */ |
192 | extern struct subsystem kernel_subsys; | 192 | extern struct subsystem kernel_subsys; |
193 | /* The global /sys/hypervisor/ subsystem */ | ||
194 | extern struct subsystem hypervisor_subsys; | ||
193 | 195 | ||
194 | /** | 196 | /** |
195 | * Helpers for setting the kset of registered objects. | 197 | * Helpers for setting the kset of registered objects. |
diff --git a/include/linux/kprobes.h b/include/linux/kprobes.h index 778adc0fa640..8bf6702da2a0 100644 --- a/include/linux/kprobes.h +++ b/include/linux/kprobes.h | |||
@@ -29,7 +29,6 @@ | |||
29 | * <jkenisto@us.ibm.com> and Prasanna S Panchamukhi | 29 | * <jkenisto@us.ibm.com> and Prasanna S Panchamukhi |
30 | * <prasanna@in.ibm.com> added function-return probes. | 30 | * <prasanna@in.ibm.com> added function-return probes. |
31 | */ | 31 | */ |
32 | #include <linux/config.h> | ||
33 | #include <linux/list.h> | 32 | #include <linux/list.h> |
34 | #include <linux/notifier.h> | 33 | #include <linux/notifier.h> |
35 | #include <linux/smp.h> | 34 | #include <linux/smp.h> |
diff --git a/include/linux/linkage.h b/include/linux/linkage.h index c08c9983e840..932021f872d5 100644 --- a/include/linux/linkage.h +++ b/include/linux/linkage.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _LINUX_LINKAGE_H | 1 | #ifndef _LINUX_LINKAGE_H |
2 | #define _LINUX_LINKAGE_H | 2 | #define _LINUX_LINKAGE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <asm/linkage.h> | 4 | #include <asm/linkage.h> |
6 | 5 | ||
7 | #ifdef __cplusplus | 6 | #ifdef __cplusplus |
diff --git a/include/linux/lockd/lockd.h b/include/linux/lockd/lockd.h index 995f89dc8c04..a8876bc6513b 100644 --- a/include/linux/lockd/lockd.h +++ b/include/linux/lockd/lockd.h | |||
@@ -11,7 +11,6 @@ | |||
11 | 11 | ||
12 | #ifdef __KERNEL__ | 12 | #ifdef __KERNEL__ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/in.h> | 14 | #include <linux/in.h> |
16 | #include <linux/fs.h> | 15 | #include <linux/fs.h> |
17 | #include <linux/kref.h> | 16 | #include <linux/kref.h> |
diff --git a/include/linux/lockd/nlm.h b/include/linux/lockd/nlm.h index 869b630cba24..d9d46e442538 100644 --- a/include/linux/lockd/nlm.h +++ b/include/linux/lockd/nlm.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef LINUX_LOCKD_NLM_H | 9 | #ifndef LINUX_LOCKD_NLM_H |
10 | #define LINUX_LOCKD_NLM_H | 10 | #define LINUX_LOCKD_NLM_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | /* Maximum file offset in file_lock.fl_end */ | 13 | /* Maximum file offset in file_lock.fl_end */ |
15 | # define NLM_OFFSET_MAX ((s32) 0x7fffffff) | 14 | # define NLM_OFFSET_MAX ((s32) 0x7fffffff) |
diff --git a/include/linux/m41t00.h b/include/linux/m41t00.h new file mode 100644 index 000000000000..b423360ca38e --- /dev/null +++ b/include/linux/m41t00.h | |||
@@ -0,0 +1,50 @@ | |||
1 | /* | ||
2 | * Definitions for the ST M41T00 family of i2c rtc chips. | ||
3 | * | ||
4 | * Author: Mark A. Greer <mgreer@mvista.com> | ||
5 | * | ||
6 | * 2005, 2006 (c) MontaVista Software, Inc. This file is licensed under | ||
7 | * the terms of the GNU General Public License version 2. This program | ||
8 | * is licensed "as is" without any warranty of any kind, whether express | ||
9 | * or implied. | ||
10 | */ | ||
11 | |||
12 | #ifndef _M41T00_H | ||
13 | #define _M41T00_H | ||
14 | |||
15 | #define M41T00_DRV_NAME "m41t00" | ||
16 | #define M41T00_I2C_ADDR 0x68 | ||
17 | |||
18 | #define M41T00_TYPE_M41T00 0 | ||
19 | #define M41T00_TYPE_M41T81 81 | ||
20 | #define M41T00_TYPE_M41T85 85 | ||
21 | |||
22 | struct m41t00_platform_data { | ||
23 | u8 type; | ||
24 | u8 i2c_addr; | ||
25 | u8 sqw_freq; | ||
26 | }; | ||
27 | |||
28 | /* SQW output disabled, this is default value by power on */ | ||
29 | #define M41T00_SQW_DISABLE (0) | ||
30 | |||
31 | #define M41T00_SQW_32KHZ (1<<4) /* 32.768 KHz */ | ||
32 | #define M41T00_SQW_8KHZ (2<<4) /* 8.192 KHz */ | ||
33 | #define M41T00_SQW_4KHZ (3<<4) /* 4.096 KHz */ | ||
34 | #define M41T00_SQW_2KHZ (4<<4) /* 2.048 KHz */ | ||
35 | #define M41T00_SQW_1KHZ (5<<4) /* 1.024 KHz */ | ||
36 | #define M41T00_SQW_512HZ (6<<4) /* 512 Hz */ | ||
37 | #define M41T00_SQW_256HZ (7<<4) /* 256 Hz */ | ||
38 | #define M41T00_SQW_128HZ (8<<4) /* 128 Hz */ | ||
39 | #define M41T00_SQW_64HZ (9<<4) /* 64 Hz */ | ||
40 | #define M41T00_SQW_32HZ (10<<4) /* 32 Hz */ | ||
41 | #define M41T00_SQW_16HZ (11<<4) /* 16 Hz */ | ||
42 | #define M41T00_SQW_8HZ (12<<4) /* 8 Hz */ | ||
43 | #define M41T00_SQW_4HZ (13<<4) /* 4 Hz */ | ||
44 | #define M41T00_SQW_2HZ (14<<4) /* 2 Hz */ | ||
45 | #define M41T00_SQW_1HZ (15<<4) /* 1 Hz */ | ||
46 | |||
47 | extern ulong m41t00_get_rtc_time(void); | ||
48 | extern int m41t00_set_rtc_time(ulong nowtime); | ||
49 | |||
50 | #endif /* _M41T00_H */ | ||
diff --git a/include/linux/mempolicy.h b/include/linux/mempolicy.h index f5fdca1d67e6..72440f0a443d 100644 --- a/include/linux/mempolicy.h +++ b/include/linux/mempolicy.h | |||
@@ -28,7 +28,6 @@ | |||
28 | 28 | ||
29 | #ifdef __KERNEL__ | 29 | #ifdef __KERNEL__ |
30 | 30 | ||
31 | #include <linux/config.h> | ||
32 | #include <linux/mmzone.h> | 31 | #include <linux/mmzone.h> |
33 | #include <linux/slab.h> | 32 | #include <linux/slab.h> |
34 | #include <linux/rbtree.h> | 33 | #include <linux/rbtree.h> |
diff --git a/include/linux/migrate.h b/include/linux/migrate.h index ff0a64073ebc..6789c4940c9c 100644 --- a/include/linux/migrate.h +++ b/include/linux/migrate.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _LINUX_MIGRATE_H | 1 | #ifndef _LINUX_MIGRATE_H |
2 | #define _LINUX_MIGRATE_H | 2 | #define _LINUX_MIGRATE_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | 4 | #include <linux/mm.h> |
6 | 5 | ||
7 | #ifdef CONFIG_MIGRATION | 6 | #ifdef CONFIG_MIGRATION |
diff --git a/include/linux/mii.h b/include/linux/mii.h index 68f5a0f392dd..beddc6d3b0f6 100644 --- a/include/linux/mii.h +++ b/include/linux/mii.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #define __LINUX_MII_H__ | 9 | #define __LINUX_MII_H__ |
10 | 10 | ||
11 | #include <linux/types.h> | 11 | #include <linux/types.h> |
12 | #include <linux/if.h> | ||
13 | 12 | ||
14 | /* Generic MII registers. */ | 13 | /* Generic MII registers. */ |
15 | 14 | ||
@@ -136,6 +135,20 @@ | |||
136 | #define LPA_1000FULL 0x0800 /* Link partner 1000BASE-T full duplex */ | 135 | #define LPA_1000FULL 0x0800 /* Link partner 1000BASE-T full duplex */ |
137 | #define LPA_1000HALF 0x0400 /* Link partner 1000BASE-T half duplex */ | 136 | #define LPA_1000HALF 0x0400 /* Link partner 1000BASE-T half duplex */ |
138 | 137 | ||
138 | /* This structure is used in all SIOCxMIIxxx ioctl calls */ | ||
139 | struct mii_ioctl_data { | ||
140 | __u16 phy_id; | ||
141 | __u16 reg_num; | ||
142 | __u16 val_in; | ||
143 | __u16 val_out; | ||
144 | }; | ||
145 | |||
146 | #ifdef __KERNEL__ | ||
147 | |||
148 | #include <linux/if.h> | ||
149 | |||
150 | struct ethtool_cmd; | ||
151 | |||
139 | struct mii_if_info { | 152 | struct mii_if_info { |
140 | int phy_id; | 153 | int phy_id; |
141 | int advertising; | 154 | int advertising; |
@@ -151,9 +164,6 @@ struct mii_if_info { | |||
151 | void (*mdio_write) (struct net_device *dev, int phy_id, int location, int val); | 164 | void (*mdio_write) (struct net_device *dev, int phy_id, int location, int val); |
152 | }; | 165 | }; |
153 | 166 | ||
154 | struct ethtool_cmd; | ||
155 | struct mii_ioctl_data; | ||
156 | |||
157 | extern int mii_link_ok (struct mii_if_info *mii); | 167 | extern int mii_link_ok (struct mii_if_info *mii); |
158 | extern int mii_nway_restart (struct mii_if_info *mii); | 168 | extern int mii_nway_restart (struct mii_if_info *mii); |
159 | extern int mii_ethtool_gset(struct mii_if_info *mii, struct ethtool_cmd *ecmd); | 169 | extern int mii_ethtool_gset(struct mii_if_info *mii, struct ethtool_cmd *ecmd); |
@@ -168,16 +178,6 @@ extern int generic_mii_ioctl(struct mii_if_info *mii_if, | |||
168 | unsigned int *duplex_changed); | 178 | unsigned int *duplex_changed); |
169 | 179 | ||
170 | 180 | ||
171 | |||
172 | /* This structure is used in all SIOCxMIIxxx ioctl calls */ | ||
173 | struct mii_ioctl_data { | ||
174 | u16 phy_id; | ||
175 | u16 reg_num; | ||
176 | u16 val_in; | ||
177 | u16 val_out; | ||
178 | }; | ||
179 | |||
180 | |||
181 | static inline struct mii_ioctl_data *if_mii(struct ifreq *rq) | 181 | static inline struct mii_ioctl_data *if_mii(struct ifreq *rq) |
182 | { | 182 | { |
183 | return (struct mii_ioctl_data *) &rq->ifr_ifru; | 183 | return (struct mii_ioctl_data *) &rq->ifr_ifru; |
@@ -235,5 +235,5 @@ static inline unsigned int mii_duplex (unsigned int duplex_lock, | |||
235 | return 0; | 235 | return 0; |
236 | } | 236 | } |
237 | 237 | ||
238 | 238 | #endif /* __KERNEL__ */ | |
239 | #endif /* __LINUX_MII_H__ */ | 239 | #endif /* __LINUX_MII_H__ */ |
diff --git a/include/linux/mm.h b/include/linux/mm.h index 1154684209a4..e2fa375e478e 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h | |||
@@ -7,7 +7,6 @@ | |||
7 | 7 | ||
8 | #ifdef __KERNEL__ | 8 | #ifdef __KERNEL__ |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <linux/gfp.h> | 10 | #include <linux/gfp.h> |
12 | #include <linux/list.h> | 11 | #include <linux/list.h> |
13 | #include <linux/mmzone.h> | 12 | #include <linux/mmzone.h> |
diff --git a/include/linux/mman.h b/include/linux/mman.h index 18a5689ef748..87920a0852a3 100644 --- a/include/linux/mman.h +++ b/include/linux/mman.h | |||
@@ -1,10 +1,6 @@ | |||
1 | #ifndef _LINUX_MMAN_H | 1 | #ifndef _LINUX_MMAN_H |
2 | #define _LINUX_MMAN_H | 2 | #define _LINUX_MMAN_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/mm.h> | ||
6 | |||
7 | #include <asm/atomic.h> | ||
8 | #include <asm/mman.h> | 4 | #include <asm/mman.h> |
9 | 5 | ||
10 | #define MREMAP_MAYMOVE 1 | 6 | #define MREMAP_MAYMOVE 1 |
@@ -13,6 +9,12 @@ | |||
13 | #define OVERCOMMIT_GUESS 0 | 9 | #define OVERCOMMIT_GUESS 0 |
14 | #define OVERCOMMIT_ALWAYS 1 | 10 | #define OVERCOMMIT_ALWAYS 1 |
15 | #define OVERCOMMIT_NEVER 2 | 11 | #define OVERCOMMIT_NEVER 2 |
12 | |||
13 | #ifdef __KERNEL__ | ||
14 | #include <linux/mm.h> | ||
15 | |||
16 | #include <asm/atomic.h> | ||
17 | |||
16 | extern int sysctl_overcommit_memory; | 18 | extern int sysctl_overcommit_memory; |
17 | extern int sysctl_overcommit_ratio; | 19 | extern int sysctl_overcommit_ratio; |
18 | extern atomic_t vm_committed_space; | 20 | extern atomic_t vm_committed_space; |
@@ -63,5 +65,5 @@ calc_vm_flag_bits(unsigned long flags) | |||
63 | _calc_vm_trans(flags, MAP_EXECUTABLE, VM_EXECUTABLE) | | 65 | _calc_vm_trans(flags, MAP_EXECUTABLE, VM_EXECUTABLE) | |
64 | _calc_vm_trans(flags, MAP_LOCKED, VM_LOCKED ); | 66 | _calc_vm_trans(flags, MAP_LOCKED, VM_LOCKED ); |
65 | } | 67 | } |
66 | 68 | #endif /* __KERNEL__ */ | |
67 | #endif /* _LINUX_MMAN_H */ | 69 | #endif /* _LINUX_MMAN_H */ |
diff --git a/include/linux/mmzone.h b/include/linux/mmzone.h index 2d8337150493..9742e3c16222 100644 --- a/include/linux/mmzone.h +++ b/include/linux/mmzone.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | #ifndef __ASSEMBLY__ | 5 | #ifndef __ASSEMBLY__ |
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | #include <linux/spinlock.h> | 7 | #include <linux/spinlock.h> |
9 | #include <linux/list.h> | 8 | #include <linux/list.h> |
10 | #include <linux/wait.h> | 9 | #include <linux/wait.h> |
diff --git a/include/linux/module.h b/include/linux/module.h index eaec13ddd667..c2d89e037af0 100644 --- a/include/linux/module.h +++ b/include/linux/module.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * Rewritten by Richard Henderson <rth@tamu.edu> Dec 1996 | 6 | * Rewritten by Richard Henderson <rth@tamu.edu> Dec 1996 |
7 | * Rewritten again by Rusty Russell, 2002 | 7 | * Rewritten again by Rusty Russell, 2002 |
8 | */ | 8 | */ |
9 | #include <linux/config.h> | ||
10 | #include <linux/sched.h> | 9 | #include <linux/sched.h> |
11 | #include <linux/spinlock.h> | 10 | #include <linux/spinlock.h> |
12 | #include <linux/list.h> | 11 | #include <linux/list.h> |
@@ -557,13 +556,4 @@ static inline void module_remove_driver(struct device_driver *driver) | |||
557 | 556 | ||
558 | #define __MODULE_STRING(x) __stringify(x) | 557 | #define __MODULE_STRING(x) __stringify(x) |
559 | 558 | ||
560 | /* Use symbol_get and symbol_put instead. You'll thank me. */ | ||
561 | #define HAVE_INTER_MODULE | ||
562 | extern void __deprecated inter_module_register(const char *, | ||
563 | struct module *, const void *); | ||
564 | extern void __deprecated inter_module_unregister(const char *); | ||
565 | extern const void * __deprecated inter_module_get_request(const char *, | ||
566 | const char *); | ||
567 | extern void __deprecated inter_module_put(const char *); | ||
568 | |||
569 | #endif /* _LINUX_MODULE_H */ | 559 | #endif /* _LINUX_MODULE_H */ |
diff --git a/include/linux/msg.h b/include/linux/msg.h index 903e0ab8101f..acc7c174ff00 100644 --- a/include/linux/msg.h +++ b/include/linux/msg.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define _LINUX_MSG_H | 2 | #define _LINUX_MSG_H |
3 | 3 | ||
4 | #include <linux/ipc.h> | 4 | #include <linux/ipc.h> |
5 | #include <linux/list.h> | ||
6 | 5 | ||
7 | /* ipcs ctl commands */ | 6 | /* ipcs ctl commands */ |
8 | #define MSG_STAT 11 | 7 | #define MSG_STAT 11 |
@@ -63,6 +62,7 @@ struct msginfo { | |||
63 | #define MSGSEG (__MSGSEG <= 0xffff ? __MSGSEG : 0xffff) | 62 | #define MSGSEG (__MSGSEG <= 0xffff ? __MSGSEG : 0xffff) |
64 | 63 | ||
65 | #ifdef __KERNEL__ | 64 | #ifdef __KERNEL__ |
65 | #include <linux/list.h> | ||
66 | 66 | ||
67 | /* one msg_msg structure for each message */ | 67 | /* one msg_msg structure for each message */ |
68 | struct msg_msg { | 68 | struct msg_msg { |
diff --git a/include/linux/mtd/cfi.h b/include/linux/mtd/cfi.h index 23a568910341..09bfae6938b3 100644 --- a/include/linux/mtd/cfi.h +++ b/include/linux/mtd/cfi.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef __MTD_CFI_H__ | 7 | #ifndef __MTD_CFI_H__ |
8 | #define __MTD_CFI_H__ | 8 | #define __MTD_CFI_H__ |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <linux/delay.h> | 10 | #include <linux/delay.h> |
12 | #include <linux/types.h> | 11 | #include <linux/types.h> |
13 | #include <linux/interrupt.h> | 12 | #include <linux/interrupt.h> |
diff --git a/include/linux/mtd/inftl.h b/include/linux/mtd/inftl.h index d7eaa40e5ab0..6977780e548f 100644 --- a/include/linux/mtd/inftl.h +++ b/include/linux/mtd/inftl.h | |||
@@ -46,7 +46,7 @@ struct INFTLrecord { | |||
46 | unsigned int nb_blocks; /* number of physical blocks */ | 46 | unsigned int nb_blocks; /* number of physical blocks */ |
47 | unsigned int nb_boot_blocks; /* number of blocks used by the bios */ | 47 | unsigned int nb_boot_blocks; /* number of blocks used by the bios */ |
48 | struct erase_info instr; | 48 | struct erase_info instr; |
49 | struct nand_oobinfo oobinfo; | 49 | struct nand_ecclayout oobinfo; |
50 | }; | 50 | }; |
51 | 51 | ||
52 | int INFTL_mount(struct INFTLrecord *s); | 52 | int INFTL_mount(struct INFTLrecord *s); |
diff --git a/include/linux/mtd/map.h b/include/linux/mtd/map.h index 7dfd6e1fcde7..28d461d862bd 100644 --- a/include/linux/mtd/map.h +++ b/include/linux/mtd/map.h | |||
@@ -5,7 +5,6 @@ | |||
5 | #ifndef __LINUX_MTD_MAP_H__ | 5 | #ifndef __LINUX_MTD_MAP_H__ |
6 | #define __LINUX_MTD_MAP_H__ | 6 | #define __LINUX_MTD_MAP_H__ |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | #include <linux/types.h> | 8 | #include <linux/types.h> |
10 | #include <linux/list.h> | 9 | #include <linux/list.h> |
11 | #include <linux/string.h> | 10 | #include <linux/string.h> |
diff --git a/include/linux/mtd/mtd.h b/include/linux/mtd/mtd.h index b6f2fdae65c6..9b7a2b525d63 100644 --- a/include/linux/mtd/mtd.h +++ b/include/linux/mtd/mtd.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #error This is a kernel header. Perhaps include mtd-user.h instead? | 13 | #error This is a kernel header. Perhaps include mtd-user.h instead? |
14 | #endif | 14 | #endif |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/types.h> | 16 | #include <linux/types.h> |
18 | #include <linux/module.h> | 17 | #include <linux/module.h> |
19 | #include <linux/uio.h> | 18 | #include <linux/uio.h> |
@@ -56,18 +55,69 @@ struct mtd_erase_region_info { | |||
56 | u_int32_t numblocks; /* Number of blocks of erasesize in this region */ | 55 | u_int32_t numblocks; /* Number of blocks of erasesize in this region */ |
57 | }; | 56 | }; |
58 | 57 | ||
58 | /* | ||
59 | * oob operation modes | ||
60 | * | ||
61 | * MTD_OOB_PLACE: oob data are placed at the given offset | ||
62 | * MTD_OOB_AUTO: oob data are automatically placed at the free areas | ||
63 | * which are defined by the ecclayout | ||
64 | * MTD_OOB_RAW: mode to read raw data+oob in one chunk. The oob data | ||
65 | * is inserted into the data. Thats a raw image of the | ||
66 | * flash contents. | ||
67 | */ | ||
68 | typedef enum { | ||
69 | MTD_OOB_PLACE, | ||
70 | MTD_OOB_AUTO, | ||
71 | MTD_OOB_RAW, | ||
72 | } mtd_oob_mode_t; | ||
73 | |||
74 | /** | ||
75 | * struct mtd_oob_ops - oob operation operands | ||
76 | * @mode: operation mode | ||
77 | * | ||
78 | * @len: number of bytes to write/read. When a data buffer is given | ||
79 | * (datbuf != NULL) this is the number of data bytes. When | ||
80 | + no data buffer is available this is the number of oob bytes. | ||
81 | * | ||
82 | * @retlen: number of bytes written/read. When a data buffer is given | ||
83 | * (datbuf != NULL) this is the number of data bytes. When | ||
84 | + no data buffer is available this is the number of oob bytes. | ||
85 | * | ||
86 | * @ooblen: number of oob bytes per page | ||
87 | * @ooboffs: offset of oob data in the oob area (only relevant when | ||
88 | * mode = MTD_OOB_PLACE) | ||
89 | * @datbuf: data buffer - if NULL only oob data are read/written | ||
90 | * @oobbuf: oob data buffer | ||
91 | */ | ||
92 | struct mtd_oob_ops { | ||
93 | mtd_oob_mode_t mode; | ||
94 | size_t len; | ||
95 | size_t retlen; | ||
96 | size_t ooblen; | ||
97 | uint32_t ooboffs; | ||
98 | uint8_t *datbuf; | ||
99 | uint8_t *oobbuf; | ||
100 | }; | ||
101 | |||
59 | struct mtd_info { | 102 | struct mtd_info { |
60 | u_char type; | 103 | u_char type; |
61 | u_int32_t flags; | 104 | u_int32_t flags; |
62 | u_int32_t size; // Total size of the MTD | 105 | u_int32_t size; // Total size of the MTD |
63 | 106 | ||
64 | /* "Major" erase size for the device. Naïve users may take this | 107 | /* "Major" erase size for the device. Naïve users may take this |
65 | * to be the only erase size available, or may use the more detailed | 108 | * to be the only erase size available, or may use the more detailed |
66 | * information below if they desire | 109 | * information below if they desire |
67 | */ | 110 | */ |
68 | u_int32_t erasesize; | 111 | u_int32_t erasesize; |
112 | /* Minimal writable flash unit size. In case of NOR flash it is 1 (even | ||
113 | * though individual bits can be cleared), in case of NAND flash it is | ||
114 | * one NAND page (or half, or one-fourths of it), in case of ECC-ed NOR | ||
115 | * it is of ECC block size, etc. It is illegal to have writesize = 0. | ||
116 | * Any driver registering a struct mtd_info must ensure a writesize of | ||
117 | * 1 or larger. | ||
118 | */ | ||
119 | u_int32_t writesize; | ||
69 | 120 | ||
70 | u_int32_t oobblock; // Size of OOB blocks (e.g. 512) | ||
71 | u_int32_t oobsize; // Amount of OOB data per block (e.g. 16) | 121 | u_int32_t oobsize; // Amount of OOB data per block (e.g. 16) |
72 | u_int32_t ecctype; | 122 | u_int32_t ecctype; |
73 | u_int32_t eccsize; | 123 | u_int32_t eccsize; |
@@ -79,7 +129,6 @@ struct mtd_info { | |||
79 | * MTD_PROGRAM_REGIONS flag is set. | 129 | * MTD_PROGRAM_REGIONS flag is set. |
80 | * (Maybe we should have an union for those?) | 130 | * (Maybe we should have an union for those?) |
81 | */ | 131 | */ |
82 | #define MTD_PROGREGION_SIZE(mtd) (mtd)->oobblock | ||
83 | #define MTD_PROGREGION_CTRLMODE_VALID(mtd) (mtd)->oobsize | 132 | #define MTD_PROGREGION_CTRLMODE_VALID(mtd) (mtd)->oobsize |
84 | #define MTD_PROGREGION_CTRLMODE_INVALID(mtd) (mtd)->ecctype | 133 | #define MTD_PROGREGION_CTRLMODE_INVALID(mtd) (mtd)->ecctype |
85 | 134 | ||
@@ -87,9 +136,8 @@ struct mtd_info { | |||
87 | char *name; | 136 | char *name; |
88 | int index; | 137 | int index; |
89 | 138 | ||
90 | // oobinfo is a nand_oobinfo structure, which can be set by iotcl (MEMSETOOBINFO) | 139 | /* ecc layout structure pointer - read only ! */ |
91 | struct nand_oobinfo oobinfo; | 140 | struct nand_ecclayout *ecclayout; |
92 | u_int32_t oobavail; // Number of bytes in OOB area available for fs | ||
93 | 141 | ||
94 | /* Data for variable erase regions. If numeraseregions is zero, | 142 | /* Data for variable erase regions. If numeraseregions is zero, |
95 | * it means that the whole device has erasesize as given above. | 143 | * it means that the whole device has erasesize as given above. |
@@ -112,11 +160,10 @@ struct mtd_info { | |||
112 | int (*read) (struct mtd_info *mtd, loff_t from, size_t len, size_t *retlen, u_char *buf); | 160 | int (*read) (struct mtd_info *mtd, loff_t from, size_t len, size_t *retlen, u_char *buf); |
113 | int (*write) (struct mtd_info *mtd, loff_t to, size_t len, size_t *retlen, const u_char *buf); | 161 | int (*write) (struct mtd_info *mtd, loff_t to, size_t len, size_t *retlen, const u_char *buf); |
114 | 162 | ||
115 | int (*read_ecc) (struct mtd_info *mtd, loff_t from, size_t len, size_t *retlen, u_char *buf, u_char *eccbuf, struct nand_oobinfo *oobsel); | 163 | int (*read_oob) (struct mtd_info *mtd, loff_t from, |
116 | int (*write_ecc) (struct mtd_info *mtd, loff_t to, size_t len, size_t *retlen, const u_char *buf, u_char *eccbuf, struct nand_oobinfo *oobsel); | 164 | struct mtd_oob_ops *ops); |
117 | 165 | int (*write_oob) (struct mtd_info *mtd, loff_t to, | |
118 | int (*read_oob) (struct mtd_info *mtd, loff_t from, size_t len, size_t *retlen, u_char *buf); | 166 | struct mtd_oob_ops *ops); |
119 | int (*write_oob) (struct mtd_info *mtd, loff_t to, size_t len, size_t *retlen, const u_char *buf); | ||
120 | 167 | ||
121 | /* | 168 | /* |
122 | * Methods to access the protection register area, present in some | 169 | * Methods to access the protection register area, present in some |
@@ -130,17 +177,11 @@ struct mtd_info { | |||
130 | int (*write_user_prot_reg) (struct mtd_info *mtd, loff_t from, size_t len, size_t *retlen, u_char *buf); | 177 | int (*write_user_prot_reg) (struct mtd_info *mtd, loff_t from, size_t len, size_t *retlen, u_char *buf); |
131 | int (*lock_user_prot_reg) (struct mtd_info *mtd, loff_t from, size_t len); | 178 | int (*lock_user_prot_reg) (struct mtd_info *mtd, loff_t from, size_t len); |
132 | 179 | ||
133 | /* kvec-based read/write methods. We need these especially for NAND flash, | 180 | /* kvec-based read/write methods. |
134 | with its limited number of write cycles per erase. | ||
135 | NB: The 'count' parameter is the number of _vectors_, each of | 181 | NB: The 'count' parameter is the number of _vectors_, each of |
136 | which contains an (ofs, len) tuple. | 182 | which contains an (ofs, len) tuple. |
137 | */ | 183 | */ |
138 | int (*readv) (struct mtd_info *mtd, struct kvec *vecs, unsigned long count, loff_t from, size_t *retlen); | ||
139 | int (*readv_ecc) (struct mtd_info *mtd, struct kvec *vecs, unsigned long count, loff_t from, | ||
140 | size_t *retlen, u_char *eccbuf, struct nand_oobinfo *oobsel); | ||
141 | int (*writev) (struct mtd_info *mtd, const struct kvec *vecs, unsigned long count, loff_t to, size_t *retlen); | 184 | int (*writev) (struct mtd_info *mtd, const struct kvec *vecs, unsigned long count, loff_t to, size_t *retlen); |
142 | int (*writev_ecc) (struct mtd_info *mtd, const struct kvec *vecs, unsigned long count, loff_t to, | ||
143 | size_t *retlen, u_char *eccbuf, struct nand_oobinfo *oobsel); | ||
144 | 185 | ||
145 | /* Sync */ | 186 | /* Sync */ |
146 | void (*sync) (struct mtd_info *mtd); | 187 | void (*sync) (struct mtd_info *mtd); |
@@ -159,6 +200,9 @@ struct mtd_info { | |||
159 | 200 | ||
160 | struct notifier_block reboot_notifier; /* default mode before reboot */ | 201 | struct notifier_block reboot_notifier; /* default mode before reboot */ |
161 | 202 | ||
203 | /* ECC status information */ | ||
204 | struct mtd_ecc_stats ecc_stats; | ||
205 | |||
162 | void *priv; | 206 | void *priv; |
163 | 207 | ||
164 | struct module *owner; | 208 | struct module *owner; |
@@ -192,20 +236,6 @@ int default_mtd_writev(struct mtd_info *mtd, const struct kvec *vecs, | |||
192 | int default_mtd_readv(struct mtd_info *mtd, struct kvec *vecs, | 236 | int default_mtd_readv(struct mtd_info *mtd, struct kvec *vecs, |
193 | unsigned long count, loff_t from, size_t *retlen); | 237 | unsigned long count, loff_t from, size_t *retlen); |
194 | 238 | ||
195 | #define MTD_ERASE(mtd, args...) (*(mtd->erase))(mtd, args) | ||
196 | #define MTD_POINT(mtd, a,b,c,d) (*(mtd->point))(mtd, a,b,c, (u_char **)(d)) | ||
197 | #define MTD_UNPOINT(mtd, arg) (*(mtd->unpoint))(mtd, (u_char *)arg) | ||
198 | #define MTD_READ(mtd, args...) (*(mtd->read))(mtd, args) | ||
199 | #define MTD_WRITE(mtd, args...) (*(mtd->write))(mtd, args) | ||
200 | #define MTD_READV(mtd, args...) (*(mtd->readv))(mtd, args) | ||
201 | #define MTD_WRITEV(mtd, args...) (*(mtd->writev))(mtd, args) | ||
202 | #define MTD_READECC(mtd, args...) (*(mtd->read_ecc))(mtd, args) | ||
203 | #define MTD_WRITEECC(mtd, args...) (*(mtd->write_ecc))(mtd, args) | ||
204 | #define MTD_READOOB(mtd, args...) (*(mtd->read_oob))(mtd, args) | ||
205 | #define MTD_WRITEOOB(mtd, args...) (*(mtd->write_oob))(mtd, args) | ||
206 | #define MTD_SYNC(mtd) do { if (mtd->sync) (*(mtd->sync))(mtd); } while (0) | ||
207 | |||
208 | |||
209 | #ifdef CONFIG_MTD_PARTITIONS | 239 | #ifdef CONFIG_MTD_PARTITIONS |
210 | void mtd_erase_callback(struct erase_info *instr); | 240 | void mtd_erase_callback(struct erase_info *instr); |
211 | #else | 241 | #else |
@@ -226,7 +256,7 @@ static inline void mtd_erase_callback(struct erase_info *instr) | |||
226 | 256 | ||
227 | #ifdef CONFIG_MTD_DEBUG | 257 | #ifdef CONFIG_MTD_DEBUG |
228 | #define DEBUG(n, args...) \ | 258 | #define DEBUG(n, args...) \ |
229 | do { \ | 259 | do { \ |
230 | if (n <= CONFIG_MTD_DEBUG_VERBOSE) \ | 260 | if (n <= CONFIG_MTD_DEBUG_VERBOSE) \ |
231 | printk(KERN_INFO args); \ | 261 | printk(KERN_INFO args); \ |
232 | } while(0) | 262 | } while(0) |
diff --git a/include/linux/mtd/nand.h b/include/linux/mtd/nand.h index da5e67b3fc70..66559272ebcb 100644 --- a/include/linux/mtd/nand.h +++ b/include/linux/mtd/nand.h | |||
@@ -11,52 +11,15 @@ | |||
11 | * it under the terms of the GNU General Public License version 2 as | 11 | * it under the terms of the GNU General Public License version 2 as |
12 | * published by the Free Software Foundation. | 12 | * published by the Free Software Foundation. |
13 | * | 13 | * |
14 | * Info: | 14 | * Info: |
15 | * Contains standard defines and IDs for NAND flash devices | 15 | * Contains standard defines and IDs for NAND flash devices |
16 | * | 16 | * |
17 | * Changelog: | 17 | * Changelog: |
18 | * 01-31-2000 DMW Created | 18 | * See git changelog. |
19 | * 09-18-2000 SJH Moved structure out of the Disk-On-Chip drivers | ||
20 | * so it can be used by other NAND flash device | ||
21 | * drivers. I also changed the copyright since none | ||
22 | * of the original contents of this file are specific | ||
23 | * to DoC devices. David can whack me with a baseball | ||
24 | * bat later if I did something naughty. | ||
25 | * 10-11-2000 SJH Added private NAND flash structure for driver | ||
26 | * 10-24-2000 SJH Added prototype for 'nand_scan' function | ||
27 | * 10-29-2001 TG changed nand_chip structure to support | ||
28 | * hardwarespecific function for accessing control lines | ||
29 | * 02-21-2002 TG added support for different read/write adress and | ||
30 | * ready/busy line access function | ||
31 | * 02-26-2002 TG added chip_delay to nand_chip structure to optimize | ||
32 | * command delay times for different chips | ||
33 | * 04-28-2002 TG OOB config defines moved from nand.c to avoid duplicate | ||
34 | * defines in jffs2/wbuf.c | ||
35 | * 08-07-2002 TG forced bad block location to byte 5 of OOB, even if | ||
36 | * CONFIG_MTD_NAND_ECC_JFFS2 is not set | ||
37 | * 08-10-2002 TG extensions to nand_chip structure to support HW-ECC | ||
38 | * | ||
39 | * 08-29-2002 tglx nand_chip structure: data_poi for selecting | ||
40 | * internal / fs-driver buffer | ||
41 | * support for 6byte/512byte hardware ECC | ||
42 | * read_ecc, write_ecc extended for different oob-layout | ||
43 | * oob layout selections: NAND_NONE_OOB, NAND_JFFS2_OOB, | ||
44 | * NAND_YAFFS_OOB | ||
45 | * 11-25-2002 tglx Added Manufacturer code FUJITSU, NATIONAL | ||
46 | * Split manufacturer and device ID structures | ||
47 | * | ||
48 | * 02-08-2004 tglx added option field to nand structure for chip anomalities | ||
49 | * 05-25-2004 tglx added bad block table support, ST-MICRO manufacturer id | ||
50 | * update of nand_chip structure description | ||
51 | * 01-17-2005 dmarlin added extended commands for AG-AND device and added option | ||
52 | * for BBT_AUTO_REFRESH. | ||
53 | * 01-20-2005 dmarlin added optional pointer to hardware specific callback for | ||
54 | * extra error status checks. | ||
55 | */ | 19 | */ |
56 | #ifndef __LINUX_MTD_NAND_H | 20 | #ifndef __LINUX_MTD_NAND_H |
57 | #define __LINUX_MTD_NAND_H | 21 | #define __LINUX_MTD_NAND_H |
58 | 22 | ||
59 | #include <linux/config.h> | ||
60 | #include <linux/wait.h> | 23 | #include <linux/wait.h> |
61 | #include <linux/spinlock.h> | 24 | #include <linux/spinlock.h> |
62 | #include <linux/mtd/mtd.h> | 25 | #include <linux/mtd/mtd.h> |
@@ -67,10 +30,6 @@ extern int nand_scan (struct mtd_info *mtd, int max_chips); | |||
67 | /* Free resources held by the NAND device */ | 30 | /* Free resources held by the NAND device */ |
68 | extern void nand_release (struct mtd_info *mtd); | 31 | extern void nand_release (struct mtd_info *mtd); |
69 | 32 | ||
70 | /* Read raw data from the device without ECC */ | ||
71 | extern int nand_read_raw (struct mtd_info *mtd, uint8_t *buf, loff_t from, size_t len, size_t ooblen); | ||
72 | |||
73 | |||
74 | /* The maximum number of NAND chips in an array */ | 33 | /* The maximum number of NAND chips in an array */ |
75 | #define NAND_MAX_CHIPS 8 | 34 | #define NAND_MAX_CHIPS 8 |
76 | 35 | ||
@@ -79,44 +38,45 @@ extern int nand_read_raw (struct mtd_info *mtd, uint8_t *buf, loff_t from, size_ | |||
79 | * adjust this accordingly. | 38 | * adjust this accordingly. |
80 | */ | 39 | */ |
81 | #define NAND_MAX_OOBSIZE 64 | 40 | #define NAND_MAX_OOBSIZE 64 |
41 | #define NAND_MAX_PAGESIZE 2048 | ||
82 | 42 | ||
83 | /* | 43 | /* |
84 | * Constants for hardware specific CLE/ALE/NCE function | 44 | * Constants for hardware specific CLE/ALE/NCE function |
85 | */ | 45 | * |
46 | * These are bits which can be or'ed to set/clear multiple | ||
47 | * bits in one go. | ||
48 | */ | ||
86 | /* Select the chip by setting nCE to low */ | 49 | /* Select the chip by setting nCE to low */ |
87 | #define NAND_CTL_SETNCE 1 | 50 | #define NAND_NCE 0x01 |
88 | /* Deselect the chip by setting nCE to high */ | ||
89 | #define NAND_CTL_CLRNCE 2 | ||
90 | /* Select the command latch by setting CLE to high */ | 51 | /* Select the command latch by setting CLE to high */ |
91 | #define NAND_CTL_SETCLE 3 | 52 | #define NAND_CLE 0x02 |
92 | /* Deselect the command latch by setting CLE to low */ | ||
93 | #define NAND_CTL_CLRCLE 4 | ||
94 | /* Select the address latch by setting ALE to high */ | 53 | /* Select the address latch by setting ALE to high */ |
95 | #define NAND_CTL_SETALE 5 | 54 | #define NAND_ALE 0x04 |
96 | /* Deselect the address latch by setting ALE to low */ | 55 | |
97 | #define NAND_CTL_CLRALE 6 | 56 | #define NAND_CTRL_CLE (NAND_NCE | NAND_CLE) |
98 | /* Set write protection by setting WP to high. Not used! */ | 57 | #define NAND_CTRL_ALE (NAND_NCE | NAND_ALE) |
99 | #define NAND_CTL_SETWP 7 | 58 | #define NAND_CTRL_CHANGE 0x80 |
100 | /* Clear write protection by setting WP to low. Not used! */ | ||
101 | #define NAND_CTL_CLRWP 8 | ||
102 | 59 | ||
103 | /* | 60 | /* |
104 | * Standard NAND flash commands | 61 | * Standard NAND flash commands |
105 | */ | 62 | */ |
106 | #define NAND_CMD_READ0 0 | 63 | #define NAND_CMD_READ0 0 |
107 | #define NAND_CMD_READ1 1 | 64 | #define NAND_CMD_READ1 1 |
65 | #define NAND_CMD_RNDOUT 5 | ||
108 | #define NAND_CMD_PAGEPROG 0x10 | 66 | #define NAND_CMD_PAGEPROG 0x10 |
109 | #define NAND_CMD_READOOB 0x50 | 67 | #define NAND_CMD_READOOB 0x50 |
110 | #define NAND_CMD_ERASE1 0x60 | 68 | #define NAND_CMD_ERASE1 0x60 |
111 | #define NAND_CMD_STATUS 0x70 | 69 | #define NAND_CMD_STATUS 0x70 |
112 | #define NAND_CMD_STATUS_MULTI 0x71 | 70 | #define NAND_CMD_STATUS_MULTI 0x71 |
113 | #define NAND_CMD_SEQIN 0x80 | 71 | #define NAND_CMD_SEQIN 0x80 |
72 | #define NAND_CMD_RNDIN 0x85 | ||
114 | #define NAND_CMD_READID 0x90 | 73 | #define NAND_CMD_READID 0x90 |
115 | #define NAND_CMD_ERASE2 0xd0 | 74 | #define NAND_CMD_ERASE2 0xd0 |
116 | #define NAND_CMD_RESET 0xff | 75 | #define NAND_CMD_RESET 0xff |
117 | 76 | ||
118 | /* Extended commands for large page devices */ | 77 | /* Extended commands for large page devices */ |
119 | #define NAND_CMD_READSTART 0x30 | 78 | #define NAND_CMD_READSTART 0x30 |
79 | #define NAND_CMD_RNDOUTSTART 0xE0 | ||
120 | #define NAND_CMD_CACHEDPROG 0x15 | 80 | #define NAND_CMD_CACHEDPROG 0x15 |
121 | 81 | ||
122 | /* Extended commands for AG-AND device */ | 82 | /* Extended commands for AG-AND device */ |
@@ -138,6 +98,8 @@ extern int nand_read_raw (struct mtd_info *mtd, uint8_t *buf, loff_t from, size_ | |||
138 | #define NAND_CMD_STATUS_RESET 0x7f | 98 | #define NAND_CMD_STATUS_RESET 0x7f |
139 | #define NAND_CMD_STATUS_CLEAR 0xff | 99 | #define NAND_CMD_STATUS_CLEAR 0xff |
140 | 100 | ||
101 | #define NAND_CMD_NONE -1 | ||
102 | |||
141 | /* Status bits */ | 103 | /* Status bits */ |
142 | #define NAND_STATUS_FAIL 0x01 | 104 | #define NAND_STATUS_FAIL 0x01 |
143 | #define NAND_STATUS_FAIL_N1 0x02 | 105 | #define NAND_STATUS_FAIL_N1 0x02 |
@@ -148,21 +110,12 @@ extern int nand_read_raw (struct mtd_info *mtd, uint8_t *buf, loff_t from, size_ | |||
148 | /* | 110 | /* |
149 | * Constants for ECC_MODES | 111 | * Constants for ECC_MODES |
150 | */ | 112 | */ |
151 | 113 | typedef enum { | |
152 | /* No ECC. Usage is not recommended ! */ | 114 | NAND_ECC_NONE, |
153 | #define NAND_ECC_NONE 0 | 115 | NAND_ECC_SOFT, |
154 | /* Software ECC 3 byte ECC per 256 Byte data */ | 116 | NAND_ECC_HW, |
155 | #define NAND_ECC_SOFT 1 | 117 | NAND_ECC_HW_SYNDROME, |
156 | /* Hardware ECC 3 byte ECC per 256 Byte data */ | 118 | } nand_ecc_modes_t; |
157 | #define NAND_ECC_HW3_256 2 | ||
158 | /* Hardware ECC 3 byte ECC per 512 Byte data */ | ||
159 | #define NAND_ECC_HW3_512 3 | ||
160 | /* Hardware ECC 3 byte ECC per 512 Byte data */ | ||
161 | #define NAND_ECC_HW6_512 4 | ||
162 | /* Hardware ECC 8 byte ECC per 512 Byte data */ | ||
163 | #define NAND_ECC_HW8_512 6 | ||
164 | /* Hardware ECC 12 byte ECC per 2048 Byte data */ | ||
165 | #define NAND_ECC_HW12_2048 7 | ||
166 | 119 | ||
167 | /* | 120 | /* |
168 | * Constants for Hardware ECC | 121 | * Constants for Hardware ECC |
@@ -201,6 +154,10 @@ extern int nand_read_raw (struct mtd_info *mtd, uint8_t *buf, loff_t from, size_ | |||
201 | * bits from adjacent blocks from 'leaking' in altering data. | 154 | * bits from adjacent blocks from 'leaking' in altering data. |
202 | * This happens with the Renesas AG-AND chips, possibly others. */ | 155 | * This happens with the Renesas AG-AND chips, possibly others. */ |
203 | #define BBT_AUTO_REFRESH 0x00000080 | 156 | #define BBT_AUTO_REFRESH 0x00000080 |
157 | /* Chip does not require ready check on read. True | ||
158 | * for all large page devices, as they do not support | ||
159 | * autoincrement.*/ | ||
160 | #define NAND_NO_READRDY 0x00000100 | ||
204 | 161 | ||
205 | /* Options valid for Samsung large page devices */ | 162 | /* Options valid for Samsung large page devices */ |
206 | #define NAND_SAMSUNG_LP_OPTIONS \ | 163 | #define NAND_SAMSUNG_LP_OPTIONS \ |
@@ -219,18 +176,12 @@ extern int nand_read_raw (struct mtd_info *mtd, uint8_t *buf, loff_t from, size_ | |||
219 | /* Use a flash based bad block table. This option is passed to the | 176 | /* Use a flash based bad block table. This option is passed to the |
220 | * default bad block table function. */ | 177 | * default bad block table function. */ |
221 | #define NAND_USE_FLASH_BBT 0x00010000 | 178 | #define NAND_USE_FLASH_BBT 0x00010000 |
222 | /* The hw ecc generator provides a syndrome instead a ecc value on read | ||
223 | * This can only work if we have the ecc bytes directly behind the | ||
224 | * data bytes. Applies for DOC and AG-AND Renesas HW Reed Solomon generators */ | ||
225 | #define NAND_HWECC_SYNDROME 0x00020000 | ||
226 | /* This option skips the bbt scan during initialization. */ | 179 | /* This option skips the bbt scan during initialization. */ |
227 | #define NAND_SKIP_BBTSCAN 0x00040000 | 180 | #define NAND_SKIP_BBTSCAN 0x00020000 |
228 | 181 | ||
229 | /* Options set by nand scan */ | 182 | /* Options set by nand scan */ |
230 | /* Nand scan has allocated oob_buf */ | 183 | /* Nand scan has allocated controller struct */ |
231 | #define NAND_OOBBUF_ALLOC 0x40000000 | 184 | #define NAND_CONTROLLER_ALLOC 0x80000000 |
232 | /* Nand scan has allocated data_buf */ | ||
233 | #define NAND_DATABUF_ALLOC 0x80000000 | ||
234 | 185 | ||
235 | 186 | ||
236 | /* | 187 | /* |
@@ -264,45 +215,102 @@ struct nand_hw_control { | |||
264 | }; | 215 | }; |
265 | 216 | ||
266 | /** | 217 | /** |
218 | * struct nand_ecc_ctrl - Control structure for ecc | ||
219 | * @mode: ecc mode | ||
220 | * @steps: number of ecc steps per page | ||
221 | * @size: data bytes per ecc step | ||
222 | * @bytes: ecc bytes per step | ||
223 | * @total: total number of ecc bytes per page | ||
224 | * @prepad: padding information for syndrome based ecc generators | ||
225 | * @postpad: padding information for syndrome based ecc generators | ||
226 | * @hwctl: function to control hardware ecc generator. Must only | ||
227 | * be provided if an hardware ECC is available | ||
228 | * @calculate: function for ecc calculation or readback from ecc hardware | ||
229 | * @correct: function for ecc correction, matching to ecc generator (sw/hw) | ||
230 | * @read_page: function to read a page according to the ecc generator requirements | ||
231 | * @write_page: function to write a page according to the ecc generator requirements | ||
232 | */ | ||
233 | struct nand_ecc_ctrl { | ||
234 | nand_ecc_modes_t mode; | ||
235 | int steps; | ||
236 | int size; | ||
237 | int bytes; | ||
238 | int total; | ||
239 | int prepad; | ||
240 | int postpad; | ||
241 | struct nand_ecclayout *layout; | ||
242 | void (*hwctl)(struct mtd_info *mtd, int mode); | ||
243 | int (*calculate)(struct mtd_info *mtd, | ||
244 | const uint8_t *dat, | ||
245 | uint8_t *ecc_code); | ||
246 | int (*correct)(struct mtd_info *mtd, uint8_t *dat, | ||
247 | uint8_t *read_ecc, | ||
248 | uint8_t *calc_ecc); | ||
249 | int (*read_page)(struct mtd_info *mtd, | ||
250 | struct nand_chip *chip, | ||
251 | uint8_t *buf); | ||
252 | void (*write_page)(struct mtd_info *mtd, | ||
253 | struct nand_chip *chip, | ||
254 | const uint8_t *buf); | ||
255 | int (*read_oob)(struct mtd_info *mtd, | ||
256 | struct nand_chip *chip, | ||
257 | int page, | ||
258 | int sndcmd); | ||
259 | int (*write_oob)(struct mtd_info *mtd, | ||
260 | struct nand_chip *chip, | ||
261 | int page); | ||
262 | }; | ||
263 | |||
264 | /** | ||
265 | * struct nand_buffers - buffer structure for read/write | ||
266 | * @ecccalc: buffer for calculated ecc | ||
267 | * @ecccode: buffer for ecc read from flash | ||
268 | * @oobwbuf: buffer for write oob data | ||
269 | * @databuf: buffer for data - dynamically sized | ||
270 | * @oobrbuf: buffer to read oob data | ||
271 | * | ||
272 | * Do not change the order of buffers. databuf and oobrbuf must be in | ||
273 | * consecutive order. | ||
274 | */ | ||
275 | struct nand_buffers { | ||
276 | uint8_t ecccalc[NAND_MAX_OOBSIZE]; | ||
277 | uint8_t ecccode[NAND_MAX_OOBSIZE]; | ||
278 | uint8_t oobwbuf[NAND_MAX_OOBSIZE]; | ||
279 | uint8_t databuf[NAND_MAX_PAGESIZE]; | ||
280 | uint8_t oobrbuf[NAND_MAX_OOBSIZE]; | ||
281 | }; | ||
282 | |||
283 | /** | ||
267 | * struct nand_chip - NAND Private Flash Chip Data | 284 | * struct nand_chip - NAND Private Flash Chip Data |
268 | * @IO_ADDR_R: [BOARDSPECIFIC] address to read the 8 I/O lines of the flash device | 285 | * @IO_ADDR_R: [BOARDSPECIFIC] address to read the 8 I/O lines of the flash device |
269 | * @IO_ADDR_W: [BOARDSPECIFIC] address to write the 8 I/O lines of the flash device | 286 | * @IO_ADDR_W: [BOARDSPECIFIC] address to write the 8 I/O lines of the flash device |
270 | * @read_byte: [REPLACEABLE] read one byte from the chip | 287 | * @read_byte: [REPLACEABLE] read one byte from the chip |
271 | * @write_byte: [REPLACEABLE] write one byte to the chip | ||
272 | * @read_word: [REPLACEABLE] read one word from the chip | 288 | * @read_word: [REPLACEABLE] read one word from the chip |
273 | * @write_word: [REPLACEABLE] write one word to the chip | ||
274 | * @write_buf: [REPLACEABLE] write data from the buffer to the chip | 289 | * @write_buf: [REPLACEABLE] write data from the buffer to the chip |
275 | * @read_buf: [REPLACEABLE] read data from the chip into the buffer | 290 | * @read_buf: [REPLACEABLE] read data from the chip into the buffer |
276 | * @verify_buf: [REPLACEABLE] verify buffer contents against the chip data | 291 | * @verify_buf: [REPLACEABLE] verify buffer contents against the chip data |
277 | * @select_chip: [REPLACEABLE] select chip nr | 292 | * @select_chip: [REPLACEABLE] select chip nr |
278 | * @block_bad: [REPLACEABLE] check, if the block is bad | 293 | * @block_bad: [REPLACEABLE] check, if the block is bad |
279 | * @block_markbad: [REPLACEABLE] mark the block bad | 294 | * @block_markbad: [REPLACEABLE] mark the block bad |
280 | * @hwcontrol: [BOARDSPECIFIC] hardwarespecific function for accesing control-lines | 295 | * @cmd_ctrl: [BOARDSPECIFIC] hardwarespecific funtion for controlling |
296 | * ALE/CLE/nCE. Also used to write command and address | ||
281 | * @dev_ready: [BOARDSPECIFIC] hardwarespecific function for accesing device ready/busy line | 297 | * @dev_ready: [BOARDSPECIFIC] hardwarespecific function for accesing device ready/busy line |
282 | * If set to NULL no access to ready/busy is available and the ready/busy information | 298 | * If set to NULL no access to ready/busy is available and the ready/busy information |
283 | * is read from the chip status register | 299 | * is read from the chip status register |
284 | * @cmdfunc: [REPLACEABLE] hardwarespecific function for writing commands to the chip | 300 | * @cmdfunc: [REPLACEABLE] hardwarespecific function for writing commands to the chip |
285 | * @waitfunc: [REPLACEABLE] hardwarespecific function for wait on ready | 301 | * @waitfunc: [REPLACEABLE] hardwarespecific function for wait on ready |
286 | * @calculate_ecc: [REPLACEABLE] function for ecc calculation or readback from ecc hardware | 302 | * @ecc: [BOARDSPECIFIC] ecc control ctructure |
287 | * @correct_data: [REPLACEABLE] function for ecc correction, matching to ecc generator (sw/hw) | ||
288 | * @enable_hwecc: [BOARDSPECIFIC] function to enable (reset) hardware ecc generator. Must only | ||
289 | * be provided if a hardware ECC is available | ||
290 | * @erase_cmd: [INTERN] erase command write function, selectable due to AND support | 303 | * @erase_cmd: [INTERN] erase command write function, selectable due to AND support |
291 | * @scan_bbt: [REPLACEABLE] function to scan bad block table | 304 | * @scan_bbt: [REPLACEABLE] function to scan bad block table |
292 | * @eccmode: [BOARDSPECIFIC] mode of ecc, see defines | ||
293 | * @eccsize: [INTERN] databytes used per ecc-calculation | ||
294 | * @eccbytes: [INTERN] number of ecc bytes per ecc-calculation step | ||
295 | * @eccsteps: [INTERN] number of ecc calculation steps per page | ||
296 | * @chip_delay: [BOARDSPECIFIC] chip dependent delay for transfering data from array to read regs (tR) | 305 | * @chip_delay: [BOARDSPECIFIC] chip dependent delay for transfering data from array to read regs (tR) |
297 | * @chip_lock: [INTERN] spinlock used to protect access to this structure and the chip | ||
298 | * @wq: [INTERN] wait queue to sleep on if a NAND operation is in progress | 306 | * @wq: [INTERN] wait queue to sleep on if a NAND operation is in progress |
299 | * @state: [INTERN] the current state of the NAND device | 307 | * @state: [INTERN] the current state of the NAND device |
300 | * @page_shift: [INTERN] number of address bits in a page (column address bits) | 308 | * @page_shift: [INTERN] number of address bits in a page (column address bits) |
301 | * @phys_erase_shift: [INTERN] number of address bits in a physical eraseblock | 309 | * @phys_erase_shift: [INTERN] number of address bits in a physical eraseblock |
302 | * @bbt_erase_shift: [INTERN] number of address bits in a bbt entry | 310 | * @bbt_erase_shift: [INTERN] number of address bits in a bbt entry |
303 | * @chip_shift: [INTERN] number of address bits in one chip | 311 | * @chip_shift: [INTERN] number of address bits in one chip |
304 | * @data_buf: [INTERN] internal buffer for one page + oob | 312 | * @datbuf: [INTERN] internal buffer for one page + oob |
305 | * @oob_buf: [INTERN] oob buffer for one eraseblock | 313 | * @oobbuf: [INTERN] oob buffer for one eraseblock |
306 | * @oobdirty: [INTERN] indicates that oob_buf must be reinitialized | 314 | * @oobdirty: [INTERN] indicates that oob_buf must be reinitialized |
307 | * @data_poi: [INTERN] pointer to a data buffer | 315 | * @data_poi: [INTERN] pointer to a data buffer |
308 | * @options: [BOARDSPECIFIC] various chip options. They can partly be set to inform nand_scan about | 316 | * @options: [BOARDSPECIFIC] various chip options. They can partly be set to inform nand_scan about |
@@ -312,12 +320,13 @@ struct nand_hw_control { | |||
312 | * @chipsize: [INTERN] the size of one chip for multichip arrays | 320 | * @chipsize: [INTERN] the size of one chip for multichip arrays |
313 | * @pagemask: [INTERN] page number mask = number of (pages / chip) - 1 | 321 | * @pagemask: [INTERN] page number mask = number of (pages / chip) - 1 |
314 | * @pagebuf: [INTERN] holds the pagenumber which is currently in data_buf | 322 | * @pagebuf: [INTERN] holds the pagenumber which is currently in data_buf |
315 | * @autooob: [REPLACEABLE] the default (auto)placement scheme | 323 | * @ecclayout: [REPLACEABLE] the default ecc placement scheme |
316 | * @bbt: [INTERN] bad block table pointer | 324 | * @bbt: [INTERN] bad block table pointer |
317 | * @bbt_td: [REPLACEABLE] bad block table descriptor for flash lookup | 325 | * @bbt_td: [REPLACEABLE] bad block table descriptor for flash lookup |
318 | * @bbt_md: [REPLACEABLE] bad block table mirror descriptor | 326 | * @bbt_md: [REPLACEABLE] bad block table mirror descriptor |
319 | * @badblock_pattern: [REPLACEABLE] bad block scan pattern used for initial bad block scan | 327 | * @badblock_pattern: [REPLACEABLE] bad block scan pattern used for initial bad block scan |
320 | * @controller: [OPTIONAL] a pointer to a hardware controller structure which is shared among multiple independend devices | 328 | * @controller: [REPLACEABLE] a pointer to a hardware controller structure |
329 | * which is shared among multiple independend devices | ||
321 | * @priv: [OPTIONAL] pointer to private chip date | 330 | * @priv: [OPTIONAL] pointer to private chip date |
322 | * @errstat: [OPTIONAL] hardware specific function to perform additional error status checks | 331 | * @errstat: [OPTIONAL] hardware specific function to perform additional error status checks |
323 | * (determine if errors are correctable) | 332 | * (determine if errors are correctable) |
@@ -325,58 +334,57 @@ struct nand_hw_control { | |||
325 | 334 | ||
326 | struct nand_chip { | 335 | struct nand_chip { |
327 | void __iomem *IO_ADDR_R; | 336 | void __iomem *IO_ADDR_R; |
328 | void __iomem *IO_ADDR_W; | 337 | void __iomem *IO_ADDR_W; |
329 | 338 | ||
330 | u_char (*read_byte)(struct mtd_info *mtd); | 339 | uint8_t (*read_byte)(struct mtd_info *mtd); |
331 | void (*write_byte)(struct mtd_info *mtd, u_char byte); | ||
332 | u16 (*read_word)(struct mtd_info *mtd); | 340 | u16 (*read_word)(struct mtd_info *mtd); |
333 | void (*write_word)(struct mtd_info *mtd, u16 word); | 341 | void (*write_buf)(struct mtd_info *mtd, const uint8_t *buf, int len); |
334 | 342 | void (*read_buf)(struct mtd_info *mtd, uint8_t *buf, int len); | |
335 | void (*write_buf)(struct mtd_info *mtd, const u_char *buf, int len); | 343 | int (*verify_buf)(struct mtd_info *mtd, const uint8_t *buf, int len); |
336 | void (*read_buf)(struct mtd_info *mtd, u_char *buf, int len); | ||
337 | int (*verify_buf)(struct mtd_info *mtd, const u_char *buf, int len); | ||
338 | void (*select_chip)(struct mtd_info *mtd, int chip); | 344 | void (*select_chip)(struct mtd_info *mtd, int chip); |
339 | int (*block_bad)(struct mtd_info *mtd, loff_t ofs, int getchip); | 345 | int (*block_bad)(struct mtd_info *mtd, loff_t ofs, int getchip); |
340 | int (*block_markbad)(struct mtd_info *mtd, loff_t ofs); | 346 | int (*block_markbad)(struct mtd_info *mtd, loff_t ofs); |
341 | void (*hwcontrol)(struct mtd_info *mtd, int cmd); | 347 | void (*cmd_ctrl)(struct mtd_info *mtd, int dat, |
342 | int (*dev_ready)(struct mtd_info *mtd); | 348 | unsigned int ctrl); |
343 | void (*cmdfunc)(struct mtd_info *mtd, unsigned command, int column, int page_addr); | 349 | int (*dev_ready)(struct mtd_info *mtd); |
344 | int (*waitfunc)(struct mtd_info *mtd, struct nand_chip *this, int state); | 350 | void (*cmdfunc)(struct mtd_info *mtd, unsigned command, int column, int page_addr); |
345 | int (*calculate_ecc)(struct mtd_info *mtd, const u_char *dat, u_char *ecc_code); | 351 | int (*waitfunc)(struct mtd_info *mtd, struct nand_chip *this); |
346 | int (*correct_data)(struct mtd_info *mtd, u_char *dat, u_char *read_ecc, u_char *calc_ecc); | ||
347 | void (*enable_hwecc)(struct mtd_info *mtd, int mode); | ||
348 | void (*erase_cmd)(struct mtd_info *mtd, int page); | 352 | void (*erase_cmd)(struct mtd_info *mtd, int page); |
349 | int (*scan_bbt)(struct mtd_info *mtd); | 353 | int (*scan_bbt)(struct mtd_info *mtd); |
350 | int eccmode; | 354 | int (*errstat)(struct mtd_info *mtd, struct nand_chip *this, int state, int status, int page); |
351 | int eccsize; | 355 | |
352 | int eccbytes; | 356 | int chip_delay; |
353 | int eccsteps; | 357 | unsigned int options; |
354 | int chip_delay; | 358 | |
355 | spinlock_t chip_lock; | 359 | int page_shift; |
356 | wait_queue_head_t wq; | ||
357 | nand_state_t state; | ||
358 | int page_shift; | ||
359 | int phys_erase_shift; | 360 | int phys_erase_shift; |
360 | int bbt_erase_shift; | 361 | int bbt_erase_shift; |
361 | int chip_shift; | 362 | int chip_shift; |
362 | u_char *data_buf; | ||
363 | u_char *oob_buf; | ||
364 | int oobdirty; | ||
365 | u_char *data_poi; | ||
366 | unsigned int options; | ||
367 | int badblockpos; | ||
368 | int numchips; | 363 | int numchips; |
369 | unsigned long chipsize; | 364 | unsigned long chipsize; |
370 | int pagemask; | 365 | int pagemask; |
371 | int pagebuf; | 366 | int pagebuf; |
372 | struct nand_oobinfo *autooob; | 367 | int badblockpos; |
368 | |||
369 | nand_state_t state; | ||
370 | |||
371 | uint8_t *oob_poi; | ||
372 | struct nand_hw_control *controller; | ||
373 | struct nand_ecclayout *ecclayout; | ||
374 | |||
375 | struct nand_ecc_ctrl ecc; | ||
376 | struct nand_buffers buffers; | ||
377 | struct nand_hw_control hwcontrol; | ||
378 | |||
379 | struct mtd_oob_ops ops; | ||
380 | |||
373 | uint8_t *bbt; | 381 | uint8_t *bbt; |
374 | struct nand_bbt_descr *bbt_td; | 382 | struct nand_bbt_descr *bbt_td; |
375 | struct nand_bbt_descr *bbt_md; | 383 | struct nand_bbt_descr *bbt_md; |
384 | |||
376 | struct nand_bbt_descr *badblock_pattern; | 385 | struct nand_bbt_descr *badblock_pattern; |
377 | struct nand_hw_control *controller; | 386 | |
378 | void *priv; | 387 | void *priv; |
379 | int (*errstat)(struct mtd_info *mtd, struct nand_chip *this, int state, int status, int page); | ||
380 | }; | 388 | }; |
381 | 389 | ||
382 | /* | 390 | /* |
@@ -388,19 +396,19 @@ struct nand_chip { | |||
388 | #define NAND_MFR_NATIONAL 0x8f | 396 | #define NAND_MFR_NATIONAL 0x8f |
389 | #define NAND_MFR_RENESAS 0x07 | 397 | #define NAND_MFR_RENESAS 0x07 |
390 | #define NAND_MFR_STMICRO 0x20 | 398 | #define NAND_MFR_STMICRO 0x20 |
391 | #define NAND_MFR_HYNIX 0xad | 399 | #define NAND_MFR_HYNIX 0xad |
392 | 400 | ||
393 | /** | 401 | /** |
394 | * struct nand_flash_dev - NAND Flash Device ID Structure | 402 | * struct nand_flash_dev - NAND Flash Device ID Structure |
395 | * | 403 | * |
396 | * @name: Identify the device type | 404 | * @name: Identify the device type |
397 | * @id: device ID code | 405 | * @id: device ID code |
398 | * @pagesize: Pagesize in bytes. Either 256 or 512 or 0 | 406 | * @pagesize: Pagesize in bytes. Either 256 or 512 or 0 |
399 | * If the pagesize is 0, then the real pagesize | 407 | * If the pagesize is 0, then the real pagesize |
400 | * and the eraseize are determined from the | 408 | * and the eraseize are determined from the |
401 | * extended id bytes in the chip | 409 | * extended id bytes in the chip |
402 | * @erasesize: Size of an erase block in the flash device. | 410 | * @erasesize: Size of an erase block in the flash device. |
403 | * @chipsize: Total chipsize in Mega Bytes | 411 | * @chipsize: Total chipsize in Mega Bytes |
404 | * @options: Bitfield to store chip relevant options | 412 | * @options: Bitfield to store chip relevant options |
405 | */ | 413 | */ |
406 | struct nand_flash_dev { | 414 | struct nand_flash_dev { |
@@ -415,7 +423,7 @@ struct nand_flash_dev { | |||
415 | /** | 423 | /** |
416 | * struct nand_manufacturers - NAND Flash Manufacturer ID Structure | 424 | * struct nand_manufacturers - NAND Flash Manufacturer ID Structure |
417 | * @name: Manufacturer name | 425 | * @name: Manufacturer name |
418 | * @id: manufacturer ID code of device. | 426 | * @id: manufacturer ID code of device. |
419 | */ | 427 | */ |
420 | struct nand_manufacturers { | 428 | struct nand_manufacturers { |
421 | int id; | 429 | int id; |
@@ -455,7 +463,7 @@ struct nand_bbt_descr { | |||
455 | int veroffs; | 463 | int veroffs; |
456 | uint8_t version[NAND_MAX_CHIPS]; | 464 | uint8_t version[NAND_MAX_CHIPS]; |
457 | int len; | 465 | int len; |
458 | int maxblocks; | 466 | int maxblocks; |
459 | int reserved_block_code; | 467 | int reserved_block_code; |
460 | uint8_t *pattern; | 468 | uint8_t *pattern; |
461 | }; | 469 | }; |
@@ -494,14 +502,14 @@ struct nand_bbt_descr { | |||
494 | /* The maximum number of blocks to scan for a bbt */ | 502 | /* The maximum number of blocks to scan for a bbt */ |
495 | #define NAND_BBT_SCAN_MAXBLOCKS 4 | 503 | #define NAND_BBT_SCAN_MAXBLOCKS 4 |
496 | 504 | ||
497 | extern int nand_scan_bbt (struct mtd_info *mtd, struct nand_bbt_descr *bd); | 505 | extern int nand_scan_bbt(struct mtd_info *mtd, struct nand_bbt_descr *bd); |
498 | extern int nand_update_bbt (struct mtd_info *mtd, loff_t offs); | 506 | extern int nand_update_bbt(struct mtd_info *mtd, loff_t offs); |
499 | extern int nand_default_bbt (struct mtd_info *mtd); | 507 | extern int nand_default_bbt(struct mtd_info *mtd); |
500 | extern int nand_isbad_bbt (struct mtd_info *mtd, loff_t offs, int allowbbt); | 508 | extern int nand_isbad_bbt(struct mtd_info *mtd, loff_t offs, int allowbbt); |
501 | extern int nand_erase_nand (struct mtd_info *mtd, struct erase_info *instr, int allowbbt); | 509 | extern int nand_erase_nand(struct mtd_info *mtd, struct erase_info *instr, |
502 | extern int nand_do_read_ecc (struct mtd_info *mtd, loff_t from, size_t len, | 510 | int allowbbt); |
503 | size_t * retlen, u_char * buf, u_char * oob_buf, | 511 | extern int nand_do_read(struct mtd_info *mtd, loff_t from, size_t len, |
504 | struct nand_oobinfo *oobsel, int flags); | 512 | size_t * retlen, uint8_t * buf); |
505 | 513 | ||
506 | /* | 514 | /* |
507 | * Constants for oob configuration | 515 | * Constants for oob configuration |
@@ -509,4 +517,53 @@ extern int nand_do_read_ecc (struct mtd_info *mtd, loff_t from, size_t len, | |||
509 | #define NAND_SMALL_BADBLOCK_POS 5 | 517 | #define NAND_SMALL_BADBLOCK_POS 5 |
510 | #define NAND_LARGE_BADBLOCK_POS 0 | 518 | #define NAND_LARGE_BADBLOCK_POS 0 |
511 | 519 | ||
520 | /** | ||
521 | * struct platform_nand_chip - chip level device structure | ||
522 | * | ||
523 | * @nr_chips: max. number of chips to scan for | ||
524 | * @chip_offs: chip number offset | ||
525 | * @nr_partitions: number of partitions pointed to by partitions (or zero) | ||
526 | * @partitions: mtd partition list | ||
527 | * @chip_delay: R/B delay value in us | ||
528 | * @options: Option flags, e.g. 16bit buswidth | ||
529 | * @ecclayout: ecc layout info structure | ||
530 | * @priv: hardware controller specific settings | ||
531 | */ | ||
532 | struct platform_nand_chip { | ||
533 | int nr_chips; | ||
534 | int chip_offset; | ||
535 | int nr_partitions; | ||
536 | struct mtd_partition *partitions; | ||
537 | struct nand_ecclayout *ecclayout; | ||
538 | int chip_delay; | ||
539 | unsigned int options; | ||
540 | void *priv; | ||
541 | }; | ||
542 | |||
543 | /** | ||
544 | * struct platform_nand_ctrl - controller level device structure | ||
545 | * | ||
546 | * @hwcontrol: platform specific hardware control structure | ||
547 | * @dev_ready: platform specific function to read ready/busy pin | ||
548 | * @select_chip: platform specific chip select function | ||
549 | * @priv_data: private data to transport driver specific settings | ||
550 | * | ||
551 | * All fields are optional and depend on the hardware driver requirements | ||
552 | */ | ||
553 | struct platform_nand_ctrl { | ||
554 | void (*hwcontrol)(struct mtd_info *mtd, int cmd); | ||
555 | int (*dev_ready)(struct mtd_info *mtd); | ||
556 | void (*select_chip)(struct mtd_info *mtd, int chip); | ||
557 | void *priv; | ||
558 | }; | ||
559 | |||
560 | /* Some helpers to access the data structures */ | ||
561 | static inline | ||
562 | struct platform_nand_chip *get_platform_nandchip(struct mtd_info *mtd) | ||
563 | { | ||
564 | struct nand_chip *chip = mtd->priv; | ||
565 | |||
566 | return chip->priv; | ||
567 | } | ||
568 | |||
512 | #endif /* __LINUX_MTD_NAND_H */ | 569 | #endif /* __LINUX_MTD_NAND_H */ |
diff --git a/include/linux/mtd/ndfc.h b/include/linux/mtd/ndfc.h new file mode 100644 index 000000000000..d0558a982628 --- /dev/null +++ b/include/linux/mtd/ndfc.h | |||
@@ -0,0 +1,67 @@ | |||
1 | /* | ||
2 | * linux/include/linux/mtd/ndfc.h | ||
3 | * | ||
4 | * Copyright (c) 2006 Thomas Gleixner <tglx@linutronix.de> | ||
5 | * | ||
6 | * This program is free software; you can redistribute it and/or modify | ||
7 | * it under the terms of the GNU General Public License version 2 as | ||
8 | * published by the Free Software Foundation. | ||
9 | * | ||
10 | * Info: | ||
11 | * Contains defines, datastructures for ndfc nand controller | ||
12 | * | ||
13 | */ | ||
14 | #ifndef __LINUX_MTD_NDFC_H | ||
15 | #define __LINUX_MTD_NDFC_H | ||
16 | |||
17 | /* NDFC Register definitions */ | ||
18 | #define NDFC_CMD 0x00 | ||
19 | #define NDFC_ALE 0x04 | ||
20 | #define NDFC_DATA 0x08 | ||
21 | #define NDFC_ECC 0x10 | ||
22 | #define NDFC_BCFG0 0x30 | ||
23 | #define NDFC_BCFG1 0x34 | ||
24 | #define NDFC_BCFG2 0x38 | ||
25 | #define NDFC_BCFG3 0x3c | ||
26 | #define NDFC_CCR 0x40 | ||
27 | #define NDFC_STAT 0x44 | ||
28 | #define NDFC_HWCTL 0x48 | ||
29 | #define NDFC_REVID 0x50 | ||
30 | |||
31 | #define NDFC_STAT_IS_READY 0x01000000 | ||
32 | |||
33 | #define NDFC_CCR_RESET_CE 0x80000000 /* CE Reset */ | ||
34 | #define NDFC_CCR_RESET_ECC 0x40000000 /* ECC Reset */ | ||
35 | #define NDFC_CCR_RIE 0x20000000 /* Interrupt Enable on Device Rdy */ | ||
36 | #define NDFC_CCR_REN 0x10000000 /* Enable wait for Rdy in LinearR */ | ||
37 | #define NDFC_CCR_ROMEN 0x08000000 /* Enable ROM In LinearR */ | ||
38 | #define NDFC_CCR_ARE 0x04000000 /* Auto-Read Enable */ | ||
39 | #define NDFC_CCR_BS(x) (((x) & 0x3) << 24) /* Select Bank on CE[x] */ | ||
40 | #define NDFC_CCR_BS_MASK 0x03000000 /* Select Bank */ | ||
41 | #define NDFC_CCR_ARAC0 0x00000000 /* 3 Addr, 1 Col 2 Row 512b page */ | ||
42 | #define NDFC_CCR_ARAC1 0x00001000 /* 4 Addr, 1 Col 3 Row 512b page */ | ||
43 | #define NDFC_CCR_ARAC2 0x00002000 /* 4 Addr, 2 Col 2 Row 2K page */ | ||
44 | #define NDFC_CCR_ARAC3 0x00003000 /* 5 Addr, 2 Col 3 Row 2K page */ | ||
45 | #define NDFC_CCR_ARAC_MASK 0x00003000 /* Auto-Read mode Addr Cycles */ | ||
46 | #define NDFC_CCR_RPG 0x0000C000 /* Auto-Read Page */ | ||
47 | #define NDFC_CCR_EBCC 0x00000004 /* EBC Configuration Completed */ | ||
48 | #define NDFC_CCR_DHC 0x00000002 /* Direct Hardware Control Enable */ | ||
49 | |||
50 | #define NDFC_BxCFG_EN 0x80000000 /* Bank Enable */ | ||
51 | #define NDFC_BxCFG_CED 0x40000000 /* nCE Style */ | ||
52 | #define NDFC_BxCFG_SZ_MASK 0x08000000 /* Bank Size */ | ||
53 | #define NDFC_BxCFG_SZ_8BIT 0x00000000 /* 8bit */ | ||
54 | #define NDFC_BxCFG_SZ_16BIT 0x08000000 /* 16bit */ | ||
55 | |||
56 | #define NDFC_MAX_BANKS 4 | ||
57 | |||
58 | struct ndfc_controller_settings { | ||
59 | uint32_t ccr_settings; | ||
60 | uint64_t ndfc_erpn; | ||
61 | }; | ||
62 | |||
63 | struct ndfc_chip_settings { | ||
64 | uint32_t bank_settings; | ||
65 | }; | ||
66 | |||
67 | #endif | ||
diff --git a/include/linux/mtd/nftl.h b/include/linux/mtd/nftl.h index d35d2c21ff3e..bcf2fb3fa4a7 100644 --- a/include/linux/mtd/nftl.h +++ b/include/linux/mtd/nftl.h | |||
@@ -37,7 +37,7 @@ struct NFTLrecord { | |||
37 | unsigned int nb_blocks; /* number of physical blocks */ | 37 | unsigned int nb_blocks; /* number of physical blocks */ |
38 | unsigned int nb_boot_blocks; /* number of blocks used by the bios */ | 38 | unsigned int nb_boot_blocks; /* number of blocks used by the bios */ |
39 | struct erase_info instr; | 39 | struct erase_info instr; |
40 | struct nand_oobinfo oobinfo; | 40 | struct nand_ecclayout oobinfo; |
41 | }; | 41 | }; |
42 | 42 | ||
43 | int NFTL_mount(struct NFTLrecord *s); | 43 | int NFTL_mount(struct NFTLrecord *s); |
diff --git a/include/linux/mtd/onenand.h b/include/linux/mtd/onenand.h index 7419b5fab133..9ce9a48db444 100644 --- a/include/linux/mtd/onenand.h +++ b/include/linux/mtd/onenand.h | |||
@@ -35,6 +35,8 @@ typedef enum { | |||
35 | FL_SYNCING, | 35 | FL_SYNCING, |
36 | FL_UNLOCKING, | 36 | FL_UNLOCKING, |
37 | FL_LOCKING, | 37 | FL_LOCKING, |
38 | FL_RESETING, | ||
39 | FL_OTPING, | ||
38 | FL_PM_SUSPENDED, | 40 | FL_PM_SUSPENDED, |
39 | } onenand_state_t; | 41 | } onenand_state_t; |
40 | 42 | ||
@@ -75,7 +77,7 @@ struct onenand_bufferram { | |||
75 | * @param chip_lock [INTERN] spinlock used to protect access to this structure and the chip | 77 | * @param chip_lock [INTERN] spinlock used to protect access to this structure and the chip |
76 | * @param wq [INTERN] wait queue to sleep on if a OneNAND operation is in progress | 78 | * @param wq [INTERN] wait queue to sleep on if a OneNAND operation is in progress |
77 | * @param state [INTERN] the current state of the OneNAND device | 79 | * @param state [INTERN] the current state of the OneNAND device |
78 | * @param autooob [REPLACEABLE] the default (auto)placement scheme | 80 | * @param ecclayout [REPLACEABLE] the default ecc placement scheme |
79 | * @param bbm [REPLACEABLE] pointer to Bad Block Management | 81 | * @param bbm [REPLACEABLE] pointer to Bad Block Management |
80 | * @param priv [OPTIONAL] pointer to private chip date | 82 | * @param priv [OPTIONAL] pointer to private chip date |
81 | */ | 83 | */ |
@@ -111,9 +113,9 @@ struct onenand_chip { | |||
111 | onenand_state_t state; | 113 | onenand_state_t state; |
112 | unsigned char *page_buf; | 114 | unsigned char *page_buf; |
113 | 115 | ||
114 | struct nand_oobinfo *autooob; | 116 | struct nand_ecclayout *ecclayout; |
115 | 117 | ||
116 | void *bbm; | 118 | void *bbm; |
117 | 119 | ||
118 | void *priv; | 120 | void *priv; |
119 | }; | 121 | }; |
@@ -130,6 +132,9 @@ struct onenand_chip { | |||
130 | #define ONENAND_SET_SYS_CFG1(v, this) \ | 132 | #define ONENAND_SET_SYS_CFG1(v, this) \ |
131 | (this->write_word(v, this->base + ONENAND_REG_SYS_CFG1)) | 133 | (this->write_word(v, this->base + ONENAND_REG_SYS_CFG1)) |
132 | 134 | ||
135 | /* Check byte access in OneNAND */ | ||
136 | #define ONENAND_CHECK_BYTE_ACCESS(addr) (addr & 0x1) | ||
137 | |||
133 | /* | 138 | /* |
134 | * Options bits | 139 | * Options bits |
135 | */ | 140 | */ |
diff --git a/include/linux/mtd/onenand_regs.h b/include/linux/mtd/onenand_regs.h index d7832ef8ed63..4a72818d2545 100644 --- a/include/linux/mtd/onenand_regs.h +++ b/include/linux/mtd/onenand_regs.h | |||
@@ -112,6 +112,7 @@ | |||
112 | #define ONENAND_CMD_LOCK_TIGHT (0x2C) | 112 | #define ONENAND_CMD_LOCK_TIGHT (0x2C) |
113 | #define ONENAND_CMD_ERASE (0x94) | 113 | #define ONENAND_CMD_ERASE (0x94) |
114 | #define ONENAND_CMD_RESET (0xF0) | 114 | #define ONENAND_CMD_RESET (0xF0) |
115 | #define ONENAND_CMD_OTP_ACCESS (0x65) | ||
115 | #define ONENAND_CMD_READID (0x90) | 116 | #define ONENAND_CMD_READID (0x90) |
116 | 117 | ||
117 | /* NOTE: Those are not *REAL* commands */ | 118 | /* NOTE: Those are not *REAL* commands */ |
@@ -152,6 +153,8 @@ | |||
152 | #define ONENAND_CTRL_ERASE (1 << 11) | 153 | #define ONENAND_CTRL_ERASE (1 << 11) |
153 | #define ONENAND_CTRL_ERROR (1 << 10) | 154 | #define ONENAND_CTRL_ERROR (1 << 10) |
154 | #define ONENAND_CTRL_RSTB (1 << 7) | 155 | #define ONENAND_CTRL_RSTB (1 << 7) |
156 | #define ONENAND_CTRL_OTP_L (1 << 6) | ||
157 | #define ONENAND_CTRL_OTP_BL (1 << 5) | ||
155 | 158 | ||
156 | /* | 159 | /* |
157 | * Interrupt Status Register F241h (R) | 160 | * Interrupt Status Register F241h (R) |
@@ -177,4 +180,9 @@ | |||
177 | #define ONENAND_ECC_2BIT (1 << 1) | 180 | #define ONENAND_ECC_2BIT (1 << 1) |
178 | #define ONENAND_ECC_2BIT_ALL (0xAAAA) | 181 | #define ONENAND_ECC_2BIT_ALL (0xAAAA) |
179 | 182 | ||
183 | /* | ||
184 | * One-Time Programmable (OTP) | ||
185 | */ | ||
186 | #define ONENAND_OTP_LOCK_OFFSET (14) | ||
187 | |||
180 | #endif /* __ONENAND_REG_H */ | 188 | #endif /* __ONENAND_REG_H */ |
diff --git a/include/linux/mtd/partitions.h b/include/linux/mtd/partitions.h index b03f512d51b9..da6b3d6f12a7 100644 --- a/include/linux/mtd/partitions.h +++ b/include/linux/mtd/partitions.h | |||
@@ -41,7 +41,7 @@ struct mtd_partition { | |||
41 | u_int32_t size; /* partition size */ | 41 | u_int32_t size; /* partition size */ |
42 | u_int32_t offset; /* offset within the master MTD space */ | 42 | u_int32_t offset; /* offset within the master MTD space */ |
43 | u_int32_t mask_flags; /* master MTD flags to mask out for this partition */ | 43 | u_int32_t mask_flags; /* master MTD flags to mask out for this partition */ |
44 | struct nand_oobinfo *oobsel; /* out of band layout for this partition (NAND only)*/ | 44 | struct nand_ecclayout *ecclayout; /* out of band layout for this partition (NAND only)*/ |
45 | struct mtd_info **mtdp; /* pointer to store the MTD object */ | 45 | struct mtd_info **mtdp; /* pointer to store the MTD object */ |
46 | }; | 46 | }; |
47 | 47 | ||
diff --git a/include/linux/mtd/physmap.h b/include/linux/mtd/physmap.h index c7b8bcdef013..86831e3594f6 100644 --- a/include/linux/mtd/physmap.h +++ b/include/linux/mtd/physmap.h | |||
@@ -15,33 +15,26 @@ | |||
15 | */ | 15 | */ |
16 | 16 | ||
17 | #ifndef __LINUX_MTD_PHYSMAP__ | 17 | #ifndef __LINUX_MTD_PHYSMAP__ |
18 | 18 | #define __LINUX_MTD_PHYSMAP__ | |
19 | #include <linux/config.h> | ||
20 | |||
21 | #if defined(CONFIG_MTD_PHYSMAP) | ||
22 | 19 | ||
23 | #include <linux/mtd/mtd.h> | 20 | #include <linux/mtd/mtd.h> |
24 | #include <linux/mtd/map.h> | 21 | #include <linux/mtd/map.h> |
25 | #include <linux/mtd/partitions.h> | 22 | #include <linux/mtd/partitions.h> |
26 | 23 | ||
27 | /* | 24 | struct physmap_flash_data { |
28 | * The map_info for physmap. Board can override size, buswidth, phys, | 25 | unsigned int width; |
29 | * (*set_vpp)(), etc in their initial setup routine. | 26 | void (*set_vpp)(struct map_info *, int); |
30 | */ | 27 | unsigned int nr_parts; |
31 | extern struct map_info physmap_map; | 28 | struct mtd_partition *parts; |
29 | }; | ||
32 | 30 | ||
33 | /* | 31 | /* |
34 | * Board needs to specify the exact mapping during their setup time. | 32 | * Board needs to specify the exact mapping during their setup time. |
35 | */ | 33 | */ |
36 | static inline void physmap_configure(unsigned long addr, unsigned long size, int bankwidth, void (*set_vpp)(struct map_info *, int) ) | 34 | void physmap_configure(unsigned long addr, unsigned long size, |
37 | { | 35 | int bankwidth, void (*set_vpp)(struct map_info *, int) ); |
38 | physmap_map.phys = addr; | ||
39 | physmap_map.size = size; | ||
40 | physmap_map.bankwidth = bankwidth; | ||
41 | physmap_map.set_vpp = set_vpp; | ||
42 | } | ||
43 | 36 | ||
44 | #if defined(CONFIG_MTD_PARTITIONS) | 37 | #ifdef CONFIG_MTD_PARTITIONS |
45 | 38 | ||
46 | /* | 39 | /* |
47 | * Machines that wish to do flash partition may want to call this function in | 40 | * Machines that wish to do flash partition may want to call this function in |
@@ -55,7 +48,5 @@ static inline void physmap_configure(unsigned long addr, unsigned long size, int | |||
55 | void physmap_set_partitions(struct mtd_partition *parts, int num_parts); | 48 | void physmap_set_partitions(struct mtd_partition *parts, int num_parts); |
56 | 49 | ||
57 | #endif /* defined(CONFIG_MTD_PARTITIONS) */ | 50 | #endif /* defined(CONFIG_MTD_PARTITIONS) */ |
58 | #endif /* defined(CONFIG_MTD) */ | ||
59 | 51 | ||
60 | #endif /* __LINUX_MTD_PHYSMAP__ */ | 52 | #endif /* __LINUX_MTD_PHYSMAP__ */ |
61 | |||
diff --git a/include/linux/mtd/xip.h b/include/linux/mtd/xip.h index 220d50bb71cd..e9d40bdde48c 100644 --- a/include/linux/mtd/xip.h +++ b/include/linux/mtd/xip.h | |||
@@ -18,7 +18,6 @@ | |||
18 | #ifndef __LINUX_MTD_XIP_H__ | 18 | #ifndef __LINUX_MTD_XIP_H__ |
19 | #define __LINUX_MTD_XIP_H__ | 19 | #define __LINUX_MTD_XIP_H__ |
20 | 20 | ||
21 | #include <linux/config.h> | ||
22 | 21 | ||
23 | #ifdef CONFIG_MTD_XIP | 22 | #ifdef CONFIG_MTD_XIP |
24 | 23 | ||
diff --git a/include/linux/nbd.h b/include/linux/nbd.h index a6ce409ec6fc..1d7cdd20b553 100644 --- a/include/linux/nbd.h +++ b/include/linux/nbd.h | |||
@@ -77,11 +77,11 @@ struct nbd_device { | |||
77 | * server. All data are in network byte order. | 77 | * server. All data are in network byte order. |
78 | */ | 78 | */ |
79 | struct nbd_request { | 79 | struct nbd_request { |
80 | u32 magic; | 80 | __u32 magic; |
81 | u32 type; /* == READ || == WRITE */ | 81 | __u32 type; /* == READ || == WRITE */ |
82 | char handle[8]; | 82 | char handle[8]; |
83 | u64 from; | 83 | __u64 from; |
84 | u32 len; | 84 | __u32 len; |
85 | } | 85 | } |
86 | #ifdef __GNUC__ | 86 | #ifdef __GNUC__ |
87 | __attribute__ ((packed)) | 87 | __attribute__ ((packed)) |
@@ -93,8 +93,8 @@ struct nbd_request { | |||
93 | * it has completed an I/O request (or an error occurs). | 93 | * it has completed an I/O request (or an error occurs). |
94 | */ | 94 | */ |
95 | struct nbd_reply { | 95 | struct nbd_reply { |
96 | u32 magic; | 96 | __u32 magic; |
97 | u32 error; /* 0 = ok, else error */ | 97 | __u32 error; /* 0 = ok, else error */ |
98 | char handle[8]; /* handle you got from request */ | 98 | char handle[8]; /* handle you got from request */ |
99 | }; | 99 | }; |
100 | #endif | 100 | #endif |
diff --git a/include/linux/ncp_fs.h b/include/linux/ncp_fs.h index 96dc237b8f03..b208f0cd556b 100644 --- a/include/linux/ncp_fs.h +++ b/include/linux/ncp_fs.h | |||
@@ -12,8 +12,6 @@ | |||
12 | #include <linux/in.h> | 12 | #include <linux/in.h> |
13 | #include <linux/types.h> | 13 | #include <linux/types.h> |
14 | 14 | ||
15 | #include <linux/ncp_fs_i.h> | ||
16 | #include <linux/ncp_fs_sb.h> | ||
17 | #include <linux/ipx.h> | 15 | #include <linux/ipx.h> |
18 | #include <linux/ncp_no.h> | 16 | #include <linux/ncp_no.h> |
19 | 17 | ||
@@ -146,7 +144,8 @@ struct ncp_nls_ioctl | |||
146 | 144 | ||
147 | #ifdef __KERNEL__ | 145 | #ifdef __KERNEL__ |
148 | 146 | ||
149 | #include <linux/config.h> | 147 | #include <linux/ncp_fs_i.h> |
148 | #include <linux/ncp_fs_sb.h> | ||
150 | 149 | ||
151 | /* undef because public define in umsdos_fs.h (ncp_fs.h isn't public) */ | 150 | /* undef because public define in umsdos_fs.h (ncp_fs.h isn't public) */ |
152 | #undef PRINTK | 151 | #undef PRINTK |
diff --git a/include/linux/net.h b/include/linux/net.h index 84a490e5f0a1..385e68f5bd93 100644 --- a/include/linux/net.h +++ b/include/linux/net.h | |||
@@ -18,9 +18,7 @@ | |||
18 | #ifndef _LINUX_NET_H | 18 | #ifndef _LINUX_NET_H |
19 | #define _LINUX_NET_H | 19 | #define _LINUX_NET_H |
20 | 20 | ||
21 | #include <linux/config.h> | ||
22 | #include <linux/wait.h> | 21 | #include <linux/wait.h> |
23 | #include <linux/stringify.h> | ||
24 | #include <asm/socket.h> | 22 | #include <asm/socket.h> |
25 | 23 | ||
26 | struct poll_table_struct; | 24 | struct poll_table_struct; |
@@ -57,6 +55,7 @@ typedef enum { | |||
57 | #define __SO_ACCEPTCON (1 << 16) /* performed a listen */ | 55 | #define __SO_ACCEPTCON (1 << 16) /* performed a listen */ |
58 | 56 | ||
59 | #ifdef __KERNEL__ | 57 | #ifdef __KERNEL__ |
58 | #include <linux/stringify.h> | ||
60 | 59 | ||
61 | #define SOCK_ASYNC_NOSPACE 0 | 60 | #define SOCK_ASYNC_NOSPACE 0 |
62 | #define SOCK_ASYNC_WAITDATA 1 | 61 | #define SOCK_ASYNC_WAITDATA 1 |
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index f4169bbb60eb..cead6be467ed 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h | |||
@@ -34,9 +34,9 @@ | |||
34 | #include <asm/cache.h> | 34 | #include <asm/cache.h> |
35 | #include <asm/byteorder.h> | 35 | #include <asm/byteorder.h> |
36 | 36 | ||
37 | #include <linux/config.h> | ||
38 | #include <linux/device.h> | 37 | #include <linux/device.h> |
39 | #include <linux/percpu.h> | 38 | #include <linux/percpu.h> |
39 | #include <linux/dmaengine.h> | ||
40 | 40 | ||
41 | struct divert_blk; | 41 | struct divert_blk; |
42 | struct vlan_group; | 42 | struct vlan_group; |
@@ -232,6 +232,7 @@ enum netdev_state_t | |||
232 | __LINK_STATE_RX_SCHED, | 232 | __LINK_STATE_RX_SCHED, |
233 | __LINK_STATE_LINKWATCH_PENDING, | 233 | __LINK_STATE_LINKWATCH_PENDING, |
234 | __LINK_STATE_DORMANT, | 234 | __LINK_STATE_DORMANT, |
235 | __LINK_STATE_QDISC_RUNNING, | ||
235 | }; | 236 | }; |
236 | 237 | ||
237 | 238 | ||
@@ -311,6 +312,9 @@ struct net_device | |||
311 | #define NETIF_F_LLTX 4096 /* LockLess TX */ | 312 | #define NETIF_F_LLTX 4096 /* LockLess TX */ |
312 | #define NETIF_F_UFO 8192 /* Can offload UDP Large Send*/ | 313 | #define NETIF_F_UFO 8192 /* Can offload UDP Large Send*/ |
313 | 314 | ||
315 | #define NETIF_F_GEN_CSUM (NETIF_F_NO_CSUM | NETIF_F_HW_CSUM) | ||
316 | #define NETIF_F_ALL_CSUM (NETIF_F_IP_CSUM | NETIF_F_GEN_CSUM) | ||
317 | |||
314 | struct net_device *next_sched; | 318 | struct net_device *next_sched; |
315 | 319 | ||
316 | /* Interface index. Unique device identifier */ | 320 | /* Interface index. Unique device identifier */ |
@@ -406,7 +410,7 @@ struct net_device | |||
406 | * One part is mostly used on xmit path (device) | 410 | * One part is mostly used on xmit path (device) |
407 | */ | 411 | */ |
408 | /* hard_start_xmit synchronizer */ | 412 | /* hard_start_xmit synchronizer */ |
409 | spinlock_t xmit_lock ____cacheline_aligned_in_smp; | 413 | spinlock_t _xmit_lock ____cacheline_aligned_in_smp; |
410 | /* cpu id of processor entered to hard_start_xmit or -1, | 414 | /* cpu id of processor entered to hard_start_xmit or -1, |
411 | if nobody entered there. | 415 | if nobody entered there. |
412 | */ | 416 | */ |
@@ -593,6 +597,9 @@ struct softnet_data | |||
593 | struct sk_buff *completion_queue; | 597 | struct sk_buff *completion_queue; |
594 | 598 | ||
595 | struct net_device backlog_dev; /* Sorry. 8) */ | 599 | struct net_device backlog_dev; /* Sorry. 8) */ |
600 | #ifdef CONFIG_NET_DMA | ||
601 | struct dma_chan *net_dma; | ||
602 | #endif | ||
596 | }; | 603 | }; |
597 | 604 | ||
598 | DECLARE_PER_CPU(struct softnet_data,softnet_data); | 605 | DECLARE_PER_CPU(struct softnet_data,softnet_data); |
@@ -889,11 +896,43 @@ static inline void __netif_rx_complete(struct net_device *dev) | |||
889 | clear_bit(__LINK_STATE_RX_SCHED, &dev->state); | 896 | clear_bit(__LINK_STATE_RX_SCHED, &dev->state); |
890 | } | 897 | } |
891 | 898 | ||
899 | static inline void netif_tx_lock(struct net_device *dev) | ||
900 | { | ||
901 | spin_lock(&dev->_xmit_lock); | ||
902 | dev->xmit_lock_owner = smp_processor_id(); | ||
903 | } | ||
904 | |||
905 | static inline void netif_tx_lock_bh(struct net_device *dev) | ||
906 | { | ||
907 | spin_lock_bh(&dev->_xmit_lock); | ||
908 | dev->xmit_lock_owner = smp_processor_id(); | ||
909 | } | ||
910 | |||
911 | static inline int netif_tx_trylock(struct net_device *dev) | ||
912 | { | ||
913 | int err = spin_trylock(&dev->_xmit_lock); | ||
914 | if (!err) | ||
915 | dev->xmit_lock_owner = smp_processor_id(); | ||
916 | return err; | ||
917 | } | ||
918 | |||
919 | static inline void netif_tx_unlock(struct net_device *dev) | ||
920 | { | ||
921 | dev->xmit_lock_owner = -1; | ||
922 | spin_unlock(&dev->_xmit_lock); | ||
923 | } | ||
924 | |||
925 | static inline void netif_tx_unlock_bh(struct net_device *dev) | ||
926 | { | ||
927 | dev->xmit_lock_owner = -1; | ||
928 | spin_unlock_bh(&dev->_xmit_lock); | ||
929 | } | ||
930 | |||
892 | static inline void netif_tx_disable(struct net_device *dev) | 931 | static inline void netif_tx_disable(struct net_device *dev) |
893 | { | 932 | { |
894 | spin_lock_bh(&dev->xmit_lock); | 933 | netif_tx_lock_bh(dev); |
895 | netif_stop_queue(dev); | 934 | netif_stop_queue(dev); |
896 | spin_unlock_bh(&dev->xmit_lock); | 935 | netif_tx_unlock_bh(dev); |
897 | } | 936 | } |
898 | 937 | ||
899 | /* These functions live elsewhere (drivers/net/net_init.c, but related) */ | 938 | /* These functions live elsewhere (drivers/net/net_init.c, but related) */ |
diff --git a/include/linux/netfilter.h b/include/linux/netfilter.h index b31a9bca9361..10168e26a846 100644 --- a/include/linux/netfilter.h +++ b/include/linux/netfilter.h | |||
@@ -40,7 +40,6 @@ | |||
40 | #endif | 40 | #endif |
41 | 41 | ||
42 | #ifdef __KERNEL__ | 42 | #ifdef __KERNEL__ |
43 | #include <linux/config.h> | ||
44 | #ifdef CONFIG_NETFILTER | 43 | #ifdef CONFIG_NETFILTER |
45 | 44 | ||
46 | extern void netfilter_init(void); | 45 | extern void netfilter_init(void); |
diff --git a/include/linux/netfilter/nf_conntrack_common.h b/include/linux/netfilter/nf_conntrack_common.h index 3ff88c878308..d2e4bd7a7a14 100644 --- a/include/linux/netfilter/nf_conntrack_common.h +++ b/include/linux/netfilter/nf_conntrack_common.h | |||
@@ -69,6 +69,10 @@ enum ip_conntrack_status { | |||
69 | /* Connection is dying (removed from lists), can not be unset. */ | 69 | /* Connection is dying (removed from lists), can not be unset. */ |
70 | IPS_DYING_BIT = 9, | 70 | IPS_DYING_BIT = 9, |
71 | IPS_DYING = (1 << IPS_DYING_BIT), | 71 | IPS_DYING = (1 << IPS_DYING_BIT), |
72 | |||
73 | /* Connection has fixed timeout. */ | ||
74 | IPS_FIXED_TIMEOUT_BIT = 10, | ||
75 | IPS_FIXED_TIMEOUT = (1 << IPS_FIXED_TIMEOUT_BIT), | ||
72 | }; | 76 | }; |
73 | 77 | ||
74 | /* Connection tracking event bits */ | 78 | /* Connection tracking event bits */ |
diff --git a/include/linux/netfilter/nfnetlink_conntrack.h b/include/linux/netfilter/nfnetlink_conntrack.h index 668ec946c8e2..b5883ccee295 100644 --- a/include/linux/netfilter/nfnetlink_conntrack.h +++ b/include/linux/netfilter/nfnetlink_conntrack.h | |||
@@ -27,13 +27,15 @@ enum ctattr_type { | |||
27 | CTA_STATUS, | 27 | CTA_STATUS, |
28 | CTA_PROTOINFO, | 28 | CTA_PROTOINFO, |
29 | CTA_HELP, | 29 | CTA_HELP, |
30 | CTA_NAT, | 30 | CTA_NAT_SRC, |
31 | #define CTA_NAT CTA_NAT_SRC /* backwards compatibility */ | ||
31 | CTA_TIMEOUT, | 32 | CTA_TIMEOUT, |
32 | CTA_MARK, | 33 | CTA_MARK, |
33 | CTA_COUNTERS_ORIG, | 34 | CTA_COUNTERS_ORIG, |
34 | CTA_COUNTERS_REPLY, | 35 | CTA_COUNTERS_REPLY, |
35 | CTA_USE, | 36 | CTA_USE, |
36 | CTA_ID, | 37 | CTA_ID, |
38 | CTA_NAT_DST, | ||
37 | __CTA_MAX | 39 | __CTA_MAX |
38 | }; | 40 | }; |
39 | #define CTA_MAX (__CTA_MAX - 1) | 41 | #define CTA_MAX (__CTA_MAX - 1) |
diff --git a/include/linux/netfilter/xt_CONNSECMARK.h b/include/linux/netfilter/xt_CONNSECMARK.h new file mode 100644 index 000000000000..c6bd75469ba2 --- /dev/null +++ b/include/linux/netfilter/xt_CONNSECMARK.h | |||
@@ -0,0 +1,13 @@ | |||
1 | #ifndef _XT_CONNSECMARK_H_target | ||
2 | #define _XT_CONNSECMARK_H_target | ||
3 | |||
4 | enum { | ||
5 | CONNSECMARK_SAVE = 1, | ||
6 | CONNSECMARK_RESTORE, | ||
7 | }; | ||
8 | |||
9 | struct xt_connsecmark_target_info { | ||
10 | u_int8_t mode; | ||
11 | }; | ||
12 | |||
13 | #endif /*_XT_CONNSECMARK_H_target */ | ||
diff --git a/include/linux/netfilter/xt_SECMARK.h b/include/linux/netfilter/xt_SECMARK.h new file mode 100644 index 000000000000..c53fbffa997d --- /dev/null +++ b/include/linux/netfilter/xt_SECMARK.h | |||
@@ -0,0 +1,26 @@ | |||
1 | #ifndef _XT_SECMARK_H_target | ||
2 | #define _XT_SECMARK_H_target | ||
3 | |||
4 | /* | ||
5 | * This is intended for use by various security subsystems (but not | ||
6 | * at the same time). | ||
7 | * | ||
8 | * 'mode' refers to the specific security subsystem which the | ||
9 | * packets are being marked for. | ||
10 | */ | ||
11 | #define SECMARK_MODE_SEL 0x01 /* SELinux */ | ||
12 | #define SECMARK_SELCTX_MAX 256 | ||
13 | |||
14 | struct xt_secmark_target_selinux_info { | ||
15 | u_int32_t selsid; | ||
16 | char selctx[SECMARK_SELCTX_MAX]; | ||
17 | }; | ||
18 | |||
19 | struct xt_secmark_target_info { | ||
20 | u_int8_t mode; | ||
21 | union { | ||
22 | struct xt_secmark_target_selinux_info sel; | ||
23 | } u; | ||
24 | }; | ||
25 | |||
26 | #endif /*_XT_SECMARK_H_target */ | ||
diff --git a/include/linux/netfilter/xt_conntrack.h b/include/linux/netfilter/xt_conntrack.h index 34f63cf2e293..4c2d9945ca54 100644 --- a/include/linux/netfilter/xt_conntrack.h +++ b/include/linux/netfilter/xt_conntrack.h | |||
@@ -42,7 +42,7 @@ struct ip_conntrack_old_tuple | |||
42 | } u; | 42 | } u; |
43 | 43 | ||
44 | /* The protocol. */ | 44 | /* The protocol. */ |
45 | u16 protonum; | 45 | __u16 protonum; |
46 | } dst; | 46 | } dst; |
47 | }; | 47 | }; |
48 | 48 | ||
diff --git a/include/linux/netfilter/xt_quota.h b/include/linux/netfilter/xt_quota.h new file mode 100644 index 000000000000..acd7fd77bbee --- /dev/null +++ b/include/linux/netfilter/xt_quota.h | |||
@@ -0,0 +1,16 @@ | |||
1 | #ifndef _XT_QUOTA_H | ||
2 | #define _XT_QUOTA_H | ||
3 | |||
4 | enum xt_quota_flags { | ||
5 | XT_QUOTA_INVERT = 0x1, | ||
6 | }; | ||
7 | #define XT_QUOTA_MASK 0x1 | ||
8 | |||
9 | struct xt_quota_info { | ||
10 | u_int32_t flags; | ||
11 | u_int32_t pad; | ||
12 | aligned_u64 quota; | ||
13 | struct xt_quota_info *master; | ||
14 | }; | ||
15 | |||
16 | #endif /* _XT_QUOTA_H */ | ||
diff --git a/include/linux/netfilter/xt_statistic.h b/include/linux/netfilter/xt_statistic.h new file mode 100644 index 000000000000..c344e9916e23 --- /dev/null +++ b/include/linux/netfilter/xt_statistic.h | |||
@@ -0,0 +1,32 @@ | |||
1 | #ifndef _XT_STATISTIC_H | ||
2 | #define _XT_STATISTIC_H | ||
3 | |||
4 | enum xt_statistic_mode { | ||
5 | XT_STATISTIC_MODE_RANDOM, | ||
6 | XT_STATISTIC_MODE_NTH, | ||
7 | __XT_STATISTIC_MODE_MAX | ||
8 | }; | ||
9 | #define XT_STATISTIC_MODE_MAX (__XT_STATISTIC_MODE_MAX - 1) | ||
10 | |||
11 | enum xt_statistic_flags { | ||
12 | XT_STATISTIC_INVERT = 0x1, | ||
13 | }; | ||
14 | #define XT_STATISTIC_MASK 0x1 | ||
15 | |||
16 | struct xt_statistic_info { | ||
17 | u_int16_t mode; | ||
18 | u_int16_t flags; | ||
19 | union { | ||
20 | struct { | ||
21 | u_int32_t probability; | ||
22 | } random; | ||
23 | struct { | ||
24 | u_int32_t every; | ||
25 | u_int32_t packet; | ||
26 | u_int32_t count; | ||
27 | } nth; | ||
28 | } u; | ||
29 | struct xt_statistic_info *master __attribute__((aligned(8))); | ||
30 | }; | ||
31 | |||
32 | #endif /* _XT_STATISTIC_H */ | ||
diff --git a/include/linux/netfilter_arp.h b/include/linux/netfilter_arp.h index a3f8977f7f12..92bc6ddcbf73 100644 --- a/include/linux/netfilter_arp.h +++ b/include/linux/netfilter_arp.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * (C)2002 Rusty Russell IBM -- This code is GPL. | 5 | * (C)2002 Rusty Russell IBM -- This code is GPL. |
6 | */ | 6 | */ |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | #include <linux/netfilter.h> | 8 | #include <linux/netfilter.h> |
10 | 9 | ||
11 | /* There is no PF_ARP. */ | 10 | /* There is no PF_ARP. */ |
diff --git a/include/linux/netfilter_bridge.h b/include/linux/netfilter_bridge.h index a75b84bb9a88..87764022cc67 100644 --- a/include/linux/netfilter_bridge.h +++ b/include/linux/netfilter_bridge.h | |||
@@ -4,7 +4,6 @@ | |||
4 | /* bridge-specific defines for netfilter. | 4 | /* bridge-specific defines for netfilter. |
5 | */ | 5 | */ |
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | #include <linux/netfilter.h> | 7 | #include <linux/netfilter.h> |
9 | #if defined(__KERNEL__) && defined(CONFIG_BRIDGE_NETFILTER) | 8 | #if defined(__KERNEL__) && defined(CONFIG_BRIDGE_NETFILTER) |
10 | #include <asm/atomic.h> | 9 | #include <asm/atomic.h> |
diff --git a/include/linux/netfilter_ipv4.h b/include/linux/netfilter_ipv4.h index 85301c5e8d24..ce02c984f3ba 100644 --- a/include/linux/netfilter_ipv4.h +++ b/include/linux/netfilter_ipv4.h | |||
@@ -5,7 +5,6 @@ | |||
5 | * (C)1998 Rusty Russell -- This code is GPL. | 5 | * (C)1998 Rusty Russell -- This code is GPL. |
6 | */ | 6 | */ |
7 | 7 | ||
8 | #include <linux/config.h> | ||
9 | #include <linux/netfilter.h> | 8 | #include <linux/netfilter.h> |
10 | 9 | ||
11 | /* only for userspace compatibility */ | 10 | /* only for userspace compatibility */ |
diff --git a/include/linux/netfilter_ipv4/ip_conntrack.h b/include/linux/netfilter_ipv4/ip_conntrack.h index d54d7b278e96..51dbec1892c8 100644 --- a/include/linux/netfilter_ipv4/ip_conntrack.h +++ b/include/linux/netfilter_ipv4/ip_conntrack.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #include <linux/netfilter/nf_conntrack_common.h> | 4 | #include <linux/netfilter/nf_conntrack_common.h> |
5 | 5 | ||
6 | #ifdef __KERNEL__ | 6 | #ifdef __KERNEL__ |
7 | #include <linux/config.h> | ||
8 | #include <linux/netfilter_ipv4/ip_conntrack_tuple.h> | 7 | #include <linux/netfilter_ipv4/ip_conntrack_tuple.h> |
9 | #include <linux/bitops.h> | 8 | #include <linux/bitops.h> |
10 | #include <linux/compiler.h> | 9 | #include <linux/compiler.h> |
@@ -121,6 +120,10 @@ struct ip_conntrack | |||
121 | u_int32_t mark; | 120 | u_int32_t mark; |
122 | #endif | 121 | #endif |
123 | 122 | ||
123 | #ifdef CONFIG_IP_NF_CONNTRACK_SECMARK | ||
124 | u_int32_t secmark; | ||
125 | #endif | ||
126 | |||
124 | /* Traversed often, so hopefully in different cacheline to top */ | 127 | /* Traversed often, so hopefully in different cacheline to top */ |
125 | /* These are my tuples; original and reply */ | 128 | /* These are my tuples; original and reply */ |
126 | struct ip_conntrack_tuple_hash tuplehash[IP_CT_DIR_MAX]; | 129 | struct ip_conntrack_tuple_hash tuplehash[IP_CT_DIR_MAX]; |
@@ -154,6 +157,7 @@ struct ip_conntrack_expect | |||
154 | unsigned int flags; | 157 | unsigned int flags; |
155 | 158 | ||
156 | #ifdef CONFIG_IP_NF_NAT_NEEDED | 159 | #ifdef CONFIG_IP_NF_NAT_NEEDED |
160 | u_int32_t saved_ip; | ||
157 | /* This is the original per-proto part, used to map the | 161 | /* This is the original per-proto part, used to map the |
158 | * expected connection the way the recipient expects. */ | 162 | * expected connection the way the recipient expects. */ |
159 | union ip_conntrack_manip_proto saved_proto; | 163 | union ip_conntrack_manip_proto saved_proto; |
@@ -293,6 +297,7 @@ static inline int is_dying(struct ip_conntrack *ct) | |||
293 | } | 297 | } |
294 | 298 | ||
295 | extern unsigned int ip_conntrack_htable_size; | 299 | extern unsigned int ip_conntrack_htable_size; |
300 | extern int ip_conntrack_checksum; | ||
296 | 301 | ||
297 | #define CONNTRACK_STAT_INC(count) (__get_cpu_var(ip_conntrack_stat).count++) | 302 | #define CONNTRACK_STAT_INC(count) (__get_cpu_var(ip_conntrack_stat).count++) |
298 | 303 | ||
diff --git a/include/linux/netfilter_ipv4/ip_conntrack_h323.h b/include/linux/netfilter_ipv4/ip_conntrack_h323.h index eace86bd2adb..3cbff7379002 100644 --- a/include/linux/netfilter_ipv4/ip_conntrack_h323.h +++ b/include/linux/netfilter_ipv4/ip_conntrack_h323.h | |||
@@ -71,6 +71,13 @@ extern int (*nat_h245_hook) (struct sk_buff ** pskb, struct ip_conntrack * ct, | |||
71 | unsigned char **data, int dataoff, | 71 | unsigned char **data, int dataoff, |
72 | TransportAddress * addr, u_int16_t port, | 72 | TransportAddress * addr, u_int16_t port, |
73 | struct ip_conntrack_expect * exp); | 73 | struct ip_conntrack_expect * exp); |
74 | extern int (*nat_callforwarding_hook) (struct sk_buff ** pskb, | ||
75 | struct ip_conntrack * ct, | ||
76 | enum ip_conntrack_info ctinfo, | ||
77 | unsigned char **data, int dataoff, | ||
78 | TransportAddress * addr, | ||
79 | u_int16_t port, | ||
80 | struct ip_conntrack_expect * exp); | ||
74 | extern int (*nat_q931_hook) (struct sk_buff ** pskb, struct ip_conntrack * ct, | 81 | extern int (*nat_q931_hook) (struct sk_buff ** pskb, struct ip_conntrack * ct, |
75 | enum ip_conntrack_info ctinfo, | 82 | enum ip_conntrack_info ctinfo, |
76 | unsigned char **data, TransportAddress * addr, | 83 | unsigned char **data, TransportAddress * addr, |
diff --git a/include/linux/netfilter_ipv4/ip_conntrack_helper_h323_types.h b/include/linux/netfilter_ipv4/ip_conntrack_helper_h323_types.h index cc98f7aa5abe..3d4a773799fc 100644 --- a/include/linux/netfilter_ipv4/ip_conntrack_helper_h323_types.h +++ b/include/linux/netfilter_ipv4/ip_conntrack_helper_h323_types.h | |||
@@ -1,4 +1,4 @@ | |||
1 | /* Generated by Jing Min Zhao's ASN.1 parser, Mar 15 2006 | 1 | /* Generated by Jing Min Zhao's ASN.1 parser, Apr 20 2006 |
2 | * | 2 | * |
3 | * Copyright (c) 2006 Jing Min Zhao <zhaojingmin@users.sourceforge.net> | 3 | * Copyright (c) 2006 Jing Min Zhao <zhaojingmin@users.sourceforge.net> |
4 | * | 4 | * |
@@ -412,6 +412,7 @@ typedef struct Facility_UUIE { /* SEQUENCE */ | |||
412 | eFacility_UUIE_destinationInfo = (1 << 14), | 412 | eFacility_UUIE_destinationInfo = (1 << 14), |
413 | eFacility_UUIE_h245SecurityMode = (1 << 13), | 413 | eFacility_UUIE_h245SecurityMode = (1 << 13), |
414 | } options; | 414 | } options; |
415 | TransportAddress alternativeAddress; | ||
415 | FacilityReason reason; | 416 | FacilityReason reason; |
416 | TransportAddress h245Address; | 417 | TransportAddress h245Address; |
417 | Facility_UUIE_fastStart fastStart; | 418 | Facility_UUIE_fastStart fastStart; |
diff --git a/include/linux/netfilter_ipv4/ip_conntrack_sip.h b/include/linux/netfilter_ipv4/ip_conntrack_sip.h new file mode 100644 index 000000000000..913dad66c0fb --- /dev/null +++ b/include/linux/netfilter_ipv4/ip_conntrack_sip.h | |||
@@ -0,0 +1,44 @@ | |||
1 | #ifndef __IP_CONNTRACK_SIP_H__ | ||
2 | #define __IP_CONNTRACK_SIP_H__ | ||
3 | #ifdef __KERNEL__ | ||
4 | |||
5 | #define SIP_PORT 5060 | ||
6 | #define SIP_TIMEOUT 3600 | ||
7 | |||
8 | #define POS_VIA 0 | ||
9 | #define POS_CONTACT 1 | ||
10 | #define POS_CONTENT 2 | ||
11 | #define POS_MEDIA 3 | ||
12 | #define POS_OWNER 4 | ||
13 | #define POS_CONNECTION 5 | ||
14 | #define POS_REQ_HEADER 6 | ||
15 | #define POS_SDP_HEADER 7 | ||
16 | |||
17 | struct sip_header_nfo { | ||
18 | const char *lname; | ||
19 | const char *sname; | ||
20 | const char *ln_str; | ||
21 | size_t lnlen; | ||
22 | size_t snlen; | ||
23 | size_t ln_strlen; | ||
24 | int (*match_len)(const char *, const char *, int *); | ||
25 | }; | ||
26 | |||
27 | extern unsigned int (*ip_nat_sip_hook)(struct sk_buff **pskb, | ||
28 | enum ip_conntrack_info ctinfo, | ||
29 | struct ip_conntrack *ct, | ||
30 | const char **dptr); | ||
31 | extern unsigned int (*ip_nat_sdp_hook)(struct sk_buff **pskb, | ||
32 | enum ip_conntrack_info ctinfo, | ||
33 | struct ip_conntrack_expect *exp, | ||
34 | const char *dptr); | ||
35 | |||
36 | extern int ct_sip_get_info(const char *dptr, size_t dlen, | ||
37 | unsigned int *matchoff, | ||
38 | unsigned int *matchlen, | ||
39 | struct sip_header_nfo *hnfo); | ||
40 | extern int ct_sip_lnlen(const char *line, const char *limit); | ||
41 | extern const char *ct_sip_search(const char *needle, const char *haystack, | ||
42 | size_t needle_len, size_t haystack_len); | ||
43 | #endif /* __KERNEL__ */ | ||
44 | #endif /* __IP_CONNTRACK_SIP_H__ */ | ||
diff --git a/include/linux/netfilter_ipv4/listhelp.h b/include/linux/netfilter_ipv4/listhelp.h index 360429f48737..5d92cf044d91 100644 --- a/include/linux/netfilter_ipv4/listhelp.h +++ b/include/linux/netfilter_ipv4/listhelp.h | |||
@@ -1,6 +1,5 @@ | |||
1 | #ifndef _LISTHELP_H | 1 | #ifndef _LISTHELP_H |
2 | #define _LISTHELP_H | 2 | #define _LISTHELP_H |
3 | #include <linux/config.h> | ||
4 | #include <linux/list.h> | 3 | #include <linux/list.h> |
5 | 4 | ||
6 | /* Header to do more comprehensive job than linux/list.h; assume list | 5 | /* Header to do more comprehensive job than linux/list.h; assume list |
diff --git a/include/linux/netlink.h b/include/linux/netlink.h index 87b8a5703ebc..855b44668caa 100644 --- a/include/linux/netlink.h +++ b/include/linux/netlink.h | |||
@@ -5,7 +5,7 @@ | |||
5 | #include <linux/types.h> | 5 | #include <linux/types.h> |
6 | 6 | ||
7 | #define NETLINK_ROUTE 0 /* Routing/device hook */ | 7 | #define NETLINK_ROUTE 0 /* Routing/device hook */ |
8 | #define NETLINK_W1 1 /* 1-wire subsystem */ | 8 | #define NETLINK_UNUSED 1 /* Unused number */ |
9 | #define NETLINK_USERSOCK 2 /* Reserved for user mode socket protocols */ | 9 | #define NETLINK_USERSOCK 2 /* Reserved for user mode socket protocols */ |
10 | #define NETLINK_FIREWALL 3 /* Firewalling hook */ | 10 | #define NETLINK_FIREWALL 3 /* Firewalling hook */ |
11 | #define NETLINK_INET_DIAG 4 /* INET socket monitoring */ | 11 | #define NETLINK_INET_DIAG 4 /* INET socket monitoring */ |
diff --git a/include/linux/nfs.h b/include/linux/nfs.h index ca2ffa6ae1d5..54af92c1c70b 100644 --- a/include/linux/nfs.h +++ b/include/linux/nfs.h | |||
@@ -7,9 +7,6 @@ | |||
7 | #ifndef _LINUX_NFS_H | 7 | #ifndef _LINUX_NFS_H |
8 | #define _LINUX_NFS_H | 8 | #define _LINUX_NFS_H |
9 | 9 | ||
10 | #include <linux/sunrpc/msg_prot.h> | ||
11 | #include <linux/string.h> | ||
12 | |||
13 | #define NFS_PROGRAM 100003 | 10 | #define NFS_PROGRAM 100003 |
14 | #define NFS_PORT 2049 | 11 | #define NFS_PORT 2049 |
15 | #define NFS_MAXDATA 8192 | 12 | #define NFS_MAXDATA 8192 |
@@ -129,7 +126,10 @@ enum nfs_ftype { | |||
129 | NFFIFO = 8 | 126 | NFFIFO = 8 |
130 | }; | 127 | }; |
131 | 128 | ||
132 | #if defined(__KERNEL__) | 129 | #ifdef __KERNEL__ |
130 | #include <linux/sunrpc/msg_prot.h> | ||
131 | #include <linux/string.h> | ||
132 | |||
133 | /* | 133 | /* |
134 | * This is the kernel NFS client file handle representation | 134 | * This is the kernel NFS client file handle representation |
135 | */ | 135 | */ |
diff --git a/include/linux/nfs4.h b/include/linux/nfs4.h index 0c1c306cdaec..1059e6d69d3b 100644 --- a/include/linux/nfs4.h +++ b/include/linux/nfs4.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #define _LINUX_NFS4_H | 14 | #define _LINUX_NFS4_H |
15 | 15 | ||
16 | #include <linux/types.h> | 16 | #include <linux/types.h> |
17 | #include <linux/list.h> | ||
18 | 17 | ||
19 | #define NFS4_VERIFIER_SIZE 8 | 18 | #define NFS4_VERIFIER_SIZE 8 |
20 | #define NFS4_FHSIZE 128 | 19 | #define NFS4_FHSIZE 128 |
@@ -97,6 +96,9 @@ enum nfs4_acl_whotype { | |||
97 | NFS4_ACL_WHO_EVERYONE, | 96 | NFS4_ACL_WHO_EVERYONE, |
98 | }; | 97 | }; |
99 | 98 | ||
99 | #ifdef __KERNEL__ | ||
100 | #include <linux/list.h> | ||
101 | |||
100 | struct nfs4_ace { | 102 | struct nfs4_ace { |
101 | uint32_t type; | 103 | uint32_t type; |
102 | uint32_t flag; | 104 | uint32_t flag; |
@@ -345,8 +347,6 @@ enum lock_type4 { | |||
345 | #define NFS4_MINOR_VERSION 0 | 347 | #define NFS4_MINOR_VERSION 0 |
346 | #define NFS4_DEBUG 1 | 348 | #define NFS4_DEBUG 1 |
347 | 349 | ||
348 | #ifdef __KERNEL__ | ||
349 | |||
350 | /* Index of predefined Linux client operations */ | 350 | /* Index of predefined Linux client operations */ |
351 | 351 | ||
352 | enum { | 352 | enum { |
diff --git a/include/linux/nfs_fs.h b/include/linux/nfs_fs.h index c71227dd4389..7e079f8ce18b 100644 --- a/include/linux/nfs_fs.h +++ b/include/linux/nfs_fs.h | |||
@@ -9,26 +9,6 @@ | |||
9 | #ifndef _LINUX_NFS_FS_H | 9 | #ifndef _LINUX_NFS_FS_H |
10 | #define _LINUX_NFS_FS_H | 10 | #define _LINUX_NFS_FS_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/in.h> | ||
14 | #include <linux/mm.h> | ||
15 | #include <linux/pagemap.h> | ||
16 | #include <linux/rwsem.h> | ||
17 | #include <linux/wait.h> | ||
18 | |||
19 | #include <linux/nfs_fs_sb.h> | ||
20 | |||
21 | #include <linux/sunrpc/debug.h> | ||
22 | #include <linux/sunrpc/auth.h> | ||
23 | #include <linux/sunrpc/clnt.h> | ||
24 | |||
25 | #include <linux/nfs.h> | ||
26 | #include <linux/nfs2.h> | ||
27 | #include <linux/nfs3.h> | ||
28 | #include <linux/nfs4.h> | ||
29 | #include <linux/nfs_xdr.h> | ||
30 | #include <linux/rwsem.h> | ||
31 | #include <linux/mempool.h> | ||
32 | 12 | ||
33 | /* | 13 | /* |
34 | * Enable debugging support for nfs client. | 14 | * Enable debugging support for nfs client. |
@@ -63,6 +43,25 @@ | |||
63 | #define FLUSH_NOCOMMIT 32 /* Don't send the NFSv3/v4 COMMIT */ | 43 | #define FLUSH_NOCOMMIT 32 /* Don't send the NFSv3/v4 COMMIT */ |
64 | 44 | ||
65 | #ifdef __KERNEL__ | 45 | #ifdef __KERNEL__ |
46 | #include <linux/in.h> | ||
47 | #include <linux/mm.h> | ||
48 | #include <linux/pagemap.h> | ||
49 | #include <linux/rwsem.h> | ||
50 | #include <linux/wait.h> | ||
51 | |||
52 | #include <linux/nfs_fs_sb.h> | ||
53 | |||
54 | #include <linux/sunrpc/debug.h> | ||
55 | #include <linux/sunrpc/auth.h> | ||
56 | #include <linux/sunrpc/clnt.h> | ||
57 | |||
58 | #include <linux/nfs.h> | ||
59 | #include <linux/nfs2.h> | ||
60 | #include <linux/nfs3.h> | ||
61 | #include <linux/nfs4.h> | ||
62 | #include <linux/nfs_xdr.h> | ||
63 | #include <linux/rwsem.h> | ||
64 | #include <linux/mempool.h> | ||
66 | 65 | ||
67 | /* | 66 | /* |
68 | * NFSv3/v4 Access mode cache entry | 67 | * NFSv3/v4 Access mode cache entry |
diff --git a/include/linux/nfsd/nfsd.h b/include/linux/nfsd/nfsd.h index ec7c2e872d72..2dcad295fece 100644 --- a/include/linux/nfsd/nfsd.h +++ b/include/linux/nfsd/nfsd.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef LINUX_NFSD_NFSD_H | 10 | #ifndef LINUX_NFSD_NFSD_H |
11 | #define LINUX_NFSD_NFSD_H | 11 | #define LINUX_NFSD_NFSD_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/types.h> | 13 | #include <linux/types.h> |
15 | #include <linux/unistd.h> | 14 | #include <linux/unistd.h> |
16 | #include <linux/dirent.h> | 15 | #include <linux/dirent.h> |
diff --git a/include/linux/nfsd/nfsfh.h b/include/linux/nfsd/nfsfh.h index 0798b7781a6e..f9edcd2ff3c8 100644 --- a/include/linux/nfsd/nfsfh.h +++ b/include/linux/nfsd/nfsfh.h | |||
@@ -16,7 +16,6 @@ | |||
16 | 16 | ||
17 | #include <asm/types.h> | 17 | #include <asm/types.h> |
18 | #ifdef __KERNEL__ | 18 | #ifdef __KERNEL__ |
19 | # include <linux/config.h> | ||
20 | # include <linux/types.h> | 19 | # include <linux/types.h> |
21 | # include <linux/string.h> | 20 | # include <linux/string.h> |
22 | # include <linux/fs.h> | 21 | # include <linux/fs.h> |
diff --git a/include/linux/nfsd/syscall.h b/include/linux/nfsd/syscall.h index 781efbf94ed3..dae0faea2807 100644 --- a/include/linux/nfsd/syscall.h +++ b/include/linux/nfsd/syscall.h | |||
@@ -11,7 +11,6 @@ | |||
11 | 11 | ||
12 | #include <asm/types.h> | 12 | #include <asm/types.h> |
13 | #ifdef __KERNEL__ | 13 | #ifdef __KERNEL__ |
14 | # include <linux/config.h> | ||
15 | # include <linux/types.h> | 14 | # include <linux/types.h> |
16 | # include <linux/in.h> | 15 | # include <linux/in.h> |
17 | #endif | 16 | #endif |
diff --git a/include/linux/numa.h b/include/linux/numa.h index e481feb1bfd8..a31a7301b159 100644 --- a/include/linux/numa.h +++ b/include/linux/numa.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _LINUX_NUMA_H | 1 | #ifndef _LINUX_NUMA_H |
2 | #define _LINUX_NUMA_H | 2 | #define _LINUX_NUMA_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_NODES_SHIFT | 5 | #ifdef CONFIG_NODES_SHIFT |
7 | #define NODES_SHIFT CONFIG_NODES_SHIFT | 6 | #define NODES_SHIFT CONFIG_NODES_SHIFT |
diff --git a/include/linux/parport.h b/include/linux/parport.h index 008d736a6c9a..d42737eeee06 100644 --- a/include/linux/parport.h +++ b/include/linux/parport.h | |||
@@ -96,7 +96,6 @@ typedef enum { | |||
96 | /* The rest is for the kernel only */ | 96 | /* The rest is for the kernel only */ |
97 | #ifdef __KERNEL__ | 97 | #ifdef __KERNEL__ |
98 | 98 | ||
99 | #include <linux/config.h> | ||
100 | #include <linux/jiffies.h> | 99 | #include <linux/jiffies.h> |
101 | #include <linux/proc_fs.h> | 100 | #include <linux/proc_fs.h> |
102 | #include <linux/spinlock.h> | 101 | #include <linux/spinlock.h> |
diff --git a/include/linux/pci.h b/include/linux/pci.h index 3a6a4e37a482..62a8c22f5f60 100644 --- a/include/linux/pci.h +++ b/include/linux/pci.h | |||
@@ -17,8 +17,6 @@ | |||
17 | #ifndef LINUX_PCI_H | 17 | #ifndef LINUX_PCI_H |
18 | #define LINUX_PCI_H | 18 | #define LINUX_PCI_H |
19 | 19 | ||
20 | #include <linux/mod_devicetable.h> | ||
21 | |||
22 | /* Include the pci register defines */ | 20 | /* Include the pci register defines */ |
23 | #include <linux/pci_regs.h> | 21 | #include <linux/pci_regs.h> |
24 | 22 | ||
@@ -46,8 +44,9 @@ | |||
46 | 44 | ||
47 | #ifdef __KERNEL__ | 45 | #ifdef __KERNEL__ |
48 | 46 | ||
47 | #include <linux/mod_devicetable.h> | ||
48 | |||
49 | #include <linux/types.h> | 49 | #include <linux/types.h> |
50 | #include <linux/config.h> | ||
51 | #include <linux/ioport.h> | 50 | #include <linux/ioport.h> |
52 | #include <linux/list.h> | 51 | #include <linux/list.h> |
53 | #include <linux/errno.h> | 52 | #include <linux/errno.h> |
@@ -163,6 +162,9 @@ struct pci_dev { | |||
163 | unsigned int is_busmaster:1; /* device is busmaster */ | 162 | unsigned int is_busmaster:1; /* device is busmaster */ |
164 | unsigned int no_msi:1; /* device may not use msi */ | 163 | unsigned int no_msi:1; /* device may not use msi */ |
165 | unsigned int block_ucfg_access:1; /* userspace config space access is blocked */ | 164 | unsigned int block_ucfg_access:1; /* userspace config space access is blocked */ |
165 | unsigned int broken_parity_status:1; /* Device generates false positive parity */ | ||
166 | unsigned int msi_enabled:1; | ||
167 | unsigned int msix_enabled:1; | ||
166 | 168 | ||
167 | u32 saved_config_space[16]; /* config space saved at suspend time */ | 169 | u32 saved_config_space[16]; /* config space saved at suspend time */ |
168 | struct hlist_head saved_cap_space; | 170 | struct hlist_head saved_cap_space; |
@@ -442,6 +444,7 @@ struct pci_dev *pci_find_device_reverse (unsigned int vendor, unsigned int devic | |||
442 | struct pci_dev *pci_find_slot (unsigned int bus, unsigned int devfn); | 444 | struct pci_dev *pci_find_slot (unsigned int bus, unsigned int devfn); |
443 | int pci_find_capability (struct pci_dev *dev, int cap); | 445 | int pci_find_capability (struct pci_dev *dev, int cap); |
444 | int pci_find_next_capability (struct pci_dev *dev, u8 pos, int cap); | 446 | int pci_find_next_capability (struct pci_dev *dev, u8 pos, int cap); |
447 | int pci_find_ext_capability (struct pci_dev *dev, int cap); | ||
445 | struct pci_bus * pci_find_next_bus(const struct pci_bus *from); | 448 | struct pci_bus * pci_find_next_bus(const struct pci_bus *from); |
446 | 449 | ||
447 | struct pci_dev *pci_get_device (unsigned int vendor, unsigned int device, struct pci_dev *from); | 450 | struct pci_dev *pci_get_device (unsigned int vendor, unsigned int device, struct pci_dev *from); |
@@ -496,6 +499,7 @@ int pci_set_dma_mask(struct pci_dev *dev, u64 mask); | |||
496 | int pci_set_consistent_dma_mask(struct pci_dev *dev, u64 mask); | 499 | int pci_set_consistent_dma_mask(struct pci_dev *dev, u64 mask); |
497 | void pci_update_resource(struct pci_dev *dev, struct resource *res, int resno); | 500 | void pci_update_resource(struct pci_dev *dev, struct resource *res, int resno); |
498 | int pci_assign_resource(struct pci_dev *dev, int i); | 501 | int pci_assign_resource(struct pci_dev *dev, int i); |
502 | int pci_assign_resource_fixed(struct pci_dev *dev, int i); | ||
499 | void pci_restore_bars(struct pci_dev *dev); | 503 | void pci_restore_bars(struct pci_dev *dev); |
500 | 504 | ||
501 | /* ROM control related routines */ | 505 | /* ROM control related routines */ |
@@ -662,6 +666,7 @@ static inline int pci_register_driver(struct pci_driver *drv) { return 0;} | |||
662 | static inline void pci_unregister_driver(struct pci_driver *drv) { } | 666 | static inline void pci_unregister_driver(struct pci_driver *drv) { } |
663 | static inline int pci_find_capability (struct pci_dev *dev, int cap) {return 0; } | 667 | static inline int pci_find_capability (struct pci_dev *dev, int cap) {return 0; } |
664 | static inline int pci_find_next_capability (struct pci_dev *dev, u8 post, int cap) { return 0; } | 668 | static inline int pci_find_next_capability (struct pci_dev *dev, u8 post, int cap) { return 0; } |
669 | static inline int pci_find_ext_capability (struct pci_dev *dev, int cap) {return 0; } | ||
665 | static inline const struct pci_device_id *pci_match_device(const struct pci_device_id *ids, const struct pci_dev *dev) { return NULL; } | 670 | static inline const struct pci_device_id *pci_match_device(const struct pci_device_id *ids, const struct pci_dev *dev) { return NULL; } |
666 | 671 | ||
667 | /* Power management related routines */ | 672 | /* Power management related routines */ |
diff --git a/include/linux/pci_ids.h b/include/linux/pci_ids.h index 55dc8ac3f020..c2fd2d19938b 100644 --- a/include/linux/pci_ids.h +++ b/include/linux/pci_ids.h | |||
@@ -352,8 +352,11 @@ | |||
352 | #define PCI_DEVICE_ID_ATI_RS480 0x5950 | 352 | #define PCI_DEVICE_ID_ATI_RS480 0x5950 |
353 | /* ATI IXP Chipset */ | 353 | /* ATI IXP Chipset */ |
354 | #define PCI_DEVICE_ID_ATI_IXP200_IDE 0x4349 | 354 | #define PCI_DEVICE_ID_ATI_IXP200_IDE 0x4349 |
355 | #define PCI_DEVICE_ID_ATI_IXP200_SMBUS 0x4353 | ||
356 | #define PCI_DEVICE_ID_ATI_IXP300_SMBUS 0x4363 | ||
355 | #define PCI_DEVICE_ID_ATI_IXP300_IDE 0x4369 | 357 | #define PCI_DEVICE_ID_ATI_IXP300_IDE 0x4369 |
356 | #define PCI_DEVICE_ID_ATI_IXP300_SATA 0x436e | 358 | #define PCI_DEVICE_ID_ATI_IXP300_SATA 0x436e |
359 | #define PCI_DEVICE_ID_ATI_IXP400_SMBUS 0x4372 | ||
357 | #define PCI_DEVICE_ID_ATI_IXP400_IDE 0x4376 | 360 | #define PCI_DEVICE_ID_ATI_IXP400_IDE 0x4376 |
358 | #define PCI_DEVICE_ID_ATI_IXP400_SATA 0x4379 | 361 | #define PCI_DEVICE_ID_ATI_IXP400_SATA 0x4379 |
359 | #define PCI_DEVICE_ID_ATI_IXP400_SATA2 0x437a | 362 | #define PCI_DEVICE_ID_ATI_IXP400_SATA2 0x437a |
@@ -848,7 +851,12 @@ | |||
848 | 851 | ||
849 | 852 | ||
850 | #define PCI_VENDOR_ID_QLOGIC 0x1077 | 853 | #define PCI_VENDOR_ID_QLOGIC 0x1077 |
854 | #define PCI_DEVICE_ID_QLOGIC_ISP10160 0x1016 | ||
851 | #define PCI_DEVICE_ID_QLOGIC_ISP1020 0x1020 | 855 | #define PCI_DEVICE_ID_QLOGIC_ISP1020 0x1020 |
856 | #define PCI_DEVICE_ID_QLOGIC_ISP1080 0x1080 | ||
857 | #define PCI_DEVICE_ID_QLOGIC_ISP12160 0x1216 | ||
858 | #define PCI_DEVICE_ID_QLOGIC_ISP1240 0x1240 | ||
859 | #define PCI_DEVICE_ID_QLOGIC_ISP1280 0x1280 | ||
852 | #define PCI_DEVICE_ID_QLOGIC_ISP2100 0x2100 | 860 | #define PCI_DEVICE_ID_QLOGIC_ISP2100 0x2100 |
853 | #define PCI_DEVICE_ID_QLOGIC_ISP2200 0x2200 | 861 | #define PCI_DEVICE_ID_QLOGIC_ISP2200 0x2200 |
854 | #define PCI_DEVICE_ID_QLOGIC_ISP2300 0x2300 | 862 | #define PCI_DEVICE_ID_QLOGIC_ISP2300 0x2300 |
@@ -935,6 +943,7 @@ | |||
935 | #define PCI_DEVICE_ID_PLX_DJINN_ITOO 0x1151 | 943 | #define PCI_DEVICE_ID_PLX_DJINN_ITOO 0x1151 |
936 | #define PCI_DEVICE_ID_PLX_R753 0x1152 | 944 | #define PCI_DEVICE_ID_PLX_R753 0x1152 |
937 | #define PCI_DEVICE_ID_PLX_OLITEC 0x1187 | 945 | #define PCI_DEVICE_ID_PLX_OLITEC 0x1187 |
946 | #define PCI_DEVICE_ID_PLX_PCI200SYN 0x3196 | ||
938 | #define PCI_DEVICE_ID_PLX_9050 0x9050 | 947 | #define PCI_DEVICE_ID_PLX_9050 0x9050 |
939 | #define PCI_DEVICE_ID_PLX_9080 0x9080 | 948 | #define PCI_DEVICE_ID_PLX_9080 0x9080 |
940 | #define PCI_DEVICE_ID_PLX_GTEK_SERIAL2 0xa001 | 949 | #define PCI_DEVICE_ID_PLX_GTEK_SERIAL2 0xa001 |
@@ -1017,6 +1026,7 @@ | |||
1017 | #define PCI_DEVICE_ID_NVIDIA_NVENET_8 0x0056 | 1026 | #define PCI_DEVICE_ID_NVIDIA_NVENET_8 0x0056 |
1018 | #define PCI_DEVICE_ID_NVIDIA_NVENET_9 0x0057 | 1027 | #define PCI_DEVICE_ID_NVIDIA_NVENET_9 0x0057 |
1019 | #define PCI_DEVICE_ID_NVIDIA_CK804_AUDIO 0x0059 | 1028 | #define PCI_DEVICE_ID_NVIDIA_CK804_AUDIO 0x0059 |
1029 | #define PCI_DEVICE_ID_NVIDIA_CK804_PCIE 0x005d | ||
1020 | #define PCI_DEVICE_ID_NVIDIA_NFORCE2_SMBUS 0x0064 | 1030 | #define PCI_DEVICE_ID_NVIDIA_NFORCE2_SMBUS 0x0064 |
1021 | #define PCI_DEVICE_ID_NVIDIA_NFORCE2_IDE 0x0065 | 1031 | #define PCI_DEVICE_ID_NVIDIA_NFORCE2_IDE 0x0065 |
1022 | #define PCI_DEVICE_ID_NVIDIA_NVENET_2 0x0066 | 1032 | #define PCI_DEVICE_ID_NVIDIA_NVENET_2 0x0066 |
@@ -1126,9 +1136,11 @@ | |||
1126 | #define PCI_DEVICE_ID_NVIDIA_QUADRO4_900XGL 0x0258 | 1136 | #define PCI_DEVICE_ID_NVIDIA_QUADRO4_900XGL 0x0258 |
1127 | #define PCI_DEVICE_ID_NVIDIA_QUADRO4_750XGL 0x0259 | 1137 | #define PCI_DEVICE_ID_NVIDIA_QUADRO4_750XGL 0x0259 |
1128 | #define PCI_DEVICE_ID_NVIDIA_QUADRO4_700XGL 0x025B | 1138 | #define PCI_DEVICE_ID_NVIDIA_QUADRO4_700XGL 0x025B |
1139 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP51_SMBUS 0x0264 | ||
1129 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP51_IDE 0x0265 | 1140 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP51_IDE 0x0265 |
1130 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP51_SATA 0x0266 | 1141 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP51_SATA 0x0266 |
1131 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP51_SATA2 0x0267 | 1142 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP51_SATA2 0x0267 |
1143 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP55_SMBUS 0x0368 | ||
1132 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP55_IDE 0x036E | 1144 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP55_IDE 0x036E |
1133 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP55_SATA 0x037E | 1145 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP55_SATA 0x037E |
1134 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP55_SATA2 0x037F | 1146 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP55_SATA2 0x037F |
@@ -1182,10 +1194,18 @@ | |||
1182 | #define PCI_DEVICE_ID_NVIDIA_QUADRO_FX_1100 0x034E | 1194 | #define PCI_DEVICE_ID_NVIDIA_QUADRO_FX_1100 0x034E |
1183 | #define PCI_DEVICE_ID_NVIDIA_NVENET_14 0x0372 | 1195 | #define PCI_DEVICE_ID_NVIDIA_NVENET_14 0x0372 |
1184 | #define PCI_DEVICE_ID_NVIDIA_NVENET_15 0x0373 | 1196 | #define PCI_DEVICE_ID_NVIDIA_NVENET_15 0x0373 |
1197 | #define PCI_DEVICE_ID_NVIDIA_NVENET_16 0x03E5 | ||
1198 | #define PCI_DEVICE_ID_NVIDIA_NVENET_17 0x03E6 | ||
1185 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP61_SATA 0x03E7 | 1199 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP61_SATA 0x03E7 |
1186 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP61_IDE 0x03EC | 1200 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP61_IDE 0x03EC |
1201 | #define PCI_DEVICE_ID_NVIDIA_NVENET_18 0x03EE | ||
1202 | #define PCI_DEVICE_ID_NVIDIA_NVENET_19 0x03EF | ||
1187 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP61_SATA2 0x03F6 | 1203 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP61_SATA2 0x03F6 |
1188 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP61_SATA3 0x03F7 | 1204 | #define PCI_DEVICE_ID_NVIDIA_NFORCE_MCP61_SATA3 0x03F7 |
1205 | #define PCI_DEVICE_ID_NVIDIA_NVENET_20 0x0450 | ||
1206 | #define PCI_DEVICE_ID_NVIDIA_NVENET_21 0x0451 | ||
1207 | #define PCI_DEVICE_ID_NVIDIA_NVENET_22 0x0452 | ||
1208 | #define PCI_DEVICE_ID_NVIDIA_NVENET_23 0x0453 | ||
1189 | 1209 | ||
1190 | #define PCI_VENDOR_ID_IMS 0x10e0 | 1210 | #define PCI_VENDOR_ID_IMS 0x10e0 |
1191 | #define PCI_DEVICE_ID_IMS_TT128 0x9128 | 1211 | #define PCI_DEVICE_ID_IMS_TT128 0x9128 |
@@ -1834,6 +1854,7 @@ | |||
1834 | 1854 | ||
1835 | #define PCI_VENDOR_ID_SAMSUNG 0x144d | 1855 | #define PCI_VENDOR_ID_SAMSUNG 0x144d |
1836 | 1856 | ||
1857 | #define PCI_VENDOR_ID_MYRICOM 0x14c1 | ||
1837 | 1858 | ||
1838 | #define PCI_VENDOR_ID_TITAN 0x14D2 | 1859 | #define PCI_VENDOR_ID_TITAN 0x14D2 |
1839 | #define PCI_DEVICE_ID_TITAN_010L 0x8001 | 1860 | #define PCI_DEVICE_ID_TITAN_010L 0x8001 |
@@ -1894,6 +1915,7 @@ | |||
1894 | #define PCI_DEVICE_ID_TIGON3_5751F 0x167e | 1915 | #define PCI_DEVICE_ID_TIGON3_5751F 0x167e |
1895 | #define PCI_DEVICE_ID_TIGON3_5787M 0x1693 | 1916 | #define PCI_DEVICE_ID_TIGON3_5787M 0x1693 |
1896 | #define PCI_DEVICE_ID_TIGON3_5782 0x1696 | 1917 | #define PCI_DEVICE_ID_TIGON3_5782 0x1696 |
1918 | #define PCI_DEVICE_ID_TIGON3_5786 0x169a | ||
1897 | #define PCI_DEVICE_ID_TIGON3_5787 0x169b | 1919 | #define PCI_DEVICE_ID_TIGON3_5787 0x169b |
1898 | #define PCI_DEVICE_ID_TIGON3_5788 0x169c | 1920 | #define PCI_DEVICE_ID_TIGON3_5788 0x169c |
1899 | #define PCI_DEVICE_ID_TIGON3_5789 0x169d | 1921 | #define PCI_DEVICE_ID_TIGON3_5789 0x169d |
@@ -1942,6 +1964,7 @@ | |||
1942 | 1964 | ||
1943 | #define PCI_VENDOR_ID_MELLANOX 0x15b3 | 1965 | #define PCI_VENDOR_ID_MELLANOX 0x15b3 |
1944 | #define PCI_DEVICE_ID_MELLANOX_TAVOR 0x5a44 | 1966 | #define PCI_DEVICE_ID_MELLANOX_TAVOR 0x5a44 |
1967 | #define PCI_DEVICE_ID_MELLANOX_TAVOR_BRIDGE 0x5a46 | ||
1945 | #define PCI_DEVICE_ID_MELLANOX_ARBEL_COMPAT 0x6278 | 1968 | #define PCI_DEVICE_ID_MELLANOX_ARBEL_COMPAT 0x6278 |
1946 | #define PCI_DEVICE_ID_MELLANOX_ARBEL 0x6282 | 1969 | #define PCI_DEVICE_ID_MELLANOX_ARBEL 0x6282 |
1947 | #define PCI_DEVICE_ID_MELLANOX_SINAI_OLD 0x5e8c | 1970 | #define PCI_DEVICE_ID_MELLANOX_SINAI_OLD 0x5e8c |
@@ -1965,6 +1988,9 @@ | |||
1965 | #define PCI_VENDOR_ID_NETCELL 0x169c | 1988 | #define PCI_VENDOR_ID_NETCELL 0x169c |
1966 | #define PCI_DEVICE_ID_REVOLUTION 0x0044 | 1989 | #define PCI_DEVICE_ID_REVOLUTION 0x0044 |
1967 | 1990 | ||
1991 | #define PCI_VENDOR_ID_VITESSE 0x1725 | ||
1992 | #define PCI_DEVICE_ID_VITESSE_VSC7174 0x7174 | ||
1993 | |||
1968 | #define PCI_VENDOR_ID_LINKSYS 0x1737 | 1994 | #define PCI_VENDOR_ID_LINKSYS 0x1737 |
1969 | #define PCI_DEVICE_ID_LINKSYS_EG1064 0x1064 | 1995 | #define PCI_DEVICE_ID_LINKSYS_EG1064 0x1064 |
1970 | 1996 | ||
@@ -2050,6 +2076,7 @@ | |||
2050 | #define PCI_DEVICE_ID_INTEL_80960_RP 0x1960 | 2076 | #define PCI_DEVICE_ID_INTEL_80960_RP 0x1960 |
2051 | #define PCI_DEVICE_ID_INTEL_82840_HB 0x1a21 | 2077 | #define PCI_DEVICE_ID_INTEL_82840_HB 0x1a21 |
2052 | #define PCI_DEVICE_ID_INTEL_82845_HB 0x1a30 | 2078 | #define PCI_DEVICE_ID_INTEL_82845_HB 0x1a30 |
2079 | #define PCI_DEVICE_ID_INTEL_IOAT 0x1a38 | ||
2053 | #define PCI_DEVICE_ID_INTEL_82801AA_0 0x2410 | 2080 | #define PCI_DEVICE_ID_INTEL_82801AA_0 0x2410 |
2054 | #define PCI_DEVICE_ID_INTEL_82801AA_1 0x2411 | 2081 | #define PCI_DEVICE_ID_INTEL_82801AA_1 0x2411 |
2055 | #define PCI_DEVICE_ID_INTEL_82801AA_3 0x2413 | 2082 | #define PCI_DEVICE_ID_INTEL_82801AA_3 0x2413 |
@@ -2143,6 +2170,7 @@ | |||
2143 | #define PCI_DEVICE_ID_INTEL_ICH8_4 0x2815 | 2170 | #define PCI_DEVICE_ID_INTEL_ICH8_4 0x2815 |
2144 | #define PCI_DEVICE_ID_INTEL_ICH8_5 0x283e | 2171 | #define PCI_DEVICE_ID_INTEL_ICH8_5 0x283e |
2145 | #define PCI_DEVICE_ID_INTEL_ICH8_6 0x2850 | 2172 | #define PCI_DEVICE_ID_INTEL_ICH8_6 0x2850 |
2173 | #define PCI_DEVICE_ID_INTEL_GD31244 0x3200 | ||
2146 | #define PCI_DEVICE_ID_INTEL_82855PM_HB 0x3340 | 2174 | #define PCI_DEVICE_ID_INTEL_82855PM_HB 0x3340 |
2147 | #define PCI_DEVICE_ID_INTEL_82830_HB 0x3575 | 2175 | #define PCI_DEVICE_ID_INTEL_82830_HB 0x3575 |
2148 | #define PCI_DEVICE_ID_INTEL_82830_CGC 0x3577 | 2176 | #define PCI_DEVICE_ID_INTEL_82830_CGC 0x3577 |
diff --git a/include/linux/pci_regs.h b/include/linux/pci_regs.h index d27a78b71297..6bce4a240364 100644 --- a/include/linux/pci_regs.h +++ b/include/linux/pci_regs.h | |||
@@ -197,6 +197,7 @@ | |||
197 | #define PCI_CAP_ID_CHSWP 0x06 /* CompactPCI HotSwap */ | 197 | #define PCI_CAP_ID_CHSWP 0x06 /* CompactPCI HotSwap */ |
198 | #define PCI_CAP_ID_PCIX 0x07 /* PCI-X */ | 198 | #define PCI_CAP_ID_PCIX 0x07 /* PCI-X */ |
199 | #define PCI_CAP_ID_HT_IRQCONF 0x08 /* HyperTransport IRQ Configuration */ | 199 | #define PCI_CAP_ID_HT_IRQCONF 0x08 /* HyperTransport IRQ Configuration */ |
200 | #define PCI_CAP_ID_VNDR 0x09 /* Vendor specific capability */ | ||
200 | #define PCI_CAP_ID_SHPC 0x0C /* PCI Standard Hot-Plug Controller */ | 201 | #define PCI_CAP_ID_SHPC 0x0C /* PCI Standard Hot-Plug Controller */ |
201 | #define PCI_CAP_ID_EXP 0x10 /* PCI Express */ | 202 | #define PCI_CAP_ID_EXP 0x10 /* PCI Express */ |
202 | #define PCI_CAP_ID_MSIX 0x11 /* MSI-X */ | 203 | #define PCI_CAP_ID_MSIX 0x11 /* MSI-X */ |
diff --git a/include/linux/percpu_counter.h b/include/linux/percpu_counter.h index 682525511c9e..66b5de404f22 100644 --- a/include/linux/percpu_counter.h +++ b/include/linux/percpu_counter.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * WARNING: these things are HUGE. 4 kbytes per counter on 32-way P4. | 6 | * WARNING: these things are HUGE. 4 kbytes per counter on 32-way P4. |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <linux/spinlock.h> | 9 | #include <linux/spinlock.h> |
11 | #include <linux/smp.h> | 10 | #include <linux/smp.h> |
12 | #include <linux/threads.h> | 11 | #include <linux/threads.h> |
diff --git a/include/linux/pfkeyv2.h b/include/linux/pfkeyv2.h index bac0fb389cf1..d5dd471da225 100644 --- a/include/linux/pfkeyv2.h +++ b/include/linux/pfkeyv2.h | |||
@@ -159,7 +159,7 @@ struct sadb_spirange { | |||
159 | struct sadb_x_kmprivate { | 159 | struct sadb_x_kmprivate { |
160 | uint16_t sadb_x_kmprivate_len; | 160 | uint16_t sadb_x_kmprivate_len; |
161 | uint16_t sadb_x_kmprivate_exttype; | 161 | uint16_t sadb_x_kmprivate_exttype; |
162 | u_int32_t sadb_x_kmprivate_reserved; | 162 | uint32_t sadb_x_kmprivate_reserved; |
163 | } __attribute__((packed)); | 163 | } __attribute__((packed)); |
164 | /* sizeof(struct sadb_x_kmprivate) == 8 */ | 164 | /* sizeof(struct sadb_x_kmprivate) == 8 */ |
165 | 165 | ||
diff --git a/include/linux/pm.h b/include/linux/pm.h index 66be58902b17..658c1b93d5bb 100644 --- a/include/linux/pm.h +++ b/include/linux/pm.h | |||
@@ -23,7 +23,6 @@ | |||
23 | 23 | ||
24 | #ifdef __KERNEL__ | 24 | #ifdef __KERNEL__ |
25 | 25 | ||
26 | #include <linux/config.h> | ||
27 | #include <linux/list.h> | 26 | #include <linux/list.h> |
28 | #include <asm/atomic.h> | 27 | #include <asm/atomic.h> |
29 | 28 | ||
diff --git a/include/linux/pm_legacy.h b/include/linux/pm_legacy.h index 008932d73c35..78027c533b94 100644 --- a/include/linux/pm_legacy.h +++ b/include/linux/pm_legacy.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __LINUX_PM_LEGACY_H__ | 1 | #ifndef __LINUX_PM_LEGACY_H__ |
2 | #define __LINUX_PM_LEGACY_H__ | 2 | #define __LINUX_PM_LEGACY_H__ |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_PM_LEGACY | 5 | #ifdef CONFIG_PM_LEGACY |
7 | 6 | ||
diff --git a/include/linux/pmu.h b/include/linux/pmu.h index 217d3daf7336..ecce5912f4d6 100644 --- a/include/linux/pmu.h +++ b/include/linux/pmu.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * Copyright (C) 1998 Paul Mackerras. | 6 | * Copyright (C) 1998 Paul Mackerras. |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | #define PMU_DRIVER_VERSION 2 | 10 | #define PMU_DRIVER_VERSION 2 |
12 | 11 | ||
diff --git a/include/linux/ppp_defs.h b/include/linux/ppp_defs.h index 402056cd049d..c6b13ff85028 100644 --- a/include/linux/ppp_defs.h +++ b/include/linux/ppp_defs.h | |||
@@ -42,8 +42,6 @@ | |||
42 | #ifndef _PPP_DEFS_H_ | 42 | #ifndef _PPP_DEFS_H_ |
43 | #define _PPP_DEFS_H_ | 43 | #define _PPP_DEFS_H_ |
44 | 44 | ||
45 | #include <linux/crc-ccitt.h> | ||
46 | |||
47 | /* | 45 | /* |
48 | * The basic PPP frame. | 46 | * The basic PPP frame. |
49 | */ | 47 | */ |
@@ -97,7 +95,11 @@ | |||
97 | 95 | ||
98 | #define PPP_INITFCS 0xffff /* Initial FCS value */ | 96 | #define PPP_INITFCS 0xffff /* Initial FCS value */ |
99 | #define PPP_GOODFCS 0xf0b8 /* Good final FCS value */ | 97 | #define PPP_GOODFCS 0xf0b8 /* Good final FCS value */ |
98 | |||
99 | #ifdef __KERNEL__ | ||
100 | #include <linux/crc-ccitt.h> | ||
100 | #define PPP_FCS(fcs, c) crc_ccitt_byte(fcs, c) | 101 | #define PPP_FCS(fcs, c) crc_ccitt_byte(fcs, c) |
102 | #endif | ||
101 | 103 | ||
102 | /* | 104 | /* |
103 | * Extended asyncmap - allows any character to be escaped. | 105 | * Extended asyncmap - allows any character to be escaped. |
@@ -179,12 +181,4 @@ struct ppp_idle { | |||
179 | time_t recv_idle; /* time since last NP packet received */ | 181 | time_t recv_idle; /* time since last NP packet received */ |
180 | }; | 182 | }; |
181 | 183 | ||
182 | #ifndef __P | ||
183 | #ifdef __STDC__ | ||
184 | #define __P(x) x | ||
185 | #else | ||
186 | #define __P(x) () | ||
187 | #endif | ||
188 | #endif | ||
189 | |||
190 | #endif /* _PPP_DEFS_H_ */ | 184 | #endif /* _PPP_DEFS_H_ */ |
diff --git a/include/linux/preempt.h b/include/linux/preempt.h index 5769d14d1e6a..d0926d63406c 100644 --- a/include/linux/preempt.h +++ b/include/linux/preempt.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * preempt_count (used for kernel preemption, interrupt count, etc.) | 6 | * preempt_count (used for kernel preemption, interrupt count, etc.) |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <linux/thread_info.h> | 9 | #include <linux/thread_info.h> |
11 | #include <linux/linkage.h> | 10 | #include <linux/linkage.h> |
12 | 11 | ||
diff --git a/include/linux/proc_fs.h b/include/linux/proc_fs.h index 4b47a0253425..5810d28fbed9 100644 --- a/include/linux/proc_fs.h +++ b/include/linux/proc_fs.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _LINUX_PROC_FS_H | 1 | #ifndef _LINUX_PROC_FS_H |
2 | #define _LINUX_PROC_FS_H | 2 | #define _LINUX_PROC_FS_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/slab.h> | 4 | #include <linux/slab.h> |
6 | #include <linux/fs.h> | 5 | #include <linux/fs.h> |
7 | #include <linux/spinlock.h> | 6 | #include <linux/spinlock.h> |
diff --git a/include/linux/profile.h b/include/linux/profile.h index 1f2fea6640a4..e633004ae052 100644 --- a/include/linux/profile.h +++ b/include/linux/profile.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | 5 | ||
6 | #include <linux/kernel.h> | 6 | #include <linux/kernel.h> |
7 | #include <linux/config.h> | ||
8 | #include <linux/init.h> | 7 | #include <linux/init.h> |
9 | #include <linux/cpumask.h> | 8 | #include <linux/cpumask.h> |
10 | #include <asm/errno.h> | 9 | #include <asm/errno.h> |
diff --git a/include/linux/quota.h b/include/linux/quota.h index 2dab71e1c3d1..b8fbf26eb885 100644 --- a/include/linux/quota.h +++ b/include/linux/quota.h | |||
@@ -37,8 +37,6 @@ | |||
37 | 37 | ||
38 | #include <linux/errno.h> | 38 | #include <linux/errno.h> |
39 | #include <linux/types.h> | 39 | #include <linux/types.h> |
40 | #include <linux/spinlock.h> | ||
41 | #include <linux/mutex.h> | ||
42 | 40 | ||
43 | #define __DQUOT_VERSION__ "dquot_6.5.1" | 41 | #define __DQUOT_VERSION__ "dquot_6.5.1" |
44 | #define __DQUOT_NUM_VERSION__ 6*10000+5*100+1 | 42 | #define __DQUOT_NUM_VERSION__ 6*10000+5*100+1 |
@@ -133,6 +131,8 @@ struct if_dqinfo { | |||
133 | }; | 131 | }; |
134 | 132 | ||
135 | #ifdef __KERNEL__ | 133 | #ifdef __KERNEL__ |
134 | #include <linux/spinlock.h> | ||
135 | #include <linux/mutex.h> | ||
136 | 136 | ||
137 | #include <linux/dqblk_xfs.h> | 137 | #include <linux/dqblk_xfs.h> |
138 | #include <linux/dqblk_v1.h> | 138 | #include <linux/dqblk_v1.h> |
diff --git a/include/linux/quotaops.h b/include/linux/quotaops.h index 21e5a9124856..5110201a4159 100644 --- a/include/linux/quotaops.h +++ b/include/linux/quotaops.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _LINUX_QUOTAOPS_ | 10 | #ifndef _LINUX_QUOTAOPS_ |
11 | #define _LINUX_QUOTAOPS_ | 11 | #define _LINUX_QUOTAOPS_ |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/smp_lock.h> | 13 | #include <linux/smp_lock.h> |
15 | 14 | ||
16 | #include <linux/fs.h> | 15 | #include <linux/fs.h> |
diff --git a/include/linux/rbtree.h b/include/linux/rbtree.h index 4b7cc4fe366d..f37006f21664 100644 --- a/include/linux/rbtree.h +++ b/include/linux/rbtree.h | |||
@@ -99,19 +99,36 @@ static inline struct page * rb_insert_page_cache(struct inode * inode, | |||
99 | 99 | ||
100 | struct rb_node | 100 | struct rb_node |
101 | { | 101 | { |
102 | struct rb_node *rb_parent; | 102 | unsigned long rb_parent_color; |
103 | int rb_color; | ||
104 | #define RB_RED 0 | 103 | #define RB_RED 0 |
105 | #define RB_BLACK 1 | 104 | #define RB_BLACK 1 |
106 | struct rb_node *rb_right; | 105 | struct rb_node *rb_right; |
107 | struct rb_node *rb_left; | 106 | struct rb_node *rb_left; |
108 | }; | 107 | } __attribute__((aligned(sizeof(long)))); |
108 | /* The alignment might seem pointless, but allegedly CRIS needs it */ | ||
109 | 109 | ||
110 | struct rb_root | 110 | struct rb_root |
111 | { | 111 | { |
112 | struct rb_node *rb_node; | 112 | struct rb_node *rb_node; |
113 | }; | 113 | }; |
114 | 114 | ||
115 | |||
116 | #define rb_parent(r) ((struct rb_node *)((r)->rb_parent_color & ~3)) | ||
117 | #define rb_color(r) ((r)->rb_parent_color & 1) | ||
118 | #define rb_is_red(r) (!rb_color(r)) | ||
119 | #define rb_is_black(r) rb_color(r) | ||
120 | #define rb_set_red(r) do { (r)->rb_parent_color &= ~1; } while (0) | ||
121 | #define rb_set_black(r) do { (r)->rb_parent_color |= 1; } while (0) | ||
122 | |||
123 | static inline void rb_set_parent(struct rb_node *rb, struct rb_node *p) | ||
124 | { | ||
125 | rb->rb_parent_color = (rb->rb_parent_color & 3) | (unsigned long)p; | ||
126 | } | ||
127 | static inline void rb_set_color(struct rb_node *rb, int color) | ||
128 | { | ||
129 | rb->rb_parent_color = (rb->rb_parent_color & ~1) | color; | ||
130 | } | ||
131 | |||
115 | #define RB_ROOT (struct rb_root) { NULL, } | 132 | #define RB_ROOT (struct rb_root) { NULL, } |
116 | #define rb_entry(ptr, type, member) container_of(ptr, type, member) | 133 | #define rb_entry(ptr, type, member) container_of(ptr, type, member) |
117 | 134 | ||
@@ -131,8 +148,7 @@ extern void rb_replace_node(struct rb_node *victim, struct rb_node *new, | |||
131 | static inline void rb_link_node(struct rb_node * node, struct rb_node * parent, | 148 | static inline void rb_link_node(struct rb_node * node, struct rb_node * parent, |
132 | struct rb_node ** rb_link) | 149 | struct rb_node ** rb_link) |
133 | { | 150 | { |
134 | node->rb_parent = parent; | 151 | node->rb_parent_color = (unsigned long )parent; |
135 | node->rb_color = RB_RED; | ||
136 | node->rb_left = node->rb_right = NULL; | 152 | node->rb_left = node->rb_right = NULL; |
137 | 153 | ||
138 | *rb_link = node; | 154 | *rb_link = node; |
diff --git a/include/linux/reiserfs_xattr.h b/include/linux/reiserfs_xattr.h index 5353afb11db3..5e961035c725 100644 --- a/include/linux/reiserfs_xattr.h +++ b/include/linux/reiserfs_xattr.h | |||
@@ -2,8 +2,6 @@ | |||
2 | File: linux/reiserfs_xattr.h | 2 | File: linux/reiserfs_xattr.h |
3 | */ | 3 | */ |
4 | 4 | ||
5 | #include <linux/config.h> | ||
6 | #include <linux/init.h> | ||
7 | #include <linux/xattr.h> | 5 | #include <linux/xattr.h> |
8 | 6 | ||
9 | /* Magic value in header */ | 7 | /* Magic value in header */ |
@@ -15,6 +13,7 @@ struct reiserfs_xattr_header { | |||
15 | }; | 13 | }; |
16 | 14 | ||
17 | #ifdef __KERNEL__ | 15 | #ifdef __KERNEL__ |
16 | #include <linux/init.h> | ||
18 | 17 | ||
19 | struct reiserfs_xattr_handler { | 18 | struct reiserfs_xattr_handler { |
20 | char *prefix; | 19 | char *prefix; |
diff --git a/include/linux/relay.h b/include/linux/relay.h index 4bcc1531d6a9..24accb483849 100644 --- a/include/linux/relay.h +++ b/include/linux/relay.h | |||
@@ -10,7 +10,6 @@ | |||
10 | #ifndef _LINUX_RELAY_H | 10 | #ifndef _LINUX_RELAY_H |
11 | #define _LINUX_RELAY_H | 11 | #define _LINUX_RELAY_H |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/types.h> | 13 | #include <linux/types.h> |
15 | #include <linux/sched.h> | 14 | #include <linux/sched.h> |
16 | #include <linux/wait.h> | 15 | #include <linux/wait.h> |
diff --git a/include/linux/rio.h b/include/linux/rio.h index c7e907faae9c..d93857056cb9 100644 --- a/include/linux/rio.h +++ b/include/linux/rio.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #ifdef __KERNEL__ | 17 | #ifdef __KERNEL__ |
18 | 18 | ||
19 | #include <linux/types.h> | 19 | #include <linux/types.h> |
20 | #include <linux/config.h> | ||
21 | #include <linux/ioport.h> | 20 | #include <linux/ioport.h> |
22 | #include <linux/list.h> | 21 | #include <linux/list.h> |
23 | #include <linux/errno.h> | 22 | #include <linux/errno.h> |
diff --git a/include/linux/rio_drv.h b/include/linux/rio_drv.h index f54772d0e7f8..7adb2a1aac92 100644 --- a/include/linux/rio_drv.h +++ b/include/linux/rio_drv.h | |||
@@ -16,7 +16,6 @@ | |||
16 | #ifdef __KERNEL__ | 16 | #ifdef __KERNEL__ |
17 | 17 | ||
18 | #include <linux/types.h> | 18 | #include <linux/types.h> |
19 | #include <linux/config.h> | ||
20 | #include <linux/ioport.h> | 19 | #include <linux/ioport.h> |
21 | #include <linux/list.h> | 20 | #include <linux/list.h> |
22 | #include <linux/errno.h> | 21 | #include <linux/errno.h> |
diff --git a/include/linux/rmap.h b/include/linux/rmap.h index d6b9bcd1384c..2d4c81a220db 100644 --- a/include/linux/rmap.h +++ b/include/linux/rmap.h | |||
@@ -4,7 +4,6 @@ | |||
4 | * Declarations for Reverse Mapping functions in mm/rmap.c | 4 | * Declarations for Reverse Mapping functions in mm/rmap.c |
5 | */ | 5 | */ |
6 | 6 | ||
7 | #include <linux/config.h> | ||
8 | #include <linux/list.h> | 7 | #include <linux/list.h> |
9 | #include <linux/slab.h> | 8 | #include <linux/slab.h> |
10 | #include <linux/mm.h> | 9 | #include <linux/mm.h> |
diff --git a/include/linux/rtnetlink.h b/include/linux/rtnetlink.h index df0cdd41085c..facd9ee37b76 100644 --- a/include/linux/rtnetlink.h +++ b/include/linux/rtnetlink.h | |||
@@ -909,7 +909,6 @@ struct tcamsg | |||
909 | 909 | ||
910 | #ifdef __KERNEL__ | 910 | #ifdef __KERNEL__ |
911 | 911 | ||
912 | #include <linux/config.h> | ||
913 | #include <linux/mutex.h> | 912 | #include <linux/mutex.h> |
914 | 913 | ||
915 | extern size_t rtattr_strlcpy(char *dest, const struct rtattr *rta, size_t size); | 914 | extern size_t rtattr_strlcpy(char *dest, const struct rtattr *rta, size_t size); |
diff --git a/include/linux/rwsem.h b/include/linux/rwsem.h index bfb988885002..f99fe90732ab 100644 --- a/include/linux/rwsem.h +++ b/include/linux/rwsem.h | |||
@@ -13,7 +13,6 @@ | |||
13 | 13 | ||
14 | #ifdef __KERNEL__ | 14 | #ifdef __KERNEL__ |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | #include <linux/types.h> | 16 | #include <linux/types.h> |
18 | #include <linux/kernel.h> | 17 | #include <linux/kernel.h> |
19 | #include <asm/system.h> | 18 | #include <asm/system.h> |
diff --git a/include/linux/scc.h b/include/linux/scc.h index 885a4a02b23c..3495bd953cc6 100644 --- a/include/linux/scc.h +++ b/include/linux/scc.h | |||
@@ -3,7 +3,6 @@ | |||
3 | #ifndef _SCC_H | 3 | #ifndef _SCC_H |
4 | #define _SCC_H | 4 | #define _SCC_H |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | /* selection of hardware types */ | 7 | /* selection of hardware types */ |
9 | 8 | ||
diff --git a/include/linux/sched.h b/include/linux/sched.h index 29b7d4f87d20..267f15257040 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
@@ -1,9 +1,46 @@ | |||
1 | #ifndef _LINUX_SCHED_H | 1 | #ifndef _LINUX_SCHED_H |
2 | #define _LINUX_SCHED_H | 2 | #define _LINUX_SCHED_H |
3 | 3 | ||
4 | #include <linux/auxvec.h> /* For AT_VECTOR_SIZE */ | ||
5 | |||
6 | /* | ||
7 | * cloning flags: | ||
8 | */ | ||
9 | #define CSIGNAL 0x000000ff /* signal mask to be sent at exit */ | ||
10 | #define CLONE_VM 0x00000100 /* set if VM shared between processes */ | ||
11 | #define CLONE_FS 0x00000200 /* set if fs info shared between processes */ | ||
12 | #define CLONE_FILES 0x00000400 /* set if open files shared between processes */ | ||
13 | #define CLONE_SIGHAND 0x00000800 /* set if signal handlers and blocked signals shared */ | ||
14 | #define CLONE_PTRACE 0x00002000 /* set if we want to let tracing continue on the child too */ | ||
15 | #define CLONE_VFORK 0x00004000 /* set if the parent wants the child to wake it up on mm_release */ | ||
16 | #define CLONE_PARENT 0x00008000 /* set if we want to have the same parent as the cloner */ | ||
17 | #define CLONE_THREAD 0x00010000 /* Same thread group? */ | ||
18 | #define CLONE_NEWNS 0x00020000 /* New namespace group? */ | ||
19 | #define CLONE_SYSVSEM 0x00040000 /* share system V SEM_UNDO semantics */ | ||
20 | #define CLONE_SETTLS 0x00080000 /* create a new TLS for the child */ | ||
21 | #define CLONE_PARENT_SETTID 0x00100000 /* set the TID in the parent */ | ||
22 | #define CLONE_CHILD_CLEARTID 0x00200000 /* clear the TID in the child */ | ||
23 | #define CLONE_DETACHED 0x00400000 /* Unused, ignored */ | ||
24 | #define CLONE_UNTRACED 0x00800000 /* set if the tracing process can't force CLONE_PTRACE on this clone */ | ||
25 | #define CLONE_CHILD_SETTID 0x01000000 /* set the TID in the child */ | ||
26 | #define CLONE_STOPPED 0x02000000 /* Start in stopped state */ | ||
27 | |||
28 | /* | ||
29 | * Scheduling policies | ||
30 | */ | ||
31 | #define SCHED_NORMAL 0 | ||
32 | #define SCHED_FIFO 1 | ||
33 | #define SCHED_RR 2 | ||
34 | #define SCHED_BATCH 3 | ||
35 | |||
36 | #ifdef __KERNEL__ | ||
37 | |||
38 | struct sched_param { | ||
39 | int sched_priority; | ||
40 | }; | ||
41 | |||
4 | #include <asm/param.h> /* for HZ */ | 42 | #include <asm/param.h> /* for HZ */ |
5 | 43 | ||
6 | #include <linux/config.h> | ||
7 | #include <linux/capability.h> | 44 | #include <linux/capability.h> |
8 | #include <linux/threads.h> | 45 | #include <linux/threads.h> |
9 | #include <linux/kernel.h> | 46 | #include <linux/kernel.h> |
@@ -37,31 +74,15 @@ | |||
37 | #include <linux/rcupdate.h> | 74 | #include <linux/rcupdate.h> |
38 | #include <linux/futex.h> | 75 | #include <linux/futex.h> |
39 | 76 | ||
40 | #include <linux/auxvec.h> /* For AT_VECTOR_SIZE */ | 77 | #include <linux/time.h> |
78 | #include <linux/param.h> | ||
79 | #include <linux/resource.h> | ||
80 | #include <linux/timer.h> | ||
81 | #include <linux/hrtimer.h> | ||
41 | 82 | ||
42 | struct exec_domain; | 83 | #include <asm/processor.h> |
43 | 84 | ||
44 | /* | 85 | struct exec_domain; |
45 | * cloning flags: | ||
46 | */ | ||
47 | #define CSIGNAL 0x000000ff /* signal mask to be sent at exit */ | ||
48 | #define CLONE_VM 0x00000100 /* set if VM shared between processes */ | ||
49 | #define CLONE_FS 0x00000200 /* set if fs info shared between processes */ | ||
50 | #define CLONE_FILES 0x00000400 /* set if open files shared between processes */ | ||
51 | #define CLONE_SIGHAND 0x00000800 /* set if signal handlers and blocked signals shared */ | ||
52 | #define CLONE_PTRACE 0x00002000 /* set if we want to let tracing continue on the child too */ | ||
53 | #define CLONE_VFORK 0x00004000 /* set if the parent wants the child to wake it up on mm_release */ | ||
54 | #define CLONE_PARENT 0x00008000 /* set if we want to have the same parent as the cloner */ | ||
55 | #define CLONE_THREAD 0x00010000 /* Same thread group? */ | ||
56 | #define CLONE_NEWNS 0x00020000 /* New namespace group? */ | ||
57 | #define CLONE_SYSVSEM 0x00040000 /* share system V SEM_UNDO semantics */ | ||
58 | #define CLONE_SETTLS 0x00080000 /* create a new TLS for the child */ | ||
59 | #define CLONE_PARENT_SETTID 0x00100000 /* set the TID in the parent */ | ||
60 | #define CLONE_CHILD_CLEARTID 0x00200000 /* clear the TID in the child */ | ||
61 | #define CLONE_DETACHED 0x00400000 /* Unused, ignored */ | ||
62 | #define CLONE_UNTRACED 0x00800000 /* set if the tracing process can't force CLONE_PTRACE on this clone */ | ||
63 | #define CLONE_CHILD_SETTID 0x01000000 /* set the TID in the child */ | ||
64 | #define CLONE_STOPPED 0x02000000 /* Start in stopped state */ | ||
65 | 86 | ||
66 | /* | 87 | /* |
67 | * List of flags we want to share for kernel threads, | 88 | * List of flags we want to share for kernel threads, |
@@ -103,13 +124,6 @@ extern unsigned long nr_uninterruptible(void); | |||
103 | extern unsigned long nr_active(void); | 124 | extern unsigned long nr_active(void); |
104 | extern unsigned long nr_iowait(void); | 125 | extern unsigned long nr_iowait(void); |
105 | 126 | ||
106 | #include <linux/time.h> | ||
107 | #include <linux/param.h> | ||
108 | #include <linux/resource.h> | ||
109 | #include <linux/timer.h> | ||
110 | #include <linux/hrtimer.h> | ||
111 | |||
112 | #include <asm/processor.h> | ||
113 | 127 | ||
114 | /* | 128 | /* |
115 | * Task state bitmask. NOTE! These bits are also | 129 | * Task state bitmask. NOTE! These bits are also |
@@ -156,20 +170,6 @@ extern unsigned long nr_iowait(void); | |||
156 | /* Task command name length */ | 170 | /* Task command name length */ |
157 | #define TASK_COMM_LEN 16 | 171 | #define TASK_COMM_LEN 16 |
158 | 172 | ||
159 | /* | ||
160 | * Scheduling policies | ||
161 | */ | ||
162 | #define SCHED_NORMAL 0 | ||
163 | #define SCHED_FIFO 1 | ||
164 | #define SCHED_RR 2 | ||
165 | #define SCHED_BATCH 3 | ||
166 | |||
167 | struct sched_param { | ||
168 | int sched_priority; | ||
169 | }; | ||
170 | |||
171 | #ifdef __KERNEL__ | ||
172 | |||
173 | #include <linux/spinlock.h> | 173 | #include <linux/spinlock.h> |
174 | 174 | ||
175 | /* | 175 | /* |
@@ -494,7 +494,7 @@ struct user_struct { | |||
494 | atomic_t processes; /* How many processes does this user have? */ | 494 | atomic_t processes; /* How many processes does this user have? */ |
495 | atomic_t files; /* How many open files does this user have? */ | 495 | atomic_t files; /* How many open files does this user have? */ |
496 | atomic_t sigpending; /* How many pending signals does this user have? */ | 496 | atomic_t sigpending; /* How many pending signals does this user have? */ |
497 | #ifdef CONFIG_INOTIFY | 497 | #ifdef CONFIG_INOTIFY_USER |
498 | atomic_t inotify_watches; /* How many inotify watches does this user have? */ | 498 | atomic_t inotify_watches; /* How many inotify watches does this user have? */ |
499 | atomic_t inotify_devs; /* How many inotify devs does this user have opened? */ | 499 | atomic_t inotify_devs; /* How many inotify devs does this user have opened? */ |
500 | #endif | 500 | #endif |
diff --git a/include/linux/seccomp.h b/include/linux/seccomp.h index cd2773b29a64..3e8b1cf54303 100644 --- a/include/linux/seccomp.h +++ b/include/linux/seccomp.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _LINUX_SECCOMP_H | 1 | #ifndef _LINUX_SECCOMP_H |
2 | #define _LINUX_SECCOMP_H | 2 | #define _LINUX_SECCOMP_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | #ifdef CONFIG_SECCOMP | 5 | #ifdef CONFIG_SECCOMP |
7 | 6 | ||
diff --git a/include/linux/security.h b/include/linux/security.h index 1bab48f6aeac..47722d355532 100644 --- a/include/linux/security.h +++ b/include/linux/security.h | |||
@@ -805,31 +805,37 @@ struct swap_info_struct; | |||
805 | * used by the XFRM system. | 805 | * used by the XFRM system. |
806 | * @sec_ctx contains the security context information being provided by | 806 | * @sec_ctx contains the security context information being provided by |
807 | * the user-level policy update program (e.g., setkey). | 807 | * the user-level policy update program (e.g., setkey). |
808 | * Allocate a security structure to the xp->selector.security field. | 808 | * Allocate a security structure to the xp->security field. |
809 | * The security field is initialized to NULL when the xfrm_policy is | 809 | * The security field is initialized to NULL when the xfrm_policy is |
810 | * allocated. | 810 | * allocated. |
811 | * Return 0 if operation was successful (memory to allocate, legal context) | 811 | * Return 0 if operation was successful (memory to allocate, legal context) |
812 | * @xfrm_policy_clone_security: | 812 | * @xfrm_policy_clone_security: |
813 | * @old contains an existing xfrm_policy in the SPD. | 813 | * @old contains an existing xfrm_policy in the SPD. |
814 | * @new contains a new xfrm_policy being cloned from old. | 814 | * @new contains a new xfrm_policy being cloned from old. |
815 | * Allocate a security structure to the new->selector.security field | 815 | * Allocate a security structure to the new->security field |
816 | * that contains the information from the old->selector.security field. | 816 | * that contains the information from the old->security field. |
817 | * Return 0 if operation was successful (memory to allocate). | 817 | * Return 0 if operation was successful (memory to allocate). |
818 | * @xfrm_policy_free_security: | 818 | * @xfrm_policy_free_security: |
819 | * @xp contains the xfrm_policy | 819 | * @xp contains the xfrm_policy |
820 | * Deallocate xp->selector.security. | 820 | * Deallocate xp->security. |
821 | * @xfrm_policy_delete_security: | ||
822 | * @xp contains the xfrm_policy. | ||
823 | * Authorize deletion of xp->security. | ||
821 | * @xfrm_state_alloc_security: | 824 | * @xfrm_state_alloc_security: |
822 | * @x contains the xfrm_state being added to the Security Association | 825 | * @x contains the xfrm_state being added to the Security Association |
823 | * Database by the XFRM system. | 826 | * Database by the XFRM system. |
824 | * @sec_ctx contains the security context information being provided by | 827 | * @sec_ctx contains the security context information being provided by |
825 | * the user-level SA generation program (e.g., setkey or racoon). | 828 | * the user-level SA generation program (e.g., setkey or racoon). |
826 | * Allocate a security structure to the x->sel.security field. The | 829 | * Allocate a security structure to the x->security field. The |
827 | * security field is initialized to NULL when the xfrm_state is | 830 | * security field is initialized to NULL when the xfrm_state is |
828 | * allocated. | 831 | * allocated. |
829 | * Return 0 if operation was successful (memory to allocate, legal context). | 832 | * Return 0 if operation was successful (memory to allocate, legal context). |
830 | * @xfrm_state_free_security: | 833 | * @xfrm_state_free_security: |
831 | * @x contains the xfrm_state. | 834 | * @x contains the xfrm_state. |
832 | * Deallocate x>sel.security. | 835 | * Deallocate x->security. |
836 | * @xfrm_state_delete_security: | ||
837 | * @x contains the xfrm_state. | ||
838 | * Authorize deletion of x->security. | ||
833 | * @xfrm_policy_lookup: | 839 | * @xfrm_policy_lookup: |
834 | * @xp contains the xfrm_policy for which the access control is being | 840 | * @xp contains the xfrm_policy for which the access control is being |
835 | * checked. | 841 | * checked. |
@@ -1298,14 +1304,16 @@ struct security_operations { | |||
1298 | int (*xfrm_policy_alloc_security) (struct xfrm_policy *xp, struct xfrm_user_sec_ctx *sec_ctx); | 1304 | int (*xfrm_policy_alloc_security) (struct xfrm_policy *xp, struct xfrm_user_sec_ctx *sec_ctx); |
1299 | int (*xfrm_policy_clone_security) (struct xfrm_policy *old, struct xfrm_policy *new); | 1305 | int (*xfrm_policy_clone_security) (struct xfrm_policy *old, struct xfrm_policy *new); |
1300 | void (*xfrm_policy_free_security) (struct xfrm_policy *xp); | 1306 | void (*xfrm_policy_free_security) (struct xfrm_policy *xp); |
1307 | int (*xfrm_policy_delete_security) (struct xfrm_policy *xp); | ||
1301 | int (*xfrm_state_alloc_security) (struct xfrm_state *x, struct xfrm_user_sec_ctx *sec_ctx); | 1308 | int (*xfrm_state_alloc_security) (struct xfrm_state *x, struct xfrm_user_sec_ctx *sec_ctx); |
1302 | void (*xfrm_state_free_security) (struct xfrm_state *x); | 1309 | void (*xfrm_state_free_security) (struct xfrm_state *x); |
1310 | int (*xfrm_state_delete_security) (struct xfrm_state *x); | ||
1303 | int (*xfrm_policy_lookup)(struct xfrm_policy *xp, u32 sk_sid, u8 dir); | 1311 | int (*xfrm_policy_lookup)(struct xfrm_policy *xp, u32 sk_sid, u8 dir); |
1304 | #endif /* CONFIG_SECURITY_NETWORK_XFRM */ | 1312 | #endif /* CONFIG_SECURITY_NETWORK_XFRM */ |
1305 | 1313 | ||
1306 | /* key management security hooks */ | 1314 | /* key management security hooks */ |
1307 | #ifdef CONFIG_KEYS | 1315 | #ifdef CONFIG_KEYS |
1308 | int (*key_alloc)(struct key *key); | 1316 | int (*key_alloc)(struct key *key, struct task_struct *tsk); |
1309 | void (*key_free)(struct key *key); | 1317 | void (*key_free)(struct key *key); |
1310 | int (*key_permission)(key_ref_t key_ref, | 1318 | int (*key_permission)(key_ref_t key_ref, |
1311 | struct task_struct *context, | 1319 | struct task_struct *context, |
@@ -2934,11 +2942,21 @@ static inline void security_xfrm_policy_free(struct xfrm_policy *xp) | |||
2934 | security_ops->xfrm_policy_free_security(xp); | 2942 | security_ops->xfrm_policy_free_security(xp); |
2935 | } | 2943 | } |
2936 | 2944 | ||
2945 | static inline int security_xfrm_policy_delete(struct xfrm_policy *xp) | ||
2946 | { | ||
2947 | return security_ops->xfrm_policy_delete_security(xp); | ||
2948 | } | ||
2949 | |||
2937 | static inline int security_xfrm_state_alloc(struct xfrm_state *x, struct xfrm_user_sec_ctx *sec_ctx) | 2950 | static inline int security_xfrm_state_alloc(struct xfrm_state *x, struct xfrm_user_sec_ctx *sec_ctx) |
2938 | { | 2951 | { |
2939 | return security_ops->xfrm_state_alloc_security(x, sec_ctx); | 2952 | return security_ops->xfrm_state_alloc_security(x, sec_ctx); |
2940 | } | 2953 | } |
2941 | 2954 | ||
2955 | static inline int security_xfrm_state_delete(struct xfrm_state *x) | ||
2956 | { | ||
2957 | return security_ops->xfrm_state_delete_security(x); | ||
2958 | } | ||
2959 | |||
2942 | static inline void security_xfrm_state_free(struct xfrm_state *x) | 2960 | static inline void security_xfrm_state_free(struct xfrm_state *x) |
2943 | { | 2961 | { |
2944 | security_ops->xfrm_state_free_security(x); | 2962 | security_ops->xfrm_state_free_security(x); |
@@ -2963,6 +2981,11 @@ static inline void security_xfrm_policy_free(struct xfrm_policy *xp) | |||
2963 | { | 2981 | { |
2964 | } | 2982 | } |
2965 | 2983 | ||
2984 | static inline int security_xfrm_policy_delete(struct xfrm_policy *xp) | ||
2985 | { | ||
2986 | return 0; | ||
2987 | } | ||
2988 | |||
2966 | static inline int security_xfrm_state_alloc(struct xfrm_state *x, struct xfrm_user_sec_ctx *sec_ctx) | 2989 | static inline int security_xfrm_state_alloc(struct xfrm_state *x, struct xfrm_user_sec_ctx *sec_ctx) |
2967 | { | 2990 | { |
2968 | return 0; | 2991 | return 0; |
@@ -2972,6 +2995,11 @@ static inline void security_xfrm_state_free(struct xfrm_state *x) | |||
2972 | { | 2995 | { |
2973 | } | 2996 | } |
2974 | 2997 | ||
2998 | static inline int security_xfrm_state_delete(struct xfrm_state *x) | ||
2999 | { | ||
3000 | return 0; | ||
3001 | } | ||
3002 | |||
2975 | static inline int security_xfrm_policy_lookup(struct xfrm_policy *xp, u32 sk_sid, u8 dir) | 3003 | static inline int security_xfrm_policy_lookup(struct xfrm_policy *xp, u32 sk_sid, u8 dir) |
2976 | { | 3004 | { |
2977 | return 0; | 3005 | return 0; |
@@ -2980,9 +3008,10 @@ static inline int security_xfrm_policy_lookup(struct xfrm_policy *xp, u32 sk_sid | |||
2980 | 3008 | ||
2981 | #ifdef CONFIG_KEYS | 3009 | #ifdef CONFIG_KEYS |
2982 | #ifdef CONFIG_SECURITY | 3010 | #ifdef CONFIG_SECURITY |
2983 | static inline int security_key_alloc(struct key *key) | 3011 | static inline int security_key_alloc(struct key *key, |
3012 | struct task_struct *tsk) | ||
2984 | { | 3013 | { |
2985 | return security_ops->key_alloc(key); | 3014 | return security_ops->key_alloc(key, tsk); |
2986 | } | 3015 | } |
2987 | 3016 | ||
2988 | static inline void security_key_free(struct key *key) | 3017 | static inline void security_key_free(struct key *key) |
@@ -2999,7 +3028,8 @@ static inline int security_key_permission(key_ref_t key_ref, | |||
2999 | 3028 | ||
3000 | #else | 3029 | #else |
3001 | 3030 | ||
3002 | static inline int security_key_alloc(struct key *key) | 3031 | static inline int security_key_alloc(struct key *key, |
3032 | struct task_struct *tsk) | ||
3003 | { | 3033 | { |
3004 | return 0; | 3034 | return 0; |
3005 | } | 3035 | } |
diff --git a/include/linux/selinux.h b/include/linux/selinux.h index 4047bcde4484..aad4e390d6a5 100644 --- a/include/linux/selinux.h +++ b/include/linux/selinux.h | |||
@@ -118,6 +118,27 @@ void selinux_get_ipc_sid(const struct kern_ipc_perm *ipcp, u32 *sid); | |||
118 | */ | 118 | */ |
119 | void selinux_get_task_sid(struct task_struct *tsk, u32 *sid); | 119 | void selinux_get_task_sid(struct task_struct *tsk, u32 *sid); |
120 | 120 | ||
121 | /** | ||
122 | * selinux_string_to_sid - map a security context string to a security ID | ||
123 | * @str: the security context string to be mapped | ||
124 | * @sid: ID value returned via this. | ||
125 | * | ||
126 | * Returns 0 if successful, with the SID stored in sid. A value | ||
127 | * of zero for sid indicates no SID could be determined (but no error | ||
128 | * occurred). | ||
129 | */ | ||
130 | int selinux_string_to_sid(char *str, u32 *sid); | ||
131 | |||
132 | /** | ||
133 | * selinux_relabel_packet_permission - check permission to relabel a packet | ||
134 | * @sid: ID value to be applied to network packet (via SECMARK, most likely) | ||
135 | * | ||
136 | * Returns 0 if the current task is allowed to label packets with the | ||
137 | * supplied security ID. Note that it is implicit that the packet is always | ||
138 | * being relabeled from the default unlabled value, and that the access | ||
139 | * control decision is made in the AVC. | ||
140 | */ | ||
141 | int selinux_relabel_packet_permission(u32 sid); | ||
121 | 142 | ||
122 | #else | 143 | #else |
123 | 144 | ||
@@ -172,6 +193,17 @@ static inline void selinux_get_task_sid(struct task_struct *tsk, u32 *sid) | |||
172 | *sid = 0; | 193 | *sid = 0; |
173 | } | 194 | } |
174 | 195 | ||
196 | static inline int selinux_string_to_sid(const char *str, u32 *sid) | ||
197 | { | ||
198 | *sid = 0; | ||
199 | return 0; | ||
200 | } | ||
201 | |||
202 | static inline int selinux_relabel_packet_permission(u32 sid) | ||
203 | { | ||
204 | return 0; | ||
205 | } | ||
206 | |||
175 | #endif /* CONFIG_SECURITY_SELINUX */ | 207 | #endif /* CONFIG_SECURITY_SELINUX */ |
176 | 208 | ||
177 | #endif /* _LINUX_SELINUX_H */ | 209 | #endif /* _LINUX_SELINUX_H */ |
diff --git a/include/linux/sem.h b/include/linux/sem.h index 3c1f1120fe88..9aaffb0b1d81 100644 --- a/include/linux/sem.h +++ b/include/linux/sem.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define _LINUX_SEM_H | 2 | #define _LINUX_SEM_H |
3 | 3 | ||
4 | #include <linux/ipc.h> | 4 | #include <linux/ipc.h> |
5 | #include <asm/atomic.h> | ||
6 | 5 | ||
7 | /* semop flags */ | 6 | /* semop flags */ |
8 | #define SEM_UNDO 0x1000 /* undo the operation on exit */ | 7 | #define SEM_UNDO 0x1000 /* undo the operation on exit */ |
@@ -78,6 +77,7 @@ struct seminfo { | |||
78 | #define SEMUSZ 20 /* sizeof struct sem_undo */ | 77 | #define SEMUSZ 20 /* sizeof struct sem_undo */ |
79 | 78 | ||
80 | #ifdef __KERNEL__ | 79 | #ifdef __KERNEL__ |
80 | #include <asm/atomic.h> | ||
81 | 81 | ||
82 | struct task_struct; | 82 | struct task_struct; |
83 | 83 | ||
diff --git a/include/linux/seqlock.h b/include/linux/seqlock.h index 5a095572881d..7bc5c7c12b54 100644 --- a/include/linux/seqlock.h +++ b/include/linux/seqlock.h | |||
@@ -26,7 +26,6 @@ | |||
26 | * by Keith Owens and Andrea Arcangeli | 26 | * by Keith Owens and Andrea Arcangeli |
27 | */ | 27 | */ |
28 | 28 | ||
29 | #include <linux/config.h> | ||
30 | #include <linux/spinlock.h> | 29 | #include <linux/spinlock.h> |
31 | #include <linux/preempt.h> | 30 | #include <linux/preempt.h> |
32 | 31 | ||
diff --git a/include/linux/serialP.h b/include/linux/serialP.h index 2b9e6b9554d5..e811a615f696 100644 --- a/include/linux/serialP.h +++ b/include/linux/serialP.h | |||
@@ -19,7 +19,6 @@ | |||
19 | * For definitions of the flags field, see tty.h | 19 | * For definitions of the flags field, see tty.h |
20 | */ | 20 | */ |
21 | 21 | ||
22 | #include <linux/config.h> | ||
23 | #include <linux/termios.h> | 22 | #include <linux/termios.h> |
24 | #include <linux/workqueue.h> | 23 | #include <linux/workqueue.h> |
25 | #include <linux/interrupt.h> | 24 | #include <linux/interrupt.h> |
diff --git a/include/linux/serial_core.h b/include/linux/serial_core.h index bd14858121ea..0ef50baa7da6 100644 --- a/include/linux/serial_core.h +++ b/include/linux/serial_core.h | |||
@@ -67,8 +67,8 @@ | |||
67 | /* Parisc type numbers. */ | 67 | /* Parisc type numbers. */ |
68 | #define PORT_MUX 48 | 68 | #define PORT_MUX 48 |
69 | 69 | ||
70 | /* Atmel AT91RM9200 SoC */ | 70 | /* Atmel AT91xxx SoC */ |
71 | #define PORT_AT91RM9200 49 | 71 | #define PORT_AT91 49 |
72 | 72 | ||
73 | /* Macintosh Zilog type numbers */ | 73 | /* Macintosh Zilog type numbers */ |
74 | #define PORT_MAC_ZILOG 50 /* m68k : not yet implemented */ | 74 | #define PORT_MAC_ZILOG 50 /* m68k : not yet implemented */ |
@@ -132,7 +132,6 @@ | |||
132 | 132 | ||
133 | #ifdef __KERNEL__ | 133 | #ifdef __KERNEL__ |
134 | 134 | ||
135 | #include <linux/config.h> | ||
136 | #include <linux/compiler.h> | 135 | #include <linux/compiler.h> |
137 | #include <linux/interrupt.h> | 136 | #include <linux/interrupt.h> |
138 | #include <linux/circ_buf.h> | 137 | #include <linux/circ_buf.h> |
diff --git a/include/linux/signal.h b/include/linux/signal.h index 70739f51a09f..1e4ce7225eee 100644 --- a/include/linux/signal.h +++ b/include/linux/signal.h | |||
@@ -1,12 +1,12 @@ | |||
1 | #ifndef _LINUX_SIGNAL_H | 1 | #ifndef _LINUX_SIGNAL_H |
2 | #define _LINUX_SIGNAL_H | 2 | #define _LINUX_SIGNAL_H |
3 | 3 | ||
4 | #include <linux/list.h> | ||
5 | #include <linux/spinlock.h> | ||
6 | #include <asm/signal.h> | 4 | #include <asm/signal.h> |
7 | #include <asm/siginfo.h> | 5 | #include <asm/siginfo.h> |
8 | 6 | ||
9 | #ifdef __KERNEL__ | 7 | #ifdef __KERNEL__ |
8 | #include <linux/list.h> | ||
9 | #include <linux/spinlock.h> | ||
10 | 10 | ||
11 | /* | 11 | /* |
12 | * These values of sa_flags are used only by the kernel as part of the | 12 | * These values of sa_flags are used only by the kernel as part of the |
diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h index f8f234708b98..66f8819f9568 100644 --- a/include/linux/skbuff.h +++ b/include/linux/skbuff.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #ifndef _LINUX_SKBUFF_H | 14 | #ifndef _LINUX_SKBUFF_H |
15 | #define _LINUX_SKBUFF_H | 15 | #define _LINUX_SKBUFF_H |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | #include <linux/kernel.h> | 17 | #include <linux/kernel.h> |
19 | #include <linux/compiler.h> | 18 | #include <linux/compiler.h> |
20 | #include <linux/time.h> | 19 | #include <linux/time.h> |
@@ -29,6 +28,7 @@ | |||
29 | #include <linux/net.h> | 28 | #include <linux/net.h> |
30 | #include <linux/textsearch.h> | 29 | #include <linux/textsearch.h> |
31 | #include <net/checksum.h> | 30 | #include <net/checksum.h> |
31 | #include <linux/dmaengine.h> | ||
32 | 32 | ||
33 | #define HAVE_ALLOC_SKB /* For the drivers to know */ | 33 | #define HAVE_ALLOC_SKB /* For the drivers to know */ |
34 | #define HAVE_ALIGNABLE_SKB /* Ditto 8) */ | 34 | #define HAVE_ALIGNABLE_SKB /* Ditto 8) */ |
@@ -209,6 +209,7 @@ enum { | |||
209 | * @nf_bridge: Saved data about a bridged frame - see br_netfilter.c | 209 | * @nf_bridge: Saved data about a bridged frame - see br_netfilter.c |
210 | * @tc_index: Traffic control index | 210 | * @tc_index: Traffic control index |
211 | * @tc_verd: traffic control verdict | 211 | * @tc_verd: traffic control verdict |
212 | * @secmark: security marking | ||
212 | */ | 213 | */ |
213 | 214 | ||
214 | struct sk_buff { | 215 | struct sk_buff { |
@@ -285,6 +286,12 @@ struct sk_buff { | |||
285 | __u16 tc_verd; /* traffic control verdict */ | 286 | __u16 tc_verd; /* traffic control verdict */ |
286 | #endif | 287 | #endif |
287 | #endif | 288 | #endif |
289 | #ifdef CONFIG_NET_DMA | ||
290 | dma_cookie_t dma_cookie; | ||
291 | #endif | ||
292 | #ifdef CONFIG_NETWORK_SECMARK | ||
293 | __u32 secmark; | ||
294 | #endif | ||
288 | 295 | ||
289 | 296 | ||
290 | /* These elements must be at the end, see alloc_skb() for details. */ | 297 | /* These elements must be at the end, see alloc_skb() for details. */ |
@@ -967,15 +974,16 @@ static inline void skb_reserve(struct sk_buff *skb, int len) | |||
967 | #define NET_SKB_PAD 16 | 974 | #define NET_SKB_PAD 16 |
968 | #endif | 975 | #endif |
969 | 976 | ||
970 | extern int ___pskb_trim(struct sk_buff *skb, unsigned int len, int realloc); | 977 | extern int ___pskb_trim(struct sk_buff *skb, unsigned int len); |
971 | 978 | ||
972 | static inline void __skb_trim(struct sk_buff *skb, unsigned int len) | 979 | static inline void __skb_trim(struct sk_buff *skb, unsigned int len) |
973 | { | 980 | { |
974 | if (!skb->data_len) { | 981 | if (unlikely(skb->data_len)) { |
975 | skb->len = len; | 982 | WARN_ON(1); |
976 | skb->tail = skb->data + len; | 983 | return; |
977 | } else | 984 | } |
978 | ___pskb_trim(skb, len, 0); | 985 | skb->len = len; |
986 | skb->tail = skb->data + len; | ||
979 | } | 987 | } |
980 | 988 | ||
981 | /** | 989 | /** |
@@ -985,6 +993,7 @@ static inline void __skb_trim(struct sk_buff *skb, unsigned int len) | |||
985 | * | 993 | * |
986 | * Cut the length of a buffer down by removing data from the tail. If | 994 | * Cut the length of a buffer down by removing data from the tail. If |
987 | * the buffer is already under the length specified it is not modified. | 995 | * the buffer is already under the length specified it is not modified. |
996 | * The skb must be linear. | ||
988 | */ | 997 | */ |
989 | static inline void skb_trim(struct sk_buff *skb, unsigned int len) | 998 | static inline void skb_trim(struct sk_buff *skb, unsigned int len) |
990 | { | 999 | { |
@@ -995,12 +1004,10 @@ static inline void skb_trim(struct sk_buff *skb, unsigned int len) | |||
995 | 1004 | ||
996 | static inline int __pskb_trim(struct sk_buff *skb, unsigned int len) | 1005 | static inline int __pskb_trim(struct sk_buff *skb, unsigned int len) |
997 | { | 1006 | { |
998 | if (!skb->data_len) { | 1007 | if (skb->data_len) |
999 | skb->len = len; | 1008 | return ___pskb_trim(skb, len); |
1000 | skb->tail = skb->data+len; | 1009 | __skb_trim(skb, len); |
1001 | return 0; | 1010 | return 0; |
1002 | } | ||
1003 | return ___pskb_trim(skb, len, 1); | ||
1004 | } | 1011 | } |
1005 | 1012 | ||
1006 | static inline int pskb_trim(struct sk_buff *skb, unsigned int len) | 1013 | static inline int pskb_trim(struct sk_buff *skb, unsigned int len) |
@@ -1161,18 +1168,34 @@ static inline int skb_can_coalesce(struct sk_buff *skb, int i, | |||
1161 | return 0; | 1168 | return 0; |
1162 | } | 1169 | } |
1163 | 1170 | ||
1171 | static inline int __skb_linearize(struct sk_buff *skb) | ||
1172 | { | ||
1173 | return __pskb_pull_tail(skb, skb->data_len) ? 0 : -ENOMEM; | ||
1174 | } | ||
1175 | |||
1164 | /** | 1176 | /** |
1165 | * skb_linearize - convert paged skb to linear one | 1177 | * skb_linearize - convert paged skb to linear one |
1166 | * @skb: buffer to linarize | 1178 | * @skb: buffer to linarize |
1167 | * @gfp: allocation mode | ||
1168 | * | 1179 | * |
1169 | * If there is no free memory -ENOMEM is returned, otherwise zero | 1180 | * If there is no free memory -ENOMEM is returned, otherwise zero |
1170 | * is returned and the old skb data released. | 1181 | * is returned and the old skb data released. |
1171 | */ | 1182 | */ |
1172 | extern int __skb_linearize(struct sk_buff *skb, gfp_t gfp); | 1183 | static inline int skb_linearize(struct sk_buff *skb) |
1173 | static inline int skb_linearize(struct sk_buff *skb, gfp_t gfp) | 1184 | { |
1185 | return skb_is_nonlinear(skb) ? __skb_linearize(skb) : 0; | ||
1186 | } | ||
1187 | |||
1188 | /** | ||
1189 | * skb_linearize_cow - make sure skb is linear and writable | ||
1190 | * @skb: buffer to process | ||
1191 | * | ||
1192 | * If there is no free memory -ENOMEM is returned, otherwise zero | ||
1193 | * is returned and the old skb data released. | ||
1194 | */ | ||
1195 | static inline int skb_linearize_cow(struct sk_buff *skb) | ||
1174 | { | 1196 | { |
1175 | return __skb_linearize(skb, gfp); | 1197 | return skb_is_nonlinear(skb) || skb_cloned(skb) ? |
1198 | __skb_linearize(skb) : 0; | ||
1176 | } | 1199 | } |
1177 | 1200 | ||
1178 | /** | 1201 | /** |
@@ -1396,5 +1419,23 @@ static inline void nf_reset(struct sk_buff *skb) | |||
1396 | static inline void nf_reset(struct sk_buff *skb) {} | 1419 | static inline void nf_reset(struct sk_buff *skb) {} |
1397 | #endif /* CONFIG_NETFILTER */ | 1420 | #endif /* CONFIG_NETFILTER */ |
1398 | 1421 | ||
1422 | #ifdef CONFIG_NETWORK_SECMARK | ||
1423 | static inline void skb_copy_secmark(struct sk_buff *to, const struct sk_buff *from) | ||
1424 | { | ||
1425 | to->secmark = from->secmark; | ||
1426 | } | ||
1427 | |||
1428 | static inline void skb_init_secmark(struct sk_buff *skb) | ||
1429 | { | ||
1430 | skb->secmark = 0; | ||
1431 | } | ||
1432 | #else | ||
1433 | static inline void skb_copy_secmark(struct sk_buff *to, const struct sk_buff *from) | ||
1434 | { } | ||
1435 | |||
1436 | static inline void skb_init_secmark(struct sk_buff *skb) | ||
1437 | { } | ||
1438 | #endif | ||
1439 | |||
1399 | #endif /* __KERNEL__ */ | 1440 | #endif /* __KERNEL__ */ |
1400 | #endif /* _LINUX_SKBUFF_H */ | 1441 | #endif /* _LINUX_SKBUFF_H */ |
diff --git a/include/linux/slab.h b/include/linux/slab.h index 2d985d59c7b8..9dc93163e065 100644 --- a/include/linux/slab.h +++ b/include/linux/slab.h | |||
@@ -11,7 +11,6 @@ | |||
11 | 11 | ||
12 | typedef struct kmem_cache kmem_cache_t; | 12 | typedef struct kmem_cache kmem_cache_t; |
13 | 13 | ||
14 | #include <linux/config.h> /* kmalloc_sizes.h needs CONFIG_ options */ | ||
15 | #include <linux/gfp.h> | 14 | #include <linux/gfp.h> |
16 | #include <linux/init.h> | 15 | #include <linux/init.h> |
17 | #include <linux/types.h> | 16 | #include <linux/types.h> |
diff --git a/include/linux/smb_fs.h b/include/linux/smb_fs.h index 621a3d3662f3..367d6c3e8ed4 100644 --- a/include/linux/smb_fs.h +++ b/include/linux/smb_fs.h | |||
@@ -10,8 +10,6 @@ | |||
10 | #define _LINUX_SMB_FS_H | 10 | #define _LINUX_SMB_FS_H |
11 | 11 | ||
12 | #include <linux/smb.h> | 12 | #include <linux/smb.h> |
13 | #include <linux/smb_fs_i.h> | ||
14 | #include <linux/smb_fs_sb.h> | ||
15 | 13 | ||
16 | /* | 14 | /* |
17 | * ioctl commands | 15 | * ioctl commands |
@@ -24,6 +22,8 @@ | |||
24 | 22 | ||
25 | 23 | ||
26 | #ifdef __KERNEL__ | 24 | #ifdef __KERNEL__ |
25 | #include <linux/smb_fs_i.h> | ||
26 | #include <linux/smb_fs_sb.h> | ||
27 | 27 | ||
28 | #include <linux/fs.h> | 28 | #include <linux/fs.h> |
29 | #include <linux/pagemap.h> | 29 | #include <linux/pagemap.h> |
diff --git a/include/linux/smp.h b/include/linux/smp.h index e2fa3ab4afc5..c93c3fe4308c 100644 --- a/include/linux/smp.h +++ b/include/linux/smp.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * Alan Cox. <alan@redhat.com> | 6 | * Alan Cox. <alan@redhat.com> |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | 9 | ||
11 | extern void cpu_idle(void); | 10 | extern void cpu_idle(void); |
12 | 11 | ||
diff --git a/include/linux/smp_lock.h b/include/linux/smp_lock.h index fa1ff3b165fe..cf715a40d833 100644 --- a/include/linux/smp_lock.h +++ b/include/linux/smp_lock.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __LINUX_SMPLOCK_H | 1 | #ifndef __LINUX_SMPLOCK_H |
2 | #define __LINUX_SMPLOCK_H | 2 | #define __LINUX_SMPLOCK_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #ifdef CONFIG_LOCK_KERNEL | 4 | #ifdef CONFIG_LOCK_KERNEL |
6 | #include <linux/sched.h> | 5 | #include <linux/sched.h> |
7 | #include <linux/spinlock.h> | 6 | #include <linux/spinlock.h> |
diff --git a/include/linux/socket.h b/include/linux/socket.h index 9ab2ddd80221..361409094649 100644 --- a/include/linux/socket.h +++ b/include/linux/socket.h | |||
@@ -18,8 +18,6 @@ struct __kernel_sockaddr_storage { | |||
18 | 18 | ||
19 | #if defined(__KERNEL__) || !defined(__GLIBC__) || (__GLIBC__ < 2) | 19 | #if defined(__KERNEL__) || !defined(__GLIBC__) || (__GLIBC__ < 2) |
20 | 20 | ||
21 | #include <linux/config.h> /* for CONFIG_COMPAT */ | ||
22 | #include <linux/linkage.h> | ||
23 | #include <asm/socket.h> /* arch-dependent defines */ | 21 | #include <asm/socket.h> /* arch-dependent defines */ |
24 | #include <linux/sockios.h> /* the SIOCxxx I/O controls */ | 22 | #include <linux/sockios.h> /* the SIOCxxx I/O controls */ |
25 | #include <linux/uio.h> /* iovec support */ | 23 | #include <linux/uio.h> /* iovec support */ |
diff --git a/include/linux/spinlock.h b/include/linux/spinlock.h index 799be6747944..ae23beef9cc9 100644 --- a/include/linux/spinlock.h +++ b/include/linux/spinlock.h | |||
@@ -46,7 +46,6 @@ | |||
46 | * linux/spinlock.h: builds the final spin_*() APIs. | 46 | * linux/spinlock.h: builds the final spin_*() APIs. |
47 | */ | 47 | */ |
48 | 48 | ||
49 | #include <linux/config.h> | ||
50 | #include <linux/preempt.h> | 49 | #include <linux/preempt.h> |
51 | #include <linux/linkage.h> | 50 | #include <linux/linkage.h> |
52 | #include <linux/compiler.h> | 51 | #include <linux/compiler.h> |
diff --git a/include/linux/stop_machine.h b/include/linux/stop_machine.h index 151a803ed0ed..5bfc553bdb21 100644 --- a/include/linux/stop_machine.h +++ b/include/linux/stop_machine.h | |||
@@ -4,7 +4,6 @@ | |||
4 | very heavy lock, which is equivalent to grabbing every spinlock | 4 | very heavy lock, which is equivalent to grabbing every spinlock |
5 | (and more). So the "read" side to such a lock is anything which | 5 | (and more). So the "read" side to such a lock is anything which |
6 | diables preeempt. */ | 6 | diables preeempt. */ |
7 | #include <linux/config.h> | ||
8 | #include <linux/cpu.h> | 7 | #include <linux/cpu.h> |
9 | #include <asm/system.h> | 8 | #include <asm/system.h> |
10 | 9 | ||
diff --git a/include/linux/sunrpc/auth.h b/include/linux/sunrpc/auth.h index be4772ed43c0..a6de332e57d4 100644 --- a/include/linux/sunrpc/auth.h +++ b/include/linux/sunrpc/auth.h | |||
@@ -11,7 +11,6 @@ | |||
11 | 11 | ||
12 | #ifdef __KERNEL__ | 12 | #ifdef __KERNEL__ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | #include <linux/sunrpc/sched.h> | 14 | #include <linux/sunrpc/sched.h> |
16 | #include <linux/sunrpc/msg_prot.h> | 15 | #include <linux/sunrpc/msg_prot.h> |
17 | #include <linux/sunrpc/xdr.h> | 16 | #include <linux/sunrpc/xdr.h> |
diff --git a/include/linux/sunrpc/debug.h b/include/linux/sunrpc/debug.h index 1a42d902bc11..e4729aa67654 100644 --- a/include/linux/sunrpc/debug.h +++ b/include/linux/sunrpc/debug.h | |||
@@ -9,19 +9,6 @@ | |||
9 | #ifndef _LINUX_SUNRPC_DEBUG_H_ | 9 | #ifndef _LINUX_SUNRPC_DEBUG_H_ |
10 | #define _LINUX_SUNRPC_DEBUG_H_ | 10 | #define _LINUX_SUNRPC_DEBUG_H_ |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | |||
14 | #include <linux/timer.h> | ||
15 | #include <linux/workqueue.h> | ||
16 | |||
17 | /* | ||
18 | * Enable RPC debugging/profiling. | ||
19 | */ | ||
20 | #ifdef CONFIG_SYSCTL | ||
21 | #define RPC_DEBUG | ||
22 | #endif | ||
23 | /* #define RPC_PROFILE */ | ||
24 | |||
25 | /* | 12 | /* |
26 | * RPC debug facilities | 13 | * RPC debug facilities |
27 | */ | 14 | */ |
@@ -41,6 +28,17 @@ | |||
41 | 28 | ||
42 | #ifdef __KERNEL__ | 29 | #ifdef __KERNEL__ |
43 | 30 | ||
31 | #include <linux/timer.h> | ||
32 | #include <linux/workqueue.h> | ||
33 | |||
34 | /* | ||
35 | * Enable RPC debugging/profiling. | ||
36 | */ | ||
37 | #ifdef CONFIG_SYSCTL | ||
38 | #define RPC_DEBUG | ||
39 | #endif | ||
40 | /* #define RPC_PROFILE */ | ||
41 | |||
44 | /* | 42 | /* |
45 | * Debugging macros etc | 43 | * Debugging macros etc |
46 | */ | 44 | */ |
diff --git a/include/linux/sunrpc/stats.h b/include/linux/sunrpc/stats.h index d93c24b47f3f..5fa0f2084307 100644 --- a/include/linux/sunrpc/stats.h +++ b/include/linux/sunrpc/stats.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef _LINUX_SUNRPC_STATS_H | 9 | #ifndef _LINUX_SUNRPC_STATS_H |
10 | #define _LINUX_SUNRPC_STATS_H | 10 | #define _LINUX_SUNRPC_STATS_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | #include <linux/proc_fs.h> | 12 | #include <linux/proc_fs.h> |
14 | 13 | ||
15 | struct rpc_stat { | 14 | struct rpc_stat { |
diff --git a/include/linux/suspend.h b/include/linux/suspend.h index 37c1c76fd547..96e31aa64cc7 100644 --- a/include/linux/suspend.h +++ b/include/linux/suspend.h | |||
@@ -6,7 +6,6 @@ | |||
6 | #endif | 6 | #endif |
7 | #include <linux/swap.h> | 7 | #include <linux/swap.h> |
8 | #include <linux/notifier.h> | 8 | #include <linux/notifier.h> |
9 | #include <linux/config.h> | ||
10 | #include <linux/init.h> | 9 | #include <linux/init.h> |
11 | #include <linux/pm.h> | 10 | #include <linux/pm.h> |
12 | 11 | ||
diff --git a/include/linux/swap.h b/include/linux/swap.h index f03c24719302..aca9bfae208f 100644 --- a/include/linux/swap.h +++ b/include/linux/swap.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _LINUX_SWAP_H | 1 | #ifndef _LINUX_SWAP_H |
2 | #define _LINUX_SWAP_H | 2 | #define _LINUX_SWAP_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/spinlock.h> | 4 | #include <linux/spinlock.h> |
6 | #include <linux/linkage.h> | 5 | #include <linux/linkage.h> |
7 | #include <linux/mmzone.h> | 6 | #include <linux/mmzone.h> |
diff --git a/include/linux/syscalls.h b/include/linux/syscalls.h index 60d49e5456e7..bd67a4413df7 100644 --- a/include/linux/syscalls.h +++ b/include/linux/syscalls.h | |||
@@ -54,7 +54,6 @@ struct compat_stat; | |||
54 | struct compat_timeval; | 54 | struct compat_timeval; |
55 | struct robust_list_head; | 55 | struct robust_list_head; |
56 | 56 | ||
57 | #include <linux/config.h> | ||
58 | #include <linux/types.h> | 57 | #include <linux/types.h> |
59 | #include <linux/aio_abi.h> | 58 | #include <linux/aio_abi.h> |
60 | #include <linux/capability.h> | 59 | #include <linux/capability.h> |
diff --git a/include/linux/sysctl.h b/include/linux/sysctl.h index 76eaeff76f82..cee944dbdcd4 100644 --- a/include/linux/sysctl.h +++ b/include/linux/sysctl.h | |||
@@ -313,6 +313,7 @@ enum | |||
313 | NET_NF_CONNTRACK_FRAG6_TIMEOUT=29, | 313 | NET_NF_CONNTRACK_FRAG6_TIMEOUT=29, |
314 | NET_NF_CONNTRACK_FRAG6_LOW_THRESH=30, | 314 | NET_NF_CONNTRACK_FRAG6_LOW_THRESH=30, |
315 | NET_NF_CONNTRACK_FRAG6_HIGH_THRESH=31, | 315 | NET_NF_CONNTRACK_FRAG6_HIGH_THRESH=31, |
316 | NET_NF_CONNTRACK_CHECKSUM=32, | ||
316 | }; | 317 | }; |
317 | 318 | ||
318 | /* /proc/sys/net/ipv4 */ | 319 | /* /proc/sys/net/ipv4 */ |
@@ -403,6 +404,8 @@ enum | |||
403 | NET_TCP_MTU_PROBING=113, | 404 | NET_TCP_MTU_PROBING=113, |
404 | NET_TCP_BASE_MSS=114, | 405 | NET_TCP_BASE_MSS=114, |
405 | NET_IPV4_TCP_WORKAROUND_SIGNED_WINDOWS=115, | 406 | NET_IPV4_TCP_WORKAROUND_SIGNED_WINDOWS=115, |
407 | NET_TCP_DMA_COPYBREAK=116, | ||
408 | NET_TCP_SLOW_START_AFTER_IDLE=117, | ||
406 | }; | 409 | }; |
407 | 410 | ||
408 | enum { | 411 | enum { |
@@ -491,6 +494,7 @@ enum | |||
491 | NET_IPV4_NF_CONNTRACK_SCTP_TIMEOUT_SHUTDOWN_RECD=25, | 494 | NET_IPV4_NF_CONNTRACK_SCTP_TIMEOUT_SHUTDOWN_RECD=25, |
492 | NET_IPV4_NF_CONNTRACK_SCTP_TIMEOUT_SHUTDOWN_ACK_SENT=26, | 495 | NET_IPV4_NF_CONNTRACK_SCTP_TIMEOUT_SHUTDOWN_ACK_SENT=26, |
493 | NET_IPV4_NF_CONNTRACK_COUNT=27, | 496 | NET_IPV4_NF_CONNTRACK_COUNT=27, |
497 | NET_IPV4_NF_CONNTRACK_CHECKSUM=28, | ||
494 | }; | 498 | }; |
495 | 499 | ||
496 | /* /proc/sys/net/ipv6 */ | 500 | /* /proc/sys/net/ipv6 */ |
diff --git a/include/linux/sysdev.h b/include/linux/sysdev.h index 2a4b432e1176..166a2e58c287 100644 --- a/include/linux/sysdev.h +++ b/include/linux/sysdev.h | |||
@@ -37,11 +37,27 @@ struct sysdev_class { | |||
37 | struct kset kset; | 37 | struct kset kset; |
38 | }; | 38 | }; |
39 | 39 | ||
40 | struct sysdev_class_attribute { | ||
41 | struct attribute attr; | ||
42 | ssize_t (*show)(struct sysdev_class *, char *); | ||
43 | ssize_t (*store)(struct sysdev_class *, const char *, size_t); | ||
44 | }; | ||
45 | |||
46 | #define SYSDEV_CLASS_ATTR(_name,_mode,_show,_store) \ | ||
47 | struct sysdev_class_attribute attr_##_name = { \ | ||
48 | .attr = {.name = __stringify(_name), .mode = _mode }, \ | ||
49 | .show = _show, \ | ||
50 | .store = _store, \ | ||
51 | }; | ||
52 | |||
40 | 53 | ||
41 | extern int sysdev_class_register(struct sysdev_class *); | 54 | extern int sysdev_class_register(struct sysdev_class *); |
42 | extern void sysdev_class_unregister(struct sysdev_class *); | 55 | extern void sysdev_class_unregister(struct sysdev_class *); |
43 | 56 | ||
44 | 57 | extern int sysdev_class_create_file(struct sysdev_class *, | |
58 | struct sysdev_class_attribute *); | ||
59 | extern void sysdev_class_remove_file(struct sysdev_class *, | ||
60 | struct sysdev_class_attribute *); | ||
45 | /** | 61 | /** |
46 | * Auxillary system device drivers. | 62 | * Auxillary system device drivers. |
47 | */ | 63 | */ |
diff --git a/include/linux/sysrq.h b/include/linux/sysrq.h index ea819b89c235..4812ff60561c 100644 --- a/include/linux/sysrq.h +++ b/include/linux/sysrq.h | |||
@@ -11,7 +11,6 @@ | |||
11 | * based upon discusions in irc://irc.openprojects.net/#kernelnewbies | 11 | * based upon discusions in irc://irc.openprojects.net/#kernelnewbies |
12 | */ | 12 | */ |
13 | 13 | ||
14 | #include <linux/config.h> | ||
15 | 14 | ||
16 | struct pt_regs; | 15 | struct pt_regs; |
17 | struct tty_struct; | 16 | struct tty_struct; |
diff --git a/include/linux/tcp.h b/include/linux/tcp.h index 542d39596bd8..420a689c3fb4 100644 --- a/include/linux/tcp.h +++ b/include/linux/tcp.h | |||
@@ -18,6 +18,7 @@ | |||
18 | #define _LINUX_TCP_H | 18 | #define _LINUX_TCP_H |
19 | 19 | ||
20 | #include <linux/types.h> | 20 | #include <linux/types.h> |
21 | #include <linux/dmaengine.h> | ||
21 | #include <asm/byteorder.h> | 22 | #include <asm/byteorder.h> |
22 | 23 | ||
23 | struct tcphdr { | 24 | struct tcphdr { |
@@ -159,7 +160,6 @@ struct tcp_info | |||
159 | 160 | ||
160 | #ifdef __KERNEL__ | 161 | #ifdef __KERNEL__ |
161 | 162 | ||
162 | #include <linux/config.h> | ||
163 | #include <linux/skbuff.h> | 163 | #include <linux/skbuff.h> |
164 | #include <net/sock.h> | 164 | #include <net/sock.h> |
165 | #include <net/inet_connection_sock.h> | 165 | #include <net/inet_connection_sock.h> |
@@ -233,6 +233,13 @@ struct tcp_sock { | |||
233 | struct iovec *iov; | 233 | struct iovec *iov; |
234 | int memory; | 234 | int memory; |
235 | int len; | 235 | int len; |
236 | #ifdef CONFIG_NET_DMA | ||
237 | /* members for async copy */ | ||
238 | struct dma_chan *dma_chan; | ||
239 | int wakeup; | ||
240 | struct dma_pinned_list *pinned_list; | ||
241 | dma_cookie_t dma_cookie; | ||
242 | #endif | ||
236 | } ucopy; | 243 | } ucopy; |
237 | 244 | ||
238 | __u32 snd_wl1; /* Sequence for window update */ | 245 | __u32 snd_wl1; /* Sequence for window update */ |
diff --git a/include/linux/threads.h b/include/linux/threads.h index e646bcdf2614..38d1a5d6568e 100644 --- a/include/linux/threads.h +++ b/include/linux/threads.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _LINUX_THREADS_H | 1 | #ifndef _LINUX_THREADS_H |
2 | #define _LINUX_THREADS_H | 2 | #define _LINUX_THREADS_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | /* | 5 | /* |
7 | * The default limit for the nr of threads is now in | 6 | * The default limit for the nr of threads is now in |
diff --git a/include/linux/timer.h b/include/linux/timer.h index 0a485beba9f5..c982304dbafd 100644 --- a/include/linux/timer.h +++ b/include/linux/timer.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef _LINUX_TIMER_H | 1 | #ifndef _LINUX_TIMER_H |
2 | #define _LINUX_TIMER_H | 2 | #define _LINUX_TIMER_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/list.h> | 4 | #include <linux/list.h> |
6 | #include <linux/spinlock.h> | 5 | #include <linux/spinlock.h> |
7 | #include <linux/stddef.h> | 6 | #include <linux/stddef.h> |
diff --git a/include/linux/timex.h b/include/linux/timex.h index 03914b7e41b1..34d3ccff7bbb 100644 --- a/include/linux/timex.h +++ b/include/linux/timex.h | |||
@@ -53,7 +53,6 @@ | |||
53 | #ifndef _LINUX_TIMEX_H | 53 | #ifndef _LINUX_TIMEX_H |
54 | #define _LINUX_TIMEX_H | 54 | #define _LINUX_TIMEX_H |
55 | 55 | ||
56 | #include <linux/config.h> | ||
57 | #include <linux/compiler.h> | 56 | #include <linux/compiler.h> |
58 | #include <linux/time.h> | 57 | #include <linux/time.h> |
59 | 58 | ||
diff --git a/include/linux/tty.h b/include/linux/tty.h index f13f49afe198..cb35ca50a0a6 100644 --- a/include/linux/tty.h +++ b/include/linux/tty.h | |||
@@ -16,7 +16,6 @@ | |||
16 | consoles 16 and higher (since it returns a short) */ | 16 | consoles 16 and higher (since it returns a short) */ |
17 | 17 | ||
18 | #ifdef __KERNEL__ | 18 | #ifdef __KERNEL__ |
19 | #include <linux/config.h> | ||
20 | #include <linux/fs.h> | 19 | #include <linux/fs.h> |
21 | #include <linux/major.h> | 20 | #include <linux/major.h> |
22 | #include <linux/termios.h> | 21 | #include <linux/termios.h> |
@@ -291,7 +290,9 @@ extern int tty_register_ldisc(int disc, struct tty_ldisc *new_ldisc); | |||
291 | extern int tty_unregister_ldisc(int disc); | 290 | extern int tty_unregister_ldisc(int disc); |
292 | extern int tty_register_driver(struct tty_driver *driver); | 291 | extern int tty_register_driver(struct tty_driver *driver); |
293 | extern int tty_unregister_driver(struct tty_driver *driver); | 292 | extern int tty_unregister_driver(struct tty_driver *driver); |
294 | extern void tty_register_device(struct tty_driver *driver, unsigned index, struct device *dev); | 293 | extern struct class_device *tty_register_device(struct tty_driver *driver, |
294 | unsigned index, | ||
295 | struct device *dev); | ||
295 | extern void tty_unregister_device(struct tty_driver *driver, unsigned index); | 296 | extern void tty_unregister_device(struct tty_driver *driver, unsigned index); |
296 | extern int tty_read_raw_data(struct tty_struct *tty, unsigned char *bufp, | 297 | extern int tty_read_raw_data(struct tty_struct *tty, unsigned char *bufp, |
297 | int buflen); | 298 | int buflen); |
diff --git a/include/linux/types.h b/include/linux/types.h index 1046c7ad86d9..a5e46e783ffa 100644 --- a/include/linux/types.h +++ b/include/linux/types.h | |||
@@ -2,7 +2,6 @@ | |||
2 | #define _LINUX_TYPES_H | 2 | #define _LINUX_TYPES_H |
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | #include <linux/config.h> | ||
6 | 5 | ||
7 | #define BITS_TO_LONGS(bits) \ | 6 | #define BITS_TO_LONGS(bits) \ |
8 | (((bits)+BITS_PER_LONG-1)/BITS_PER_LONG) | 7 | (((bits)+BITS_PER_LONG-1)/BITS_PER_LONG) |
diff --git a/include/linux/udp.h b/include/linux/udp.h index 85a55658831c..bdd39be09406 100644 --- a/include/linux/udp.h +++ b/include/linux/udp.h | |||
@@ -35,7 +35,6 @@ struct udphdr { | |||
35 | #define UDP_ENCAP_ESPINUDP 2 /* draft-ietf-ipsec-udp-encaps-06 */ | 35 | #define UDP_ENCAP_ESPINUDP 2 /* draft-ietf-ipsec-udp-encaps-06 */ |
36 | 36 | ||
37 | #ifdef __KERNEL__ | 37 | #ifdef __KERNEL__ |
38 | #include <linux/config.h> | ||
39 | #include <linux/types.h> | 38 | #include <linux/types.h> |
40 | 39 | ||
41 | #include <net/inet_sock.h> | 40 | #include <net/inet_sock.h> |
diff --git a/include/linux/ufs_fs.h b/include/linux/ufs_fs.h index 843aeaaa79d4..86b5b4271b5a 100644 --- a/include/linux/ufs_fs.h +++ b/include/linux/ufs_fs.h | |||
@@ -32,7 +32,6 @@ | |||
32 | 32 | ||
33 | #include <linux/types.h> | 33 | #include <linux/types.h> |
34 | #include <linux/kernel.h> | 34 | #include <linux/kernel.h> |
35 | #include <linux/time.h> | ||
36 | #include <linux/stat.h> | 35 | #include <linux/stat.h> |
37 | #include <linux/fs.h> | 36 | #include <linux/fs.h> |
38 | 37 | ||
diff --git a/include/linux/unistd.h b/include/linux/unistd.h index 10ed9834b822..c18c60f3254e 100644 --- a/include/linux/unistd.h +++ b/include/linux/unistd.h | |||
@@ -1,7 +1,9 @@ | |||
1 | #ifndef _LINUX_UNISTD_H_ | 1 | #ifndef _LINUX_UNISTD_H_ |
2 | #define _LINUX_UNISTD_H_ | 2 | #define _LINUX_UNISTD_H_ |
3 | 3 | ||
4 | #ifdef __KERNEL__ | ||
4 | extern int errno; | 5 | extern int errno; |
6 | #endif | ||
5 | 7 | ||
6 | /* | 8 | /* |
7 | * Include machine specific syscallX macros | 9 | * Include machine specific syscallX macros |
diff --git a/include/linux/usb.h b/include/linux/usb.h index e34e5e3dce52..8dead32e7ebf 100644 --- a/include/linux/usb.h +++ b/include/linux/usb.h | |||
@@ -10,7 +10,6 @@ | |||
10 | 10 | ||
11 | #ifdef __KERNEL__ | 11 | #ifdef __KERNEL__ |
12 | 12 | ||
13 | #include <linux/config.h> | ||
14 | #include <linux/errno.h> /* for -ENODEV */ | 13 | #include <linux/errno.h> /* for -ENODEV */ |
15 | #include <linux/delay.h> /* for mdelay() */ | 14 | #include <linux/delay.h> /* for mdelay() */ |
16 | #include <linux/interrupt.h> /* for in_interrupt() */ | 15 | #include <linux/interrupt.h> /* for in_interrupt() */ |
@@ -41,6 +40,8 @@ struct usb_driver; | |||
41 | * Devices may also have class-specific or vendor-specific descriptors. | 40 | * Devices may also have class-specific or vendor-specific descriptors. |
42 | */ | 41 | */ |
43 | 42 | ||
43 | struct ep_device; | ||
44 | |||
44 | /** | 45 | /** |
45 | * struct usb_host_endpoint - host-side endpoint descriptor and queue | 46 | * struct usb_host_endpoint - host-side endpoint descriptor and queue |
46 | * @desc: descriptor for this endpoint, wMaxPacketSize in native byteorder | 47 | * @desc: descriptor for this endpoint, wMaxPacketSize in native byteorder |
@@ -58,7 +59,7 @@ struct usb_host_endpoint { | |||
58 | struct usb_endpoint_descriptor desc; | 59 | struct usb_endpoint_descriptor desc; |
59 | struct list_head urb_list; | 60 | struct list_head urb_list; |
60 | void *hcpriv; | 61 | void *hcpriv; |
61 | struct kobject *kobj; /* For sysfs info */ | 62 | struct ep_device *ep_dev; /* For sysfs info */ |
62 | 63 | ||
63 | unsigned char *extra; /* Extra descriptors */ | 64 | unsigned char *extra; /* Extra descriptors */ |
64 | int extralen; | 65 | int extralen; |
@@ -102,7 +103,8 @@ enum usb_interface_condition { | |||
102 | * @condition: binding state of the interface: not bound, binding | 103 | * @condition: binding state of the interface: not bound, binding |
103 | * (in probe()), bound to a driver, or unbinding (in disconnect()) | 104 | * (in probe()), bound to a driver, or unbinding (in disconnect()) |
104 | * @dev: driver model's view of this device | 105 | * @dev: driver model's view of this device |
105 | * @class_dev: driver model's class view of this device. | 106 | * @usb_dev: if an interface is bound to the USB major, this will point |
107 | * to the sysfs representation for that device. | ||
106 | * | 108 | * |
107 | * USB device drivers attach to interfaces on a physical device. Each | 109 | * USB device drivers attach to interfaces on a physical device. Each |
108 | * interface encapsulates a single high level function, such as feeding | 110 | * interface encapsulates a single high level function, such as feeding |
@@ -142,7 +144,7 @@ struct usb_interface { | |||
142 | * bound to */ | 144 | * bound to */ |
143 | enum usb_interface_condition condition; /* state of binding */ | 145 | enum usb_interface_condition condition; /* state of binding */ |
144 | struct device dev; /* interface specific device info */ | 146 | struct device dev; /* interface specific device info */ |
145 | struct class_device *class_dev; | 147 | struct device *usb_dev; /* pointer to the usb class's device, if any */ |
146 | }; | 148 | }; |
147 | #define to_usb_interface(d) container_of(d, struct usb_interface, dev) | 149 | #define to_usb_interface(d) container_of(d, struct usb_interface, dev) |
148 | #define interface_to_usbdev(intf) \ | 150 | #define interface_to_usbdev(intf) \ |
@@ -359,7 +361,7 @@ struct usb_device { | |||
359 | char *serial; /* iSerialNumber string, if present */ | 361 | char *serial; /* iSerialNumber string, if present */ |
360 | 362 | ||
361 | struct list_head filelist; | 363 | struct list_head filelist; |
362 | struct class_device *class_dev; | 364 | struct device *usbfs_dev; |
363 | struct dentry *usbfs_dentry; /* usbfs dentry entry for the device */ | 365 | struct dentry *usbfs_dentry; /* usbfs dentry entry for the device */ |
364 | 366 | ||
365 | /* | 367 | /* |
@@ -387,6 +389,8 @@ extern int usb_lock_device_for_reset(struct usb_device *udev, | |||
387 | 389 | ||
388 | /* USB port reset for device reinitialization */ | 390 | /* USB port reset for device reinitialization */ |
389 | extern int usb_reset_device(struct usb_device *dev); | 391 | extern int usb_reset_device(struct usb_device *dev); |
392 | extern int usb_reset_composite_device(struct usb_device *dev, | ||
393 | struct usb_interface *iface); | ||
390 | 394 | ||
391 | extern struct usb_device *usb_find_device(u16 vendor_id, u16 product_id); | 395 | extern struct usb_device *usb_find_device(u16 vendor_id, u16 product_id); |
392 | 396 | ||
@@ -555,6 +559,10 @@ struct usb_dynids { | |||
555 | * do (or don't) show up otherwise in the filesystem. | 559 | * do (or don't) show up otherwise in the filesystem. |
556 | * @suspend: Called when the device is going to be suspended by the system. | 560 | * @suspend: Called when the device is going to be suspended by the system. |
557 | * @resume: Called when the device is being resumed by the system. | 561 | * @resume: Called when the device is being resumed by the system. |
562 | * @pre_reset: Called by usb_reset_composite_device() when the device | ||
563 | * is about to be reset. | ||
564 | * @post_reset: Called by usb_reset_composite_device() after the device | ||
565 | * has been reset. | ||
558 | * @id_table: USB drivers use ID table to support hotplugging. | 566 | * @id_table: USB drivers use ID table to support hotplugging. |
559 | * Export this with MODULE_DEVICE_TABLE(usb,...). This must be set | 567 | * Export this with MODULE_DEVICE_TABLE(usb,...). This must be set |
560 | * or your driver's probe function will never get called. | 568 | * or your driver's probe function will never get called. |
@@ -593,6 +601,9 @@ struct usb_driver { | |||
593 | int (*suspend) (struct usb_interface *intf, pm_message_t message); | 601 | int (*suspend) (struct usb_interface *intf, pm_message_t message); |
594 | int (*resume) (struct usb_interface *intf); | 602 | int (*resume) (struct usb_interface *intf); |
595 | 603 | ||
604 | void (*pre_reset) (struct usb_interface *intf); | ||
605 | void (*post_reset) (struct usb_interface *intf); | ||
606 | |||
596 | const struct usb_device_id *id_table; | 607 | const struct usb_device_id *id_table; |
597 | 608 | ||
598 | struct usb_dynids dynids; | 609 | struct usb_dynids dynids; |
@@ -1009,6 +1020,8 @@ void usb_buffer_unmap_sg (struct usb_device *dev, unsigned pipe, | |||
1009 | extern int usb_control_msg(struct usb_device *dev, unsigned int pipe, | 1020 | extern int usb_control_msg(struct usb_device *dev, unsigned int pipe, |
1010 | __u8 request, __u8 requesttype, __u16 value, __u16 index, | 1021 | __u8 request, __u8 requesttype, __u16 value, __u16 index, |
1011 | void *data, __u16 size, int timeout); | 1022 | void *data, __u16 size, int timeout); |
1023 | extern int usb_interrupt_msg(struct usb_device *usb_dev, unsigned int pipe, | ||
1024 | void *data, int len, int *actual_length, int timeout); | ||
1012 | extern int usb_bulk_msg(struct usb_device *usb_dev, unsigned int pipe, | 1025 | extern int usb_bulk_msg(struct usb_device *usb_dev, unsigned int pipe, |
1013 | void *data, int len, int *actual_length, | 1026 | void *data, int len, int *actual_length, |
1014 | int timeout); | 1027 | int timeout); |
diff --git a/include/linux/usb_cdc.h b/include/linux/usb/cdc.h index ba617c372455..ba617c372455 100644 --- a/include/linux/usb_cdc.h +++ b/include/linux/usb/cdc.h | |||
diff --git a/include/linux/usb_input.h b/include/linux/usb/input.h index 716e0cc16043..716e0cc16043 100644 --- a/include/linux/usb_input.h +++ b/include/linux/usb/input.h | |||
diff --git a/include/linux/usb_isp116x.h b/include/linux/usb/isp116x.h index 436dd8a2b64a..436dd8a2b64a 100644 --- a/include/linux/usb_isp116x.h +++ b/include/linux/usb/isp116x.h | |||
diff --git a/include/linux/usb_sl811.h b/include/linux/usb/sl811.h index 4f2d012d7309..397ee3b3d7f3 100644 --- a/include/linux/usb_sl811.h +++ b/include/linux/usb/sl811.h | |||
@@ -14,13 +14,13 @@ struct sl811_platform_data { | |||
14 | u8 power; | 14 | u8 power; |
15 | 15 | ||
16 | /* sl811 relies on an external source of VBUS current */ | 16 | /* sl811 relies on an external source of VBUS current */ |
17 | void (*port_power)(struct device *dev, int is_on); | 17 | void (*port_power)(struct device *dev, int is_on); |
18 | 18 | ||
19 | /* pulse sl811 nRST (probably with a GPIO) */ | 19 | /* pulse sl811 nRST (probably with a GPIO) */ |
20 | void (*reset)(struct device *dev); | 20 | void (*reset)(struct device *dev); |
21 | 21 | ||
22 | // some boards need something like these: | 22 | // some boards need something like these: |
23 | // int (*check_overcurrent)(struct device *dev); | 23 | // int (*check_overcurrent)(struct device *dev); |
24 | // void (*clock_enable)(struct device *dev, int is_on); | 24 | // void (*clock_enable)(struct device *dev, int is_on); |
25 | }; | 25 | }; |
26 | 26 | ||
diff --git a/include/linux/usb_usual.h b/include/linux/usb_usual.h index b2d08984a9f7..608487a62c98 100644 --- a/include/linux/usb_usual.h +++ b/include/linux/usb_usual.h | |||
@@ -9,7 +9,6 @@ | |||
9 | #ifndef __LINUX_USB_USUAL_H | 9 | #ifndef __LINUX_USB_USUAL_H |
10 | #define __LINUX_USB_USUAL_H | 10 | #define __LINUX_USB_USUAL_H |
11 | 11 | ||
12 | #include <linux/config.h> | ||
13 | 12 | ||
14 | /* We should do this for cleanliness... But other usb_foo.h do not do this. */ | 13 | /* We should do this for cleanliness... But other usb_foo.h do not do this. */ |
15 | /* #include <linux/usb.h> */ | 14 | /* #include <linux/usb.h> */ |
diff --git a/include/linux/usbdevice_fs.h b/include/linux/usbdevice_fs.h index 8859f0b41543..7b7aadb69092 100644 --- a/include/linux/usbdevice_fs.h +++ b/include/linux/usbdevice_fs.h | |||
@@ -123,6 +123,7 @@ struct usbdevfs_hub_portinfo { | |||
123 | char port [127]; /* e.g. port 3 connects to device 27 */ | 123 | char port [127]; /* e.g. port 3 connects to device 27 */ |
124 | }; | 124 | }; |
125 | 125 | ||
126 | #ifdef __KERNEL__ | ||
126 | #ifdef CONFIG_COMPAT | 127 | #ifdef CONFIG_COMPAT |
127 | #include <linux/compat.h> | 128 | #include <linux/compat.h> |
128 | struct usbdevfs_urb32 { | 129 | struct usbdevfs_urb32 { |
@@ -147,6 +148,7 @@ struct usbdevfs_ioctl32 { | |||
147 | compat_caddr_t data; | 148 | compat_caddr_t data; |
148 | }; | 149 | }; |
149 | #endif | 150 | #endif |
151 | #endif /* __KERNEL__ */ | ||
150 | 152 | ||
151 | #define USBDEVFS_CONTROL _IOWR('U', 0, struct usbdevfs_ctrltransfer) | 153 | #define USBDEVFS_CONTROL _IOWR('U', 0, struct usbdevfs_ctrltransfer) |
152 | #define USBDEVFS_BULK _IOWR('U', 2, struct usbdevfs_bulktransfer) | 154 | #define USBDEVFS_BULK _IOWR('U', 2, struct usbdevfs_bulktransfer) |
diff --git a/include/linux/vt_buffer.h b/include/linux/vt_buffer.h index 1f7ba3629053..057db7d2f448 100644 --- a/include/linux/vt_buffer.h +++ b/include/linux/vt_buffer.h | |||
@@ -13,7 +13,6 @@ | |||
13 | #ifndef _LINUX_VT_BUFFER_H_ | 13 | #ifndef _LINUX_VT_BUFFER_H_ |
14 | #define _LINUX_VT_BUFFER_H_ | 14 | #define _LINUX_VT_BUFFER_H_ |
15 | 15 | ||
16 | #include <linux/config.h> | ||
17 | 16 | ||
18 | #if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_MDA_CONSOLE) | 17 | #if defined(CONFIG_VGA_CONSOLE) || defined(CONFIG_MDA_CONSOLE) |
19 | #include <asm/vga.h> | 18 | #include <asm/vga.h> |
diff --git a/include/linux/vt_kern.h b/include/linux/vt_kern.h index fab5aed8ca31..940d0261a545 100644 --- a/include/linux/vt_kern.h +++ b/include/linux/vt_kern.h | |||
@@ -6,7 +6,6 @@ | |||
6 | * with information needed by the vt package | 6 | * with information needed by the vt package |
7 | */ | 7 | */ |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <linux/vt.h> | 9 | #include <linux/vt.h> |
11 | #include <linux/kd.h> | 10 | #include <linux/kd.h> |
12 | #include <linux/tty.h> | 11 | #include <linux/tty.h> |
diff --git a/include/linux/wait.h b/include/linux/wait.h index d28518236b62..544e855c7c02 100644 --- a/include/linux/wait.h +++ b/include/linux/wait.h | |||
@@ -19,7 +19,6 @@ | |||
19 | 19 | ||
20 | #ifdef __KERNEL__ | 20 | #ifdef __KERNEL__ |
21 | 21 | ||
22 | #include <linux/config.h> | ||
23 | #include <linux/list.h> | 22 | #include <linux/list.h> |
24 | #include <linux/stddef.h> | 23 | #include <linux/stddef.h> |
25 | #include <linux/spinlock.h> | 24 | #include <linux/spinlock.h> |
diff --git a/include/linux/wanrouter.h b/include/linux/wanrouter.h index 1b6b76a4eb54..2cd05013edfc 100644 --- a/include/linux/wanrouter.h +++ b/include/linux/wanrouter.h | |||
@@ -44,8 +44,6 @@ | |||
44 | * Jan 02, 1997 Gene Kozin Initial version (based on wanpipe.h). | 44 | * Jan 02, 1997 Gene Kozin Initial version (based on wanpipe.h). |
45 | *****************************************************************************/ | 45 | *****************************************************************************/ |
46 | 46 | ||
47 | #include <linux/spinlock.h> /* Support for SMP Locking */ | ||
48 | |||
49 | #ifndef _ROUTER_H | 47 | #ifndef _ROUTER_H |
50 | #define _ROUTER_H | 48 | #define _ROUTER_H |
51 | 49 | ||
@@ -457,6 +455,8 @@ typedef struct wanif_conf | |||
457 | #include <linux/fs.h> /* support for device drivers */ | 455 | #include <linux/fs.h> /* support for device drivers */ |
458 | #include <linux/proc_fs.h> /* proc filesystem pragmatics */ | 456 | #include <linux/proc_fs.h> /* proc filesystem pragmatics */ |
459 | #include <linux/netdevice.h> /* support for network drivers */ | 457 | #include <linux/netdevice.h> /* support for network drivers */ |
458 | #include <linux/spinlock.h> /* Support for SMP Locking */ | ||
459 | |||
460 | /*---------------------------------------------------------------------------- | 460 | /*---------------------------------------------------------------------------- |
461 | * WAN device data space. | 461 | * WAN device data space. |
462 | */ | 462 | */ |
diff --git a/include/linux/xfrm.h b/include/linux/xfrm.h index 6b42cc474c01..46a15c7a1a13 100644 --- a/include/linux/xfrm.h +++ b/include/linux/xfrm.h | |||
@@ -118,6 +118,10 @@ enum | |||
118 | XFRM_SHARE_UNIQUE /* Use once */ | 118 | XFRM_SHARE_UNIQUE /* Use once */ |
119 | }; | 119 | }; |
120 | 120 | ||
121 | #define XFRM_MODE_TRANSPORT 0 | ||
122 | #define XFRM_MODE_TUNNEL 1 | ||
123 | #define XFRM_MODE_MAX 2 | ||
124 | |||
121 | /* Netlink configuration messages. */ | 125 | /* Netlink configuration messages. */ |
122 | enum { | 126 | enum { |
123 | XFRM_MSG_BASE = 0x10, | 127 | XFRM_MSG_BASE = 0x10, |
diff --git a/include/linux/zconf.h b/include/linux/zconf.h index f1cfd66b9554..0beb75e38caa 100644 --- a/include/linux/zconf.h +++ b/include/linux/zconf.h | |||
@@ -35,6 +35,18 @@ | |||
35 | # define MAX_WBITS 15 /* 32K LZ77 window */ | 35 | # define MAX_WBITS 15 /* 32K LZ77 window */ |
36 | #endif | 36 | #endif |
37 | 37 | ||
38 | /* default windowBits for decompression. MAX_WBITS is for compression only */ | ||
39 | #ifndef DEF_WBITS | ||
40 | # define DEF_WBITS MAX_WBITS | ||
41 | #endif | ||
42 | |||
43 | /* default memLevel */ | ||
44 | #if MAX_MEM_LEVEL >= 8 | ||
45 | # define DEF_MEM_LEVEL 8 | ||
46 | #else | ||
47 | # define DEF_MEM_LEVEL MAX_MEM_LEVEL | ||
48 | #endif | ||
49 | |||
38 | /* Type declarations */ | 50 | /* Type declarations */ |
39 | 51 | ||
40 | typedef unsigned char Byte; /* 8 bits */ | 52 | typedef unsigned char Byte; /* 8 bits */ |
diff --git a/include/linux/zlib.h b/include/linux/zlib.h index 4fa32f0d4df8..9e3192a7dc6f 100644 --- a/include/linux/zlib.h +++ b/include/linux/zlib.h | |||
@@ -1,7 +1,6 @@ | |||
1 | /* zlib.h -- interface of the 'zlib' general purpose compression library | 1 | /* zlib.h -- interface of the 'zlib' general purpose compression library |
2 | version 1.1.3, July 9th, 1998 | ||
3 | 2 | ||
4 | Copyright (C) 1995-1998 Jean-loup Gailly and Mark Adler | 3 | Copyright (C) 1995-2005 Jean-loup Gailly and Mark Adler |
5 | 4 | ||
6 | This software is provided 'as-is', without any express or implied | 5 | This software is provided 'as-is', without any express or implied |
7 | warranty. In no event will the authors be held liable for any damages | 6 | warranty. In no event will the authors be held liable for any damages |
@@ -24,7 +23,7 @@ | |||
24 | 23 | ||
25 | 24 | ||
26 | The data format used by the zlib library is described by RFCs (Request for | 25 | The data format used by the zlib library is described by RFCs (Request for |
27 | Comments) 1950 to 1952 in the files ftp://ds.internic.net/rfc/rfc1950.txt | 26 | Comments) 1950 to 1952 in the files http://www.ietf.org/rfc/rfc1950.txt |
28 | (zlib format), rfc1951.txt (deflate format) and rfc1952.txt (gzip format). | 27 | (zlib format), rfc1951.txt (deflate format) and rfc1952.txt (gzip format). |
29 | */ | 28 | */ |
30 | 29 | ||
@@ -33,7 +32,22 @@ | |||
33 | 32 | ||
34 | #include <linux/zconf.h> | 33 | #include <linux/zconf.h> |
35 | 34 | ||
36 | #define ZLIB_VERSION "1.1.3" | 35 | /* zlib deflate based on ZLIB_VERSION "1.1.3" */ |
36 | /* zlib inflate based on ZLIB_VERSION "1.2.3" */ | ||
37 | |||
38 | /* | ||
39 | This is a modified version of zlib for use inside the Linux kernel. | ||
40 | The main changes are to perform all memory allocation in advance. | ||
41 | |||
42 | Inflation Changes: | ||
43 | * Z_PACKET_FLUSH is added and used by ppp_deflate. Before returning | ||
44 | this checks there is no more input data available and the next data | ||
45 | is a STORED block. It also resets the mode to be read for the next | ||
46 | data, all as per PPP requirements. | ||
47 | * Addition of zlib_inflateIncomp which copies incompressible data into | ||
48 | the history window and adjusts the accoutning without calling | ||
49 | zlib_inflate itself to inflate the data. | ||
50 | */ | ||
37 | 51 | ||
38 | /* | 52 | /* |
39 | The 'zlib' compression library provides in-memory compression and | 53 | The 'zlib' compression library provides in-memory compression and |
@@ -48,9 +62,18 @@ | |||
48 | application must provide more input and/or consume the output | 62 | application must provide more input and/or consume the output |
49 | (providing more output space) before each call. | 63 | (providing more output space) before each call. |
50 | 64 | ||
65 | The compressed data format used by default by the in-memory functions is | ||
66 | the zlib format, which is a zlib wrapper documented in RFC 1950, wrapped | ||
67 | around a deflate stream, which is itself documented in RFC 1951. | ||
68 | |||
51 | The library also supports reading and writing files in gzip (.gz) format | 69 | The library also supports reading and writing files in gzip (.gz) format |
52 | with an interface similar to that of stdio. | 70 | with an interface similar to that of stdio. |
53 | 71 | ||
72 | The zlib format was designed to be compact and fast for use in memory | ||
73 | and on communications channels. The gzip format was designed for single- | ||
74 | file compression on file systems, has a larger header than zlib to maintain | ||
75 | directory information, and uses a different, slower check method than zlib. | ||
76 | |||
54 | The library does not install any signal handler. The decoder checks | 77 | The library does not install any signal handler. The decoder checks |
55 | the consistency of the compressed data, so the library should never | 78 | the consistency of the compressed data, so the library should never |
56 | crash even in case of corrupted input. | 79 | crash even in case of corrupted input. |
@@ -119,7 +142,8 @@ typedef z_stream *z_streamp; | |||
119 | #define Z_SYNC_FLUSH 3 | 142 | #define Z_SYNC_FLUSH 3 |
120 | #define Z_FULL_FLUSH 4 | 143 | #define Z_FULL_FLUSH 4 |
121 | #define Z_FINISH 5 | 144 | #define Z_FINISH 5 |
122 | /* Allowed flush values; see deflate() below for details */ | 145 | #define Z_BLOCK 6 /* Only for inflate at present */ |
146 | /* Allowed flush values; see deflate() and inflate() below for details */ | ||
123 | 147 | ||
124 | #define Z_OK 0 | 148 | #define Z_OK 0 |
125 | #define Z_STREAM_END 1 | 149 | #define Z_STREAM_END 1 |
@@ -155,13 +179,6 @@ typedef z_stream *z_streamp; | |||
155 | 179 | ||
156 | /* basic functions */ | 180 | /* basic functions */ |
157 | 181 | ||
158 | extern const char * zlib_zlibVersion (void); | ||
159 | /* The application can compare zlibVersion and ZLIB_VERSION for consistency. | ||
160 | If the first character differs, the library code actually used is | ||
161 | not compatible with the zlib.h header file used by the application. | ||
162 | This check is automatically made by deflateInit and inflateInit. | ||
163 | */ | ||
164 | |||
165 | extern int zlib_deflate_workspacesize (void); | 182 | extern int zlib_deflate_workspacesize (void); |
166 | /* | 183 | /* |
167 | Returns the number of bytes that needs to be allocated for a per- | 184 | Returns the number of bytes that needs to be allocated for a per- |
@@ -315,9 +332,9 @@ extern int zlib_inflateInit (z_streamp strm); | |||
315 | extern int zlib_inflate (z_streamp strm, int flush); | 332 | extern int zlib_inflate (z_streamp strm, int flush); |
316 | /* | 333 | /* |
317 | inflate decompresses as much data as possible, and stops when the input | 334 | inflate decompresses as much data as possible, and stops when the input |
318 | buffer becomes empty or the output buffer becomes full. It may some | 335 | buffer becomes empty or the output buffer becomes full. It may introduce |
319 | introduce some output latency (reading input without producing any output) | 336 | some output latency (reading input without producing any output) except when |
320 | except when forced to flush. | 337 | forced to flush. |
321 | 338 | ||
322 | The detailed semantics are as follows. inflate performs one or both of the | 339 | The detailed semantics are as follows. inflate performs one or both of the |
323 | following actions: | 340 | following actions: |
@@ -341,11 +358,26 @@ extern int zlib_inflate (z_streamp strm, int flush); | |||
341 | must be called again after making room in the output buffer because there | 358 | must be called again after making room in the output buffer because there |
342 | might be more output pending. | 359 | might be more output pending. |
343 | 360 | ||
344 | If the parameter flush is set to Z_SYNC_FLUSH, inflate flushes as much | 361 | The flush parameter of inflate() can be Z_NO_FLUSH, Z_SYNC_FLUSH, |
345 | output as possible to the output buffer. The flushing behavior of inflate is | 362 | Z_FINISH, or Z_BLOCK. Z_SYNC_FLUSH requests that inflate() flush as much |
346 | not specified for values of the flush parameter other than Z_SYNC_FLUSH | 363 | output as possible to the output buffer. Z_BLOCK requests that inflate() stop |
347 | and Z_FINISH, but the current implementation actually flushes as much output | 364 | if and when it gets to the next deflate block boundary. When decoding the |
348 | as possible anyway. | 365 | zlib or gzip format, this will cause inflate() to return immediately after |
366 | the header and before the first block. When doing a raw inflate, inflate() | ||
367 | will go ahead and process the first block, and will return when it gets to | ||
368 | the end of that block, or when it runs out of data. | ||
369 | |||
370 | The Z_BLOCK option assists in appending to or combining deflate streams. | ||
371 | Also to assist in this, on return inflate() will set strm->data_type to the | ||
372 | number of unused bits in the last byte taken from strm->next_in, plus 64 | ||
373 | if inflate() is currently decoding the last block in the deflate stream, | ||
374 | plus 128 if inflate() returned immediately after decoding an end-of-block | ||
375 | code or decoding the complete header up to just before the first byte of the | ||
376 | deflate stream. The end-of-block will not be indicated until all of the | ||
377 | uncompressed data from that block has been written to strm->next_out. The | ||
378 | number of unused bits may in general be greater than seven, except when | ||
379 | bit 7 of data_type is set, in which case the number of unused bits will be | ||
380 | less than eight. | ||
349 | 381 | ||
350 | inflate() should normally be called until it returns Z_STREAM_END or an | 382 | inflate() should normally be called until it returns Z_STREAM_END or an |
351 | error. However if all decompression is to be performed in a single step | 383 | error. However if all decompression is to be performed in a single step |
@@ -355,29 +387,44 @@ extern int zlib_inflate (z_streamp strm, int flush); | |||
355 | uncompressed data. (The size of the uncompressed data may have been saved | 387 | uncompressed data. (The size of the uncompressed data may have been saved |
356 | by the compressor for this purpose.) The next operation on this stream must | 388 | by the compressor for this purpose.) The next operation on this stream must |
357 | be inflateEnd to deallocate the decompression state. The use of Z_FINISH | 389 | be inflateEnd to deallocate the decompression state. The use of Z_FINISH |
358 | is never required, but can be used to inform inflate that a faster routine | 390 | is never required, but can be used to inform inflate that a faster approach |
359 | may be used for the single inflate() call. | 391 | may be used for the single inflate() call. |
360 | 392 | ||
361 | If a preset dictionary is needed at this point (see inflateSetDictionary | 393 | In this implementation, inflate() always flushes as much output as |
362 | below), inflate sets strm-adler to the adler32 checksum of the | 394 | possible to the output buffer, and always uses the faster approach on the |
363 | dictionary chosen by the compressor and returns Z_NEED_DICT; otherwise | 395 | first call. So the only effect of the flush parameter in this implementation |
364 | it sets strm->adler to the adler32 checksum of all output produced | 396 | is on the return value of inflate(), as noted below, or when it returns early |
365 | so far (that is, total_out bytes) and returns Z_OK, Z_STREAM_END or | 397 | because Z_BLOCK is used. |
366 | an error code as described below. At the end of the stream, inflate() | 398 | |
367 | checks that its computed adler32 checksum is equal to that saved by the | 399 | If a preset dictionary is needed after this call (see inflateSetDictionary |
368 | compressor and returns Z_STREAM_END only if the checksum is correct. | 400 | below), inflate sets strm->adler to the adler32 checksum of the dictionary |
401 | chosen by the compressor and returns Z_NEED_DICT; otherwise it sets | ||
402 | strm->adler to the adler32 checksum of all output produced so far (that is, | ||
403 | total_out bytes) and returns Z_OK, Z_STREAM_END or an error code as described | ||
404 | below. At the end of the stream, inflate() checks that its computed adler32 | ||
405 | checksum is equal to that saved by the compressor and returns Z_STREAM_END | ||
406 | only if the checksum is correct. | ||
407 | |||
408 | inflate() will decompress and check either zlib-wrapped or gzip-wrapped | ||
409 | deflate data. The header type is detected automatically. Any information | ||
410 | contained in the gzip header is not retained, so applications that need that | ||
411 | information should instead use raw inflate, see inflateInit2() below, or | ||
412 | inflateBack() and perform their own processing of the gzip header and | ||
413 | trailer. | ||
369 | 414 | ||
370 | inflate() returns Z_OK if some progress has been made (more input processed | 415 | inflate() returns Z_OK if some progress has been made (more input processed |
371 | or more output produced), Z_STREAM_END if the end of the compressed data has | 416 | or more output produced), Z_STREAM_END if the end of the compressed data has |
372 | been reached and all uncompressed output has been produced, Z_NEED_DICT if a | 417 | been reached and all uncompressed output has been produced, Z_NEED_DICT if a |
373 | preset dictionary is needed at this point, Z_DATA_ERROR if the input data was | 418 | preset dictionary is needed at this point, Z_DATA_ERROR if the input data was |
374 | corrupted (input stream not conforming to the zlib format or incorrect | 419 | corrupted (input stream not conforming to the zlib format or incorrect check |
375 | adler32 checksum), Z_STREAM_ERROR if the stream structure was inconsistent | 420 | value), Z_STREAM_ERROR if the stream structure was inconsistent (for example |
376 | (for example if next_in or next_out was NULL), Z_MEM_ERROR if there was not | 421 | if next_in or next_out was NULL), Z_MEM_ERROR if there was not enough memory, |
377 | enough memory, Z_BUF_ERROR if no progress is possible or if there was not | 422 | Z_BUF_ERROR if no progress is possible or if there was not enough room in the |
378 | enough room in the output buffer when Z_FINISH is used. In the Z_DATA_ERROR | 423 | output buffer when Z_FINISH is used. Note that Z_BUF_ERROR is not fatal, and |
379 | case, the application may then call inflateSync to look for a good | 424 | inflate() can be called again with more input and more output space to |
380 | compression block. | 425 | continue decompressing. If Z_DATA_ERROR is returned, the application may then |
426 | call inflateSync() to look for a good compression block if a partial recovery | ||
427 | of the data is desired. | ||
381 | */ | 428 | */ |
382 | 429 | ||
383 | 430 | ||
@@ -547,16 +594,36 @@ extern int inflateInit2 (z_streamp strm, int windowBits); | |||
547 | The windowBits parameter is the base two logarithm of the maximum window | 594 | The windowBits parameter is the base two logarithm of the maximum window |
548 | size (the size of the history buffer). It should be in the range 8..15 for | 595 | size (the size of the history buffer). It should be in the range 8..15 for |
549 | this version of the library. The default value is 15 if inflateInit is used | 596 | this version of the library. The default value is 15 if inflateInit is used |
550 | instead. If a compressed stream with a larger window size is given as | 597 | instead. windowBits must be greater than or equal to the windowBits value |
551 | input, inflate() will return with the error code Z_DATA_ERROR instead of | 598 | provided to deflateInit2() while compressing, or it must be equal to 15 if |
552 | trying to allocate a larger window. | 599 | deflateInit2() was not used. If a compressed stream with a larger window |
553 | 600 | size is given as input, inflate() will return with the error code | |
554 | inflateInit2 returns Z_OK if success, Z_MEM_ERROR if there was not enough | 601 | Z_DATA_ERROR instead of trying to allocate a larger window. |
555 | memory, Z_STREAM_ERROR if a parameter is invalid (such as a negative | 602 | |
556 | memLevel). msg is set to null if there is no error message. inflateInit2 | 603 | windowBits can also be -8..-15 for raw inflate. In this case, -windowBits |
557 | does not perform any decompression apart from reading the zlib header if | 604 | determines the window size. inflate() will then process raw deflate data, |
558 | present: this will be done by inflate(). (So next_in and avail_in may be | 605 | not looking for a zlib or gzip header, not generating a check value, and not |
559 | modified, but next_out and avail_out are unchanged.) | 606 | looking for any check values for comparison at the end of the stream. This |
607 | is for use with other formats that use the deflate compressed data format | ||
608 | such as zip. Those formats provide their own check values. If a custom | ||
609 | format is developed using the raw deflate format for compressed data, it is | ||
610 | recommended that a check value such as an adler32 or a crc32 be applied to | ||
611 | the uncompressed data as is done in the zlib, gzip, and zip formats. For | ||
612 | most applications, the zlib format should be used as is. Note that comments | ||
613 | above on the use in deflateInit2() applies to the magnitude of windowBits. | ||
614 | |||
615 | windowBits can also be greater than 15 for optional gzip decoding. Add | ||
616 | 32 to windowBits to enable zlib and gzip decoding with automatic header | ||
617 | detection, or add 16 to decode only the gzip format (the zlib format will | ||
618 | return a Z_DATA_ERROR). If a gzip stream is being decoded, strm->adler is | ||
619 | a crc32 instead of an adler32. | ||
620 | |||
621 | inflateInit2 returns Z_OK if success, Z_MEM_ERROR if there was not enough | ||
622 | memory, Z_STREAM_ERROR if a parameter is invalid (such as a null strm). msg | ||
623 | is set to null if there is no error message. inflateInit2 does not perform | ||
624 | any decompression apart from reading the zlib header if present: this will | ||
625 | be done by inflate(). (So next_in and avail_in may be modified, but next_out | ||
626 | and avail_out are unchanged.) | ||
560 | */ | 627 | */ |
561 | 628 | ||
562 | extern int zlib_inflateSetDictionary (z_streamp strm, | 629 | extern int zlib_inflateSetDictionary (z_streamp strm, |
@@ -564,16 +631,19 @@ extern int zlib_inflateSetDictionary (z_streamp strm, | |||
564 | uInt dictLength); | 631 | uInt dictLength); |
565 | /* | 632 | /* |
566 | Initializes the decompression dictionary from the given uncompressed byte | 633 | Initializes the decompression dictionary from the given uncompressed byte |
567 | sequence. This function must be called immediately after a call of inflate | 634 | sequence. This function must be called immediately after a call of inflate, |
568 | if this call returned Z_NEED_DICT. The dictionary chosen by the compressor | 635 | if that call returned Z_NEED_DICT. The dictionary chosen by the compressor |
569 | can be determined from the Adler32 value returned by this call of | 636 | can be determined from the adler32 value returned by that call of inflate. |
570 | inflate. The compressor and decompressor must use exactly the same | 637 | The compressor and decompressor must use exactly the same dictionary (see |
571 | dictionary (see deflateSetDictionary). | 638 | deflateSetDictionary). For raw inflate, this function can be called |
639 | immediately after inflateInit2() or inflateReset() and before any call of | ||
640 | inflate() to set the dictionary. The application must insure that the | ||
641 | dictionary that was used for compression is provided. | ||
572 | 642 | ||
573 | inflateSetDictionary returns Z_OK if success, Z_STREAM_ERROR if a | 643 | inflateSetDictionary returns Z_OK if success, Z_STREAM_ERROR if a |
574 | parameter is invalid (such as NULL dictionary) or the stream state is | 644 | parameter is invalid (such as NULL dictionary) or the stream state is |
575 | inconsistent, Z_DATA_ERROR if the given dictionary doesn't match the | 645 | inconsistent, Z_DATA_ERROR if the given dictionary doesn't match the |
576 | expected one (incorrect Adler32 value). inflateSetDictionary does not | 646 | expected one (incorrect adler32 value). inflateSetDictionary does not |
577 | perform any decompression: this will be done by subsequent calls of | 647 | perform any decompression: this will be done by subsequent calls of |
578 | inflate(). | 648 | inflate(). |
579 | */ | 649 | */ |
@@ -614,40 +684,19 @@ extern int zlib_inflateIncomp (z_stream *strm); | |||
614 | containing the data at next_in (except that the data is not output). | 684 | containing the data at next_in (except that the data is not output). |
615 | */ | 685 | */ |
616 | 686 | ||
617 | /* various hacks, don't look :) */ | ||
618 | |||
619 | /* deflateInit and inflateInit are macros to allow checking the zlib version | ||
620 | * and the compiler's view of z_stream: | ||
621 | */ | ||
622 | extern int zlib_deflateInit_ (z_streamp strm, int level, | ||
623 | const char *version, int stream_size); | ||
624 | extern int zlib_inflateInit_ (z_streamp strm, | ||
625 | const char *version, int stream_size); | ||
626 | extern int zlib_deflateInit2_ (z_streamp strm, int level, int method, | ||
627 | int windowBits, int memLevel, | ||
628 | int strategy, const char *version, | ||
629 | int stream_size); | ||
630 | extern int zlib_inflateInit2_ (z_streamp strm, int windowBits, | ||
631 | const char *version, int stream_size); | ||
632 | #define zlib_deflateInit(strm, level) \ | 687 | #define zlib_deflateInit(strm, level) \ |
633 | zlib_deflateInit_((strm), (level), ZLIB_VERSION, sizeof(z_stream)) | 688 | zlib_deflateInit2((strm), (level), Z_DEFLATED, MAX_WBITS, \ |
689 | DEF_MEM_LEVEL, Z_DEFAULT_STRATEGY) | ||
634 | #define zlib_inflateInit(strm) \ | 690 | #define zlib_inflateInit(strm) \ |
635 | zlib_inflateInit_((strm), ZLIB_VERSION, sizeof(z_stream)) | 691 | zlib_inflateInit2((strm), DEF_WBITS) |
636 | #define zlib_deflateInit2(strm, level, method, windowBits, memLevel, strategy) \ | ||
637 | zlib_deflateInit2_((strm),(level),(method),(windowBits),(memLevel),\ | ||
638 | (strategy), ZLIB_VERSION, sizeof(z_stream)) | ||
639 | #define zlib_inflateInit2(strm, windowBits) \ | ||
640 | zlib_inflateInit2_((strm), (windowBits), ZLIB_VERSION, sizeof(z_stream)) | ||
641 | 692 | ||
693 | extern int zlib_deflateInit2(z_streamp strm, int level, int method, | ||
694 | int windowBits, int memLevel, | ||
695 | int strategy); | ||
696 | extern int zlib_inflateInit2(z_streamp strm, int windowBits); | ||
642 | 697 | ||
643 | #if !defined(_Z_UTIL_H) && !defined(NO_DUMMY_DECL) | 698 | #if !defined(_Z_UTIL_H) && !defined(NO_DUMMY_DECL) |
644 | struct internal_state {int dummy;}; /* hack for buggy compilers */ | 699 | struct internal_state {int dummy;}; /* hack for buggy compilers */ |
645 | #endif | 700 | #endif |
646 | 701 | ||
647 | extern const char * zlib_zError (int err); | ||
648 | #if 0 | ||
649 | extern int zlib_inflateSyncPoint (z_streamp z); | ||
650 | #endif | ||
651 | extern const uLong * zlib_get_crc_table (void); | ||
652 | |||
653 | #endif /* _ZLIB_H */ | 702 | #endif /* _ZLIB_H */ |
diff --git a/include/linux/zutil.h b/include/linux/zutil.h index ee0c59cf2136..6adfa9a6ffe9 100644 --- a/include/linux/zutil.h +++ b/include/linux/zutil.h | |||
@@ -23,18 +23,6 @@ typedef unsigned long ulg; | |||
23 | 23 | ||
24 | /* common constants */ | 24 | /* common constants */ |
25 | 25 | ||
26 | #ifndef DEF_WBITS | ||
27 | # define DEF_WBITS MAX_WBITS | ||
28 | #endif | ||
29 | /* default windowBits for decompression. MAX_WBITS is for compression only */ | ||
30 | |||
31 | #if MAX_MEM_LEVEL >= 8 | ||
32 | # define DEF_MEM_LEVEL 8 | ||
33 | #else | ||
34 | # define DEF_MEM_LEVEL MAX_MEM_LEVEL | ||
35 | #endif | ||
36 | /* default memLevel */ | ||
37 | |||
38 | #define STORED_BLOCK 0 | 26 | #define STORED_BLOCK 0 |
39 | #define STATIC_TREES 1 | 27 | #define STATIC_TREES 1 |
40 | #define DYN_TREES 2 | 28 | #define DYN_TREES 2 |
diff --git a/include/mtd/mtd-abi.h b/include/mtd/mtd-abi.h index b5994ea56a5a..31329fce1ff5 100644 --- a/include/mtd/mtd-abi.h +++ b/include/mtd/mtd-abi.h | |||
@@ -7,8 +7,9 @@ | |||
7 | #ifndef __MTD_ABI_H__ | 7 | #ifndef __MTD_ABI_H__ |
8 | #define __MTD_ABI_H__ | 8 | #define __MTD_ABI_H__ |
9 | 9 | ||
10 | #ifndef __KERNEL__ /* Urgh. The whole point of splitting this out into | 10 | #ifndef __KERNEL__ |
11 | separate files was to avoid #ifdef __KERNEL__ */ | 11 | /* Urgh. The whole point of splitting this out into |
12 | separate files was to avoid #ifdef __KERNEL__ */ | ||
12 | #define __user | 13 | #define __user |
13 | #endif | 14 | #endif |
14 | 15 | ||
@@ -28,28 +29,17 @@ struct mtd_oob_buf { | |||
28 | #define MTD_ROM 2 | 29 | #define MTD_ROM 2 |
29 | #define MTD_NORFLASH 3 | 30 | #define MTD_NORFLASH 3 |
30 | #define MTD_NANDFLASH 4 | 31 | #define MTD_NANDFLASH 4 |
31 | #define MTD_PEROM 5 | ||
32 | #define MTD_DATAFLASH 6 | 32 | #define MTD_DATAFLASH 6 |
33 | #define MTD_OTHER 14 | 33 | |
34 | #define MTD_UNKNOWN 15 | 34 | #define MTD_WRITEABLE 0x400 /* Device is writeable */ |
35 | 35 | #define MTD_BIT_WRITEABLE 0x800 /* Single bits can be flipped */ | |
36 | #define MTD_CLEAR_BITS 1 // Bits can be cleared (flash) | 36 | #define MTD_NO_ERASE 0x1000 /* No erase necessary */ |
37 | #define MTD_SET_BITS 2 // Bits can be set | ||
38 | #define MTD_ERASEABLE 4 // Has an erase function | ||
39 | #define MTD_WRITEB_WRITEABLE 8 // Direct IO is possible | ||
40 | #define MTD_VOLATILE 16 // Set for RAMs | ||
41 | #define MTD_XIP 32 // eXecute-In-Place possible | ||
42 | #define MTD_OOB 64 // Out-of-band data (NAND flash) | ||
43 | #define MTD_ECC 128 // Device capable of automatic ECC | ||
44 | #define MTD_NO_VIRTBLOCKS 256 // Virtual blocks not allowed | ||
45 | #define MTD_PROGRAM_REGIONS 512 // Configurable Programming Regions | ||
46 | 37 | ||
47 | // Some common devices / combinations of capabilities | 38 | // Some common devices / combinations of capabilities |
48 | #define MTD_CAP_ROM 0 | 39 | #define MTD_CAP_ROM 0 |
49 | #define MTD_CAP_RAM (MTD_CLEAR_BITS|MTD_SET_BITS|MTD_WRITEB_WRITEABLE) | 40 | #define MTD_CAP_RAM (MTD_WRITEABLE | MTD_BIT_WRITEABLE | MTD_NO_ERASE) |
50 | #define MTD_CAP_NORFLASH (MTD_CLEAR_BITS|MTD_ERASEABLE) | 41 | #define MTD_CAP_NORFLASH (MTD_WRITEABLE | MTD_BIT_WRITEABLE) |
51 | #define MTD_CAP_NANDFLASH (MTD_CLEAR_BITS|MTD_ERASEABLE|MTD_OOB) | 42 | #define MTD_CAP_NANDFLASH (MTD_WRITEABLE) |
52 | #define MTD_WRITEABLE (MTD_CLEAR_BITS|MTD_SET_BITS) | ||
53 | 43 | ||
54 | 44 | ||
55 | // Types of automatic ECC/Checksum available | 45 | // Types of automatic ECC/Checksum available |
@@ -74,7 +64,7 @@ struct mtd_info_user { | |||
74 | uint32_t flags; | 64 | uint32_t flags; |
75 | uint32_t size; // Total size of the MTD | 65 | uint32_t size; // Total size of the MTD |
76 | uint32_t erasesize; | 66 | uint32_t erasesize; |
77 | uint32_t oobblock; // Size of OOB blocks (e.g. 512) | 67 | uint32_t writesize; |
78 | uint32_t oobsize; // Amount of OOB data per block (e.g. 16) | 68 | uint32_t oobsize; // Amount of OOB data per block (e.g. 16) |
79 | uint32_t ecctype; | 69 | uint32_t ecctype; |
80 | uint32_t eccsize; | 70 | uint32_t eccsize; |
@@ -94,12 +84,12 @@ struct otp_info { | |||
94 | uint32_t locked; | 84 | uint32_t locked; |
95 | }; | 85 | }; |
96 | 86 | ||
97 | #define MEMGETINFO _IOR('M', 1, struct mtd_info_user) | 87 | #define MEMGETINFO _IOR('M', 1, struct mtd_info_user) |
98 | #define MEMERASE _IOW('M', 2, struct erase_info_user) | 88 | #define MEMERASE _IOW('M', 2, struct erase_info_user) |
99 | #define MEMWRITEOOB _IOWR('M', 3, struct mtd_oob_buf) | 89 | #define MEMWRITEOOB _IOWR('M', 3, struct mtd_oob_buf) |
100 | #define MEMREADOOB _IOWR('M', 4, struct mtd_oob_buf) | 90 | #define MEMREADOOB _IOWR('M', 4, struct mtd_oob_buf) |
101 | #define MEMLOCK _IOW('M', 5, struct erase_info_user) | 91 | #define MEMLOCK _IOW('M', 5, struct erase_info_user) |
102 | #define MEMUNLOCK _IOW('M', 6, struct erase_info_user) | 92 | #define MEMUNLOCK _IOW('M', 6, struct erase_info_user) |
103 | #define MEMGETREGIONCOUNT _IOR('M', 7, int) | 93 | #define MEMGETREGIONCOUNT _IOR('M', 7, int) |
104 | #define MEMGETREGIONINFO _IOWR('M', 8, struct region_info_user) | 94 | #define MEMGETREGIONINFO _IOWR('M', 8, struct region_info_user) |
105 | #define MEMSETOOBSEL _IOW('M', 9, struct nand_oobinfo) | 95 | #define MEMSETOOBSEL _IOW('M', 9, struct nand_oobinfo) |
@@ -109,8 +99,15 @@ struct otp_info { | |||
109 | #define OTPSELECT _IOR('M', 13, int) | 99 | #define OTPSELECT _IOR('M', 13, int) |
110 | #define OTPGETREGIONCOUNT _IOW('M', 14, int) | 100 | #define OTPGETREGIONCOUNT _IOW('M', 14, int) |
111 | #define OTPGETREGIONINFO _IOW('M', 15, struct otp_info) | 101 | #define OTPGETREGIONINFO _IOW('M', 15, struct otp_info) |
112 | #define OTPLOCK _IOR('M', 16, struct otp_info) | 102 | #define OTPLOCK _IOR('M', 16, struct otp_info) |
103 | #define ECCGETLAYOUT _IOR('M', 17, struct nand_ecclayout) | ||
104 | #define ECCGETSTATS _IOR('M', 18, struct mtd_ecc_stats) | ||
105 | #define MTDFILEMODE _IO('M', 19) | ||
113 | 106 | ||
107 | /* | ||
108 | * Obsolete legacy interface. Keep it in order not to break userspace | ||
109 | * interfaces | ||
110 | */ | ||
114 | struct nand_oobinfo { | 111 | struct nand_oobinfo { |
115 | uint32_t useecc; | 112 | uint32_t useecc; |
116 | uint32_t eccbytes; | 113 | uint32_t eccbytes; |
@@ -118,4 +115,46 @@ struct nand_oobinfo { | |||
118 | uint32_t eccpos[32]; | 115 | uint32_t eccpos[32]; |
119 | }; | 116 | }; |
120 | 117 | ||
118 | struct nand_oobfree { | ||
119 | uint32_t offset; | ||
120 | uint32_t length; | ||
121 | }; | ||
122 | |||
123 | #define MTD_MAX_OOBFREE_ENTRIES 8 | ||
124 | /* | ||
125 | * ECC layout control structure. Exported to userspace for | ||
126 | * diagnosis and to allow creation of raw images | ||
127 | */ | ||
128 | struct nand_ecclayout { | ||
129 | uint32_t eccbytes; | ||
130 | uint32_t eccpos[64]; | ||
131 | uint32_t oobavail; | ||
132 | struct nand_oobfree oobfree[MTD_MAX_OOBFREE_ENTRIES]; | ||
133 | }; | ||
134 | |||
135 | /** | ||
136 | * struct mtd_ecc_stats - error correction status | ||
137 | * | ||
138 | * @corrected: number of corrected bits | ||
139 | * @failed: number of uncorrectable errors | ||
140 | * @badblocks: number of bad blocks in this partition | ||
141 | * @bbtblocks: number of blocks reserved for bad block tables | ||
142 | */ | ||
143 | struct mtd_ecc_stats { | ||
144 | uint32_t corrected; | ||
145 | uint32_t failed; | ||
146 | uint32_t badblocks; | ||
147 | uint32_t bbtblocks; | ||
148 | }; | ||
149 | |||
150 | /* | ||
151 | * Read/write file modes for access to MTD | ||
152 | */ | ||
153 | enum mtd_file_modes { | ||
154 | MTD_MODE_NORMAL = MTD_OTP_OFF, | ||
155 | MTD_MODE_OTP_FACTORY = MTD_OTP_FACTORY, | ||
156 | MTD_MODE_OTP_USER = MTD_OTP_USER, | ||
157 | MTD_MODE_RAW, | ||
158 | }; | ||
159 | |||
121 | #endif /* __MTD_ABI_H__ */ | 160 | #endif /* __MTD_ABI_H__ */ |
diff --git a/include/mtd/mtd-user.h b/include/mtd/mtd-user.h index 1c13fc7161fe..713f34d3e62e 100644 --- a/include/mtd/mtd-user.h +++ b/include/mtd/mtd-user.h | |||
@@ -16,5 +16,6 @@ typedef struct mtd_info_user mtd_info_t; | |||
16 | typedef struct erase_info_user erase_info_t; | 16 | typedef struct erase_info_user erase_info_t; |
17 | typedef struct region_info_user region_info_t; | 17 | typedef struct region_info_user region_info_t; |
18 | typedef struct nand_oobinfo nand_oobinfo_t; | 18 | typedef struct nand_oobinfo nand_oobinfo_t; |
19 | typedef struct nand_ecclayout nand_ecclayout_t; | ||
19 | 20 | ||
20 | #endif /* __MTD_USER_H__ */ | 21 | #endif /* __MTD_USER_H__ */ |
diff --git a/include/net/addrconf.h b/include/net/addrconf.h index 750e2508dd90..3d71251b3eca 100644 --- a/include/net/addrconf.h +++ b/include/net/addrconf.h | |||
@@ -45,7 +45,6 @@ struct prefix_info { | |||
45 | 45 | ||
46 | #ifdef __KERNEL__ | 46 | #ifdef __KERNEL__ |
47 | 47 | ||
48 | #include <linux/config.h> | ||
49 | #include <linux/netdevice.h> | 48 | #include <linux/netdevice.h> |
50 | #include <net/if_inet6.h> | 49 | #include <net/if_inet6.h> |
51 | #include <net/ipv6.h> | 50 | #include <net/ipv6.h> |
diff --git a/include/net/af_unix.h b/include/net/af_unix.h index 427dac94bc7e..795f81f9ec7f 100644 --- a/include/net/af_unix.h +++ b/include/net/af_unix.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __LINUX_NET_AFUNIX_H | 1 | #ifndef __LINUX_NET_AFUNIX_H |
2 | #define __LINUX_NET_AFUNIX_H | 2 | #define __LINUX_NET_AFUNIX_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/socket.h> | 4 | #include <linux/socket.h> |
6 | #include <linux/un.h> | 5 | #include <linux/un.h> |
7 | #include <linux/mutex.h> | 6 | #include <linux/mutex.h> |
diff --git a/include/net/ax25.h b/include/net/ax25.h index 5bd997487054..7cd528e9d668 100644 --- a/include/net/ax25.h +++ b/include/net/ax25.h | |||
@@ -6,7 +6,6 @@ | |||
6 | #ifndef _AX25_H | 6 | #ifndef _AX25_H |
7 | #define _AX25_H | 7 | #define _AX25_H |
8 | 8 | ||
9 | #include <linux/config.h> | ||
10 | #include <linux/ax25.h> | 9 | #include <linux/ax25.h> |
11 | #include <linux/spinlock.h> | 10 | #include <linux/spinlock.h> |
12 | #include <linux/timer.h> | 11 | #include <linux/timer.h> |
diff --git a/include/net/compat.h b/include/net/compat.h index e65cbedb6abc..9859b60280d5 100644 --- a/include/net/compat.h +++ b/include/net/compat.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef NET_COMPAT_H | 1 | #ifndef NET_COMPAT_H |
2 | #define NET_COMPAT_H | 2 | #define NET_COMPAT_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | 4 | ||
6 | struct sock; | 5 | struct sock; |
7 | 6 | ||
diff --git a/include/net/dst.h b/include/net/dst.h index 5161e89017f9..36d54fc248b0 100644 --- a/include/net/dst.h +++ b/include/net/dst.h | |||
@@ -8,7 +8,6 @@ | |||
8 | #ifndef _NET_DST_H | 8 | #ifndef _NET_DST_H |
9 | #define _NET_DST_H | 9 | #define _NET_DST_H |
10 | 10 | ||
11 | #include <linux/config.h> | ||
12 | #include <linux/netdevice.h> | 11 | #include <linux/netdevice.h> |
13 | #include <linux/rtnetlink.h> | 12 | #include <linux/rtnetlink.h> |
14 | #include <linux/rcupdate.h> | 13 | #include <linux/rcupdate.h> |
diff --git a/include/net/icmp.h b/include/net/icmp.h index e7c3f20fbafc..05f8ff7d9316 100644 --- a/include/net/icmp.h +++ b/include/net/icmp.h | |||
@@ -18,7 +18,6 @@ | |||
18 | #ifndef _ICMP_H | 18 | #ifndef _ICMP_H |
19 | #define _ICMP_H | 19 | #define _ICMP_H |
20 | 20 | ||
21 | #include <linux/config.h> | ||
22 | #include <linux/icmp.h> | 21 | #include <linux/icmp.h> |
23 | 22 | ||
24 | #include <net/inet_sock.h> | 23 | #include <net/inet_sock.h> |
diff --git a/include/net/ieee80211.h b/include/net/ieee80211.h index d5926bfb1fc9..d5147770ad47 100644 --- a/include/net/ieee80211.h +++ b/include/net/ieee80211.h | |||
@@ -29,7 +29,7 @@ | |||
29 | #include <linux/kernel.h> /* ARRAY_SIZE */ | 29 | #include <linux/kernel.h> /* ARRAY_SIZE */ |
30 | #include <linux/wireless.h> | 30 | #include <linux/wireless.h> |
31 | 31 | ||
32 | #define IEEE80211_VERSION "git-1.1.7" | 32 | #define IEEE80211_VERSION "git-1.1.13" |
33 | 33 | ||
34 | #define IEEE80211_DATA_LEN 2304 | 34 | #define IEEE80211_DATA_LEN 2304 |
35 | /* Maximum size for the MA-UNITDATA primitive, 802.11 standard section | 35 | /* Maximum size for the MA-UNITDATA primitive, 802.11 standard section |
@@ -104,6 +104,9 @@ | |||
104 | #define IEEE80211_SCTL_FRAG 0x000F | 104 | #define IEEE80211_SCTL_FRAG 0x000F |
105 | #define IEEE80211_SCTL_SEQ 0xFFF0 | 105 | #define IEEE80211_SCTL_SEQ 0xFFF0 |
106 | 106 | ||
107 | /* QOS control */ | ||
108 | #define IEEE80211_QCTL_TID 0x000F | ||
109 | |||
107 | /* debug macros */ | 110 | /* debug macros */ |
108 | 111 | ||
109 | #ifdef CONFIG_IEEE80211_DEBUG | 112 | #ifdef CONFIG_IEEE80211_DEBUG |
@@ -1075,6 +1078,7 @@ struct ieee80211_device { | |||
1075 | 1078 | ||
1076 | int (*handle_management) (struct net_device * dev, | 1079 | int (*handle_management) (struct net_device * dev, |
1077 | struct ieee80211_network * network, u16 type); | 1080 | struct ieee80211_network * network, u16 type); |
1081 | int (*is_qos_active) (struct net_device *dev, struct sk_buff *skb); | ||
1078 | 1082 | ||
1079 | /* Typical STA methods */ | 1083 | /* Typical STA methods */ |
1080 | int (*handle_auth) (struct net_device * dev, | 1084 | int (*handle_auth) (struct net_device * dev, |
@@ -1243,7 +1247,8 @@ extern int ieee80211_set_encryption(struct ieee80211_device *ieee); | |||
1243 | extern int ieee80211_xmit(struct sk_buff *skb, struct net_device *dev); | 1247 | extern int ieee80211_xmit(struct sk_buff *skb, struct net_device *dev); |
1244 | extern void ieee80211_txb_free(struct ieee80211_txb *); | 1248 | extern void ieee80211_txb_free(struct ieee80211_txb *); |
1245 | extern int ieee80211_tx_frame(struct ieee80211_device *ieee, | 1249 | extern int ieee80211_tx_frame(struct ieee80211_device *ieee, |
1246 | struct ieee80211_hdr *frame, int len); | 1250 | struct ieee80211_hdr *frame, int hdr_len, |
1251 | int total_len, int encrypt_mpdu); | ||
1247 | 1252 | ||
1248 | /* ieee80211_rx.c */ | 1253 | /* ieee80211_rx.c */ |
1249 | extern int ieee80211_rx(struct ieee80211_device *ieee, struct sk_buff *skb, | 1254 | extern int ieee80211_rx(struct ieee80211_device *ieee, struct sk_buff *skb, |
diff --git a/include/net/ieee80211softmac.h b/include/net/ieee80211softmac.h index 052ed596a4e4..7a483ab4022f 100644 --- a/include/net/ieee80211softmac.h +++ b/include/net/ieee80211softmac.h | |||
@@ -86,6 +86,9 @@ struct ieee80211softmac_assoc_info { | |||
86 | 86 | ||
87 | /* BSSID we're trying to associate to */ | 87 | /* BSSID we're trying to associate to */ |
88 | char bssid[ETH_ALEN]; | 88 | char bssid[ETH_ALEN]; |
89 | |||
90 | /* Rates supported by the network */ | ||
91 | struct ieee80211softmac_ratesinfo supported_rates; | ||
89 | 92 | ||
90 | /* some flags. | 93 | /* some flags. |
91 | * static_essid is valid if the essid is constant, | 94 | * static_essid is valid if the essid is constant, |
@@ -132,23 +135,26 @@ enum { | |||
132 | struct ieee80211softmac_txrates { | 135 | struct ieee80211softmac_txrates { |
133 | /* The Bit-Rate to be used for multicast frames. */ | 136 | /* The Bit-Rate to be used for multicast frames. */ |
134 | u8 mcast_rate; | 137 | u8 mcast_rate; |
135 | /* The Bit-Rate to be used for multicast fallback | 138 | |
136 | * (If the device supports fallback and hardware-retry) | 139 | /* The Bit-Rate to be used for multicast management frames. */ |
137 | */ | 140 | u8 mgt_mcast_rate; |
138 | u8 mcast_fallback; | 141 | |
139 | /* The Bit-Rate to be used for any other (normal) data packet. */ | 142 | /* The Bit-Rate to be used for any other (normal) data packet. */ |
140 | u8 default_rate; | 143 | u8 default_rate; |
141 | /* The Bit-Rate to be used for default fallback | 144 | /* The Bit-Rate to be used for default fallback |
142 | * (If the device supports fallback and hardware-retry) | 145 | * (If the device supports fallback and hardware-retry) |
143 | */ | 146 | */ |
144 | u8 default_fallback; | 147 | u8 default_fallback; |
148 | |||
149 | /* This is the rate that the user asked for */ | ||
150 | u8 user_rate; | ||
145 | }; | 151 | }; |
146 | 152 | ||
147 | /* Bits for txrates_change callback. */ | 153 | /* Bits for txrates_change callback. */ |
148 | #define IEEE80211SOFTMAC_TXRATECHG_DEFAULT (1 << 0) /* default_rate */ | 154 | #define IEEE80211SOFTMAC_TXRATECHG_DEFAULT (1 << 0) /* default_rate */ |
149 | #define IEEE80211SOFTMAC_TXRATECHG_DEFAULT_FBACK (1 << 1) /* default_fallback */ | 155 | #define IEEE80211SOFTMAC_TXRATECHG_DEFAULT_FBACK (1 << 1) /* default_fallback */ |
150 | #define IEEE80211SOFTMAC_TXRATECHG_MCAST (1 << 2) /* mcast_rate */ | 156 | #define IEEE80211SOFTMAC_TXRATECHG_MCAST (1 << 2) /* mcast_rate */ |
151 | #define IEEE80211SOFTMAC_TXRATECHG_MCAST_FBACK (1 << 3) /* mcast_fallback */ | 157 | #define IEEE80211SOFTMAC_TXRATECHG_MGT_MCAST (1 << 3) /* mgt_mcast_rate */ |
152 | 158 | ||
153 | struct ieee80211softmac_device { | 159 | struct ieee80211softmac_device { |
154 | /* 802.11 structure for data stuff */ | 160 | /* 802.11 structure for data stuff */ |
@@ -250,6 +256,28 @@ extern void ieee80211softmac_fragment_lost(struct net_device *dev, | |||
250 | * Note that the rates need to be sorted. */ | 256 | * Note that the rates need to be sorted. */ |
251 | extern void ieee80211softmac_set_rates(struct net_device *dev, u8 count, u8 *rates); | 257 | extern void ieee80211softmac_set_rates(struct net_device *dev, u8 count, u8 *rates); |
252 | 258 | ||
259 | /* Helper function which advises you the rate at which a frame should be | ||
260 | * transmitted at. */ | ||
261 | static inline u8 ieee80211softmac_suggest_txrate(struct ieee80211softmac_device *mac, | ||
262 | int is_multicast, | ||
263 | int is_mgt) | ||
264 | { | ||
265 | struct ieee80211softmac_txrates *txrates = &mac->txrates; | ||
266 | |||
267 | if (!mac->associated) | ||
268 | return txrates->mgt_mcast_rate; | ||
269 | |||
270 | /* We are associated, sending unicast frame */ | ||
271 | if (!is_multicast) | ||
272 | return txrates->default_rate; | ||
273 | |||
274 | /* We are associated, sending multicast frame */ | ||
275 | if (is_mgt) | ||
276 | return txrates->mgt_mcast_rate; | ||
277 | else | ||
278 | return txrates->mcast_rate; | ||
279 | } | ||
280 | |||
253 | /* Start the SoftMAC. Call this after you initialized the device | 281 | /* Start the SoftMAC. Call this after you initialized the device |
254 | * and it is ready to run. | 282 | * and it is ready to run. |
255 | */ | 283 | */ |
@@ -282,7 +310,7 @@ extern void ieee80211softmac_stop(struct net_device *dev); | |||
282 | * - context set to the context data you want passed | 310 | * - context set to the context data you want passed |
283 | * The return value is 0, or an error. | 311 | * The return value is 0, or an error. |
284 | */ | 312 | */ |
285 | typedef void (*notify_function_ptr)(struct net_device *dev, void *context); | 313 | typedef void (*notify_function_ptr)(struct net_device *dev, int event_type, void *context); |
286 | 314 | ||
287 | #define ieee80211softmac_notify(dev, event, fun, context) ieee80211softmac_notify_gfp(dev, event, fun, context, GFP_KERNEL); | 315 | #define ieee80211softmac_notify(dev, event, fun, context) ieee80211softmac_notify_gfp(dev, event, fun, context, GFP_KERNEL); |
288 | #define ieee80211softmac_notify_atomic(dev, event, fun, context) ieee80211softmac_notify_gfp(dev, event, fun, context, GFP_ATOMIC); | 316 | #define ieee80211softmac_notify_atomic(dev, event, fun, context) ieee80211softmac_notify_gfp(dev, event, fun, context, GFP_ATOMIC); |
diff --git a/include/net/ieee80211softmac_wx.h b/include/net/ieee80211softmac_wx.h index 3e0be453ecea..4ee3ad57283f 100644 --- a/include/net/ieee80211softmac_wx.h +++ b/include/net/ieee80211softmac_wx.h | |||
@@ -91,4 +91,9 @@ ieee80211softmac_wx_get_genie(struct net_device *dev, | |||
91 | struct iw_request_info *info, | 91 | struct iw_request_info *info, |
92 | union iwreq_data *wrqu, | 92 | union iwreq_data *wrqu, |
93 | char *extra); | 93 | char *extra); |
94 | extern int | ||
95 | ieee80211softmac_wx_set_mlme(struct net_device *dev, | ||
96 | struct iw_request_info *info, | ||
97 | union iwreq_data *wrqu, | ||
98 | char *extra); | ||
94 | #endif /* _IEEE80211SOFTMAC_WX */ | 99 | #endif /* _IEEE80211SOFTMAC_WX */ |
diff --git a/include/net/inet6_hashtables.h b/include/net/inet6_hashtables.h index 59f0c83d55a2..bc6a71dce984 100644 --- a/include/net/inet6_hashtables.h +++ b/include/net/inet6_hashtables.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #ifndef _INET6_HASHTABLES_H | 14 | #ifndef _INET6_HASHTABLES_H |
15 | #define _INET6_HASHTABLES_H | 15 | #define _INET6_HASHTABLES_H |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | 17 | ||
19 | #if defined(CONFIG_IPV6) || defined (CONFIG_IPV6_MODULE) | 18 | #if defined(CONFIG_IPV6) || defined (CONFIG_IPV6_MODULE) |
20 | #include <linux/in6.h> | 19 | #include <linux/in6.h> |
diff --git a/include/net/inet_hashtables.h b/include/net/inet_hashtables.h index 135d80fd658e..98e0bb3014fe 100644 --- a/include/net/inet_hashtables.h +++ b/include/net/inet_hashtables.h | |||
@@ -14,7 +14,6 @@ | |||
14 | #ifndef _INET_HASHTABLES_H | 14 | #ifndef _INET_HASHTABLES_H |
15 | #define _INET_HASHTABLES_H | 15 | #define _INET_HASHTABLES_H |
16 | 16 | ||
17 | #include <linux/config.h> | ||
18 | 17 | ||
19 | #include <linux/interrupt.h> | 18 | #include <linux/interrupt.h> |
20 | #include <linux/ipv6.h> | 19 | #include <linux/ipv6.h> |
diff --git a/include/net/inet_sock.h b/include/net/inet_sock.h index 883eb529ef8e..1f4a9a60d4cc 100644 --- a/include/net/inet_sock.h +++ b/include/net/inet_sock.h | |||
@@ -16,7 +16,6 @@ | |||
16 | #ifndef _INET_SOCK_H | 16 | #ifndef _INET_SOCK_H |
17 | #define _INET_SOCK_H | 17 | #define _INET_SOCK_H |
18 | 18 | ||
19 | #include <linux/config.h> | ||
20 | 19 | ||
21 | #include <linux/string.h> | 20 | #include <linux/string.h> |
22 | #include <linux/types.h> | 21 | #include <linux/types.h> |
diff --git a/include/net/inet_timewait_sock.h b/include/net/inet_timewait_sock.h index e837f98fdb50..600cb543550d 100644 --- a/include/net/inet_timewait_sock.h +++ b/include/net/inet_timewait_sock.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #ifndef _INET_TIMEWAIT_SOCK_ | 15 | #ifndef _INET_TIMEWAIT_SOCK_ |
16 | #define _INET_TIMEWAIT_SOCK_ | 16 | #define _INET_TIMEWAIT_SOCK_ |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | 18 | ||
20 | #include <linux/list.h> | 19 | #include <linux/list.h> |
21 | #include <linux/module.h> | 20 | #include <linux/module.h> |
diff --git a/include/net/ip.h b/include/net/ip.h index 3d2e5ca62a5a..98f908400771 100644 --- a/include/net/ip.h +++ b/include/net/ip.h | |||
@@ -22,7 +22,6 @@ | |||
22 | #ifndef _IP_H | 22 | #ifndef _IP_H |
23 | #define _IP_H | 23 | #define _IP_H |
24 | 24 | ||
25 | #include <linux/config.h> | ||
26 | #include <linux/types.h> | 25 | #include <linux/types.h> |
27 | #include <linux/ip.h> | 26 | #include <linux/ip.h> |
28 | #include <linux/in.h> | 27 | #include <linux/in.h> |
@@ -147,7 +146,6 @@ void ip_send_reply(struct sock *sk, struct sk_buff *skb, struct ip_reply_arg *ar | |||
147 | struct ipv4_config | 146 | struct ipv4_config |
148 | { | 147 | { |
149 | int log_martians; | 148 | int log_martians; |
150 | int autoconfig; | ||
151 | int no_pmtu_disc; | 149 | int no_pmtu_disc; |
152 | }; | 150 | }; |
153 | 151 | ||
diff --git a/include/net/ip_fib.h b/include/net/ip_fib.h index e000fa2cd5f6..a095d1dec7a4 100644 --- a/include/net/ip_fib.h +++ b/include/net/ip_fib.h | |||
@@ -16,7 +16,6 @@ | |||
16 | #ifndef _NET_IP_FIB_H | 16 | #ifndef _NET_IP_FIB_H |
17 | #define _NET_IP_FIB_H | 17 | #define _NET_IP_FIB_H |
18 | 18 | ||
19 | #include <linux/config.h> | ||
20 | #include <net/flow.h> | 19 | #include <net/flow.h> |
21 | #include <linux/seq_file.h> | 20 | #include <linux/seq_file.h> |
22 | 21 | ||
diff --git a/include/net/ip_mp_alg.h b/include/net/ip_mp_alg.h index 77225735cbd4..ac747b64734c 100644 --- a/include/net/ip_mp_alg.h +++ b/include/net/ip_mp_alg.h | |||
@@ -7,7 +7,6 @@ | |||
7 | #ifndef _NET_IP_MP_ALG_H | 7 | #ifndef _NET_IP_MP_ALG_H |
8 | #define _NET_IP_MP_ALG_H | 8 | #define _NET_IP_MP_ALG_H |
9 | 9 | ||
10 | #include <linux/config.h> | ||
11 | #include <linux/ip_mp_alg.h> | 10 | #include <linux/ip_mp_alg.h> |
12 | #include <net/flow.h> | 11 | #include <net/flow.h> |
13 | #include <net/route.h> | 12 | #include <net/route.h> |
diff --git a/include/net/ip_vs.h b/include/net/ip_vs.h index 7d2674fde19a..3b57b159b653 100644 --- a/include/net/ip_vs.h +++ b/include/net/ip_vs.h | |||
@@ -248,7 +248,6 @@ struct ip_vs_daemon_user { | |||
248 | 248 | ||
249 | #ifdef __KERNEL__ | 249 | #ifdef __KERNEL__ |
250 | 250 | ||
251 | #include <linux/config.h> | ||
252 | #include <linux/list.h> /* for struct list_head */ | 251 | #include <linux/list.h> /* for struct list_head */ |
253 | #include <linux/spinlock.h> /* for struct rwlock_t */ | 252 | #include <linux/spinlock.h> /* for struct rwlock_t */ |
254 | #include <asm/atomic.h> /* for struct atomic_t */ | 253 | #include <asm/atomic.h> /* for struct atomic_t */ |
diff --git a/include/net/ipv6.h b/include/net/ipv6.h index 4abedb8eaece..a8fdf7970b37 100644 --- a/include/net/ipv6.h +++ b/include/net/ipv6.h | |||
@@ -104,7 +104,6 @@ struct frag_hdr { | |||
104 | 104 | ||
105 | #ifdef __KERNEL__ | 105 | #ifdef __KERNEL__ |
106 | 106 | ||
107 | #include <linux/config.h> | ||
108 | #include <net/sock.h> | 107 | #include <net/sock.h> |
109 | 108 | ||
110 | /* sysctls */ | 109 | /* sysctls */ |
diff --git a/include/net/irda/irda.h b/include/net/irda/irda.h index 1880e46ecc9b..1cb0607fcbb9 100644 --- a/include/net/irda/irda.h +++ b/include/net/irda/irda.h | |||
@@ -26,7 +26,6 @@ | |||
26 | #ifndef NET_IRDA_H | 26 | #ifndef NET_IRDA_H |
27 | #define NET_IRDA_H | 27 | #define NET_IRDA_H |
28 | 28 | ||
29 | #include <linux/config.h> | ||
30 | #include <linux/skbuff.h> /* struct sk_buff */ | 29 | #include <linux/skbuff.h> /* struct sk_buff */ |
31 | #include <linux/kernel.h> | 30 | #include <linux/kernel.h> |
32 | #include <linux/if.h> /* sa_family_t in <linux/irda.h> */ | 31 | #include <linux/if.h> /* sa_family_t in <linux/irda.h> */ |
diff --git a/include/net/irda/irda_device.h b/include/net/irda/irda_device.h index 92c828029cd8..0575c59a5c96 100644 --- a/include/net/irda/irda_device.h +++ b/include/net/irda/irda_device.h | |||
@@ -39,7 +39,6 @@ | |||
39 | #ifndef IRDA_DEVICE_H | 39 | #ifndef IRDA_DEVICE_H |
40 | #define IRDA_DEVICE_H | 40 | #define IRDA_DEVICE_H |
41 | 41 | ||
42 | #include <linux/config.h> | ||
43 | #include <linux/tty.h> | 42 | #include <linux/tty.h> |
44 | #include <linux/netdevice.h> | 43 | #include <linux/netdevice.h> |
45 | #include <linux/spinlock.h> | 44 | #include <linux/spinlock.h> |
diff --git a/include/net/irda/irlap.h b/include/net/irda/irlap.h index 2127cae1e0a6..e77eb88d9226 100644 --- a/include/net/irda/irlap.h +++ b/include/net/irda/irlap.h | |||
@@ -27,7 +27,6 @@ | |||
27 | #ifndef IRLAP_H | 27 | #ifndef IRLAP_H |
28 | #define IRLAP_H | 28 | #define IRLAP_H |
29 | 29 | ||
30 | #include <linux/config.h> | ||
31 | #include <linux/types.h> | 30 | #include <linux/types.h> |
32 | #include <linux/skbuff.h> | 31 | #include <linux/skbuff.h> |
33 | #include <linux/netdevice.h> | 32 | #include <linux/netdevice.h> |
diff --git a/include/net/irda/irlmp.h b/include/net/irda/irlmp.h index c0c895d379ba..11ecfa58a648 100644 --- a/include/net/irda/irlmp.h +++ b/include/net/irda/irlmp.h | |||
@@ -29,7 +29,6 @@ | |||
29 | 29 | ||
30 | #include <asm/param.h> /* for HZ */ | 30 | #include <asm/param.h> /* for HZ */ |
31 | 31 | ||
32 | #include <linux/config.h> | ||
33 | #include <linux/types.h> | 32 | #include <linux/types.h> |
34 | 33 | ||
35 | #include <net/irda/irda.h> | 34 | #include <net/irda/irda.h> |
diff --git a/include/net/irda/irlmp_frame.h b/include/net/irda/irlmp_frame.h index eb3ad158c023..c463f8bca856 100644 --- a/include/net/irda/irlmp_frame.h +++ b/include/net/irda/irlmp_frame.h | |||
@@ -26,7 +26,6 @@ | |||
26 | #ifndef IRMLP_FRAME_H | 26 | #ifndef IRMLP_FRAME_H |
27 | #define IRMLP_FRAME_H | 27 | #define IRMLP_FRAME_H |
28 | 28 | ||
29 | #include <linux/config.h> | ||
30 | #include <linux/skbuff.h> | 29 | #include <linux/skbuff.h> |
31 | 30 | ||
32 | #include <net/irda/discovery.h> | 31 | #include <net/irda/discovery.h> |
diff --git a/include/net/irda/qos.h b/include/net/irda/qos.h index 9ae3d6bc2423..cc577dc0a0ef 100644 --- a/include/net/irda/qos.h +++ b/include/net/irda/qos.h | |||
@@ -31,7 +31,6 @@ | |||
31 | #ifndef IRDA_QOS_H | 31 | #ifndef IRDA_QOS_H |
32 | #define IRDA_QOS_H | 32 | #define IRDA_QOS_H |
33 | 33 | ||
34 | #include <linux/config.h> | ||
35 | #include <linux/skbuff.h> | 34 | #include <linux/skbuff.h> |
36 | 35 | ||
37 | #include <net/irda/parameters.h> | 36 | #include <net/irda/parameters.h> |
diff --git a/include/net/llc_if.h b/include/net/llc_if.h index 090eaa0d71f9..c608812a8e89 100644 --- a/include/net/llc_if.h +++ b/include/net/llc_if.h | |||
@@ -16,6 +16,7 @@ | |||
16 | #include <linux/if.h> | 16 | #include <linux/if.h> |
17 | #include <linux/if_arp.h> | 17 | #include <linux/if_arp.h> |
18 | #include <linux/llc.h> | 18 | #include <linux/llc.h> |
19 | #include <linux/etherdevice.h> | ||
19 | #include <net/llc.h> | 20 | #include <net/llc.h> |
20 | 21 | ||
21 | #define LLC_DATAUNIT_PRIM 1 | 22 | #define LLC_DATAUNIT_PRIM 1 |
@@ -61,8 +62,6 @@ | |||
61 | #define LLC_STATUS_CONFLICT 7 /* disconnect conn */ | 62 | #define LLC_STATUS_CONFLICT 7 /* disconnect conn */ |
62 | #define LLC_STATUS_RESET_DONE 8 /* */ | 63 | #define LLC_STATUS_RESET_DONE 8 /* */ |
63 | 64 | ||
64 | extern u8 llc_mac_null_var[IFHWADDRLEN]; | ||
65 | |||
66 | /** | 65 | /** |
67 | * llc_mac_null - determines if a address is a null mac address | 66 | * llc_mac_null - determines if a address is a null mac address |
68 | * @mac: Mac address to test if null. | 67 | * @mac: Mac address to test if null. |
@@ -70,16 +69,20 @@ extern u8 llc_mac_null_var[IFHWADDRLEN]; | |||
70 | * Determines if a given address is a null mac address. Returns 0 if the | 69 | * Determines if a given address is a null mac address. Returns 0 if the |
71 | * address is not a null mac, 1 if the address is a null mac. | 70 | * address is not a null mac, 1 if the address is a null mac. |
72 | */ | 71 | */ |
73 | static __inline__ int llc_mac_null(u8 *mac) | 72 | static inline int llc_mac_null(const u8 *mac) |
74 | { | 73 | { |
75 | return !memcmp(mac, llc_mac_null_var, IFHWADDRLEN); | 74 | return is_zero_ether_addr(mac); |
76 | } | 75 | } |
77 | 76 | ||
78 | static __inline__ int llc_addrany(struct llc_addr *addr) | 77 | static inline int llc_addrany(const struct llc_addr *addr) |
79 | { | 78 | { |
80 | return llc_mac_null(addr->mac) && !addr->lsap; | 79 | return llc_mac_null(addr->mac) && !addr->lsap; |
81 | } | 80 | } |
82 | 81 | ||
82 | static inline int llc_mac_multicast(const u8 *mac) | ||
83 | { | ||
84 | return is_multicast_ether_addr(mac); | ||
85 | } | ||
83 | /** | 86 | /** |
84 | * llc_mac_match - determines if two mac addresses are the same | 87 | * llc_mac_match - determines if two mac addresses are the same |
85 | * @mac1: First mac address to compare. | 88 | * @mac1: First mac address to compare. |
@@ -89,9 +92,9 @@ static __inline__ int llc_addrany(struct llc_addr *addr) | |||
89 | * is not a complete match up to len, 1 if a complete match up to len is | 92 | * is not a complete match up to len, 1 if a complete match up to len is |
90 | * found. | 93 | * found. |
91 | */ | 94 | */ |
92 | static __inline__ int llc_mac_match(u8 *mac1, u8 *mac2) | 95 | static inline int llc_mac_match(const u8 *mac1, const u8 *mac2) |
93 | { | 96 | { |
94 | return !memcmp(mac1, mac2, IFHWADDRLEN); | 97 | return !compare_ether_addr(mac1, mac2); |
95 | } | 98 | } |
96 | 99 | ||
97 | extern int llc_establish_connection(struct sock *sk, u8 *lmac, | 100 | extern int llc_establish_connection(struct sock *sk, u8 *lmac, |
diff --git a/include/net/ndisc.h b/include/net/ndisc.h index 91fa271a0064..d3915dabe6de 100644 --- a/include/net/ndisc.h +++ b/include/net/ndisc.h | |||
@@ -37,7 +37,6 @@ enum { | |||
37 | 37 | ||
38 | #ifdef __KERNEL__ | 38 | #ifdef __KERNEL__ |
39 | 39 | ||
40 | #include <linux/config.h> | ||
41 | #include <linux/compiler.h> | 40 | #include <linux/compiler.h> |
42 | #include <linux/icmpv6.h> | 41 | #include <linux/icmpv6.h> |
43 | #include <linux/in6.h> | 42 | #include <linux/in6.h> |
diff --git a/include/net/netdma.h b/include/net/netdma.h new file mode 100644 index 000000000000..19760eb131aa --- /dev/null +++ b/include/net/netdma.h | |||
@@ -0,0 +1,44 @@ | |||
1 | /* | ||
2 | * Copyright(c) 2004 - 2006 Intel Corporation. All rights reserved. | ||
3 | * | ||
4 | * This program is free software; you can redistribute it and/or modify it | ||
5 | * under the terms of the GNU General Public License as published by the Free | ||
6 | * Software Foundation; either version 2 of the License, or (at your option) | ||
7 | * any later version. | ||
8 | * | ||
9 | * This program is distributed in the hope that it will be useful, but WITHOUT | ||
10 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
11 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | ||
12 | * more details. | ||
13 | * | ||
14 | * You should have received a copy of the GNU General Public License along with | ||
15 | * this program; if not, write to the Free Software Foundation, Inc., 59 | ||
16 | * Temple Place - Suite 330, Boston, MA 02111-1307, USA. | ||
17 | * | ||
18 | * The full GNU General Public License is included in this distribution in the | ||
19 | * file called COPYING. | ||
20 | */ | ||
21 | #ifndef NETDMA_H | ||
22 | #define NETDMA_H | ||
23 | #include <linux/config.h> | ||
24 | #ifdef CONFIG_NET_DMA | ||
25 | #include <linux/dmaengine.h> | ||
26 | #include <linux/skbuff.h> | ||
27 | |||
28 | static inline struct dma_chan *get_softnet_dma(void) | ||
29 | { | ||
30 | struct dma_chan *chan; | ||
31 | rcu_read_lock(); | ||
32 | chan = rcu_dereference(__get_cpu_var(softnet_data.net_dma)); | ||
33 | if (chan) | ||
34 | dma_chan_get(chan); | ||
35 | rcu_read_unlock(); | ||
36 | return chan; | ||
37 | } | ||
38 | |||
39 | int dma_skb_copy_datagram_iovec(struct dma_chan* chan, | ||
40 | const struct sk_buff *skb, int offset, struct iovec *to, | ||
41 | size_t len, struct dma_pinned_list *pinned_list); | ||
42 | |||
43 | #endif /* CONFIG_NET_DMA */ | ||
44 | #endif /* NETDMA_H */ | ||
diff --git a/include/net/netfilter/nf_conntrack.h b/include/net/netfilter/nf_conntrack.h index 916013ca4a5c..1fbd8193d5f1 100644 --- a/include/net/netfilter/nf_conntrack.h +++ b/include/net/netfilter/nf_conntrack.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #include <linux/netfilter/nf_conntrack_common.h> | 15 | #include <linux/netfilter/nf_conntrack_common.h> |
16 | 16 | ||
17 | #ifdef __KERNEL__ | 17 | #ifdef __KERNEL__ |
18 | #include <linux/config.h> | ||
19 | #include <linux/bitops.h> | 18 | #include <linux/bitops.h> |
20 | #include <linux/compiler.h> | 19 | #include <linux/compiler.h> |
21 | #include <asm/atomic.h> | 20 | #include <asm/atomic.h> |
@@ -114,6 +113,10 @@ struct nf_conn | |||
114 | u_int32_t mark; | 113 | u_int32_t mark; |
115 | #endif | 114 | #endif |
116 | 115 | ||
116 | #ifdef CONFIG_NF_CONNTRACK_SECMARK | ||
117 | u_int32_t secmark; | ||
118 | #endif | ||
119 | |||
117 | /* Storage reserved for other modules: */ | 120 | /* Storage reserved for other modules: */ |
118 | union nf_conntrack_proto proto; | 121 | union nf_conntrack_proto proto; |
119 | 122 | ||
@@ -285,6 +288,7 @@ static inline int nf_ct_is_dying(struct nf_conn *ct) | |||
285 | } | 288 | } |
286 | 289 | ||
287 | extern unsigned int nf_conntrack_htable_size; | 290 | extern unsigned int nf_conntrack_htable_size; |
291 | extern int nf_conntrack_checksum; | ||
288 | 292 | ||
289 | #define NF_CT_STAT_INC(count) (__get_cpu_var(nf_conntrack_stat).count++) | 293 | #define NF_CT_STAT_INC(count) (__get_cpu_var(nf_conntrack_stat).count++) |
290 | 294 | ||
diff --git a/include/net/netfilter/nf_conntrack_compat.h b/include/net/netfilter/nf_conntrack_compat.h index 3cac19fb3648..f1b1482d7200 100644 --- a/include/net/netfilter/nf_conntrack_compat.h +++ b/include/net/netfilter/nf_conntrack_compat.h | |||
@@ -20,6 +20,19 @@ static inline u_int32_t *nf_ct_get_mark(const struct sk_buff *skb, | |||
20 | } | 20 | } |
21 | #endif /* CONFIG_IP_NF_CONNTRACK_MARK */ | 21 | #endif /* CONFIG_IP_NF_CONNTRACK_MARK */ |
22 | 22 | ||
23 | #ifdef CONFIG_IP_NF_CONNTRACK_SECMARK | ||
24 | static inline u_int32_t *nf_ct_get_secmark(const struct sk_buff *skb, | ||
25 | u_int32_t *ctinfo) | ||
26 | { | ||
27 | struct ip_conntrack *ct = ip_conntrack_get(skb, ctinfo); | ||
28 | |||
29 | if (ct) | ||
30 | return &ct->secmark; | ||
31 | else | ||
32 | return NULL; | ||
33 | } | ||
34 | #endif /* CONFIG_IP_NF_CONNTRACK_SECMARK */ | ||
35 | |||
23 | #ifdef CONFIG_IP_NF_CT_ACCT | 36 | #ifdef CONFIG_IP_NF_CT_ACCT |
24 | static inline struct ip_conntrack_counter * | 37 | static inline struct ip_conntrack_counter * |
25 | nf_ct_get_counters(const struct sk_buff *skb) | 38 | nf_ct_get_counters(const struct sk_buff *skb) |
@@ -70,6 +83,19 @@ static inline u_int32_t *nf_ct_get_mark(const struct sk_buff *skb, | |||
70 | } | 83 | } |
71 | #endif /* CONFIG_NF_CONNTRACK_MARK */ | 84 | #endif /* CONFIG_NF_CONNTRACK_MARK */ |
72 | 85 | ||
86 | #ifdef CONFIG_NF_CONNTRACK_SECMARK | ||
87 | static inline u_int32_t *nf_ct_get_secmark(const struct sk_buff *skb, | ||
88 | u_int32_t *ctinfo) | ||
89 | { | ||
90 | struct nf_conn *ct = nf_ct_get(skb, ctinfo); | ||
91 | |||
92 | if (ct) | ||
93 | return &ct->secmark; | ||
94 | else | ||
95 | return NULL; | ||
96 | } | ||
97 | #endif /* CONFIG_NF_CONNTRACK_MARK */ | ||
98 | |||
73 | #ifdef CONFIG_NF_CT_ACCT | 99 | #ifdef CONFIG_NF_CT_ACCT |
74 | static inline struct ip_conntrack_counter * | 100 | static inline struct ip_conntrack_counter * |
75 | nf_ct_get_counters(const struct sk_buff *skb) | 101 | nf_ct_get_counters(const struct sk_buff *skb) |
diff --git a/include/net/pkt_act.h b/include/net/pkt_act.h index b225d8472b7e..cf5e4d2e4c21 100644 --- a/include/net/pkt_act.h +++ b/include/net/pkt_act.h | |||
@@ -4,7 +4,6 @@ | |||
4 | #include <asm/uaccess.h> | 4 | #include <asm/uaccess.h> |
5 | #include <asm/system.h> | 5 | #include <asm/system.h> |
6 | #include <linux/bitops.h> | 6 | #include <linux/bitops.h> |
7 | #include <linux/config.h> | ||
8 | #include <linux/types.h> | 7 | #include <linux/types.h> |
9 | #include <linux/kernel.h> | 8 | #include <linux/kernel.h> |
10 | #include <linux/sched.h> | 9 | #include <linux/sched.h> |
diff --git a/include/net/pkt_sched.h b/include/net/pkt_sched.h index b94d1ad92c4d..75b5b9333fc7 100644 --- a/include/net/pkt_sched.h +++ b/include/net/pkt_sched.h | |||
@@ -218,12 +218,13 @@ extern struct qdisc_rate_table *qdisc_get_rtab(struct tc_ratespec *r, | |||
218 | struct rtattr *tab); | 218 | struct rtattr *tab); |
219 | extern void qdisc_put_rtab(struct qdisc_rate_table *tab); | 219 | extern void qdisc_put_rtab(struct qdisc_rate_table *tab); |
220 | 220 | ||
221 | extern int qdisc_restart(struct net_device *dev); | 221 | extern void __qdisc_run(struct net_device *dev); |
222 | 222 | ||
223 | static inline void qdisc_run(struct net_device *dev) | 223 | static inline void qdisc_run(struct net_device *dev) |
224 | { | 224 | { |
225 | while (!netif_queue_stopped(dev) && qdisc_restart(dev) < 0) | 225 | if (!netif_queue_stopped(dev) && |
226 | /* NOTHING */; | 226 | !test_and_set_bit(__LINK_STATE_QDISC_RUNNING, &dev->state)) |
227 | __qdisc_run(dev); | ||
227 | } | 228 | } |
228 | 229 | ||
229 | extern int tc_classify(struct sk_buff *skb, struct tcf_proto *tp, | 230 | extern int tc_classify(struct sk_buff *skb, struct tcf_proto *tp, |
diff --git a/include/net/protocol.h b/include/net/protocol.h index 6dc5970612d7..bcaee39bd2ff 100644 --- a/include/net/protocol.h +++ b/include/net/protocol.h | |||
@@ -24,7 +24,6 @@ | |||
24 | #ifndef _PROTOCOL_H | 24 | #ifndef _PROTOCOL_H |
25 | #define _PROTOCOL_H | 25 | #define _PROTOCOL_H |
26 | 26 | ||
27 | #include <linux/config.h> | ||
28 | #include <linux/in6.h> | 27 | #include <linux/in6.h> |
29 | #if defined(CONFIG_IPV6) || defined (CONFIG_IPV6_MODULE) | 28 | #if defined(CONFIG_IPV6) || defined (CONFIG_IPV6_MODULE) |
30 | #include <linux/ipv6.h> | 29 | #include <linux/ipv6.h> |
diff --git a/include/net/raw.h b/include/net/raw.h index e67b28a0248c..e4af59781949 100644 --- a/include/net/raw.h +++ b/include/net/raw.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #ifndef _RAW_H | 17 | #ifndef _RAW_H |
18 | #define _RAW_H | 18 | #define _RAW_H |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | 20 | ||
22 | #include <net/protocol.h> | 21 | #include <net/protocol.h> |
23 | 22 | ||
@@ -36,7 +35,7 @@ extern rwlock_t raw_v4_lock; | |||
36 | 35 | ||
37 | 36 | ||
38 | extern struct sock *__raw_v4_lookup(struct sock *sk, unsigned short num, | 37 | extern struct sock *__raw_v4_lookup(struct sock *sk, unsigned short num, |
39 | unsigned long raddr, unsigned long laddr, | 38 | __be32 raddr, __be32 laddr, |
40 | int dif); | 39 | int dif); |
41 | 40 | ||
42 | extern int raw_v4_input(struct sk_buff *skb, struct iphdr *iph, int hash); | 41 | extern int raw_v4_input(struct sk_buff *skb, struct iphdr *iph, int hash); |
diff --git a/include/net/red.h b/include/net/red.h index 2ed4358e3295..5ccdbb3d4722 100644 --- a/include/net/red.h +++ b/include/net/red.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __NET_SCHED_RED_H | 1 | #ifndef __NET_SCHED_RED_H |
2 | #define __NET_SCHED_RED_H | 2 | #define __NET_SCHED_RED_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/types.h> | 4 | #include <linux/types.h> |
6 | #include <net/pkt_sched.h> | 5 | #include <net/pkt_sched.h> |
7 | #include <net/inet_ecn.h> | 6 | #include <net/inet_ecn.h> |
diff --git a/include/net/route.h b/include/net/route.h index 98c915abdec8..c4a068692dcc 100644 --- a/include/net/route.h +++ b/include/net/route.h | |||
@@ -24,7 +24,6 @@ | |||
24 | #ifndef _ROUTE_H | 24 | #ifndef _ROUTE_H |
25 | #define _ROUTE_H | 25 | #define _ROUTE_H |
26 | 26 | ||
27 | #include <linux/config.h> | ||
28 | #include <net/dst.h> | 27 | #include <net/dst.h> |
29 | #include <net/inetpeer.h> | 28 | #include <net/inetpeer.h> |
30 | #include <net/flow.h> | 29 | #include <net/flow.h> |
diff --git a/include/net/sch_generic.h b/include/net/sch_generic.h index 7b6ec9986715..b0e9108a4e18 100644 --- a/include/net/sch_generic.h +++ b/include/net/sch_generic.h | |||
@@ -1,7 +1,6 @@ | |||
1 | #ifndef __NET_SCHED_GENERIC_H | 1 | #ifndef __NET_SCHED_GENERIC_H |
2 | #define __NET_SCHED_GENERIC_H | 2 | #define __NET_SCHED_GENERIC_H |
3 | 3 | ||
4 | #include <linux/config.h> | ||
5 | #include <linux/netdevice.h> | 4 | #include <linux/netdevice.h> |
6 | #include <linux/types.h> | 5 | #include <linux/types.h> |
7 | #include <linux/rcupdate.h> | 6 | #include <linux/rcupdate.h> |
diff --git a/include/net/sctp/sctp.h b/include/net/sctp/sctp.h index aa6033ca7cd8..a9663b49ea54 100644 --- a/include/net/sctp/sctp.h +++ b/include/net/sctp/sctp.h | |||
@@ -63,7 +63,6 @@ | |||
63 | */ | 63 | */ |
64 | 64 | ||
65 | 65 | ||
66 | #include <linux/config.h> | ||
67 | 66 | ||
68 | #ifdef TEST_FRAME | 67 | #ifdef TEST_FRAME |
69 | #undef CONFIG_PROC_FS | 68 | #undef CONFIG_PROC_FS |
diff --git a/include/net/sctp/structs.h b/include/net/sctp/structs.h index 7f4fea173fb1..5f69158c1006 100644 --- a/include/net/sctp/structs.h +++ b/include/net/sctp/structs.h | |||
@@ -555,7 +555,8 @@ struct sctp_af { | |||
555 | int (*to_addr_param) (const union sctp_addr *, | 555 | int (*to_addr_param) (const union sctp_addr *, |
556 | union sctp_addr_param *); | 556 | union sctp_addr_param *); |
557 | int (*addr_valid) (union sctp_addr *, | 557 | int (*addr_valid) (union sctp_addr *, |
558 | struct sctp_sock *); | 558 | struct sctp_sock *, |
559 | const struct sk_buff *); | ||
559 | sctp_scope_t (*scope) (union sctp_addr *); | 560 | sctp_scope_t (*scope) (union sctp_addr *); |
560 | void (*inaddr_any) (union sctp_addr *, unsigned short); | 561 | void (*inaddr_any) (union sctp_addr *, unsigned short); |
561 | int (*is_any) (const union sctp_addr *); | 562 | int (*is_any) (const union sctp_addr *); |
diff --git a/include/net/sock.h b/include/net/sock.h index c9fad6fb629b..d10dfecb6cbd 100644 --- a/include/net/sock.h +++ b/include/net/sock.h | |||
@@ -40,7 +40,6 @@ | |||
40 | #ifndef _SOCK_H | 40 | #ifndef _SOCK_H |
41 | #define _SOCK_H | 41 | #define _SOCK_H |
42 | 42 | ||
43 | #include <linux/config.h> | ||
44 | #include <linux/list.h> | 43 | #include <linux/list.h> |
45 | #include <linux/timer.h> | 44 | #include <linux/timer.h> |
46 | #include <linux/cache.h> | 45 | #include <linux/cache.h> |
@@ -132,6 +131,7 @@ struct sock_common { | |||
132 | * @sk_receive_queue: incoming packets | 131 | * @sk_receive_queue: incoming packets |
133 | * @sk_wmem_alloc: transmit queue bytes committed | 132 | * @sk_wmem_alloc: transmit queue bytes committed |
134 | * @sk_write_queue: Packet sending queue | 133 | * @sk_write_queue: Packet sending queue |
134 | * @sk_async_wait_queue: DMA copied packets | ||
135 | * @sk_omem_alloc: "o" is "option" or "other" | 135 | * @sk_omem_alloc: "o" is "option" or "other" |
136 | * @sk_wmem_queued: persistent queue size | 136 | * @sk_wmem_queued: persistent queue size |
137 | * @sk_forward_alloc: space allocated forward | 137 | * @sk_forward_alloc: space allocated forward |
@@ -205,6 +205,7 @@ struct sock { | |||
205 | atomic_t sk_omem_alloc; | 205 | atomic_t sk_omem_alloc; |
206 | struct sk_buff_head sk_receive_queue; | 206 | struct sk_buff_head sk_receive_queue; |
207 | struct sk_buff_head sk_write_queue; | 207 | struct sk_buff_head sk_write_queue; |
208 | struct sk_buff_head sk_async_wait_queue; | ||
208 | int sk_wmem_queued; | 209 | int sk_wmem_queued; |
209 | int sk_forward_alloc; | 210 | int sk_forward_alloc; |
210 | gfp_t sk_allocation; | 211 | gfp_t sk_allocation; |
@@ -871,10 +872,7 @@ static inline int sk_filter(struct sock *sk, struct sk_buff *skb, int needlock) | |||
871 | if (filter) { | 872 | if (filter) { |
872 | unsigned int pkt_len = sk_run_filter(skb, filter->insns, | 873 | unsigned int pkt_len = sk_run_filter(skb, filter->insns, |
873 | filter->len); | 874 | filter->len); |
874 | if (!pkt_len) | 875 | err = pkt_len ? pskb_trim(skb, pkt_len) : -EPERM; |
875 | err = -EPERM; | ||
876 | else | ||
877 | skb_trim(skb, pkt_len); | ||
878 | } | 876 | } |
879 | 877 | ||
880 | if (needlock) | 878 | if (needlock) |
@@ -1271,11 +1269,22 @@ sock_recv_timestamp(struct msghdr *msg, struct sock *sk, struct sk_buff *skb) | |||
1271 | * This routine must be called with interrupts disabled or with the socket | 1269 | * This routine must be called with interrupts disabled or with the socket |
1272 | * locked so that the sk_buff queue operation is ok. | 1270 | * locked so that the sk_buff queue operation is ok. |
1273 | */ | 1271 | */ |
1274 | static inline void sk_eat_skb(struct sock *sk, struct sk_buff *skb) | 1272 | #ifdef CONFIG_NET_DMA |
1273 | static inline void sk_eat_skb(struct sock *sk, struct sk_buff *skb, int copied_early) | ||
1274 | { | ||
1275 | __skb_unlink(skb, &sk->sk_receive_queue); | ||
1276 | if (!copied_early) | ||
1277 | __kfree_skb(skb); | ||
1278 | else | ||
1279 | __skb_queue_tail(&sk->sk_async_wait_queue, skb); | ||
1280 | } | ||
1281 | #else | ||
1282 | static inline void sk_eat_skb(struct sock *sk, struct sk_buff *skb, int copied_early) | ||
1275 | { | 1283 | { |
1276 | __skb_unlink(skb, &sk->sk_receive_queue); | 1284 | __skb_unlink(skb, &sk->sk_receive_queue); |
1277 | __kfree_skb(skb); | 1285 | __kfree_skb(skb); |
1278 | } | 1286 | } |
1287 | #endif | ||
1279 | 1288 | ||
1280 | extern void sock_enable_timestamp(struct sock *sk); | 1289 | extern void sock_enable_timestamp(struct sock *sk); |
1281 | extern int sock_get_timestamp(struct sock *, struct timeval __user *); | 1290 | extern int sock_get_timestamp(struct sock *, struct timeval __user *); |
diff --git a/include/net/tcp.h b/include/net/tcp.h index 3c989db8a7aa..5f4eb5c79689 100644 --- a/include/net/tcp.h +++ b/include/net/tcp.h | |||
@@ -21,13 +21,13 @@ | |||
21 | #define TCP_DEBUG 1 | 21 | #define TCP_DEBUG 1 |
22 | #define FASTRETRANS_DEBUG 1 | 22 | #define FASTRETRANS_DEBUG 1 |
23 | 23 | ||
24 | #include <linux/config.h> | ||
25 | #include <linux/list.h> | 24 | #include <linux/list.h> |
26 | #include <linux/tcp.h> | 25 | #include <linux/tcp.h> |
27 | #include <linux/slab.h> | 26 | #include <linux/slab.h> |
28 | #include <linux/cache.h> | 27 | #include <linux/cache.h> |
29 | #include <linux/percpu.h> | 28 | #include <linux/percpu.h> |
30 | #include <linux/skbuff.h> | 29 | #include <linux/skbuff.h> |
30 | #include <linux/dmaengine.h> | ||
31 | 31 | ||
32 | #include <net/inet_connection_sock.h> | 32 | #include <net/inet_connection_sock.h> |
33 | #include <net/inet_timewait_sock.h> | 33 | #include <net/inet_timewait_sock.h> |
@@ -218,6 +218,7 @@ extern int sysctl_tcp_adv_win_scale; | |||
218 | extern int sysctl_tcp_tw_reuse; | 218 | extern int sysctl_tcp_tw_reuse; |
219 | extern int sysctl_tcp_frto; | 219 | extern int sysctl_tcp_frto; |
220 | extern int sysctl_tcp_low_latency; | 220 | extern int sysctl_tcp_low_latency; |
221 | extern int sysctl_tcp_dma_copybreak; | ||
221 | extern int sysctl_tcp_nometrics_save; | 222 | extern int sysctl_tcp_nometrics_save; |
222 | extern int sysctl_tcp_moderate_rcvbuf; | 223 | extern int sysctl_tcp_moderate_rcvbuf; |
223 | extern int sysctl_tcp_tso_win_divisor; | 224 | extern int sysctl_tcp_tso_win_divisor; |
@@ -225,6 +226,7 @@ extern int sysctl_tcp_abc; | |||
225 | extern int sysctl_tcp_mtu_probing; | 226 | extern int sysctl_tcp_mtu_probing; |
226 | extern int sysctl_tcp_base_mss; | 227 | extern int sysctl_tcp_base_mss; |
227 | extern int sysctl_tcp_workaround_signed_windows; | 228 | extern int sysctl_tcp_workaround_signed_windows; |
229 | extern int sysctl_tcp_slow_start_after_idle; | ||
228 | 230 | ||
229 | extern atomic_t tcp_memory_allocated; | 231 | extern atomic_t tcp_memory_allocated; |
230 | extern atomic_t tcp_sockets_allocated; | 232 | extern atomic_t tcp_sockets_allocated; |
@@ -293,6 +295,8 @@ extern int tcp_rcv_established(struct sock *sk, | |||
293 | 295 | ||
294 | extern void tcp_rcv_space_adjust(struct sock *sk); | 296 | extern void tcp_rcv_space_adjust(struct sock *sk); |
295 | 297 | ||
298 | extern void tcp_cleanup_rbuf(struct sock *sk, int copied); | ||
299 | |||
296 | extern int tcp_twsk_unique(struct sock *sk, | 300 | extern int tcp_twsk_unique(struct sock *sk, |
297 | struct sock *sktw, void *twp); | 301 | struct sock *sktw, void *twp); |
298 | 302 | ||
@@ -628,7 +632,7 @@ struct tcp_congestion_ops { | |||
628 | /* return slow start threshold (required) */ | 632 | /* return slow start threshold (required) */ |
629 | u32 (*ssthresh)(struct sock *sk); | 633 | u32 (*ssthresh)(struct sock *sk); |
630 | /* lower bound for congestion window (optional) */ | 634 | /* lower bound for congestion window (optional) */ |
631 | u32 (*min_cwnd)(struct sock *sk); | 635 | u32 (*min_cwnd)(const struct sock *sk); |
632 | /* do new cwnd calculation (required) */ | 636 | /* do new cwnd calculation (required) */ |
633 | void (*cong_avoid)(struct sock *sk, u32 ack, | 637 | void (*cong_avoid)(struct sock *sk, u32 ack, |
634 | u32 rtt, u32 in_flight, int good_ack); | 638 | u32 rtt, u32 in_flight, int good_ack); |
@@ -663,7 +667,7 @@ extern struct tcp_congestion_ops tcp_init_congestion_ops; | |||
663 | extern u32 tcp_reno_ssthresh(struct sock *sk); | 667 | extern u32 tcp_reno_ssthresh(struct sock *sk); |
664 | extern void tcp_reno_cong_avoid(struct sock *sk, u32 ack, | 668 | extern void tcp_reno_cong_avoid(struct sock *sk, u32 ack, |
665 | u32 rtt, u32 in_flight, int flag); | 669 | u32 rtt, u32 in_flight, int flag); |
666 | extern u32 tcp_reno_min_cwnd(struct sock *sk); | 670 | extern u32 tcp_reno_min_cwnd(const struct sock *sk); |
667 | extern struct tcp_congestion_ops tcp_reno; | 671 | extern struct tcp_congestion_ops tcp_reno; |
668 | 672 | ||
669 | static inline void tcp_set_ca_state(struct sock *sk, const u8 ca_state) | 673 | static inline void tcp_set_ca_state(struct sock *sk, const u8 ca_state) |
@@ -817,6 +821,12 @@ static inline void tcp_prequeue_init(struct tcp_sock *tp) | |||
817 | tp->ucopy.len = 0; | 821 | tp->ucopy.len = 0; |
818 | tp->ucopy.memory = 0; | 822 | tp->ucopy.memory = 0; |
819 | skb_queue_head_init(&tp->ucopy.prequeue); | 823 | skb_queue_head_init(&tp->ucopy.prequeue); |
824 | #ifdef CONFIG_NET_DMA | ||
825 | tp->ucopy.dma_chan = NULL; | ||
826 | tp->ucopy.wakeup = 0; | ||
827 | tp->ucopy.pinned_list = NULL; | ||
828 | tp->ucopy.dma_cookie = 0; | ||
829 | #endif | ||
820 | } | 830 | } |
821 | 831 | ||
822 | /* Packet is added to VJ-style prequeue for processing in process | 832 | /* Packet is added to VJ-style prequeue for processing in process |
diff --git a/include/net/xfrm.h b/include/net/xfrm.h index afa508d92c93..9c5ee9f20b65 100644 --- a/include/net/xfrm.h +++ b/include/net/xfrm.h | |||
@@ -20,6 +20,8 @@ | |||
20 | #include <net/ip6_fib.h> | 20 | #include <net/ip6_fib.h> |
21 | 21 | ||
22 | #define XFRM_ALIGN8(len) (((len) + 7) & ~7) | 22 | #define XFRM_ALIGN8(len) (((len) + 7) & ~7) |
23 | #define MODULE_ALIAS_XFRM_MODE(family, encap) \ | ||
24 | MODULE_ALIAS("xfrm-mode-" __stringify(family) "-" __stringify(encap)) | ||
23 | 25 | ||
24 | extern struct sock *xfrm_nl; | 26 | extern struct sock *xfrm_nl; |
25 | extern u32 sysctl_xfrm_aevent_etime; | 27 | extern u32 sysctl_xfrm_aevent_etime; |
@@ -164,6 +166,7 @@ struct xfrm_state | |||
164 | /* Reference to data common to all the instances of this | 166 | /* Reference to data common to all the instances of this |
165 | * transformer. */ | 167 | * transformer. */ |
166 | struct xfrm_type *type; | 168 | struct xfrm_type *type; |
169 | struct xfrm_mode *mode; | ||
167 | 170 | ||
168 | /* Security context */ | 171 | /* Security context */ |
169 | struct xfrm_sec_ctx *security; | 172 | struct xfrm_sec_ctx *security; |
@@ -204,8 +207,8 @@ struct xfrm_type; | |||
204 | struct xfrm_dst; | 207 | struct xfrm_dst; |
205 | struct xfrm_policy_afinfo { | 208 | struct xfrm_policy_afinfo { |
206 | unsigned short family; | 209 | unsigned short family; |
207 | rwlock_t lock; | 210 | struct xfrm_type *type_map[IPPROTO_MAX]; |
208 | struct xfrm_type_map *type_map; | 211 | struct xfrm_mode *mode_map[XFRM_MODE_MAX]; |
209 | struct dst_ops *dst_ops; | 212 | struct dst_ops *dst_ops; |
210 | void (*garbage_collect)(void); | 213 | void (*garbage_collect)(void); |
211 | int (*dst_lookup)(struct xfrm_dst **dst, struct flowi *fl); | 214 | int (*dst_lookup)(struct xfrm_dst **dst, struct flowi *fl); |
@@ -232,7 +235,6 @@ extern int __xfrm_state_delete(struct xfrm_state *x); | |||
232 | 235 | ||
233 | struct xfrm_state_afinfo { | 236 | struct xfrm_state_afinfo { |
234 | unsigned short family; | 237 | unsigned short family; |
235 | rwlock_t lock; | ||
236 | struct list_head *state_bydst; | 238 | struct list_head *state_bydst; |
237 | struct list_head *state_byspi; | 239 | struct list_head *state_byspi; |
238 | int (*init_flags)(struct xfrm_state *x); | 240 | int (*init_flags)(struct xfrm_state *x); |
@@ -264,16 +266,24 @@ struct xfrm_type | |||
264 | u32 (*get_max_size)(struct xfrm_state *, int size); | 266 | u32 (*get_max_size)(struct xfrm_state *, int size); |
265 | }; | 267 | }; |
266 | 268 | ||
267 | struct xfrm_type_map { | ||
268 | rwlock_t lock; | ||
269 | struct xfrm_type *map[256]; | ||
270 | }; | ||
271 | |||
272 | extern int xfrm_register_type(struct xfrm_type *type, unsigned short family); | 269 | extern int xfrm_register_type(struct xfrm_type *type, unsigned short family); |
273 | extern int xfrm_unregister_type(struct xfrm_type *type, unsigned short family); | 270 | extern int xfrm_unregister_type(struct xfrm_type *type, unsigned short family); |
274 | extern struct xfrm_type *xfrm_get_type(u8 proto, unsigned short family); | 271 | extern struct xfrm_type *xfrm_get_type(u8 proto, unsigned short family); |
275 | extern void xfrm_put_type(struct xfrm_type *type); | 272 | extern void xfrm_put_type(struct xfrm_type *type); |
276 | 273 | ||
274 | struct xfrm_mode { | ||
275 | int (*input)(struct xfrm_state *x, struct sk_buff *skb); | ||
276 | int (*output)(struct sk_buff *skb); | ||
277 | |||
278 | struct module *owner; | ||
279 | unsigned int encap; | ||
280 | }; | ||
281 | |||
282 | extern int xfrm_register_mode(struct xfrm_mode *mode, int family); | ||
283 | extern int xfrm_unregister_mode(struct xfrm_mode *mode, int family); | ||
284 | extern struct xfrm_mode *xfrm_get_mode(unsigned int encap, int family); | ||
285 | extern void xfrm_put_mode(struct xfrm_mode *mode); | ||
286 | |||
277 | struct xfrm_tmpl | 287 | struct xfrm_tmpl |
278 | { | 288 | { |
279 | /* id in template is interpreted as: | 289 | /* id in template is interpreted as: |
diff --git a/include/pcmcia/ss.h b/include/pcmcia/ss.h index 5e0a01ab2216..ede639812f8a 100644 --- a/include/pcmcia/ss.h +++ b/include/pcmcia/ss.h | |||
@@ -15,7 +15,6 @@ | |||
15 | #ifndef _LINUX_SS_H | 15 | #ifndef _LINUX_SS_H |
16 | #define _LINUX_SS_H | 16 | #define _LINUX_SS_H |
17 | 17 | ||
18 | #include <linux/config.h> | ||
19 | #include <linux/device.h> | 18 | #include <linux/device.h> |
20 | #include <linux/sched.h> /* task_struct, completion */ | 19 | #include <linux/sched.h> /* task_struct, completion */ |
21 | #include <linux/mutex.h> | 20 | #include <linux/mutex.h> |
diff --git a/include/rdma/ib_addr.h b/include/rdma/ib_addr.h new file mode 100644 index 000000000000..fcb5ba87dcc5 --- /dev/null +++ b/include/rdma/ib_addr.h | |||
@@ -0,0 +1,114 @@ | |||
1 | /* | ||
2 | * Copyright (c) 2005 Voltaire Inc. All rights reserved. | ||
3 | * Copyright (c) 2005 Intel Corporation. All rights reserved. | ||
4 | * | ||
5 | * This Software is licensed under one of the following licenses: | ||
6 | * | ||
7 | * 1) under the terms of the "Common Public License 1.0" a copy of which is | ||
8 | * available from the Open Source Initiative, see | ||
9 | * http://www.opensource.org/licenses/cpl.php. | ||
10 | * | ||
11 | * 2) under the terms of the "The BSD License" a copy of which is | ||
12 | * available from the Open Source Initiative, see | ||
13 | * http://www.opensource.org/licenses/bsd-license.php. | ||
14 | * | ||
15 | * 3) under the terms of the "GNU General Public License (GPL) Version 2" a | ||
16 | * copy of which is available from the Open Source Initiative, see | ||
17 | * http://www.opensource.org/licenses/gpl-license.php. | ||
18 | * | ||
19 | * Licensee has the right to choose one of the above licenses. | ||
20 | * | ||
21 | * Redistributions of source code must retain the above copyright | ||
22 | * notice and one of the license notices. | ||
23 | * | ||
24 | * Redistributions in binary form must reproduce both the above copyright | ||
25 | * notice, one of the license notices in the documentation | ||
26 | * and/or other materials provided with the distribution. | ||
27 | * | ||
28 | */ | ||
29 | |||
30 | #if !defined(IB_ADDR_H) | ||
31 | #define IB_ADDR_H | ||
32 | |||
33 | #include <linux/in.h> | ||
34 | #include <linux/in6.h> | ||
35 | #include <linux/netdevice.h> | ||
36 | #include <linux/socket.h> | ||
37 | #include <rdma/ib_verbs.h> | ||
38 | |||
39 | struct rdma_dev_addr { | ||
40 | unsigned char src_dev_addr[MAX_ADDR_LEN]; | ||
41 | unsigned char dst_dev_addr[MAX_ADDR_LEN]; | ||
42 | unsigned char broadcast[MAX_ADDR_LEN]; | ||
43 | enum ib_node_type dev_type; | ||
44 | }; | ||
45 | |||
46 | /** | ||
47 | * rdma_translate_ip - Translate a local IP address to an RDMA hardware | ||
48 | * address. | ||
49 | */ | ||
50 | int rdma_translate_ip(struct sockaddr *addr, struct rdma_dev_addr *dev_addr); | ||
51 | |||
52 | /** | ||
53 | * rdma_resolve_ip - Resolve source and destination IP addresses to | ||
54 | * RDMA hardware addresses. | ||
55 | * @src_addr: An optional source address to use in the resolution. If a | ||
56 | * source address is not provided, a usable address will be returned via | ||
57 | * the callback. | ||
58 | * @dst_addr: The destination address to resolve. | ||
59 | * @addr: A reference to a data location that will receive the resolved | ||
60 | * addresses. The data location must remain valid until the callback has | ||
61 | * been invoked. | ||
62 | * @timeout_ms: Amount of time to wait for the address resolution to complete. | ||
63 | * @callback: Call invoked once address resolution has completed, timed out, | ||
64 | * or been canceled. A status of 0 indicates success. | ||
65 | * @context: User-specified context associated with the call. | ||
66 | */ | ||
67 | int rdma_resolve_ip(struct sockaddr *src_addr, struct sockaddr *dst_addr, | ||
68 | struct rdma_dev_addr *addr, int timeout_ms, | ||
69 | void (*callback)(int status, struct sockaddr *src_addr, | ||
70 | struct rdma_dev_addr *addr, void *context), | ||
71 | void *context); | ||
72 | |||
73 | void rdma_addr_cancel(struct rdma_dev_addr *addr); | ||
74 | |||
75 | static inline int ip_addr_size(struct sockaddr *addr) | ||
76 | { | ||
77 | return addr->sa_family == AF_INET6 ? | ||
78 | sizeof(struct sockaddr_in6) : sizeof(struct sockaddr_in); | ||
79 | } | ||
80 | |||
81 | static inline u16 ib_addr_get_pkey(struct rdma_dev_addr *dev_addr) | ||
82 | { | ||
83 | return ((u16)dev_addr->broadcast[8] << 8) | (u16)dev_addr->broadcast[9]; | ||
84 | } | ||
85 | |||
86 | static inline void ib_addr_set_pkey(struct rdma_dev_addr *dev_addr, u16 pkey) | ||
87 | { | ||
88 | dev_addr->broadcast[8] = pkey >> 8; | ||
89 | dev_addr->broadcast[9] = (unsigned char) pkey; | ||
90 | } | ||
91 | |||
92 | static inline union ib_gid *ib_addr_get_sgid(struct rdma_dev_addr *dev_addr) | ||
93 | { | ||
94 | return (union ib_gid *) (dev_addr->src_dev_addr + 4); | ||
95 | } | ||
96 | |||
97 | static inline void ib_addr_set_sgid(struct rdma_dev_addr *dev_addr, | ||
98 | union ib_gid *gid) | ||
99 | { | ||
100 | memcpy(dev_addr->src_dev_addr + 4, gid, sizeof *gid); | ||
101 | } | ||
102 | |||
103 | static inline union ib_gid *ib_addr_get_dgid(struct rdma_dev_addr *dev_addr) | ||
104 | { | ||
105 | return (union ib_gid *) (dev_addr->dst_dev_addr + 4); | ||
106 | } | ||
107 | |||
108 | static inline void ib_addr_set_dgid(struct rdma_dev_addr *dev_addr, | ||
109 | union ib_gid *gid) | ||
110 | { | ||
111 | memcpy(dev_addr->dst_dev_addr + 4, gid, sizeof *gid); | ||
112 | } | ||
113 | |||
114 | #endif /* IB_ADDR_H */ | ||
diff --git a/include/rdma/ib_cache.h b/include/rdma/ib_cache.h index 5bf9834f7dca..f179d233ffc3 100644 --- a/include/rdma/ib_cache.h +++ b/include/rdma/ib_cache.h | |||
@@ -102,4 +102,17 @@ int ib_find_cached_pkey(struct ib_device *device, | |||
102 | u16 pkey, | 102 | u16 pkey, |
103 | u16 *index); | 103 | u16 *index); |
104 | 104 | ||
105 | /** | ||
106 | * ib_get_cached_lmc - Returns a cached lmc table entry | ||
107 | * @device: The device to query. | ||
108 | * @port_num: The port number of the device to query. | ||
109 | * @lmc: The lmc value for the specified port for that device. | ||
110 | * | ||
111 | * ib_get_cached_lmc() fetches the specified lmc table entry stored in | ||
112 | * the local software cache. | ||
113 | */ | ||
114 | int ib_get_cached_lmc(struct ib_device *device, | ||
115 | u8 port_num, | ||
116 | u8 *lmc); | ||
117 | |||
105 | #endif /* _IB_CACHE_H */ | 118 | #endif /* _IB_CACHE_H */ |
diff --git a/include/rdma/ib_cm.h b/include/rdma/ib_cm.h index 0a9fcd59eb43..c9b4738be9d6 100644 --- a/include/rdma/ib_cm.h +++ b/include/rdma/ib_cm.h | |||
@@ -32,7 +32,7 @@ | |||
32 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | 32 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE |
33 | * SOFTWARE. | 33 | * SOFTWARE. |
34 | * | 34 | * |
35 | * $Id: ib_cm.h 2730 2005-06-28 16:43:03Z sean.hefty $ | 35 | * $Id: ib_cm.h 4311 2005-12-05 18:42:01Z sean.hefty $ |
36 | */ | 36 | */ |
37 | #if !defined(IB_CM_H) | 37 | #if !defined(IB_CM_H) |
38 | #define IB_CM_H | 38 | #define IB_CM_H |
@@ -102,7 +102,8 @@ enum ib_cm_data_size { | |||
102 | IB_CM_APR_INFO_LENGTH = 72, | 102 | IB_CM_APR_INFO_LENGTH = 72, |
103 | IB_CM_SIDR_REQ_PRIVATE_DATA_SIZE = 216, | 103 | IB_CM_SIDR_REQ_PRIVATE_DATA_SIZE = 216, |
104 | IB_CM_SIDR_REP_PRIVATE_DATA_SIZE = 136, | 104 | IB_CM_SIDR_REP_PRIVATE_DATA_SIZE = 136, |
105 | IB_CM_SIDR_REP_INFO_LENGTH = 72 | 105 | IB_CM_SIDR_REP_INFO_LENGTH = 72, |
106 | IB_CM_COMPARE_SIZE = 64 | ||
106 | }; | 107 | }; |
107 | 108 | ||
108 | struct ib_cm_id; | 109 | struct ib_cm_id; |
@@ -238,7 +239,6 @@ struct ib_cm_sidr_rep_event_param { | |||
238 | u32 qpn; | 239 | u32 qpn; |
239 | void *info; | 240 | void *info; |
240 | u8 info_len; | 241 | u8 info_len; |
241 | |||
242 | }; | 242 | }; |
243 | 243 | ||
244 | struct ib_cm_event { | 244 | struct ib_cm_event { |
@@ -317,6 +317,15 @@ void ib_destroy_cm_id(struct ib_cm_id *cm_id); | |||
317 | 317 | ||
318 | #define IB_SERVICE_ID_AGN_MASK __constant_cpu_to_be64(0xFF00000000000000ULL) | 318 | #define IB_SERVICE_ID_AGN_MASK __constant_cpu_to_be64(0xFF00000000000000ULL) |
319 | #define IB_CM_ASSIGN_SERVICE_ID __constant_cpu_to_be64(0x0200000000000000ULL) | 319 | #define IB_CM_ASSIGN_SERVICE_ID __constant_cpu_to_be64(0x0200000000000000ULL) |
320 | #define IB_CMA_SERVICE_ID __constant_cpu_to_be64(0x0000000001000000ULL) | ||
321 | #define IB_CMA_SERVICE_ID_MASK __constant_cpu_to_be64(0xFFFFFFFFFF000000ULL) | ||
322 | #define IB_SDP_SERVICE_ID __constant_cpu_to_be64(0x0000000000010000ULL) | ||
323 | #define IB_SDP_SERVICE_ID_MASK __constant_cpu_to_be64(0xFFFFFFFFFFFF0000ULL) | ||
324 | |||
325 | struct ib_cm_compare_data { | ||
326 | u8 data[IB_CM_COMPARE_SIZE]; | ||
327 | u8 mask[IB_CM_COMPARE_SIZE]; | ||
328 | }; | ||
320 | 329 | ||
321 | /** | 330 | /** |
322 | * ib_cm_listen - Initiates listening on the specified service ID for | 331 | * ib_cm_listen - Initiates listening on the specified service ID for |
@@ -330,10 +339,12 @@ void ib_destroy_cm_id(struct ib_cm_id *cm_id); | |||
330 | * range of service IDs. If set to 0, the service ID is matched | 339 | * range of service IDs. If set to 0, the service ID is matched |
331 | * exactly. This parameter is ignored if %service_id is set to | 340 | * exactly. This parameter is ignored if %service_id is set to |
332 | * IB_CM_ASSIGN_SERVICE_ID. | 341 | * IB_CM_ASSIGN_SERVICE_ID. |
342 | * @compare_data: This parameter is optional. It specifies data that must | ||
343 | * appear in the private data of a connection request for the specified | ||
344 | * listen request. | ||
333 | */ | 345 | */ |
334 | int ib_cm_listen(struct ib_cm_id *cm_id, | 346 | int ib_cm_listen(struct ib_cm_id *cm_id, __be64 service_id, __be64 service_mask, |
335 | __be64 service_id, | 347 | struct ib_cm_compare_data *compare_data); |
336 | __be64 service_mask); | ||
337 | 348 | ||
338 | struct ib_cm_req_param { | 349 | struct ib_cm_req_param { |
339 | struct ib_sa_path_rec *primary_path; | 350 | struct ib_sa_path_rec *primary_path; |
@@ -535,7 +546,6 @@ struct ib_cm_sidr_req_param { | |||
535 | const void *private_data; | 546 | const void *private_data; |
536 | u8 private_data_len; | 547 | u8 private_data_len; |
537 | u8 max_cm_retries; | 548 | u8 max_cm_retries; |
538 | u16 pkey; | ||
539 | }; | 549 | }; |
540 | 550 | ||
541 | /** | 551 | /** |
@@ -559,7 +569,7 @@ struct ib_cm_sidr_rep_param { | |||
559 | }; | 569 | }; |
560 | 570 | ||
561 | /** | 571 | /** |
562 | * ib_send_cm_sidr_rep - Sends a service ID resolution request to the | 572 | * ib_send_cm_sidr_rep - Sends a service ID resolution reply to the |
563 | * remote node. | 573 | * remote node. |
564 | * @cm_id: Communication identifier associated with the received service ID | 574 | * @cm_id: Communication identifier associated with the received service ID |
565 | * resolution request. | 575 | * resolution request. |
diff --git a/include/rdma/ib_marshall.h b/include/rdma/ib_marshall.h new file mode 100644 index 000000000000..66bf4d7d0dfb --- /dev/null +++ b/include/rdma/ib_marshall.h | |||
@@ -0,0 +1,50 @@ | |||
1 | /* | ||
2 | * Copyright (c) 2005 Intel Corporation. All rights reserved. | ||
3 | * | ||
4 | * This software is available to you under a choice of one of two | ||
5 | * licenses. You may choose to be licensed under the terms of the GNU | ||
6 | * General Public License (GPL) Version 2, available from the file | ||
7 | * COPYING in the main directory of this source tree, or the | ||
8 | * OpenIB.org BSD license below: | ||
9 | * | ||
10 | * Redistribution and use in source and binary forms, with or | ||
11 | * without modification, are permitted provided that the following | ||
12 | * conditions are met: | ||
13 | * | ||
14 | * - Redistributions of source code must retain the above | ||
15 | * copyright notice, this list of conditions and the following | ||
16 | * disclaimer. | ||
17 | * | ||
18 | * - Redistributions in binary form must reproduce the above | ||
19 | * copyright notice, this list of conditions and the following | ||
20 | * disclaimer in the documentation and/or other materials | ||
21 | * provided with the distribution. | ||
22 | * | ||
23 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | ||
24 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF | ||
25 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND | ||
26 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS | ||
27 | * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN | ||
28 | * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN | ||
29 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
30 | * SOFTWARE. | ||
31 | */ | ||
32 | |||
33 | #if !defined(IB_USER_MARSHALL_H) | ||
34 | #define IB_USER_MARSHALL_H | ||
35 | |||
36 | #include <rdma/ib_verbs.h> | ||
37 | #include <rdma/ib_sa.h> | ||
38 | #include <rdma/ib_user_verbs.h> | ||
39 | #include <rdma/ib_user_sa.h> | ||
40 | |||
41 | void ib_copy_qp_attr_to_user(struct ib_uverbs_qp_attr *dst, | ||
42 | struct ib_qp_attr *src); | ||
43 | |||
44 | void ib_copy_path_rec_to_user(struct ib_user_path_rec *dst, | ||
45 | struct ib_sa_path_rec *src); | ||
46 | |||
47 | void ib_copy_path_rec_from_user(struct ib_sa_path_rec *dst, | ||
48 | struct ib_user_path_rec *src); | ||
49 | |||
50 | #endif /* IB_USER_MARSHALL_H */ | ||
diff --git a/include/rdma/ib_sa.h b/include/rdma/ib_sa.h index ad63c215efe5..c99e4420fd7e 100644 --- a/include/rdma/ib_sa.h +++ b/include/rdma/ib_sa.h | |||
@@ -370,5 +370,12 @@ ib_sa_mcmember_rec_delete(struct ib_device *device, u8 port_num, | |||
370 | context, query); | 370 | context, query); |
371 | } | 371 | } |
372 | 372 | ||
373 | /** | ||
374 | * ib_init_ah_from_path - Initialize address handle attributes based on an SA | ||
375 | * path record. | ||
376 | */ | ||
377 | int ib_init_ah_from_path(struct ib_device *device, u8 port_num, | ||
378 | struct ib_sa_path_rec *rec, | ||
379 | struct ib_ah_attr *ah_attr); | ||
373 | 380 | ||
374 | #endif /* IB_SA_H */ | 381 | #endif /* IB_SA_H */ |
diff --git a/include/rdma/ib_smi.h b/include/rdma/ib_smi.h index 87f60737f695..f29af135ba83 100644 --- a/include/rdma/ib_smi.h +++ b/include/rdma/ib_smi.h | |||
@@ -85,6 +85,42 @@ struct ib_smp { | |||
85 | #define IB_SMP_ATTR_LED_INFO __constant_htons(0x0031) | 85 | #define IB_SMP_ATTR_LED_INFO __constant_htons(0x0031) |
86 | #define IB_SMP_ATTR_VENDOR_MASK __constant_htons(0xFF00) | 86 | #define IB_SMP_ATTR_VENDOR_MASK __constant_htons(0xFF00) |
87 | 87 | ||
88 | struct ib_port_info { | ||
89 | __be64 mkey; | ||
90 | __be64 gid_prefix; | ||
91 | __be16 lid; | ||
92 | __be16 sm_lid; | ||
93 | __be32 cap_mask; | ||
94 | __be16 diag_code; | ||
95 | __be16 mkey_lease_period; | ||
96 | u8 local_port_num; | ||
97 | u8 link_width_enabled; | ||
98 | u8 link_width_supported; | ||
99 | u8 link_width_active; | ||
100 | u8 linkspeed_portstate; /* 4 bits, 4 bits */ | ||
101 | u8 portphysstate_linkdown; /* 4 bits, 4 bits */ | ||
102 | u8 mkeyprot_resv_lmc; /* 2 bits, 3, 3 */ | ||
103 | u8 linkspeedactive_enabled; /* 4 bits, 4 bits */ | ||
104 | u8 neighbormtu_mastersmsl; /* 4 bits, 4 bits */ | ||
105 | u8 vlcap_inittype; /* 4 bits, 4 bits */ | ||
106 | u8 vl_high_limit; | ||
107 | u8 vl_arb_high_cap; | ||
108 | u8 vl_arb_low_cap; | ||
109 | u8 inittypereply_mtucap; /* 4 bits, 4 bits */ | ||
110 | u8 vlstallcnt_hoqlife; /* 3 bits, 5 bits */ | ||
111 | u8 operationalvl_pei_peo_fpi_fpo; /* 4 bits, 1, 1, 1, 1 */ | ||
112 | __be16 mkey_violations; | ||
113 | __be16 pkey_violations; | ||
114 | __be16 qkey_violations; | ||
115 | u8 guid_cap; | ||
116 | u8 clientrereg_resv_subnetto; /* 1 bit, 2 bits, 5 */ | ||
117 | u8 resv_resptimevalue; /* 3 bits, 5 bits */ | ||
118 | u8 localphyerrors_overrunerrors; /* 4 bits, 4 bits */ | ||
119 | __be16 max_credit_hint; | ||
120 | u8 resv; | ||
121 | u8 link_roundtrip_latency[3]; | ||
122 | }; | ||
123 | |||
88 | static inline u8 | 124 | static inline u8 |
89 | ib_get_smp_direction(struct ib_smp *smp) | 125 | ib_get_smp_direction(struct ib_smp *smp) |
90 | { | 126 | { |
diff --git a/include/rdma/ib_user_cm.h b/include/rdma/ib_user_cm.h index 19be116047f6..066c20b7cdfb 100644 --- a/include/rdma/ib_user_cm.h +++ b/include/rdma/ib_user_cm.h | |||
@@ -30,13 +30,13 @@ | |||
30 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | 30 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE |
31 | * SOFTWARE. | 31 | * SOFTWARE. |
32 | * | 32 | * |
33 | * $Id: ib_user_cm.h 2576 2005-06-09 17:00:30Z libor $ | 33 | * $Id: ib_user_cm.h 4019 2005-11-11 00:33:09Z sean.hefty $ |
34 | */ | 34 | */ |
35 | 35 | ||
36 | #ifndef IB_USER_CM_H | 36 | #ifndef IB_USER_CM_H |
37 | #define IB_USER_CM_H | 37 | #define IB_USER_CM_H |
38 | 38 | ||
39 | #include <linux/types.h> | 39 | #include <rdma/ib_user_sa.h> |
40 | 40 | ||
41 | #define IB_USER_CM_ABI_VERSION 4 | 41 | #define IB_USER_CM_ABI_VERSION 4 |
42 | 42 | ||
@@ -110,58 +110,6 @@ struct ib_ucm_init_qp_attr { | |||
110 | __u32 qp_state; | 110 | __u32 qp_state; |
111 | }; | 111 | }; |
112 | 112 | ||
113 | struct ib_ucm_ah_attr { | ||
114 | __u8 grh_dgid[16]; | ||
115 | __u32 grh_flow_label; | ||
116 | __u16 dlid; | ||
117 | __u16 reserved; | ||
118 | __u8 grh_sgid_index; | ||
119 | __u8 grh_hop_limit; | ||
120 | __u8 grh_traffic_class; | ||
121 | __u8 sl; | ||
122 | __u8 src_path_bits; | ||
123 | __u8 static_rate; | ||
124 | __u8 is_global; | ||
125 | __u8 port_num; | ||
126 | }; | ||
127 | |||
128 | struct ib_ucm_init_qp_attr_resp { | ||
129 | __u32 qp_attr_mask; | ||
130 | __u32 qp_state; | ||
131 | __u32 cur_qp_state; | ||
132 | __u32 path_mtu; | ||
133 | __u32 path_mig_state; | ||
134 | __u32 qkey; | ||
135 | __u32 rq_psn; | ||
136 | __u32 sq_psn; | ||
137 | __u32 dest_qp_num; | ||
138 | __u32 qp_access_flags; | ||
139 | |||
140 | struct ib_ucm_ah_attr ah_attr; | ||
141 | struct ib_ucm_ah_attr alt_ah_attr; | ||
142 | |||
143 | /* ib_qp_cap */ | ||
144 | __u32 max_send_wr; | ||
145 | __u32 max_recv_wr; | ||
146 | __u32 max_send_sge; | ||
147 | __u32 max_recv_sge; | ||
148 | __u32 max_inline_data; | ||
149 | |||
150 | __u16 pkey_index; | ||
151 | __u16 alt_pkey_index; | ||
152 | __u8 en_sqd_async_notify; | ||
153 | __u8 sq_draining; | ||
154 | __u8 max_rd_atomic; | ||
155 | __u8 max_dest_rd_atomic; | ||
156 | __u8 min_rnr_timer; | ||
157 | __u8 port_num; | ||
158 | __u8 timeout; | ||
159 | __u8 retry_cnt; | ||
160 | __u8 rnr_retry; | ||
161 | __u8 alt_port_num; | ||
162 | __u8 alt_timeout; | ||
163 | }; | ||
164 | |||
165 | struct ib_ucm_listen { | 113 | struct ib_ucm_listen { |
166 | __be64 service_id; | 114 | __be64 service_id; |
167 | __be64 service_mask; | 115 | __be64 service_mask; |
@@ -180,28 +128,6 @@ struct ib_ucm_private_data { | |||
180 | __u8 reserved[3]; | 128 | __u8 reserved[3]; |
181 | }; | 129 | }; |
182 | 130 | ||
183 | struct ib_ucm_path_rec { | ||
184 | __u8 dgid[16]; | ||
185 | __u8 sgid[16]; | ||
186 | __be16 dlid; | ||
187 | __be16 slid; | ||
188 | __u32 raw_traffic; | ||
189 | __be32 flow_label; | ||
190 | __u32 reversible; | ||
191 | __u32 mtu; | ||
192 | __be16 pkey; | ||
193 | __u8 hop_limit; | ||
194 | __u8 traffic_class; | ||
195 | __u8 numb_path; | ||
196 | __u8 sl; | ||
197 | __u8 mtu_selector; | ||
198 | __u8 rate_selector; | ||
199 | __u8 rate; | ||
200 | __u8 packet_life_time_selector; | ||
201 | __u8 packet_life_time; | ||
202 | __u8 preference; | ||
203 | }; | ||
204 | |||
205 | struct ib_ucm_req { | 131 | struct ib_ucm_req { |
206 | __u32 id; | 132 | __u32 id; |
207 | __u32 qpn; | 133 | __u32 qpn; |
@@ -274,7 +200,7 @@ struct ib_ucm_sidr_req { | |||
274 | __be64 sid; | 200 | __be64 sid; |
275 | __u64 data; | 201 | __u64 data; |
276 | __u64 path; | 202 | __u64 path; |
277 | __u16 pkey; | 203 | __u16 reserved_pkey; |
278 | __u8 len; | 204 | __u8 len; |
279 | __u8 max_cm_retries; | 205 | __u8 max_cm_retries; |
280 | __u8 reserved[4]; | 206 | __u8 reserved[4]; |
@@ -304,8 +230,8 @@ struct ib_ucm_event_get { | |||
304 | }; | 230 | }; |
305 | 231 | ||
306 | struct ib_ucm_req_event_resp { | 232 | struct ib_ucm_req_event_resp { |
307 | struct ib_ucm_path_rec primary_path; | 233 | struct ib_user_path_rec primary_path; |
308 | struct ib_ucm_path_rec alternate_path; | 234 | struct ib_user_path_rec alternate_path; |
309 | __be64 remote_ca_guid; | 235 | __be64 remote_ca_guid; |
310 | __u32 remote_qkey; | 236 | __u32 remote_qkey; |
311 | __u32 remote_qpn; | 237 | __u32 remote_qpn; |
@@ -349,7 +275,7 @@ struct ib_ucm_mra_event_resp { | |||
349 | }; | 275 | }; |
350 | 276 | ||
351 | struct ib_ucm_lap_event_resp { | 277 | struct ib_ucm_lap_event_resp { |
352 | struct ib_ucm_path_rec path; | 278 | struct ib_user_path_rec path; |
353 | }; | 279 | }; |
354 | 280 | ||
355 | struct ib_ucm_apr_event_resp { | 281 | struct ib_ucm_apr_event_resp { |
diff --git a/include/rdma/ib_user_sa.h b/include/rdma/ib_user_sa.h new file mode 100644 index 000000000000..659120157e14 --- /dev/null +++ b/include/rdma/ib_user_sa.h | |||
@@ -0,0 +1,60 @@ | |||
1 | /* | ||
2 | * Copyright (c) 2005 Intel Corporation. All rights reserved. | ||
3 | * | ||
4 | * This software is available to you under a choice of one of two | ||
5 | * licenses. You may choose to be licensed under the terms of the GNU | ||
6 | * General Public License (GPL) Version 2, available from the file | ||
7 | * COPYING in the main directory of this source tree, or the | ||
8 | * OpenIB.org BSD license below: | ||
9 | * | ||
10 | * Redistribution and use in source and binary forms, with or | ||
11 | * without modification, are permitted provided that the following | ||
12 | * conditions are met: | ||
13 | * | ||
14 | * - Redistributions of source code must retain the above | ||
15 | * copyright notice, this list of conditions and the following | ||
16 | * disclaimer. | ||
17 | * | ||
18 | * - Redistributions in binary form must reproduce the above | ||
19 | * copyright notice, this list of conditions and the following | ||
20 | * disclaimer in the documentation and/or other materials | ||
21 | * provided with the distribution. | ||
22 | * | ||
23 | * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, | ||
24 | * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF | ||
25 | * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND | ||
26 | * NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS | ||
27 | * BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN | ||
28 | * ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN | ||
29 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | ||
30 | * SOFTWARE. | ||
31 | */ | ||
32 | |||
33 | #ifndef IB_USER_SA_H | ||
34 | #define IB_USER_SA_H | ||
35 | |||
36 | #include <linux/types.h> | ||
37 | |||
38 | struct ib_user_path_rec { | ||
39 | __u8 dgid[16]; | ||
40 | __u8 sgid[16]; | ||
41 | __be16 dlid; | ||
42 | __be16 slid; | ||
43 | __u32 raw_traffic; | ||
44 | __be32 flow_label; | ||
45 | __u32 reversible; | ||
46 | __u32 mtu; | ||
47 | __be16 pkey; | ||
48 | __u8 hop_limit; | ||
49 | __u8 traffic_class; | ||
50 | __u8 numb_path; | ||
51 | __u8 sl; | ||
52 | __u8 mtu_selector; | ||
53 | __u8 rate_selector; | ||
54 | __u8 rate; | ||
55 | __u8 packet_life_time_selector; | ||
56 | __u8 packet_life_time; | ||
57 | __u8 preference; | ||
58 | }; | ||
59 | |||
60 | #endif /* IB_USER_SA_H */ | ||
diff --git a/include/rdma/ib_user_verbs.h b/include/rdma/ib_user_verbs.h index 338ed4333063..7b5372010f4b 100644 --- a/include/rdma/ib_user_verbs.h +++ b/include/rdma/ib_user_verbs.h | |||
@@ -32,7 +32,7 @@ | |||
32 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE | 32 | * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE |
33 | * SOFTWARE. | 33 | * SOFTWARE. |
34 | * | 34 | * |
35 | * $Id: ib_user_verbs.h 2708 2005-06-24 17:27:21Z roland $ | 35 | * $Id: ib_user_verbs.h 4019 2005-11-11 00:33:09Z sean.hefty $ |
36 | */ | 36 | */ |
37 | 37 | ||
38 | #ifndef IB_USER_VERBS_H | 38 | #ifndef IB_USER_VERBS_H |
@@ -323,6 +323,64 @@ struct ib_uverbs_destroy_cq_resp { | |||
323 | __u32 async_events_reported; | 323 | __u32 async_events_reported; |
324 | }; | 324 | }; |
325 | 325 | ||
326 | struct ib_uverbs_global_route { | ||
327 | __u8 dgid[16]; | ||
328 | __u32 flow_label; | ||
329 | __u8 sgid_index; | ||
330 | __u8 hop_limit; | ||
331 | __u8 traffic_class; | ||
332 | __u8 reserved; | ||
333 | }; | ||
334 | |||
335 | struct ib_uverbs_ah_attr { | ||
336 | struct ib_uverbs_global_route grh; | ||
337 | __u16 dlid; | ||
338 | __u8 sl; | ||
339 | __u8 src_path_bits; | ||
340 | __u8 static_rate; | ||
341 | __u8 is_global; | ||
342 | __u8 port_num; | ||
343 | __u8 reserved; | ||
344 | }; | ||
345 | |||
346 | struct ib_uverbs_qp_attr { | ||
347 | __u32 qp_attr_mask; | ||
348 | __u32 qp_state; | ||
349 | __u32 cur_qp_state; | ||
350 | __u32 path_mtu; | ||
351 | __u32 path_mig_state; | ||
352 | __u32 qkey; | ||
353 | __u32 rq_psn; | ||
354 | __u32 sq_psn; | ||
355 | __u32 dest_qp_num; | ||
356 | __u32 qp_access_flags; | ||
357 | |||
358 | struct ib_uverbs_ah_attr ah_attr; | ||
359 | struct ib_uverbs_ah_attr alt_ah_attr; | ||
360 | |||
361 | /* ib_qp_cap */ | ||
362 | __u32 max_send_wr; | ||
363 | __u32 max_recv_wr; | ||
364 | __u32 max_send_sge; | ||
365 | __u32 max_recv_sge; | ||
366 | __u32 max_inline_data; | ||
367 | |||
368 | __u16 pkey_index; | ||
369 | __u16 alt_pkey_index; | ||
370 | __u8 en_sqd_async_notify; | ||
371 | __u8 sq_draining; | ||
372 | __u8 max_rd_atomic; | ||
373 | __u8 max_dest_rd_atomic; | ||
374 | __u8 min_rnr_timer; | ||
375 | __u8 port_num; | ||
376 | __u8 timeout; | ||
377 | __u8 retry_cnt; | ||
378 | __u8 rnr_retry; | ||
379 | __u8 alt_port_num; | ||
380 | __u8 alt_timeout; | ||
381 | __u8 reserved[5]; | ||
382 | }; | ||
383 | |||
326 | struct ib_uverbs_create_qp { | 384 | struct ib_uverbs_create_qp { |
327 | __u64 response; | 385 | __u64 response; |
328 | __u64 user_handle; | 386 | __u64 user_handle; |
@@ -541,26 +599,6 @@ struct ib_uverbs_post_srq_recv_resp { | |||
541 | __u32 bad_wr; | 599 | __u32 bad_wr; |
542 | }; | 600 | }; |
543 | 601 | ||
544 | struct ib_uverbs_global_route { | ||
545 | __u8 dgid[16]; | ||
546 | __u32 flow_label; | ||
547 | __u8 sgid_index; | ||
548 | __u8 hop_limit; | ||
549 | __u8 traffic_class; | ||
550 | __u8 reserved; | ||
551 | }; | ||
552 | |||
553 | struct ib_uverbs_ah_attr { | ||
554 | struct ib_uverbs_global_route grh; | ||
555 | __u16 dlid; | ||
556 | __u8 sl; | ||
557 | __u8 src_path_bits; | ||
558 | __u8 static_rate; | ||
559 | __u8 is_global; | ||
560 | __u8 port_num; | ||
561 | __u8 reserved; | ||
562 | }; | ||
563 | |||
564 | struct ib_uverbs_create_ah { | 602 | struct ib_uverbs_create_ah { |
565 | __u64 response; | 603 | __u64 response; |
566 | __u64 user_handle; | 604 | __u64 user_handle; |
diff --git a/include/rdma/ib_verbs.h b/include/rdma/ib_verbs.h index 6bbf1b364400..ee1f3a355666 100644 --- a/include/rdma/ib_verbs.h +++ b/include/rdma/ib_verbs.h | |||
@@ -260,7 +260,8 @@ enum ib_event_type { | |||
260 | IB_EVENT_SM_CHANGE, | 260 | IB_EVENT_SM_CHANGE, |
261 | IB_EVENT_SRQ_ERR, | 261 | IB_EVENT_SRQ_ERR, |
262 | IB_EVENT_SRQ_LIMIT_REACHED, | 262 | IB_EVENT_SRQ_LIMIT_REACHED, |
263 | IB_EVENT_QP_LAST_WQE_REACHED | 263 | IB_EVENT_QP_LAST_WQE_REACHED, |
264 | IB_EVENT_CLIENT_REREGISTER | ||
264 | }; | 265 | }; |
265 | 266 | ||
266 | struct ib_event { | 267 | struct ib_event { |
@@ -696,8 +697,12 @@ struct ib_ucontext { | |||
696 | struct ib_uobject { | 697 | struct ib_uobject { |
697 | u64 user_handle; /* handle given to us by userspace */ | 698 | u64 user_handle; /* handle given to us by userspace */ |
698 | struct ib_ucontext *context; /* associated user context */ | 699 | struct ib_ucontext *context; /* associated user context */ |
700 | void *object; /* containing object */ | ||
699 | struct list_head list; /* link to context's list */ | 701 | struct list_head list; /* link to context's list */ |
700 | u32 id; /* index into kernel idr */ | 702 | u32 id; /* index into kernel idr */ |
703 | struct kref ref; | ||
704 | struct rw_semaphore mutex; /* protects .live */ | ||
705 | int live; | ||
701 | }; | 706 | }; |
702 | 707 | ||
703 | struct ib_umem { | 708 | struct ib_umem { |
@@ -827,6 +832,7 @@ struct ib_cache { | |||
827 | struct ib_event_handler event_handler; | 832 | struct ib_event_handler event_handler; |
828 | struct ib_pkey_cache **pkey_cache; | 833 | struct ib_pkey_cache **pkey_cache; |
829 | struct ib_gid_cache **gid_cache; | 834 | struct ib_gid_cache **gid_cache; |
835 | u8 *lmc_cache; | ||
830 | }; | 836 | }; |
831 | 837 | ||
832 | struct ib_device { | 838 | struct ib_device { |
@@ -1086,6 +1092,20 @@ int ib_dealloc_pd(struct ib_pd *pd); | |||
1086 | struct ib_ah *ib_create_ah(struct ib_pd *pd, struct ib_ah_attr *ah_attr); | 1092 | struct ib_ah *ib_create_ah(struct ib_pd *pd, struct ib_ah_attr *ah_attr); |
1087 | 1093 | ||
1088 | /** | 1094 | /** |
1095 | * ib_init_ah_from_wc - Initializes address handle attributes from a | ||
1096 | * work completion. | ||
1097 | * @device: Device on which the received message arrived. | ||
1098 | * @port_num: Port on which the received message arrived. | ||
1099 | * @wc: Work completion associated with the received message. | ||
1100 | * @grh: References the received global route header. This parameter is | ||
1101 | * ignored unless the work completion indicates that the GRH is valid. | ||
1102 | * @ah_attr: Returned attributes that can be used when creating an address | ||
1103 | * handle for replying to the message. | ||
1104 | */ | ||
1105 | int ib_init_ah_from_wc(struct ib_device *device, u8 port_num, struct ib_wc *wc, | ||
1106 | struct ib_grh *grh, struct ib_ah_attr *ah_attr); | ||
1107 | |||
1108 | /** | ||
1089 | * ib_create_ah_from_wc - Creates an address handle associated with the | 1109 | * ib_create_ah_from_wc - Creates an address handle associated with the |
1090 | * sender of the specified work completion. | 1110 | * sender of the specified work completion. |
1091 | * @pd: The protection domain associated with the address handle. | 1111 | * @pd: The protection domain associated with the address handle. |
diff --git a/include/rdma/rdma_cm.h b/include/rdma/rdma_cm.h new file mode 100644 index 000000000000..402c63d7226b --- /dev/null +++ b/include/rdma/rdma_cm.h | |||
@@ -0,0 +1,256 @@ | |||
1 | /* | ||
2 | * Copyright (c) 2005 Voltaire Inc. All rights reserved. | ||
3 | * Copyright (c) 2005 Intel Corporation. All rights reserved. | ||
4 | * | ||
5 | * This Software is licensed under one of the following licenses: | ||
6 | * | ||
7 | * 1) under the terms of the "Common Public License 1.0" a copy of which is | ||
8 | * available from the Open Source Initiative, see | ||
9 | * http://www.opensource.org/licenses/cpl.php. | ||
10 | * | ||
11 | * 2) under the terms of the "The BSD License" a copy of which is | ||
12 | * available from the Open Source Initiative, see | ||
13 | * http://www.opensource.org/licenses/bsd-license.php. | ||
14 | * | ||
15 | * 3) under the terms of the "GNU General Public License (GPL) Version 2" a | ||
16 | * copy of which is available from the Open Source Initiative, see | ||
17 | * http://www.opensource.org/licenses/gpl-license.php. | ||
18 | * | ||
19 | * Licensee has the right to choose one of the above licenses. | ||
20 | * | ||
21 | * Redistributions of source code must retain the above copyright | ||
22 | * notice and one of the license notices. | ||
23 | * | ||
24 | * Redistributions in binary form must reproduce both the above copyright | ||
25 | * notice, one of the license notices in the documentation | ||
26 | * and/or other materials provided with the distribution. | ||
27 | * | ||
28 | */ | ||
29 | |||
30 | #if !defined(RDMA_CM_H) | ||
31 | #define RDMA_CM_H | ||
32 | |||
33 | #include <linux/socket.h> | ||
34 | #include <linux/in6.h> | ||
35 | #include <rdma/ib_addr.h> | ||
36 | #include <rdma/ib_sa.h> | ||
37 | |||
38 | /* | ||
39 | * Upon receiving a device removal event, users must destroy the associated | ||
40 | * RDMA identifier and release all resources allocated with the device. | ||
41 | */ | ||
42 | enum rdma_cm_event_type { | ||
43 | RDMA_CM_EVENT_ADDR_RESOLVED, | ||
44 | RDMA_CM_EVENT_ADDR_ERROR, | ||
45 | RDMA_CM_EVENT_ROUTE_RESOLVED, | ||
46 | RDMA_CM_EVENT_ROUTE_ERROR, | ||
47 | RDMA_CM_EVENT_CONNECT_REQUEST, | ||
48 | RDMA_CM_EVENT_CONNECT_RESPONSE, | ||
49 | RDMA_CM_EVENT_CONNECT_ERROR, | ||
50 | RDMA_CM_EVENT_UNREACHABLE, | ||
51 | RDMA_CM_EVENT_REJECTED, | ||
52 | RDMA_CM_EVENT_ESTABLISHED, | ||
53 | RDMA_CM_EVENT_DISCONNECTED, | ||
54 | RDMA_CM_EVENT_DEVICE_REMOVAL, | ||
55 | }; | ||
56 | |||
57 | enum rdma_port_space { | ||
58 | RDMA_PS_SDP = 0x0001, | ||
59 | RDMA_PS_TCP = 0x0106, | ||
60 | RDMA_PS_UDP = 0x0111, | ||
61 | RDMA_PS_SCTP = 0x0183 | ||
62 | }; | ||
63 | |||
64 | struct rdma_addr { | ||
65 | struct sockaddr src_addr; | ||
66 | u8 src_pad[sizeof(struct sockaddr_in6) - | ||
67 | sizeof(struct sockaddr)]; | ||
68 | struct sockaddr dst_addr; | ||
69 | u8 dst_pad[sizeof(struct sockaddr_in6) - | ||
70 | sizeof(struct sockaddr)]; | ||
71 | struct rdma_dev_addr dev_addr; | ||
72 | }; | ||
73 | |||
74 | struct rdma_route { | ||
75 | struct rdma_addr addr; | ||
76 | struct ib_sa_path_rec *path_rec; | ||
77 | int num_paths; | ||
78 | }; | ||
79 | |||
80 | struct rdma_cm_event { | ||
81 | enum rdma_cm_event_type event; | ||
82 | int status; | ||
83 | void *private_data; | ||
84 | u8 private_data_len; | ||
85 | }; | ||
86 | |||
87 | struct rdma_cm_id; | ||
88 | |||
89 | /** | ||
90 | * rdma_cm_event_handler - Callback used to report user events. | ||
91 | * | ||
92 | * Notes: Users may not call rdma_destroy_id from this callback to destroy | ||
93 | * the passed in id, or a corresponding listen id. Returning a | ||
94 | * non-zero value from the callback will destroy the passed in id. | ||
95 | */ | ||
96 | typedef int (*rdma_cm_event_handler)(struct rdma_cm_id *id, | ||
97 | struct rdma_cm_event *event); | ||
98 | |||
99 | struct rdma_cm_id { | ||
100 | struct ib_device *device; | ||
101 | void *context; | ||
102 | struct ib_qp *qp; | ||
103 | rdma_cm_event_handler event_handler; | ||
104 | struct rdma_route route; | ||
105 | enum rdma_port_space ps; | ||
106 | u8 port_num; | ||
107 | }; | ||
108 | |||
109 | /** | ||
110 | * rdma_create_id - Create an RDMA identifier. | ||
111 | * | ||
112 | * @event_handler: User callback invoked to report events associated with the | ||
113 | * returned rdma_id. | ||
114 | * @context: User specified context associated with the id. | ||
115 | * @ps: RDMA port space. | ||
116 | */ | ||
117 | struct rdma_cm_id *rdma_create_id(rdma_cm_event_handler event_handler, | ||
118 | void *context, enum rdma_port_space ps); | ||
119 | |||
120 | void rdma_destroy_id(struct rdma_cm_id *id); | ||
121 | |||
122 | /** | ||
123 | * rdma_bind_addr - Bind an RDMA identifier to a source address and | ||
124 | * associated RDMA device, if needed. | ||
125 | * | ||
126 | * @id: RDMA identifier. | ||
127 | * @addr: Local address information. Wildcard values are permitted. | ||
128 | * | ||
129 | * This associates a source address with the RDMA identifier before calling | ||
130 | * rdma_listen. If a specific local address is given, the RDMA identifier will | ||
131 | * be bound to a local RDMA device. | ||
132 | */ | ||
133 | int rdma_bind_addr(struct rdma_cm_id *id, struct sockaddr *addr); | ||
134 | |||
135 | /** | ||
136 | * rdma_resolve_addr - Resolve destination and optional source addresses | ||
137 | * from IP addresses to an RDMA address. If successful, the specified | ||
138 | * rdma_cm_id will be bound to a local device. | ||
139 | * | ||
140 | * @id: RDMA identifier. | ||
141 | * @src_addr: Source address information. This parameter may be NULL. | ||
142 | * @dst_addr: Destination address information. | ||
143 | * @timeout_ms: Time to wait for resolution to complete. | ||
144 | */ | ||
145 | int rdma_resolve_addr(struct rdma_cm_id *id, struct sockaddr *src_addr, | ||
146 | struct sockaddr *dst_addr, int timeout_ms); | ||
147 | |||
148 | /** | ||
149 | * rdma_resolve_route - Resolve the RDMA address bound to the RDMA identifier | ||
150 | * into route information needed to establish a connection. | ||
151 | * | ||
152 | * This is called on the client side of a connection. | ||
153 | * Users must have first called rdma_resolve_addr to resolve a dst_addr | ||
154 | * into an RDMA address before calling this routine. | ||
155 | */ | ||
156 | int rdma_resolve_route(struct rdma_cm_id *id, int timeout_ms); | ||
157 | |||
158 | /** | ||
159 | * rdma_create_qp - Allocate a QP and associate it with the specified RDMA | ||
160 | * identifier. | ||
161 | * | ||
162 | * QPs allocated to an rdma_cm_id will automatically be transitioned by the CMA | ||
163 | * through their states. | ||
164 | */ | ||
165 | int rdma_create_qp(struct rdma_cm_id *id, struct ib_pd *pd, | ||
166 | struct ib_qp_init_attr *qp_init_attr); | ||
167 | |||
168 | /** | ||
169 | * rdma_destroy_qp - Deallocate the QP associated with the specified RDMA | ||
170 | * identifier. | ||
171 | * | ||
172 | * Users must destroy any QP associated with an RDMA identifier before | ||
173 | * destroying the RDMA ID. | ||
174 | */ | ||
175 | void rdma_destroy_qp(struct rdma_cm_id *id); | ||
176 | |||
177 | /** | ||
178 | * rdma_init_qp_attr - Initializes the QP attributes for use in transitioning | ||
179 | * to a specified QP state. | ||
180 | * @id: Communication identifier associated with the QP attributes to | ||
181 | * initialize. | ||
182 | * @qp_attr: On input, specifies the desired QP state. On output, the | ||
183 | * mandatory and desired optional attributes will be set in order to | ||
184 | * modify the QP to the specified state. | ||
185 | * @qp_attr_mask: The QP attribute mask that may be used to transition the | ||
186 | * QP to the specified state. | ||
187 | * | ||
188 | * Users must set the @qp_attr->qp_state to the desired QP state. This call | ||
189 | * will set all required attributes for the given transition, along with | ||
190 | * known optional attributes. Users may override the attributes returned from | ||
191 | * this call before calling ib_modify_qp. | ||
192 | * | ||
193 | * Users that wish to have their QP automatically transitioned through its | ||
194 | * states can associate a QP with the rdma_cm_id by calling rdma_create_qp(). | ||
195 | */ | ||
196 | int rdma_init_qp_attr(struct rdma_cm_id *id, struct ib_qp_attr *qp_attr, | ||
197 | int *qp_attr_mask); | ||
198 | |||
199 | struct rdma_conn_param { | ||
200 | const void *private_data; | ||
201 | u8 private_data_len; | ||
202 | u8 responder_resources; | ||
203 | u8 initiator_depth; | ||
204 | u8 flow_control; | ||
205 | u8 retry_count; /* ignored when accepting */ | ||
206 | u8 rnr_retry_count; | ||
207 | /* Fields below ignored if a QP is created on the rdma_cm_id. */ | ||
208 | u8 srq; | ||
209 | u32 qp_num; | ||
210 | enum ib_qp_type qp_type; | ||
211 | }; | ||
212 | |||
213 | /** | ||
214 | * rdma_connect - Initiate an active connection request. | ||
215 | * | ||
216 | * Users must have resolved a route for the rdma_cm_id to connect with | ||
217 | * by having called rdma_resolve_route before calling this routine. | ||
218 | */ | ||
219 | int rdma_connect(struct rdma_cm_id *id, struct rdma_conn_param *conn_param); | ||
220 | |||
221 | /** | ||
222 | * rdma_listen - This function is called by the passive side to | ||
223 | * listen for incoming connection requests. | ||
224 | * | ||
225 | * Users must have bound the rdma_cm_id to a local address by calling | ||
226 | * rdma_bind_addr before calling this routine. | ||
227 | */ | ||
228 | int rdma_listen(struct rdma_cm_id *id, int backlog); | ||
229 | |||
230 | /** | ||
231 | * rdma_accept - Called to accept a connection request or response. | ||
232 | * @id: Connection identifier associated with the request. | ||
233 | * @conn_param: Information needed to establish the connection. This must be | ||
234 | * provided if accepting a connection request. If accepting a connection | ||
235 | * response, this parameter must be NULL. | ||
236 | * | ||
237 | * Typically, this routine is only called by the listener to accept a connection | ||
238 | * request. It must also be called on the active side of a connection if the | ||
239 | * user is performing their own QP transitions. | ||
240 | */ | ||
241 | int rdma_accept(struct rdma_cm_id *id, struct rdma_conn_param *conn_param); | ||
242 | |||
243 | /** | ||
244 | * rdma_reject - Called to reject a connection request or response. | ||
245 | */ | ||
246 | int rdma_reject(struct rdma_cm_id *id, const void *private_data, | ||
247 | u8 private_data_len); | ||
248 | |||
249 | /** | ||
250 | * rdma_disconnect - This function disconnects the associated QP and | ||
251 | * transitions it into the error state. | ||
252 | */ | ||
253 | int rdma_disconnect(struct rdma_cm_id *id); | ||
254 | |||
255 | #endif /* RDMA_CM_H */ | ||
256 | |||
diff --git a/include/rdma/rdma_cm_ib.h b/include/rdma/rdma_cm_ib.h new file mode 100644 index 000000000000..e8c3af1804d4 --- /dev/null +++ b/include/rdma/rdma_cm_ib.h | |||
@@ -0,0 +1,47 @@ | |||
1 | /* | ||
2 | * Copyright (c) 2006 Intel Corporation. All rights reserved. | ||
3 | * | ||
4 | * This Software is licensed under one of the following licenses: | ||
5 | * | ||
6 | * 1) under the terms of the "Common Public License 1.0" a copy of which is | ||
7 | * available from the Open Source Initiative, see | ||
8 | * http://www.opensource.org/licenses/cpl.php. | ||
9 | * | ||
10 | * 2) under the terms of the "The BSD License" a copy of which is | ||
11 | * available from the Open Source Initiative, see | ||
12 | * http://www.opensource.org/licenses/bsd-license.php. | ||
13 | * | ||
14 | * 3) under the terms of the "GNU General Public License (GPL) Version 2" a | ||
15 | * copy of which is available from the Open Source Initiative, see | ||
16 | * http://www.opensource.org/licenses/gpl-license.php. | ||
17 | * | ||
18 | * Licensee has the right to choose one of the above licenses. | ||
19 | * | ||
20 | * Redistributions of source code must retain the above copyright | ||
21 | * notice and one of the license notices. | ||
22 | * | ||
23 | * Redistributions in binary form must reproduce both the above copyright | ||
24 | * notice, one of the license notices in the documentation | ||
25 | * and/or other materials provided with the distribution. | ||
26 | * | ||
27 | */ | ||
28 | |||
29 | #if !defined(RDMA_CM_IB_H) | ||
30 | #define RDMA_CM_IB_H | ||
31 | |||
32 | #include <rdma/rdma_cm.h> | ||
33 | |||
34 | /** | ||
35 | * rdma_set_ib_paths - Manually sets the path records used to establish a | ||
36 | * connection. | ||
37 | * @id: Connection identifier associated with the request. | ||
38 | * @path_rec: Reference to the path record | ||
39 | * | ||
40 | * This call permits a user to specify routing information for rdma_cm_id's | ||
41 | * bound to Infiniband devices. It is called on the client side of a | ||
42 | * connection and replaces the call to rdma_resolve_route. | ||
43 | */ | ||
44 | int rdma_set_ib_paths(struct rdma_cm_id *id, | ||
45 | struct ib_sa_path_rec *path_rec, int num_paths); | ||
46 | |||
47 | #endif /* RDMA_CM_IB_H */ | ||
diff --git a/include/scsi/iscsi_if.h b/include/scsi/iscsi_if.h index e5618b90996e..253797c60095 100644 --- a/include/scsi/iscsi_if.h +++ b/include/scsi/iscsi_if.h | |||
@@ -43,6 +43,10 @@ enum iscsi_uevent_e { | |||
43 | ISCSI_UEVENT_GET_STATS = UEVENT_BASE + 10, | 43 | ISCSI_UEVENT_GET_STATS = UEVENT_BASE + 10, |
44 | ISCSI_UEVENT_GET_PARAM = UEVENT_BASE + 11, | 44 | ISCSI_UEVENT_GET_PARAM = UEVENT_BASE + 11, |
45 | 45 | ||
46 | ISCSI_UEVENT_TRANSPORT_EP_CONNECT = UEVENT_BASE + 12, | ||
47 | ISCSI_UEVENT_TRANSPORT_EP_POLL = UEVENT_BASE + 13, | ||
48 | ISCSI_UEVENT_TRANSPORT_EP_DISCONNECT = UEVENT_BASE + 14, | ||
49 | |||
46 | /* up events */ | 50 | /* up events */ |
47 | ISCSI_KEVENT_RECV_PDU = KEVENT_BASE + 1, | 51 | ISCSI_KEVENT_RECV_PDU = KEVENT_BASE + 1, |
48 | ISCSI_KEVENT_CONN_ERROR = KEVENT_BASE + 2, | 52 | ISCSI_KEVENT_CONN_ERROR = KEVENT_BASE + 2, |
@@ -60,61 +64,83 @@ struct iscsi_uevent { | |||
60 | uint32_t initial_cmdsn; | 64 | uint32_t initial_cmdsn; |
61 | } c_session; | 65 | } c_session; |
62 | struct msg_destroy_session { | 66 | struct msg_destroy_session { |
63 | uint64_t session_handle; | ||
64 | uint32_t sid; | 67 | uint32_t sid; |
65 | } d_session; | 68 | } d_session; |
66 | struct msg_create_conn { | 69 | struct msg_create_conn { |
67 | uint64_t session_handle; | ||
68 | uint32_t cid; | ||
69 | uint32_t sid; | 70 | uint32_t sid; |
71 | uint32_t cid; | ||
70 | } c_conn; | 72 | } c_conn; |
71 | struct msg_bind_conn { | 73 | struct msg_bind_conn { |
72 | uint64_t session_handle; | 74 | uint32_t sid; |
73 | uint64_t conn_handle; | 75 | uint32_t cid; |
74 | uint32_t transport_fd; | 76 | uint64_t transport_eph; |
75 | uint32_t is_leading; | 77 | uint32_t is_leading; |
76 | } b_conn; | 78 | } b_conn; |
77 | struct msg_destroy_conn { | 79 | struct msg_destroy_conn { |
78 | uint64_t conn_handle; | 80 | uint32_t sid; |
79 | uint32_t cid; | 81 | uint32_t cid; |
80 | } d_conn; | 82 | } d_conn; |
81 | struct msg_send_pdu { | 83 | struct msg_send_pdu { |
84 | uint32_t sid; | ||
85 | uint32_t cid; | ||
82 | uint32_t hdr_size; | 86 | uint32_t hdr_size; |
83 | uint32_t data_size; | 87 | uint32_t data_size; |
84 | uint64_t conn_handle; | ||
85 | } send_pdu; | 88 | } send_pdu; |
86 | struct msg_set_param { | 89 | struct msg_set_param { |
87 | uint64_t conn_handle; | 90 | uint32_t sid; |
91 | uint32_t cid; | ||
88 | uint32_t param; /* enum iscsi_param */ | 92 | uint32_t param; /* enum iscsi_param */ |
89 | uint32_t value; | 93 | uint32_t len; |
90 | } set_param; | 94 | } set_param; |
91 | struct msg_start_conn { | 95 | struct msg_start_conn { |
92 | uint64_t conn_handle; | 96 | uint32_t sid; |
97 | uint32_t cid; | ||
93 | } start_conn; | 98 | } start_conn; |
94 | struct msg_stop_conn { | 99 | struct msg_stop_conn { |
100 | uint32_t sid; | ||
101 | uint32_t cid; | ||
95 | uint64_t conn_handle; | 102 | uint64_t conn_handle; |
96 | uint32_t flag; | 103 | uint32_t flag; |
97 | } stop_conn; | 104 | } stop_conn; |
98 | struct msg_get_stats { | 105 | struct msg_get_stats { |
99 | uint64_t conn_handle; | 106 | uint32_t sid; |
107 | uint32_t cid; | ||
100 | } get_stats; | 108 | } get_stats; |
109 | struct msg_transport_connect { | ||
110 | uint32_t non_blocking; | ||
111 | } ep_connect; | ||
112 | struct msg_transport_poll { | ||
113 | uint64_t ep_handle; | ||
114 | uint32_t timeout_ms; | ||
115 | } ep_poll; | ||
116 | struct msg_transport_disconnect { | ||
117 | uint64_t ep_handle; | ||
118 | } ep_disconnect; | ||
101 | } u; | 119 | } u; |
102 | union { | 120 | union { |
103 | /* messages k -> u */ | 121 | /* messages k -> u */ |
104 | uint64_t handle; | ||
105 | int retcode; | 122 | int retcode; |
106 | struct msg_create_session_ret { | 123 | struct msg_create_session_ret { |
107 | uint64_t session_handle; | ||
108 | uint32_t sid; | 124 | uint32_t sid; |
125 | uint32_t host_no; | ||
109 | } c_session_ret; | 126 | } c_session_ret; |
127 | struct msg_create_conn_ret { | ||
128 | uint32_t sid; | ||
129 | uint32_t cid; | ||
130 | } c_conn_ret; | ||
110 | struct msg_recv_req { | 131 | struct msg_recv_req { |
132 | uint32_t sid; | ||
133 | uint32_t cid; | ||
111 | uint64_t recv_handle; | 134 | uint64_t recv_handle; |
112 | uint64_t conn_handle; | ||
113 | } recv_req; | 135 | } recv_req; |
114 | struct msg_conn_error { | 136 | struct msg_conn_error { |
115 | uint64_t conn_handle; | 137 | uint32_t sid; |
138 | uint32_t cid; | ||
116 | uint32_t error; /* enum iscsi_err */ | 139 | uint32_t error; /* enum iscsi_err */ |
117 | } connerror; | 140 | } connerror; |
141 | struct msg_transport_connect_ret { | ||
142 | uint64_t handle; | ||
143 | } ep_connect_ret; | ||
118 | } r; | 144 | } r; |
119 | } __attribute__ ((aligned (sizeof(uint64_t)))); | 145 | } __attribute__ ((aligned (sizeof(uint64_t)))); |
120 | 146 | ||
@@ -139,29 +165,66 @@ enum iscsi_err { | |||
139 | ISCSI_ERR_SESSION_FAILED = ISCSI_ERR_BASE + 13, | 165 | ISCSI_ERR_SESSION_FAILED = ISCSI_ERR_BASE + 13, |
140 | ISCSI_ERR_HDR_DGST = ISCSI_ERR_BASE + 14, | 166 | ISCSI_ERR_HDR_DGST = ISCSI_ERR_BASE + 14, |
141 | ISCSI_ERR_DATA_DGST = ISCSI_ERR_BASE + 15, | 167 | ISCSI_ERR_DATA_DGST = ISCSI_ERR_BASE + 15, |
142 | ISCSI_ERR_PARAM_NOT_FOUND = ISCSI_ERR_BASE + 16 | 168 | ISCSI_ERR_PARAM_NOT_FOUND = ISCSI_ERR_BASE + 16, |
169 | ISCSI_ERR_NO_SCSI_CMD = ISCSI_ERR_BASE + 17, | ||
143 | }; | 170 | }; |
144 | 171 | ||
145 | /* | 172 | /* |
146 | * iSCSI Parameters (RFC3720) | 173 | * iSCSI Parameters (RFC3720) |
147 | */ | 174 | */ |
148 | enum iscsi_param { | 175 | enum iscsi_param { |
149 | ISCSI_PARAM_MAX_RECV_DLENGTH = 0, | 176 | /* passed in using netlink set param */ |
150 | ISCSI_PARAM_MAX_XMIT_DLENGTH = 1, | 177 | ISCSI_PARAM_MAX_RECV_DLENGTH, |
151 | ISCSI_PARAM_HDRDGST_EN = 2, | 178 | ISCSI_PARAM_MAX_XMIT_DLENGTH, |
152 | ISCSI_PARAM_DATADGST_EN = 3, | 179 | ISCSI_PARAM_HDRDGST_EN, |
153 | ISCSI_PARAM_INITIAL_R2T_EN = 4, | 180 | ISCSI_PARAM_DATADGST_EN, |
154 | ISCSI_PARAM_MAX_R2T = 5, | 181 | ISCSI_PARAM_INITIAL_R2T_EN, |
155 | ISCSI_PARAM_IMM_DATA_EN = 6, | 182 | ISCSI_PARAM_MAX_R2T, |
156 | ISCSI_PARAM_FIRST_BURST = 7, | 183 | ISCSI_PARAM_IMM_DATA_EN, |
157 | ISCSI_PARAM_MAX_BURST = 8, | 184 | ISCSI_PARAM_FIRST_BURST, |
158 | ISCSI_PARAM_PDU_INORDER_EN = 9, | 185 | ISCSI_PARAM_MAX_BURST, |
159 | ISCSI_PARAM_DATASEQ_INORDER_EN = 10, | 186 | ISCSI_PARAM_PDU_INORDER_EN, |
160 | ISCSI_PARAM_ERL = 11, | 187 | ISCSI_PARAM_DATASEQ_INORDER_EN, |
161 | ISCSI_PARAM_IFMARKER_EN = 12, | 188 | ISCSI_PARAM_ERL, |
162 | ISCSI_PARAM_OFMARKER_EN = 13, | 189 | ISCSI_PARAM_IFMARKER_EN, |
190 | ISCSI_PARAM_OFMARKER_EN, | ||
191 | ISCSI_PARAM_EXP_STATSN, | ||
192 | ISCSI_PARAM_TARGET_NAME, | ||
193 | ISCSI_PARAM_TPGT, | ||
194 | ISCSI_PARAM_PERSISTENT_ADDRESS, | ||
195 | ISCSI_PARAM_PERSISTENT_PORT, | ||
196 | ISCSI_PARAM_SESS_RECOVERY_TMO, | ||
197 | |||
198 | /* pased in through bind conn using transport_fd */ | ||
199 | ISCSI_PARAM_CONN_PORT, | ||
200 | ISCSI_PARAM_CONN_ADDRESS, | ||
201 | |||
202 | /* must always be last */ | ||
203 | ISCSI_PARAM_MAX, | ||
163 | }; | 204 | }; |
164 | #define ISCSI_PARAM_MAX 14 | 205 | |
206 | #define ISCSI_MAX_RECV_DLENGTH (1 << ISCSI_PARAM_MAX_RECV_DLENGTH) | ||
207 | #define ISCSI_MAX_XMIT_DLENGTH (1 << ISCSI_PARAM_MAX_XMIT_DLENGTH) | ||
208 | #define ISCSI_HDRDGST_EN (1 << ISCSI_PARAM_HDRDGST_EN) | ||
209 | #define ISCSI_DATADGST_EN (1 << ISCSI_PARAM_DATADGST_EN) | ||
210 | #define ISCSI_INITIAL_R2T_EN (1 << ISCSI_PARAM_INITIAL_R2T_EN) | ||
211 | #define ISCSI_MAX_R2T (1 << ISCSI_PARAM_MAX_R2T) | ||
212 | #define ISCSI_IMM_DATA_EN (1 << ISCSI_PARAM_IMM_DATA_EN) | ||
213 | #define ISCSI_FIRST_BURST (1 << ISCSI_PARAM_FIRST_BURST) | ||
214 | #define ISCSI_MAX_BURST (1 << ISCSI_PARAM_MAX_BURST) | ||
215 | #define ISCSI_PDU_INORDER_EN (1 << ISCSI_PARAM_PDU_INORDER_EN) | ||
216 | #define ISCSI_DATASEQ_INORDER_EN (1 << ISCSI_PARAM_DATASEQ_INORDER_EN) | ||
217 | #define ISCSI_ERL (1 << ISCSI_PARAM_ERL) | ||
218 | #define ISCSI_IFMARKER_EN (1 << ISCSI_PARAM_IFMARKER_EN) | ||
219 | #define ISCSI_OFMARKER_EN (1 << ISCSI_PARAM_OFMARKER_EN) | ||
220 | #define ISCSI_EXP_STATSN (1 << ISCSI_PARAM_EXP_STATSN) | ||
221 | #define ISCSI_TARGET_NAME (1 << ISCSI_PARAM_TARGET_NAME) | ||
222 | #define ISCSI_TPGT (1 << ISCSI_PARAM_TPGT) | ||
223 | #define ISCSI_PERSISTENT_ADDRESS (1 << ISCSI_PARAM_PERSISTENT_ADDRESS) | ||
224 | #define ISCSI_PERSISTENT_PORT (1 << ISCSI_PARAM_PERSISTENT_PORT) | ||
225 | #define ISCSI_SESS_RECOVERY_TMO (1 << ISCSI_PARAM_SESS_RECOVERY_TMO) | ||
226 | #define ISCSI_CONN_PORT (1 << ISCSI_PARAM_CONN_PORT) | ||
227 | #define ISCSI_CONN_ADDRESS (1 << ISCSI_PARAM_CONN_ADDRESS) | ||
165 | 228 | ||
166 | #define iscsi_ptr(_handle) ((void*)(unsigned long)_handle) | 229 | #define iscsi_ptr(_handle) ((void*)(unsigned long)_handle) |
167 | #define iscsi_handle(_ptr) ((uint64_t)(unsigned long)_ptr) | 230 | #define iscsi_handle(_ptr) ((uint64_t)(unsigned long)_ptr) |
diff --git a/include/scsi/iscsi_proto.h b/include/scsi/iscsi_proto.h index 4feda05fdf25..02f6e4b9e693 100644 --- a/include/scsi/iscsi_proto.h +++ b/include/scsi/iscsi_proto.h | |||
@@ -21,8 +21,6 @@ | |||
21 | #ifndef ISCSI_PROTO_H | 21 | #ifndef ISCSI_PROTO_H |
22 | #define ISCSI_PROTO_H | 22 | #define ISCSI_PROTO_H |
23 | 23 | ||
24 | #define ISCSI_VERSION_STR "0.3" | ||
25 | #define ISCSI_DATE_STR "22-Apr-2005" | ||
26 | #define ISCSI_DRAFT20_VERSION 0x00 | 24 | #define ISCSI_DRAFT20_VERSION 0x00 |
27 | 25 | ||
28 | /* default iSCSI listen port for incoming connections */ | 26 | /* default iSCSI listen port for incoming connections */ |
diff --git a/include/scsi/libiscsi.h b/include/scsi/libiscsi.h new file mode 100644 index 000000000000..cbf7e58bd6f9 --- /dev/null +++ b/include/scsi/libiscsi.h | |||
@@ -0,0 +1,282 @@ | |||
1 | /* | ||
2 | * iSCSI lib definitions | ||
3 | * | ||
4 | * Copyright (C) 2006 Red Hat, Inc. All rights reserved. | ||
5 | * Copyright (C) 2004 - 2006 Mike Christie | ||
6 | * Copyright (C) 2004 - 2005 Dmitry Yusupov | ||
7 | * Copyright (C) 2004 - 2005 Alex Aizman | ||
8 | * | ||
9 | * This program is free software; you can redistribute it and/or modify | ||
10 | * it under the terms of the GNU General Public License as published by | ||
11 | * the Free Software Foundation; either version 2 of the License, or | ||
12 | * (at your option) any later version. | ||
13 | * | ||
14 | * This program is distributed in the hope that it will be useful, | ||
15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
17 | * GNU General Public License for more details. | ||
18 | * | ||
19 | * You should have received a copy of the GNU General Public License | ||
20 | * along with this program; if not, write to the Free Software | ||
21 | * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. | ||
22 | */ | ||
23 | #ifndef LIBISCSI_H | ||
24 | #define LIBISCSI_H | ||
25 | |||
26 | #include <linux/types.h> | ||
27 | #include <linux/mutex.h> | ||
28 | #include <scsi/iscsi_proto.h> | ||
29 | #include <scsi/iscsi_if.h> | ||
30 | |||
31 | struct scsi_transport_template; | ||
32 | struct scsi_device; | ||
33 | struct Scsi_Host; | ||
34 | struct scsi_cmnd; | ||
35 | struct socket; | ||
36 | struct iscsi_transport; | ||
37 | struct iscsi_cls_session; | ||
38 | struct iscsi_cls_conn; | ||
39 | struct iscsi_session; | ||
40 | struct iscsi_nopin; | ||
41 | |||
42 | /* #define DEBUG_SCSI */ | ||
43 | #ifdef DEBUG_SCSI | ||
44 | #define debug_scsi(fmt...) printk(KERN_INFO "iscsi: " fmt) | ||
45 | #else | ||
46 | #define debug_scsi(fmt...) | ||
47 | #endif | ||
48 | |||
49 | #define ISCSI_XMIT_CMDS_MAX 128 /* must be power of 2 */ | ||
50 | #define ISCSI_MGMT_CMDS_MAX 32 /* must be power of 2 */ | ||
51 | #define ISCSI_CONN_MAX 1 | ||
52 | |||
53 | #define ISCSI_MGMT_ITT_OFFSET 0xa00 | ||
54 | |||
55 | #define ISCSI_DEF_CMD_PER_LUN 32 | ||
56 | #define ISCSI_MAX_CMD_PER_LUN 128 | ||
57 | |||
58 | /* Task Mgmt states */ | ||
59 | #define TMABORT_INITIAL 0x0 | ||
60 | #define TMABORT_SUCCESS 0x1 | ||
61 | #define TMABORT_FAILED 0x2 | ||
62 | #define TMABORT_TIMEDOUT 0x3 | ||
63 | |||
64 | /* Connection suspend "bit" */ | ||
65 | #define ISCSI_SUSPEND_BIT 1 | ||
66 | |||
67 | #define ISCSI_ITT_MASK (0xfff) | ||
68 | #define ISCSI_CID_SHIFT 12 | ||
69 | #define ISCSI_CID_MASK (0xffff << ISCSI_CID_SHIFT) | ||
70 | #define ISCSI_AGE_SHIFT 28 | ||
71 | #define ISCSI_AGE_MASK (0xf << ISCSI_AGE_SHIFT) | ||
72 | |||
73 | struct iscsi_mgmt_task { | ||
74 | /* | ||
75 | * Becuae LLDs allocate their hdr differently, this is a pointer to | ||
76 | * that storage. It must be setup at session creation time. | ||
77 | */ | ||
78 | struct iscsi_hdr *hdr; | ||
79 | char *data; /* mgmt payload */ | ||
80 | int data_count; /* counts data to be sent */ | ||
81 | uint32_t itt; /* this ITT */ | ||
82 | void *dd_data; /* driver/transport data */ | ||
83 | struct list_head running; | ||
84 | }; | ||
85 | |||
86 | struct iscsi_cmd_task { | ||
87 | /* | ||
88 | * Becuae LLDs allocate their hdr differently, this is a pointer to | ||
89 | * that storage. It must be setup at session creation time. | ||
90 | */ | ||
91 | struct iscsi_cmd *hdr; | ||
92 | int itt; /* this ITT */ | ||
93 | int datasn; /* DataSN */ | ||
94 | |||
95 | uint32_t unsol_datasn; | ||
96 | int imm_count; /* imm-data (bytes) */ | ||
97 | int unsol_count; /* unsolicited (bytes)*/ | ||
98 | int data_count; /* remaining Data-Out */ | ||
99 | struct scsi_cmnd *sc; /* associated SCSI cmd*/ | ||
100 | int total_length; | ||
101 | struct iscsi_conn *conn; /* used connection */ | ||
102 | struct iscsi_mgmt_task *mtask; /* tmf mtask in progr */ | ||
103 | |||
104 | struct list_head running; /* running cmd list */ | ||
105 | void *dd_data; /* driver/transport data */ | ||
106 | }; | ||
107 | |||
108 | struct iscsi_conn { | ||
109 | struct iscsi_cls_conn *cls_conn; /* ptr to class connection */ | ||
110 | void *dd_data; /* iscsi_transport data */ | ||
111 | struct iscsi_session *session; /* parent session */ | ||
112 | /* | ||
113 | * LLDs should set this lock. It protects the transport recv | ||
114 | * code | ||
115 | */ | ||
116 | rwlock_t *recv_lock; | ||
117 | /* | ||
118 | * conn_stop() flag: stop to recover, stop to terminate | ||
119 | */ | ||
120 | int stop_stage; | ||
121 | |||
122 | /* iSCSI connection-wide sequencing */ | ||
123 | uint32_t exp_statsn; | ||
124 | |||
125 | /* control data */ | ||
126 | int id; /* CID */ | ||
127 | struct list_head item; /* maintains list of conns */ | ||
128 | int c_stage; /* connection state */ | ||
129 | struct iscsi_mgmt_task *login_mtask; /* mtask used for login/text */ | ||
130 | struct iscsi_mgmt_task *mtask; /* xmit mtask in progress */ | ||
131 | struct iscsi_cmd_task *ctask; /* xmit ctask in progress */ | ||
132 | |||
133 | /* xmit */ | ||
134 | struct kfifo *immqueue; /* immediate xmit queue */ | ||
135 | struct kfifo *mgmtqueue; /* mgmt (control) xmit queue */ | ||
136 | struct list_head mgmt_run_list; /* list of control tasks */ | ||
137 | struct kfifo *xmitqueue; /* data-path cmd queue */ | ||
138 | struct list_head run_list; /* list of cmds in progress */ | ||
139 | struct work_struct xmitwork; /* per-conn. xmit workqueue */ | ||
140 | /* | ||
141 | * serializes connection xmit, access to kfifos: | ||
142 | * xmitqueue, immqueue, mgmtqueue | ||
143 | */ | ||
144 | struct mutex xmitmutex; | ||
145 | |||
146 | unsigned long suspend_tx; /* suspend Tx */ | ||
147 | unsigned long suspend_rx; /* suspend Rx */ | ||
148 | |||
149 | /* abort */ | ||
150 | wait_queue_head_t ehwait; /* used in eh_abort() */ | ||
151 | struct iscsi_tm tmhdr; | ||
152 | struct timer_list tmabort_timer; | ||
153 | int tmabort_state; /* see TMABORT_INITIAL, etc.*/ | ||
154 | |||
155 | /* negotiated params */ | ||
156 | int max_recv_dlength; /* initiator_max_recv_dsl*/ | ||
157 | int max_xmit_dlength; /* target_max_recv_dsl */ | ||
158 | int hdrdgst_en; | ||
159 | int datadgst_en; | ||
160 | |||
161 | /* MIB-statistics */ | ||
162 | uint64_t txdata_octets; | ||
163 | uint64_t rxdata_octets; | ||
164 | uint32_t scsicmd_pdus_cnt; | ||
165 | uint32_t dataout_pdus_cnt; | ||
166 | uint32_t scsirsp_pdus_cnt; | ||
167 | uint32_t datain_pdus_cnt; | ||
168 | uint32_t r2t_pdus_cnt; | ||
169 | uint32_t tmfcmd_pdus_cnt; | ||
170 | int32_t tmfrsp_pdus_cnt; | ||
171 | |||
172 | /* custom statistics */ | ||
173 | uint32_t eh_abort_cnt; | ||
174 | }; | ||
175 | |||
176 | struct iscsi_queue { | ||
177 | struct kfifo *queue; /* FIFO Queue */ | ||
178 | void **pool; /* Pool of elements */ | ||
179 | int max; /* Max number of elements */ | ||
180 | }; | ||
181 | |||
182 | struct iscsi_session { | ||
183 | /* iSCSI session-wide sequencing */ | ||
184 | uint32_t cmdsn; | ||
185 | uint32_t exp_cmdsn; | ||
186 | uint32_t max_cmdsn; | ||
187 | |||
188 | /* configuration */ | ||
189 | int initial_r2t_en; | ||
190 | int max_r2t; | ||
191 | int imm_data_en; | ||
192 | int first_burst; | ||
193 | int max_burst; | ||
194 | int time2wait; | ||
195 | int time2retain; | ||
196 | int pdu_inorder_en; | ||
197 | int dataseq_inorder_en; | ||
198 | int erl; | ||
199 | int ifmarker_en; | ||
200 | int ofmarker_en; | ||
201 | |||
202 | /* control data */ | ||
203 | struct iscsi_transport *tt; | ||
204 | struct Scsi_Host *host; | ||
205 | struct iscsi_conn *leadconn; /* leading connection */ | ||
206 | spinlock_t lock; /* protects session state, * | ||
207 | * sequence numbers, * | ||
208 | * session resources: * | ||
209 | * - cmdpool, * | ||
210 | * - mgmtpool, * | ||
211 | * - r2tpool */ | ||
212 | int state; /* session state */ | ||
213 | struct list_head item; | ||
214 | int age; /* counts session re-opens */ | ||
215 | |||
216 | struct list_head connections; /* list of connections */ | ||
217 | int cmds_max; /* size of cmds array */ | ||
218 | struct iscsi_cmd_task **cmds; /* Original Cmds arr */ | ||
219 | struct iscsi_queue cmdpool; /* PDU's pool */ | ||
220 | int mgmtpool_max; /* size of mgmt array */ | ||
221 | struct iscsi_mgmt_task **mgmt_cmds; /* Original mgmt arr */ | ||
222 | struct iscsi_queue mgmtpool; /* Mgmt PDU's pool */ | ||
223 | }; | ||
224 | |||
225 | /* | ||
226 | * scsi host template | ||
227 | */ | ||
228 | extern int iscsi_change_queue_depth(struct scsi_device *sdev, int depth); | ||
229 | extern int iscsi_eh_abort(struct scsi_cmnd *sc); | ||
230 | extern int iscsi_eh_host_reset(struct scsi_cmnd *sc); | ||
231 | extern int iscsi_queuecommand(struct scsi_cmnd *sc, | ||
232 | void (*done)(struct scsi_cmnd *)); | ||
233 | |||
234 | /* | ||
235 | * session management | ||
236 | */ | ||
237 | extern struct iscsi_cls_session * | ||
238 | iscsi_session_setup(struct iscsi_transport *, struct scsi_transport_template *, | ||
239 | int, int, uint32_t, uint32_t *); | ||
240 | extern void iscsi_session_teardown(struct iscsi_cls_session *); | ||
241 | extern struct iscsi_session *class_to_transport_session(struct iscsi_cls_session *); | ||
242 | extern void iscsi_session_recovery_timedout(struct iscsi_cls_session *); | ||
243 | |||
244 | #define session_to_cls(_sess) \ | ||
245 | hostdata_session(_sess->host->hostdata) | ||
246 | |||
247 | /* | ||
248 | * connection management | ||
249 | */ | ||
250 | extern struct iscsi_cls_conn *iscsi_conn_setup(struct iscsi_cls_session *, | ||
251 | uint32_t); | ||
252 | extern void iscsi_conn_teardown(struct iscsi_cls_conn *); | ||
253 | extern int iscsi_conn_start(struct iscsi_cls_conn *); | ||
254 | extern void iscsi_conn_stop(struct iscsi_cls_conn *, int); | ||
255 | extern int iscsi_conn_bind(struct iscsi_cls_session *, struct iscsi_cls_conn *, | ||
256 | int); | ||
257 | extern void iscsi_conn_failure(struct iscsi_conn *conn, enum iscsi_err err); | ||
258 | |||
259 | /* | ||
260 | * pdu and task processing | ||
261 | */ | ||
262 | extern int iscsi_check_assign_cmdsn(struct iscsi_session *, | ||
263 | struct iscsi_nopin *); | ||
264 | extern void iscsi_prep_unsolicit_data_pdu(struct iscsi_cmd_task *, | ||
265 | struct iscsi_data *hdr, | ||
266 | int transport_data_cnt); | ||
267 | extern int iscsi_conn_send_pdu(struct iscsi_cls_conn *, struct iscsi_hdr *, | ||
268 | char *, uint32_t); | ||
269 | extern int iscsi_complete_pdu(struct iscsi_conn *, struct iscsi_hdr *, | ||
270 | char *, int); | ||
271 | extern int __iscsi_complete_pdu(struct iscsi_conn *, struct iscsi_hdr *, | ||
272 | char *, int); | ||
273 | extern int iscsi_verify_itt(struct iscsi_conn *, struct iscsi_hdr *, | ||
274 | uint32_t *); | ||
275 | |||
276 | /* | ||
277 | * generic helpers | ||
278 | */ | ||
279 | extern void iscsi_pool_free(struct iscsi_queue *, void **); | ||
280 | extern int iscsi_pool_init(struct iscsi_queue *, int, void ***, int); | ||
281 | |||
282 | #endif | ||
diff --git a/include/scsi/scsi_cmnd.h b/include/scsi/scsi_cmnd.h index 88c6c4da6c05..e46cd404bd7d 100644 --- a/include/scsi/scsi_cmnd.h +++ b/include/scsi/scsi_cmnd.h | |||
@@ -9,7 +9,6 @@ | |||
9 | struct request; | 9 | struct request; |
10 | struct scatterlist; | 10 | struct scatterlist; |
11 | struct scsi_device; | 11 | struct scsi_device; |
12 | struct scsi_request; | ||
13 | 12 | ||
14 | 13 | ||
15 | /* embedded in scsi_cmnd */ | 14 | /* embedded in scsi_cmnd */ |
@@ -29,13 +28,8 @@ struct scsi_pointer { | |||
29 | }; | 28 | }; |
30 | 29 | ||
31 | struct scsi_cmnd { | 30 | struct scsi_cmnd { |
32 | int sc_magic; | ||
33 | |||
34 | struct scsi_device *device; | 31 | struct scsi_device *device; |
35 | struct scsi_request *sc_request; | ||
36 | |||
37 | struct list_head list; /* scsi_cmnd participates in queue lists */ | 32 | struct list_head list; /* scsi_cmnd participates in queue lists */ |
38 | |||
39 | struct list_head eh_entry; /* entry for the host eh_cmd_q */ | 33 | struct list_head eh_entry; /* entry for the host eh_cmd_q */ |
40 | int eh_eflags; /* Used by error handlr */ | 34 | int eh_eflags; /* Used by error handlr */ |
41 | void (*done) (struct scsi_cmnd *); /* Mid-level done function */ | 35 | void (*done) (struct scsi_cmnd *); /* Mid-level done function */ |
@@ -153,4 +147,8 @@ extern void scsi_io_completion(struct scsi_cmnd *, unsigned int, unsigned int); | |||
153 | extern void scsi_finish_command(struct scsi_cmnd *cmd); | 147 | extern void scsi_finish_command(struct scsi_cmnd *cmd); |
154 | extern void scsi_req_abort_cmd(struct scsi_cmnd *cmd); | 148 | extern void scsi_req_abort_cmd(struct scsi_cmnd *cmd); |
155 | 149 | ||
150 | extern void *scsi_kmap_atomic_sg(struct scatterlist *sg, int sg_count, | ||
151 | size_t *offset, size_t *len); | ||
152 | extern void scsi_kunmap_atomic_sg(void *virt); | ||
153 | |||
156 | #endif /* _SCSI_SCSI_CMND_H */ | 154 | #endif /* _SCSI_SCSI_CMND_H */ |
diff --git a/include/scsi/scsi_dbg.h b/include/scsi/scsi_dbg.h index 4d69dee66d4d..3bbbfbe8cbfc 100644 --- a/include/scsi/scsi_dbg.h +++ b/include/scsi/scsi_dbg.h | |||
@@ -2,14 +2,12 @@ | |||
2 | #define _SCSI_SCSI_DBG_H | 2 | #define _SCSI_SCSI_DBG_H |
3 | 3 | ||
4 | struct scsi_cmnd; | 4 | struct scsi_cmnd; |
5 | struct scsi_request; | ||
6 | struct scsi_sense_hdr; | 5 | struct scsi_sense_hdr; |
7 | 6 | ||
8 | extern void scsi_print_command(struct scsi_cmnd *); | 7 | extern void scsi_print_command(struct scsi_cmnd *); |
9 | extern void scsi_print_sense_hdr(const char *, struct scsi_sense_hdr *); | 8 | extern void scsi_print_sense_hdr(const char *, struct scsi_sense_hdr *); |
10 | extern void __scsi_print_command(unsigned char *); | 9 | extern void __scsi_print_command(unsigned char *); |
11 | extern void scsi_print_sense(const char *, struct scsi_cmnd *); | 10 | extern void scsi_print_sense(const char *, struct scsi_cmnd *); |
12 | extern void scsi_print_req_sense(const char *, struct scsi_request *); | ||
13 | extern void __scsi_print_sense(const char *name, | 11 | extern void __scsi_print_sense(const char *name, |
14 | const unsigned char *sense_buffer, | 12 | const unsigned char *sense_buffer, |
15 | int sense_len); | 13 | int sense_len); |
diff --git a/include/scsi/scsi_devinfo.h b/include/scsi/scsi_devinfo.h index d31b16d25a09..b4ddd3b18b4c 100644 --- a/include/scsi/scsi_devinfo.h +++ b/include/scsi/scsi_devinfo.h | |||
@@ -29,4 +29,5 @@ | |||
29 | #define BLIST_SELECT_NO_ATN 0x200000 /* select without ATN */ | 29 | #define BLIST_SELECT_NO_ATN 0x200000 /* select without ATN */ |
30 | #define BLIST_RETRY_HWERROR 0x400000 /* retry HARDWARE_ERROR */ | 30 | #define BLIST_RETRY_HWERROR 0x400000 /* retry HARDWARE_ERROR */ |
31 | #define BLIST_MAX_512 0x800000 /* maximum 512 sector cdb length */ | 31 | #define BLIST_MAX_512 0x800000 /* maximum 512 sector cdb length */ |
32 | #define BLIST_ATTACH_PQ3 0x1000000 /* Scan: Attach to PQ3 devices */ | ||
32 | #endif | 33 | #endif |
diff --git a/include/scsi/scsi_eh.h b/include/scsi/scsi_eh.h index d160880b2a87..c5c0f6762a01 100644 --- a/include/scsi/scsi_eh.h +++ b/include/scsi/scsi_eh.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | struct scsi_cmnd; | 4 | struct scsi_cmnd; |
5 | struct scsi_device; | 5 | struct scsi_device; |
6 | struct scsi_request; | ||
7 | struct Scsi_Host; | 6 | struct Scsi_Host; |
8 | 7 | ||
9 | /* | 8 | /* |
@@ -43,8 +42,6 @@ extern void scsi_report_device_reset(struct Scsi_Host *, int, int); | |||
43 | extern int scsi_block_when_processing_errors(struct scsi_device *); | 42 | extern int scsi_block_when_processing_errors(struct scsi_device *); |
44 | extern int scsi_normalize_sense(const u8 *sense_buffer, int sb_len, | 43 | extern int scsi_normalize_sense(const u8 *sense_buffer, int sb_len, |
45 | struct scsi_sense_hdr *sshdr); | 44 | struct scsi_sense_hdr *sshdr); |
46 | extern int scsi_request_normalize_sense(struct scsi_request *sreq, | ||
47 | struct scsi_sense_hdr *sshdr); | ||
48 | extern int scsi_command_normalize_sense(struct scsi_cmnd *cmd, | 45 | extern int scsi_command_normalize_sense(struct scsi_cmnd *cmd, |
49 | struct scsi_sense_hdr *sshdr); | 46 | struct scsi_sense_hdr *sshdr); |
50 | 47 | ||
diff --git a/include/scsi/scsi_request.h b/include/scsi/scsi_request.h deleted file mode 100644 index 98d69fdb851c..000000000000 --- a/include/scsi/scsi_request.h +++ /dev/null | |||
@@ -1,54 +0,0 @@ | |||
1 | #ifndef _SCSI_SCSI_REQUEST_H | ||
2 | #define _SCSI_SCSI_REQUEST_H | ||
3 | |||
4 | #include <scsi/scsi_cmnd.h> | ||
5 | |||
6 | struct request; | ||
7 | struct scsi_cmnd; | ||
8 | struct scsi_device; | ||
9 | struct Scsi_Host; | ||
10 | |||
11 | |||
12 | /* | ||
13 | * This is essentially a slimmed down version of Scsi_Cmnd. The point of | ||
14 | * having this is that requests that are injected into the queue as result | ||
15 | * of things like ioctls and character devices shouldn't be using a | ||
16 | * Scsi_Cmnd until such a time that the command is actually at the head | ||
17 | * of the queue and being sent to the driver. | ||
18 | */ | ||
19 | struct scsi_request { | ||
20 | int sr_magic; | ||
21 | int sr_result; /* Status code from lower level driver */ | ||
22 | unsigned char sr_sense_buffer[SCSI_SENSE_BUFFERSIZE]; /* obtained by REQUEST SENSE | ||
23 | * when CHECK CONDITION is | ||
24 | * received on original command | ||
25 | * (auto-sense) */ | ||
26 | |||
27 | struct Scsi_Host *sr_host; | ||
28 | struct scsi_device *sr_device; | ||
29 | struct scsi_cmnd *sr_command; | ||
30 | struct request *sr_request; /* A copy of the command we are | ||
31 | working on */ | ||
32 | unsigned sr_bufflen; /* Size of data buffer */ | ||
33 | void *sr_buffer; /* Data buffer */ | ||
34 | int sr_allowed; | ||
35 | enum dma_data_direction sr_data_direction; | ||
36 | unsigned char sr_cmd_len; | ||
37 | unsigned char sr_cmnd[MAX_COMMAND_SIZE]; | ||
38 | void (*sr_done) (struct scsi_cmnd *); /* Mid-level done function */ | ||
39 | int sr_timeout_per_command; | ||
40 | unsigned short sr_use_sg; /* Number of pieces of scatter-gather */ | ||
41 | unsigned short sr_sglist_len; /* size of malloc'd scatter-gather list */ | ||
42 | unsigned sr_underflow; /* Return error if less than | ||
43 | this amount is transferred */ | ||
44 | void *upper_private_data; /* reserved for owner (usually upper | ||
45 | level driver) of this request */ | ||
46 | }; | ||
47 | |||
48 | extern struct scsi_request *scsi_allocate_request(struct scsi_device *, gfp_t); | ||
49 | extern void scsi_release_request(struct scsi_request *); | ||
50 | extern void scsi_do_req(struct scsi_request *, const void *cmnd, | ||
51 | void *buffer, unsigned bufflen, | ||
52 | void (*done) (struct scsi_cmnd *), | ||
53 | int timeout, int retries); | ||
54 | #endif /* _SCSI_SCSI_REQUEST_H */ | ||
diff --git a/include/scsi/scsi_transport_fc.h b/include/scsi/scsi_transport_fc.h index 5626225bd3ae..6d28b0317657 100644 --- a/include/scsi/scsi_transport_fc.h +++ b/include/scsi/scsi_transport_fc.h | |||
@@ -27,7 +27,6 @@ | |||
27 | #ifndef SCSI_TRANSPORT_FC_H | 27 | #ifndef SCSI_TRANSPORT_FC_H |
28 | #define SCSI_TRANSPORT_FC_H | 28 | #define SCSI_TRANSPORT_FC_H |
29 | 29 | ||
30 | #include <linux/config.h> | ||
31 | #include <linux/sched.h> | 30 | #include <linux/sched.h> |
32 | #include <scsi/scsi.h> | 31 | #include <scsi/scsi.h> |
33 | 32 | ||
diff --git a/include/scsi/scsi_transport_iscsi.h b/include/scsi/scsi_transport_iscsi.h index b41cf077e54b..b684426a5900 100644 --- a/include/scsi/scsi_transport_iscsi.h +++ b/include/scsi/scsi_transport_iscsi.h | |||
@@ -2,7 +2,7 @@ | |||
2 | * iSCSI transport class definitions | 2 | * iSCSI transport class definitions |
3 | * | 3 | * |
4 | * Copyright (C) IBM Corporation, 2004 | 4 | * Copyright (C) IBM Corporation, 2004 |
5 | * Copyright (C) Mike Christie, 2004 - 2005 | 5 | * Copyright (C) Mike Christie, 2004 - 2006 |
6 | * Copyright (C) Dmitry Yusupov, 2004 - 2005 | 6 | * Copyright (C) Dmitry Yusupov, 2004 - 2005 |
7 | * Copyright (C) Alex Aizman, 2004 - 2005 | 7 | * Copyright (C) Alex Aizman, 2004 - 2005 |
8 | * | 8 | * |
@@ -27,9 +27,13 @@ | |||
27 | #include <scsi/iscsi_if.h> | 27 | #include <scsi/iscsi_if.h> |
28 | 28 | ||
29 | struct scsi_transport_template; | 29 | struct scsi_transport_template; |
30 | struct iscsi_transport; | ||
30 | struct Scsi_Host; | 31 | struct Scsi_Host; |
31 | struct mempool_zone; | 32 | struct mempool_zone; |
32 | struct iscsi_cls_conn; | 33 | struct iscsi_cls_conn; |
34 | struct iscsi_conn; | ||
35 | struct iscsi_cmd_task; | ||
36 | struct iscsi_mgmt_task; | ||
33 | 37 | ||
34 | /** | 38 | /** |
35 | * struct iscsi_transport - iSCSI Transport template | 39 | * struct iscsi_transport - iSCSI Transport template |
@@ -46,6 +50,24 @@ struct iscsi_cls_conn; | |||
46 | * @start_conn: set connection to be operational | 50 | * @start_conn: set connection to be operational |
47 | * @stop_conn: suspend/recover/terminate connection | 51 | * @stop_conn: suspend/recover/terminate connection |
48 | * @send_pdu: send iSCSI PDU, Login, Logout, NOP-Out, Reject, Text. | 52 | * @send_pdu: send iSCSI PDU, Login, Logout, NOP-Out, Reject, Text. |
53 | * @session_recovery_timedout: notify LLD a block during recovery timed out | ||
54 | * @suspend_conn_recv: susepend the recv side of the connection | ||
55 | * @termincate_conn: destroy socket connection. Called with mutex lock. | ||
56 | * @init_cmd_task: Initialize a iscsi_cmd_task and any internal structs. | ||
57 | * Called from queuecommand with session lock held. | ||
58 | * @init_mgmt_task: Initialize a iscsi_mgmt_task and any internal structs. | ||
59 | * Called from iscsi_conn_send_generic with xmitmutex. | ||
60 | * @xmit_cmd_task: Requests LLD to transfer cmd task. Returns 0 or the | ||
61 | * the number of bytes transferred on success, and -Exyz | ||
62 | * value on error. | ||
63 | * @xmit_mgmt_task: Requests LLD to transfer mgmt task. Returns 0 or the | ||
64 | * the number of bytes transferred on success, and -Exyz | ||
65 | * value on error. | ||
66 | * @cleanup_cmd_task: requests LLD to fail cmd task. Called with xmitmutex | ||
67 | * and session->lock after the connection has been | ||
68 | * suspended and terminated during recovery. If called | ||
69 | * from abort task then connection is not suspended | ||
70 | * or terminated but sk_callback_lock is held | ||
49 | * | 71 | * |
50 | * Template API provided by iSCSI Transport | 72 | * Template API provided by iSCSI Transport |
51 | */ | 73 | */ |
@@ -53,38 +75,58 @@ struct iscsi_transport { | |||
53 | struct module *owner; | 75 | struct module *owner; |
54 | char *name; | 76 | char *name; |
55 | unsigned int caps; | 77 | unsigned int caps; |
78 | /* LLD sets this to indicate what values it can export to sysfs */ | ||
79 | unsigned int param_mask; | ||
56 | struct scsi_host_template *host_template; | 80 | struct scsi_host_template *host_template; |
57 | /* LLD session/scsi_host data size */ | ||
58 | int hostdata_size; | ||
59 | /* LLD iscsi_host data size */ | ||
60 | int ihostdata_size; | ||
61 | /* LLD connection data size */ | 81 | /* LLD connection data size */ |
62 | int conndata_size; | 82 | int conndata_size; |
83 | /* LLD session data size */ | ||
84 | int sessiondata_size; | ||
63 | int max_lun; | 85 | int max_lun; |
64 | unsigned int max_conn; | 86 | unsigned int max_conn; |
65 | unsigned int max_cmd_len; | 87 | unsigned int max_cmd_len; |
66 | struct iscsi_cls_session *(*create_session) | 88 | struct iscsi_cls_session *(*create_session) (struct iscsi_transport *it, |
67 | (struct scsi_transport_template *t, uint32_t sn, uint32_t *sid); | 89 | struct scsi_transport_template *t, uint32_t sn, uint32_t *hn); |
68 | void (*destroy_session) (struct iscsi_cls_session *session); | 90 | void (*destroy_session) (struct iscsi_cls_session *session); |
69 | struct iscsi_cls_conn *(*create_conn) (struct iscsi_cls_session *sess, | 91 | struct iscsi_cls_conn *(*create_conn) (struct iscsi_cls_session *sess, |
70 | uint32_t cid); | 92 | uint32_t cid); |
71 | int (*bind_conn) (struct iscsi_cls_session *session, | 93 | int (*bind_conn) (struct iscsi_cls_session *session, |
72 | struct iscsi_cls_conn *cls_conn, | 94 | struct iscsi_cls_conn *cls_conn, |
73 | uint32_t transport_fd, int is_leading); | 95 | uint64_t transport_eph, int is_leading); |
74 | int (*start_conn) (struct iscsi_cls_conn *conn); | 96 | int (*start_conn) (struct iscsi_cls_conn *conn); |
75 | void (*stop_conn) (struct iscsi_cls_conn *conn, int flag); | 97 | void (*stop_conn) (struct iscsi_cls_conn *conn, int flag); |
76 | void (*destroy_conn) (struct iscsi_cls_conn *conn); | 98 | void (*destroy_conn) (struct iscsi_cls_conn *conn); |
77 | int (*set_param) (struct iscsi_cls_conn *conn, enum iscsi_param param, | 99 | int (*set_param) (struct iscsi_cls_conn *conn, enum iscsi_param param, |
78 | uint32_t value); | 100 | uint32_t value); |
79 | int (*get_conn_param) (struct iscsi_cls_conn *conn, | 101 | int (*get_conn_param) (struct iscsi_cls_conn *conn, |
80 | enum iscsi_param param, | 102 | enum iscsi_param param, uint32_t *value); |
81 | uint32_t *value); | ||
82 | int (*get_session_param) (struct iscsi_cls_session *session, | 103 | int (*get_session_param) (struct iscsi_cls_session *session, |
83 | enum iscsi_param param, uint32_t *value); | 104 | enum iscsi_param param, uint32_t *value); |
105 | int (*get_conn_str_param) (struct iscsi_cls_conn *conn, | ||
106 | enum iscsi_param param, char *buf); | ||
107 | int (*get_session_str_param) (struct iscsi_cls_session *session, | ||
108 | enum iscsi_param param, char *buf); | ||
84 | int (*send_pdu) (struct iscsi_cls_conn *conn, struct iscsi_hdr *hdr, | 109 | int (*send_pdu) (struct iscsi_cls_conn *conn, struct iscsi_hdr *hdr, |
85 | char *data, uint32_t data_size); | 110 | char *data, uint32_t data_size); |
86 | void (*get_stats) (struct iscsi_cls_conn *conn, | 111 | void (*get_stats) (struct iscsi_cls_conn *conn, |
87 | struct iscsi_stats *stats); | 112 | struct iscsi_stats *stats); |
113 | void (*suspend_conn_recv) (struct iscsi_conn *conn); | ||
114 | void (*terminate_conn) (struct iscsi_conn *conn); | ||
115 | void (*init_cmd_task) (struct iscsi_cmd_task *ctask); | ||
116 | void (*init_mgmt_task) (struct iscsi_conn *conn, | ||
117 | struct iscsi_mgmt_task *mtask, | ||
118 | char *data, uint32_t data_size); | ||
119 | int (*xmit_cmd_task) (struct iscsi_conn *conn, | ||
120 | struct iscsi_cmd_task *ctask); | ||
121 | void (*cleanup_cmd_task) (struct iscsi_conn *conn, | ||
122 | struct iscsi_cmd_task *ctask); | ||
123 | int (*xmit_mgmt_task) (struct iscsi_conn *conn, | ||
124 | struct iscsi_mgmt_task *mtask); | ||
125 | void (*session_recovery_timedout) (struct iscsi_cls_session *session); | ||
126 | int (*ep_connect) (struct sockaddr *dst_addr, int non_blocking, | ||
127 | uint64_t *ep_handle); | ||
128 | int (*ep_poll) (uint64_t ep_handle, int timeout_ms); | ||
129 | void (*ep_disconnect) (uint64_t ep_handle); | ||
88 | }; | 130 | }; |
89 | 131 | ||
90 | /* | 132 | /* |
@@ -100,10 +142,26 @@ extern void iscsi_conn_error(struct iscsi_cls_conn *conn, enum iscsi_err error); | |||
100 | extern int iscsi_recv_pdu(struct iscsi_cls_conn *conn, struct iscsi_hdr *hdr, | 142 | extern int iscsi_recv_pdu(struct iscsi_cls_conn *conn, struct iscsi_hdr *hdr, |
101 | char *data, uint32_t data_size); | 143 | char *data, uint32_t data_size); |
102 | 144 | ||
145 | |||
146 | /* Connection's states */ | ||
147 | #define ISCSI_CONN_INITIAL_STAGE 0 | ||
148 | #define ISCSI_CONN_STARTED 1 | ||
149 | #define ISCSI_CONN_STOPPED 2 | ||
150 | #define ISCSI_CONN_CLEANUP_WAIT 3 | ||
151 | |||
103 | struct iscsi_cls_conn { | 152 | struct iscsi_cls_conn { |
104 | struct list_head conn_list; /* item in connlist */ | 153 | struct list_head conn_list; /* item in connlist */ |
105 | void *dd_data; /* LLD private data */ | 154 | void *dd_data; /* LLD private data */ |
106 | struct iscsi_transport *transport; | 155 | struct iscsi_transport *transport; |
156 | uint32_t cid; /* connection id */ | ||
157 | |||
158 | /* portal/group values we got during discovery */ | ||
159 | char *persistent_address; | ||
160 | int persistent_port; | ||
161 | /* portal/group values we are currently using */ | ||
162 | char *address; | ||
163 | int port; | ||
164 | |||
107 | int active; /* must be accessed with the connlock */ | 165 | int active; /* must be accessed with the connlock */ |
108 | struct device dev; /* sysfs transport/container device */ | 166 | struct device dev; /* sysfs transport/container device */ |
109 | struct mempool_zone *z_error; | 167 | struct mempool_zone *z_error; |
@@ -114,9 +172,32 @@ struct iscsi_cls_conn { | |||
114 | #define iscsi_dev_to_conn(_dev) \ | 172 | #define iscsi_dev_to_conn(_dev) \ |
115 | container_of(_dev, struct iscsi_cls_conn, dev) | 173 | container_of(_dev, struct iscsi_cls_conn, dev) |
116 | 174 | ||
175 | /* Session's states */ | ||
176 | #define ISCSI_STATE_FREE 1 | ||
177 | #define ISCSI_STATE_LOGGED_IN 2 | ||
178 | #define ISCSI_STATE_FAILED 3 | ||
179 | #define ISCSI_STATE_TERMINATE 4 | ||
180 | #define ISCSI_STATE_IN_RECOVERY 5 | ||
181 | #define ISCSI_STATE_RECOVERY_FAILED 6 | ||
182 | |||
117 | struct iscsi_cls_session { | 183 | struct iscsi_cls_session { |
118 | struct list_head sess_list; /* item in session_list */ | 184 | struct list_head sess_list; /* item in session_list */ |
185 | struct list_head host_list; | ||
119 | struct iscsi_transport *transport; | 186 | struct iscsi_transport *transport; |
187 | |||
188 | /* iSCSI values used as unique id by userspace. */ | ||
189 | char *targetname; | ||
190 | int tpgt; | ||
191 | |||
192 | /* recovery fields */ | ||
193 | int recovery_tmo; | ||
194 | struct work_struct recovery_work; | ||
195 | |||
196 | int target_id; | ||
197 | int channel; | ||
198 | |||
199 | int sid; /* session id */ | ||
200 | void *dd_data; /* LLD private data */ | ||
120 | struct device dev; /* sysfs transport/container device */ | 201 | struct device dev; /* sysfs transport/container device */ |
121 | }; | 202 | }; |
122 | 203 | ||
@@ -126,22 +207,22 @@ struct iscsi_cls_session { | |||
126 | #define iscsi_session_to_shost(_session) \ | 207 | #define iscsi_session_to_shost(_session) \ |
127 | dev_to_shost(_session->dev.parent) | 208 | dev_to_shost(_session->dev.parent) |
128 | 209 | ||
210 | struct iscsi_host { | ||
211 | int next_target_id; | ||
212 | struct list_head sessions; | ||
213 | struct mutex mutex; | ||
214 | }; | ||
215 | |||
129 | /* | 216 | /* |
130 | * session and connection functions that can be used by HW iSCSI LLDs | 217 | * session and connection functions that can be used by HW iSCSI LLDs |
131 | */ | 218 | */ |
132 | extern struct iscsi_cls_session *iscsi_create_session(struct Scsi_Host *shost, | 219 | extern struct iscsi_cls_session *iscsi_create_session(struct Scsi_Host *shost, |
133 | struct iscsi_transport *t); | 220 | struct iscsi_transport *t, int channel); |
134 | extern int iscsi_destroy_session(struct iscsi_cls_session *session); | 221 | extern int iscsi_destroy_session(struct iscsi_cls_session *session); |
135 | extern struct iscsi_cls_conn *iscsi_create_conn(struct iscsi_cls_session *sess, | 222 | extern struct iscsi_cls_conn *iscsi_create_conn(struct iscsi_cls_session *sess, |
136 | uint32_t cid); | 223 | uint32_t cid); |
137 | extern int iscsi_destroy_conn(struct iscsi_cls_conn *conn); | 224 | extern int iscsi_destroy_conn(struct iscsi_cls_conn *conn); |
138 | 225 | extern void iscsi_unblock_session(struct iscsi_cls_session *session); | |
139 | /* | 226 | extern void iscsi_block_session(struct iscsi_cls_session *session); |
140 | * session functions used by software iscsi | ||
141 | */ | ||
142 | extern struct Scsi_Host * | ||
143 | iscsi_transport_create_session(struct scsi_transport_template *scsit, | ||
144 | struct iscsi_transport *transport); | ||
145 | extern int iscsi_transport_destroy_session(struct Scsi_Host *shost); | ||
146 | 227 | ||
147 | #endif | 228 | #endif |
diff --git a/include/scsi/scsi_transport_spi.h b/include/scsi/scsi_transport_spi.h index 5e1d61913d4e..302680c0c0de 100644 --- a/include/scsi/scsi_transport_spi.h +++ b/include/scsi/scsi_transport_spi.h | |||
@@ -20,7 +20,6 @@ | |||
20 | #ifndef SCSI_TRANSPORT_SPI_H | 20 | #ifndef SCSI_TRANSPORT_SPI_H |
21 | #define SCSI_TRANSPORT_SPI_H | 21 | #define SCSI_TRANSPORT_SPI_H |
22 | 22 | ||
23 | #include <linux/config.h> | ||
24 | #include <linux/transport_class.h> | 23 | #include <linux/transport_class.h> |
25 | #include <linux/mutex.h> | 24 | #include <linux/mutex.h> |
26 | 25 | ||
diff --git a/include/scsi/sg_request.h b/include/scsi/sg_request.h deleted file mode 100644 index 57ff525bdd3b..000000000000 --- a/include/scsi/sg_request.h +++ /dev/null | |||
@@ -1,26 +0,0 @@ | |||
1 | typedef struct scsi_request Scsi_Request; | ||
2 | |||
3 | static Scsi_Request *dummy_cmdp; /* only used for sizeof */ | ||
4 | |||
5 | typedef struct sg_scatter_hold { /* holding area for scsi scatter gather info */ | ||
6 | unsigned short k_use_sg; /* Count of kernel scatter-gather pieces */ | ||
7 | unsigned short sglist_len; /* size of malloc'd scatter-gather list ++ */ | ||
8 | unsigned bufflen; /* Size of (aggregate) data buffer */ | ||
9 | unsigned b_malloc_len; /* actual len malloc'ed in buffer */ | ||
10 | void *buffer; /* Data buffer or scatter list (k_use_sg>0) */ | ||
11 | char dio_in_use; /* 0->indirect IO (or mmap), 1->dio */ | ||
12 | unsigned char cmd_opcode; /* first byte of command */ | ||
13 | } Sg_scatter_hold; | ||
14 | |||
15 | typedef struct sg_request { /* SG_MAX_QUEUE requests outstanding per file */ | ||
16 | Scsi_Request *my_cmdp; /* != 0 when request with lower levels */ | ||
17 | struct sg_request *nextrp; /* NULL -> tail request (slist) */ | ||
18 | struct sg_fd *parentfp; /* NULL -> not in use */ | ||
19 | Sg_scatter_hold data; /* hold buffer, perhaps scatter list */ | ||
20 | sg_io_hdr_t header; /* scsi command+info, see <scsi/sg.h> */ | ||
21 | unsigned char sense_b[sizeof (dummy_cmdp->sr_sense_buffer)]; | ||
22 | char res_used; /* 1 -> using reserve buffer, 0 -> not ... */ | ||
23 | char orphan; /* 1 -> drop on sight, 0 -> normal */ | ||
24 | char sg_io_owned; /* 1 -> packet belongs to SG_IO */ | ||
25 | volatile char done; /* 0->before bh, 1->before read, 2->read */ | ||
26 | } Sg_request; | ||
diff --git a/include/scsi/srp.h b/include/scsi/srp.h index 637f77eccf0c..ad178fa78f66 100644 --- a/include/scsi/srp.h +++ b/include/scsi/srp.h | |||
@@ -87,6 +87,11 @@ enum srp_login_rej_reason { | |||
87 | SRP_LOGIN_REJ_CHANNEL_LIMIT_REACHED = 0x00010006 | 87 | SRP_LOGIN_REJ_CHANNEL_LIMIT_REACHED = 0x00010006 |
88 | }; | 88 | }; |
89 | 89 | ||
90 | enum { | ||
91 | SRP_REV10_IB_IO_CLASS = 0xff00, | ||
92 | SRP_REV16A_IB_IO_CLASS = 0x0100 | ||
93 | }; | ||
94 | |||
90 | struct srp_direct_buf { | 95 | struct srp_direct_buf { |
91 | __be64 va; | 96 | __be64 va; |
92 | __be32 key; | 97 | __be32 key; |
diff --git a/include/sound/ac97_codec.h b/include/sound/ac97_codec.h index b45a73712748..446afc3ea27f 100644 --- a/include/sound/ac97_codec.h +++ b/include/sound/ac97_codec.h | |||
@@ -378,6 +378,7 @@ | |||
378 | #define AC97_HAS_NO_MIC (1<<15) /* no MIC volume */ | 378 | #define AC97_HAS_NO_MIC (1<<15) /* no MIC volume */ |
379 | #define AC97_HAS_NO_TONE (1<<16) /* no Tone volume */ | 379 | #define AC97_HAS_NO_TONE (1<<16) /* no Tone volume */ |
380 | #define AC97_HAS_NO_STD_PCM (1<<17) /* no standard AC97 PCM volume and mute */ | 380 | #define AC97_HAS_NO_STD_PCM (1<<17) /* no standard AC97 PCM volume and mute */ |
381 | #define AC97_HAS_NO_AUX (1<<18) /* no standard AC97 AUX volume and mute */ | ||
381 | 382 | ||
382 | /* rates indexes */ | 383 | /* rates indexes */ |
383 | #define AC97_RATES_FRONT_DAC 0 | 384 | #define AC97_RATES_FRONT_DAC 0 |
diff --git a/include/sound/asequencer.h b/include/sound/asequencer.h index 6691e4aa4ea7..3f2f4042a20d 100644 --- a/include/sound/asequencer.h +++ b/include/sound/asequencer.h | |||
@@ -605,6 +605,10 @@ struct snd_seq_remove_events { | |||
605 | #define SNDRV_SEQ_PORT_TYPE_DIRECT_SAMPLE (1<<11) /* Sampling device (support sample download) */ | 605 | #define SNDRV_SEQ_PORT_TYPE_DIRECT_SAMPLE (1<<11) /* Sampling device (support sample download) */ |
606 | #define SNDRV_SEQ_PORT_TYPE_SAMPLE (1<<12) /* Sampling device (sample can be downloaded at any time) */ | 606 | #define SNDRV_SEQ_PORT_TYPE_SAMPLE (1<<12) /* Sampling device (sample can be downloaded at any time) */ |
607 | /*...*/ | 607 | /*...*/ |
608 | #define SNDRV_SEQ_PORT_TYPE_HARDWARE (1<<16) /* driver for a hardware device */ | ||
609 | #define SNDRV_SEQ_PORT_TYPE_SOFTWARE (1<<17) /* implemented in software */ | ||
610 | #define SNDRV_SEQ_PORT_TYPE_SYNTHESIZER (1<<18) /* generates sound */ | ||
611 | #define SNDRV_SEQ_PORT_TYPE_PORT (1<<19) /* connects to other device(s) */ | ||
608 | #define SNDRV_SEQ_PORT_TYPE_APPLICATION (1<<20) /* application (sequencer/editor) */ | 612 | #define SNDRV_SEQ_PORT_TYPE_APPLICATION (1<<20) /* application (sequencer/editor) */ |
609 | 613 | ||
610 | /* misc. conditioning flags */ | 614 | /* misc. conditioning flags */ |
diff --git a/include/sound/asound.h b/include/sound/asound.h index 9cc021c7ee11..41885f48ad91 100644 --- a/include/sound/asound.h +++ b/include/sound/asound.h | |||
@@ -137,7 +137,7 @@ enum { | |||
137 | * * | 137 | * * |
138 | *****************************************************************************/ | 138 | *****************************************************************************/ |
139 | 139 | ||
140 | #define SNDRV_PCM_VERSION SNDRV_PROTOCOL_VERSION(2, 0, 7) | 140 | #define SNDRV_PCM_VERSION SNDRV_PROTOCOL_VERSION(2, 0, 8) |
141 | 141 | ||
142 | typedef unsigned long snd_pcm_uframes_t; | 142 | typedef unsigned long snd_pcm_uframes_t; |
143 | typedef signed long snd_pcm_sframes_t; | 143 | typedef signed long snd_pcm_sframes_t; |
diff --git a/include/sound/core.h b/include/sound/core.h index 5135147f20e8..5d184be0ff72 100644 --- a/include/sound/core.h +++ b/include/sound/core.h | |||
@@ -233,9 +233,8 @@ int copy_from_user_toio(volatile void __iomem *dst, const void __user *src, size | |||
233 | 233 | ||
234 | /* init.c */ | 234 | /* init.c */ |
235 | 235 | ||
236 | extern unsigned int snd_cards_lock; | ||
237 | extern struct snd_card *snd_cards[SNDRV_CARDS]; | 236 | extern struct snd_card *snd_cards[SNDRV_CARDS]; |
238 | extern rwlock_t snd_card_rwlock; | 237 | int snd_card_locked(int card); |
239 | #if defined(CONFIG_SND_MIXER_OSS) || defined(CONFIG_SND_MIXER_OSS_MODULE) | 238 | #if defined(CONFIG_SND_MIXER_OSS) || defined(CONFIG_SND_MIXER_OSS_MODULE) |
240 | #define SND_MIXER_OSS_NOTIFY_REGISTER 0 | 239 | #define SND_MIXER_OSS_NOTIFY_REGISTER 0 |
241 | #define SND_MIXER_OSS_NOTIFY_DISCONNECT 1 | 240 | #define SND_MIXER_OSS_NOTIFY_DISCONNECT 1 |
diff --git a/include/sound/driver.h b/include/sound/driver.h index 89c6a73f3920..3c522e59a33c 100644 --- a/include/sound/driver.h +++ b/include/sound/driver.h | |||
@@ -26,7 +26,6 @@ | |||
26 | #include "config.h" | 26 | #include "config.h" |
27 | #endif | 27 | #endif |
28 | 28 | ||
29 | #include <linux/config.h> | ||
30 | 29 | ||
31 | /* number of supported soundcards */ | 30 | /* number of supported soundcards */ |
32 | #ifdef CONFIG_SND_DYNAMIC_MINORS | 31 | #ifdef CONFIG_SND_DYNAMIC_MINORS |
diff --git a/include/sound/emu10k1.h b/include/sound/emu10k1.h index 186e00ad9e79..884bbf54cd36 100644 --- a/include/sound/emu10k1.h +++ b/include/sound/emu10k1.h | |||
@@ -245,6 +245,7 @@ | |||
245 | #define A_IOCFG_GPOUT0 0x0044 /* analog/digital */ | 245 | #define A_IOCFG_GPOUT0 0x0044 /* analog/digital */ |
246 | #define A_IOCFG_DISABLE_ANALOG 0x0040 /* = 'enable' for Audigy2 (chiprev=4) */ | 246 | #define A_IOCFG_DISABLE_ANALOG 0x0040 /* = 'enable' for Audigy2 (chiprev=4) */ |
247 | #define A_IOCFG_ENABLE_DIGITAL 0x0004 | 247 | #define A_IOCFG_ENABLE_DIGITAL 0x0004 |
248 | #define A_IOCFG_ENABLE_DIGITAL_AUDIGY4 0x0080 | ||
248 | #define A_IOCFG_UNKNOWN_20 0x0020 | 249 | #define A_IOCFG_UNKNOWN_20 0x0020 |
249 | #define A_IOCFG_DISABLE_AC97_FRONT 0x0080 /* turn off ac97 front -> front (10k2.1) */ | 250 | #define A_IOCFG_DISABLE_AC97_FRONT 0x0080 /* turn off ac97 front -> front (10k2.1) */ |
250 | #define A_IOCFG_GPOUT1 0x0002 /* IR? drive's internal bypass (?) */ | 251 | #define A_IOCFG_GPOUT1 0x0002 /* IR? drive's internal bypass (?) */ |
@@ -1065,6 +1066,7 @@ struct snd_emu_chip_details { | |||
1065 | unsigned char emu1212m; /* EMU 1212m card */ | 1066 | unsigned char emu1212m; /* EMU 1212m card */ |
1066 | unsigned char spi_dac; /* SPI interface for DAC */ | 1067 | unsigned char spi_dac; /* SPI interface for DAC */ |
1067 | unsigned char i2c_adc; /* I2C interface for ADC */ | 1068 | unsigned char i2c_adc; /* I2C interface for ADC */ |
1069 | unsigned char adc_1361t; /* Use Philips 1361T ADC */ | ||
1068 | const char *driver; | 1070 | const char *driver; |
1069 | const char *name; | 1071 | const char *name; |
1070 | const char *id; /* for backward compatibility - can be NULL if not needed */ | 1072 | const char *id; /* for backward compatibility - can be NULL if not needed */ |
diff --git a/include/sound/hdsp.h b/include/sound/hdsp.h index 25e1951a9955..dec6b1dc37ea 100644 --- a/include/sound/hdsp.h +++ b/include/sound/hdsp.h | |||
@@ -30,13 +30,13 @@ enum HDSP_IO_Type { | |||
30 | }; | 30 | }; |
31 | 31 | ||
32 | struct hdsp_peak_rms { | 32 | struct hdsp_peak_rms { |
33 | u32 input_peaks[26]; | 33 | __u32 input_peaks[26]; |
34 | u32 playback_peaks[26]; | 34 | __u32 playback_peaks[26]; |
35 | u32 output_peaks[28]; | 35 | __u32 output_peaks[28]; |
36 | u64 input_rms[26]; | 36 | __u64 input_rms[26]; |
37 | u64 playback_rms[26]; | 37 | __u64 playback_rms[26]; |
38 | /* These are only used for H96xx cards */ | 38 | /* These are only used for H96xx cards */ |
39 | u64 output_rms[26]; | 39 | __u64 output_rms[26]; |
40 | }; | 40 | }; |
41 | 41 | ||
42 | #define SNDRV_HDSP_IOCTL_GET_PEAK_RMS _IOR('H', 0x40, struct hdsp_peak_rms) | 42 | #define SNDRV_HDSP_IOCTL_GET_PEAK_RMS _IOR('H', 0x40, struct hdsp_peak_rms) |
diff --git a/include/sound/info.h b/include/sound/info.h index f23d8381c216..74f6996769c7 100644 --- a/include/sound/info.h +++ b/include/sound/info.h | |||
@@ -27,9 +27,9 @@ | |||
27 | /* buffer for information */ | 27 | /* buffer for information */ |
28 | struct snd_info_buffer { | 28 | struct snd_info_buffer { |
29 | char *buffer; /* pointer to begin of buffer */ | 29 | char *buffer; /* pointer to begin of buffer */ |
30 | char *curr; /* current position in buffer */ | 30 | unsigned int curr; /* current position in buffer */ |
31 | unsigned long size; /* current size */ | 31 | unsigned int size; /* current size */ |
32 | unsigned long len; /* total length of buffer */ | 32 | unsigned int len; /* total length of buffer */ |
33 | int stop; /* stop flag */ | 33 | int stop; /* stop flag */ |
34 | int error; /* error code */ | 34 | int error; /* error code */ |
35 | }; | 35 | }; |
@@ -40,8 +40,6 @@ struct snd_info_buffer { | |||
40 | struct snd_info_entry; | 40 | struct snd_info_entry; |
41 | 41 | ||
42 | struct snd_info_entry_text { | 42 | struct snd_info_entry_text { |
43 | unsigned long read_size; | ||
44 | unsigned long write_size; | ||
45 | void (*read) (struct snd_info_entry *entry, struct snd_info_buffer *buffer); | 43 | void (*read) (struct snd_info_entry *entry, struct snd_info_buffer *buffer); |
46 | void (*write) (struct snd_info_entry *entry, struct snd_info_buffer *buffer); | 44 | void (*write) (struct snd_info_entry *entry, struct snd_info_buffer *buffer); |
47 | }; | 45 | }; |
@@ -132,11 +130,9 @@ int snd_card_proc_new(struct snd_card *card, const char *name, struct snd_info_e | |||
132 | 130 | ||
133 | static inline void snd_info_set_text_ops(struct snd_info_entry *entry, | 131 | static inline void snd_info_set_text_ops(struct snd_info_entry *entry, |
134 | void *private_data, | 132 | void *private_data, |
135 | long read_size, | ||
136 | void (*read)(struct snd_info_entry *, struct snd_info_buffer *)) | 133 | void (*read)(struct snd_info_entry *, struct snd_info_buffer *)) |
137 | { | 134 | { |
138 | entry->private_data = private_data; | 135 | entry->private_data = private_data; |
139 | entry->c.text.read_size = read_size; | ||
140 | entry->c.text.read = read; | 136 | entry->c.text.read = read; |
141 | } | 137 | } |
142 | 138 | ||
@@ -167,7 +163,6 @@ static inline int snd_card_proc_new(struct snd_card *card, const char *name, | |||
167 | struct snd_info_entry **entryp) { return -EINVAL; } | 163 | struct snd_info_entry **entryp) { return -EINVAL; } |
168 | static inline void snd_info_set_text_ops(struct snd_info_entry *entry __attribute__((unused)), | 164 | static inline void snd_info_set_text_ops(struct snd_info_entry *entry __attribute__((unused)), |
169 | void *private_data, | 165 | void *private_data, |
170 | long read_size, | ||
171 | void (*read)(struct snd_info_entry *, struct snd_info_buffer *)) {} | 166 | void (*read)(struct snd_info_entry *, struct snd_info_buffer *)) {} |
172 | 167 | ||
173 | static inline int snd_info_check_reserved_words(const char *str) { return 1; } | 168 | static inline int snd_info_check_reserved_words(const char *str) { return 1; } |
diff --git a/include/sound/mpu401.h b/include/sound/mpu401.h index 8e97ace78f16..ac504321ea56 100644 --- a/include/sound/mpu401.h +++ b/include/sound/mpu401.h | |||
@@ -45,6 +45,12 @@ | |||
45 | #define MPU401_HW_PC98II 18 /* Roland PC98II */ | 45 | #define MPU401_HW_PC98II 18 /* Roland PC98II */ |
46 | #define MPU401_HW_AUREAL 19 /* Aureal Vortex */ | 46 | #define MPU401_HW_AUREAL 19 /* Aureal Vortex */ |
47 | 47 | ||
48 | #define MPU401_INFO_INPUT (1 << 0) /* input stream */ | ||
49 | #define MPU401_INFO_OUTPUT (1 << 1) /* output stream */ | ||
50 | #define MPU401_INFO_INTEGRATED (1 << 2) /* integrated h/w port */ | ||
51 | #define MPU401_INFO_MMIO (1 << 3) /* MMIO access */ | ||
52 | #define MPU401_INFO_TX_IRQ (1 << 4) /* independent TX irq */ | ||
53 | |||
48 | #define MPU401_MODE_BIT_INPUT 0 | 54 | #define MPU401_MODE_BIT_INPUT 0 |
49 | #define MPU401_MODE_BIT_OUTPUT 1 | 55 | #define MPU401_MODE_BIT_OUTPUT 1 |
50 | #define MPU401_MODE_BIT_INPUT_TRIGGER 2 | 56 | #define MPU401_MODE_BIT_INPUT_TRIGGER 2 |
@@ -62,6 +68,7 @@ struct snd_mpu401 { | |||
62 | struct snd_rawmidi *rmidi; | 68 | struct snd_rawmidi *rmidi; |
63 | 69 | ||
64 | unsigned short hardware; /* MPU401_HW_XXXX */ | 70 | unsigned short hardware; /* MPU401_HW_XXXX */ |
71 | unsigned int info_flags; /* MPU401_INFO_XXX */ | ||
65 | unsigned long port; /* base port of MPU-401 chip */ | 72 | unsigned long port; /* base port of MPU-401 chip */ |
66 | unsigned long cport; /* port + 1 (usually) */ | 73 | unsigned long cport; /* port + 1 (usually) */ |
67 | struct resource *res; /* port resource */ | 74 | struct resource *res; /* port resource */ |
@@ -99,13 +106,16 @@ struct snd_mpu401 { | |||
99 | 106 | ||
100 | */ | 107 | */ |
101 | 108 | ||
102 | irqreturn_t snd_mpu401_uart_interrupt(int irq, void *dev_id, struct pt_regs *regs); | 109 | irqreturn_t snd_mpu401_uart_interrupt(int irq, void *dev_id, |
110 | struct pt_regs *regs); | ||
111 | irqreturn_t snd_mpu401_uart_interrupt_tx(int irq, void *dev_id, | ||
112 | struct pt_regs *regs); | ||
103 | 113 | ||
104 | int snd_mpu401_uart_new(struct snd_card *card, | 114 | int snd_mpu401_uart_new(struct snd_card *card, |
105 | int device, | 115 | int device, |
106 | unsigned short hardware, | 116 | unsigned short hardware, |
107 | unsigned long port, | 117 | unsigned long port, |
108 | int integrated, | 118 | unsigned int info_flags, |
109 | int irq, | 119 | int irq, |
110 | int irq_flags, | 120 | int irq_flags, |
111 | struct snd_rawmidi ** rrawmidi); | 121 | struct snd_rawmidi ** rrawmidi); |
diff --git a/include/sound/pcm.h b/include/sound/pcm.h index 373425895faa..f84d84993a31 100644 --- a/include/sound/pcm.h +++ b/include/sound/pcm.h | |||
@@ -300,7 +300,6 @@ struct snd_pcm_runtime { | |||
300 | /* -- mmap -- */ | 300 | /* -- mmap -- */ |
301 | volatile struct snd_pcm_mmap_status *status; | 301 | volatile struct snd_pcm_mmap_status *status; |
302 | volatile struct snd_pcm_mmap_control *control; | 302 | volatile struct snd_pcm_mmap_control *control; |
303 | atomic_t mmap_count; | ||
304 | 303 | ||
305 | /* -- locking / scheduling -- */ | 304 | /* -- locking / scheduling -- */ |
306 | wait_queue_head_t sleep; | 305 | wait_queue_head_t sleep; |
@@ -368,7 +367,9 @@ struct snd_pcm_substream { | |||
368 | struct snd_pcm_group *group; /* pointer to current group */ | 367 | struct snd_pcm_group *group; /* pointer to current group */ |
369 | /* -- assigned files -- */ | 368 | /* -- assigned files -- */ |
370 | void *file; | 369 | void *file; |
371 | struct file *ffile; | 370 | int ref_count; |
371 | atomic_t mmap_count; | ||
372 | unsigned int f_flags; | ||
372 | void (*pcm_release)(struct snd_pcm_substream *); | 373 | void (*pcm_release)(struct snd_pcm_substream *); |
373 | #if defined(CONFIG_SND_PCM_OSS) || defined(CONFIG_SND_PCM_OSS_MODULE) | 374 | #if defined(CONFIG_SND_PCM_OSS) || defined(CONFIG_SND_PCM_OSS_MODULE) |
374 | /* -- OSS things -- */ | 375 | /* -- OSS things -- */ |
@@ -387,7 +388,7 @@ struct snd_pcm_substream { | |||
387 | unsigned int hw_opened: 1; | 388 | unsigned int hw_opened: 1; |
388 | }; | 389 | }; |
389 | 390 | ||
390 | #define SUBSTREAM_BUSY(substream) ((substream)->file != NULL) | 391 | #define SUBSTREAM_BUSY(substream) ((substream)->ref_count > 0) |
391 | 392 | ||
392 | 393 | ||
393 | struct snd_pcm_str { | 394 | struct snd_pcm_str { |
@@ -825,14 +826,6 @@ int snd_interval_ratnum(struct snd_interval *i, | |||
825 | 826 | ||
826 | void _snd_pcm_hw_params_any(struct snd_pcm_hw_params *params); | 827 | void _snd_pcm_hw_params_any(struct snd_pcm_hw_params *params); |
827 | void _snd_pcm_hw_param_setempty(struct snd_pcm_hw_params *params, snd_pcm_hw_param_t var); | 828 | void _snd_pcm_hw_param_setempty(struct snd_pcm_hw_params *params, snd_pcm_hw_param_t var); |
828 | int snd_pcm_hw_param_near(struct snd_pcm_substream *substream, | ||
829 | struct snd_pcm_hw_params *params, | ||
830 | snd_pcm_hw_param_t var, | ||
831 | unsigned int val, int *dir); | ||
832 | int snd_pcm_hw_param_set(struct snd_pcm_substream *pcm, | ||
833 | struct snd_pcm_hw_params *params, | ||
834 | snd_pcm_hw_param_t var, | ||
835 | unsigned int val, int dir); | ||
836 | int snd_pcm_hw_params_choose(struct snd_pcm_substream *substream, struct snd_pcm_hw_params *params); | 829 | int snd_pcm_hw_params_choose(struct snd_pcm_substream *substream, struct snd_pcm_hw_params *params); |
837 | 830 | ||
838 | int snd_pcm_hw_refine(struct snd_pcm_substream *substream, struct snd_pcm_hw_params *params); | 831 | int snd_pcm_hw_refine(struct snd_pcm_substream *substream, struct snd_pcm_hw_params *params); |
@@ -979,13 +972,13 @@ struct page *snd_pcm_sgbuf_ops_page(struct snd_pcm_substream *substream, unsigne | |||
979 | static inline void snd_pcm_mmap_data_open(struct vm_area_struct *area) | 972 | static inline void snd_pcm_mmap_data_open(struct vm_area_struct *area) |
980 | { | 973 | { |
981 | struct snd_pcm_substream *substream = (struct snd_pcm_substream *)area->vm_private_data; | 974 | struct snd_pcm_substream *substream = (struct snd_pcm_substream *)area->vm_private_data; |
982 | atomic_inc(&substream->runtime->mmap_count); | 975 | atomic_inc(&substream->mmap_count); |
983 | } | 976 | } |
984 | 977 | ||
985 | static inline void snd_pcm_mmap_data_close(struct vm_area_struct *area) | 978 | static inline void snd_pcm_mmap_data_close(struct vm_area_struct *area) |
986 | { | 979 | { |
987 | struct snd_pcm_substream *substream = (struct snd_pcm_substream *)area->vm_private_data; | 980 | struct snd_pcm_substream *substream = (struct snd_pcm_substream *)area->vm_private_data; |
988 | atomic_dec(&substream->runtime->mmap_count); | 981 | atomic_dec(&substream->mmap_count); |
989 | } | 982 | } |
990 | 983 | ||
991 | /* mmap for io-memory area */ | 984 | /* mmap for io-memory area */ |
diff --git a/include/sound/pcm_params.h b/include/sound/pcm_params.h index fb18aef77341..85cf1cf4f31a 100644 --- a/include/sound/pcm_params.h +++ b/include/sound/pcm_params.h | |||
@@ -22,29 +22,21 @@ | |||
22 | * | 22 | * |
23 | */ | 23 | */ |
24 | 24 | ||
25 | extern int snd_pcm_hw_param_mask(struct snd_pcm_substream *pcm, struct snd_pcm_hw_params *params, | 25 | int snd_pcm_hw_param_first(struct snd_pcm_substream *pcm, |
26 | snd_pcm_hw_param_t var, const struct snd_mask *val); | 26 | struct snd_pcm_hw_params *params, |
27 | extern unsigned int snd_pcm_hw_param_value_min(const struct snd_pcm_hw_params *params, | 27 | snd_pcm_hw_param_t var, int *dir); |
28 | snd_pcm_hw_param_t var, int *dir); | 28 | int snd_pcm_hw_param_last(struct snd_pcm_substream *pcm, |
29 | extern unsigned int snd_pcm_hw_param_value_max(const struct snd_pcm_hw_params *params, | 29 | struct snd_pcm_hw_params *params, |
30 | snd_pcm_hw_param_t var, int *dir); | 30 | snd_pcm_hw_param_t var, int *dir); |
31 | extern int _snd_pcm_hw_param_min(struct snd_pcm_hw_params *params, | 31 | int snd_pcm_hw_param_value(const struct snd_pcm_hw_params *params, |
32 | snd_pcm_hw_param_t var, unsigned int val, int dir); | 32 | snd_pcm_hw_param_t var, int *dir); |
33 | extern int _snd_pcm_hw_param_setinteger(struct snd_pcm_hw_params *params, | ||
34 | snd_pcm_hw_param_t var); | ||
35 | extern int _snd_pcm_hw_param_set(struct snd_pcm_hw_params *params, | ||
36 | snd_pcm_hw_param_t var, unsigned int val, int dir); | ||
37 | |||
38 | /* To share the same code we have alsa-lib */ | ||
39 | #define INLINE static inline | ||
40 | #define assert(a) (void)(a) | ||
41 | 33 | ||
42 | #define SNDRV_MASK_BITS 64 /* we use so far 64bits only */ | 34 | #define SNDRV_MASK_BITS 64 /* we use so far 64bits only */ |
43 | #define SNDRV_MASK_SIZE (SNDRV_MASK_BITS / 32) | 35 | #define SNDRV_MASK_SIZE (SNDRV_MASK_BITS / 32) |
44 | #define MASK_OFS(i) ((i) >> 5) | 36 | #define MASK_OFS(i) ((i) >> 5) |
45 | #define MASK_BIT(i) (1U << ((i) & 31)) | 37 | #define MASK_BIT(i) (1U << ((i) & 31)) |
46 | 38 | ||
47 | INLINE unsigned int ld2(u_int32_t v) | 39 | static inline unsigned int ld2(u_int32_t v) |
48 | { | 40 | { |
49 | unsigned r = 0; | 41 | unsigned r = 0; |
50 | 42 | ||
@@ -69,22 +61,22 @@ INLINE unsigned int ld2(u_int32_t v) | |||
69 | return r; | 61 | return r; |
70 | } | 62 | } |
71 | 63 | ||
72 | INLINE size_t snd_mask_sizeof(void) | 64 | static inline size_t snd_mask_sizeof(void) |
73 | { | 65 | { |
74 | return sizeof(struct snd_mask); | 66 | return sizeof(struct snd_mask); |
75 | } | 67 | } |
76 | 68 | ||
77 | INLINE void snd_mask_none(struct snd_mask *mask) | 69 | static inline void snd_mask_none(struct snd_mask *mask) |
78 | { | 70 | { |
79 | memset(mask, 0, sizeof(*mask)); | 71 | memset(mask, 0, sizeof(*mask)); |
80 | } | 72 | } |
81 | 73 | ||
82 | INLINE void snd_mask_any(struct snd_mask *mask) | 74 | static inline void snd_mask_any(struct snd_mask *mask) |
83 | { | 75 | { |
84 | memset(mask, 0xff, SNDRV_MASK_SIZE * sizeof(u_int32_t)); | 76 | memset(mask, 0xff, SNDRV_MASK_SIZE * sizeof(u_int32_t)); |
85 | } | 77 | } |
86 | 78 | ||
87 | INLINE int snd_mask_empty(const struct snd_mask *mask) | 79 | static inline int snd_mask_empty(const struct snd_mask *mask) |
88 | { | 80 | { |
89 | int i; | 81 | int i; |
90 | for (i = 0; i < SNDRV_MASK_SIZE; i++) | 82 | for (i = 0; i < SNDRV_MASK_SIZE; i++) |
@@ -93,10 +85,9 @@ INLINE int snd_mask_empty(const struct snd_mask *mask) | |||
93 | return 1; | 85 | return 1; |
94 | } | 86 | } |
95 | 87 | ||
96 | INLINE unsigned int snd_mask_min(const struct snd_mask *mask) | 88 | static inline unsigned int snd_mask_min(const struct snd_mask *mask) |
97 | { | 89 | { |
98 | int i; | 90 | int i; |
99 | assert(!snd_mask_empty(mask)); | ||
100 | for (i = 0; i < SNDRV_MASK_SIZE; i++) { | 91 | for (i = 0; i < SNDRV_MASK_SIZE; i++) { |
101 | if (mask->bits[i]) | 92 | if (mask->bits[i]) |
102 | return ffs(mask->bits[i]) - 1 + (i << 5); | 93 | return ffs(mask->bits[i]) - 1 + (i << 5); |
@@ -104,10 +95,9 @@ INLINE unsigned int snd_mask_min(const struct snd_mask *mask) | |||
104 | return 0; | 95 | return 0; |
105 | } | 96 | } |
106 | 97 | ||
107 | INLINE unsigned int snd_mask_max(const struct snd_mask *mask) | 98 | static inline unsigned int snd_mask_max(const struct snd_mask *mask) |
108 | { | 99 | { |
109 | int i; | 100 | int i; |
110 | assert(!snd_mask_empty(mask)); | ||
111 | for (i = SNDRV_MASK_SIZE - 1; i >= 0; i--) { | 101 | for (i = SNDRV_MASK_SIZE - 1; i >= 0; i--) { |
112 | if (mask->bits[i]) | 102 | if (mask->bits[i]) |
113 | return ld2(mask->bits[i]) + (i << 5); | 103 | return ld2(mask->bits[i]) + (i << 5); |
@@ -115,70 +105,68 @@ INLINE unsigned int snd_mask_max(const struct snd_mask *mask) | |||
115 | return 0; | 105 | return 0; |
116 | } | 106 | } |
117 | 107 | ||
118 | INLINE void snd_mask_set(struct snd_mask *mask, unsigned int val) | 108 | static inline void snd_mask_set(struct snd_mask *mask, unsigned int val) |
119 | { | 109 | { |
120 | assert(val <= SNDRV_MASK_BITS); | ||
121 | mask->bits[MASK_OFS(val)] |= MASK_BIT(val); | 110 | mask->bits[MASK_OFS(val)] |= MASK_BIT(val); |
122 | } | 111 | } |
123 | 112 | ||
124 | INLINE void snd_mask_reset(struct snd_mask *mask, unsigned int val) | 113 | static inline void snd_mask_reset(struct snd_mask *mask, unsigned int val) |
125 | { | 114 | { |
126 | assert(val <= SNDRV_MASK_BITS); | ||
127 | mask->bits[MASK_OFS(val)] &= ~MASK_BIT(val); | 115 | mask->bits[MASK_OFS(val)] &= ~MASK_BIT(val); |
128 | } | 116 | } |
129 | 117 | ||
130 | INLINE void snd_mask_set_range(struct snd_mask *mask, unsigned int from, unsigned int to) | 118 | static inline void snd_mask_set_range(struct snd_mask *mask, |
119 | unsigned int from, unsigned int to) | ||
131 | { | 120 | { |
132 | unsigned int i; | 121 | unsigned int i; |
133 | assert(to <= SNDRV_MASK_BITS && from <= to); | ||
134 | for (i = from; i <= to; i++) | 122 | for (i = from; i <= to; i++) |
135 | mask->bits[MASK_OFS(i)] |= MASK_BIT(i); | 123 | mask->bits[MASK_OFS(i)] |= MASK_BIT(i); |
136 | } | 124 | } |
137 | 125 | ||
138 | INLINE void snd_mask_reset_range(struct snd_mask *mask, unsigned int from, unsigned int to) | 126 | static inline void snd_mask_reset_range(struct snd_mask *mask, |
127 | unsigned int from, unsigned int to) | ||
139 | { | 128 | { |
140 | unsigned int i; | 129 | unsigned int i; |
141 | assert(to <= SNDRV_MASK_BITS && from <= to); | ||
142 | for (i = from; i <= to; i++) | 130 | for (i = from; i <= to; i++) |
143 | mask->bits[MASK_OFS(i)] &= ~MASK_BIT(i); | 131 | mask->bits[MASK_OFS(i)] &= ~MASK_BIT(i); |
144 | } | 132 | } |
145 | 133 | ||
146 | INLINE void snd_mask_leave(struct snd_mask *mask, unsigned int val) | 134 | static inline void snd_mask_leave(struct snd_mask *mask, unsigned int val) |
147 | { | 135 | { |
148 | unsigned int v; | 136 | unsigned int v; |
149 | assert(val <= SNDRV_MASK_BITS); | ||
150 | v = mask->bits[MASK_OFS(val)] & MASK_BIT(val); | 137 | v = mask->bits[MASK_OFS(val)] & MASK_BIT(val); |
151 | snd_mask_none(mask); | 138 | snd_mask_none(mask); |
152 | mask->bits[MASK_OFS(val)] = v; | 139 | mask->bits[MASK_OFS(val)] = v; |
153 | } | 140 | } |
154 | 141 | ||
155 | INLINE void snd_mask_intersect(struct snd_mask *mask, const struct snd_mask *v) | 142 | static inline void snd_mask_intersect(struct snd_mask *mask, |
143 | const struct snd_mask *v) | ||
156 | { | 144 | { |
157 | int i; | 145 | int i; |
158 | for (i = 0; i < SNDRV_MASK_SIZE; i++) | 146 | for (i = 0; i < SNDRV_MASK_SIZE; i++) |
159 | mask->bits[i] &= v->bits[i]; | 147 | mask->bits[i] &= v->bits[i]; |
160 | } | 148 | } |
161 | 149 | ||
162 | INLINE int snd_mask_eq(const struct snd_mask *mask, const struct snd_mask *v) | 150 | static inline int snd_mask_eq(const struct snd_mask *mask, |
151 | const struct snd_mask *v) | ||
163 | { | 152 | { |
164 | return ! memcmp(mask, v, SNDRV_MASK_SIZE * sizeof(u_int32_t)); | 153 | return ! memcmp(mask, v, SNDRV_MASK_SIZE * sizeof(u_int32_t)); |
165 | } | 154 | } |
166 | 155 | ||
167 | INLINE void snd_mask_copy(struct snd_mask *mask, const struct snd_mask *v) | 156 | static inline void snd_mask_copy(struct snd_mask *mask, |
157 | const struct snd_mask *v) | ||
168 | { | 158 | { |
169 | *mask = *v; | 159 | *mask = *v; |
170 | } | 160 | } |
171 | 161 | ||
172 | INLINE int snd_mask_test(const struct snd_mask *mask, unsigned int val) | 162 | static inline int snd_mask_test(const struct snd_mask *mask, unsigned int val) |
173 | { | 163 | { |
174 | assert(val <= SNDRV_MASK_BITS); | ||
175 | return mask->bits[MASK_OFS(val)] & MASK_BIT(val); | 164 | return mask->bits[MASK_OFS(val)] & MASK_BIT(val); |
176 | } | 165 | } |
177 | 166 | ||
178 | INLINE int snd_mask_single(const struct snd_mask *mask) | 167 | static inline int snd_mask_single(const struct snd_mask *mask) |
179 | { | 168 | { |
180 | int i, c = 0; | 169 | int i, c = 0; |
181 | assert(!snd_mask_empty(mask)); | ||
182 | for (i = 0; i < SNDRV_MASK_SIZE; i++) { | 170 | for (i = 0; i < SNDRV_MASK_SIZE; i++) { |
183 | if (! mask->bits[i]) | 171 | if (! mask->bits[i]) |
184 | continue; | 172 | continue; |
@@ -191,10 +179,10 @@ INLINE int snd_mask_single(const struct snd_mask *mask) | |||
191 | return 1; | 179 | return 1; |
192 | } | 180 | } |
193 | 181 | ||
194 | INLINE int snd_mask_refine(struct snd_mask *mask, const struct snd_mask *v) | 182 | static inline int snd_mask_refine(struct snd_mask *mask, |
183 | const struct snd_mask *v) | ||
195 | { | 184 | { |
196 | struct snd_mask old; | 185 | struct snd_mask old; |
197 | assert(!snd_mask_empty(mask)); | ||
198 | snd_mask_copy(&old, mask); | 186 | snd_mask_copy(&old, mask); |
199 | snd_mask_intersect(mask, v); | 187 | snd_mask_intersect(mask, v); |
200 | if (snd_mask_empty(mask)) | 188 | if (snd_mask_empty(mask)) |
@@ -202,27 +190,24 @@ INLINE int snd_mask_refine(struct snd_mask *mask, const struct snd_mask *v) | |||
202 | return !snd_mask_eq(mask, &old); | 190 | return !snd_mask_eq(mask, &old); |
203 | } | 191 | } |
204 | 192 | ||
205 | INLINE int snd_mask_refine_first(struct snd_mask *mask) | 193 | static inline int snd_mask_refine_first(struct snd_mask *mask) |
206 | { | 194 | { |
207 | assert(!snd_mask_empty(mask)); | ||
208 | if (snd_mask_single(mask)) | 195 | if (snd_mask_single(mask)) |
209 | return 0; | 196 | return 0; |
210 | snd_mask_leave(mask, snd_mask_min(mask)); | 197 | snd_mask_leave(mask, snd_mask_min(mask)); |
211 | return 1; | 198 | return 1; |
212 | } | 199 | } |
213 | 200 | ||
214 | INLINE int snd_mask_refine_last(struct snd_mask *mask) | 201 | static inline int snd_mask_refine_last(struct snd_mask *mask) |
215 | { | 202 | { |
216 | assert(!snd_mask_empty(mask)); | ||
217 | if (snd_mask_single(mask)) | 203 | if (snd_mask_single(mask)) |
218 | return 0; | 204 | return 0; |
219 | snd_mask_leave(mask, snd_mask_max(mask)); | 205 | snd_mask_leave(mask, snd_mask_max(mask)); |
220 | return 1; | 206 | return 1; |
221 | } | 207 | } |
222 | 208 | ||
223 | INLINE int snd_mask_refine_min(struct snd_mask *mask, unsigned int val) | 209 | static inline int snd_mask_refine_min(struct snd_mask *mask, unsigned int val) |
224 | { | 210 | { |
225 | assert(!snd_mask_empty(mask)); | ||
226 | if (snd_mask_min(mask) >= val) | 211 | if (snd_mask_min(mask) >= val) |
227 | return 0; | 212 | return 0; |
228 | snd_mask_reset_range(mask, 0, val - 1); | 213 | snd_mask_reset_range(mask, 0, val - 1); |
@@ -231,9 +216,8 @@ INLINE int snd_mask_refine_min(struct snd_mask *mask, unsigned int val) | |||
231 | return 1; | 216 | return 1; |
232 | } | 217 | } |
233 | 218 | ||
234 | INLINE int snd_mask_refine_max(struct snd_mask *mask, unsigned int val) | 219 | static inline int snd_mask_refine_max(struct snd_mask *mask, unsigned int val) |
235 | { | 220 | { |
236 | assert(!snd_mask_empty(mask)); | ||
237 | if (snd_mask_max(mask) <= val) | 221 | if (snd_mask_max(mask) <= val) |
238 | return 0; | 222 | return 0; |
239 | snd_mask_reset_range(mask, val + 1, SNDRV_MASK_BITS); | 223 | snd_mask_reset_range(mask, val + 1, SNDRV_MASK_BITS); |
@@ -242,10 +226,9 @@ INLINE int snd_mask_refine_max(struct snd_mask *mask, unsigned int val) | |||
242 | return 1; | 226 | return 1; |
243 | } | 227 | } |
244 | 228 | ||
245 | INLINE int snd_mask_refine_set(struct snd_mask *mask, unsigned int val) | 229 | static inline int snd_mask_refine_set(struct snd_mask *mask, unsigned int val) |
246 | { | 230 | { |
247 | int changed; | 231 | int changed; |
248 | assert(!snd_mask_empty(mask)); | ||
249 | changed = !snd_mask_single(mask); | 232 | changed = !snd_mask_single(mask); |
250 | snd_mask_leave(mask, val); | 233 | snd_mask_leave(mask, val); |
251 | if (snd_mask_empty(mask)) | 234 | if (snd_mask_empty(mask)) |
@@ -253,13 +236,12 @@ INLINE int snd_mask_refine_set(struct snd_mask *mask, unsigned int val) | |||
253 | return changed; | 236 | return changed; |
254 | } | 237 | } |
255 | 238 | ||
256 | INLINE int snd_mask_value(const struct snd_mask *mask) | 239 | static inline int snd_mask_value(const struct snd_mask *mask) |
257 | { | 240 | { |
258 | assert(!snd_mask_empty(mask)); | ||
259 | return snd_mask_min(mask); | 241 | return snd_mask_min(mask); |
260 | } | 242 | } |
261 | 243 | ||
262 | INLINE void snd_interval_any(struct snd_interval *i) | 244 | static inline void snd_interval_any(struct snd_interval *i) |
263 | { | 245 | { |
264 | i->min = 0; | 246 | i->min = 0; |
265 | i->openmin = 0; | 247 | i->openmin = 0; |
@@ -269,63 +251,59 @@ INLINE void snd_interval_any(struct snd_interval *i) | |||
269 | i->empty = 0; | 251 | i->empty = 0; |
270 | } | 252 | } |
271 | 253 | ||
272 | INLINE void snd_interval_none(struct snd_interval *i) | 254 | static inline void snd_interval_none(struct snd_interval *i) |
273 | { | 255 | { |
274 | i->empty = 1; | 256 | i->empty = 1; |
275 | } | 257 | } |
276 | 258 | ||
277 | INLINE int snd_interval_checkempty(const struct snd_interval *i) | 259 | static inline int snd_interval_checkempty(const struct snd_interval *i) |
278 | { | 260 | { |
279 | return (i->min > i->max || | 261 | return (i->min > i->max || |
280 | (i->min == i->max && (i->openmin || i->openmax))); | 262 | (i->min == i->max && (i->openmin || i->openmax))); |
281 | } | 263 | } |
282 | 264 | ||
283 | INLINE int snd_interval_empty(const struct snd_interval *i) | 265 | static inline int snd_interval_empty(const struct snd_interval *i) |
284 | { | 266 | { |
285 | return i->empty; | 267 | return i->empty; |
286 | } | 268 | } |
287 | 269 | ||
288 | INLINE int snd_interval_single(const struct snd_interval *i) | 270 | static inline int snd_interval_single(const struct snd_interval *i) |
289 | { | 271 | { |
290 | assert(!snd_interval_empty(i)); | ||
291 | return (i->min == i->max || | 272 | return (i->min == i->max || |
292 | (i->min + 1 == i->max && i->openmax)); | 273 | (i->min + 1 == i->max && i->openmax)); |
293 | } | 274 | } |
294 | 275 | ||
295 | INLINE int snd_interval_value(const struct snd_interval *i) | 276 | static inline int snd_interval_value(const struct snd_interval *i) |
296 | { | 277 | { |
297 | assert(snd_interval_single(i)); | ||
298 | return i->min; | 278 | return i->min; |
299 | } | 279 | } |
300 | 280 | ||
301 | INLINE int snd_interval_min(const struct snd_interval *i) | 281 | static inline int snd_interval_min(const struct snd_interval *i) |
302 | { | 282 | { |
303 | assert(!snd_interval_empty(i)); | ||
304 | return i->min; | 283 | return i->min; |
305 | } | 284 | } |
306 | 285 | ||
307 | INLINE int snd_interval_max(const struct snd_interval *i) | 286 | static inline int snd_interval_max(const struct snd_interval *i) |
308 | { | 287 | { |
309 | unsigned int v; | 288 | unsigned int v; |
310 | assert(!snd_interval_empty(i)); | ||
311 | v = i->max; | 289 | v = i->max; |
312 | if (i->openmax) | 290 | if (i->openmax) |
313 | v--; | 291 | v--; |
314 | return v; | 292 | return v; |
315 | } | 293 | } |
316 | 294 | ||
317 | INLINE int snd_interval_test(const struct snd_interval *i, unsigned int val) | 295 | static inline int snd_interval_test(const struct snd_interval *i, unsigned int val) |
318 | { | 296 | { |
319 | return !((i->min > val || (i->min == val && i->openmin) || | 297 | return !((i->min > val || (i->min == val && i->openmin) || |
320 | i->max < val || (i->max == val && i->openmax))); | 298 | i->max < val || (i->max == val && i->openmax))); |
321 | } | 299 | } |
322 | 300 | ||
323 | INLINE void snd_interval_copy(struct snd_interval *d, const struct snd_interval *s) | 301 | static inline void snd_interval_copy(struct snd_interval *d, const struct snd_interval *s) |
324 | { | 302 | { |
325 | *d = *s; | 303 | *d = *s; |
326 | } | 304 | } |
327 | 305 | ||
328 | INLINE int snd_interval_setinteger(struct snd_interval *i) | 306 | static inline int snd_interval_setinteger(struct snd_interval *i) |
329 | { | 307 | { |
330 | if (i->integer) | 308 | if (i->integer) |
331 | return 0; | 309 | return 0; |
@@ -335,7 +313,7 @@ INLINE int snd_interval_setinteger(struct snd_interval *i) | |||
335 | return 1; | 313 | return 1; |
336 | } | 314 | } |
337 | 315 | ||
338 | INLINE int snd_interval_eq(const struct snd_interval *i1, const struct snd_interval *i2) | 316 | static inline int snd_interval_eq(const struct snd_interval *i1, const struct snd_interval *i2) |
339 | { | 317 | { |
340 | if (i1->empty) | 318 | if (i1->empty) |
341 | return i2->empty; | 319 | return i2->empty; |
@@ -359,8 +337,5 @@ static inline unsigned int sub(unsigned int a, unsigned int b) | |||
359 | return 0; | 337 | return 0; |
360 | } | 338 | } |
361 | 339 | ||
362 | #undef INLINE | ||
363 | #undef assert | ||
364 | |||
365 | #endif /* __SOUND_PCM_PARAMS_H */ | 340 | #endif /* __SOUND_PCM_PARAMS_H */ |
366 | 341 | ||
diff --git a/include/sound/rawmidi.h b/include/sound/rawmidi.h index 584e73dd4793..7dbcd10fa215 100644 --- a/include/sound/rawmidi.h +++ b/include/sound/rawmidi.h | |||
@@ -46,6 +46,7 @@ | |||
46 | 46 | ||
47 | struct snd_rawmidi; | 47 | struct snd_rawmidi; |
48 | struct snd_rawmidi_substream; | 48 | struct snd_rawmidi_substream; |
49 | struct snd_seq_port_info; | ||
49 | 50 | ||
50 | struct snd_rawmidi_ops { | 51 | struct snd_rawmidi_ops { |
51 | int (*open) (struct snd_rawmidi_substream * substream); | 52 | int (*open) (struct snd_rawmidi_substream * substream); |
@@ -57,6 +58,8 @@ struct snd_rawmidi_ops { | |||
57 | struct snd_rawmidi_global_ops { | 58 | struct snd_rawmidi_global_ops { |
58 | int (*dev_register) (struct snd_rawmidi * rmidi); | 59 | int (*dev_register) (struct snd_rawmidi * rmidi); |
59 | int (*dev_unregister) (struct snd_rawmidi * rmidi); | 60 | int (*dev_unregister) (struct snd_rawmidi * rmidi); |
61 | void (*get_port_info)(struct snd_rawmidi *rmidi, int number, | ||
62 | struct snd_seq_port_info *info); | ||
60 | }; | 63 | }; |
61 | 64 | ||
62 | struct snd_rawmidi_runtime { | 65 | struct snd_rawmidi_runtime { |
diff --git a/include/sound/version.h b/include/sound/version.h index 4f0e65808cf1..2ee849d0e198 100644 --- a/include/sound/version.h +++ b/include/sound/version.h | |||
@@ -1,3 +1,3 @@ | |||
1 | /* include/version.h. Generated by configure. */ | 1 | /* include/version.h. Generated by configure. */ |
2 | #define CONFIG_SND_VERSION "1.0.11rc4" | 2 | #define CONFIG_SND_VERSION "1.0.12rc1" |
3 | #define CONFIG_SND_DATE " (Wed Mar 22 10:27:24 2006 UTC)" | 3 | #define CONFIG_SND_DATE " (Thu Jun 22 13:55:50 2006 UTC)" |
diff --git a/include/video/edid.h b/include/video/edid.h index b913f196131d..f6a42d6c2e2d 100644 --- a/include/video/edid.h +++ b/include/video/edid.h | |||
@@ -3,7 +3,6 @@ | |||
3 | 3 | ||
4 | #ifdef __KERNEL__ | 4 | #ifdef __KERNEL__ |
5 | 5 | ||
6 | #include <linux/config.h> | ||
7 | 6 | ||
8 | #ifdef CONFIG_X86 | 7 | #ifdef CONFIG_X86 |
9 | struct edid_info { | 8 | struct edid_info { |
diff --git a/include/video/vga.h b/include/video/vga.h index 700d6c8eb736..b49a5120ca2d 100644 --- a/include/video/vga.h +++ b/include/video/vga.h | |||
@@ -17,7 +17,6 @@ | |||
17 | #ifndef __linux_video_vga_h__ | 17 | #ifndef __linux_video_vga_h__ |
18 | #define __linux_video_vga_h__ | 18 | #define __linux_video_vga_h__ |
19 | 19 | ||
20 | #include <linux/config.h> | ||
21 | #include <linux/types.h> | 20 | #include <linux/types.h> |
22 | #include <asm/io.h> | 21 | #include <asm/io.h> |
23 | #ifndef CONFIG_AMIGA | 22 | #ifndef CONFIG_AMIGA |