diff options
author | Michael Hennerich <michael.hennerich@analog.com> | 2008-07-14 05:04:14 -0400 |
---|---|---|
committer | Bryan Wu <cooloney@kernel.org> | 2008-07-14 05:04:14 -0400 |
commit | 99d95bbd48f43dafdcd0540eb0da26c5655d7f33 (patch) | |
tree | e17a4d331e7ae07212dd9b6917edeac57fbb02fc /arch | |
parent | 96b86e94bcf7eadbd8c959c0474d2971b3695478 (diff) |
Blackfin arch: Remove redundant kernel option
use kernel command line mem and max_mem bootargs to limit
availabe memory instead.
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/blackfin/Kconfig | 7 | ||||
-rw-r--r-- | arch/blackfin/kernel/cplb-nompu/cplbinit.c | 6 | ||||
-rw-r--r-- | arch/blackfin/kernel/setup.c | 14 | ||||
-rw-r--r-- | arch/blackfin/mach-common/arch_checks.c | 6 |
4 files changed, 7 insertions, 26 deletions
diff --git a/arch/blackfin/Kconfig b/arch/blackfin/Kconfig index d0f7ff3dc088..c602727d1a9a 100644 --- a/arch/blackfin/Kconfig +++ b/arch/blackfin/Kconfig | |||
@@ -310,11 +310,6 @@ config BFIN_KERNEL_CLOCK | |||
310 | are also not changed, and the Bootloader does 100% of the hardware | 310 | are also not changed, and the Bootloader does 100% of the hardware |
311 | configuration. | 311 | configuration. |
312 | 312 | ||
313 | config MEM_SIZE | ||
314 | int "SDRAM Memory Size in MBytes" | ||
315 | depends on BFIN_KERNEL_CLOCK | ||
316 | default 64 | ||
317 | |||
318 | config PLL_BYPASS | 313 | config PLL_BYPASS |
319 | bool "Bypass PLL" | 314 | bool "Bypass PLL" |
320 | depends on BFIN_KERNEL_CLOCK | 315 | depends on BFIN_KERNEL_CLOCK |
@@ -376,7 +371,7 @@ config SCLK_DIV | |||
376 | 371 | ||
377 | config MAX_MEM_SIZE | 372 | config MAX_MEM_SIZE |
378 | int "Max SDRAM Memory Size in MBytes" | 373 | int "Max SDRAM Memory Size in MBytes" |
379 | depends on !BFIN_KERNEL_CLOCK && !MPU | 374 | depends on !MPU |
380 | default 512 | 375 | default 512 |
381 | help | 376 | help |
382 | This is the max memory size that the kernel will create CPLB | 377 | This is the max memory size that the kernel will create CPLB |
diff --git a/arch/blackfin/kernel/cplb-nompu/cplbinit.c b/arch/blackfin/kernel/cplb-nompu/cplbinit.c index 6be0c50122e8..224e7cc30bc5 100644 --- a/arch/blackfin/kernel/cplb-nompu/cplbinit.c +++ b/arch/blackfin/kernel/cplb-nompu/cplbinit.c | |||
@@ -26,11 +26,7 @@ | |||
26 | #include <asm/cplb.h> | 26 | #include <asm/cplb.h> |
27 | #include <asm/cplbinit.h> | 27 | #include <asm/cplbinit.h> |
28 | 28 | ||
29 | #ifdef CONFIG_MAX_MEM_SIZE | 29 | #define CPLB_MEM CONFIG_MAX_MEM_SIZE |
30 | # define CPLB_MEM CONFIG_MAX_MEM_SIZE | ||
31 | #else | ||
32 | # define CPLB_MEM CONFIG_MEM_SIZE | ||
33 | #endif | ||
34 | 30 | ||
35 | /* | 31 | /* |
36 | * Number of required data CPLB switchtable entries | 32 | * Number of required data CPLB switchtable entries |
diff --git a/arch/blackfin/kernel/setup.c b/arch/blackfin/kernel/setup.c index 8efea004aecb..861a1db74df8 100644 --- a/arch/blackfin/kernel/setup.c +++ b/arch/blackfin/kernel/setup.c | |||
@@ -664,11 +664,8 @@ static __init void setup_bootmem_allocator(void) | |||
664 | }) | 664 | }) |
665 | static inline int __init get_mem_size(void) | 665 | static inline int __init get_mem_size(void) |
666 | { | 666 | { |
667 | #ifdef CONFIG_MEM_SIZE | 667 | #if defined(EBIU_SDBCTL) |
668 | return CONFIG_MEM_SIZE; | 668 | # if defined(BF561_FAMILY) |
669 | #else | ||
670 | # if defined(EBIU_SDBCTL) | ||
671 | # if defined(BF561_FAMILY) | ||
672 | int ret = 0; | 669 | int ret = 0; |
673 | u32 sdbctl = bfin_read_EBIU_SDBCTL(); | 670 | u32 sdbctl = bfin_read_EBIU_SDBCTL(); |
674 | ret += EBSZ_TO_MEG(sdbctl >> 0); | 671 | ret += EBSZ_TO_MEG(sdbctl >> 0); |
@@ -676,10 +673,10 @@ static inline int __init get_mem_size(void) | |||
676 | ret += EBSZ_TO_MEG(sdbctl >> 16); | 673 | ret += EBSZ_TO_MEG(sdbctl >> 16); |
677 | ret += EBSZ_TO_MEG(sdbctl >> 24); | 674 | ret += EBSZ_TO_MEG(sdbctl >> 24); |
678 | return ret; | 675 | return ret; |
679 | # else | 676 | # else |
680 | return EBSZ_TO_MEG(bfin_read_EBIU_SDBCTL()); | 677 | return EBSZ_TO_MEG(bfin_read_EBIU_SDBCTL()); |
681 | # endif | 678 | # endif |
682 | # elif defined(EBIU_DDRCTL1) | 679 | #elif defined(EBIU_DDRCTL1) |
683 | u32 ddrctl = bfin_read_EBIU_DDRCTL1(); | 680 | u32 ddrctl = bfin_read_EBIU_DDRCTL1(); |
684 | int ret = 0; | 681 | int ret = 0; |
685 | switch (ddrctl & 0xc0000) { | 682 | switch (ddrctl & 0xc0000) { |
@@ -694,7 +691,6 @@ static inline int __init get_mem_size(void) | |||
694 | case DEVWD_16: break; | 691 | case DEVWD_16: break; |
695 | } | 692 | } |
696 | return ret; | 693 | return ret; |
697 | # endif | ||
698 | #endif | 694 | #endif |
699 | BUG(); | 695 | BUG(); |
700 | } | 696 | } |
diff --git a/arch/blackfin/mach-common/arch_checks.c b/arch/blackfin/mach-common/arch_checks.c index caaab49e9cfa..f9160d83b91f 100644 --- a/arch/blackfin/mach-common/arch_checks.c +++ b/arch/blackfin/mach-common/arch_checks.c | |||
@@ -53,9 +53,3 @@ | |||
53 | # endif | 53 | # endif |
54 | 54 | ||
55 | #endif /* CONFIG_BFIN_KERNEL_CLOCK */ | 55 | #endif /* CONFIG_BFIN_KERNEL_CLOCK */ |
56 | |||
57 | #ifdef CONFIG_MEM_SIZE | ||
58 | #if (CONFIG_MEM_SIZE % 4) | ||
59 | #error "SDRAM mem size must be multible of 4MB" | ||
60 | #endif | ||
61 | #endif | ||