aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/generic/files/arch
diff options
context:
space:
mode:
authorJames <>2013-03-17 12:16:37 +0000
committerJames <>2013-03-17 12:16:37 +0000
commit27b76ab0671089c47506615a796a261e993896a7 (patch)
tree61213d67e7fa87b20356b23798558e2c4212c42f /target/linux/generic/files/arch
downloadtrunk-36060-master.tar.gz
trunk-36060-master.tar.bz2
trunk-36060-master.zip
Diffstat (limited to 'target/linux/generic/files/arch')
-rw-r--r--target/linux/generic/files/arch/.svn/entries31
-rw-r--r--target/linux/generic/files/arch/mips/.svn/entries31
-rw-r--r--target/linux/generic/files/arch/mips/fw/.svn/entries31
-rw-r--r--target/linux/generic/files/arch/mips/fw/myloader/.svn/entries96
-rw-r--r--target/linux/generic/files/arch/mips/fw/myloader/.svn/prop-base/Makefile.svn-base5
-rw-r--r--target/linux/generic/files/arch/mips/fw/myloader/.svn/prop-base/myloader.c.svn-base5
-rw-r--r--target/linux/generic/files/arch/mips/fw/myloader/.svn/text-base/Makefile.svn-base5
-rw-r--r--target/linux/generic/files/arch/mips/fw/myloader/.svn/text-base/myloader.c.svn-base63
-rw-r--r--target/linux/generic/files/arch/mips/fw/myloader/Makefile5
-rw-r--r--target/linux/generic/files/arch/mips/fw/myloader/myloader.c63
10 files changed, 335 insertions, 0 deletions
diff --git a/target/linux/generic/files/arch/.svn/entries b/target/linux/generic/files/arch/.svn/entries
new file mode 100644
index 0000000..ade6724
--- /dev/null
+++ b/target/linux/generic/files/arch/.svn/entries
@@ -0,0 +1,31 @@
+10
+
+dir
+36060
+svn://svn.openwrt.org/openwrt/trunk/target/linux/generic/files/arch
+svn://svn.openwrt.org/openwrt
+
+
+
+2010-06-26T20:42:58.993070Z
+21952
+nbd
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3c298f89-4303-0410-b956-a3cf2f4a3e73
+
+mips
+dir
+
diff --git a/target/linux/generic/files/arch/mips/.svn/entries b/target/linux/generic/files/arch/mips/.svn/entries
new file mode 100644
index 0000000..b9929b0
--- /dev/null
+++ b/target/linux/generic/files/arch/mips/.svn/entries
@@ -0,0 +1,31 @@
+10
+
+dir
+36060
+svn://svn.openwrt.org/openwrt/trunk/target/linux/generic/files/arch/mips
+svn://svn.openwrt.org/openwrt
+
+
+
+2010-06-26T20:42:58.993070Z
+21952
+nbd
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3c298f89-4303-0410-b956-a3cf2f4a3e73
+
+fw
+dir
+
diff --git a/target/linux/generic/files/arch/mips/fw/.svn/entries b/target/linux/generic/files/arch/mips/fw/.svn/entries
new file mode 100644
index 0000000..1f2fc3e
--- /dev/null
+++ b/target/linux/generic/files/arch/mips/fw/.svn/entries
@@ -0,0 +1,31 @@
+10
+
+dir
+36060
+svn://svn.openwrt.org/openwrt/trunk/target/linux/generic/files/arch/mips/fw
+svn://svn.openwrt.org/openwrt
+
+
+
+2010-06-26T20:42:58.993070Z
+21952
+nbd
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3c298f89-4303-0410-b956-a3cf2f4a3e73
+
+myloader
+dir
+
diff --git a/target/linux/generic/files/arch/mips/fw/myloader/.svn/entries b/target/linux/generic/files/arch/mips/fw/myloader/.svn/entries
new file mode 100644
index 0000000..72ea7f1
--- /dev/null
+++ b/target/linux/generic/files/arch/mips/fw/myloader/.svn/entries
@@ -0,0 +1,96 @@
+10
+
+dir
+36060
+svn://svn.openwrt.org/openwrt/trunk/target/linux/generic/files/arch/mips/fw/myloader
+svn://svn.openwrt.org/openwrt
+
+
+
+2010-06-26T20:42:58.993070Z
+21952
+nbd
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+3c298f89-4303-0410-b956-a3cf2f4a3e73
+
+Makefile
+file
+
+
+
+
+2013-03-17T12:13:03.000000Z
+a0686d815c236787a5303a449d72e163
+2010-06-26T20:42:58.993070Z
+21952
+nbd
+has-props
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+91
+
+myloader.c
+file
+
+
+
+
+2013-03-17T12:13:03.000000Z
+c0ca4c2176c3f148716db7298dd2183a
+2010-06-26T20:42:58.993070Z
+21952
+nbd
+has-props
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+1835
+
diff --git a/target/linux/generic/files/arch/mips/fw/myloader/.svn/prop-base/Makefile.svn-base b/target/linux/generic/files/arch/mips/fw/myloader/.svn/prop-base/Makefile.svn-base
new file mode 100644
index 0000000..bdbd305
--- /dev/null
+++ b/target/linux/generic/files/arch/mips/fw/myloader/.svn/prop-base/Makefile.svn-base
@@ -0,0 +1,5 @@
+K 13
+svn:eol-style
+V 6
+native
+END
diff --git a/target/linux/generic/files/arch/mips/fw/myloader/.svn/prop-base/myloader.c.svn-base b/target/linux/generic/files/arch/mips/fw/myloader/.svn/prop-base/myloader.c.svn-base
new file mode 100644
index 0000000..bdbd305
--- /dev/null
+++ b/target/linux/generic/files/arch/mips/fw/myloader/.svn/prop-base/myloader.c.svn-base
@@ -0,0 +1,5 @@
+K 13
+svn:eol-style
+V 6
+native
+END
diff --git a/target/linux/generic/files/arch/mips/fw/myloader/.svn/text-base/Makefile.svn-base b/target/linux/generic/files/arch/mips/fw/myloader/.svn/text-base/Makefile.svn-base
new file mode 100644
index 0000000..34acfd0
--- /dev/null
+++ b/target/linux/generic/files/arch/mips/fw/myloader/.svn/text-base/Makefile.svn-base
@@ -0,0 +1,5 @@
+#
+# Makefile for the Compex's MyLoader support on MIPS architecture
+#
+
+lib-y += myloader.o
diff --git a/target/linux/generic/files/arch/mips/fw/myloader/.svn/text-base/myloader.c.svn-base b/target/linux/generic/files/arch/mips/fw/myloader/.svn/text-base/myloader.c.svn-base
new file mode 100644
index 0000000..a26f9ad
--- /dev/null
+++ b/target/linux/generic/files/arch/mips/fw/myloader/.svn/text-base/myloader.c.svn-base
@@ -0,0 +1,63 @@
+/*
+ * Compex's MyLoader specific prom routines
+ *
+ * Copyright (C) 2007-2008 Gabor Juhos <juhosg@openwrt.org>
+ *
+ * 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.
+ *
+ */
+
+#include <linux/kernel.h>
+#include <linux/init.h>
+#include <linux/types.h>
+#include <linux/string.h>
+
+#include <asm/addrspace.h>
+#include <asm/fw/myloader/myloader.h>
+
+#define SYS_PARAMS_ADDR KSEG1ADDR(0x80000800)
+#define BOARD_PARAMS_ADDR KSEG1ADDR(0x80000A00)
+#define PART_TABLE_ADDR KSEG1ADDR(0x80000C00)
+#define BOOT_PARAMS_ADDR KSEG1ADDR(0x80000E00)
+
+static struct myloader_info myloader_info __initdata;
+static int myloader_found __initdata;
+
+struct myloader_info * __init myloader_get_info(void)
+{
+ struct mylo_system_params *sysp;
+ struct mylo_board_params *boardp;
+ struct mylo_partition_table *parts;
+
+ if (myloader_found)
+ return &myloader_info;
+
+ sysp = (struct mylo_system_params *)(SYS_PARAMS_ADDR);
+ boardp = (struct mylo_board_params *)(BOARD_PARAMS_ADDR);
+ parts = (struct mylo_partition_table *)(PART_TABLE_ADDR);
+
+ printk(KERN_DEBUG "MyLoader: sysp=%08x, boardp=%08x, parts=%08x\n",
+ sysp->magic, boardp->magic, parts->magic);
+
+ /* Check for some magic numbers */
+ if (sysp->magic != MYLO_MAGIC_SYS_PARAMS ||
+ boardp->magic != MYLO_MAGIC_BOARD_PARAMS ||
+ le32_to_cpu(parts->magic) != MYLO_MAGIC_PARTITIONS)
+ return NULL;
+
+ printk(KERN_DEBUG "MyLoader: id=%04x:%04x, sub_id=%04x:%04x\n",
+ sysp->vid, sysp->did, sysp->svid, sysp->sdid);
+
+ myloader_info.vid = sysp->vid;
+ myloader_info.did = sysp->did;
+ myloader_info.svid = sysp->svid;
+ myloader_info.sdid = sysp->sdid;
+
+ memcpy(myloader_info.macs, boardp->addr, sizeof(myloader_info.macs));
+
+ myloader_found = 1;
+
+ return &myloader_info;
+}
diff --git a/target/linux/generic/files/arch/mips/fw/myloader/Makefile b/target/linux/generic/files/arch/mips/fw/myloader/Makefile
new file mode 100644
index 0000000..34acfd0
--- /dev/null
+++ b/target/linux/generic/files/arch/mips/fw/myloader/Makefile
@@ -0,0 +1,5 @@
+#
+# Makefile for the Compex's MyLoader support on MIPS architecture
+#
+
+lib-y += myloader.o
diff --git a/target/linux/generic/files/arch/mips/fw/myloader/myloader.c b/target/linux/generic/files/arch/mips/fw/myloader/myloader.c
new file mode 100644
index 0000000..a26f9ad
--- /dev/null
+++ b/target/linux/generic/files/arch/mips/fw/myloader/myloader.c
@@ -0,0 +1,63 @@
+/*
+ * Compex's MyLoader specific prom routines
+ *
+ * Copyright (C) 2007-2008 Gabor Juhos <juhosg@openwrt.org>
+ *
+ * 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.
+ *
+ */
+
+#include <linux/kernel.h>
+#include <linux/init.h>
+#include <linux/types.h>
+#include <linux/string.h>
+
+#include <asm/addrspace.h>
+#include <asm/fw/myloader/myloader.h>
+
+#define SYS_PARAMS_ADDR KSEG1ADDR(0x80000800)
+#define BOARD_PARAMS_ADDR KSEG1ADDR(0x80000A00)
+#define PART_TABLE_ADDR KSEG1ADDR(0x80000C00)
+#define BOOT_PARAMS_ADDR KSEG1ADDR(0x80000E00)
+
+static struct myloader_info myloader_info __initdata;
+static int myloader_found __initdata;
+
+struct myloader_info * __init myloader_get_info(void)
+{
+ struct mylo_system_params *sysp;
+ struct mylo_board_params *boardp;
+ struct mylo_partition_table *parts;
+
+ if (myloader_found)
+ return &myloader_info;
+
+ sysp = (struct mylo_system_params *)(SYS_PARAMS_ADDR);
+ boardp = (struct mylo_board_params *)(BOARD_PARAMS_ADDR);
+ parts = (struct mylo_partition_table *)(PART_TABLE_ADDR);
+
+ printk(KERN_DEBUG "MyLoader: sysp=%08x, boardp=%08x, parts=%08x\n",
+ sysp->magic, boardp->magic, parts->magic);
+
+ /* Check for some magic numbers */
+ if (sysp->magic != MYLO_MAGIC_SYS_PARAMS ||
+ boardp->magic != MYLO_MAGIC_BOARD_PARAMS ||
+ le32_to_cpu(parts->magic) != MYLO_MAGIC_PARTITIONS)
+ return NULL;
+
+ printk(KERN_DEBUG "MyLoader: id=%04x:%04x, sub_id=%04x:%04x\n",
+ sysp->vid, sysp->did, sysp->svid, sysp->sdid);
+
+ myloader_info.vid = sysp->vid;
+ myloader_info.did = sysp->did;
+ myloader_info.svid = sysp->svid;
+ myloader_info.sdid = sysp->sdid;
+
+ memcpy(myloader_info.macs, boardp->addr, sizeof(myloader_info.macs));
+
+ myloader_found = 1;
+
+ return &myloader_info;
+}