Re: [OpenWrt-Devel] [PATCH] ar71xx/sysupgrade: use $magic_long instead of $magic when comparing with a 32-bit value

2011-10-30 Thread Gabor Juhos
2011.10.27. 15:54 keltezéssel, Daniel Golle írta:
 Aparently $magic_long was meant here instead of $magic when comparing with
 32-bit values.
 
 On Thu, Oct 27, 2011 at 10:02:39AM +0200, Gabor Juhos wrote:
 Good catch! However this change should go into a separate patch.
 Here it comes.

Applied, thanks!

Gabor
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] tor 0.2.2.34 update patch

2011-10-30 Thread Peter Wagner
Signed-off-by: Peter Wagner tripo...@gmx.at
diff --git a/net/tor/Makefile b/net/tor/Makefile
index f9a9ae0..f87ab26 100644
--- a/net/tor/Makefile
+++ b/net/tor/Makefile
@@ -8,13 +8,13 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=tor
-PKG_VERSION:=0.2.2.33
+PKG_VERSION:=0.2.2.34
 PKG_RELEASE:=1
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=https://www.torproject.org/dist \
 	https://archive.torproject.org/tor-package-archive
-PKG_MD5SUM:=ea99aba49694bb982d2fccc57a70d58e
+PKG_MD5SUM:=0f1bbb8e086ea2aba41ff7f898fcf3bd
 
 PKG_INSTALL:=1
 
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] Remove empty packages/libs/json-c

2011-10-30 Thread Nico
Done in r28684

Thanks,
--
-{Nico}
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] [PATCH v2 1/1] linux-atm: update solos-pci with latest upstream patches

2011-10-30 Thread Philip Prindeville
Fixes for the solos-pci driver.

- Corrects calculation of headroom for padding.
- Removes pointless debug messages.
- Expose Bis A and Bis M annex capabilities.
- Expose hardware revision.

Accepted upstream into netdev.

Signed-Off-By: Nathan Williams nat...@traverse.com.au
Acked-By: David Woodhouse david.woodho...@intel.com
Cc: David Miller da...@davemloft.net
---

Index: target/linux/generic/patches-3.0/050-linux-atm_nathan.patch
===
--- target/linux/generic/patches-3.0/050-linux-atm_nathan.patch (revision 0)
+++ target/linux/generic/patches-3.0/050-linux-atm_nathan.patch (revision 0)
@@ -0,0 +1,348 @@
+From: Nathan Williams nat...@traverse.com.au
+To: net...@vger.kernel.org
+Date: Wed, 05 Oct 2011 15:43:30 +1100
+Cc: linux-atm-gene...@lists.sourceforge.net,
+David Woodhouse dw...@infradead.org, linux-ker...@vger.kernel.org
+Subject: [Linux-ATM-General] [PATCH 1/4] atm: solos-pci: Add AnnexA/M
+   capability attributes
+
+BisACapability and BisMCapability allow users to
+force either Annex A or Annex M.
+
+Signed-off-by: Nathan Williams nat...@traverse.com.au
+---
+ drivers/atm/solos-attrlist.c |2 ++
+ 1 files changed, 2 insertions(+), 0 deletions(-)
+
+diff --git a/drivers/atm/solos-attrlist.c b/drivers/atm/solos-attrlist.c
+index 9a676ee..8092533 100644
+--- a/drivers/atm/solos-attrlist.c
 b/drivers/atm/solos-attrlist.c
+@@ -71,6 +71,8 @@ SOLOS_ATTR_RW(BisAForceSNRMarginDn)
+ SOLOS_ATTR_RW(BisMForceSNRMarginDn)
+ SOLOS_ATTR_RW(BisAMaxMargin)
+ SOLOS_ATTR_RW(BisMMaxMargin)
++SOLOS_ATTR_RW(BisACapability)
++SOLOS_ATTR_RW(BisMCapability)
+ SOLOS_ATTR_RW(AnnexAForceSNRMarginDn)
+ SOLOS_ATTR_RW(AnnexAMaxMargin)
+ SOLOS_ATTR_RW(AnnexMMaxMargin)
+
+From: Nathan Williams nat...@traverse.com.au
+To: net...@vger.kernel.org
+Date: Wed, 05 Oct 2011 15:44:17 +1100
+Cc: linux-atm-gene...@lists.sourceforge.net,
+David Woodhouse dw...@infradead.org, linux-ker...@vger.kernel.org
+Subject: [Linux-ATM-General] [PATCH 2/4] atm: solos-pci: Remove annoying
+   line of debugging
+
+len: %d isn't particularly useful for anyone and confuses users.
+
+Signed-off-by: Nathan Williams nat...@traverse.com.au
+---
+ drivers/atm/solos-pci.c |1 -
+ 1 files changed, 0 insertions(+), 1 deletions(-)
+
+diff --git a/drivers/atm/solos-pci.c b/drivers/atm/solos-pci.c
+index 5d1d076..bd01aa3 100644
+--- a/drivers/atm/solos-pci.c
 b/drivers/atm/solos-pci.c
+@@ -452,7 +452,6 @@ static ssize_t console_show(struct device *dev, struct 
device_attribute *attr,
+ 
+   len = skb-len;
+   memcpy(buf, skb-data, len);
+-  dev_dbg(card-dev-dev, len: %d\n, len);
+ 
+   kfree_skb(skb);
+   return len;
+From: Nathan Williams nat...@traverse.com.au
+To: net...@vger.kernel.org
+Date: Wed, 05 Oct 2011 15:45:15 +1100
+Cc: linux-atm-gene...@lists.sourceforge.net,
+David Woodhouse dw...@infradead.org, linux-ker...@vger.kernel.org
+Subject: [Linux-ATM-General] [PATCH 3/4] atm: solos-pci: Add support for
+   Geos GPIO pins
+
+Geos ADSL2+ routers have on-board Solos chipsets with some
+extra I/O pins and a push button connected to the FPGA.
+
+PCB version and variant numbers are also made available
+through the HardwareVersion and HardwareVariant attributes.
+
+Signed-off-by: Nathan Williams nat...@traverse.com.au
+---
+ drivers/atm/solos-pci.c |   98 +++
+ 1 files changed, 98 insertions(+), 0 deletions(-)
+
+diff --git a/drivers/atm/solos-pci.c b/drivers/atm/solos-pci.c
+index bd01aa3..33c0c2b 100644
+--- a/drivers/atm/solos-pci.c
 b/drivers/atm/solos-pci.c
+@@ -56,6 +56,7 @@
+ #define FLASH_BUSY0x60
+ #define FPGA_MODE 0x5C
+ #define FLASH_MODE0x58
++#define GPIO_STATUS   0x54
+ #define TX_DMA_ADDR(port) (0x40 + (4 * (port)))
+ #define RX_DMA_ADDR(port) (0x30 + (4 * (port)))
+ 
+@@ -498,6 +499,87 @@ static ssize_t console_store(struct device *dev, struct 
device_attribute *attr,
+   return err?:count;
+ }
+ 
++struct geos_gpio {
++  char *name;
++  int offset;
++};
++
++static struct geos_gpio geos_gpio_pins[] = {
++  {GPIO1, 9},
++  {GPIO2, 10},
++  {GPIO3, 11},
++  {GPIO4, 12},
++  {GPIO5, 13},
++  {PushButton, 14},
++  {NULL, 0}
++};
++
++static ssize_t geos_gpio_store(struct device *dev, struct device_attribute 
*attr,
++ const char *buf, size_t count)
++{
++  struct atm_dev *atmdev = container_of(dev, struct atm_dev, class_dev);
++  struct solos_card *card = atmdev-dev_data;
++  uint32_t data32;
++
++  struct geos_gpio *p = geos_gpio_pins;
++  while(p-name){
++  if(!strcmp(attr-attr.name, p-name)){
++  break;
++  }
++  p++;
++  }
++
++  data32 = ioread32(card-config_regs + GPIO_STATUS);
++  if(buf[0] == '1'){
++  data32 |= 1  p-offset;
++  iowrite32(data32, card-config_regs + 

[OpenWrt-Devel] paper on openwrt and ieee802.11

2011-10-30 Thread Andrea Imparato
Hello to all the mailing list,

I'm an italian computer science student and I wish to do on a university
project a presentation on how openwrt implements ieee802.11 and its
kernel architectural structure. Someone of you can point me to some
papers. 


Thank you so much


___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


Re: [OpenWrt-Devel] [OpenWrt-Commits] r28688 - in trunk/tools/firmware-utils: . src

2011-10-30 Thread Michael Büsch
On Sun, 30 Oct 2011 23:57:41 +0100
openwrt-comm...@openwrt.org wrote:

 Author: acinonyx
 Date: 2011-10-30 23:57:41 +0100 (Sun, 30 Oct 2011)
 New Revision: 28688

Just a few comments...

 --- trunk/tools/firmware-utils/src/mkedimaximg.c  
 (rev 0)
 +++ trunk/tools/firmware-utils/src/mkedimaximg.c  2011-10-30 22:57:41 UTC 
 (rev 28688)

 +#if (__BYTE_ORDER == __LITTLE_ENDIAN)
 +#  define HOST_TO_LE16(x)(x)
 +#  define HOST_TO_LE32(x)(x)
 +#else
 +#  define HOST_TO_LE16(x)bswap_16(x)
 +#  define HOST_TO_LE32(x)bswap_32(x)
 +#endif
 +
 +struct header
 +{
 +unsigned char sign[4];
 +unsigned int start;
 +unsigned int flash;
 +unsigned char model[4];
 +unsigned int size;
 +} __attribute__ ((packed));

 +static unsigned short fwcsum (struct buf *buf) {
 +int i;
 +unsigned short ret = 0;
 +
 +for (i = 0; i  buf-size / 2; i++)
 + ret -= ((unsigned short *) buf-start)[i];

It seems you need
ret -= LE16_TO_HOST(((unsigned short *) buf-start)[i]);
to be endianness safe.

 +if (header.sign == NULL) {
 + fprintf(stderr, no signature specified\n);
 + usage(EXIT_FAILURE);
 +}
 +
 +if (header.model == NULL) {
 + fprintf(stderr, no model specified\n);
 + usage(EXIT_FAILURE);
 +}

You are actually comparing arrays to NULL here. Seems an odd thing to do.
You probably want
if (!header.sign[0])
and
if (!header.model[0])
That ought to be good enough in this case.

-- 
Greetings, Michael.
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel


[OpenWrt-Devel] Is there a ticket or bug about add default routing?

2011-10-30 Thread 馬克泡
Hi all,

I'm using r28496 with AR71xx to do some testing.
However, I've found that when I'm doing dhcp on WAN side,
will manually add default routing, the operation cannot be success.

The WAN port is not ethernet, it is WiMAX interface (wimax0).
If I do ifconfig on eth0 (WAN) to set the ip of eth0 the same subnet
as default gateway, then the operation could be success.
However, I cannot add default gateway while the eth0 has no ip address,
or add default gateway with WiMAX interface (wimax0).

(package GCTWIMAX)

Do I miss something?
Thanks.

1. DHCP on WAN side,
ending discover...
Sending select for 111.67.48.58...
Lease of 111.67.48.58 obtained, lease time 3600
udhcpc: ifconfig wimax0 111.67.48.58 netmask 255.255.255.255 broadcast +
udhcpc: setting default routers: 111.67.48.1
route: SIOCADDRT: No such process
udhcpc: setting dns servers: 111.67.54.11 111.67.54.12
udhcpc: setting dns domain: vmax.net.tw

2. Manually add default gateway,
route add default gw 111.67.48.1
route: SIOCADDRT: No such process


-- 
Best regards,
Macpaul Lin
___
openwrt-devel mailing list
openwrt-devel@lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel