From: Antony Pavlov <antonynpavlov@gmail.com>
To: barebox@lists.infradead.org
Subject: [PATCH 4/5] ARM: uemd: add mb7707 board support
Date: Wed, 16 Apr 2014 13:57:39 +0400 [thread overview]
Message-ID: <1397642260-32606-5-git-send-email-antonynpavlov@gmail.com> (raw)
In-Reply-To: <1397642260-32606-1-git-send-email-antonynpavlov@gmail.com>
The MB 77.07 is a small (80x80 mm) single-board computer
developed in Russia by the RC Module.
It was developed as an educational board for К1879ХБ1Я SoC
capabilities demonstration.
See http://www.module.ru/en/catalog/micro/micro_pc/ for details.
Signed-off-by: Antony Pavlov <antonynpavlov@gmail.com>
---
arch/arm/boards/Makefile | 1 +
arch/arm/boards/module-mb7707/Makefile | 1 +
arch/arm/boards/module-mb7707/board.c | 27 +++++++++++++++++++++++++
arch/arm/boards/module-mb7707/lowlevel.c | 34 ++++++++++++++++++++++++++++++++
arch/arm/dts/module-mb7707.dts | 16 +++++++++++++++
arch/arm/mach-uemd/Kconfig | 9 +++++++++
6 files changed, 88 insertions(+)
diff --git a/arch/arm/boards/Makefile b/arch/arm/boards/Makefile
index 16742d9..806ab3e 100644
--- a/arch/arm/boards/Makefile
+++ b/arch/arm/boards/Makefile
@@ -47,6 +47,7 @@ obj-$(CONFIG_MACH_HIGHBANK) += highbank/
obj-$(CONFIG_MACH_IMX21ADS) += freescale-mx21-ads/
obj-$(CONFIG_MACH_IMX233_OLINUXINO) += imx233-olinuxino/
obj-$(CONFIG_MACH_IMX27ADS) += freescale-mx27-ads/
+obj-$(CONFIG_MACH_MB7707) += module-mb7707/
obj-$(CONFIG_MACH_MIOA701) += mioa701/
obj-$(CONFIG_MACH_MMCCPU) += mmccpu/
obj-$(CONFIG_MACH_MX23EVK) += freescale-mx23-evk/
diff --git a/arch/arm/boards/module-mb7707/Makefile b/arch/arm/boards/module-mb7707/Makefile
new file mode 100644
index 0000000..b2f44bb
--- /dev/null
+++ b/arch/arm/boards/module-mb7707/Makefile
@@ -0,0 +1 @@
+obj-y += lowlevel.o board.o
diff --git a/arch/arm/boards/module-mb7707/board.c b/arch/arm/boards/module-mb7707/board.c
new file mode 100644
index 0000000..9e544b5
--- /dev/null
+++ b/arch/arm/boards/module-mb7707/board.c
@@ -0,0 +1,27 @@
+/*
+ * Copyright (C) 2014 Antony Pavlov <antonynpavlov@gmail.com>
+ *
+ * This file is part of barebox.
+ * 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 version 2
+ * as published by the Free Software Foundation.
+ *
+ * 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.
+ *
+ */
+
+#include <common.h>
+#include <init.h>
+
+static int hostname_init(void)
+{
+ barebox_set_hostname("mb7707");
+
+ return 0;
+}
+core_initcall(hostname_init);
diff --git a/arch/arm/boards/module-mb7707/lowlevel.c b/arch/arm/boards/module-mb7707/lowlevel.c
new file mode 100644
index 0000000..5f5e1d7
--- /dev/null
+++ b/arch/arm/boards/module-mb7707/lowlevel.c
@@ -0,0 +1,34 @@
+/*
+ * Copyright (C) 2014 Antony Pavlov <antonynpavlov@gmail.com>
+ *
+ * This file is part of barebox.
+ * 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 version 2
+ * as published by the Free Software Foundation.
+ *
+ * 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.
+ *
+ */
+
+#define __LOWLEVEL_INIT__
+
+#include <common.h>
+#include <asm/barebox-arm.h>
+#include <asm/barebox-arm-head.h>
+#include <init.h>
+#include <sizes.h>
+
+#define MB7707_SRAM_BASE 0x40000000
+#define MB7707_SRAM_SIZE SZ_128M
+
+void __naked __bare_init barebox_arm_reset_vector(void)
+{
+ arm_cpu_lowlevel_init();
+
+ barebox_arm_entry(MB7707_SRAM_BASE, MB7707_SRAM_SIZE, 0);
+}
diff --git a/arch/arm/dts/module-mb7707.dts b/arch/arm/dts/module-mb7707.dts
new file mode 100644
index 0000000..21bdeb2
--- /dev/null
+++ b/arch/arm/dts/module-mb7707.dts
@@ -0,0 +1,16 @@
+/dts-v1/;
+
+#include "k1879hb1ya.dtsi"
+
+/ {
+ model = "Module MB 77.07";
+ compatible = "module,mb7707";
+
+ memory {
+ reg = <0x40000000 0x8000000>;
+ };
+};
+
+&serial0 {
+ status = "okay";
+};
diff --git a/arch/arm/mach-uemd/Kconfig b/arch/arm/mach-uemd/Kconfig
index f9cf859..aedd757 100644
--- a/arch/arm/mach-uemd/Kconfig
+++ b/arch/arm/mach-uemd/Kconfig
@@ -4,4 +4,13 @@ config ARCH_TEXT_BASE
hex
default 0x40800000
+choice
+ prompt "UEMD Board type"
+
+config MACH_MB7707
+ bool "MB7707"
+ select HAVE_DEFAULT_ENVIRONMENT_NEW
+
+endchoice
+
endif
--
1.9.0
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2014-04-16 9:58 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-16 9:57 [PATCH 0/5] ARM: initial support for RC Module UEMD SoCs and MB 77.07 board Antony Pavlov
2014-04-16 9:57 ` [PATCH 1/5] ARM: initial support for RC Module UEMD SoCs Antony Pavlov
2014-04-23 8:35 ` Sascha Hauer
2014-04-16 9:57 ` [PATCH 2/5] ARM: uemd: add DEBUG_LL support Antony Pavlov
2014-04-16 9:57 ` [PATCH 3/5] ARM: dts: add minimal К1879ХБ1Я devicetree file Antony Pavlov
2014-04-16 9:57 ` Antony Pavlov [this message]
2014-04-16 9:57 ` [PATCH 5/5] ARM: uemd: add module-mb7707_defconfig Antony Pavlov
2014-05-09 6:20 ` [PATCH 0/5] ARM: initial support for RC Module UEMD SoCs and MB 77.07 board Sascha Hauer
2014-05-09 7:49 ` Antony Pavlov
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1397642260-32606-5-git-send-email-antonynpavlov@gmail.com \
--to=antonynpavlov@gmail.com \
--cc=barebox@lists.infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox