Re: [OpenWrt-Devel] [PATCH 1/9] ar71xx: PowerCloud CAP324 kernel support To: openwrt-devel@lists.openwrt.org
On 12/09/2015 09:47 PM, Felix Fietkau wrote: > On 2015-12-09 21:02, Daniel Dickinson wrote: >>> Seems like we've been accumulating separate patches for adding >>> individual boards again, I'm going to clean up that stuff later. When >>> you've fixed the issues that I've pointed out already, please also >>> restructure your patches to add the mach files individually, then a >>> commit that integrates your boards into >>> 700-MIPS-ath79-openwrt-machines.patch, then the image build integration >>> patches. >> >> >> Sorry, I'm not 100% sure I follow, so let me make sure I'm understanding: >> >> You no longer want to have individual patches in >> target/linux/xxx/patches/ for each board, so the commit series should be to >> >> do each board separately in terms of commit, but which each affect >> 700-MIPS-ath79-openwrt-machines.patch rather than being in individual >> patches. >> >> That is the adding mach-xxx.c becomes part of 700-MIPS-ath79-... ? > mach-xxx.c should go to files/arch/mips/ath79/ instead of patches/ > >> Or should the mach file be added somewhere else (e.g. somewhere in the >> target/linux/ar71xx tree and referenced by patch 700-MIPS-... for the >> KConfig and Makefile and so on? >> >> >> It would be perhaps useful to have some documentation on dev.openwrt.org >> pointing to expected board patch guidelines. > This mess really is ar71xx specific. On targets that have been converted > to device tree (e.g. ramips), things are a lot easier and cleaner. > Maybe some day ar71xx will be converted to run device tree too, but I'm > not sure if anybody's actively working on this. > > - Felix For the record: I'm planning to work on device trees for ar71xx sometime next year (and getting as much of it as possible to the upstream kernel in the process). Matthias signature.asc Description: OpenPGP digital signature ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH 1/9] ar71xx: PowerCloud CAP324 kernel support To: openwrt-devel@lists.openwrt.org
On 09/12/15 04:07 PM, Felix Fietkau wrote: On 2015-12-09 21:47, Felix Fietkau wrote: On 2015-12-09 21:02, Daniel Dickinson wrote: Seems like we've been accumulating separate patches for adding individual boards again, I'm going to clean up that stuff later. When you've fixed the issues that I've pointed out already, please also restructure your patches to add the mach files individually, then a commit that integrates your boards into 700-MIPS-ath79-openwrt-machines.patch, then the image build integration patches. Sorry, I'm not 100% sure I follow, so let me make sure I'm understanding: You no longer want to have individual patches in target/linux/xxx/patches/ for each board, so the commit series should be to do each board separately in terms of commit, but which each affect 700-MIPS-ath79-openwrt-machines.patch rather than being in individual patches. That is the adding mach-xxx.c becomes part of 700-MIPS-ath79-... ? mach-xxx.c should go to files/arch/mips/ath79/ instead of patches/ Actually, now that I think about it again, I will probably change the structure so that we don't have to touch patches/ for new boards anymore. It's just annoying to maintain, considering how many boards we have. If you could let me know when you've done that I will be the first one to do things the new way. Regards, Daniel ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH 1/9] ar71xx: PowerCloud CAP324 kernel support To: openwrt-devel@lists.openwrt.org
On 2015-12-09 21:47, Felix Fietkau wrote: > On 2015-12-09 21:02, Daniel Dickinson wrote: >>> Seems like we've been accumulating separate patches for adding >>> individual boards again, I'm going to clean up that stuff later. When >>> you've fixed the issues that I've pointed out already, please also >>> restructure your patches to add the mach files individually, then a >>> commit that integrates your boards into >>> 700-MIPS-ath79-openwrt-machines.patch, then the image build integration >>> patches. >> >> >> Sorry, I'm not 100% sure I follow, so let me make sure I'm understanding: >> >> You no longer want to have individual patches in >> target/linux/xxx/patches/ for each board, so the commit series should be to >> >> do each board separately in terms of commit, but which each affect >> 700-MIPS-ath79-openwrt-machines.patch rather than being in individual >> patches. >> >> That is the adding mach-xxx.c becomes part of 700-MIPS-ath79-... ? > mach-xxx.c should go to files/arch/mips/ath79/ instead of patches/ Actually, now that I think about it again, I will probably change the structure so that we don't have to touch patches/ for new boards anymore. It's just annoying to maintain, considering how many boards we have. - Felix ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH 1/9] ar71xx: PowerCloud CAP324 kernel support To: openwrt-devel@lists.openwrt.org
On 2015-12-09 21:02, Daniel Dickinson wrote: >> Seems like we've been accumulating separate patches for adding >> individual boards again, I'm going to clean up that stuff later. When >> you've fixed the issues that I've pointed out already, please also >> restructure your patches to add the mach files individually, then a >> commit that integrates your boards into >> 700-MIPS-ath79-openwrt-machines.patch, then the image build integration >> patches. > > > Sorry, I'm not 100% sure I follow, so let me make sure I'm understanding: > > You no longer want to have individual patches in > target/linux/xxx/patches/ for each board, so the commit series should be to > > do each board separately in terms of commit, but which each affect > 700-MIPS-ath79-openwrt-machines.patch rather than being in individual > patches. > > That is the adding mach-xxx.c becomes part of 700-MIPS-ath79-... ? mach-xxx.c should go to files/arch/mips/ath79/ instead of patches/ > Or should the mach file be added somewhere else (e.g. somewhere in the > target/linux/ar71xx tree and referenced by patch 700-MIPS-... for the > KConfig and Makefile and so on? > > > It would be perhaps useful to have some documentation on dev.openwrt.org > pointing to expected board patch guidelines. This mess really is ar71xx specific. On targets that have been converted to device tree (e.g. ramips), things are a lot easier and cleaner. Maybe some day ar71xx will be converted to run device tree too, but I'm not sure if anybody's actively working on this. - Felix ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH 1/9] ar71xx: PowerCloud CAP324 kernel support To: openwrt-devel@lists.openwrt.org
Seems like we've been accumulating separate patches for adding individual boards again, I'm going to clean up that stuff later. When you've fixed the issues that I've pointed out already, please also restructure your patches to add the mach files individually, then a commit that integrates your boards into 700-MIPS-ath79-openwrt-machines.patch, then the image build integration patches. Sorry, I'm not 100% sure I follow, so let me make sure I'm understanding: You no longer want to have individual patches in target/linux/xxx/patches/ for each board, so the commit series should be to do each board separately in terms of commit, but which each affect 700-MIPS-ath79-openwrt-machines.patch rather than being in individual patches. That is the adding mach-xxx.c becomes part of 700-MIPS-ath79-... ? Or should the mach file be added somewhere else (e.g. somewhere in the target/linux/ar71xx tree and referenced by patch 700-MIPS-... for the KConfig and Makefile and so on? It would be perhaps useful to have some documentation on dev.openwrt.org pointing to expected board patch guidelines. Regards, Daniel ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
Re: [OpenWrt-Devel] [PATCH 1/9] ar71xx: PowerCloud CAP324 kernel support To: openwrt-devel@lists.openwrt.org
On 2015-12-09 10:21, open...@daniel.thecshore.com wrote: > From: Daniel Dickinson > > Kernel part of support for PowerCloud CAP324 Cloud AP. > The CAP324 Cloud AP was a device sold by PowerCloud Systems as hardware for > the CloudCommand service for 'cloud' based managment of large numbers > access points. > > The CAP324 is a dual-band 802.11n wireless access point with 16MB flash > and 128MB RAM and single gigabit ethernet port. It can be powered via PoE > or a wall wart. > --- > target/linux/ar71xx/config-4.1 | 1 + > target/linux/ar71xx/mikrotik/config-default| 1 + > target/linux/ar71xx/nand/config-default| 1 + > ...-MIPS-ath79-add-powercloud-cap324-support.patch | 175 > + > 4 files changed, 178 insertions(+) > create mode 100644 > target/linux/ar71xx/patches-4.1/823-MIPS-ath79-add-powercloud-cap324-support.patch > > diff --git a/target/linux/ar71xx/config-4.1 b/target/linux/ar71xx/config-4.1 > index eff197a..7a402a4 100644 > --- a/target/linux/ar71xx/config-4.1 > +++ b/target/linux/ar71xx/config-4.1 > @@ -50,6 +50,7 @@ CONFIG_ATH79_MACH_ARDUINO_YUN=y > CONFIG_ATH79_MACH_AW_NR580=y > CONFIG_ATH79_MACH_BHU_BXU2000N2_A=y > CONFIG_ATH79_MACH_BSB=y > +CONFIG_ATH79_MACH_CAP324=y > CONFIG_ATH79_MACH_CAP4200AG=y > CONFIG_ATH79_MACH_CARAMBOLA2=y > CONFIG_ATH79_MACH_CF_E316N_V2=y > diff --git a/target/linux/ar71xx/mikrotik/config-default > b/target/linux/ar71xx/mikrotik/config-default > index de91e4b..c46529c 100644 > --- a/target/linux/ar71xx/mikrotik/config-default > +++ b/target/linux/ar71xx/mikrotik/config-default > @@ -15,6 +15,7 @@ > # CONFIG_ATH79_MACH_ARCHER_C7 is not set > # CONFIG_ATH79_MACH_AW_NR580 is not set > # CONFIG_ATH79_MACH_BHU_BXU2000N2_A is not set > +# CONFIG_ATH79_MACH_CAP324 is not set > # CONFIG_ATH79_MACH_CAP4200AG is not set > # CONFIG_ATH79_MACH_CARAMBOLA2 is not set > # CONFIG_ATH79_MACH_CPE510 is not set > diff --git a/target/linux/ar71xx/nand/config-default > b/target/linux/ar71xx/nand/config-default > index 50b6dbe..0407da0 100644 > --- a/target/linux/ar71xx/nand/config-default > +++ b/target/linux/ar71xx/nand/config-default > @@ -13,6 +13,7 @@ > # CONFIG_ATH79_MACH_AP96 is not set > # CONFIG_ATH79_MACH_ARCHER_C7 is not set > # CONFIG_ATH79_MACH_AW_NR580 is not set > +# CONFIG_ATH79_MACH_CAP324 is not set > # CONFIG_ATH79_MACH_CAP4200AG is not set > # CONFIG_ATH79_MACH_CARAMBOLA2 is not set > # CONFIG_ATH79_MACH_DB120 is not set > diff --git > a/target/linux/ar71xx/patches-4.1/823-MIPS-ath79-add-powercloud-cap324-support.patch > > b/target/linux/ar71xx/patches-4.1/823-MIPS-ath79-add-powercloud-cap324-support.patch > new file mode 100644 > index 000..2653d24 > --- /dev/null > +++ > b/target/linux/ar71xx/patches-4.1/823-MIPS-ath79-add-powercloud-cap324-support.patch > @@ -0,0 +1,175 @@ > +--- a/arch/mips/ath79/Kconfig > b/arch/mips/ath79/Kconfig Seems like we've been accumulating separate patches for adding individual boards again, I'm going to clean up that stuff later. When you've fixed the issues that I've pointed out already, please also restructure your patches to add the mach files individually, then a commit that integrates your boards into 700-MIPS-ath79-openwrt-machines.patch, then the image build integration patches. - Felix ___ openwrt-devel mailing list openwrt-devel@lists.openwrt.org https://lists.openwrt.org/cgi-bin/mailman/listinfo/openwrt-devel
[OpenWrt-Devel] [PATCH 1/9] ar71xx: PowerCloud CAP324 kernel support To: openwrt-devel@lists.openwrt.org
From: Daniel Dickinson Kernel part of support for PowerCloud CAP324 Cloud AP. The CAP324 Cloud AP was a device sold by PowerCloud Systems as hardware for the CloudCommand service for 'cloud' based managment of large numbers access points. The CAP324 is a dual-band 802.11n wireless access point with 16MB flash and 128MB RAM and single gigabit ethernet port. It can be powered via PoE or a wall wart. --- target/linux/ar71xx/config-4.1 | 1 + target/linux/ar71xx/mikrotik/config-default| 1 + target/linux/ar71xx/nand/config-default| 1 + ...-MIPS-ath79-add-powercloud-cap324-support.patch | 175 + 4 files changed, 178 insertions(+) create mode 100644 target/linux/ar71xx/patches-4.1/823-MIPS-ath79-add-powercloud-cap324-support.patch diff --git a/target/linux/ar71xx/config-4.1 b/target/linux/ar71xx/config-4.1 index eff197a..7a402a4 100644 --- a/target/linux/ar71xx/config-4.1 +++ b/target/linux/ar71xx/config-4.1 @@ -50,6 +50,7 @@ CONFIG_ATH79_MACH_ARDUINO_YUN=y CONFIG_ATH79_MACH_AW_NR580=y CONFIG_ATH79_MACH_BHU_BXU2000N2_A=y CONFIG_ATH79_MACH_BSB=y +CONFIG_ATH79_MACH_CAP324=y CONFIG_ATH79_MACH_CAP4200AG=y CONFIG_ATH79_MACH_CARAMBOLA2=y CONFIG_ATH79_MACH_CF_E316N_V2=y diff --git a/target/linux/ar71xx/mikrotik/config-default b/target/linux/ar71xx/mikrotik/config-default index de91e4b..c46529c 100644 --- a/target/linux/ar71xx/mikrotik/config-default +++ b/target/linux/ar71xx/mikrotik/config-default @@ -15,6 +15,7 @@ # CONFIG_ATH79_MACH_ARCHER_C7 is not set # CONFIG_ATH79_MACH_AW_NR580 is not set # CONFIG_ATH79_MACH_BHU_BXU2000N2_A is not set +# CONFIG_ATH79_MACH_CAP324 is not set # CONFIG_ATH79_MACH_CAP4200AG is not set # CONFIG_ATH79_MACH_CARAMBOLA2 is not set # CONFIG_ATH79_MACH_CPE510 is not set diff --git a/target/linux/ar71xx/nand/config-default b/target/linux/ar71xx/nand/config-default index 50b6dbe..0407da0 100644 --- a/target/linux/ar71xx/nand/config-default +++ b/target/linux/ar71xx/nand/config-default @@ -13,6 +13,7 @@ # CONFIG_ATH79_MACH_AP96 is not set # CONFIG_ATH79_MACH_ARCHER_C7 is not set # CONFIG_ATH79_MACH_AW_NR580 is not set +# CONFIG_ATH79_MACH_CAP324 is not set # CONFIG_ATH79_MACH_CAP4200AG is not set # CONFIG_ATH79_MACH_CARAMBOLA2 is not set # CONFIG_ATH79_MACH_DB120 is not set diff --git a/target/linux/ar71xx/patches-4.1/823-MIPS-ath79-add-powercloud-cap324-support.patch b/target/linux/ar71xx/patches-4.1/823-MIPS-ath79-add-powercloud-cap324-support.patch new file mode 100644 index 000..2653d24 --- /dev/null +++ b/target/linux/ar71xx/patches-4.1/823-MIPS-ath79-add-powercloud-cap324-support.patch @@ -0,0 +1,175 @@ +--- a/arch/mips/ath79/Kconfig b/arch/mips/ath79/Kconfig +@@ -866,6 +866,16 @@ config ATH79_MACH_MZK_W300NH + select ATH79_DEV_M25P80 + select ATH79_DEV_WMAC + ++config ATH79_MACH_CAP324 ++ bool "PowerCloud Systems CAP324 board support" ++ select SOC_AR934X ++ select ATH79_DEV_AP9X_PCI if PCI ++ select ATH79_DEV_ETH ++ select ATH79_DEV_GPIO_BUTTONS ++ select ATH79_DEV_LEDS_GPIO ++ select ATH79_DEV_M25P80 ++ select ATH79_DEV_WMAC ++ + config ATH79_MACH_RW2458N + bool "Redwave RW2458N board support" + select SOC_AR724X +--- a/arch/mips/ath79/Makefile b/arch/mips/ath79/Makefile +@@ -57,6 +57,7 @@ obj-$(CONFIG_ATH79_MACH_ARCHER_C7) += ma + obj-$(CONFIG_ATH79_MACH_AW_NR580) += mach-aw-nr580.o + obj-$(CONFIG_ATH79_MACH_BHU_BXU2000N2_A)+= mach-bhu-bxu2000n2-a.o + obj-$(CONFIG_ATH79_MACH_BSB) += mach-bsb.o ++obj-$(CONFIG_ATH79_MACH_CAP324) += mach-cap324.o + obj-$(CONFIG_ATH79_MACH_CAP4200AG)+= mach-cap4200ag.o + obj-$(CONFIG_ATH79_MACH_CPE510) += mach-cpe510.o + obj-$(CONFIG_ATH79_MACH_DB120)+= mach-db120.o +--- /dev/null b/arch/mips/ath79/mach-cap324.c +@@ -0,0 +1,133 @@ ++/* ++ * PowerCloud Systems CAP324 board support ++ * ++ * Copyright (C) 2012 Gabor Juhos ++ * Copyright (C) 2012-2013 PowerCloud Systems ++ * Copyright (C) 2015 Daniel Dickinson ++ * ++ * 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 ++#include ++#include ++#include ++ ++#include ++ ++#include "common.h" ++#include "dev-ap9x-pci.h" ++#include "dev-eth.h" ++#include "dev-gpio-buttons.h" ++#include "dev-leds-gpio.h" ++#include "dev-m25p80.h" ++#include "dev-spi.h" ++#include "dev-usb.h" ++#include "dev-wmac.h" ++#include "machtypes.h" ++ ++#define CAP324_GPIO_LED_POWER_GREEN 12 ++#define CAP324_GPIO_LED_POWER_AMBER 13 ++#define CAP324_GPIO_LED_LAN_GREEN 14 ++#define CAP324_GPIO_LED_LAN_AMBER 15 ++#define CAP324_GPIO_LED_WLAN_GREEN18 ++#define CAP324_GPIO_LED_WLAN_AMBER19 ++ ++#define CAP324_GPIO_BTN_RESET 17 ++ ++#define CAP324_KEYS_POLL_INTERVAL 20 /* msecs */ ++#define CAP324_KEYS_DEB