Moritz Warning | 17 May 00:38
Picon

[PATCH] Update tinc init script with new variable names

The tinc init script needs to know all valid options used in /etc/conf/tinc.
This patch updates that list to tinc 0.18 (current version). 

Signed-off-by: Moritz Warning <moritzwarning <at> web.de>

---

Index: net/tinc/files/tinc.init
===================================================================
--- net/tinc/files/tinc.init    (revision 31761)
+++ net/tinc/files/tinc.init    (working copy)
@@ -98,11 +98,12 @@

        # append flags
        append_conf_bools "$s" "$TMP_TINC/$n/hosts/$s" \
-               ClampMSS IndirectData PMTUDiscovery
+               ClampMSS IndirectData PMTUDiscovery TCPOnly

        # append params
        append_conf_params "$s" "$TMP_TINC/$n/hosts/$s" \
-               Address Cipher Compression Digest MACLength PMTU Port Subnet
+               Address Cipher Compression Digest MACLength PMTU \
+               Port PublicKey PublicKeyFile Subnet
 }

 check_gen_own_key() {
@@ -139,17 +140,20 @@

        # append flags
        append_conf_bools "$s" "$TMP_TINC/$s/tinc.conf" \
(Continue reading)

Picon
Gravatar

bug in selecting packages in the backfire buildroot

I found the following bug in the Backfire buildroot:

If package X is in a submenu, if it exist another package Y that
requires X, than X is not represented anymore in the submenu but at
the same hierarchy of this parent. Note that Y must exist and do not
need to be selected.

Because of this the subfolder of the plugins of the olsrd-package is
broken. As soon as you select olsrd, all the plugins will appear in
the list and _not_ in a subfolder.

This package has this behaviour:
https://dev.openwrt.org/browser/packages/net/olsrd

This package is identical,but with a different name, so not being
referenced by other packages it will not suffer from this bug.
https://github.com/ninuxorg/ninux-openwrt-packages/tree/stablepackages/olsrd-ninux

How can we fix this ?

Saverio
Massimo Vellucci | 16 May 15:50
Picon

support for All.net ALL0239-3G

This patch adds support for router All.net ALL0239-3G

I opened a ticket: https://dev.openwrt.org/ticket/11464
More information of device can be found in the link:
http://www.allnet-italia.it/boxbaseoff.php?clbox=0&pi=888022853&tit=Allnet%20Wireless%20N%20300Mbit%20Router/AP,%20HSPA%203Gt

Bye
Massimo
Attachment (all0239.patch): application/octet-stream, 9 KiB
_______________________________________________
openwrt-devel mailing list
openwrt-devel <at> lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Maxim Osipov | 16 May 13:12
Picon

problem with IPv6 traffic on SLIP interface

Hello,

I'm having a very strange problem with SLIP (tunslip6 from Contiki) on
OpenWRT (fon-ng) and hoping someone can help with investigation.

In short - wpan0 interface with address aaaa::1/64 is created.
ping6 to aaaa::1 is OK
ping6 to aaaa::250:c2a8:c3d4:a645 FAILS. But tcpdump shows ICMP6
requests and replies.
curl to border router web page also times out.

Any hint where the problem could be? Command lines and selected logs are below.

Kind regards,
Maxim

tunslip6 command line:
usr/bin/tunslip6 -B 9600 -s /dev/ttyUSB1 -t wpan0 aaaa::1/64

Interface is created and TX/RX packages (ifconfig output):
wpan0     Link encap:UNSPEC  HWaddr
00-00-00-00-00-00-00-00-00-00-00-00-00-00-00-00
         inet6 addr: fe80::1/64 Scope:Link
         inet6 addr: aaaa::1/64 Scope:Global
         UP POINTOPOINT RUNNING NOARP MULTICAST  MTU:1500  Metric:1
         RX packets:62 errors:0 dropped:0 overruns:0 frame:0
         TX packets:62 errors:0 dropped:0 overruns:0 carrier:0
         collisions:0 txqueuelen:500
         RX bytes:6448 (6.2 KiB)  TX bytes:6448 (6.2 KiB)

(Continue reading)

马进 | 15 May 08:46
Picon

No gdb found! Make sure that CONFIG_GDB is set!

Hi all,


I am trying to debug openwrt. 
I followed the instruction from http://wiki.openwrt.org/doc/devel/gdb

Everything works well but when 

scorpio <at> scorpio-desktop:~/mjproject/openwrt/buffalo/backfire$ ./scripts/remote-gdb 192.168.1.1:9000 ./staging_dir/target-mips_r2_uClibc-0.9.30.1/root-ar71xx/bin/ping
Choose target:
  1) mips (r2)
  2) i386 (uClibc-0.9.30.1)
Target? > 1
No gdb found! Make sure that CONFIG_GDB is set!

I don't why. CONFIG_GDB=y is set when I compiled openwrt. 
If I chose 2, then it works. But I think in order to debug the router(mips arch), I should choose 1.

What should I do?

Thank you.

Jin



_______________________________________________
openwrt-devel mailing list
openwrt-devel <at> lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Etienne Champetier | 15 May 01:11
Picon
Favicon

[PATCH] Update monit to 5.4 and bugfixes

Hi
this patch update monit from 5.2.5 to 5.4, this add cool feature like "check program", to execute a script
and send email/do action depending on the return code, and many bugfixes (http://mmonit.com/monit/dist/CHANGES.txt)
I've modified the init script because "-d 60" overide the conf file and the stat command doesn't seem to
exist, so either we just chmod each time or we let the people RTFM and the syslog (i prefer the latter)

For now i've tested only the ssl version with backfire (r31676) on x86 and ar71xx (tplink wr1043nd) (it send
mail via google, ping, watch load average and cpu ...)
It compile (monit and monit-nossl) for x86 and ar71xx for backfire & trunk (trunk x86 mount the ext4
partition readonly so i haven't tested)

Signed-off-by: Etienne CHAMPETIER <etienne.champetier <at> free.fr>
Index: files/monit.init
===================================================================
--- files/monit.init	(révision 31729)
+++ files/monit.init	(copie de travail)
@@ -1,5 +1,5 @@
 #!/bin/sh /etc/rc.common
-# Copyright (C) 2006-2011 OpenWrt.org
+# Copyright (C) 2006-2012 OpenWrt.org

 START=60

@@ -7,8 +7,8 @@

 start() {
 	[ -f /etc/monitrc ] || return 1
-	[ "$(stat -c "%a" /etc/monitrc)" = "0700" ] || chmod 0700 /etc/monitrc
-	service_start /usr/bin/monit -d 60
+	#chmod 0700 /etc/monitrc
+	service_start /usr/bin/monit
 }

 stop() {
Index: patches/001-no_sslv2.patch
===================================================================
--- patches/001-no_sslv2.patch	(révision 31729)
+++ patches/001-no_sslv2.patch	(copie de travail)
@@ -1,18 +0,0 @@
---- a/ssl.c
-+++ b/ssl.c
-@@ -635,6 +635,7 @@ ssl_connection *new_ssl_connection(char
- #endif
-     break;
- 
-+#ifndef OPENSSL_NO_SSLV2
-   case SSL_VERSION_SSLV2:
- #ifdef OPENSSL_FIPS
-     if (FIPS_mode()) {
-@@ -647,6 +648,7 @@ ssl_connection *new_ssl_connection(char
-     }
- #endif
-     break;
-+#endif
- 
-   case SSL_VERSION_SSLV3:
- #ifdef OPENSSL_FIPS
Index: patches/002-uclibc_loadavg.patch
===================================================================
--- patches/002-uclibc_loadavg.patch	(révision 31729)
+++ patches/002-uclibc_loadavg.patch	(copie de travail)
@@ -1,48 +0,0 @@
---- a/process/sysdep_LINUX.c
-+++ b/process/sysdep_LINUX.c
-@@ -144,6 +144,45 @@ static time_t get_starttime() {
- 
-   return time(NULL) - (time_t)up;
- }
-+
-+
-+/* uclibc and dietlibc do not have this junk -ReneR */
-+#if defined (__UCLIBC__) || defined (__dietlibc__)
-+static int getloadavg (double loadavg[], int nelem)
-+{
-+  int fd;
-+
-+  fd = open ("/proc/loadavg", O_RDONLY);
-+  if (fd < 0)
-+    return -1;
-+  else
-+    {
-+      char buf[65], *p;
-+      ssize_t nread;
-+      int i;
-+
-+      nread = read (fd, buf, sizeof buf - 1);
-+      close (fd);
-+      if (nread <= 0)
-+	return -1;
-+      buf[nread - 1] = '\0';
-+
-+      if (nelem > 3)
-+	nelem = 3;
-+      p = buf;
-+      for (i = 0; i < nelem; ++i)
-+	{
-+	  char *endp;
-+	  loadavg[i] = strtod (p, &endp);
-+	  if (endp == p)
-+	    return -1;
-+	  p = endp;
-+	}
-+
-+      return i;
-+    }
-+}
-+#endif
-   
- 
- /* ------------------------------------------------------------------ Public */
Index: Makefile
===================================================================
--- Makefile	(révision 31729)
+++ Makefile	(copie de travail)
@@ -8,12 +8,12 @@
 include $(TOPDIR)/rules.mk

 PKG_NAME:=monit
-PKG_VERSION:=5.2.5
-PKG_RELEASE:=2
+PKG_VERSION:=5.4
+PKG_RELEASE:=1

 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=http://mmonit.com/monit/dist
-PKG_MD5SUM:=862fb7939ad6f73fc0cc82096c2309c7
+PKG_MD5SUM:=f1f391241d44059d0d3e5d26f4ec5ddf

 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
 PKG_INSTALL:=1
@@ -55,6 +55,11 @@
 	This package is built without SSL support.
 endef

+CONFIGURE_ARGS += \
+	--without-pam \
+	libmonit_cv_setjmp_available=yes \
+	libmonit_cv_vsnprintf_c99_conformant=yes
+
 ifeq ($(BUILD_VARIANT),ssl)
 	CONFIGURE_ARGS += \
 		--with-ssl \
_______________________________________________
openwrt-devel mailing list
openwrt-devel <at> lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Pieter Voorthuijsen | 14 May 21:53
Picon

lantiq + ath9k: what to expect?

Hello,

I would like to know what kind of transfers speeds I can expect with
the recent ath9k driver.

On my xway chip in the dgn3500 I can create a 150Mbps connection. When
starting transfers, it peaks to 3,5Mib and after that drops to ~2. Is
this normal? With the original firmware transfer speeds of 6Mib were
possible....

Kind regards,
Conor O'Gorman | 14 May 18:39

ethernet carrier, udhcpc, hotplug

I don't seem to get udhcpc renewing a lease after plugging out/in the
ethernet cable.

I've checked that the carrier state is being signaled correctly via 'ip
link'. 

I imagined that either udhcpc directly, or hotplug indirectly, would
make the magic happen, ie. an attempted renewal.

Am I missing something? I would think this useful, as it may have been
plugged into a different network.

Thanks,
Conor
Matzka Gerald | 14 May 13:35
Picon
Favicon

[PATCH] Add support for php5 calendar module

Hi,

this patch adds calendar module support to php5

Signed-off-by: Gerald Matzka <mgerald21 <at> yahoo.de>

Index: feeds/packages/lang/php5/Makefile
===================================================================
--- feeds/packages/lang/php5/Makefile    (revision 31709)
+++ feeds/packages/lang/php5/Makefile    (working copy)
@@ -159,6 +159,10 @@
   CONFIGURE_ARGS+= --disable-apc
 endif

+ifneq ($(SDK)$(CONFIG_PACKAGE_php5-mod-calendar),)
+  CONFIGURE_ARGS+= --enable-calendar=shared
+endif
+
 ifneq ($(SDK)$(CONFIG_PACKAGE_php5-mod-ctype),)
   CONFIGURE_ARGS+= --enable-ctype=shared
 else
@@ -521,6 +525,7 @@

 #$(eval $(call BuildModule,NAME,TITLE[,PKG DEPENDS]))
 $(eval $(call BuildModule,apc,APC,+PACKAGE_php5-mod-apc:librt))
+$(eval $(call BuildModule,calendar,Calendar))
 $(eval $(call BuildModule,ctype,Ctype))
 $(eval $(call BuildModule,curl,cURL,+PACKAGE_php5-mod-curl:libcurl))
 $(eval $(call BuildModule,fileinfo,Fileinfo,+PACKAGE_php5-mod-fileinfo:libmagic))  
Daniel Golle | 14 May 00:07
Picon
Favicon

[PATCH 3/3] uboot-kirkwood: backport iconnect support to 2012.04.01

iconnect board support apparently used sheevaplug as a template as well, so
same game once again.

Signed-off-by: Daniel Golle <dgolle <at> allnet.de>

diff --git a/package/uboot-kirkwood/files/board/Marvell/iconnect/Makefile b/package/uboot-kirkwood/files/board/Marvell/iconnect/Makefile
index 0301f98..4ab7bc5 100644
--- a/package/uboot-kirkwood/files/board/Marvell/iconnect/Makefile
+++ b/package/uboot-kirkwood/files/board/Marvell/iconnect/Makefile
@@ -24,7 +24,7 @@

 include $(TOPDIR)/config.mk

-LIB	= $(obj)lib$(BOARD).a
+LIB	= $(obj)lib$(BOARD).o

 COBJS	:= iconnect.o

@@ -33,13 +33,7 @@ OBJS	:= $(addprefix $(obj),$(COBJS))
 SOBJS	:= $(addprefix $(obj),$(SOBJS))

 $(LIB):	$(obj).depend $(OBJS) $(SOBJS)
-	$(AR) $(ARFLAGS) $@ $(OBJS) $(SOBJS)
-
-clean:
-	rm -f $(SOBJS) $(OBJS)
-
-distclean:	clean
-	rm -f $(LIB) core *.bak .depend
+	$(call cmd_link_o_target, $(OBJS) $(SOBJS))

 #########################################################################

diff --git a/package/uboot-kirkwood/files/board/Marvell/iconnect/config.mk b/package/uboot-kirkwood/files/board/Marvell/iconnect/config.mk
deleted file mode 100644
index 2bd9f79..0000000
--- a/package/uboot-kirkwood/files/board/Marvell/iconnect/config.mk
+++ /dev/null
@@ -1,28 +0,0 @@
-#
-# (C) Copyright 2009
-# Marvell Semiconductor <www.marvell.com>
-# Written-by: Prafulla Wadaskar <prafulla <at> marvell.com>
-#
-# 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., 51 Franklin Street, Fifth Floor, Boston,
-# MA 02110-1301 USA
-#
-
-TEXT_BASE = 0x00600000
-
-# Kirkwood Boot Image configuration file
-KWD_CONFIG = $(SRCTREE)/board/$(BOARDDIR)/kwbimage.cfg
diff --git a/package/uboot-kirkwood/files/board/Marvell/iconnect/iconnect.c b/package/uboot-kirkwood/files/board/Marvell/iconnect/iconnect.c
index ee5d587..50640c3 100644
--- a/package/uboot-kirkwood/files/board/Marvell/iconnect/iconnect.c
+++ b/package/uboot-kirkwood/files/board/Marvell/iconnect/iconnect.c
@@ -24,13 +24,14 @@

 #include <common.h>
 #include <miiphy.h>
+#include <asm/arch/cpu.h>
 #include <asm/arch/kirkwood.h>
 #include <asm/arch/mpp.h>
 #include "iconnect.h"

 DECLARE_GLOBAL_DATA_PTR;

-int board_init(void)
+int board_early_init_f(void)
 {
 	/*
 	 * default gpio configuration
@@ -94,9 +95,13 @@ int board_init(void)
 		MPP48_GPIO,
 		MPP49_GPIO,
 		0
-};
+	};
 	kirkwood_mpp_conf(kwmpp_config);
+	return 0;
+}

+int board_init(void)
+{
 	/*
 	 * arch number of board
 	 */
@@ -108,17 +113,6 @@ int board_init(void)
 	return 0;
 }

-int dram_init(void)
-{
-	int i;
-
-	for (i = 0; i < CONFIG_NR_DRAM_BANKS; i++) {
-		gd->bd->bi_dram[i].start = kw_sdram_bar(i);
-		gd->bd->bi_dram[i].size = kw_sdram_bs(i);
-	}
-	return 0;
-}
-
 #ifdef CONFIG_RESET_PHY_R
 /* Configure and enable MV88E1116 PHY */
 void reset_phy(void)
diff --git a/package/uboot-kirkwood/files/include/configs/iconnect.h b/package/uboot-kirkwood/files/include/configs/iconnect.h
index 434397a..5435329 100644
--- a/package/uboot-kirkwood/files/include/configs/iconnect.h
+++ b/package/uboot-kirkwood/files/include/configs/iconnect.h
@@ -37,83 +37,32 @@
 /*
  * High Level Configuration Options (easy to change)
  */
-#define CONFIG_MARVELL		1
-#define CONFIG_ARM926EJS	1	/* Basic Architecture */
 #define CONFIG_FEROCEON_88FR131	1	/* CPU Core subversion */
 #define CONFIG_KIRKWOOD		1	/* SOC Family Name */
 #define CONFIG_KW88F6281	1	/* SOC Name */
 #define CONFIG_MACH_ICONNECT	/* Machine type */
-
-#define CONFIG_MD5	/* get_random_hex on krikwood needs MD5 support */
 #define CONFIG_SKIP_LOWLEVEL_INIT	/* disable board lowlevel_init */
 #define CONFIG_KIRKWOOD_EGIGA_INIT	/* Enable GbePort0/1 for kernel */
-#define CONFIG_KIRKWOOD_RGMII_PAD_1V8	/* Set RGMII Pad voltage to 1.8V */
-#define CONFIG_KIRKWOOD_PCIE_INIT	/*enable pci express on iconnect board*/
-
-/*
- * CLKs configurations
- */
-#define CONFIG_SYS_HZ		1000
-
-/*
- * NS16550 Configuration
- */
-#define CONFIG_SYS_NS16550
-#define CONFIG_SYS_NS16550_SERIAL
-#define CONFIG_SYS_NS16550_REG_SIZE	(-4)
-#define CONFIG_SYS_NS16550_CLK		CONFIG_SYS_TCLK
-#define CONFIG_SYS_NS16550_COM1		KW_UART0_BASE
-
-/*
- * Serial Port configuration
- * The following definitions let you select what serial you want to use
- * for your console driver.
- */
-
-#define CONFIG_CONS_INDEX	1	/*Console on UART0 */
-#define CONFIG_BAUDRATE			115200
-#define CONFIG_SYS_BAUDRATE_TABLE	{ 9600, 19200, 38400, 57600, \
-					  115200,230400, 460800, 921600 }
-/* auto boot */
-#define CONFIG_BOOTDELAY	3	/* default enable autoboot */
-
-/*
- * For booting Linux, the board info and command line data
- * have to be in the first 8 MB of memory, since this is
- * the maximum mapped by the Linux kernel during initialization.
- */
-#define CONFIG_CMDLINE_TAG	1	/* enable passing of ATAGs  */
-#define CONFIG_INITRD_TAG	1	/* enable INITRD tag */
-#define CONFIG_SETUP_MEMORY_TAGS 1	/* enable memory tag */
-
-#define	CONFIG_SYS_PROMPT	"Marvell>> "	/* Command Prompt */
-#define	CONFIG_SYS_CBSIZE	1024	/* Console I/O Buff Size */
-#define	CONFIG_SYS_PBSIZE	(CONFIG_SYS_CBSIZE \
-		+sizeof(CONFIG_SYS_PROMPT) + 16)	/* Print Buff */

 /*
  * Commands configuration
  */
 #define CONFIG_SYS_NO_FLASH		/* Declare no flash (NOR/SPI) */
 #include <config_cmd_default.h>
-#define CONFIG_CMD_AUTOSCRIPT
 #define CONFIG_CMD_DHCP
 #define CONFIG_CMD_ENV
 #define CONFIG_CMD_MII
 #define CONFIG_CMD_NAND
 #define CONFIG_CMD_PING
 #define CONFIG_CMD_USB
+#define CONFIG_CMD_IDE
+#define CONFIG_SYS_MVFS

 /*
- * NAND configuration
+ * mv-common.h should be defined after CMD configs since it used them
+ * to enable certain macros
  */
-#ifdef CONFIG_CMD_NAND
-#define CONFIG_NAND_KIRKWOOD
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
-#define NAND_MAX_CHIPS			1
-#define CONFIG_SYS_NAND_BASE		0xD8000000	/* KW_DEFADR_NANDF */
-#define NAND_ALLOW_ERASE_ALL		1
-#endif
+#include "mv-common.h"

 /*
  *  Environment variables configurations
@@ -149,285 +98,19 @@
 	"x_bootargs_root=root=/dev/mtdblock2 rw rootfstype=jffs2\0"

 /*
- * Size of malloc() pool
- */
-#define CONFIG_SYS_MALLOC_LEN	(1024 * 1024) /* 1 MiB for malloc() */
-/* size in bytes reserved for initial data */
-#define CONFIG_SYS_GBL_DATA_SIZE	128
-
-/*
- * Other required minimal configurations
- */
-#define CONFIG_SYS_LONGHELP
-#define CONFIG_AUTO_COMPLETE
-#define CONFIG_CMDLINE_EDITING
-#define CONFIG_ARCH_CPU_INIT	/* call arch_cpu_init() */
-#define CONFIG_ARCH_MISC_INIT	/* call arch_misc_init() */
-#define CONFIG_DISPLAY_CPUINFO	/* Display cpu info */
-#define CONFIG_NR_DRAM_BANKS	4
-#define CONFIG_STACKSIZE	0x00100000	/* regular stack- 1M */
-#define CONFIG_SYS_LOAD_ADDR	0x00800000	/* default load adr- 8M */
-#define CONFIG_SYS_MEMTEST_START 0x00400000	/* 4M */
-#define CONFIG_SYS_MEMTEST_END	0x007fffff	/*(_8M -1) */
-#define CONFIG_SYS_RESET_ADDRESS 0xffff0000	/* Rst Vector Adr */
-#define CONFIG_SYS_MAXARGS	16	/* max number of command args */
-
-/*
  * Ethernet Driver configuration
  */
 #ifdef CONFIG_CMD_NET
-#define CONFIG_NETCONSOLE	/* include NetConsole support   */
-#define CONFIG_NET_MULTI	/* specify more that one ports available */
-#define	CONFIG_MII		/* expose smi ove miiphy interface */
-#define CONFIG_MVGBE	/* Enable kirkwood Gbe Controller Driver */
-#define CONFIG_SYS_FAULT_ECHO_LINK_DOWN	/* detect link using phy */
 #define CONFIG_MVGBE_PORTS	{1,0}	/* enable port 0 only */
 #define CONFIG_PHY_BASE_ADR	11
-#define CONFIG_ENV_OVERWRITE	/* ethaddr can be reprogrammed */
-#define CONFIG_RESET_PHY_R	/* use reset_phy() to init mv8831116 PHY */
 #endif /* CONFIG_CMD_NET */

 /*
- * USB/EHCI
- */
-#ifdef CONFIG_CMD_USB
-#define CONFIG_USB_EHCI			/* Enable EHCI USB support */
-#define CONFIG_USB_EHCI_KIRKWOOD	/* on Kirkwood platform	*/
-#define CONFIG_EHCI_IS_TDI
-#define CONFIG_USB_STORAGE
-#define CONFIG_DOS_PARTITION
-#define CONFIG_ISO_PARTITION
-#define CONFIG_SUPPORT_VFAT
-#endif /* CONFIG_CMD_USB */
-
-/*
- * File system
- */
-#define CONFIG_CMD_EXT2
-#define CONFIG_CMD_FAT
-#define CONFIG_CMD_JFFS2
-#define CONFIG_CMD_UBI
-#define CONFIG_CMD_UBIFS
-#define CONFIG_RBTREE
-#define CONFIG_MTD_DEVICE               /* needed for mtdparts commands */
-#define CONFIG_MTD_PARTITIONS
-#define CONFIG_CMD_MTDPARTS
-#define CONFIG_LZO
-
-#endif /* _CONFIG_SHEEVAPLUG_H */
-/*
- * (C) Copyright 2009
- * Marvell Semiconductor <www.marvell.com>
- * Written-by: Prafulla Wadaskar <prafulla <at> marvell.com>
- *
- * 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., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301 USA
- */
-
-#ifndef _CONFIG_ICONNECT_H
-#define _CONFIG_ICONNECT_H
-
-/*
- * Version number information
- */
-#define CONFIG_IDENT_STRING	"\nIomega iConnect Wireless"
-
-
-//#define DEBUG
-
-
-/*
- * High Level Configuration Options (easy to change)
- */
-#define CONFIG_MARVELL		1
-#define CONFIG_ARM926EJS	1	/* Basic Architecture */
-#define CONFIG_FEROCEON_88FR131	1	/* CPU Core subversion */
-#define CONFIG_KIRKWOOD		1	/* SOC Family Name */
-#define CONFIG_KW88F6281	1	/* SOC Name */
-#define CONFIG_MACH_ICONNECT	/* Machine type */
-
-#define CONFIG_MD5	/* get_random_hex on krikwood needs MD5 support */
-#define CONFIG_SKIP_LOWLEVEL_INIT	/* disable board lowlevel_init */
-#define CONFIG_KIRKWOOD_EGIGA_INIT	/* Enable GbePort0/1 for kernel */
-#define CONFIG_KIRKWOOD_RGMII_PAD_1V8	/* Set RGMII Pad voltage to 1.8V */
-
-/*
- * CLKs configurations
- */
-#define CONFIG_SYS_HZ		1000
-
-/*
- * NS16550 Configuration
- */
-#define CONFIG_SYS_NS16550
-#define CONFIG_SYS_NS16550_SERIAL
-#define CONFIG_SYS_NS16550_REG_SIZE	(-4)
-#define CONFIG_SYS_NS16550_CLK		CONFIG_SYS_TCLK
-#define CONFIG_SYS_NS16550_COM1		KW_UART0_BASE
-
-/*
- * Serial Port configuration
- * The following definitions let you select what serial you want to use
- * for your console driver.
- */
-
-#define CONFIG_CONS_INDEX	1	/*Console on UART0 */
-#define CONFIG_BAUDRATE			115200
-#define CONFIG_SYS_BAUDRATE_TABLE	{ 9600, 19200, 38400, 57600, \
-					  115200,230400, 460800, 921600 }
-/* auto boot */
-#define CONFIG_BOOTDELAY	3	/* default enable autoboot */
-
-/*
- * For booting Linux, the board info and command line data
- * have to be in the first 8 MB of memory, since this is
- * the maximum mapped by the Linux kernel during initialization.
- */
-#define CONFIG_CMDLINE_TAG	1	/* enable passing of ATAGs  */
-#define CONFIG_INITRD_TAG	1	/* enable INITRD tag */
-#define CONFIG_SETUP_MEMORY_TAGS 1	/* enable memory tag */
-
-#define	CONFIG_SYS_PROMPT	"Marvell>> "	/* Command Prompt */
-#define	CONFIG_SYS_CBSIZE	1024	/* Console I/O Buff Size */
-#define	CONFIG_SYS_PBSIZE	(CONFIG_SYS_CBSIZE \
-		+sizeof(CONFIG_SYS_PROMPT) + 16)	/* Print Buff */
-
-/*
- * Commands configuration
- */
-#define CONFIG_SYS_NO_FLASH		/* Declare no flash (NOR/SPI) */
-#include <config_cmd_default.h>
-#define CONFIG_CMD_AUTOSCRIPT
-#define CONFIG_CMD_DHCP
-#define CONFIG_CMD_ENV
-#define CONFIG_CMD_MII
-#define CONFIG_CMD_NAND
-#define CONFIG_CMD_PING
-#define CONFIG_CMD_USB
-
-/*
- * NAND configuration
- */
-#ifdef CONFIG_CMD_NAND
-#define CONFIG_NAND_KIRKWOOD
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
-#define NAND_MAX_CHIPS			1
-#define CONFIG_SYS_NAND_BASE		0xD8000000	/* KW_DEFADR_NANDF */
-#define NAND_ALLOW_ERASE_ALL		1
-#endif
-
-/*
- *  Environment variables configurations
- */
-#ifdef CONFIG_CMD_NAND
-#define CONFIG_ENV_IS_IN_NAND		1
-#define CONFIG_ENV_SECT_SIZE		0x20000	/* 128K */
-#else
-#define CONFIG_ENV_IS_NOWHERE		1	/* if env in SDRAM */
-#endif
-/*
- * max 4k env size is enough, but in case of nand
- * it has to be rounded to sector size
- */
-#define CONFIG_ENV_SIZE			0x20000	/* 128k */
-#define CONFIG_ENV_ADDR			0xc0000  /*it's above original iConnect u-boot envirinment 0xa0000 */
-#define CONFIG_ENV_OFFSET		0xc0000	/* env starts here */
-
-/*
- * Default environment variables
- */
-#define CONFIG_BOOTCOMMAND		"${x_bootcmd_kernel}; "	\
-	"setenv bootargs ${x_bootargs} ${x_bootargs_root}; "	\
-	"${x_bootcmd_usb}; bootm 0x6400000;"
-
-#define CONFIG_MTDPARTS		"orion_nand:1M(u-boot),"	\
-	"3M <at> 1M(kernel),64M <at> 4M(rootfs),443M <at> 68M(data) rw\0"
-
-#define CONFIG_EXTRA_ENV_SETTINGS	"x_bootargs=console"	\
-	"=ttyS0,115200 mtdparts="CONFIG_MTDPARTS	\
-	"x_bootcmd_kernel=nand read 0x6400000 0x100000 0x300000\0" \
-	"x_bootcmd_usb=usb start\0" \
-	"x_bootargs_root=root=/dev/mtdblock3 rw rootfstype=jffs2\0"
-
-/*
- * Size of malloc() pool
- */
-#define CONFIG_SYS_MALLOC_LEN	(1024 * 1024) /* 1 MiB for malloc() */
-/* size in bytes reserved for initial data */
-#define CONFIG_SYS_GBL_DATA_SIZE	128
-
-/*
- * Other required minimal configurations
- */
-#define CONFIG_SYS_LONGHELP
-#define CONFIG_AUTO_COMPLETE
-#define CONFIG_CMDLINE_EDITING
-#define CONFIG_ARCH_CPU_INIT	/* call arch_cpu_init() */
-#define CONFIG_ARCH_MISC_INIT	/* call arch_misc_init() */
-#define CONFIG_DISPLAY_CPUINFO	/* Display cpu info */
-#define CONFIG_NR_DRAM_BANKS	4
-#define CONFIG_STACKSIZE	0x00100000	/* regular stack- 1M */
-#define CONFIG_SYS_LOAD_ADDR	0x00800000	/* default load adr- 8M */
-#define CONFIG_SYS_MEMTEST_START 0x00400000	/* 4M */
-#define CONFIG_SYS_MEMTEST_END	0x007fffff	/*(_8M -1) */
-#define CONFIG_SYS_RESET_ADDRESS 0xffff0000	/* Rst Vector Adr */
-#define CONFIG_SYS_MAXARGS	16	/* max number of command args */
-
-/*
- * Ethernet Driver configuration
- */
-#ifdef CONFIG_CMD_NET
-#define CONFIG_NETCONSOLE	/* include NetConsole support   */
-#define CONFIG_NET_MULTI	/* specify more that one ports available */
-#define	CONFIG_MII		/* expose smi ove miiphy interface */
-#define CONFIG_MVGBE	/* Enable kirkwood Gbe Controller Driver */
-#define CONFIG_SYS_FAULT_ECHO_LINK_DOWN	/* detect link using phy */
-#define CONFIG_MVGBE_PORTS	{1,0}	/* enable port 0 only */
-#define CONFIG_PHY_BASE_ADR	11
-#define CONFIG_ENV_OVERWRITE	/* ethaddr can be reprogrammed */
-#define CONFIG_RESET_PHY_R	/* use reset_phy() to init mv8831116 PHY */
-#endif /* CONFIG_CMD_NET */
-
-/*
- * USB/EHCI
- */
-#ifdef CONFIG_CMD_USB
-#define CONFIG_USB_EHCI			/* Enable EHCI USB support */
-#define CONFIG_USB_EHCI_KIRKWOOD	/* on Kirkwood platform	*/
-#define CONFIG_EHCI_IS_TDI
-#define CONFIG_USB_STORAGE
-#define CONFIG_DOS_PARTITION
-#define CONFIG_ISO_PARTITION
-#define CONFIG_SUPPORT_VFAT
-#endif /* CONFIG_CMD_USB */
-
-/*
- * File system
+ * SATA Driver configuration
  */
-#define CONFIG_CMD_EXT2
-#define CONFIG_CMD_FAT
-#define CONFIG_CMD_JFFS2
-#define CONFIG_CMD_UBI
-#define CONFIG_CMD_UBIFS
-#define CONFIG_RBTREE
-#define CONFIG_MTD_DEVICE               /* needed for mtdparts commands */
-#define CONFIG_MTD_PARTITIONS
-#define CONFIG_CMD_MTDPARTS
-#define CONFIG_LZO
+#ifdef CONFIG_MVSATA_IDE
+#define CONFIG_SYS_ATA_IDE0_OFFSET     MV_SATA_PORT0_OFFSET
+#define CONFIG_SYS_ATA_IDE1_OFFSET     MV_SATA_PORT1_OFFSET
+#endif /*CONFIG_MVSATA_IDE*/

-#endif /* _CONFIG_SHEEVAPLUG_H */
+#endif /* _CONFIG_ICONNECT_H */
_______________________________________________
openwrt-devel mailing list
openwrt-devel <at> lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel
Daniel Golle | 14 May 00:05
Picon
Favicon

[PATCH 2/3] uboot-kirkwood: backport dockstar board support to 2012.04.01

dockstar board support is based on sheevaplug, all changes made upstream to
sheevaplug were made for dockstar as well.

Signed-off-by: Daniel Golle <dgolle <at> allnet.de>

diff --git a/package/uboot-kirkwood/files/board/Marvell/dockstar/Makefile b/package/uboot-kirkwood/files/board/Marvell/dockstar/Makefile
index da9d29e..8436fd6 100644
--- a/package/uboot-kirkwood/files/board/Marvell/dockstar/Makefile
+++ b/package/uboot-kirkwood/files/board/Marvell/dockstar/Makefile
@@ -24,7 +24,7 @@

 include $(TOPDIR)/config.mk

-LIB	= $(obj)lib$(BOARD).a
+LIB	= $(obj)lib$(BOARD).o

 COBJS	:= dockstar.o

@@ -33,13 +33,7 @@ OBJS	:= $(addprefix $(obj),$(COBJS))
 SOBJS	:= $(addprefix $(obj),$(SOBJS))

 $(LIB):	$(obj).depend $(OBJS) $(SOBJS)
-	$(AR) $(ARFLAGS) $@ $(OBJS) $(SOBJS)
-
-clean:
-	rm -f $(SOBJS) $(OBJS)
-
-distclean:	clean
-	rm -f $(LIB) core *.bak .depend
+	$(call cmd_link_o_target, $(OBJS) $(SOBJS))

 #########################################################################

diff --git a/package/uboot-kirkwood/files/board/Marvell/dockstar/config.mk b/package/uboot-kirkwood/files/board/Marvell/dockstar/config.mk
deleted file mode 100644
index 1766412..0000000
--- a/package/uboot-kirkwood/files/board/Marvell/dockstar/config.mk
+++ /dev/null
@@ -1,28 +0,0 @@
-#
-# (C) Copyright 2009
-# Marvell Semiconductor <www.marvell.com>
-# Written-by: Prafulla Wadaskar <prafulla <at> marvell.com>
-#
-# 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., 51 Franklin Street, Fifth Floor, Boston,
-# MA 02110-1301 USA
-#
-
-TEXT_BASE = 0x00800000
-
-# Kirkwood Boot Image configuration file
-KWD_CONFIG = $(SRCTREE)/board/$(BOARDDIR)/kwbimage.cfg
diff --git a/package/uboot-kirkwood/files/board/Marvell/dockstar/dockstar.c b/package/uboot-kirkwood/files/board/Marvell/dockstar/dockstar.c
index 13cd347..03460cb 100644
--- a/package/uboot-kirkwood/files/board/Marvell/dockstar/dockstar.c
+++ b/package/uboot-kirkwood/files/board/Marvell/dockstar/dockstar.c
@@ -24,13 +24,14 @@

 #include <common.h>
 #include <miiphy.h>
+#include <asm/arch/cpu.h>
 #include <asm/arch/kirkwood.h>
 #include <asm/arch/mpp.h>
 #include "dockstar.h"

 DECLARE_GLOBAL_DATA_PTR;

-int board_init(void)
+int board_early_init_f(void)
 {
 	/*
 	 * default gpio configuration
@@ -96,7 +97,11 @@ int board_init(void)
 		0
 	};
 	kirkwood_mpp_conf(kwmpp_config);
+	return 0;
+}

+int board_init(void)
+{
 	/*
 	 * arch number of board
 	 */
@@ -108,17 +113,6 @@ int board_init(void)
 	return 0;
 }

-int dram_init(void)
-{
-	int i;
-
-	for (i = 0; i < CONFIG_NR_DRAM_BANKS; i++) {
-		gd->bd->bi_dram[i].start = kw_sdram_bar(i);
-		gd->bd->bi_dram[i].size = kw_sdram_bs(i);
-	}
-	return 0;
-}
-
 #ifdef CONFIG_RESET_PHY_R
 /* Configure and enable MV88E1116 PHY */
 void reset_phy(void)
diff --git a/package/uboot-kirkwood/files/include/configs/dockstar.h b/package/uboot-kirkwood/files/include/configs/dockstar.h
index e19552c..c81b6d2 100644
--- a/package/uboot-kirkwood/files/include/configs/dockstar.h
+++ b/package/uboot-kirkwood/files/include/configs/dockstar.h
@@ -22,92 +22,42 @@
  * MA 02110-1301 USA
  */

-#ifndef _CONFIG_SHEEVAPLUG_H
-#define _CONFIG_SHEEVAPLUG_H
+#ifndef _CONFIG_DOCKSTAR_H
+#define _CONFIG_DOCKSTAR_H

 /*
  * Version number information
  */
-#define CONFIG_IDENT_STRING	"\nMarvell-Sheevaplug"
+#define CONFIG_IDENT_STRING	"\nSeagate-Dockstar"

 /*
  * High Level Configuration Options (easy to change)
  */
-#define CONFIG_MARVELL		1
-#define CONFIG_ARM926EJS	1	/* Basic Architecture */
 #define CONFIG_FEROCEON_88FR131	1	/* CPU Core subversion */
 #define CONFIG_KIRKWOOD		1	/* SOC Family Name */
 #define CONFIG_KW88F6281	1	/* SOC Name */
 #define CONFIG_MACH_SHEEVAPLUG	/* Machine type */
-
-#define CONFIG_MD5	/* get_random_hex on krikwood needs MD5 support */
 #define CONFIG_SKIP_LOWLEVEL_INIT	/* disable board lowlevel_init */
-#define CONFIG_KIRKWOOD_EGIGA_INIT	/* Enable GbePort0/1 for kernel */
-#define CONFIG_KIRKWOOD_RGMII_PAD_1V8	/* Set RGMII Pad voltage to 1.8V */
-
-/*
- * CLKs configurations
- */
-#define CONFIG_SYS_HZ		1000
-
-/*
- * NS16550 Configuration
- */
-#define CONFIG_SYS_NS16550
-#define CONFIG_SYS_NS16550_SERIAL
-#define CONFIG_SYS_NS16550_REG_SIZE	(-4)
-#define CONFIG_SYS_NS16550_CLK		CONFIG_SYS_TCLK
-#define CONFIG_SYS_NS16550_COM1		KW_UART0_BASE
-
-/*
- * Serial Port configuration
- * The following definitions let you select what serial you want to use
- * for your console driver.
- */
-
-#define CONFIG_CONS_INDEX	1	/*Console on UART0 */
-#define CONFIG_BAUDRATE			115200
-#define CONFIG_SYS_BAUDRATE_TABLE	{ 9600, 19200, 38400, 57600, \
-					  115200,230400, 460800, 921600 }
-/* auto boot */
-#define CONFIG_BOOTDELAY	3	/* default enable autoboot */

 /*
- * For booting Linux, the board info and command line data
- * have to be in the first 8 MB of memory, since this is
- * the maximum mapped by the Linux kernel during initialization.
- */
-#define CONFIG_CMDLINE_TAG	1	/* enable passing of ATAGs  */
-#define CONFIG_INITRD_TAG	1	/* enable INITRD tag */
-#define CONFIG_SETUP_MEMORY_TAGS 1	/* enable memory tag */
-
-#define	CONFIG_SYS_PROMPT	"Marvell>> "	/* Command Prompt */
-#define	CONFIG_SYS_CBSIZE	1024	/* Console I/O Buff Size */
-#define	CONFIG_SYS_PBSIZE	(CONFIG_SYS_CBSIZE \
-		+sizeof(CONFIG_SYS_PROMPT) + 16)	/* Print Buff */
-/*
  * Commands configuration
  */
 #define CONFIG_SYS_NO_FLASH		/* Declare no flash (NOR/SPI) */
 #include <config_cmd_default.h>
-#define CONFIG_CMD_AUTOSCRIPT
 #define CONFIG_CMD_DHCP
 #define CONFIG_CMD_ENV
 #define CONFIG_CMD_FAT
 #define CONFIG_CMD_NAND
 #define CONFIG_CMD_PING
 #define CONFIG_CMD_USB
+#define CONFIG_CMD_IDE
+#define CONFIG_SYS_MVFS

 /*
- * NAND configuration
+ * mv-common.h should be defined after CMD configs since it used them
+ * to enable certain macros
  */
-#ifdef CONFIG_CMD_NAND
-#define CONFIG_NAND_KIRKWOOD
-#define CONFIG_SYS_MAX_NAND_DEVICE	1
-#define NAND_MAX_CHIPS			1
-#define CONFIG_SYS_NAND_BASE		0xD8000000	/* KW_DEFADR_NANDF */
-#define NAND_ALLOW_ERASE_ALL		1
-#endif
+#include "mv-common.h"

 /*
  *  Environment variables configurations
@@ -144,55 +94,19 @@
 	"x_bootargs_root=root=/dev/mtdblock3 rw rootfstype=jffs2\0"

 /*
- * Size of malloc() pool
- */
-#define CONFIG_SYS_MALLOC_LEN	(1024 * 128) /* 128kB for malloc() */
-/* size in bytes reserved for initial data */
-#define CONFIG_SYS_GBL_DATA_SIZE	128
-
-/*
- * Other required minimal configurations
- */
-#define CONFIG_CONSOLE_INFO_QUIET	/* some code reduction */
-#define CONFIG_ARCH_CPU_INIT	/* call arch_cpu_init() */
-#define CONFIG_ARCH_MISC_INIT	/* call arch_misc_init() */
-#define CONFIG_DISPLAY_CPUINFO	/* Display cpu info */
-#define CONFIG_NR_DRAM_BANKS	4
-#define CONFIG_STACKSIZE	0x00100000	/* regular stack- 1M */
-#define CONFIG_SYS_LOAD_ADDR	0x00800000	/* default load adr- 8M */
-#define CONFIG_SYS_MEMTEST_START 0x00400000	/* 4M */
-#define CONFIG_SYS_MEMTEST_END	0x007fffff	/*(_8M -1) */
-#define CONFIG_SYS_RESET_ADDRESS 0xffff0000	/* Rst Vector Adr */
-#define CONFIG_SYS_MAXARGS	16	/* max number of command args */
-
-/*
  * Ethernet Driver configuration
  */
 #ifdef CONFIG_CMD_NET
-#define CONFIG_NETCONSOLE	/* include NetConsole support   */
-#define CONFIG_NET_MULTI	/* specify more that one ports available */
-#define	CONFIG_MII		/* expose smi ove miiphy interface */
-#define CONFIG_MVGBE	/* Enable kirkwood Gbe Controller Driver */
-#define CONFIG_SYS_FAULT_ECHO_LINK_DOWN	/* detect link using phy */
 #define CONFIG_MVGBE_PORTS	{1,0}	/* enable port 0 only */
 #define CONFIG_PHY_BASE_ADR	0
-#define CONFIG_ENV_OVERWRITE	/* ethaddr can be reprogrammed */
-#define CONFIG_RESET_PHY_R	/* use reset_phy() to init mv8831116 PHY */
 #endif /* CONFIG_CMD_NET */

 /*
- * USB/EHCI
+ * SATA Driver configuration
  */
-#ifdef CONFIG_CMD_USB
-#define CONFIG_USB_EHCI			/* Enable EHCI USB support */
-#define CONFIG_USB_EHCI_KIRKWOOD	/* on Kirkwood platform	*/
-#define CONFIG_EHCI_IS_TDI
-#define CONFIG_USB_STORAGE
-#define CONFIG_DOS_PARTITION
-#define CONFIG_ISO_PARTITION
-#define CONFIG_SUPPORT_VFAT
-#endif /* CONFIG_CMD_USB */
+#ifdef CONFIG_MVSATA_IDE
+#define CONFIG_SYS_ATA_IDE0_OFFSET     MV_SATA_PORT0_OFFSET
+#define CONFIG_SYS_ATA_IDE1_OFFSET     MV_SATA_PORT1_OFFSET
+#endif /*CONFIG_MVSATA_IDE*/

-#define CONFIG_SERVERIP	169.254.254.254
-#define CONFIG_IPADDR	169.254.254.243
-#endif /* _CONFIG_SHEEVAPLUG_H */
+#endif /* _CONFIG_DOCKSTAR_H */
_______________________________________________
openwrt-devel mailing list
openwrt-devel <at> lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel

Gmane