diff options
| author | Russell King <rmk+kernel@arm.linux.org.uk> | 2012-10-06 12:12:25 -0400 |
|---|---|---|
| committer | Russell King <rmk+kernel@arm.linux.org.uk> | 2012-10-13 12:11:28 -0400 |
| commit | b1b3f49ce4606452279b58b17f2bbe2ba00304b7 (patch) | |
| tree | c9cfdc72dd580a9c3ace71846af45b4f65268f46 | |
| parent | 4f1cd91497774488ed16119ec3f54b3daf1561de (diff) | |
ARM: config: sort select statements alphanumerically
As suggested by Andrew Morton:
This is a pet peeve of mine. Any time there's a long list of items
(header file inclusions, kconfig entries, array initalisers, etc) and
someone wants to add a new item, they *always* go and stick it at the
end of the list.
Guys, don't do this. Either put the new item into a randomly-chosen
position or, probably better, alphanumerically sort the list.
lets sort all our select statements alphanumerically. This commit was
created by the following perl:
while (<>) {
while (/\\\s*$/) {
$_ .= <>;
}
undef %selects if /^\s*config\s+/;
if (/^\s+select\s+(\w+).*/) {
if (defined($selects{$1})) {
if ($selects{$1} eq $_) {
print STDERR "Warning: removing duplicated $1 entry\n";
} else {
print STDERR "Error: $1 differently selected\n".
"\tOld: $selects{$1}\n".
"\tNew: $_\n";
exit 1;
}
}
$selects{$1} = $_;
next;
}
if (%selects and (/^\s*$/ or /^\s+help/ or /^\s+---help---/ or
/^endif/ or /^endchoice/)) {
foreach $k (sort (keys %selects)) {
print "$selects{$k}";
}
undef %selects;
}
print;
}
if (%selects) {
foreach $k (sort (keys %selects)) {
print "$selects{$k}";
}
}
It found two duplicates:
Warning: removing duplicated S5P_SETUP_MIPIPHY entry
Warning: removing duplicated HARDIRQS_SW_RESEND entry
and they are identical duplicates, hence the shrinkage in the diffstat
of two lines.
We have four testers reporting success of this change (Tony, Stephen,
Linus and Sekhar.)
Acked-by: Jason Cooper <jason@lakedaemon.net>
Acked-by: Tony Lindgren <tony@atomide.com>
Acked-by: Stephen Warren <swarren@nvidia.com>
Acked-by: Linus Walleij <linus.walleij@linaro.org>
Acked-by: Sekhar Nori <nsekhar@ti.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
39 files changed, 765 insertions, 767 deletions
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig index 767aae8277fa..bd12ddd15448 100644 --- a/arch/arm/Kconfig +++ b/arch/arm/Kconfig | |||
| @@ -1,58 +1,57 @@ | |||
| 1 | config ARM | 1 | config ARM |
| 2 | bool | 2 | bool |
| 3 | default y | 3 | default y |
| 4 | select ARCH_BINFMT_ELF_RANDOMIZE_PIE | ||
| 5 | select ARCH_HAS_ATOMIC64_DEC_IF_POSITIVE | ||
| 4 | select ARCH_HAVE_CUSTOM_GPIO_H | 6 | select ARCH_HAVE_CUSTOM_GPIO_H |
| 5 | select HAVE_AOUT | 7 | select ARCH_WANT_IPC_PARSE_VERSION |
| 6 | select HAVE_DMA_API_DEBUG | 8 | select CPU_PM if (SUSPEND || CPU_IDLE) |
| 7 | select HAVE_IDE if PCI || ISA || PCMCIA | 9 | select DCACHE_WORD_ACCESS if (CPU_V6 || CPU_V6K || CPU_V7) && !CPU_BIG_ENDIAN |
| 8 | select HAVE_DMA_ATTRS | ||
| 9 | select HAVE_DMA_CONTIGUOUS if MMU | ||
| 10 | select HAVE_MEMBLOCK | ||
| 11 | select RTC_LIB | ||
| 12 | select SYS_SUPPORTS_APM_EMULATION | ||
| 13 | select GENERIC_ATOMIC64 if (CPU_V6 || !CPU_32v6K || !AEABI) | 10 | select GENERIC_ATOMIC64 if (CPU_V6 || !CPU_32v6K || !AEABI) |
| 14 | select ARCH_HAS_ATOMIC64_DEC_IF_POSITIVE | 11 | select GENERIC_CLOCKEVENTS_BROADCAST if SMP |
| 15 | select HAVE_OPROFILE if (HAVE_PERF_EVENTS) | 12 | select GENERIC_IRQ_PROBE |
| 13 | select GENERIC_IRQ_SHOW | ||
| 14 | select GENERIC_KERNEL_THREAD | ||
| 15 | select GENERIC_PCI_IOMAP | ||
| 16 | select GENERIC_SMP_IDLE_THREAD | ||
| 17 | select GENERIC_STRNCPY_FROM_USER | ||
| 18 | select GENERIC_STRNLEN_USER | ||
| 19 | select HARDIRQS_SW_RESEND | ||
| 20 | select HAVE_AOUT | ||
| 16 | select HAVE_ARCH_JUMP_LABEL if !XIP_KERNEL | 21 | select HAVE_ARCH_JUMP_LABEL if !XIP_KERNEL |
| 17 | select HAVE_ARCH_KGDB | 22 | select HAVE_ARCH_KGDB |
| 18 | select HAVE_ARCH_TRACEHOOK | 23 | select HAVE_ARCH_TRACEHOOK |
| 19 | select HAVE_SYSCALL_TRACEPOINTS | 24 | select HAVE_BPF_JIT |
| 20 | select HAVE_KPROBES if !XIP_KERNEL | 25 | select HAVE_C_RECORDMCOUNT |
| 21 | select HAVE_KRETPROBES if (HAVE_KPROBES) | 26 | select HAVE_DEBUG_KMEMLEAK |
| 22 | select HAVE_FUNCTION_TRACER if (!XIP_KERNEL) | 27 | select HAVE_DMA_API_DEBUG |
| 23 | select HAVE_FTRACE_MCOUNT_RECORD if (!XIP_KERNEL) | 28 | select HAVE_DMA_ATTRS |
| 29 | select HAVE_DMA_CONTIGUOUS if MMU | ||
| 24 | select HAVE_DYNAMIC_FTRACE if (!XIP_KERNEL) | 30 | select HAVE_DYNAMIC_FTRACE if (!XIP_KERNEL) |
| 31 | select HAVE_FTRACE_MCOUNT_RECORD if (!XIP_KERNEL) | ||
| 25 | select HAVE_FUNCTION_GRAPH_TRACER if (!THUMB2_KERNEL) | 32 | select HAVE_FUNCTION_GRAPH_TRACER if (!THUMB2_KERNEL) |
| 26 | select ARCH_BINFMT_ELF_RANDOMIZE_PIE | 33 | select HAVE_FUNCTION_TRACER if (!XIP_KERNEL) |
| 27 | select HAVE_GENERIC_DMA_COHERENT | 34 | select HAVE_GENERIC_DMA_COHERENT |
| 28 | select HAVE_DEBUG_KMEMLEAK | 35 | select HAVE_GENERIC_HARDIRQS |
| 36 | select HAVE_HW_BREAKPOINT if (PERF_EVENTS && (CPU_V6 || CPU_V6K || CPU_V7)) | ||
| 37 | select HAVE_IDE if PCI || ISA || PCMCIA | ||
| 38 | select HAVE_IRQ_WORK | ||
| 29 | select HAVE_KERNEL_GZIP | 39 | select HAVE_KERNEL_GZIP |
| 30 | select HAVE_KERNEL_LZO | ||
| 31 | select HAVE_KERNEL_LZMA | 40 | select HAVE_KERNEL_LZMA |
| 41 | select HAVE_KERNEL_LZO | ||
| 32 | select HAVE_KERNEL_XZ | 42 | select HAVE_KERNEL_XZ |
| 33 | select HAVE_IRQ_WORK | 43 | select HAVE_KPROBES if !XIP_KERNEL |
| 44 | select HAVE_KRETPROBES if (HAVE_KPROBES) | ||
| 45 | select HAVE_MEMBLOCK | ||
| 46 | select HAVE_OPROFILE if (HAVE_PERF_EVENTS) | ||
| 34 | select HAVE_PERF_EVENTS | 47 | select HAVE_PERF_EVENTS |
| 35 | select PERF_USE_VMALLOC | ||
| 36 | select HAVE_REGS_AND_STACK_ACCESS_API | 48 | select HAVE_REGS_AND_STACK_ACCESS_API |
| 37 | select HAVE_HW_BREAKPOINT if (PERF_EVENTS && (CPU_V6 || CPU_V6K || CPU_V7)) | 49 | select HAVE_SYSCALL_TRACEPOINTS |
| 38 | select HAVE_C_RECORDMCOUNT | ||
| 39 | select HAVE_GENERIC_HARDIRQS | ||
| 40 | select HARDIRQS_SW_RESEND | ||
| 41 | select GENERIC_IRQ_PROBE | ||
| 42 | select GENERIC_IRQ_SHOW | ||
| 43 | select HAVE_UID16 | 50 | select HAVE_UID16 |
| 44 | select ARCH_WANT_IPC_PARSE_VERSION | ||
| 45 | select HARDIRQS_SW_RESEND | ||
| 46 | select CPU_PM if (SUSPEND || CPU_IDLE) | ||
| 47 | select GENERIC_PCI_IOMAP | ||
| 48 | select HAVE_BPF_JIT | ||
| 49 | select GENERIC_SMP_IDLE_THREAD | ||
| 50 | select KTIME_SCALAR | 51 | select KTIME_SCALAR |
| 51 | select GENERIC_CLOCKEVENTS_BROADCAST if SMP | 52 | select PERF_USE_VMALLOC |
| 52 | select GENERIC_STRNCPY_FROM_USER | 53 | select RTC_LIB |
| 53 | select GENERIC_STRNLEN_USER | 54 | select SYS_SUPPORTS_APM_EMULATION |
| 54 | select DCACHE_WORD_ACCESS if (CPU_V6 || CPU_V6K || CPU_V7) && !CPU_BIG_ENDIAN | ||
| 55 | select GENERIC_KERNEL_THREAD | ||
| 56 | help | 55 | help |
| 57 | The ARM series is a line of low-power-consumption RISC chip designs | 56 | The ARM series is a line of low-power-consumption RISC chip designs |
| 58 | licensed by ARM Ltd and targeted at embedded applications and | 57 | licensed by ARM Ltd and targeted at embedded applications and |
| @@ -68,9 +67,9 @@ config NEED_SG_DMA_LENGTH | |||
| 68 | bool | 67 | bool |
| 69 | 68 | ||
| 70 | config ARM_DMA_USE_IOMMU | 69 | config ARM_DMA_USE_IOMMU |
| 71 | select NEED_SG_DMA_LENGTH | ||
| 72 | select ARM_HAS_SG_CHAIN | ||
| 73 | bool | 70 | bool |
| 71 | select ARM_HAS_SG_CHAIN | ||
| 72 | select NEED_SG_DMA_LENGTH | ||
| 74 | 73 | ||
| 75 | config HAVE_PWM | 74 | config HAVE_PWM |
| 76 | bool | 75 | bool |
| @@ -262,69 +261,69 @@ choice | |||
| 262 | 261 | ||
| 263 | config ARCH_MULTIPLATFORM | 262 | config ARCH_MULTIPLATFORM |
| 264 | bool "Allow multiple platforms to be selected" | 263 | bool "Allow multiple platforms to be selected" |
| 264 | depends on MMU | ||
| 265 | select ARM_PATCH_PHYS_VIRT | 265 | select ARM_PATCH_PHYS_VIRT |
| 266 | select AUTO_ZRELADDR | 266 | select AUTO_ZRELADDR |
| 267 | select COMMON_CLK | 267 | select COMMON_CLK |
| 268 | select MULTI_IRQ_HANDLER | 268 | select MULTI_IRQ_HANDLER |
| 269 | select SPARSE_IRQ | 269 | select SPARSE_IRQ |
| 270 | select USE_OF | 270 | select USE_OF |
| 271 | depends on MMU | ||
| 272 | 271 | ||
