1 (edited by gianfranco74 2010-03-13 14:52:55)

Topic: Alice Gate W2+ "Vela" brcm63xx-based router

Hi all,

I've just posted a patch that allows to build an image for the router in subject against the latest svn (20072 if I recall properly). This is my post
https://lists.openwrt.org/pipermail/openwrt-devel/2010-March/006265.html
and hereunder is the patch that can be easily adapted also to the Alice Gate2 Plus Wi-Fi ( AGA ):

Index: target/linux/brcm63xx/patches-2.6.32/099-cfi_probe_error.patch
===================================================================
--- target/linux/brcm63xx/patches-2.6.32/099-cfi_probe_error.patch    (revision 0)
+++ target/linux/brcm63xx/patches-2.6.32/099-cfi_probe_error.patch    (revision 0)
@@ -0,0 +1,14 @@
+--- a/drivers/mtd/chips/gen_probe.c
++++ b/drivers/mtd/chips/gen_probe.c
+@@ -127,9 +127,9 @@
+      * chip in read mode.
+      */
+ 
+-    for (i = 1; i < max_chips; i++) {
++    /*for (i = 1; i < max_chips; i++) {
+         cp->probe_chip(map, i << cfi.chipshift, chip_map, &cfi);
+-    }
++    }*/
+ 
+     /*
+      * Now allocate the space for the structures we need to return to
Index: target/linux/brcm63xx/patches-2.6.32/131-board_AG3.patch
===================================================================
--- target/linux/brcm63xx/patches-2.6.32/131-board_AG3.patch    (revision 0)
+++ target/linux/brcm63xx/patches-2.6.32/131-board_AG3.patch    (revision 0)
@@ -0,0 +1,40 @@
+Index: linux-2.6.32.9/arch/mips/bcm63xx/boards/board_bcm963xx.c
+===================================================================
+--- linux-2.6.32.9/arch/mips/bcm63xx/boards/board_bcm963xx.c    (revision 20072)
++++ linux-2.6.32.9/arch/mips/bcm63xx/boards/board_bcm963xx.c    (working copy)
+Index: target/linux/brcm63xx/files-2.6.30/arch/mips/bcm63xx/boards/board_bcm963xx.c
+@@ -470,6 +470,26 @@
+         .force_duplex_full    = 1,
+     },
+ };
++ 
++static struct board_info __initdata board_alicev3_s1 = {
++    .name                = "Alice Gate W2+",
++    .expected_cpu_id        = 0x6348,
++
++    .has_enet0            = 1,
++    .has_enet1            = 1,
++    .has_pci            = 1,
++
++    .enet0 = {
++        .has_phy        = 1,
++        .use_internal_phy    = 1,
++    },
++    .enet1 = {
++        .force_speed_100    = 1,
++        .force_duplex_full    = 1,
++    },
++
++    .has_ohci0 = 1,
++};
+ #endif
+ 
+ /*
+@@ -696,6 +716,7 @@
+     &board_DV201AMR,
+     &board_96348gw_a,
+     &board_rta1025w_16,
++    &board_alicev3_s1,
+ #endif
+ 
+ #ifdef CONFIG_BCM63XX_CPU_6358

Anyway, there's still the problem (on top of DSL not working): the fylesystem inizialization occurring during the first boot make subsequent boot-ups fail because CFE complains about a bad CRC of the flash image (problem known already https://lists.openwrt.org/pipermail/openwrt-devel/2009-August/004815.html ).

I know cshore can't work on it at the time, so, as I can't' code, is anybody willing to look at a fix for that? I could do betatesting :-(

I've been told that could be possible to replace CFE (maybe with the one from USR9108) and I'm going to try it shortly, but on the other hand to do it is not something that anybody could do, so would be for few experts; I'll keep you posted about it anyway.

Ciao.

Re: Alice Gate W2+ "Vela" brcm63xx-based router

Hi gianfranco74,

Thank you for your patch, but i guess is not usable with the latest svn version.
I was thinking to update it, but first of all i wanted ask you if you already did it or if you have any other interesting news about it, like the crc problem.
Thanks

3 (edited by gianfranco74 2012-08-27 23:16:54)

Re: Alice Gate W2+ "Vela" brcm63xx-based router

Hi,
just bringing up again this thread for a good news :-D

I was finally able to build an image for Alice Gate W2+ (known in Italy as "Vela") that will fix the CRC problem as well, as it runs the "mtd fixtrx linux" command at the end of the first boot. The resulting images should be good for AGW2+ (known as AGA) as well, but on this I didn't test.

Below I'll attach the patch, if anyone is interested, but this is the procedure to apply it:
1) cd in the "trunk" folder.
2) update the source tree (this patch is tested with svn 33271)
3) "make menuconfig" and choose bcm963xx platform
4) "make kernel_menuconfig" and exit with no change
5) copy and paste the patch in a file (let's say for example vela.patch) and put it in "trunk" folder
6) from trunk, type "patch -p0  < vela.patch"
7) go on compiling as usual
When finished, you should find in the bin/bcm963xx folder few images, use openwrt-AliceGateW2+* for "Vela" or openwrt-AGW2+* for "AGA", squashfs of jffs2 as you prefer.
ONE THING TO MENTION: in order to make the device to boot properly, flash it twice, as in this way you'll flash both banks o the flash.
That's what I did: I was coming from Roleo's USR9108 fw for this device. I stopped the router at the CFE from serial console, pointed the browser to 192.168.1.1, uploaded the image, after finished flashing, I stopped again the router at CFE, pointed once more the browser to 192.168.1.1, uploaded the same image and after finishing, you'll have the router booting from openwrt.
Give few minutes to complete the first boot and then reboot it, it should be ok.

Few more things:
1) Do as per above at your own risk. I did it on my "Vela", it works, but I'm not responsible for any damage of yours! If you're afraid, keep using great Roleo's USR9108 fw!
2) As per every bcm963xx router, ADSL does not work due to lack of opensource drivers
3) I tried to put the correct gpio's of leds for "Vela", but some may be wrong. Any help is welcome :-)

I'm using openwrt on Alice Gate W2+ for the last couple of days as an AP and seems to be working fine. I noticed some troubles with opkg and gpioctl, but, what I needed (i.e. and AP), is working very good :-)

Ciao.

Here's the patch:

Index: target/linux/brcm63xx/image/Makefile
===================================================================
--- target/linux/brcm63xx/image/Makefile    (revision 33271)
+++ target/linux/brcm63xx/image/Makefile    (working copy)
@@ -218,6 +218,10 @@
     $(call Image/Build/CFE,$(1),AW4339U,6328,DSL274XB-F1-AU,,--signature2="4.06.01.AUF1" --pad 4)
     # D-Link DVA-G3810BN/TL
     $(call Image/Build/CFEFIXUP,$(1),96358VW,DVAG3810BN,6358,DVAG3810BN)
+    # Pirelli Alice Gate W2+ (Vela)
+    $(call Image/Build/CFE,$(1),"Alice Gate W2+",6348,"AliceGateW2+")
+    # Pirelli AGW2+ (AGA)
+    $(call Image/Build/CFE,$(1),AGW2+,6348,AGW2+)
 
     # TP-Link TD-8810A, TD-8810B, TD-8811A, TD-8811B
     $(call Image/Build/CFE,$(1),8L-2M-8M,6338,TP8810_8811)
Index: target/linux/brcm63xx/base-files/etc/uci-defaults/brcm63xx_fixcrc.sh
===================================================================
--- target/linux/brcm63xx/base-files/etc/uci-defaults/brcm63xx_fixcrc.sh    (revision 33271)
+++ target/linux/brcm63xx/base-files/etc/uci-defaults/brcm63xx_fixcrc.sh    (working copy)
@@ -21,7 +21,9 @@
     CT6373-1 |\
     MAGIC |\
     V2110 |\
-    V2500V_BB)
+    V2500V_BB |\
+    "Alice" |\
+    "AliceAGW2+")
         do_fixcrc
         ;;
 esac
--- build_dir/linux-brcm63xx/linux-3.3.8/arch/mips/bcm63xx/boards/board_bcm963xx.c.ori    2012-08-27 23:17:09.376939040 +0200
+++ build_dir/linux-brcm63xx/linux-3.3.8/arch/mips/bcm63xx/boards/board_bcm963xx.c    2012-08-26 22:14:12.880119000 +0200
@@ -1418,6 +1418,199 @@
             .debounce_interval = BCM963XX_KEYS_DEBOUNCE_INTERVAL,
             },
     },
+
+};
+
+static struct board_info __initdata board_alice_gate_w2plus = {
+    .name                = "Alice Gate W2+",
+    .expected_cpu_id        = 0x6348,
+
+    .has_uart0            = 1,
+    .has_enet0            = 1,
+    .has_enet1            = 1,
+    .has_pci            = 1,
+
+    .enet0 = {
+        .has_phy        = 1,
+        .use_internal_phy    = 1,
+    },
+    .enet1 = {
+        .force_speed_100    = 1,
+        .force_duplex_full    = 1,
+    },
+
+    .has_ohci0            = 1,
+    .has_pccard            = 1,
+    .has_ehci0            = 1,
+
+    .has_dsp            = 1,
+    .dsp = {
+        .gpio_rst        = 25,
+        .gpio_int        = 34,
+        .cs            = 2,
+        .ext_irq        = 2,
+    },
+
+    .leds = {
+        {
+            .name        = "Alice Gate W2+:green:power",
+            .gpio        = 0,
+            .active_low    = 1,
+            .default_trigger = "default-on",
+        },
+        {
+            .name        = "Alice Gate W2+:green:usb",
+            .gpio        = 35,
+            .active_low    = 1,
+        },
+        {
+            .name        = "Alice Gate W2+:green:ethernet",
+            .gpio        = 6,
+            .active_low    = 1,
+        },
+        {
+            .name        = "Alice Gate W2+:green:wifi",
+            .gpio        = 23,
+            .active_low    = 1,
+        },
+        {
+            .name        = "Alice Gate W2+:green:adsl",
+            .gpio        = 2,
+            .active_low    = 1,
+        },
+        {
+            .name        = "Alice Gate W2+:green:service",
+            .gpio        = 22,
+            .active_low    = 1,
+        },
+        {
+            .name        = "Alice Gate W2+:red:service",
+            .gpio        = 7,
+            .active_low    = 1,
+        },
+        {
+            .name        = "Alice Gate W2+:green:voip",
+            .gpio        = 3,
+            .active_low    = 1,
+        },
+        {
+            .name        = "Alice Gate W2+:red:voip",
+            .gpio        = 4,
+            .active_low    = 1,
+        },
+    },
+
+    .buttons = {
+        {
+            .desc           = "reset",
+            .gpio           = 33,
+            .active_low     = 1,
+            .type           = EV_KEY,
+            .code           = KEY_RESTART,
+            .debounce_interval = BCM963XX_KEYS_DEBOUNCE_INTERVAL,
+        },
+    },
+};
+
+static struct board_info __initdata board_aliceagw2plus = {
+    .name                = "AliceAGW2+",
+    .expected_cpu_id        = 0x6348,
+
+    .has_uart0            = 1,
+    .has_enet0            = 1,
+    .has_enet1            = 1,
+    .has_pci            = 1,
+
+    .enet0 = {
+        .has_phy        = 1,
+        .use_internal_phy    = 1,
+    },
+    .enet1 = {
+        .force_speed_100    = 1,
+        .force_duplex_full    = 1,
+    },
+
+    .has_ohci0            = 1,
+    .has_pccard            = 1,
+    .has_ehci0            = 1,
+
+    .has_dsp            = 1,
+    .dsp = {
+        .gpio_rst        = 25,
+        .gpio_int        = 34,
+        .cs            = 2,
+        .ext_irq        = 2,
+    },
+
+    .leds = {
+        {
+            .name        = "AliceAGW2+:green:power",
+            .gpio        = 0,
+            .active_low    = 1,
+            .default_trigger = "default-on",
+        },
+        {
+            .name        = "AliceAGW2+:green:usb/ethernet",
+            .gpio        = 6,
+            .active_low    = 1,
+        },
+        {
+            .name        = "AliceAGW2+:green:wifi",
+            .gpio        = 35,
+            .active_low    = 1,
+        },
+        {
+            .name        = "AliceAGW2+:red:wifi",
+            .gpio        = 36,
+            .active_low    = 1,
+        },
+        {
+            .name        = "AliceAGW2+:green:security",
+            .gpio        = 27,
+            .active_low    = 1,
+        },
+        {
+            .name        = "AliceAGW2+:red:security",
+            .gpio        = 28,
+            .active_low    = 1,
+        },
+        {
+            .name        = "AliceAGW2+:green:adsl",
+            .gpio        = 1,
+            .active_low    = 1,
+        },
+        {
+            .name        = "AliceAGW2+:green:service",
+            .gpio        = 2,
+            .active_low    = 1,
+        },
+        {
+            .name        = "AliceAGW2+:red:service",
+            .gpio        = 3,
+            .active_low    = 1,
+        },
+        {
+            .name        = "AliceAGW2+:green:voip",
+            .gpio        = 4,
+            .active_low    = 1,
+        },
+        {
+            .name        = "AliceAGW2+:red:voip",
+            .gpio        = 5,
+            .active_low    = 1,
+        },
+    },
+
+    .buttons = {
+        {
+            .desc           = "reset",
+            .gpio           = 33,
+            .active_low     = 1,
+            .type           = EV_KEY,
+            .code           = KEY_RESTART,
+            .debounce_interval = BCM963XX_KEYS_DEBOUNCE_INTERVAL,
+        },
+    },
 };
 
 #endif
@@ -2972,6 +3165,8 @@
     &board_96348A_122,
     &board_CPVA502plus,
     &board_96348W3,
+    &board_alice_gate_w2plus,
+    &board_aliceagw2plus,
 #endif
 
 #ifdef CONFIG_BCM63XX_CPU_6358
--- build_dir/linux-brcm63xx/linux-3.3.8/drivers/mtd/chips/gen_probe.c.ori    2012-06-01 09:16:13.000000000 +0200
+++ build_dir/linux-brcm63xx/linux-3.3.8/drivers/mtd/chips/gen_probe.c    2012-08-26 21:51:21.111119000 +0200
@@ -127,9 +127,12 @@
      * chip in read mode.
      */
 
+    /* Fix for Alice Gate W2+ (Vela) and ALiceAGW2+ (AGA)
+     
     for (i = 1; i < max_chips; i++) {
         cp->probe_chip(map, i << cfi.chipshift, chip_map, &cfi);
     }
+    */
 
     /*
      * Now allocate the space for the structures we need to return to

Re: Alice Gate W2+ "Vela" brcm63xx-based router

Are you able to use your 8MiB flash with Openwrt?

I guess at least you can't flash an image more than 4 MiB size.

Re: Alice Gate W2+ "Vela" brcm63xx-based router

any one can help me solution the wireless bcm4338....I buy a HG110 adsl router ....CPU is the smae...bcm6328 but the wireless can not be runing!!!!! I am a new guy.,.......-_- so ....if any high cast share a image for me at this form