Minimal platform support to boot linux from SD.
Supported devices/hw limited to external MMC/SD slot,
GPIO, I2C and minimal PRCMU.
Signed-off-by: John Rigby
CC: Albert Aribaud
---
This board support requires mmc driver patch set from Matt Waddel.
v2: cleanup, mostly removal of unused defines and include files
v3: incorporate changes suggested by Wolfgang including:
better commit message
get arm_pl180_mmci_init prototype from driver .h file
don't ignore value from arm_pl180_mmci_init
optimize printf's in u8500_href.c
use plain #define CONFIG_BLAH for feature enabling
v4: no changes, just rebased to latest upstream and included for completness
board/st-ericsson/u8500/Makefile | 50 +++
board/st-ericsson/u8500/gpio.c | 347 +
board/st-ericsson/u8500/prcmu-fw.h | 55
board/st-ericsson/u8500/prcmu.c | 165 ++
board/st-ericsson/u8500/u8500_href.c | 546 ++
boards.cfg |1 +
include/configs/u8500_href.h | 245 +++
7 files changed, 1409 insertions(+), 0 deletions(-)
create mode 100644 board/st-ericsson/u8500/Makefile
create mode 100644 board/st-ericsson/u8500/gpio.c
create mode 100644 board/st-ericsson/u8500/prcmu-fw.h
create mode 100644 board/st-ericsson/u8500/prcmu.c
create mode 100644 board/st-ericsson/u8500/u8500_href.c
create mode 100644 include/configs/u8500_href.h
diff --git a/board/st-ericsson/u8500/Makefile b/board/st-ericsson/u8500/Makefile
new file mode 100644
index 000..91c2abf
--- /dev/null
+++ b/board/st-ericsson/u8500/Makefile
@@ -0,0 +1,50 @@
+#
+# Copyright (C) ST-Ericsson SA 2009
+#
+# See file CREDITS for list of people who contributed to this
+# project.
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2 of
+# the License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+# MA 02111-1307 USA
+#
+
+include $(TOPDIR)/config.mk
+
+CFLAGS += -D__RELEASE -D__STN_8500
+LIB= $(obj)lib$(BOARD).o
+
+COBJS := u8500_href.o gpio.o prcmu.o
+
+SRCS := $(SOBJS:.o=.S) $(COBJS:.o=.c)
+OBJS := $(addprefix $(obj),$(COBJS))
+SOBJS := $(addprefix $(obj),$(SOBJS))
+
+$(LIB): $(obj).depend $(OBJS) $(SOBJS)
+ $(call cmd_link_o_target, $(OBJS) $(SOBJS))
+
+clean:
+ rm -f $(SOBJS) $(OBJS)
+
+distclean: clean
+ rm -f $(LIB) core *.bak $(obj).depend
+
+#
+
+# defines $(obj).depend target
+include $(SRCTREE)/rules.mk
+
+sinclude $(obj).depend
+
+#
diff --git a/board/st-ericsson/u8500/gpio.c b/board/st-ericsson/u8500/gpio.c
new file mode 100644
index 000..96b2461
--- /dev/null
+++ b/board/st-ericsson/u8500/gpio.c
@@ -0,0 +1,347 @@
+/*
+ * Copyright (C) ST-Ericsson SA 2009
+ *
+ * See file CREDITS for list of people who contributed to this
+ * project.
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License as
+ * published by the Free Software Foundation; either version 2 of
+ * the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston,
+ * MA 02111-1307 USA
+ */
+
+#include
+#include
+
+static struct gpio_register *addr_gpio_register[] = {
+ (void *)U8500_GPIO_0_BASE,
+ (void *)U8500_GPIO_1_BASE,
+ (void *)U8500_GPIO_2_BASE,
+ (void *)U8500_GPIO_3_BASE,
+ (void *)U8500_GPIO_4_BASE,
+ (void *)U8500_GPIO_5_BASE,
+ (void *)U8500_GPIO_6_BASE,
+ (void *)U8500_GPIO_7_BASE,
+ (void *)U8500_GPIO_8_BASE,
+};
+
+struct gpio_altfun_data altfun_table[] = {
+ {
+ .altfun = GPIO_ALT_I2C_0,
+ .start = 147,
+ .end = 148,
+ .cont = 0,
+ .type = GPIO_ALTF_A,
+ },
+ {
+ .altfun = GPIO_ALT_I2C_1,
+ .start = 16,
+ .end = 17,
+