Changeset 44559


Ignore:
Timestamp:
2015-02-27T18:38:46+01:00 (3 years ago)
Author:
jogo
Message:

brcm63xx: add dts and profile for Livebox

Signed-off-by: Jonas Gorski <jogo@…>

Location:
trunk/target/linux/brcm63xx
Files:
2 added
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/target/linux/brcm63xx/image/Makefile

    r44558 r44559  
    9797endef 
    9898 
    99 define Image/Build/RedBoot 
    100         cp $(KDIR)/vmlinux.elf $(BIN_DIR)/openwrt-$(1)-vmlinux.elf 
    101         gzip -9 -c $(KDIR)/vmlinux > $(KDIR)/vmlinux.bin.gz 
    102         $(STAGING_DIR_HOST)/bin/lzma e $(KDIR)/vmlinux $(KDIR)/vmlinux.bin.l7 
    103         dd if=$(KDIR)/vmlinux.bin.l7 of=$(BIN_DIR)/openwrt-$(1)-vmlinux.lzma bs=65536 conv=sync 
    104         dd if=$(KDIR)/vmlinux.bin.gz of=$(BIN_DIR)/openwrt-$(1)-vmlinux.gz bs=65536 conv=sync 
     99define Image/Build/RedBootDTB 
     100        gzip -9 -c $(KDIR)/vmlinux-$(2) > $(KDIR)/vmlinux-$(2).bin.gz 
     101        $(STAGING_DIR_HOST)/bin/lzma e $(KDIR)/vmlinux-$(2) $(KDIR)/vmlinux-$(2).bin.l7 
     102        dd if=$(KDIR)/vmlinux-$(2).bin.l7 of=$(BIN_DIR)/openwrt-$(5)-vmlinux.lzma bs=65536 conv=sync 
     103        dd if=$(KDIR)/vmlinux-$(2).bin.gz of=$(BIN_DIR)/openwrt-$(5)-vmlinux.gz bs=65536 conv=sync 
    105104endef 
    106105 
     
    201200        # RTA1320_16M (numerous routers) 
    202201        $(call Image/Build/CFE,$(1),RTA1320_16M,6338,RTA1320_16M,,--layoutver 5) 
    203  
    204         # Inventel Livebox 
    205         $(call Image/Build/RedBoot,livebox) 
    206202 
    207203        # Netgear CVG834G 
     
    298294$(eval $(call ImageDTB,CFEDTB,HG556a_AB,hg556a-b,HW556,6358,HG556a_B,--rsa-signature "EchoLife_HG556a" --image-offset 0x20000 --block-size 0x20000 --tag-version 8)) 
    299295$(eval $(call ImageDTB,CFEDTB,HG556a_C,hg556a-c,HW556,6358,HG556a_C,--rsa-signature "EchoLife_HG556a" --image-offset 0x20000 --block-size 0x20000 --tag-version 8)) 
     296# Inventel Livebox 1 
     297$(eval $(call ImageDTB,RedBootDTB,Livebox,livebox-blue-5g,,,livebox)) 
    300298# Netgear DG834GT/PN 
    301299$(eval $(call ImageDTB,CFEDTB,DG834GTPN,dg834gtpn,96348GW-10,6348,DG834GT_PN)) 
  • trunk/target/linux/brcm63xx/patches-3.14/513-MIPS-BCM63XX-add-inventel-Livebox-support.patch

    r42123 r44559  
    1 From 7e6b22225e16fbb22dbf7f2113d8c6d65333818c Mon Sep 17 00:00:00 2001 
     1From e796582b499f0ba6acaa1ac3a10c09cceaab7702 Mon Sep 17 00:00:00 2001 
    22From: Jonas Gorski <jogo@openwrt.org> 
    33Date: Sun, 9 Mar 2014 04:55:52 +0100 
    4 Subject: [PATCH 44/44] MIPS: BCM63XX: add inventel Livebox support 
     4Subject: [PATCH] MIPS: BCM63XX: add inventel Livebox support 
    55 
    66--- 
    7  arch/mips/bcm63xx/boards/Kconfig         |   6 + 
    8  arch/mips/bcm63xx/boards/Makefile        |   1 + 
    9  arch/mips/bcm63xx/boards/board_common.c  |   2 +- 
    10  arch/mips/bcm63xx/boards/board_common.h  |   6 + 
    11  arch/mips/bcm63xx/boards/board_livebox.c | 193 +++++++++++++++++++++++++++++++ 
    12  5 files changed, 207 insertions(+), 1 deletion(-) 
     7 arch/mips/bcm63xx/boards/Kconfig         |    6 + 
     8 arch/mips/bcm63xx/boards/Makefile        |    1 + 
     9 arch/mips/bcm63xx/boards/board_common.c  |    2 +- 
     10 arch/mips/bcm63xx/boards/board_common.h  |    6 + 
     11 arch/mips/bcm63xx/boards/board_livebox.c |  215 ++++++++++++++++++++++++++++++ 
     12 5 files changed, 229 insertions(+), 1 deletion(-) 
    1313 create mode 100644 arch/mips/bcm63xx/boards/board_livebox.c 
    1414 
     
    5858--- /dev/null 
    5959+++ b/arch/mips/bcm63xx/boards/board_livebox.c 
    60 @@ -0,0 +1,200 @@ 
     60@@ -0,0 +1,215 @@ 
    6161+/* 
    6262+ * This file is subject to the terms and conditions of the GNU General Public 
     
    184184+}; 
    185185+ 
     186+static struct of_device_id const livebox_boards_dt[] = { 
     187+       { .compatible = "inventel,livebox-blue-5g", .data = &board_livebox_blue5g, }, 
     188+       { } 
     189+}; 
     190+ 
    186191+/* 
    187192+ * register & return a new board mac address 
     
    228233+       u8 hw_version; 
    229234+       const struct board_info *board; 
    230 + 
    231 +       /* Get hardware version */ 
    232 +       val = bcm_gpio_readl(GPIO_CTL_LO_REG); 
    233 +       val &= ~LIVEBOX_GPIO_DETECT_MASK; 
    234 +       bcm_gpio_writel(val, GPIO_CTL_LO_REG); 
    235 + 
    236 +       hw_version = bcm_gpio_readl(GPIO_DATA_LO_REG) & LIVEBOX_GPIO_DETECT_MASK; 
    237 +       switch (hw_version) { 
    238 +       case LIVEBOX_HW_BLUE5G_9: 
    239 +               printk(KERN_INFO PFX "Livebox BLUE5G.9\n"); 
    240 +               board = bcm963xx_boards[0]; 
    241 +               break; 
    242 +       default: 
    243 +               printk(KERN_INFO PFX "Unknown livebox version: %02x\n", hw_version); 
    244 +               /* use default livebox configuration */ 
    245 +               board = bcm963xx_boards[0]; 
    246 +               break; 
     235+       const struct of_device_id *board_match; 
     236+ 
     237+       /* find board by compat */ 
     238+       board_match = bcm63xx_match_board(livebox_boards_dt); 
     239+       if (board_match) { 
     240+               board = board_match->data; 
     241+       } else { 
     242+               /* Get hardware version */ 
     243+               val = bcm_gpio_readl(GPIO_CTL_LO_REG); 
     244+               val &= ~LIVEBOX_GPIO_DETECT_MASK; 
     245+               bcm_gpio_writel(val, GPIO_CTL_LO_REG); 
     246+ 
     247+               hw_version = bcm_gpio_readl(GPIO_DATA_LO_REG); 
     248+               hw_version &= LIVEBOX_GPIO_DETECT_MASK; 
     249+ 
     250+               switch (hw_version) { 
     251+               case LIVEBOX_HW_BLUE5G_9: 
     252+                       printk(KERN_INFO PFX "Livebox BLUE5G.9\n"); 
     253+                       board = bcm963xx_boards[0]; 
     254+                       break; 
     255+               default: 
     256+                       printk(KERN_INFO PFX "Unknown livebox version: %02x\n", 
     257+                              hw_version); 
     258+                       /* use default livebox configuration */ 
     259+                       board = bcm963xx_boards[0]; 
     260+                       break; 
     261+               } 
    247262+       } 
    248263+ 
  • trunk/target/linux/brcm63xx/patches-3.18/513-MIPS-BCM63XX-add-inventel-Livebox-support.patch

    r43461 r44559  
    1 From 7e6b22225e16fbb22dbf7f2113d8c6d65333818c Mon Sep 17 00:00:00 2001 
     1From e796582b499f0ba6acaa1ac3a10c09cceaab7702 Mon Sep 17 00:00:00 2001 
    22From: Jonas Gorski <jogo@openwrt.org> 
    33Date: Sun, 9 Mar 2014 04:55:52 +0100 
    4 Subject: [PATCH 44/44] MIPS: BCM63XX: add inventel Livebox support 
     4Subject: [PATCH] MIPS: BCM63XX: add inventel Livebox support 
    55 
    66--- 
    7  arch/mips/bcm63xx/boards/Kconfig         |   6 + 
    8  arch/mips/bcm63xx/boards/Makefile        |   1 + 
    9  arch/mips/bcm63xx/boards/board_common.c  |   2 +- 
    10  arch/mips/bcm63xx/boards/board_common.h  |   6 + 
    11  arch/mips/bcm63xx/boards/board_livebox.c | 193 +++++++++++++++++++++++++++++++ 
    12  5 files changed, 207 insertions(+), 1 deletion(-) 
     7 arch/mips/bcm63xx/boards/Kconfig         |    6 + 
     8 arch/mips/bcm63xx/boards/Makefile        |    1 + 
     9 arch/mips/bcm63xx/boards/board_common.c  |    2 +- 
     10 arch/mips/bcm63xx/boards/board_common.h  |    6 + 
     11 arch/mips/bcm63xx/boards/board_livebox.c |  215 ++++++++++++++++++++++++++++++ 
     12 5 files changed, 229 insertions(+), 1 deletion(-) 
    1313 create mode 100644 arch/mips/bcm63xx/boards/board_livebox.c 
    1414 
     
    5858--- /dev/null 
    5959+++ b/arch/mips/bcm63xx/boards/board_livebox.c 
    60 @@ -0,0 +1,200 @@ 
     60@@ -0,0 +1,215 @@ 
    6161+/* 
    6262+ * This file is subject to the terms and conditions of the GNU General Public 
     
    184184+}; 
    185185+ 
     186+static struct of_device_id const livebox_boards_dt[] = { 
     187+       { .compatible = "inventel,livebox-blue-5g", .data = &board_livebox_blue5g, }, 
     188+       { } 
     189+}; 
     190+ 
    186191+/* 
    187192+ * register & return a new board mac address 
     
    228233+       u8 hw_version; 
    229234+       const struct board_info *board; 
    230 + 
    231 +       /* Get hardware version */ 
    232 +       val = bcm_gpio_readl(GPIO_CTL_LO_REG); 
    233 +       val &= ~LIVEBOX_GPIO_DETECT_MASK; 
    234 +       bcm_gpio_writel(val, GPIO_CTL_LO_REG); 
    235 + 
    236 +       hw_version = bcm_gpio_readl(GPIO_DATA_LO_REG) & LIVEBOX_GPIO_DETECT_MASK; 
    237 +       switch (hw_version) { 
    238 +       case LIVEBOX_HW_BLUE5G_9: 
    239 +               printk(KERN_INFO PFX "Livebox BLUE5G.9\n"); 
    240 +               board = bcm963xx_boards[0]; 
    241 +               break; 
    242 +       default: 
    243 +               printk(KERN_INFO PFX "Unknown livebox version: %02x\n", hw_version); 
    244 +               /* use default livebox configuration */ 
    245 +               board = bcm963xx_boards[0]; 
    246 +               break; 
     235+       const struct of_device_id *board_match; 
     236+ 
     237+       /* find board by compat */ 
     238+       board_match = bcm63xx_match_board(livebox_boards_dt); 
     239+       if (board_match) { 
     240+               board = board_match->data; 
     241+       } else { 
     242+               /* Get hardware version */ 
     243+               val = bcm_gpio_readl(GPIO_CTL_LO_REG); 
     244+               val &= ~LIVEBOX_GPIO_DETECT_MASK; 
     245+               bcm_gpio_writel(val, GPIO_CTL_LO_REG); 
     246+ 
     247+               hw_version = bcm_gpio_readl(GPIO_DATA_LO_REG); 
     248+               hw_version &= LIVEBOX_GPIO_DETECT_MASK; 
     249+ 
     250+               switch (hw_version) { 
     251+               case LIVEBOX_HW_BLUE5G_9: 
     252+                       printk(KERN_INFO PFX "Livebox BLUE5G.9\n"); 
     253+                       board = bcm963xx_boards[0]; 
     254+                       break; 
     255+               default: 
     256+                       printk(KERN_INFO PFX "Unknown livebox version: %02x\n", 
     257+                              hw_version); 
     258+                       /* use default livebox configuration */ 
     259+                       board = bcm963xx_boards[0]; 
     260+                       break; 
     261+               } 
    247262+       } 
    248263+ 
Note: See TracChangeset for help on using the changeset viewer.