summaryrefslogtreecommitdiff
path: root/arch/arm/mach-uniphier/ph1-sld3/memconf.c
diff options
context:
space:
mode:
authorAlbert ARIBAUD <albert.u.boot@aribaud.net>2015-10-14 10:46:36 +0200
committerAlbert ARIBAUD <albert.u.boot@aribaud.net>2015-10-14 10:46:36 +0200
commit13a3972585af60ec367d209cedbd3601e0c77467 (patch)
tree4b3312669b3e501f6bc10b39d8c7bbf516f07aac /arch/arm/mach-uniphier/ph1-sld3/memconf.c
parent208bd51396fb606dbdcf45b064e6b372d7dd3e81 (diff)
parent297faccca2235e359012118495b9b73451d54bb9 (diff)
downloadu-boot-imx-13a3972585af60ec367d209cedbd3601e0c77467.zip
u-boot-imx-13a3972585af60ec367d209cedbd3601e0c77467.tar.gz
u-boot-imx-13a3972585af60ec367d209cedbd3601e0c77467.tar.bz2
Merge remote-tracking branch 'u-boot/master'
Diffstat (limited to 'arch/arm/mach-uniphier/ph1-sld3/memconf.c')
-rw-r--r--arch/arm/mach-uniphier/ph1-sld3/memconf.c52
1 files changed, 0 insertions, 52 deletions
diff --git a/arch/arm/mach-uniphier/ph1-sld3/memconf.c b/arch/arm/mach-uniphier/ph1-sld3/memconf.c
deleted file mode 100644
index 553a9e3..0000000
--- a/arch/arm/mach-uniphier/ph1-sld3/memconf.c
+++ /dev/null
@@ -1,52 +0,0 @@
-/*
- * Copyright (C) 2015 Masahiro Yamada <yamada.masahiro@socionext.com>
- *
- * SPDX-License-Identifier: GPL-2.0+
- */
-
-#include <common.h>
-#include <linux/types.h>
-#include <linux/sizes.h>
-#include <mach/sg-regs.h>
-
-static inline u32 sg_memconf_val_ch2(unsigned long size, int num)
-{
- int size_mb = size / num;
- u32 ret;
-
- switch (size_mb) {
- case SZ_64M:
- ret = SG_MEMCONF_CH2_SZ_64M;
- break;
- case SZ_128M:
- ret = SG_MEMCONF_CH2_SZ_128M;
- break;
- case SZ_256M:
- ret = SG_MEMCONF_CH2_SZ_256M;
- break;
- case SZ_512M:
- ret = SG_MEMCONF_CH2_SZ_512M;
- break;
- default:
- BUG();
- break;
- }
-
- switch (num) {
- case 1:
- ret |= SG_MEMCONF_CH2_NUM_1;
- break;
- case 2:
- ret |= SG_MEMCONF_CH2_NUM_2;
- break;
- default:
- BUG();
- break;
- }
- return ret;
-}
-
-u32 memconf_additional_val(void)
-{
- return sg_memconf_val_ch2(CONFIG_SDRAM2_SIZE, CONFIG_DDR_NUM_CH2);
-}