Switch to Barrier Breaker

This commit is contained in:
Matthias Schiffer 2014-07-26 16:11:27 +02:00
parent 7a52f299e4
commit e164bac87a
45 changed files with 2069 additions and 6397 deletions

View File

@ -153,8 +153,9 @@ include $(INCLUDE_DIR)/target.mk
prereq: FORCE prereq: FORCE
+$(NO_TRACE_MAKE) prereq +$(NO_TRACE_MAKE) prereq
package/lua/host/install: tools/sed/install gluon-tools: FORCE
gluon-tools: package/lua/host/install +$(GLUONMAKE_EARLY) tools/sed/install
+$(GLUONMAKE_EARLY) package/lua/host/install
prepare-tmpinfo: FORCE prepare-tmpinfo: FORCE
mkdir -p tmp/info mkdir -p tmp/info
@ -187,7 +188,7 @@ prepare-target: FORCE
for dir in build_dir dl staging_dir tmp; do \ for dir in build_dir dl staging_dir tmp; do \
mkdir -p $(GLUON_ORIGOPENWRTDIR)/$$dir; \ mkdir -p $(GLUON_ORIGOPENWRTDIR)/$$dir; \
done done
for link in build_dir Config.in dl include Makefile package rules.mk scripts staging_dir target tmp toolchain tools; do \ for link in build_dir config Config.in dl include Makefile package rules.mk scripts staging_dir target tmp toolchain tools; do \
ln -sf $(GLUON_ORIGOPENWRTDIR)/$$link $(GLUON_OPENWRTDIR); \ ln -sf $(GLUON_ORIGOPENWRTDIR)/$$link $(GLUON_OPENWRTDIR); \
done done
+$(GLUONMAKE_EARLY) feeds +$(GLUONMAKE_EARLY) feeds

View File

@ -1,7 +1,7 @@
override BuildImage := override define BuildImage
prepare: FORCE
$(call Image/Prepare)
endef
# The Makefile included here is $(TOPDIR)/target/linux/$(BOARD)/image/Makefile # The Makefile included here is $(TOPDIR)/target/linux/$(BOARD)/image/Makefile
include Makefile include Makefile
prepare: FORCE
$(call Image/Prepare)

View File

@ -1,3 +1,4 @@
CONFIG_BUSYBOX_CUSTOM=y
CONFIG_BUSYBOX_CONFIG_SHA512SUM=y CONFIG_BUSYBOX_CONFIG_SHA512SUM=y
# CONFIG_BUSYBOX_CONFIG_FEATURE_PREFER_IPV4_ADDRESS is not set # CONFIG_BUSYBOX_CONFIG_FEATURE_PREFER_IPV4_ADDRESS is not set
CONFIG_BUSYBOX_CONFIG_IP=y CONFIG_BUSYBOX_CONFIG_IP=y
@ -11,4 +12,4 @@ CONFIG_BUSYBOX_CONFIG_FEATURE_IP_SHORT_FORMS=y
CONFIG_ATH_USER_REGD=y CONFIG_ATH_USER_REGD=y
CONFIG_PACKAGE_ATH_DEBUG=y CONFIG_PACKAGE_ATH_DEBUG=y
CONFIG_PACKAGE_luci-lib-core_srcdiet=y CONFIG_PACKAGE_luci-base_srcdiet=y

View File

@ -28,7 +28,7 @@ export GLUON_VERSION
ifeq ($(OPENWRT_BUILD),1) ifeq ($(OPENWRT_BUILD),1)
ifeq ($(GLUON_TOOLS),1) ifeq ($(GLUON_TOOLS),1)
CONFIG_VERSION_REPO := $(shell $(GLUONDIR)/scripts/site.sh opkg_repo || echo http://downloads.openwrt.org/attitude_adjustment/12.09/%S/packages) CONFIG_VERSION_REPO := $(shell $(GLUONDIR)/scripts/site.sh opkg_repo || echo http://downloads.openwrt.org/barrier_breaker/14.07-rc2/%S/packages)
export CONFIG_VERSION_REPO export CONFIG_VERSION_REPO
GLUON_SITE_CODE := $(shell $(GLUONDIR)/scripts/site.sh site_code) GLUON_SITE_CODE := $(shell $(GLUONDIR)/scripts/site.sh site_code)

View File

@ -1,15 +1,17 @@
# Makefile for OpenWrt # Makefile for OpenWrt
# #
# Copyright (C) 2007-2011 OpenWrt.org # Copyright (C) 2007-2012 OpenWrt.org
# Copyright (C) 2013 Project Gluon # Copyright (C) 2013-2014 Project Gluon
# #
# This is free software, licensed under the GNU General Public License v2. # This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information. # See /LICENSE for more information.
# #
RELEASE:=Attitude Adjustment RELEASE:=Barrier Breaker
PREP_MK= OPENWRT_BUILD= QUIET=0 PREP_MK= OPENWRT_BUILD= QUIET=0
export IS_TTY=$(shell tty -s && echo 1 || echo 0)
include $(GLUONDIR)/include/verbose.mk include $(GLUONDIR)/include/verbose.mk
REVISION:=$(shell [ -d $(TOPDIR) ] && cd $(TOPDIR) && ./scripts/getver.sh 2>/dev/null) REVISION:=$(shell [ -d $(TOPDIR) ] && cd $(TOPDIR) && ./scripts/getver.sh 2>/dev/null)
@ -39,11 +41,24 @@ unexport LPATH
# make sure that a predefined CFLAGS variable does not disturb packages # make sure that a predefined CFLAGS variable does not disturb packages
export CFLAGS= export CFLAGS=
ifneq ($(shell $(HOSTCC) 2>&1 | grep clang),)
export HOSTCC_REAL?=$(HOSTCC)
export HOSTCC_WRAPPER:=$(TOPDIR)/scripts/clang-gcc-wrapper
else
export HOSTCC_WRAPPER:=$(HOSTCC)
endif
ifeq ($(FORCE),)
.config scripts/config/conf scripts/config/mconf: tmp/.prereq-build
endif
SCAN_COOKIE?=$(shell echo $$$$) SCAN_COOKIE?=$(shell echo $$$$)
export SCAN_COOKIE export SCAN_COOKIE
SUBMAKE:=umask 022; $(SUBMAKE) SUBMAKE:=umask 022; $(SUBMAKE)
ULIMIT_FIX=_limit=`ulimit -n`; [ "$$_limit" = "unlimited" -o "$$_limit" -ge 1024 ] || ulimit -n 1024;
FORCE: ; FORCE: ;
.PHONY: FORCE .PHONY: FORCE

View File

@ -27,6 +27,7 @@ endif
ifeq ($(IS_TTY),1) ifeq ($(IS_TTY),1)
ifneq ($(strip $(NO_COLOR)),1) ifneq ($(strip $(NO_COLOR)),1)
_Y:=\\033[33m _Y:=\\033[33m
_R:=\\033[31m
_N:=\\033[m _N:=\\033[m
endif endif
endif endif
@ -36,6 +37,10 @@ ifeq ($(findstring s,$(OPENWRT_VERBOSE)),)
printf "$(_Y)%s$(_N)\n" "$(1)" >&8 printf "$(_Y)%s$(_N)\n" "$(1)" >&8
endef endef
define ERROR_MESSAGE
printf "$(_R)%s$(_N)\n" "$(1)" >&8
endef
ifeq ($(QUIET),1) ifeq ($(QUIET),1)
ifneq ($(CURDIR),$(TOPDIR)) ifneq ($(CURDIR),$(TOPDIR))
_DIR:=$(patsubst $(TOPDIR)/%,%,${CURDIR}) _DIR:=$(patsubst $(TOPDIR)/%,%,${CURDIR})
@ -58,4 +63,5 @@ else
define MESSAGE define MESSAGE
printf "%s\n" "$(1)" printf "%s\n" "$(1)"
endef endef
ERROR_MESSAGE=$(MESSAGE)
endif endif

View File

@ -1,14 +1,14 @@
GLUON_FEEDS='openwrt gluon routing luci' GLUON_FEEDS='openwrt gluon routing luci'
OPENWRT_REPO=git://git.openwrt.org/12.09/openwrt.git OPENWRT_REPO=git://git.openwrt.org/14.07/openwrt.git
OPENWRT_COMMIT=b0a05d4f7c194c7db43c3c5f1818449e4ecfe653 OPENWRT_COMMIT=79465bfe7633bb92e7ea3468e9cec8bf5d4c0190
PACKAGES_OPENWRT_REPO=git://github.com/openwrt/packages.git PACKAGES_OPENWRT_REPO=git://github.com/openwrt/packages.git
PACKAGES_OPENWRT_COMMIT=a5944176bc761a3fd233c59bad1af96165e5b60f PACKAGES_OPENWRT_COMMIT=a5944176bc761a3fd233c59bad1af96165e5b60f
PACKAGES_OPENWRT_BRANCH=for-14.07 PACKAGES_OPENWRT_BRANCH=for-14.07
PACKAGES_GLUON_REPO=git://github.com/freifunk-gluon/packages.git PACKAGES_GLUON_REPO=git://github.com/freifunk-gluon/packages.git
PACKAGES_GLUON_COMMIT=1eff492575007ff8d7eb7d079a6cbd2c8979c6b7 PACKAGES_GLUON_COMMIT=2d49f5770480d7bd612e0fa89065c52c8db7b957
PACKAGES_ROUTING_REPO=git://github.com/openwrt-routing/packages.git PACKAGES_ROUTING_REPO=git://github.com/openwrt-routing/packages.git
PACKAGES_ROUTING_COMMIT=9d3c311fdd7dc15fd5e333b55c259fc2cf661ea2 PACKAGES_ROUTING_COMMIT=9d3c311fdd7dc15fd5e333b55c259fc2cf661ea2

View File

@ -1,20 +1,12 @@
From: Matthias Schiffer <mschiffer@universe-factory.net> From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Wed, 7 May 2014 22:57:10 +0200 Date: Sat, 26 Jul 2014 06:10:23 +0200
Subject: tools/Makefile: fix host tools build dependencies Subject: tools/Makefile: fix host tools build dependencies
diff --git a/tools/Makefile b/tools/Makefile diff --git a/tools/Makefile b/tools/Makefile
index 6658f8c..26a3fb1 100644 index 75d2b0d..ff1d299 100644
--- a/tools/Makefile --- a/tools/Makefile
+++ b/tools/Makefile +++ b/tools/Makefile
@@ -75,6 +75,7 @@ endif @@ -95,10 +95,16 @@ define PrepareStaging
$(curdir)/builddirs := $(tools-y) $(tools-dep) $(tools-)
$(curdir)/builddirs-default := $(tools-y)
+
ifndef DUMP_TARGET_DB
define PrepareStaging
@for dir in $(1); do ( \
@@ -86,10 +87,16 @@ define PrepareStaging
endef endef
# preparatory work # preparatory work
@ -31,7 +23,7 @@ index 6658f8c..26a3fb1 100644
$(STAGING_DIR_HOST)/.prepared: $(TMP_DIR)/.build $(STAGING_DIR_HOST)/.prepared: $(TMP_DIR)/.build
$(call PrepareStaging,$(STAGING_DIR_HOST)) $(call PrepareStaging,$(STAGING_DIR_HOST))
@@ -101,7 +108,7 @@ $(STAGING_DIR_HOST)/.prepared: $(TMP_DIR)/.build @@ -110,7 +116,7 @@ $(STAGING_DIR_HOST)/.prepared: $(TMP_DIR)/.build
define PrepareCommand define PrepareCommand
@ -40,7 +32,7 @@ index 6658f8c..26a3fb1 100644
@mkdir -p "$$(dir $$@)"; rm -f "$$@" @mkdir -p "$$(dir $$@)"; rm -f "$$@"
@export FILE="$$$$(which $(2) 2>/dev/null | grep -v 'not found' | head -n1)"; [ -n "$$$$FILE" ] || { \ @export FILE="$$$$(which $(2) 2>/dev/null | grep -v 'not found' | head -n1)"; [ -n "$$$$FILE" ] || { \
echo "Command $(1) not found."; false; \ echo "Command $(1) not found."; false; \
@@ -110,7 +117,7 @@ $(STAGING_DIR_HOST)/bin/$(1): $(STAGING_DIR)/.prepared @@ -119,7 +125,7 @@ $(STAGING_DIR_HOST)/bin/$(1): $(STAGING_DIR)/.prepared
endef endef
endif endif
@ -49,10 +41,10 @@ index 6658f8c..26a3fb1 100644
@rm -f $@ @rm -f $@
@if stat --version > /dev/null 2>&1; then \ @if stat --version > /dev/null 2>&1; then \
ln -s `which stat` $@; \ ln -s `which stat` $@; \
@@ -128,8 +135,8 @@ $(eval $(call PrepareCommand,seq,gseq seq)) @@ -143,8 +149,8 @@ $(eval $(call PrepareCommand,tar,gtar tar))
$(eval $(call PrepareCommand,python,python2 python)) $(eval $(call PrepareCommand,diff,gdiff diff))
$(curdir)/cmddeps = $(patsubst %,$(STAGING_DIR_HOST)/bin/%,find md5sum cp stat seq python) $(curdir)/cmddeps = $(patsubst %,$(STAGING_DIR_HOST)/bin/%,md5sum cp stat seq python awk getopt grep tar diff)
-$(curdir)//prepare = $(STAGING_DIR)/.prepared $(STAGING_DIR_HOST)/.prepared $($(curdir)/cmddeps) -$(curdir)//prepare = $(STAGING_DIR)/.prepared $(STAGING_DIR_HOST)/.prepared $($(curdir)/cmddeps)
-$(curdir)//compile = $(STAGING_DIR)/.prepared $(STAGING_DIR_HOST)/.prepared $($(curdir)/cmddeps) -$(curdir)//compile = $(STAGING_DIR)/.prepared $(STAGING_DIR_HOST)/.prepared $($(curdir)/cmddeps)
+$(curdir)//prepare = $(staging_prepared) $(STAGING_DIR_HOST)/.prepared $($(curdir)/cmddeps) +$(curdir)//prepare = $(staging_prepared) $(STAGING_DIR_HOST)/.prepared $($(curdir)/cmddeps)

View File

@ -1,19 +0,0 @@
From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Fri, 27 Dec 2013 18:48:19 +0100
Subject: Make Unifi images flashable
diff --git a/target/linux/ar71xx/image/Makefile b/target/linux/ar71xx/image/Makefile
index 9ebe486..8e82f7f 100644
--- a/target/linux/ar71xx/image/Makefile
+++ b/target/linux/ar71xx/image/Makefile
@@ -896,8 +896,8 @@ $(eval $(call SingleProfile,UBNTXM,$(fs_64k),UBNTAIRROUTER,ubnt-airrouter,UBNT-A
$(eval $(call SingleProfile,UBNTXM,$(fs_64k),UBNTBULLETM,ubnt-bullet-m,UBNT-BM,ttyS0,115200,XM,XM,ar7240))
$(eval $(call SingleProfile,UBNTXM,$(fs_64k),UBNTROCKETM,ubnt-rocket-m,UBNT-RM,ttyS0,115200,XM,XM,ar7240))
$(eval $(call SingleProfile,UBNTXM,$(fs_64k),UBNTNANOM,ubnt-nano-m,UBNT-NM,ttyS0,115200,XM,XM,ar7240))
-$(eval $(call SingleProfile,UBNTXM,$(fs_64k),UBNTUNIFI,ubnt-unifi,UBNT-UF,ttyS0,115200,XM,XM,ar7240))
-$(eval $(call SingleProfile,UBNTXM,$(fs_64k),UBNTUNIFIOUTDOOR,ubnt-unifi-outdoor,UBNT-U20,ttyS0,115200,XM,XM,ar7240))
+$(eval $(call SingleProfile,UBNTXM,$(fs_64k),UBNTUNIFI,ubnt-unifi,UBNT-UF,ttyS0,115200,XM,BZ,ar7240))
+$(eval $(call SingleProfile,UBNTXM,$(fs_64k),UBNTUNIFIOUTDOOR,ubnt-unifi-outdoor,UBNT-U20,ttyS0,115200,XM,BZ,ar7240))
$(eval $(call SingleProfile,WHRHPG300N,$(fs_64k),WHRG301N,whr-g301n,WHR-G301N,ttyS0,115200,$$(whrhpg300n_mtdlayout),WHR-G301N))
$(eval $(call SingleProfile,WHRHPG300N,$(fs_64k),WHRHPG300N,whr-hp-g300n,WHR-HP-G300N,ttyS0,115200,$$(whrhpg300n_mtdlayout),WHR-HP-G300N))

View File

@ -0,0 +1,107 @@
From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Wed, 6 Aug 2014 19:12:00 +0200
Subject: procd: add support for alternative rc.d directories
diff --git a/package/system/procd/patches/0001-Add-support-for-alternative-rc.d-directories.patch b/package/system/procd/patches/0001-Add-support-for-alternative-rc.d-directories.patch
new file mode 100644
index 0000000..bc24342
--- /dev/null
+++ b/package/system/procd/patches/0001-Add-support-for-alternative-rc.d-directories.patch
@@ -0,0 +1,97 @@
+From 03a2bc70e4260ec9f669391c47b9a7a9ecd0b75d Mon Sep 17 00:00:00 2001
+Message-Id: <03a2bc70e4260ec9f669391c47b9a7a9ecd0b75d.1407329621.git.mschiffer@universe-factory.net>
+From: Matthias Schiffer <mschiffer@universe-factory.net>
+Date: Wed, 6 Aug 2014 14:51:49 +0200
+Subject: [PATCH] Add support for alternative rc.d directories
+
+---
+ initd/preinit.c | 38 ++++++++++++++++++++++++++++++++++++++
+ rcS.c | 2 +-
+ 2 files changed, 39 insertions(+), 1 deletion(-)
+
+diff --git a/initd/preinit.c b/initd/preinit.c
+index fb94527..8b832a7 100644
+--- a/initd/preinit.c
++++ b/initd/preinit.c
+@@ -12,6 +12,8 @@
+ * GNU General Public License for more details.
+ */
+
++#define _GNU_SOURCE
++
+ #include <sys/stat.h>
+ #include <sys/types.h>
+ #include <sys/mount.h>
+@@ -46,6 +48,35 @@ check_dbglvl(void)
+ debug = lvl;
+ }
+
++static char*
++get_rc_d(void)
++{
++ size_t n = 0;
++ ssize_t len;
++ char *ret = NULL;
++
++ FILE *fp = fopen("/tmp/rc_d_path", "r");
++
++ if (!fp)
++ return NULL;
++
++ len = getline(&ret, &n, fp);
++
++ fclose(fp);
++
++ unlink("/tmp/rc_d_path");
++
++ if (len <= 0) {
++ free(ret);
++ return NULL;
++ }
++
++ if (ret[len-1] == '\n')
++ ret[len-1] = 0;
++
++ return ret;
++}
++
+ static void
+ spawn_procd(struct uloop_process *proc, int ret)
+ {
+@@ -53,6 +84,7 @@ spawn_procd(struct uloop_process *proc, int ret)
+ char *argv[] = { "/sbin/procd", NULL};
+ struct stat s;
+ char dbg[2];
++ char *rc_d_path;
+
+ if (plugd_proc.pid > 0)
+ kill(plugd_proc.pid, SIGKILL);
+@@ -72,6 +104,12 @@ spawn_procd(struct uloop_process *proc, int ret)
+ setenv("DBGLVL", dbg, 1);
+ }
+
++ rc_d_path = get_rc_d();
++ if (rc_d_path) {
++ setenv("RC_D_PATH", rc_d_path, 1);
++ free(rc_d_path);
++ }
++
+ execvp(argv[0], argv);
+ }
+
+diff --git a/rcS.c b/rcS.c
+index 0e1b0ba..1b00831 100644
+--- a/rcS.c
++++ b/rcS.c
+@@ -150,7 +150,7 @@ int rcS(char *pattern, char *param, void (*q_empty)(struct runqueue *))
+ q.empty_cb = q_empty;
+ q.max_running_tasks = 1;
+
+- return _rc(&q, "/etc/rc.d", pattern, "*", param);
++ return _rc(&q, getenv("RC_D_PATH") ?: "/etc/rc.d", pattern, "*", param);
+ }
+
+ int rc(const char *file, char *param)
+--
+2.0.4
+

View File

@ -1,379 +0,0 @@
From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Sat, 11 Jan 2014 11:47:31 +0100
Subject: Update netifd and its dependencies from Barrier Breaker (r41888)
diff --git a/package/libubox/Makefile b/package/libubox/Makefile
index bcf4481..6cbfc08 100644
--- a/package/libubox/Makefile
+++ b/package/libubox/Makefile
@@ -1,13 +1,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=libubox
-PKG_VERSION:=2013-10-19
+PKG_VERSION:=2014-07-16
PKG_RELEASE=$(PKG_SOURCE_VERSION)
PKG_SOURCE_PROTO:=git
-PKG_SOURCE_URL:=git://nbd.name/luci2/libubox.git
+PKG_SOURCE_URL:=http://git.openwrt.org/project/libubox.git
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
-PKG_SOURCE_VERSION:=734d28eb1a46358743cf8837c91e5d46695c3b91
+PKG_SOURCE_VERSION:=bd388d2b6c2c151bf513c1e449417d18ce02d10b
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_MD5SUM:=
CMAKE_INSTALL:=1
@@ -26,6 +26,7 @@ define Package/libubox
SECTION:=libs
CATEGORY:=Libraries
TITLE:=Basic utility library
+ ABI_VERSION:=$(PKG_VERSION)
DEPENDS:=
endef
@@ -54,6 +55,13 @@ define Package/libjson-script
TITLE:=Minimalistic JSON based scripting engine
endef
+define Package/libubox-lua
+ SECTION:=libs
+ CATEGORY:=Libraries
+ DEPENDS:=+libubox +liblua
+ TITLE:=Lua binding for the OpenWrt Basic utility library
+endef
+
TARGET_CFLAGS += -I$(STAGING_DIR)/usr/include
CMAKE_OPTIONS = \
-DLUAPATH=/usr/lib/lua
@@ -79,7 +87,13 @@ define Package/libjson-script/install
$(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/lib/libjson_script.so $(1)/lib/
endef
+define Package/libubox-lua/install
+ $(INSTALL_DIR) $(1)/usr/lib/lua
+ $(CP) $(PKG_BUILD_DIR)/lua/uloop.so $(1)/usr/lib/lua/
+endef
+
$(eval $(call BuildPackage,libubox))
$(eval $(call BuildPackage,libblobmsg-json))
$(eval $(call BuildPackage,jshn))
$(eval $(call BuildPackage,libjson-script))
+$(eval $(call BuildPackage,libubox-lua))
diff --git a/package/netifd/Makefile b/package/netifd/Makefile
index 5f2ee03..faf3e09 100644
--- a/package/netifd/Makefile
+++ b/package/netifd/Makefile
@@ -1,13 +1,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=netifd
-PKG_VERSION:=2013-07-16
+PKG_VERSION:=2014-07-29
PKG_RELEASE=$(PKG_SOURCE_VERSION)
PKG_SOURCE_PROTO:=git
-PKG_SOURCE_URL:=git://nbd.name/luci2/netifd.git
+PKG_SOURCE_URL:=http://git.openwrt.org/project/netifd.git
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
-PKG_SOURCE_VERSION:=2674941b06c1ec67f1aff1bff9212e1372106641
+PKG_SOURCE_VERSION:=4bf89afc22b43d5bd155d32d3998348a77179c1a
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MAINTAINER:=Felix Fietkau <nbd@openwrt.org>
# PKG_MIRROR_MD5SUM:=
@@ -24,7 +24,7 @@ include $(INCLUDE_DIR)/cmake.mk
define Package/netifd
SECTION:=base
CATEGORY:=Base system
- DEPENDS:=+libuci +libnl-tiny +libubus +ubus +ubusd +jshn
+ DEPENDS:=+libuci +libnl-tiny +libubus +ubus +ubusd +jshn +libubox
TITLE:=OpenWrt Network Interface Configuration Daemon
endef
@@ -40,7 +40,7 @@ define Package/netifd/install
$(INSTALL_DIR) $(1)/sbin
$(INSTALL_BIN) $(PKG_BUILD_DIR)/netifd $(1)/sbin/
$(CP) ./files/* $(1)/
- $(CP) $(PKG_BUILD_DIR)/dummy/netifd-proto.sh $(1)/lib/netifd/
+ $(CP) $(PKG_BUILD_DIR)/scripts/* $(1)/lib/netifd/
endef
$(eval $(call BuildPackage,netifd))
diff --git a/package/netifd/files/etc/hotplug.d/iface/00-netstate b/package/netifd/files/etc/hotplug.d/iface/00-netstate
index c50cda6..023025c 100644
--- a/package/netifd/files/etc/hotplug.d/iface/00-netstate
+++ b/package/netifd/files/etc/hotplug.d/iface/00-netstate
@@ -1,6 +1,5 @@
[ ifup = "$ACTION" ] && {
uci_toggle_state network "$INTERFACE" up 1
- uci_toggle_state network "$INTERFACE" connect_time $(sed -ne 's![^0-9].*$!!p' /proc/uptime)
[ -n "$DEVICE" ] && {
uci_toggle_state network "$INTERFACE" device "$(uci -q get network.$INTERFACE.ifname)"
uci_toggle_state network "$INTERFACE" ifname "$DEVICE"
diff --git a/package/netifd/files/lib/netifd/dhcp.script b/package/netifd/files/lib/netifd/dhcp.script
index 50163da..db3fc01 100755
--- a/package/netifd/files/lib/netifd/dhcp.script
+++ b/package/netifd/files/lib/netifd/dhcp.script
@@ -33,9 +33,15 @@ setup_interface () {
for domain in $domain; do
proto_add_dns_search "$domain"
done
+
+ proto_add_data
+ [ -n "$ZONE" ] && json_add_string zone "$ZONE"
+ proto_close_data
+
proto_send_update "$INTERFACE"
- if [ -n "$IFACE6RD" -a -n "$ip6rd" ]; then
+
+ if [ "$IFACE6RD" != 0 -a -n "$ip6rd" ]; then
local v4mask="${ip6rd%% *}"
ip6rd="${ip6rd#* }"
local ip6rdprefixlen="${ip6rd%% *}"
@@ -44,19 +50,24 @@ setup_interface () {
ip6rd="${ip6rd#* }"
local ip6rdbr="${ip6rd%% *}"
-uci -q batch <<-EOF >/dev/null
-set network.$IFACE6RD.proto=6rd
-set network.$IFACE6RD.auto=0
-set network.$IFACE6RD.peeraddr=$ip6rdbr
-set network.$IFACE6RD.ip4prefixlen=$v4mask
-set network.$IFACE6RD.ip6prefix=$ip6rdprefix
-set network.$IFACE6RD.ip6prefixlen=$ip6rdprefixlen
-commit network
-EOF
-
- ifdown "$IFACE6RD"
- /etc/init.d/network reload
- ifup "$IFACE6RD"
+ [ -n "$ZONE" ] || ZONE=$(fw3 network $INTERFACE)
+ [ -z "$IFACE6RD" -o "$IFACE6RD" = 1 ] && IFACE6RD=${INTERFACE}_6rd
+
+ json_init
+ json_add_string name "$IFACE6RD"
+ json_add_string ifname "@$INTERFACE"
+ json_add_string proto "6rd"
+ json_add_string peeraddr "$ip6rdbr"
+ json_add_int ip4prefixlen "$v4mask"
+ json_add_string ip6prefix "$ip6rdprefix"
+ json_add_int ip6prefixlen "$ip6rdprefixlen"
+ json_add_string tunlink "$INTERFACE"
+ [ -n "$IFACE6RD_DELEGATE" ] && json_add_boolean delegate "$IFACE6RD_DELEGATE"
+ [ -n "$ZONE6RD" ] || ZONE6RD=$ZONE
+ [ -n "$ZONE6RD" ] && json_add_string zone "$ZONE6RD"
+ json_close_object
+
+ ubus call network add_dynamic "$(json_dump)"
fi
# TODO
diff --git a/package/netifd/files/lib/netifd/proto/dhcp.sh b/package/netifd/files/lib/netifd/proto/dhcp.sh
index a270c68..b14f7be 100755
--- a/package/netifd/files/lib/netifd/proto/dhcp.sh
+++ b/package/netifd/files/lib/netifd/proto/dhcp.sh
@@ -5,31 +5,44 @@
init_proto "$@"
proto_dhcp_init_config() {
- proto_config_add_string "ipaddr"
- proto_config_add_string "netmask"
- proto_config_add_string "hostname"
- proto_config_add_string "clientid"
- proto_config_add_string "vendorid"
- proto_config_add_boolean "broadcast"
- proto_config_add_string "reqopts"
- proto_config_add_string "iface6rd"
+ renew_handler=1
+
+ proto_config_add_string 'ipaddr:ipaddr'
+ proto_config_add_string 'hostname:hostname'
+ proto_config_add_string clientid
+ proto_config_add_string vendorid
+ proto_config_add_boolean 'broadcast:bool'
+ proto_config_add_string 'reqopts:list(string)'
+ proto_config_add_string iface6rd
+ proto_config_add_string sendopts
+ proto_config_add_boolean delegate
+ proto_config_add_string zone6rd
+ proto_config_add_string zone
}
proto_dhcp_setup() {
local config="$1"
local iface="$2"
- local ipaddr hostname clientid vendorid broadcast reqopts iface6rd
- json_get_vars ipaddr hostname clientid vendorid broadcast reqopts iface6rd
+ local ipaddr hostname clientid vendorid broadcast reqopts iface6rd sendopts delegate zone6rd zone
+ json_get_vars ipaddr hostname clientid vendorid broadcast reqopts iface6rd sendopts delegate zone6rd zone
local opt dhcpopts
for opt in $reqopts; do
append dhcpopts "-O $opt"
done
+ for opt in $sendopts; do
+ append dhcpopts "-x $opt"
+ done
+
[ "$broadcast" = 1 ] && broadcast="-B" || broadcast=
[ -n "$clientid" ] && clientid="-x 0x3d:${clientid//:/}" || clientid="-C"
[ -n "$iface6rd" ] && proto_export "IFACE6RD=$iface6rd"
+ [ -n "$iface6rd" ] && append dhcpopts "-O 212"
+ [ -n "$zone6rd" ] && proto_export "ZONE6RD=$zone6rd"
+ [ -n "$zone" ] && proto_export "ZONE=$zone"
+ [ "$delegate" = "0" ] && proto_export "IFACE6RD_DELEGATE=0"
proto_export "INTERFACE=$config"
proto_run_command "$config" udhcpc \
@@ -42,10 +55,16 @@ proto_dhcp_setup() {
$clientid $broadcast $dhcpopts
}
+proto_dhcp_renew() {
+ local interface="$1"
+ # SIGUSR1 forces udhcpc to renew its lease
+ local sigusr1="$(kill -l SIGUSR1)"
+ [ -n "$sigusr1" ] && proto_kill_command "$interface" $sigusr1
+}
+
proto_dhcp_teardown() {
local interface="$1"
proto_kill_command "$interface"
}
add_protocol dhcp
-
diff --git a/package/netifd/patches/001-musl_af_inet_include.patch b/package/netifd/patches/001-musl_af_inet_include.patch
new file mode 100644
index 0000000..510ee05
--- /dev/null
+++ b/package/netifd/patches/001-musl_af_inet_include.patch
@@ -0,0 +1,11 @@
+diff -urN netifd-2012-10-29/utils.c netifd-2012-10-29.new/utils.c
+--- netifd-2012-10-29/utils.c 2012-11-23 17:15:39.000000000 +0100
++++ netifd-2012-10-29.new/utils.c 2012-11-23 17:16:53.409244361 +0100
+@@ -17,6 +17,7 @@
+
+ #include <arpa/inet.h>
+ #include <netinet/in.h>
++#include <sys/socket.h>
+
+ void
+ __vlist_simple_init(struct vlist_simple_tree *tree, int offset)
diff --git a/package/netifd/patches/002-fix_compile_with_old_includes.patch b/package/netifd/patches/002-fix_compile_with_old_includes.patch
new file mode 100644
index 0000000..361b2d1
--- /dev/null
+++ b/package/netifd/patches/002-fix_compile_with_old_includes.patch
@@ -0,0 +1,34 @@
+--- a/system-linux.c
++++ b/system-linux.c
+@@ -43,6 +43,31 @@
+ #define RTN_FAILED_POLICY 12
+ #endif
+
++
++#ifndef IFLA_IPTUN_MAX
++enum {
++ IFLA_IPTUN_UNSPEC,
++ IFLA_IPTUN_LINK,
++ IFLA_IPTUN_LOCAL,
++ IFLA_IPTUN_REMOTE,
++ IFLA_IPTUN_TTL,
++ IFLA_IPTUN_TOS,
++ IFLA_IPTUN_ENCAP_LIMIT,
++ IFLA_IPTUN_FLOWINFO,
++ IFLA_IPTUN_FLAGS,
++ IFLA_IPTUN_PROTO,
++ IFLA_IPTUN_PMTUDISC,
++ IFLA_IPTUN_6RD_PREFIX,
++ IFLA_IPTUN_6RD_RELAY_PREFIX,
++ IFLA_IPTUN_6RD_PREFIXLEN,
++ IFLA_IPTUN_6RD_RELAY_PREFIXLEN,
++ __IFLA_IPTUN_MAX,
++};
++#define IFLA_IPTUN_MAX (__IFLA_IPTUN_MAX - 1)
++#endif
++
++
++
+ #include <string.h>
+ #include <fcntl.h>
+ #include <glob.h>
diff --git a/package/ubus/Makefile b/package/ubus/Makefile
index be18fb5..ba96b3b 100644
--- a/package/ubus/Makefile
+++ b/package/ubus/Makefile
@@ -1,13 +1,13 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=ubus
-PKG_VERSION:=2013-08-08
+PKG_VERSION:=2014-07-03
PKG_RELEASE=$(PKG_SOURCE_VERSION)
PKG_SOURCE_PROTO:=git
PKG_SOURCE_URL:=git://nbd.name/luci2/ubus.git
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
-PKG_SOURCE_VERSION:=b20a8a01c7faea5bcc9d34d10dcf7736589021b8
+PKG_SOURCE_VERSION:=f688c7ad0b2435a89bfd13f5496cabf596b54c8f
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-$(PKG_SOURCE_VERSION).tar.gz
PKG_MIRROR_MD5SUM:=
CMAKE_INSTALL:=1
@@ -38,6 +38,7 @@ define Package/libubus
SECTION:=libs
CATEGORY:=Libraries
DEPENDS:=+libubox
+ ABI_VERSION:=$(PKG_VERSION)
TITLE:=OpenWrt RPC client library
endef
@@ -66,7 +67,7 @@ endef
define Package/libubus/install
$(INSTALL_DIR) $(1)/lib
- $(CP) $(PKG_INSTALL_DIR)/usr/lib/* $(1)/lib/
+ $(CP) $(PKG_INSTALL_DIR)/usr/lib/*.so $(1)/lib/
endef
define Package/libubus-lua/install
@@ -74,8 +75,7 @@ define Package/libubus-lua/install
$(CP) $(PKG_BUILD_DIR)/lua/ubus.so $(1)/usr/lib/lua/
endef
-$(eval $(call BuildPackage,ubus))
-$(eval $(call BuildPackage,ubusd))
$(eval $(call BuildPackage,libubus))
$(eval $(call BuildPackage,libubus-lua))
-
+$(eval $(call BuildPackage,ubus))
+$(eval $(call BuildPackage,ubusd))
diff --git a/package/uci/Makefile b/package/uci/Makefile
index 54ad80b..29f9ef3 100644
--- a/package/uci/Makefile
+++ b/package/uci/Makefile
@@ -1,5 +1,5 @@
#
-# Copyright (C) 2008-2013 OpenWrt.org
+# Copyright (C) 2008-2014 OpenWrt.org
#
# This is free software, licensed under the GNU General Public License v2.
# See /LICENSE for more information.
@@ -7,13 +7,13 @@
include $(TOPDIR)/rules.mk
-UCI_VERSION=2013-06-11
+UCI_VERSION=2014-04-11
UCI_RELEASE=1
PKG_NAME:=uci
PKG_VERSION:=$(UCI_VERSION)$(if $(UCI_RELEASE),.$(UCI_RELEASE))
PKG_RELEASE:=1
-PKG_REV:=c9c9d5cb085acc58b6579ace83fb79c085a9db27
+PKG_REV:=e339407372ffc70b1451e4eda218c01aa95a6a7f
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=git://nbd.name/uci.git

View File

@ -1,283 +0,0 @@
From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Sat, 11 Jan 2014 11:47:58 +0100
Subject: Update odhcp6c from Barrier Breaker (r41830)
diff --git a/package/odhcp6c/Makefile b/package/odhcp6c/Makefile
index e767064..3ec58e1 100644
--- a/package/odhcp6c/Makefile
+++ b/package/odhcp6c/Makefile
@@ -8,26 +8,55 @@
include $(TOPDIR)/rules.mk
PKG_NAME:=odhcp6c
-PKG_VERSION:=2013-10-02
-PKG_RELEASE=$(PKG_SOURCE_VERSION)-1
+PKG_VERSION:=2014-07-21
+PKG_RELEASE=$(PKG_SOURCE_VERSION)
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
PKG_SOURCE_URL:=git://github.com/sbyx/odhcp6c.git
PKG_SOURCE_PROTO:=git
-PKG_SOURCE_VERSION:=357ecc1f5163bc7f74c64f4bca387e8d44a2eac5
+PKG_SOURCE_VERSION:=67b311ab81736b35858664219d345844ab08fcc7
PKG_MAINTAINER:=Steven Barth <steven@midlink.org>
include $(INCLUDE_DIR)/package.mk
include $(INCLUDE_DIR)/cmake.mk
+ifneq ($(CONFIG_PACKAGE_odhcp6c_ext_prefix_class),0)
+ CMAKE_OPTIONS += -DEXT_PREFIX_CLASS=$(CONFIG_PACKAGE_odhcp6c_ext_prefix_class)
+endif
+
+ifneq ($(CONFIG_PACKAGE_odhcp6c_ext_cer_id),0)
+ CMAKE_OPTIONS += -DEXT_CER_ID=$(CONFIG_PACKAGE_odhcp6c_ext_cer_id)
+endif
+
+ifneq ($(CONFIG_PACKAGE_odhcp6c_ext_s46),0)
+ CMAKE_OPTIONS += -DEXT_S46=$(CONFIG_PACKAGE_odhcp6c_ext_s46)
+endif
+
define Package/odhcp6c
- SECTION:=ipv6
- CATEGORY:=IPv6
+ SECTION:=net
+ CATEGORY:=Network
TITLE:=Embedded DHCPv6-client for OpenWrt
DEPENDS:=+kmod-ipv6
endef
+define Package/odhcp6c/config
+ config PACKAGE_odhcp6c_ext_prefix_class
+ int "Prefix Class Extension ID (0 = disabled)"
+ depends on PACKAGE_odhcp6c
+ default 0
+
+ config PACKAGE_odhcp6c_ext_cer_id
+ int "CER-ID Extension ID (0 = disabled)"
+ depends on PACKAGE_odhcp6c
+ default 0
+
+ config PACKAGE_odhcp6c_ext_s46
+ int "Softwire MAP Extension ID (0 = disabled)"
+ depends on PACKAGE_odhcp6c
+ default 0
+endef
+
define Package/odhcp6c/install
$(INSTALL_DIR) $(1)/usr/sbin/
$(INSTALL_BIN) $(PKG_BUILD_DIR)/odhcp6c $(1)/usr/sbin/
diff --git a/package/odhcp6c/files/dhcpv6.script b/package/odhcp6c/files/dhcpv6.script
index 324a823..8c1ba18 100755
--- a/package/odhcp6c/files/dhcpv6.script
+++ b/package/odhcp6c/files/dhcpv6.script
@@ -64,23 +64,68 @@ setup_interface () {
entry="${entry#*,}"
local metric="${entry%%,*}"
- proto_add_ipv6_route "$addr" "$mask" "$gw" "$metric" "$valid"
+ if [ -z "$SOURCE_ROUTING" -o -z "$gw" ]; then
+ proto_add_ipv6_route "$addr" "$mask" "$gw" "$metric" "$valid"
+ else
+ proto_add_ipv6_route "$addr" "$mask" "$gw" "$metric" "$valid" "::/128"
+ for prefix in $PREFIXES $ADDRESSES; do
+ local paddr="${prefix%%,*}"
+ proto_add_ipv6_route "$addr" "$mask" "$gw" "$metric" "$valid" "$paddr"
+ done
+ fi
done
+ proto_add_data
+ [ -n "$CER" ] && json_add_string cer "$CER"
+ [ -n "$PASSTHRU" ] && json_add_string passthru "$PASSTHRU"
+ [ -n "$ZONE" ] && json_add_string zone "$ZONE"
+ proto_close_data
+
proto_send_update "$INTERFACE"
- if [ -n "$AFTR_IP " -a -n "$IFACE_DSLITE" ]; then
-uci -q batch <<-EOF >/dev/null
-set network.$IFACE_DSLITE.proto=dslite
-set network.$IFACE_DSLITE.auto=0
-set network.$IFACE_DSLITE.peeraddr=$AFTR_IP
-set network.$IFACE_DSLITE.tunlink=$INTERFACE
-commit network
-EOF
-
- ifdown "$IFACE_DSLITE"
- /etc/init.d/network reload
- ifup "$IFACE_DSLITE"
+ MAPTYPE=""
+ MAPRULE=""
+
+ if [ -n "$MAPE" -a -f /lib/netifd/proto/map.sh ]; then
+ MAPTYPE="map-e"
+ MAPRULE="$MAPE"
+ elif [ -n "$MAPT" -a -f /lib/netifd/proto/map.sh -a -f /proc/net/nat46/control ]; then
+ MAPTYPE="map-t"
+ MAPRULE="$MAPT"
+ elif [ -n "$LW4O6" -a -f /lib/netifd/proto/map.sh ]; then
+ MAPTYPE="lw4o6"
+ MAPRULE="$LW4O6"
+ fi
+
+ [ -n "$ZONE" ] || ZONE=$(fw3 network $INTERFACE)
+
+ if [ "$IFACE_MAP" != 0 -a -n "$MAPTYPE" -a -n "$MAPRULE" ]; then
+ [ -z "$IFACE_MAP" -o "$IFACE_MAP" = 1 ] && IFACE_MAP=${INTERFACE}_map
+ json_init
+ json_add_string name "$IFACE_MAP"
+ json_add_string ifname "@$INTERFACE"
+ json_add_string proto map
+ json_add_string type "$MAPTYPE"
+ json_add_string rule "$MAPRULE"
+ json_add_string tunlink "$INTERFACE"
+ [ -n "$ZONE_MAP" ] || ZONE_MAP=$ZONE
+ [ -n "$ZONE_MAP" ] && json_add_string zone "$ZONE_MAP"
+ [ -n "$IFACE_MAP_DELEGATE" ] && json_add_boolean delegate "$IFACE_MAP_DELEGATE"
+ json_close_object
+ ubus call network add_dynamic "$(json_dump)"
+ elif [ -n "$AFTR_IP " -a "$IFACE_DSLITE" != 0 -a -f /lib/netifd/proto/dslite.sh ]; then
+ [ -z "$IFACE_DSLITE" -o "$IFACE_DSLITE" = 1 ] && IFACE_DSLITE=${INTERFACE}_dslite
+ json_init
+ json_add_string name "$IFACE_DSLITE"
+ json_add_string ifname "@$INTERFACE"
+ json_add_string proto "dslite"
+ json_add_string peeraddr "$AFTR_IP"
+ json_add_string tunlink "$INTERFACE"
+ [ -n "$ZONE_DSLITE" ] || ZONE_DSLITE=$ZONE
+ [ -n "$ZONE_DSLITE" ] && json_add_string zone "$ZONE_DSLITE"
+ [ -n "$IFACE_DSLITE_DELEGATE" ] && json_add_boolean delegate "$IFACE_DSLITE_DELEGATE"
+ json_close_object
+ ubus call network add_dynamic "$(json_dump)"
fi
# TODO: $SNTP_IP $SIP_IP $SNTP_FQDN $SIP_DOMAIN
diff --git a/package/odhcp6c/files/dhcpv6.sh b/package/odhcp6c/files/dhcpv6.sh
index bf6cd9a..0690bd1 100755
--- a/package/odhcp6c/files/dhcpv6.sh
+++ b/package/odhcp6c/files/dhcpv6.sh
@@ -5,23 +5,35 @@
init_proto "$@"
proto_dhcpv6_init_config() {
- proto_config_add_string "reqaddress"
- proto_config_add_string "reqprefix"
- proto_config_add_string "clientid"
- proto_config_add_string "reqopts"
- proto_config_add_string "noslaaconly"
- proto_config_add_string "norelease"
- proto_config_add_string "ip6prefix"
- proto_config_add_string "iface_dslite"
- proto_config_add_string "ifaceid"
+ renew_handler=1
+
+ proto_config_add_string 'reqaddress:or("try","force","none")'
+ proto_config_add_string 'reqprefix:or("auto","no",range(0, 64))'
+ proto_config_add_string clientid
+ proto_config_add_string 'reqopts:list(uinteger)'
+ proto_config_add_string 'noslaaconly:bool'
+ proto_config_add_string 'forceprefix:bool'
+ proto_config_add_string 'norelease:bool'
+ proto_config_add_string 'ip6prefix:ip6addr'
+ proto_config_add_string iface_dslite
+ proto_config_add_string zone_dslite
+ proto_config_add_string iface_map
+ proto_config_add_string zone_map
+ proto_config_add_string zone
+ proto_config_add_string 'ifaceid:ip6addr'
+ proto_config_add_string 'sourcerouting:bool'
+ proto_config_add_string "userclass"
+ proto_config_add_string "vendorclass"
+ proto_config_add_boolean delegate
+ proto_config_add_int "soltimeout"
}
proto_dhcpv6_setup() {
local config="$1"
local iface="$2"
- local reqaddress reqprefix clientid reqopts noslaaconly norelease ip6prefix iface_dslite ifaceid
- json_get_vars reqaddress reqprefix clientid reqopts noslaaconly norelease ip6prefix iface_dslite ifaceid
+ local reqaddress reqprefix clientid reqopts noslaaconly forceprefix norelease ip6prefix iface_dslite iface_map ifaceid sourcerouting userclass vendorclass delegate zone_dslite zone_map zone soltimeout
+ json_get_vars reqaddress reqprefix clientid reqopts noslaaconly forceprefix norelease ip6prefix iface_dslite iface_map ifaceid sourcerouting userclass vendorclass delegate zone_dslite zone_map zone soltimeout
# Configure
@@ -35,16 +47,31 @@ proto_dhcpv6_setup() {
[ "$noslaaconly" = "1" ] && append opts "-S"
+ [ "$forceprefix" = "1" ] && append opts "-F"
+
[ "$norelease" = "1" ] && append opts "-k"
[ -n "$ifaceid" ] && append opts "-i$ifaceid"
+ [ -n "$vendorclass" ] && append opts "-V$vendorclass"
+
+ [ -n "$userclass" ] && append opts "-u$userclass"
+
for opt in $reqopts; do
append opts "-r$opt"
done
+ append opts "-t${soltimeout:-120}"
+
[ -n "$ip6prefix" ] && proto_export "USERPREFIX=$ip6prefix"
[ -n "$iface_dslite" ] && proto_export "IFACE_DSLITE=$iface_dslite"
+ [ -n "$iface_map" ] && proto_export "IFACE_MAP=$iface_map"
+ [ "$sourcerouting" != "0" ] && proto_export "SOURCE_ROUTING=1"
+ [ "$delegate" = "0" ] && proto_export "IFACE_DSLITE_DELEGATE=0"
+ [ "$delegate" = "0" ] && proto_export "IFACE_MAP_DELEGATE=0"
+ [ -n "$zone_dslite" ] && proto_export "ZONE_DSLITE=$zone_dslite"
+ [ -n "$zone_map" ] && proto_export "ZONE_MAP=$zone_map"
+ [ -n "$zone" ] && proto_export "ZONE=$zone"
proto_export "INTERFACE=$config"
proto_run_command "$config" odhcp6c \
@@ -52,6 +79,13 @@ proto_dhcpv6_setup() {
$opts $iface
}
+proto_dhcpv6_renew() {
+ local interface="$1"
+ # SIGUSR1 forces odhcp6c to renew its lease
+ local sigusr1="$(kill -l SIGUSR1)"
+ [ -n "$sigusr1" ] && proto_kill_command "$interface" $sigusr1
+}
+
proto_dhcpv6_teardown() {
local interface="$1"
proto_kill_command "$interface"
diff --git a/package/odhcp6c/patches/001-fix-integer-overflow-after-50-days.patch b/package/odhcp6c/patches/001-fix-integer-overflow-after-50-days.patch
deleted file mode 100644
index 292d023..0000000
--- a/package/odhcp6c/patches/001-fix-integer-overflow-after-50-days.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From 5b98f902f616bd9b96a2128587bc6995555a43c1 Mon Sep 17 00:00:00 2001
-From: Steven Barth <steven@midlink.org>
-Date: Fri, 7 Mar 2014 10:33:49 +0100
-Subject: [PATCH] fix integer overflow after 50 days (thx Hauke Mehrtens)
-
----
- src/odhcp6c.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/odhcp6c.c b/src/odhcp6c.c
-index 3c6b3b0..ba11ced 100644
---- a/src/odhcp6c.c
-+++ b/src/odhcp6c.c
-@@ -470,7 +470,7 @@ uint64_t odhcp6c_get_milli_time(void)
- {
- struct timespec t = {0, 0};
- syscall(SYS_clock_gettime, CLOCK_MONOTONIC, &t);
-- return t.tv_sec * 1000 + t.tv_nsec / 1000000;
-+ return ((uint64_t)t.tv_sec) * 1000 + ((uint64_t)t.tv_nsec) / 1000000;
- }
-
-
---
-1.7.10.4
-

View File

@ -1,22 +0,0 @@
From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Sat, 11 Jan 2014 13:31:13 +0100
Subject: package/base-files: change sysctl handling
Add hotplug script that applies interface specific sysctls for interfaces that
only appear later - this allows to reliably configure per-interface parameters
in sysctl.conf, e.g. to disable ipv6 autoconfig on a specific iface.
Cherry-picked from Barrier Breaker
diff --git a/package/base-files/files/etc/hotplug.d/net/00-sysctl b/package/base-files/files/etc/hotplug.d/net/00-sysctl
new file mode 100644
index 0000000..5d9da8a
--- /dev/null
+++ b/package/base-files/files/etc/hotplug.d/net/00-sysctl
@@ -0,0 +1,6 @@
+#!/bin/sh
+
+if [ -f /etc/sysctl.conf ] && [ "$ACTION" = add ]; then
+ sed -ne "/^[[:space:]]*net\..*\.$DEVICENAME\./p" /etc/sysctl.conf | \
+ sysctl -e -p - | logger -t sysctl
+fi

View File

@ -1,39 +0,0 @@
From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Sat, 11 Jan 2014 17:08:59 +0100
Subject: Fix ping6 sender address
diff --git a/package/busybox/patches/960-ping6_sender_address.patch b/package/busybox/patches/960-ping6_sender_address.patch
new file mode 100644
index 0000000..7c56a6d
--- /dev/null
+++ b/package/busybox/patches/960-ping6_sender_address.patch
@@ -0,0 +1,29 @@
+--- a/networking/ping.c
++++ b/networking/ping.c
+@@ -638,7 +638,7 @@ static void unpack4(char *buf, int sz, s
+ }
+ }
+ #if ENABLE_PING6
+-static void unpack6(char *packet, int sz, /*struct sockaddr_in6 *from,*/ int hoplimit)
++static void unpack6(char *packet, int sz, struct sockaddr_in6 *from, int hoplimit)
+ {
+ struct icmp6_hdr *icmppkt;
+ char buf[INET6_ADDRSTRLEN];
+@@ -658,7 +658,7 @@ static void unpack6(char *packet, int sz
+ if (sz >= sizeof(struct icmp6_hdr) + sizeof(uint32_t))
+ tp = (uint32_t *) &icmppkt->icmp6_data8[4];
+ unpack_tail(sz, tp,
+- inet_ntop(AF_INET6, &pingaddr.sin6.sin6_addr,
++ inet_ntop(AF_INET6, &from->sin6_addr,
+ buf, sizeof(buf)),
+ recv_seq, hoplimit);
+ } else if (icmppkt->icmp6_type != ICMP6_ECHO_REQUEST) {
+@@ -808,7 +808,7 @@ static void ping6(len_and_sockaddr *lsa)
+ move_from_unaligned_int(hoplimit, CMSG_DATA(mp));
+ }
+ }
+- unpack6(G.rcv_packet, c, /*&from,*/ hoplimit);
++ unpack6(G.rcv_packet, c, &from, hoplimit);
+ if (pingcount && nreceived >= pingcount)
+ break;
+ }

View File

@ -1,246 +0,0 @@
From: juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Fri, 1 Feb 2013 15:50:29 +0000
Subject: ar71xx: add kernel support for the TL-WDR3500 board
WDR3500 is similar to WDR3600 except it doesn't have gigabit ethernet,
and has only 1 USB port.
Pending issues:
* Leds are not working at all (except power and wlan_5g)
* LAN switch ethernet ports are reversed with respect to case label.
[Label] -> soft device
[LAN1] -> eth0.4
[LAN2] -> eth0.3
[LAN3] -> eth0.2
[LAN4] -> eth0.1
Based on http://patchwork.openwrt.org/patch/3208/
Thanks-to: Paul Fertser <fercerpav@gmail.com>
Signed-off-by: Gui Iribarren <gui@altermundi.net>
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@35423 3c298f89-4303-0410-b956-a3cf2f4a3e73
Conflicts:
target/linux/ar71xx/config-3.7
diff --git a/target/linux/ar71xx/config-3.3 b/target/linux/ar71xx/config-3.3
index 446f202..dfc5bf2 100644
--- a/target/linux/ar71xx/config-3.3
+++ b/target/linux/ar71xx/config-3.3
@@ -60,6 +60,7 @@ CONFIG_ATH79_MACH_TL_MR3020=y
CONFIG_ATH79_MACH_TL_MR3X20=y
CONFIG_ATH79_MACH_TL_WA901ND=y
CONFIG_ATH79_MACH_TL_WA901ND_V2=y
+CONFIG_ATH79_MACH_TL_WDR3500=y
CONFIG_ATH79_MACH_TL_WDR4300=y
CONFIG_ATH79_MACH_TL_WR1041N_V2=y
CONFIG_ATH79_MACH_TL_WR1043ND=y
diff --git a/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c
new file mode 100644
index 0000000..05fe83d
--- /dev/null
+++ b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c
@@ -0,0 +1,153 @@
+/*
+ * TP-LINK TL-WDR3500 board support
+ *
+ * Copyright (C) 2012 Gabor Juhos <juhosg@openwrt.org>
+ * Copyright (C) 2013 Gui Iribarren <gui@altermundi.net>
+ *
+ * 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 <linux/pci.h>
+#include <linux/phy.h>
+#include <linux/gpio.h>
+#include <linux/platform_device.h>
+#include <linux/ath9k_platform.h>
+#include <linux/ar8216_platform.h>
+
+#include <asm/mach-ath79/ar71xx_regs.h>
+
+#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 WDR3500_GPIO_LED_USB1 11
+#define WDR3500_GPIO_LED_WLAN2G 13
+#define WDR3500_GPIO_LED_SYSTEM 14
+#define WDR3500_GPIO_LED_QSS 15
+
+#define WDR3500_GPIO_BTN_WPS 16
+#define WDR3500_GPIO_BTN_RFKILL 17
+
+#define WDR3500_GPIO_USB1_POWER 22
+
+#define WDR3500_KEYS_POLL_INTERVAL 20 /* msecs */
+#define WDR3500_KEYS_DEBOUNCE_INTERVAL (3 * WDR3500_KEYS_POLL_INTERVAL)
+
+#define WDR3500_MAC0_OFFSET 0
+#define WDR3500_MAC1_OFFSET 6
+#define WDR3500_WMAC_CALDATA_OFFSET 0x1000
+#define WDR3500_PCIE_CALDATA_OFFSET 0x5000
+
+static const char *wdr3500_part_probes[] = {
+ "tp-link",
+ NULL,
+};
+
+static struct flash_platform_data wdr3500_flash_data = {
+ .part_probes = wdr3500_part_probes,
+};
+
+static struct gpio_led wdr3500_leds_gpio[] __initdata = {
+ {
+ .name = "tp-link:green:qss",
+ .gpio = WDR3500_GPIO_LED_QSS,
+ .active_low = 1,
+ },
+ {
+ .name = "tp-link:green:system",
+ .gpio = WDR3500_GPIO_LED_SYSTEM,
+ .active_low = 1,
+ },
+ {
+ .name = "tp-link:green:usb1",
+ .gpio = WDR3500_GPIO_LED_USB1,
+ .active_low = 1,
+ },
+ {
+ .name = "tp-link:green:wlan2g",
+ .gpio = WDR3500_GPIO_LED_WLAN2G,
+ .active_low = 1,
+ },
+};
+
+static struct gpio_keys_button wdr3500_gpio_keys[] __initdata = {
+ {
+ .desc = "QSS button",
+ .type = EV_KEY,
+ .code = KEY_WPS_BUTTON,
+ .debounce_interval = WDR3500_KEYS_DEBOUNCE_INTERVAL,
+ .gpio = WDR3500_GPIO_BTN_WPS,
+ .active_low = 1,
+ },
+ {
+ .desc = "RFKILL switch",
+ .type = EV_SW,
+ .code = KEY_RFKILL,
+ .debounce_interval = WDR3500_KEYS_DEBOUNCE_INTERVAL,
+ .gpio = WDR3500_GPIO_BTN_RFKILL,
+ },
+};
+
+
+static void __init wdr3500_setup(void)
+{
+ u8 *mac = (u8 *) KSEG1ADDR(0x1f01fc00);
+ u8 *art = (u8 *) KSEG1ADDR(0x1fff0000);
+ u8 tmpmac[ETH_ALEN];
+
+ ath79_register_m25p80(&wdr3500_flash_data);
+ ath79_register_leds_gpio(-1, ARRAY_SIZE(wdr3500_leds_gpio),
+ wdr3500_leds_gpio);
+ ath79_register_gpio_keys_polled(-1, WDR3500_KEYS_POLL_INTERVAL,
+ ARRAY_SIZE(wdr3500_gpio_keys),
+ wdr3500_gpio_keys);
+
+ ath79_init_mac(tmpmac, mac, 0);
+ ath79_register_wmac(art + WDR3500_WMAC_CALDATA_OFFSET, tmpmac);
+
+ ath79_init_mac(tmpmac, mac, 1);
+ ap9x_pci_setup_wmac_led_pin(0, 0);
+ ap91_pci_init(art + WDR3500_PCIE_CALDATA_OFFSET, tmpmac);
+
+ ath79_setup_ar934x_eth_cfg(AR934X_ETH_CFG_SW_ONLY_MODE);
+
+ ath79_register_mdio(1, 0x0);
+
+ /* LAN */
+ ath79_init_mac(ath79_eth1_data.mac_addr, mac, -1);
+
+ /* GMAC1 is connected to the internal switch */
+ ath79_eth1_data.phy_if_mode = PHY_INTERFACE_MODE_GMII;
+
+ ath79_register_eth(1);
+
+ /* WAN */
+ ath79_init_mac(ath79_eth0_data.mac_addr, mac, 2);
+
+ /* GMAC0 is connected to the PHY4 of the internal switch */
+ ath79_switch_data.phy4_mii_en = 1;
+ ath79_switch_data.phy_poll_mask = BIT(4);
+ ath79_eth0_data.phy_if_mode = PHY_INTERFACE_MODE_MII;
+ ath79_eth0_data.phy_mask = BIT(4);
+ ath79_eth0_data.mii_bus_dev = &ath79_mdio1_device.dev;
+
+ ath79_register_eth(0);
+
+ gpio_request_one(WDR3500_GPIO_USB1_POWER,
+ GPIOF_OUT_INIT_HIGH | GPIOF_EXPORT_DIR_FIXED,
+ "USB1 power");
+ ath79_register_usb();
+}
+
+MIPS_MACHINE(ATH79_MACH_TL_WDR3500, "TL-WDR3500",
+ "TP-LINK TL-WDR3500",
+ wdr3500_setup);
diff --git a/target/linux/ar71xx/patches-3.3/613-MIPS-ath79-add-TL-WDR3500-support.patch b/target/linux/ar71xx/patches-3.3/613-MIPS-ath79-add-TL-WDR3500-support.patch
new file mode 100644
index 0000000..0a2c3bd
--- /dev/null
+++ b/target/linux/ar71xx/patches-3.3/613-MIPS-ath79-add-TL-WDR3500-support.patch
@@ -0,0 +1,40 @@
+--- a/arch/mips/ath79/machtypes.h
++++ b/arch/mips/ath79/machtypes.h
+@@ -84,6 +84,7 @@ enum ath79_mach_type {
+ ATH79_MACH_TL_WA7510N_V1, /* TP-LINK TL-WA7510N v1*/
+ ATH79_MACH_TL_WA901ND, /* TP-LINK TL-WA901ND */
+ ATH79_MACH_TL_WA901ND_V2, /* TP-LINK TL-WA901ND v2 */
++ ATH79_MACH_TL_WDR3500, /* TP-LINK TL-WDR3500 */
+ ATH79_MACH_TL_WDR4300, /* TP-LINK TL-WDR4300 */
+ ATH79_MACH_TL_WR1041N_V2, /* TP-LINK TL-WR1041N v2 */
+ ATH79_MACH_TL_WR1043ND, /* TP-LINK TL-WR1043ND */
+--- a/arch/mips/ath79/Kconfig
++++ b/arch/mips/ath79/Kconfig
+@@ -514,6 +514,17 @@ config ATH79_MACH_TL_WA901ND_V2
+ select ATH79_DEV_M25P80
+ select ATH79_DEV_WMAC
+
++config ATH79_MACH_TL_WDR3500
++ bool "TP-LINK TL-WDR3500 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_USB
++ select ATH79_DEV_WMAC
++
+ config ATH79_MACH_TL_WDR4300
+ bool "TP-LINK TL-WDR3600/4300/4310 board support"
+ select SOC_AR934X
+--- a/arch/mips/ath79/Makefile
++++ b/arch/mips/ath79/Makefile
+@@ -81,6 +81,7 @@ obj-$(CONFIG_ATH79_MACH_TL_MR3020) += ma
+ obj-$(CONFIG_ATH79_MACH_TL_MR3X20) += mach-tl-mr3x20.o
+ obj-$(CONFIG_ATH79_MACH_TL_WA901ND) += mach-tl-wa901nd.o
+ obj-$(CONFIG_ATH79_MACH_TL_WA901ND_V2) += mach-tl-wa901nd-v2.o
++obj-$(CONFIG_ATH79_MACH_TL_WDR3500) += mach-tl-wdr3500.o
+ obj-$(CONFIG_ATH79_MACH_TL_WDR4300) += mach-tl-wdr4300.o
+ obj-$(CONFIG_ATH79_MACH_TL_WR741ND) += mach-tl-wr741nd.o
+ obj-$(CONFIG_ATH79_MACH_TL_WR741ND_V4) += mach-tl-wr741nd-v4.o

View File

@ -1,48 +0,0 @@
From: juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Fri, 1 Feb 2013 15:50:32 +0000
Subject: ar71xx: add user-space support for TL-WDR3500 board
Based on http://patchwork.openwrt.org/patch/3208/
Thanks-to: Paul Fertser <fercerpav@gmail.com>
Signed-off-by: Gui Iribarren <gui@altermundi.net>
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@35424 3c298f89-4303-0410-b956-a3cf2f4a3e73
diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh
index fe7c910..8d71352 100755
--- a/target/linux/ar71xx/base-files/lib/ar71xx.sh
+++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh
@@ -123,6 +123,9 @@ tplink_board_detect() {
"342000"*)
model="TP-Link TL-MR3420"
;;
+ "350000"*)
+ model="TP-Link TL-WDR3500"
+ ;;
"360000"*)
model="TP-Link TL-WDR3600"
;;
@@ -357,6 +360,9 @@ ar71xx_board_detect() {
*"TL-WA901ND v2")
name="tl-wa901nd-v2"
;;
+ *"TL-WDR3500")
+ name="tl-wdr3500"
+ ;;
*"TL-WDR3600/4300/4310")
name="tl-wdr4300"
;;
diff --git a/target/linux/ar71xx/base-files/lib/upgrade/platform.sh b/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
index 49b1de9..e52ad9e 100755
--- a/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
+++ b/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
@@ -155,6 +155,7 @@ platform_check_image() {
tl-wa7510n | \
tl-wa901nd | \
tl-wa901nd-v2 | \
+ tl-wdr3500 | \
tl-wdr4300 | \
tl-wr703n | \
tl-wr741nd | \

View File

@ -1,55 +0,0 @@
From: juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Fri, 1 Feb 2013 15:50:34 +0000
Subject: ar71xx: build image for the TL-WDR3500 board
Based on http://patchwork.openwrt.org/patch/3208/
Thanks-to: Paul Fertser <fercerpav@gmail.com>
Signed-off-by: Gui Iribarren <gui@altermundi.net>
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@35425 3c298f89-4303-0410-b956-a3cf2f4a3e73
Conflicts:
target/linux/ar71xx/image/Makefile
diff --git a/target/linux/ar71xx/generic/profiles/tp-link.mk b/target/linux/ar71xx/generic/profiles/tp-link.mk
index 07d7059..3d7859c 100644
--- a/target/linux/ar71xx/generic/profiles/tp-link.mk
+++ b/target/linux/ar71xx/generic/profiles/tp-link.mk
@@ -105,12 +105,12 @@ $(eval $(call Profile,TLWA901))
define Profile/TLWDR4300
- NAME:=TP-LINK TL-WDR3600/4300/4310
+ NAME:=TP-LINK TL-WDR3500/3600/4300/4310
PACKAGES:=kmod-usb-core kmod-usb2 kmod-ledtrig-usbdev
endef
define Profile/TLWDR4300/Description
- Package set optimized for the TP-LINK TL-WDR3600/4300/4310.
+ Package set optimized for the TP-LINK TL-WDR3500/3600/4300/4310.
endef
$(eval $(call Profile,TLWDR4300))
diff --git a/target/linux/ar71xx/image/Makefile b/target/linux/ar71xx/image/Makefile
index 8e82f7f..01d1e67 100644
--- a/target/linux/ar71xx/image/Makefile
+++ b/target/linux/ar71xx/image/Makefile
@@ -881,6 +881,7 @@ $(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR741NV4,tl-wr741nd-v4,TL
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR841NV8,tl-wr841n-v8,TL-WR841N-v8,ttyS0,115200,0x08410008,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR1041,tl-wr1041n-v2,TL-WR1041N-v2,ttyS0,115200,0x10410002,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR2543,tl-wr2543-v1,TL-WR2543N,ttyS0,115200,0x25430001,1,8Mlzma,-v 3.13.99))
+$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWDR3500V1,tl-wdr3500-v1,TL-WDR3500,ttyS0,115200,0x35000001,1,8Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWDR3600V1,tl-wdr3600-v1,TL-WDR4300,ttyS0,115200,0x36000001,1,8Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWDR4300V1,tl-wdr4300-v1,TL-WDR4300,ttyS0,115200,0x43000001,1,8Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWDR4310V1,tl-wdr4310-v1,TL-WDR4300,ttyS0,115200,0x43100001,1,8Mlzma))
@@ -925,7 +926,7 @@ $(eval $(call MultiProfile,TLWR740,TLWR740NV1 TLWR740NV3 TLWR740NV4))
$(eval $(call MultiProfile,TLWR741,TLWR741NV1 TLWR741NV2 TLWR741NV4))
$(eval $(call MultiProfile,TLWR841,TLWR841NV15 TLWR841NV3 TLWR841NV5 TLWR841NV7 TLWR841NV8))
$(eval $(call MultiProfile,TLWR941,TLWR941NV2 TLWR941NV3 TLWR941NV4))
-$(eval $(call MultiProfile,TLWDR4300,TLWDR3600V1 TLWDR4300V1 TLWDR4310V1))
+$(eval $(call MultiProfile,TLWDR4300,TLWDR3500V1 TLWDR3600V1 TLWDR4300V1 TLWDR4310V1))
$(eval $(call MultiProfile,UBNT,UBNTAIRROUTER UBNTRS UBNTRSPRO UBNTLSSR71 UBNTBULLETM UBNTROCKETM UBNTNANOM UBNTUNIFI UBNTUNIFIOUTDOOR))
$(eval $(call MultiProfile,WNDR3700,WNDR3700V1 WNDR3700V2 WNDR3800 WNDRMAC WNDRMACV2))
$(eval $(call MultiProfile,WP543,WP543_2M WP543_4M WP543_8M WP543_16M))

View File

@ -1,23 +0,0 @@
From: juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Sun, 24 Mar 2013 19:23:36 +0000
Subject: ar71xx: add default switch configuration for the TL-WDR3500
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@36116 3c298f89-4303-0410-b956-a3cf2f4a3e73
Conflicts:
target/linux/ar71xx/base-files/etc/uci-defaults/02_network
diff --git a/target/linux/ar71xx/base-files/etc/uci-defaults/network b/target/linux/ar71xx/base-files/etc/uci-defaults/network
index 7fa219d..a36036f 100755
--- a/target/linux/ar71xx/base-files/etc/uci-defaults/network
+++ b/target/linux/ar71xx/base-files/etc/uci-defaults/network
@@ -188,6 +188,7 @@ tew-632brp |\
tew-712br |\
tl-mr3220 |\
tl-mr3420 |\
+tl-wdr3500 |\
tl-wr741nd |\
tl-wr741nd-v4 |\
tl-wr841n-v7 |\

View File

@ -1,20 +0,0 @@
From: juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Sun, 24 Mar 2013 19:23:43 +0000
Subject: ar71xx: add diag support for the TL-WDR3500
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@36117 3c298f89-4303-0410-b956-a3cf2f4a3e73
diff --git a/target/linux/ar71xx/base-files/etc/diag.sh b/target/linux/ar71xx/base-files/etc/diag.sh
index 416322d..b206438 100755
--- a/target/linux/ar71xx/base-files/etc/diag.sh
+++ b/target/linux/ar71xx/base-files/etc/diag.sh
@@ -129,6 +129,7 @@ get_status_led() {
tl-mr3420 | \
tl-wa901nd | \
tl-wa901nd-v2 | \
+ tl-wdr3500 | \
tl-wr1041n-v2 | \
tl-wr1043nd | \
tl-wr741nd | \

View File

@ -1,53 +0,0 @@
From: juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Sun, 24 Mar 2013 19:23:45 +0000
Subject: ar71xx: remove numeric suffix of the TL-WDR3500 USB LED
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@36118 3c298f89-4303-0410-b956-a3cf2f4a3e73
diff --git a/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c
index 05fe83d..785b21f 100644
--- a/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c
+++ b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c
@@ -29,7 +29,7 @@
#include "dev-wmac.h"
#include "machtypes.h"
-#define WDR3500_GPIO_LED_USB1 11
+#define WDR3500_GPIO_LED_USB 11
#define WDR3500_GPIO_LED_WLAN2G 13
#define WDR3500_GPIO_LED_SYSTEM 14
#define WDR3500_GPIO_LED_QSS 15
@@ -37,7 +37,7 @@
#define WDR3500_GPIO_BTN_WPS 16
#define WDR3500_GPIO_BTN_RFKILL 17
-#define WDR3500_GPIO_USB1_POWER 22
+#define WDR3500_GPIO_USB_POWER 22
#define WDR3500_KEYS_POLL_INTERVAL 20 /* msecs */
#define WDR3500_KEYS_DEBOUNCE_INTERVAL (3 * WDR3500_KEYS_POLL_INTERVAL)
@@ -68,8 +68,8 @@ static struct gpio_led wdr3500_leds_gpio[] __initdata = {
.active_low = 1,
},
{
- .name = "tp-link:green:usb1",
- .gpio = WDR3500_GPIO_LED_USB1,
+ .name = "tp-link:green:usb",
+ .gpio = WDR3500_GPIO_LED_USB,
.active_low = 1,
},
{
@@ -142,9 +142,9 @@ static void __init wdr3500_setup(void)
ath79_register_eth(0);
- gpio_request_one(WDR3500_GPIO_USB1_POWER,
+ gpio_request_one(WDR3500_GPIO_USB_POWER,
GPIOF_OUT_INIT_HIGH | GPIOF_EXPORT_DIR_FIXED,
- "USB1 power");
+ "USB power");
ath79_register_usb();
}

View File

@ -1,21 +0,0 @@
From: juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Sun, 24 Mar 2013 19:23:47 +0000
Subject: ar71xx: fix USB power GPIO on the TL-WDR3500
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@36119 3c298f89-4303-0410-b956-a3cf2f4a3e73
diff --git a/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c
index 785b21f..5020ba4 100644
--- a/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c
+++ b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c
@@ -37,7 +37,7 @@
#define WDR3500_GPIO_BTN_WPS 16
#define WDR3500_GPIO_BTN_RFKILL 17
-#define WDR3500_GPIO_USB_POWER 22
+#define WDR3500_GPIO_USB_POWER 12
#define WDR3500_KEYS_POLL_INTERVAL 20 /* msecs */
#define WDR3500_KEYS_DEBOUNCE_INTERVAL (3 * WDR3500_KEYS_POLL_INTERVAL)

View File

@ -1,27 +0,0 @@
From: juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Sun, 24 Mar 2013 21:07:21 +0000
Subject: ar71xx: add default LED configuration for the WL-WRD3500
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@36120 3c298f89-4303-0410-b956-a3cf2f4a3e73
Conflicts:
target/linux/ar71xx/base-files/etc/uci-defaults/01_leds
diff --git a/target/linux/ar71xx/base-files/etc/uci-defaults/leds b/target/linux/ar71xx/base-files/etc/uci-defaults/leds
index 7be4ce9..48b8154 100755
--- a/target/linux/ar71xx/base-files/etc/uci-defaults/leds
+++ b/target/linux/ar71xx/base-files/etc/uci-defaults/leds
@@ -126,6 +126,11 @@ tl-wa901nd-v2)
ucidef_set_led_wlan "wlan" "WLAN" "tp-link:green:wlan" "phy0tpt"
;;
+tl-wdr3500)
+ ucidef_set_led_usbdev "usb" "USB" "tp-link:green:usb" "1-1"
+ ucidef_set_led_wlan "wlan2g" "WLAN2G" "tp-link:green:wlan2g" "phy0tpt"
+ ;;
+
tl-wdr4300)
ucidef_set_led_usbdev "usb1" "USB1" "tp-link:green:usb1" "1-1.1"
ucidef_set_led_usbdev "usb2" "USB2" "tp-link:green:usb2" "1-1.2"

View File

@ -1,42 +0,0 @@
From: juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Mon, 25 Mar 2013 06:40:03 +0000
Subject: ar71xx: fix ethernet LEDs on the TL-WDR3500
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@36122 3c298f89-4303-0410-b956-a3cf2f4a3e73
diff --git a/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c
index 5020ba4..452c20b 100644
--- a/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c
+++ b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wdr3500.c
@@ -33,6 +33,11 @@
#define WDR3500_GPIO_LED_WLAN2G 13
#define WDR3500_GPIO_LED_SYSTEM 14
#define WDR3500_GPIO_LED_QSS 15
+#define WDR3500_GPIO_LED_WAN 18
+#define WDR3500_GPIO_LED_LAN1 19
+#define WDR3500_GPIO_LED_LAN2 20
+#define WDR3500_GPIO_LED_LAN3 21
+#define WDR3500_GPIO_LED_LAN4 22
#define WDR3500_GPIO_BTN_WPS 16
#define WDR3500_GPIO_BTN_RFKILL 17
@@ -146,6 +151,17 @@ static void __init wdr3500_setup(void)
GPIOF_OUT_INIT_HIGH | GPIOF_EXPORT_DIR_FIXED,
"USB power");
ath79_register_usb();
+
+ ath79_gpio_output_select(WDR3500_GPIO_LED_LAN1,
+ AR934X_GPIO_OUT_LED_LINK3);
+ ath79_gpio_output_select(WDR3500_GPIO_LED_LAN2,
+ AR934X_GPIO_OUT_LED_LINK2);
+ ath79_gpio_output_select(WDR3500_GPIO_LED_LAN3,
+ AR934X_GPIO_OUT_LED_LINK1);
+ ath79_gpio_output_select(WDR3500_GPIO_LED_LAN4,
+ AR934X_GPIO_OUT_LED_LINK0);
+ ath79_gpio_output_select(WDR3500_GPIO_LED_WAN,
+ AR934X_GPIO_OUT_LED_LINK4);
}
MIPS_MACHINE(ATH79_MACH_TL_WDR3500, "TL-WDR3500",

View File

@ -1,38 +0,0 @@
From: juhosg <juhosg@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Mon, 25 Mar 2013 06:40:00 +0000
Subject: ar71xx: add GPIO output select values for AR934x
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@36121 3c298f89-4303-0410-b956-a3cf2f4a3e73
Conflicts:
target/linux/ar71xx/patches-3.8/601-MIPS-ath79-add-more-register-defines.patch
diff --git a/target/linux/ar71xx/patches-3.3/601-MIPS-ath79-add-more-register-defines.patch b/target/linux/ar71xx/patches-3.3/601-MIPS-ath79-add-more-register-defines.patch
index 8411d58..12522c1 100644
--- a/target/linux/ar71xx/patches-3.3/601-MIPS-ath79-add-more-register-defines.patch
+++ b/target/linux/ar71xx/patches-3.3/601-MIPS-ath79-add-more-register-defines.patch
@@ -166,7 +166,7 @@
#define AR934X_GPIO_REG_FUNC 0x6c
#define AR71XX_GPIO_COUNT 16
-@@ -550,4 +618,139 @@
+@@ -550,4 +618,144 @@
#define AR934X_SRIF_DPLL2_OUTDIV_SHIFT 13
#define AR934X_SRIF_DPLL2_OUTDIV_MASK 0x7
@@ -237,7 +237,12 @@
+#define AR934X_GPIO_FUNC_CLK_OBS0_EN BIT(2)
+#define AR934X_GPIO_FUNC_JTAG_DISABLE BIT(1)
+
-+#define AR934X_GPIO_OUT_GPIO 0x00
++#define AR934X_GPIO_OUT_GPIO 0
++#define AR934X_GPIO_OUT_LED_LINK0 41
++#define AR934X_GPIO_OUT_LED_LINK1 42
++#define AR934X_GPIO_OUT_LED_LINK2 43
++#define AR934X_GPIO_OUT_LED_LINK3 44
++#define AR934X_GPIO_OUT_LED_LINK4 45
+
+/*
+ * MII_CTRL block

View File

@ -1,546 +0,0 @@
From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Sat, 29 Mar 2014 21:55:41 +0100
Subject: ar71xx: add support for QCA953x SoC
diff --git a/target/linux/ar71xx/config-3.3 b/target/linux/ar71xx/config-3.3
index dfc5bf2..1c3ba3c 100644
--- a/target/linux/ar71xx/config-3.3
+++ b/target/linux/ar71xx/config-3.3
@@ -40,11 +40,11 @@ CONFIG_ATH79_MACH_EW_DORIN=y
CONFIG_ATH79_MACH_HORNET_UB=y
CONFIG_ATH79_MACH_JA76PF=y
CONFIG_ATH79_MACH_JWAP003=y
+CONFIG_ATH79_MACH_MR600=y
CONFIG_ATH79_MACH_MZK_W04NU=y
CONFIG_ATH79_MACH_MZK_W300NH=y
CONFIG_ATH79_MACH_NBG460N=y
CONFIG_ATH79_MACH_OM2P=y
-CONFIG_ATH79_MACH_MR600=y
CONFIG_ATH79_MACH_PB42=y
CONFIG_ATH79_MACH_PB44=y
CONFIG_ATH79_MACH_PB92=y
@@ -214,6 +214,7 @@ CONFIG_SOC_AR724X=y
CONFIG_SOC_AR913X=y
CONFIG_SOC_AR933X=y
CONFIG_SOC_AR934X=y
+CONFIG_SOC_QCA953X=y
CONFIG_SOC_QCA955X=y
CONFIG_SPI=y
CONFIG_SPI_AP83=y
diff --git a/target/linux/ar71xx/files/arch/mips/ath79/dev-eth.c b/target/linux/ar71xx/files/arch/mips/ath79/dev-eth.c
index 5a0b950..1a9b0df 100644
--- a/target/linux/ar71xx/files/arch/mips/ath79/dev-eth.c
+++ b/target/linux/ar71xx/files/arch/mips/ath79/dev-eth.c
@@ -195,6 +195,7 @@ void __init ath79_register_mdio(unsigned int id, u32 phy_mask)
case ATH79_SOC_AR7241:
case ATH79_SOC_AR9330:
case ATH79_SOC_AR9331:
+ case ATH79_SOC_QCA9533:
mdio_dev = &ath79_mdio1_device;
mdio_data = &ath79_mdio1_data;
break;
@@ -250,6 +251,11 @@ void __init ath79_register_mdio(unsigned int id, u32 phy_mask)
}
mdio_data->is_ar934x = 1;
break;
+
+ case ATH79_SOC_QCA9533:
+ mdio_data->builtin_switch = 1;
+ break;
+
case ATH79_SOC_QCA9558:
if (id == 1)
mdio_data->builtin_switch = 1;
@@ -540,6 +546,7 @@ static void __init ath79_init_eth_pll_data(unsigned int id)
case ATH79_SOC_AR9341:
case ATH79_SOC_AR9342:
case ATH79_SOC_AR9344:
+ case ATH79_SOC_QCA9533:
case ATH79_SOC_QCA9558:
pll_10 = AR934X_PLL_VAL_10;
pll_100 = AR934X_PLL_VAL_100;
@@ -596,6 +603,7 @@ static int __init ath79_setup_phy_if_mode(unsigned int id,
case ATH79_SOC_AR7241:
case ATH79_SOC_AR9330:
case ATH79_SOC_AR9331:
+ case ATH79_SOC_QCA9533:
pdata->phy_if_mode = PHY_INTERFACE_MODE_MII;
break;
@@ -645,6 +653,7 @@ static int __init ath79_setup_phy_if_mode(unsigned int id,
case ATH79_SOC_AR7241:
case ATH79_SOC_AR9330:
case ATH79_SOC_AR9331:
+ case ATH79_SOC_QCA9533:
pdata->phy_if_mode = PHY_INTERFACE_MODE_GMII;
break;
@@ -882,6 +891,37 @@ void __init ath79_register_eth(unsigned int id)
pdata->fifo_cfg3 = 0x01f00140;
break;
+ case ATH79_SOC_QCA9533:
+ if (id == 0) {
+ pdata->reset_bit = AR933X_RESET_GE0_MAC |
+ AR933X_RESET_GE0_MDIO;
+ pdata->set_speed = ath79_set_speed_dummy;
+
+ pdata->phy_mask = BIT(4);
+ } else {
+ pdata->reset_bit = AR933X_RESET_GE1_MAC |
+ AR933X_RESET_GE1_MDIO;
+ pdata->set_speed = ath79_set_speed_dummy;
+
+ pdata->speed = SPEED_1000;
+ pdata->duplex = DUPLEX_FULL;
+ pdata->switch_data = &ath79_switch_data;
+
+ ath79_switch_data.phy_poll_mask |= BIT(4);
+ }
+
+ pdata->ddr_flush = ath79_ddr_no_flush;
+ pdata->has_gbit = 1;
+ pdata->is_ar724x = 1;
+
+ if (!pdata->fifo_cfg1)
+ pdata->fifo_cfg1 = 0x0010ffff;
+ if (!pdata->fifo_cfg2)
+ pdata->fifo_cfg2 = 0x015500aa;
+ if (!pdata->fifo_cfg3)
+ pdata->fifo_cfg3 = 0x01f00140;
+ break;
+
case ATH79_SOC_AR9341:
case ATH79_SOC_AR9342:
case ATH79_SOC_AR9344:
@@ -953,6 +993,7 @@ void __init ath79_register_eth(unsigned int id)
case ATH79_SOC_AR7241:
case ATH79_SOC_AR9330:
case ATH79_SOC_AR9331:
+ case ATH79_SOC_QCA9533:
pdata->mii_bus_dev = &ath79_mdio1_device.dev;
break;
diff --git a/target/linux/ar71xx/patches-3.3/707-MIPS-ath79-add-support-for-QCA953x-SoC.patch b/target/linux/ar71xx/patches-3.3/707-MIPS-ath79-add-support-for-QCA953x-SoC.patch
new file mode 100644
index 0000000..4c9e761
--- /dev/null
+++ b/target/linux/ar71xx/patches-3.3/707-MIPS-ath79-add-support-for-QCA953x-SoC.patch
@@ -0,0 +1,417 @@
+From 5300a7cd7ed2f88488ddba62947b9c6bb9663777 Mon Sep 17 00:00:00 2001
+Message-Id: <5300a7cd7ed2f88488ddba62947b9c6bb9663777.1396122227.git.mschiffer@universe-factory.net>
+From: Matthias Schiffer <mschiffer@universe-factory.net>
+Date: Sat, 29 Mar 2014 20:26:08 +0100
+Subject: [PATCH 1/2] MIPS: ath79: add support for QCA953x SoC
+
+Note that the clock calculation looks very similar to the QCA955x, but actually
+some bits' meanings are slightly different.
+---
+ arch/mips/ath79/Kconfig | 6 +-
+ arch/mips/ath79/clock.c | 78 ++++++++++++++++++++++++++
+ arch/mips/ath79/common.c | 4 ++
+ arch/mips/ath79/dev-common.c | 1 +
+ arch/mips/ath79/dev-wmac.c | 20 +++++++
+ arch/mips/ath79/early_printk.c | 1 +
+ arch/mips/ath79/gpio.c | 4 +-
+ arch/mips/ath79/irq.c | 4 ++
+ arch/mips/ath79/setup.c | 8 ++-
+ arch/mips/include/asm/mach-ath79/ar71xx_regs.h | 48 ++++++++++++++++
+ arch/mips/include/asm/mach-ath79/ath79.h | 11 ++++
+ 11 files changed, 182 insertions(+), 3 deletions(-)
+
+--- a/arch/mips/ath79/Kconfig
++++ b/arch/mips/ath79/Kconfig
+@@ -688,6 +688,10 @@ config SOC_AR934X
+ select PCI_AR724X if PCI
+ def_bool n
+
++config SOC_QCA953X
++ select USB_ARCH_HAS_EHCI
++ def_bool n
++
+ config SOC_QCA955X
+ select USB_ARCH_HAS_EHCI
+ select HW_HAS_PCI
+@@ -731,7 +735,7 @@ config ATH79_DEV_USB
+ def_bool n
+
+ config ATH79_DEV_WMAC
+- depends on (SOC_AR913X || SOC_AR933X || SOC_AR934X || SOC_QCA955X)
++ depends on (SOC_AR913X || SOC_AR933X || SOC_AR934X || SOC_QCA953X || SOC_QCA955X)
+ def_bool n
+
+ config ATH79_NVRAM
+--- a/arch/mips/ath79/clock.c
++++ b/arch/mips/ath79/clock.c
+@@ -295,6 +295,82 @@ static void __init ar934x_clocks_init(vo
+ iounmap(dpll_base);
+ }
+
++static void __init qca953x_clocks_init(void)
++{
++ u32 pll, out_div, ref_div, nint, frac, clk_ctrl, postdiv;
++ u32 cpu_pll, ddr_pll;
++ u32 bootstrap;
++
++ bootstrap = ath79_reset_rr(QCA953X_RESET_REG_BOOTSTRAP);
++ if (bootstrap & QCA953X_BOOTSTRAP_REF_CLK_40)
++ ath79_ref_clk.rate = 40 * 1000 * 1000;
++ else
++ ath79_ref_clk.rate = 25 * 1000 * 1000;
++
++ pll = ath79_pll_rr(QCA953X_PLL_CPU_CONFIG_REG);
++ out_div = (pll >> QCA953X_PLL_CPU_CONFIG_OUTDIV_SHIFT) &
++ QCA953X_PLL_CPU_CONFIG_OUTDIV_MASK;
++ ref_div = (pll >> QCA953X_PLL_CPU_CONFIG_REFDIV_SHIFT) &
++ QCA953X_PLL_CPU_CONFIG_REFDIV_MASK;
++ nint = (pll >> QCA953X_PLL_CPU_CONFIG_NINT_SHIFT) &
++ QCA953X_PLL_CPU_CONFIG_NINT_MASK;
++ frac = (pll >> QCA953X_PLL_CPU_CONFIG_NFRAC_SHIFT) &
++ QCA953X_PLL_CPU_CONFIG_NFRAC_MASK;
++
++ cpu_pll = nint * ath79_ref_clk.rate / ref_div;
++ cpu_pll += frac * (ath79_ref_clk.rate >> 6) / ref_div;
++ cpu_pll /= (1 << out_div);
++
++ pll = ath79_pll_rr(QCA953X_PLL_DDR_CONFIG_REG);
++ out_div = (pll >> QCA953X_PLL_DDR_CONFIG_OUTDIV_SHIFT) &
++ QCA953X_PLL_DDR_CONFIG_OUTDIV_MASK;
++ ref_div = (pll >> QCA953X_PLL_DDR_CONFIG_REFDIV_SHIFT) &
++ QCA953X_PLL_DDR_CONFIG_REFDIV_MASK;
++ nint = (pll >> QCA953X_PLL_DDR_CONFIG_NINT_SHIFT) &
++ QCA953X_PLL_DDR_CONFIG_NINT_MASK;
++ frac = (pll >> QCA953X_PLL_DDR_CONFIG_NFRAC_SHIFT) &
++ QCA953X_PLL_DDR_CONFIG_NFRAC_MASK;
++
++ ddr_pll = nint * ath79_ref_clk.rate / ref_div;
++ ddr_pll += frac * (ath79_ref_clk.rate >> 6) / (ref_div << 4);
++ ddr_pll /= (1 << out_div);
++
++ clk_ctrl = ath79_pll_rr(QCA953X_PLL_CLK_CTRL_REG);
++
++ postdiv = (clk_ctrl >> QCA953X_PLL_CLK_CTRL_CPU_POST_DIV_SHIFT) &
++ QCA953X_PLL_CLK_CTRL_CPU_POST_DIV_MASK;
++
++ if (clk_ctrl & QCA953X_PLL_CLK_CTRL_CPU_PLL_BYPASS)
++ ath79_cpu_clk.rate = ath79_ref_clk.rate;
++ else if (clk_ctrl & QCA953X_PLL_CLK_CTRL_CPUCLK_FROM_CPUPLL)
++ ath79_cpu_clk.rate = cpu_pll / (postdiv + 1);
++ else
++ ath79_cpu_clk.rate = ddr_pll / (postdiv + 1);
++
++ postdiv = (clk_ctrl >> QCA953X_PLL_CLK_CTRL_DDR_POST_DIV_SHIFT) &
++ QCA953X_PLL_CLK_CTRL_DDR_POST_DIV_MASK;
++
++ if (clk_ctrl & QCA953X_PLL_CLK_CTRL_DDR_PLL_BYPASS)
++ ath79_ddr_clk.rate = ath79_ref_clk.rate;
++ else if (clk_ctrl & QCA953X_PLL_CLK_CTRL_DDRCLK_FROM_DDRPLL)
++ ath79_ddr_clk.rate = ddr_pll / (postdiv + 1);
++ else
++ ath79_ddr_clk.rate = cpu_pll / (postdiv + 1);
++
++ postdiv = (clk_ctrl >> QCA953X_PLL_CLK_CTRL_AHB_POST_DIV_SHIFT) &
++ QCA953X_PLL_CLK_CTRL_AHB_POST_DIV_MASK;
++
++ if (clk_ctrl & QCA953X_PLL_CLK_CTRL_AHB_PLL_BYPASS)
++ ath79_ahb_clk.rate = ath79_ref_clk.rate;
++ else if (clk_ctrl & QCA953X_PLL_CLK_CTRL_AHBCLK_FROM_DDRPLL)
++ ath79_ahb_clk.rate = ddr_pll / (postdiv + 1);
++ else
++ ath79_ahb_clk.rate = cpu_pll / (postdiv + 1);
++
++ ath79_wdt_clk.rate = ath79_ref_clk.rate;
++ ath79_uart_clk.rate = ath79_ref_clk.rate;
++}
++
+ static void __init qca955x_clocks_init(void)
+ {
+ u32 pll, out_div, ref_div, nint, frac, clk_ctrl, postdiv;
+@@ -383,6 +459,8 @@ void __init ath79_clocks_init(void)
+ ar933x_clocks_init();
+ else if (soc_is_ar934x())
+ ar934x_clocks_init();
++ else if (soc_is_qca953x())
++ qca953x_clocks_init();
+ else if (soc_is_qca955x())
+ qca955x_clocks_init();
+ else
+--- a/arch/mips/ath79/common.c
++++ b/arch/mips/ath79/common.c
+@@ -74,6 +74,8 @@ void ath79_device_reset_set(u32 mask)
+ else if (soc_is_ar934x() ||
+ soc_is_qca955x())
+ reg = AR934X_RESET_REG_RESET_MODULE;
++ else if (soc_is_qca953x())
++ reg = QCA953X_RESET_REG_RESET_MODULE;
+ else
+ BUG();
+
+@@ -101,6 +103,8 @@ void ath79_device_reset_clear(u32 mask)
+ else if (soc_is_ar934x() ||
+ soc_is_qca955x())
+ reg = AR934X_RESET_REG_RESET_MODULE;
++ else if (soc_is_qca953x())
++ reg = QCA953X_RESET_REG_RESET_MODULE;
+ else
+ BUG();
+
+--- a/arch/mips/ath79/dev-common.c
++++ b/arch/mips/ath79/dev-common.c
+@@ -100,6 +100,7 @@ void __init ath79_register_uart(void)
+ soc_is_ar724x() ||
+ soc_is_ar913x() ||
+ soc_is_ar934x() ||
++ soc_is_qca953x() ||
+ soc_is_qca955x()) {
+ ath79_uart_data[0].uartclk = clk_get_rate(clk);
+ platform_device_register(&ath79_uart_device);
+--- a/arch/mips/ath79/dev-wmac.c
++++ b/arch/mips/ath79/dev-wmac.c
+@@ -99,7 +99,7 @@ static int ar933x_wmac_reset(void)
+ return -ETIMEDOUT;
+ }
+
+-static int ar933x_r1_get_wmac_revision(void)
++static int ar93xx_get_soc_revision(void)
+ {
+ return ath79_soc_rev;
+ }
+@@ -124,7 +124,7 @@ static void __init ar933x_wmac_setup(voi
+ ath79_wmac_data.is_clk_25mhz = true;
+
+ if (ath79_soc_rev == 1)
+- ath79_wmac_data.get_mac_revision = ar933x_r1_get_wmac_revision;
++ ath79_wmac_data.get_mac_revision = ar93xx_get_soc_revision;
+
+ ath79_wmac_data.external_reset = ar933x_wmac_reset;
+ }
+@@ -147,6 +147,26 @@ static void ar934x_wmac_setup(void)
+ ath79_wmac_data.is_clk_25mhz = true;
+ }
+
++static void qca953x_wmac_setup(void)
++{
++ u32 t;
++
++ ath79_wmac_device.name = "qca953x_wmac";
++
++ ath79_wmac_resources[0].start = QCA953X_WMAC_BASE;
++ ath79_wmac_resources[0].end = QCA953X_WMAC_BASE + QCA953X_WMAC_SIZE - 1;
++ ath79_wmac_resources[1].start = ATH79_CPU_IRQ_IP2;
++ ath79_wmac_resources[1].end = ATH79_CPU_IRQ_IP2;
++
++ t = ath79_reset_rr(QCA953X_RESET_REG_BOOTSTRAP);
++ if (t & QCA953X_BOOTSTRAP_REF_CLK_40)
++ ath79_wmac_data.is_clk_25mhz = false;
++ else
++ ath79_wmac_data.is_clk_25mhz = true;
++
++ ath79_wmac_data.get_mac_revision = ar93xx_get_soc_revision;
++}
++
+ static void qca955x_wmac_setup(void)
+ {
+ u32 t;
+@@ -314,6 +334,8 @@ void __init ath79_register_wmac(u8 *cal_
+ ar933x_wmac_setup();
+ else if (soc_is_ar934x())
+ ar934x_wmac_setup();
++ else if (soc_is_qca953x())
++ qca953x_wmac_setup();
+ else if (soc_is_qca955x())
+ qca955x_wmac_setup();
+ else
+--- a/arch/mips/ath79/early_printk.c
++++ b/arch/mips/ath79/early_printk.c
+@@ -114,6 +114,7 @@ static void prom_putchar_init(void)
+ case REV_ID_MAJOR_AR9341:
+ case REV_ID_MAJOR_AR9342:
+ case REV_ID_MAJOR_AR9344:
++ case REV_ID_MAJOR_QCA9533:
+ case REV_ID_MAJOR_QCA9558:
+ _prom_putchar = prom_putchar_ar71xx;
+ break;
+--- a/arch/mips/ath79/gpio.c
++++ b/arch/mips/ath79/gpio.c
+@@ -240,6 +240,8 @@ void __init ath79_gpio_init(void)
+ ath79_gpio_count = AR933X_GPIO_COUNT;
+ else if (soc_is_ar934x())
+ ath79_gpio_count = AR934X_GPIO_COUNT;
++ else if (soc_is_qca953x())
++ ath79_gpio_count = QCA953X_GPIO_COUNT;
+ else if (soc_is_qca955x())
+ ath79_gpio_count = QCA955X_GPIO_COUNT;
+ else
+@@ -247,7 +249,7 @@ void __init ath79_gpio_init(void)
+
+ ath79_gpio_base = ioremap_nocache(AR71XX_GPIO_BASE, AR71XX_GPIO_SIZE);
+ ath79_gpio_chip.ngpio = ath79_gpio_count;
+- if (soc_is_ar934x() || soc_is_qca955x()) {
++ if (soc_is_ar934x() || soc_is_qca953x() || soc_is_qca955x()) {
+ ath79_gpio_chip.direction_input = ar934x_gpio_direction_input;
+ ath79_gpio_chip.direction_output = ar934x_gpio_direction_output;
+ }
+--- a/arch/mips/ath79/irq.c
++++ b/arch/mips/ath79/irq.c
+@@ -106,6 +106,7 @@ static void __init ath79_misc_irq_init(v
+ else if (soc_is_ar724x() ||
+ soc_is_ar933x() ||
+ soc_is_ar934x() ||
++ soc_is_qca953x() ||
+ soc_is_qca955x())
+ ath79_misc_irq_chip.irq_ack = ar724x_misc_irq_ack;
+ else
+@@ -352,6 +353,9 @@ void __init arch_init_irq(void)
+ } else if (soc_is_ar934x()) {
+ ath79_ip2_handler = ath79_default_ip2_handler;
+ ath79_ip3_handler = ar934x_ip3_handler;
++ } else if (soc_is_qca953x()) {
++ ath79_ip2_handler = ath79_default_ip2_handler;
++ ath79_ip3_handler = ath79_default_ip3_handler;
+ } else if (soc_is_qca955x()) {
+ ath79_ip2_handler = ath79_default_ip2_handler;
+ ath79_ip3_handler = ath79_default_ip3_handler;
+--- a/arch/mips/ath79/setup.c
++++ b/arch/mips/ath79/setup.c
+@@ -164,6 +164,12 @@ static void __init ath79_detect_sys_type
+ rev = id & AR934X_REV_ID_REVISION_MASK;
+ break;
+
++ case REV_ID_MAJOR_QCA9533:
++ ath79_soc = ATH79_SOC_QCA9533;
++ chip = "9533";
++ rev = id & AR944X_REV_ID_REVISION_MASK;
++ break;
++
+ case REV_ID_MAJOR_QCA9558:
+ ath79_soc = ATH79_SOC_QCA9558;
+ chip = "9558";
+@@ -176,7 +182,7 @@ static void __init ath79_detect_sys_type
+
+ ath79_soc_rev = rev;
+
+- if (soc_is_qca955x())
++ if (soc_is_qca953x() || soc_is_qca955x())
+ sprintf(ath79_sys_type, "Qualcomm Atheros QCA%s rev %u",
+ chip, rev);
+ else
+--- a/arch/mips/include/asm/mach-ath79/ar71xx_regs.h
++++ b/arch/mips/include/asm/mach-ath79/ar71xx_regs.h
+@@ -106,6 +106,9 @@
+ #define AR934X_NFC_BASE 0x1b000200
+ #define AR934X_NFC_SIZE 0xb8
+
++#define QCA953X_WMAC_BASE (AR71XX_APB_BASE + 0x00100000)
++#define QCA953X_WMAC_SIZE 0x20000
++
+ #define QCA955X_PCI_MEM_BASE0 0x10000000
+ #define QCA955X_PCI_MEM_BASE1 0x12000000
+ #define QCA955X_PCI_MEM_SIZE 0x02000000
+@@ -280,6 +283,43 @@
+
+ #define AR934X_PLL_SWITCH_CLOCK_CONTROL_MDIO_CLK_SEL BIT(6)
+
++#define QCA953X_PLL_CPU_CONFIG_REG 0x00
++#define QCA953X_PLL_DDR_CONFIG_REG 0x04
++#define QCA953X_PLL_CLK_CTRL_REG 0x08
++#define QCA953X_PLL_ETH_XMII_CONTROL_REG 0x2c
++#define QCA953X_PLL_ETH_SGMII_CONTROL_REG 0x48
++
++#define QCA953X_PLL_CPU_CONFIG_NFRAC_SHIFT 0
++#define QCA953X_PLL_CPU_CONFIG_NFRAC_MASK 0x3f
++#define QCA953X_PLL_CPU_CONFIG_NINT_SHIFT 6
++#define QCA953X_PLL_CPU_CONFIG_NINT_MASK 0x3f
++#define QCA953X_PLL_CPU_CONFIG_REFDIV_SHIFT 12
++#define QCA953X_PLL_CPU_CONFIG_REFDIV_MASK 0x1f
++#define QCA953X_PLL_CPU_CONFIG_OUTDIV_SHIFT 19
++#define QCA953X_PLL_CPU_CONFIG_OUTDIV_MASK 0x3
++
++#define QCA953X_PLL_DDR_CONFIG_NFRAC_SHIFT 0
++#define QCA953X_PLL_DDR_CONFIG_NFRAC_MASK 0x3ff
++#define QCA953X_PLL_DDR_CONFIG_NINT_SHIFT 10
++#define QCA953X_PLL_DDR_CONFIG_NINT_MASK 0x3f
++#define QCA953X_PLL_DDR_CONFIG_REFDIV_SHIFT 16
++#define QCA953X_PLL_DDR_CONFIG_REFDIV_MASK 0x1f
++#define QCA953X_PLL_DDR_CONFIG_OUTDIV_SHIFT 23
++#define QCA953X_PLL_DDR_CONFIG_OUTDIV_MASK 0x7
++
++#define QCA953X_PLL_CLK_CTRL_CPU_PLL_BYPASS BIT(2)
++#define QCA953X_PLL_CLK_CTRL_DDR_PLL_BYPASS BIT(3)
++#define QCA953X_PLL_CLK_CTRL_AHB_PLL_BYPASS BIT(4)
++#define QCA953X_PLL_CLK_CTRL_CPU_POST_DIV_SHIFT 5
++#define QCA953X_PLL_CLK_CTRL_CPU_POST_DIV_MASK 0x1f
++#define QCA953X_PLL_CLK_CTRL_DDR_POST_DIV_SHIFT 10
++#define QCA953X_PLL_CLK_CTRL_DDR_POST_DIV_MASK 0x1f
++#define QCA953X_PLL_CLK_CTRL_AHB_POST_DIV_SHIFT 15
++#define QCA953X_PLL_CLK_CTRL_AHB_POST_DIV_MASK 0x1f
++#define QCA953X_PLL_CLK_CTRL_CPUCLK_FROM_CPUPLL BIT(20)
++#define QCA953X_PLL_CLK_CTRL_DDRCLK_FROM_DDRPLL BIT(21)
++#define QCA953X_PLL_CLK_CTRL_AHBCLK_FROM_DDRPLL BIT(24)
++
+ #define QCA955X_PLL_CPU_CONFIG_REG 0x00
+ #define QCA955X_PLL_DDR_CONFIG_REG 0x04
+ #define QCA955X_PLL_CLK_CTRL_REG 0x08
+@@ -354,6 +394,10 @@
+ #define AR934X_RESET_REG_BOOTSTRAP 0xb0
+ #define AR934X_RESET_REG_PCIE_WMAC_INT_STATUS 0xac
+
++#define QCA953X_RESET_REG_RESET_MODULE 0x1c
++#define QCA953X_RESET_REG_BOOTSTRAP 0xb0
++#define QCA953X_RESET_REG_EXT_INT_STATUS 0xac
++
+ #define QCA955X_RESET_REG_BOOTSTRAP 0xb0
+ #define QCA955X_RESET_REG_EXT_INT_STATUS 0xac
+
+@@ -468,6 +512,8 @@
+ #define AR934X_BOOTSTRAP_SDRAM_DISABLED BIT(1)
+ #define AR934X_BOOTSTRAP_DDR1 BIT(0)
+
++#define QCA953X_BOOTSTRAP_REF_CLK_40 BIT(4)
++
+ #define QCA955X_BOOTSTRAP_REF_CLK_40 BIT(4)
+
+ #define AR934X_PCIE_WMAC_INT_WMAC_MISC BIT(0)
+@@ -530,6 +576,7 @@
+ #define REV_ID_MAJOR_AR9341 0x0120
+ #define REV_ID_MAJOR_AR9342 0x1120
+ #define REV_ID_MAJOR_AR9344 0x2120
++#define REV_ID_MAJOR_QCA9533 0x0140
+ #define REV_ID_MAJOR_QCA9558 0x1130
+
+ #define AR71XX_REV_ID_MINOR_MASK 0x3
+@@ -603,6 +650,7 @@
+ #define AR913X_GPIO_COUNT 22
+ #define AR933X_GPIO_COUNT 30
+ #define AR934X_GPIO_COUNT 23
++#define QCA953X_GPIO_COUNT 24 /* (?) */
+ #define QCA955X_GPIO_COUNT 24
+
+ /*
+--- a/arch/mips/include/asm/mach-ath79/ath79.h
++++ b/arch/mips/include/asm/mach-ath79/ath79.h
+@@ -32,6 +32,7 @@ enum ath79_soc_type {
+ ATH79_SOC_AR9341,
+ ATH79_SOC_AR9342,
+ ATH79_SOC_AR9344,
++ ATH79_SOC_QCA9533,
+ ATH79_SOC_QCA9558,
+ };
+
+@@ -99,6 +100,16 @@ static inline int soc_is_ar934x(void)
+ return soc_is_ar9341() || soc_is_ar9342() || soc_is_ar9344();
+ }
+
++static inline int soc_is_qca9533(void)
++{
++ return ath79_soc == ATH79_SOC_QCA9533;
++}
++
++static inline int soc_is_qca953x(void)
++{
++ return soc_is_qca9533();
++}
++
+ static inline int soc_is_qca9558(void)
+ {
+ return ath79_soc == ATH79_SOC_QCA9558;

View File

@ -1,297 +0,0 @@
From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Sat, 29 Mar 2014 21:12:15 +0100
Subject: ar71xx: add support for the TP-LINK TL-WR841N/ND v9
diff --git a/target/linux/ar71xx/base-files/etc/diag.sh b/target/linux/ar71xx/base-files/etc/diag.sh
index b206438..0bf2dd1 100755
--- a/target/linux/ar71xx/base-files/etc/diag.sh
+++ b/target/linux/ar71xx/base-files/etc/diag.sh
@@ -144,6 +144,9 @@ get_status_led() {
tl-wr703n)
status_led="tp-link:blue:system"
;;
+ tl-wr841n-v9)
+ status_led="tp-link:green:qss"
+ ;;
tl-wr2543n)
status_led="tp-link:green:wps"
;;
diff --git a/target/linux/ar71xx/base-files/etc/uci-defaults/leds b/target/linux/ar71xx/base-files/etc/uci-defaults/leds
index 48b8154..43bc24d 100755
--- a/target/linux/ar71xx/base-files/etc/uci-defaults/leds
+++ b/target/linux/ar71xx/base-files/etc/uci-defaults/leds
@@ -163,6 +163,15 @@ tl-wr841n-v8)
ucidef_set_led_wlan "wlan" "WLAN" "tp-link:green:wlan" "phy0tpt"
;;
+tl-wr841n-v9)
+ ucidef_set_led_netdev "wan" "WAN" "tp-link:green:wan" "eth1"
+ ucidef_set_led_switch "lan1" "LAN1" "tp-link:green:lan1" "switch0" "0x10"
+ ucidef_set_led_switch "lan2" "LAN2" "tp-link:green:lan2" "switch0" "0x08"
+ ucidef_set_led_switch "lan3" "LAN3" "tp-link:green:lan3" "switch0" "0x04"
+ ucidef_set_led_switch "lan4" "LAN4" "tp-link:green:lan4" "switch0" "0x02"
+ ucidef_set_led_wlan "wlan" "WLAN" "tp-link:green:wlan" "phy0tpt"
+ ;;
+
tl-wr941nd | \
tl-wr1041n-v2)
ucidef_set_led_wlan "wlan" "WLAN" "tp-link:green:wlan" "phy0tpt"
diff --git a/target/linux/ar71xx/base-files/etc/uci-defaults/network b/target/linux/ar71xx/base-files/etc/uci-defaults/network
index a36036f..a1dfda0 100755
--- a/target/linux/ar71xx/base-files/etc/uci-defaults/network
+++ b/target/linux/ar71xx/base-files/etc/uci-defaults/network
@@ -192,6 +192,7 @@ tl-wdr3500 |\
tl-wr741nd |\
tl-wr741nd-v4 |\
tl-wr841n-v7 |\
+tl-wr841n-v9 |\
whr-g301n |\
whr-hp-g300n |\
whr-hp-gn |\
diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh
index 8d71352..ca174da 100755
--- a/target/linux/ar71xx/base-files/lib/ar71xx.sh
+++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh
@@ -381,6 +381,9 @@ ar71xx_board_detect() {
*"TL-WR841N/ND v8")
name="tl-wr841n-v8"
;;
+ *"TL-WR841N/ND v9")
+ name="tl-wr841n-v9"
+ ;;
*TL-WR941ND)
name="tl-wr941nd"
;;
diff --git a/target/linux/ar71xx/base-files/lib/upgrade/platform.sh b/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
index e52ad9e..7168b4e 100755
--- a/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
+++ b/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
@@ -163,6 +163,7 @@ platform_check_image() {
tl-wr841n-v1 | \
tl-wr841n-v7 | \
tl-wr841n-v8 | \
+ tl-wr841n-v9 | \
tl-wr941nd | \
tl-wr1041n-v2 | \
tl-wr1043nd | \
diff --git a/target/linux/ar71xx/config-3.3 b/target/linux/ar71xx/config-3.3
index 1c3ba3c..82d4d21 100644
--- a/target/linux/ar71xx/config-3.3
+++ b/target/linux/ar71xx/config-3.3
@@ -70,6 +70,7 @@ CONFIG_ATH79_MACH_TL_WR741ND=y
CONFIG_ATH79_MACH_TL_WR741ND_V4=y
CONFIG_ATH79_MACH_TL_WR841N_V1=y
CONFIG_ATH79_MACH_TL_WR841N_V8=y
+CONFIG_ATH79_MACH_TL_WR841N_V9=y
CONFIG_ATH79_MACH_TL_WR941ND=y
CONFIG_ATH79_MACH_UBNT=y
CONFIG_ATH79_MACH_UBNT_XM=y
diff --git a/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr841n-v9.c b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr841n-v9.c
new file mode 100644
index 0000000..c28afc6
--- /dev/null
+++ b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr841n-v9.c
@@ -0,0 +1,138 @@
+/*
+ * TP-LINK TL-WR841N/ND v9
+ *
+ * Copyright (C) 2014 Matthias Schiffer <mschiffer@universe-factory.net>
+ *
+ * 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 <linux/gpio.h>
+#include <linux/platform_device.h>
+
+#include <asm/mach-ath79/ath79.h>
+#include <asm/mach-ath79/ar71xx_regs.h>
+
+#include "common.h"
+#include "dev-eth.h"
+#include "dev-gpio-buttons.h"
+#include "dev-leds-gpio.h"
+#include "dev-m25p80.h"
+#include "dev-wmac.h"
+#include "machtypes.h"
+
+#define TL_WR841NV9_GPIO_LED_WLAN 13
+#define TL_WR841NV9_GPIO_LED_QSS 3
+#define TL_WR841NV9_GPIO_LED_WAN 4
+#define TL_WR841NV9_GPIO_LED_LAN1 16
+#define TL_WR841NV9_GPIO_LED_LAN2 15
+#define TL_WR841NV9_GPIO_LED_LAN3 14
+#define TL_WR841NV9_GPIO_LED_LAN4 11
+
+#define TL_WR841NV9_GPIO_BTN_RESET 12
+#define TL_WR841NV9_GPIO_BTN_WIFI 17
+
+#define TL_WR841NV9_KEYS_POLL_INTERVAL 20 /* msecs */
+#define TL_WR841NV9_KEYS_DEBOUNCE_INTERVAL (3 * TL_WR841NV9_KEYS_POLL_INTERVAL)
+
+static const char *tl_wr841n_v9_part_probes[] = {
+ "tp-link",
+ NULL,
+};
+
+static struct flash_platform_data tl_wr841n_v9_flash_data = {
+ .part_probes = tl_wr841n_v9_part_probes,
+};
+
+static struct gpio_led tl_wr841n_v9_leds_gpio[] __initdata = {
+ {
+ .name = "tp-link:green:lan1",
+ .gpio = TL_WR841NV9_GPIO_LED_LAN1,
+ .active_low = 1,
+ }, {
+ .name = "tp-link:green:lan2",
+ .gpio = TL_WR841NV9_GPIO_LED_LAN2,
+ .active_low = 1,
+ }, {
+ .name = "tp-link:green:lan3",
+ .gpio = TL_WR841NV9_GPIO_LED_LAN3,
+ .active_low = 1,
+ }, {
+ .name = "tp-link:green:lan4",
+ .gpio = TL_WR841NV9_GPIO_LED_LAN4,
+ .active_low = 1,
+ }, {
+ .name = "tp-link:green:qss",
+ .gpio = TL_WR841NV9_GPIO_LED_QSS,
+ .active_low = 1,
+ }, {
+ .name = "tp-link:green:wan",
+ .gpio = TL_WR841NV9_GPIO_LED_WAN,
+ .active_low = 1,
+ }, {
+ .name = "tp-link:green:wlan",
+ .gpio = TL_WR841NV9_GPIO_LED_WLAN,
+ .active_low = 1,
+ },
+};
+
+static struct gpio_keys_button tl_wr841n_v9_gpio_keys[] __initdata = {
+ {
+ .desc = "Reset button",
+ .type = EV_KEY,
+ .code = KEY_RESTART,
+ .debounce_interval = TL_WR841NV9_KEYS_DEBOUNCE_INTERVAL,
+ .gpio = TL_WR841NV9_GPIO_BTN_RESET,
+ .active_low = 1,
+ }, {
+ .desc = "WIFI button",
+ .type = EV_KEY,
+ .code = KEY_RFKILL,
+ .debounce_interval = TL_WR841NV9_KEYS_DEBOUNCE_INTERVAL,
+ .gpio = TL_WR841NV9_GPIO_BTN_WIFI,
+ .active_low = 1,
+ }
+};
+
+
+static void __init tl_ap143_setup(void)
+{
+ u8 *mac = (u8 *) KSEG1ADDR(0x1f01fc00);
+ u8 *ee = (u8 *) KSEG1ADDR(0x1fff1000);
+ u8 tmpmac[ETH_ALEN];
+
+ ath79_register_m25p80(&tl_wr841n_v9_flash_data);
+
+ ath79_setup_ar933x_phy4_switch(false, false);
+
+ ath79_register_mdio(0, 0x0);
+
+ /* LAN */
+ ath79_init_mac(ath79_eth1_data.mac_addr, mac, 0);
+ ath79_register_eth(1);
+
+ /* WAN */
+ ath79_switch_data.phy4_mii_en = 1;
+ ath79_eth0_data.phy_if_mode = PHY_INTERFACE_MODE_MII;
+ ath79_init_mac(ath79_eth0_data.mac_addr, mac, 1);
+ ath79_register_eth(0);
+
+ ath79_init_mac(tmpmac, mac, 0);
+ ath79_register_wmac(ee, tmpmac);
+}
+
+static void __init tl_wr841n_v9_setup(void)
+{
+ tl_ap143_setup();
+
+ ath79_register_leds_gpio(-1, ARRAY_SIZE(tl_wr841n_v9_leds_gpio),
+ tl_wr841n_v9_leds_gpio);
+
+ ath79_register_gpio_keys_polled(1, TL_WR841NV9_KEYS_POLL_INTERVAL,
+ ARRAY_SIZE(tl_wr841n_v9_gpio_keys),
+ tl_wr841n_v9_gpio_keys);
+}
+
+MIPS_MACHINE(ATH79_MACH_TL_WR841N_V9, "TL-WR841N-v9", "TP-LINK TL-WR841N/ND v9",
+ tl_wr841n_v9_setup);
diff --git a/target/linux/ar71xx/image/Makefile b/target/linux/ar71xx/image/Makefile
index 01d1e67..c270f73 100644
--- a/target/linux/ar71xx/image/Makefile
+++ b/target/linux/ar71xx/image/Makefile
@@ -879,6 +879,7 @@ $(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR703,tl-wr703n-v1,TL-WR7
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR740NV4,tl-wr740n-v4,TL-WR741ND-v4,ttyATH0,115200,0x07400004,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR741NV4,tl-wr741nd-v4,TL-WR741ND-v4,ttyATH0,115200,0x07410004,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR841NV8,tl-wr841n-v8,TL-WR841N-v8,ttyS0,115200,0x08410008,1,4Mlzma))
+$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR841NV9,tl-wr841n-v9,TL-WR841N-v9,ttyS0,115200,0x08410009,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR1041,tl-wr1041n-v2,TL-WR1041N-v2,ttyS0,115200,0x10410002,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR2543,tl-wr2543-v1,TL-WR2543N,ttyS0,115200,0x25430001,1,8Mlzma,-v 3.13.99))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWDR3500V1,tl-wdr3500-v1,TL-WDR3500,ttyS0,115200,0x35000001,1,8Mlzma))
@@ -924,7 +925,7 @@ $(eval $(call MultiProfile,TLWA901,TLWA901NV1 TLWA901NV2))
$(eval $(call MultiProfile,TLWA7510,TLWA7510NV1))
$(eval $(call MultiProfile,TLWR740,TLWR740NV1 TLWR740NV3 TLWR740NV4))
$(eval $(call MultiProfile,TLWR741,TLWR741NV1 TLWR741NV2 TLWR741NV4))
-$(eval $(call MultiProfile,TLWR841,TLWR841NV15 TLWR841NV3 TLWR841NV5 TLWR841NV7 TLWR841NV8))
+$(eval $(call MultiProfile,TLWR841,TLWR841NV15 TLWR841NV3 TLWR841NV5 TLWR841NV7 TLWR841NV8 TLWR841NV9))
$(eval $(call MultiProfile,TLWR941,TLWR941NV2 TLWR941NV3 TLWR941NV4))
$(eval $(call MultiProfile,TLWDR4300,TLWDR3500V1 TLWDR3600V1 TLWDR4300V1 TLWDR4310V1))
$(eval $(call MultiProfile,UBNT,UBNTAIRROUTER UBNTRS UBNTRSPRO UBNTLSSR71 UBNTBULLETM UBNTROCKETM UBNTNANOM UBNTUNIFI UBNTUNIFIOUTDOOR))
diff --git a/target/linux/ar71xx/patches-3.3/708-MIPS-ath79-TL-WR841v9-support.patch b/target/linux/ar71xx/patches-3.3/708-MIPS-ath79-TL-WR841v9-support.patch
new file mode 100644
index 0000000..37425a6
--- /dev/null
+++ b/target/linux/ar71xx/patches-3.3/708-MIPS-ath79-TL-WR841v9-support.patch
@@ -0,0 +1,38 @@
+--- a/arch/mips/ath79/Kconfig
++++ b/arch/mips/ath79/Kconfig
+@@ -547,6 +547,15 @@ config ATH79_MACH_TL_WR841N_V8
+ select ATH79_DEV_M25P80
+ select ATH79_DEV_WMAC
+
++config ATH79_MACH_TL_WR841N_V9
++ bool "TP-LINK TL-WR841N/ND v9 support"
++ select SOC_QCA953X
++ 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_TL_WR941ND
+ bool "TP-LINK TL-WR941ND support"
+ select SOC_AR913X
+--- a/arch/mips/ath79/Makefile
++++ b/arch/mips/ath79/Makefile
+@@ -85,6 +85,7 @@ obj-$(CONFIG_ATH79_MACH_TL_WR741ND) += m
+ obj-$(CONFIG_ATH79_MACH_TL_WR741ND_V4) += mach-tl-wr741nd-v4.o
+ obj-$(CONFIG_ATH79_MACH_TL_WR841N_V1) += mach-tl-wr841n.o
+ obj-$(CONFIG_ATH79_MACH_TL_WR841N_V8) += mach-tl-wr841n-v8.o
++obj-$(CONFIG_ATH79_MACH_TL_WR841N_V9) += mach-tl-wr841n-v9.o
+ obj-$(CONFIG_ATH79_MACH_TL_WR941ND) += mach-tl-wr941nd.o
+ obj-$(CONFIG_ATH79_MACH_TL_WR1041N_V2) += mach-tl-wr1041n-v2.o
+ obj-$(CONFIG_ATH79_MACH_TL_WR1043ND) += mach-tl-wr1043nd.o
+--- a/arch/mips/ath79/machtypes.h
++++ b/arch/mips/ath79/machtypes.h
+@@ -90,6 +90,7 @@ enum ath79_mach_type {
+ ATH79_MACH_TL_WR841N_V1, /* TP-LINK TL-WR841N v1 */
+ ATH79_MACH_TL_WR841N_V7, /* TP-LINK TL-WR841N/ND v7 */
+ ATH79_MACH_TL_WR841N_V8, /* TP-LINK TL-WR841N/ND v8 */
++ ATH79_MACH_TL_WR841N_V9, /* TP-LINK TL-WR841N/ND v9 */
+ ATH79_MACH_TL_WR941ND, /* TP-LINK TL-WR941ND */
+ ATH79_MACH_UBNT_AIRROUTER, /* Ubiquiti AirRouter */
+ ATH79_MACH_UBNT_BULLET_M, /* Ubiquiti Bullet M */

View File

@ -1,427 +0,0 @@
From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Thu, 1 May 2014 02:26:02 +0200
Subject: Backport support for TL-WR842N v2 and TL-MR3420 v2
diff --git a/target/linux/ar71xx/base-files/etc/diag.sh b/target/linux/ar71xx/base-files/etc/diag.sh
index 0bf2dd1..0d01119 100755
--- a/target/linux/ar71xx/base-files/etc/diag.sh
+++ b/target/linux/ar71xx/base-files/etc/diag.sh
@@ -127,6 +127,7 @@ get_status_led() {
;;
tl-mr3220 | \
tl-mr3420 | \
+ tl-mr3420-v2 | \
tl-wa901nd | \
tl-wa901nd-v2 | \
tl-wdr3500 | \
@@ -137,6 +138,7 @@ get_status_led() {
tl-wr841n-v1 | \
tl-wr841n-v7 | \
tl-wr841n-v8 | \
+ tl-wr842n-v2 | \
tl-wr941nd)
status_led="tp-link:green:system"
;;
diff --git a/target/linux/ar71xx/base-files/etc/uci-defaults/leds b/target/linux/ar71xx/base-files/etc/uci-defaults/leds
index 43bc24d..f1ac9ec 100755
--- a/target/linux/ar71xx/base-files/etc/uci-defaults/leds
+++ b/target/linux/ar71xx/base-files/etc/uci-defaults/leds
@@ -118,6 +118,16 @@ tl-mr3420 )
ucidef_set_led_usbdev "usb" "USB" "tp-link:green:3g" "1-1"
;;
+tl-mr3420-v2)
+ ucidef_set_led_netdev "wan" "WAN" "tp-link:green:wan" "eth0"
+ ucidef_set_led_switch "lan1" "LAN1" "tp-link:green:lan1" "switch0" "0x04"
+ ucidef_set_led_switch "lan2" "LAN2" "tp-link:green:lan2" "switch0" "0x08"
+ ucidef_set_led_switch "lan3" "LAN3" "tp-link:green:lan3" "switch0" "0x10"
+ ucidef_set_led_switch "lan4" "LAN4" "tp-link:green:lan4" "switch0" "0x02"
+ ucidef_set_led_wlan "wlan" "WLAN" "tp-link:green:wlan" "phy0tpt"
+ ucidef_set_led_usbdev "usb" "USB" "tp-link:green:3g" "1-1"
+ ;;
+
tl-wa901nd)
ucidef_set_led_netdev "lan" "LAN" "tp-link:green:lan" "eth0"
;;
@@ -172,6 +182,16 @@ tl-wr841n-v9)
ucidef_set_led_wlan "wlan" "WLAN" "tp-link:green:wlan" "phy0tpt"
;;
+tl-wr842n-v2)
+ ucidef_set_led_netdev "wan" "WAN" "tp-link:green:wan" "eth0"
+ ucidef_set_led_switch "lan1" "LAN1" "tp-link:green:lan1" "switch0" "0x04"
+ ucidef_set_led_switch "lan2" "LAN2" "tp-link:green:lan2" "switch0" "0x08"
+ ucidef_set_led_switch "lan3" "LAN3" "tp-link:green:lan3" "switch0" "0x10"
+ ucidef_set_led_switch "lan4" "LAN4" "tp-link:green:lan4" "switch0" "0x02"
+ ucidef_set_led_wlan "wlan" "WLAN" "tp-link:green:wlan" "phy0tpt"
+ ucidef_set_led_usbdev "usb" "USB" "tp-link:green:3g" "1-1"
+ ;;
+
tl-wr941nd | \
tl-wr1041n-v2)
ucidef_set_led_wlan "wlan" "WLAN" "tp-link:green:wlan" "phy0tpt"
diff --git a/target/linux/ar71xx/base-files/etc/uci-defaults/network b/target/linux/ar71xx/base-files/etc/uci-defaults/network
index a1dfda0..e38a9b8 100755
--- a/target/linux/ar71xx/base-files/etc/uci-defaults/network
+++ b/target/linux/ar71xx/base-files/etc/uci-defaults/network
@@ -128,7 +128,9 @@ tl-wr941nd)
ucidef_set_interfaces_lan_wan "lan1 lan2 lan3 lan4" "wan"
;;
-tl-wr841n-v8)
+tl-mr3420-v2 |\
+tl-wr841n-v8 |\
+tl-wr842n-v2)
ucidef_set_interfaces_lan_wan "eth1" "eth0"
ucidef_add_switch "switch0" "1" "1"
ucidef_add_switch_vlan "switch0" "1" "0 1 2 3 4"
diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh
index ca174da..11aa31b 100755
--- a/target/linux/ar71xx/base-files/lib/ar71xx.sh
+++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh
@@ -351,6 +351,9 @@ ar71xx_board_detect() {
*TL-MR3420)
name="tl-mr3420"
;;
+ *"TL-MR3420 v2")
+ name="tl-mr3420-v2"
+ ;;
*TL-WA7510N)
name="tl-wa7510n"
;;
@@ -384,6 +387,9 @@ ar71xx_board_detect() {
*"TL-WR841N/ND v9")
name="tl-wr841n-v9"
;;
+ *"TL-WR842N/ND v2")
+ name="tl-wr842n-v2"
+ ;;
*TL-WR941ND)
name="tl-wr941nd"
;;
diff --git a/target/linux/ar71xx/base-files/lib/upgrade/platform.sh b/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
index 7168b4e..b25df6c 100755
--- a/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
+++ b/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
@@ -152,6 +152,7 @@ platform_check_image() {
tl-mr3040 | \
tl-mr3220 | \
tl-mr3420 | \
+ tl-mr3420-v2 | \
tl-wa7510n | \
tl-wa901nd | \
tl-wa901nd-v2 | \
@@ -164,6 +165,7 @@ platform_check_image() {
tl-wr841n-v7 | \
tl-wr841n-v8 | \
tl-wr841n-v9 | \
+ tl-wr842n-v2 | \
tl-wr941nd | \
tl-wr1041n-v2 | \
tl-wr1043nd | \
diff --git a/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr841n-v8.c b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr841n-v8.c
index ffaf8d1..0099b15 100644
--- a/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr841n-v8.c
+++ b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr841n-v8.c
@@ -1,5 +1,5 @@
/*
- * TP-LINK TL-WR841N/ND v8 board support
+ * TP-LINK TL-WR841N/ND v8/TL-MR3420 v2 board support
*
* Copyright (C) 2012 Gabor Juhos <juhosg@openwrt.org>
*
@@ -8,6 +8,7 @@
* by the Free Software Foundation.
*/
+#include <linux/gpio.h>
#include <linux/platform_device.h>
#include <asm/mach-ath79/ath79.h>
@@ -18,6 +19,7 @@
#include "dev-gpio-buttons.h"
#include "dev-leds-gpio.h"
#include "dev-m25p80.h"
+#include "dev-usb.h"
#include "dev-wmac.h"
#include "machtypes.h"
@@ -31,7 +33,10 @@
#define TL_WR841NV8_GPIO_LED_SYSTEM 14
#define TL_WR841NV8_GPIO_BTN_RESET 17
-#define TL_WR841NV8_GPIO_SW_RFKILL 16
+#define TL_WR841NV8_GPIO_SW_RFKILL 16 /* WPS for MR3420 v2 */
+
+#define TL_MR3420V2_GPIO_LED_3G 11
+#define TL_MR3420V2_GPIO_USB_POWER 4
#define TL_WR841NV8_KEYS_POLL_INTERVAL 20 /* msecs */
#define TL_WR841NV8_KEYS_DEBOUNCE_INTERVAL (3 * TL_WR841NV8_KEYS_POLL_INTERVAL)
@@ -78,6 +83,11 @@ static struct gpio_led tl_wr841n_v8_leds_gpio[] __initdata = {
.name = "tp-link:green:wlan",
.gpio = TL_WR841NV8_GPIO_LED_WLAN,
.active_low = 1,
+ }, {
+ /* the 3G LED is only present on the MR3420 v2 */
+ .name = "tp-link:green:3g",
+ .gpio = TL_MR3420V2_GPIO_LED_3G,
+ .active_low = 1,
},
};
@@ -99,17 +109,37 @@ static struct gpio_keys_button tl_wr841n_v8_gpio_keys[] __initdata = {
}
};
-static void __init tl_wr841n_v8_setup(void)
+static struct gpio_keys_button tl_mr3420v2_gpio_keys[] __initdata = {
+ {
+ .desc = "Reset button",
+ .type = EV_KEY,
+ .code = KEY_RESTART,
+ .debounce_interval = TL_WR841NV8_KEYS_DEBOUNCE_INTERVAL,
+ .gpio = TL_WR841NV8_GPIO_BTN_RESET,
+ .active_low = 1,
+ }, {
+ .desc = "WPS",
+ .type = EV_KEY,
+ .code = KEY_WPS_BUTTON,
+ .debounce_interval = TL_WR841NV8_KEYS_DEBOUNCE_INTERVAL,
+ .gpio = TL_WR841NV8_GPIO_SW_RFKILL,
+ .active_low = 0,
+ }
+};
+
+static void __init tl_ap123_setup(void)
{
u8 *mac = (u8 *) KSEG1ADDR(0x1f01fc00);
u8 *ee = (u8 *) KSEG1ADDR(0x1fff1000);
- ath79_register_leds_gpio(-1, ARRAY_SIZE(tl_wr841n_v8_leds_gpio),
- tl_wr841n_v8_leds_gpio);
+ /* Disable JTAG, enabling GPIOs 0-3 */
+ /* Configure OBS4 line, for GPIO 4*/
+ ath79_gpio_function_setup(AR934X_GPIO_FUNC_JTAG_DISABLE,
+ AR934X_GPIO_FUNC_CLK_OBS4_EN);
- ath79_register_gpio_keys_polled(1, TL_WR841NV8_KEYS_POLL_INTERVAL,
- ARRAY_SIZE(tl_wr841n_v8_gpio_keys),
- tl_wr841n_v8_gpio_keys);
+ /* config gpio4 as normal gpio function */
+ ath79_gpio_output_select(TL_MR3420V2_GPIO_USB_POWER,
+ AR934X_GPIO_OUT_GPIO);
ath79_register_m25p80(&tl_wr841n_v8_flash_data);
@@ -135,5 +165,61 @@ static void __init tl_wr841n_v8_setup(void)
ath79_register_wmac(ee, mac);
}
+static void __init tl_wr841n_v8_setup(void)
+{
+ tl_ap123_setup();
+
+ ath79_register_leds_gpio(-1, ARRAY_SIZE(tl_wr841n_v8_leds_gpio) - 1,
+ tl_wr841n_v8_leds_gpio);
+
+ ath79_register_gpio_keys_polled(1, TL_WR841NV8_KEYS_POLL_INTERVAL,
+ ARRAY_SIZE(tl_wr841n_v8_gpio_keys),
+ tl_wr841n_v8_gpio_keys);
+}
+
MIPS_MACHINE(ATH79_MACH_TL_WR841N_V8, "TL-WR841N-v8", "TP-LINK TL-WR841N/ND v8",
tl_wr841n_v8_setup);
+
+
+static void __init tl_wr842n_v2_setup(void)
+{
+ tl_ap123_setup();
+
+ ath79_register_leds_gpio(-1, ARRAY_SIZE(tl_wr841n_v8_leds_gpio),
+ tl_wr841n_v8_leds_gpio);
+
+ ath79_register_gpio_keys_polled(1, TL_WR841NV8_KEYS_POLL_INTERVAL,
+ ARRAY_SIZE(tl_wr841n_v8_gpio_keys),
+ tl_wr841n_v8_gpio_keys);
+
+ gpio_request_one(TL_MR3420V2_GPIO_USB_POWER,
+ GPIOF_OUT_INIT_HIGH | GPIOF_EXPORT_DIR_FIXED,
+ "USB power");
+
+ ath79_register_usb();
+}
+
+MIPS_MACHINE(ATH79_MACH_TL_WR842N_V2, "TL-WR842N-v2", "TP-LINK TL-WR842N/ND v2",
+ tl_wr842n_v2_setup);
+
+static void __init tl_mr3420v2_setup(void)
+{
+ tl_ap123_setup();
+
+ ath79_register_leds_gpio(-1, ARRAY_SIZE(tl_wr841n_v8_leds_gpio),
+ tl_wr841n_v8_leds_gpio);
+
+ ath79_register_gpio_keys_polled(1, TL_WR841NV8_KEYS_POLL_INTERVAL,
+ ARRAY_SIZE(tl_mr3420v2_gpio_keys),
+ tl_mr3420v2_gpio_keys);
+
+ /* enable power for the USB port */
+ gpio_request_one(TL_MR3420V2_GPIO_USB_POWER,
+ GPIOF_OUT_INIT_HIGH | GPIOF_EXPORT_DIR_FIXED,
+ "USB power");
+
+ ath79_register_usb();
+}
+
+MIPS_MACHINE(ATH79_MACH_TL_MR3420_V2, "TL-MR3420-v2", "TP-LINK TL-MR3420 v2",
+ tl_mr3420v2_setup);
diff --git a/target/linux/ar71xx/image/Makefile b/target/linux/ar71xx/image/Makefile
index c270f73..a055521 100644
--- a/target/linux/ar71xx/image/Makefile
+++ b/target/linux/ar71xx/image/Makefile
@@ -853,7 +853,7 @@ $(eval $(call SingleProfile,Planex,$(fs_64k),MZKW300NH,mzk-w300nh,MZK-W300NH,tty
$(eval $(call SingleProfile,TPLINKOLD,$(fs_squash),TLWR841NV15,tl-wr841nd-v1.5,TL-WR841N-v1.5,ttyS0,115200,0x08410002,2,4M))
$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLMR3220,tl-mr3220-v1,TL-MR3220,ttyS0,115200,0x32200001,1,4M))
-$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLMR3420,tl-mr3420-v1,TL-MR3420,ttyS0,115200,0x34200001,1,4M))
+$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLMR3420V1,tl-mr3420-v1,TL-MR3420,ttyS0,115200,0x34200001,1,4M))
$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLWA701,tl-wa701n-v1,TL-WA901ND,ttyS0,115200,0x07010001,1,4M))
$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLWA7510NV1,tl-wa7510n,TL-WA7510N,ttyS0,115200,0x75100001,1,4M))
$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLWA901NV1,tl-wa901nd-v1,TL-WA901ND,ttyS0,115200,0x09010001,1,4M))
@@ -866,7 +866,7 @@ $(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLWR743,tl-wr743nd-v1,TL-WR741ND
$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLWR841NV3,tl-wr841nd-v3,TL-WR941ND,ttyS0,115200,0x08410003,3,4M))
$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLWR841NV5,tl-wr841nd-v5,TL-WR741ND,ttyS0,115200,0x08410005,1,4M))
$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLWR841NV7,tl-wr841nd-v7,TL-WR841N-v7,ttyS0,115200,0x08410007,1,4M))
-$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLWR842,tl-wr842n-v1,TL-MR3420,ttyS0,115200,0x08420001,1,8M))
+$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLWR842V1,tl-wr842n-v1,TL-MR3420,ttyS0,115200,0x08420001,1,8M))
$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLWR941NV2,tl-wr941nd-v2,TL-WR941ND,ttyS0,115200,0x09410002,2,4M))
$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLWR941NV3,tl-wr941nd-v3,TL-WR941ND,ttyS0,115200,0x09410002,2,4M))
$(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLWR941NV4,tl-wr941nd-v4,TL-WR741ND,ttyS0,115200,0x09410004,1,4M))
@@ -875,11 +875,13 @@ $(eval $(call SingleProfile,TPLINK,$(fs_64kraw),TLWR1043,tl-wr1043nd-v1,TL-WR104
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLMR11U,tl-mr11u-v1,TL-MR11U,ttyATH0,115200,0x00110101,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLMR3020,tl-mr3020-v1,TL-MR3020,ttyATH0,115200,0x30200001,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLMR3040,tl-mr3040-v1,TL-MR3040,ttyATH0,115200,0x30400001,1,4Mlzma))
+$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLMR3420V2,tl-mr3420-v2,TL-MR3420-v2,ttyS0,115200,0x34200002,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR703,tl-wr703n-v1,TL-WR703N,ttyATH0,115200,0x07030101,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR740NV4,tl-wr740n-v4,TL-WR741ND-v4,ttyATH0,115200,0x07400004,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR741NV4,tl-wr741nd-v4,TL-WR741ND-v4,ttyATH0,115200,0x07410004,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR841NV8,tl-wr841n-v8,TL-WR841N-v8,ttyS0,115200,0x08410008,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR841NV9,tl-wr841n-v9,TL-WR841N-v9,ttyS0,115200,0x08410009,1,4Mlzma))
+$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR842V2,tl-wr842n-v2,TL-WR842N-v2,ttyS0,115200,0x8420002,1,8Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR1041,tl-wr1041n-v2,TL-WR1041N-v2,ttyS0,115200,0x10410002,1,4Mlzma))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWR2543,tl-wr2543-v1,TL-WR2543N,ttyS0,115200,0x25430001,1,8Mlzma,-v 3.13.99))
$(eval $(call SingleProfile,TPLINK-LZMA,$(fs_64kraw),TLWDR3500V1,tl-wdr3500-v1,TL-WDR3500,ttyS0,115200,0x35000001,1,8Mlzma))
@@ -921,11 +923,13 @@ $(eval $(call SingleProfile,ZyXEL,$(fs_64k),NBG_460N_550N_550NH,nbg460n_550n_550
$(eval $(call MultiProfile,AP121,AP121_2M AP121_4M))
$(eval $(call MultiProfile,EWDORIN, EWDORINAP EWDORINRT))
$(eval $(call MultiProfile,TEW652BRP,TEW652BRP_FW TEW652BRP_RECOVERY))
+$(eval $(call MultiProfile,TLMR3420,TLMR3420V1 TLMR3420V2))
$(eval $(call MultiProfile,TLWA901,TLWA901NV1 TLWA901NV2))
$(eval $(call MultiProfile,TLWA7510,TLWA7510NV1))
$(eval $(call MultiProfile,TLWR740,TLWR740NV1 TLWR740NV3 TLWR740NV4))
$(eval $(call MultiProfile,TLWR741,TLWR741NV1 TLWR741NV2 TLWR741NV4))
$(eval $(call MultiProfile,TLWR841,TLWR841NV15 TLWR841NV3 TLWR841NV5 TLWR841NV7 TLWR841NV8 TLWR841NV9))
+$(eval $(call MultiProfile,TLWR842,TLWR842V1 TLWR842V2))
$(eval $(call MultiProfile,TLWR941,TLWR941NV2 TLWR941NV3 TLWR941NV4))
$(eval $(call MultiProfile,TLWDR4300,TLWDR3500V1 TLWDR3600V1 TLWDR4300V1 TLWDR4310V1))
$(eval $(call MultiProfile,UBNT,UBNTAIRROUTER UBNTRS UBNTRSPRO UBNTLSSR71 UBNTBULLETM UBNTROCKETM UBNTNANOM UBNTUNIFI UBNTUNIFIOUTDOOR))
diff --git a/target/linux/ar71xx/patches-3.3/610-MIPS-ath79-openwrt-machines.patch b/target/linux/ar71xx/patches-3.3/610-MIPS-ath79-openwrt-machines.patch
index 0230908..6d67f5f 100644
--- a/target/linux/ar71xx/patches-3.3/610-MIPS-ath79-openwrt-machines.patch
+++ b/target/linux/ar71xx/patches-3.3/610-MIPS-ath79-openwrt-machines.patch
@@ -1,6 +1,6 @@
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -16,18 +16,102 @@
+@@ -16,18 +16,104 @@
enum ath79_mach_type {
ATH79_MACH_GENERIC = 0,
@@ -61,6 +61,7 @@
+ ATH79_MACH_TL_MR3040, /* TP-LINK TL-MR3040 */
+ ATH79_MACH_TL_MR3220, /* TP-LINK TL-MR3220 */
+ ATH79_MACH_TL_MR3420, /* TP-LINK TL-MR3420 */
++ ATH79_MACH_TL_MR3420_V2, /* TP-LINK TL-MR3420 v2 */
+ ATH79_MACH_TL_WA901ND, /* TP-LINK TL-WA901ND */
+ ATH79_MACH_TL_WA901ND_V2, /* TP-LINK TL-WA901ND v2 */
+ ATH79_MACH_TL_WDR4300, /* TP-LINK TL-WDR4300 */
@@ -73,6 +74,7 @@
+ ATH79_MACH_TL_WR841N_V1, /* TP-LINK TL-WR841N v1 */
+ ATH79_MACH_TL_WR841N_V7, /* TP-LINK TL-WR841N/ND v7 */
+ ATH79_MACH_TL_WR841N_V8, /* TP-LINK TL-WR841N/ND v8 */
++ ATH79_MACH_TL_WR842N_V2, /* TP-LINK TL-WR842N/ND v2 */
+ ATH79_MACH_TL_WR941ND, /* TP-LINK TL-WR941ND */
ATH79_MACH_UBNT_AIRROUTER, /* Ubiquiti AirRouter */
ATH79_MACH_UBNT_BULLET_M, /* Ubiquiti Bullet M */
diff --git a/target/linux/ar71xx/patches-3.3/612-MIPS-ath79-TL-WA7510N-v1-support.patch b/target/linux/ar71xx/patches-3.3/612-MIPS-ath79-TL-WA7510N-v1-support.patch
index 6bd58b0..dba879e 100644
--- a/target/linux/ar71xx/patches-3.3/612-MIPS-ath79-TL-WA7510N-v1-support.patch
+++ b/target/linux/ar71xx/patches-3.3/612-MIPS-ath79-TL-WA7510N-v1-support.patch
@@ -1,9 +1,9 @@
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -74,6 +74,7 @@ enum ath79_mach_type {
- ATH79_MACH_TL_MR3040, /* TP-LINK TL-MR3040 */
+@@ -75,6 +75,7 @@ enum ath79_mach_type {
ATH79_MACH_TL_MR3220, /* TP-LINK TL-MR3220 */
ATH79_MACH_TL_MR3420, /* TP-LINK TL-MR3420 */
+ ATH79_MACH_TL_MR3420_V2, /* TP-LINK TL-MR3420 v2 */
+ ATH79_MACH_TL_WA7510N_V1, /* TP-LINK TL-WA7510N v1*/
ATH79_MACH_TL_WA901ND, /* TP-LINK TL-WA901ND */
ATH79_MACH_TL_WA901ND_V2, /* TP-LINK TL-WA901ND v2 */
diff --git a/target/linux/ar71xx/patches-3.3/613-MIPS-ath79-add-TL-WDR3500-support.patch b/target/linux/ar71xx/patches-3.3/613-MIPS-ath79-add-TL-WDR3500-support.patch
index 0a2c3bd..059089b 100644
--- a/target/linux/ar71xx/patches-3.3/613-MIPS-ath79-add-TL-WDR3500-support.patch
+++ b/target/linux/ar71xx/patches-3.3/613-MIPS-ath79-add-TL-WDR3500-support.patch
@@ -1,6 +1,6 @@
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -84,6 +84,7 @@ enum ath79_mach_type {
+@@ -78,6 +78,7 @@ enum ath79_mach_type {
ATH79_MACH_TL_WA7510N_V1, /* TP-LINK TL-WA7510N v1*/
ATH79_MACH_TL_WA901ND, /* TP-LINK TL-WA901ND */
ATH79_MACH_TL_WA901ND_V2, /* TP-LINK TL-WA901ND v2 */
@@ -10,7 +10,7 @@
ATH79_MACH_TL_WR1043ND, /* TP-LINK TL-WR1043ND */
--- a/arch/mips/ath79/Kconfig
+++ b/arch/mips/ath79/Kconfig
-@@ -514,6 +514,17 @@ config ATH79_MACH_TL_WA901ND_V2
+@@ -469,6 +469,17 @@ config ATH79_MACH_TL_WA901ND_V2
select ATH79_DEV_M25P80
select ATH79_DEV_WMAC
@@ -30,7 +30,7 @@
select SOC_AR934X
--- a/arch/mips/ath79/Makefile
+++ b/arch/mips/ath79/Makefile
-@@ -81,6 +81,7 @@ obj-$(CONFIG_ATH79_MACH_TL_MR3020) += ma
+@@ -78,6 +78,7 @@ obj-$(CONFIG_ATH79_MACH_TL_MR3020) += ma
obj-$(CONFIG_ATH79_MACH_TL_MR3X20) += mach-tl-mr3x20.o
obj-$(CONFIG_ATH79_MACH_TL_WA901ND) += mach-tl-wa901nd.o
obj-$(CONFIG_ATH79_MACH_TL_WA901ND_V2) += mach-tl-wa901nd-v2.o
diff --git a/target/linux/ar71xx/patches-3.3/613-MIPS-ath79-ubnt-xm-add-unifi-outdoor.patch b/target/linux/ar71xx/patches-3.3/613-MIPS-ath79-ubnt-xm-add-unifi-outdoor.patch
index 8a1c770..9766afe 100644
--- a/target/linux/ar71xx/patches-3.3/613-MIPS-ath79-ubnt-xm-add-unifi-outdoor.patch
+++ b/target/linux/ar71xx/patches-3.3/613-MIPS-ath79-ubnt-xm-add-unifi-outdoor.patch
@@ -56,7 +56,7 @@
+ ubnt_unifi_outdoor_setup);
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -97,6 +97,7 @@ enum ath79_mach_type {
+@@ -100,6 +100,7 @@ enum ath79_mach_type {
ATH79_MACH_UBNT_RSPRO, /* Ubiquiti RouterStation Pro */
ATH79_MACH_UBNT_RS, /* Ubiquiti RouterStation */
ATH79_MACH_UBNT_UNIFI, /* Ubiquiti Unifi */
diff --git a/target/linux/ar71xx/patches-3.3/708-MIPS-ath79-TL-WR841v9-support.patch b/target/linux/ar71xx/patches-3.3/708-MIPS-ath79-TL-WR841v9-support.patch
index 37425a6..612970b 100644
--- a/target/linux/ar71xx/patches-3.3/708-MIPS-ath79-TL-WR841v9-support.patch
+++ b/target/linux/ar71xx/patches-3.3/708-MIPS-ath79-TL-WR841v9-support.patch
@@ -33,6 +33,6 @@
ATH79_MACH_TL_WR841N_V7, /* TP-LINK TL-WR841N/ND v7 */
ATH79_MACH_TL_WR841N_V8, /* TP-LINK TL-WR841N/ND v8 */
+ ATH79_MACH_TL_WR841N_V9, /* TP-LINK TL-WR841N/ND v9 */
+ ATH79_MACH_TL_WR842N_V2, /* TP-LINK TL-WR842N/ND v2 */
ATH79_MACH_TL_WR941ND, /* TP-LINK TL-WR941ND */
ATH79_MACH_UBNT_AIRROUTER, /* Ubiquiti AirRouter */
- ATH79_MACH_UBNT_BULLET_M, /* Ubiquiti Bullet M */

View File

@ -1,110 +0,0 @@
From: nbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Sun, 7 Oct 2012 23:01:52 +0000
Subject: x86: add grub2 iso support
diff --git a/Config.in b/Config.in
index 5b4522e..54df7c8 100644
--- a/Config.in
+++ b/Config.in
@@ -81,7 +81,7 @@ menu "Target Images"
config TARGET_ROOTFS_ISO
bool "iso"
default n
- depends TARGET_ROOTFS_INITRAMFS && TARGET_x86
+ depends on TARGET_x86_generic
help
Create some bootable ISO image
diff --git a/target/linux/x86/base-files/lib/preinit/20_check_iso b/target/linux/x86/base-files/lib/preinit/20_check_iso
new file mode 100644
index 0000000..beff6eb
--- /dev/null
+++ b/target/linux/x86/base-files/lib/preinit/20_check_iso
@@ -0,0 +1,5 @@
+check_for_iso() {
+ grep -qE '/dev/root.*iso9660' /proc/mounts && ramoverlay
+}
+
+boot_hook_add preinit_mount_root check_for_iso
diff --git a/target/linux/x86/image/Makefile b/target/linux/x86/image/Makefile
index 13da511..8f0debd 100644
--- a/target/linux/x86/image/Makefile
+++ b/target/linux/x86/image/Makefile
@@ -9,7 +9,8 @@ include $(INCLUDE_DIR)/image.mk
export PATH=$(TARGET_PATH):/sbin
-GRUB2_MODULES = biosdisk boot chain configfile ext2 linux ls part_msdos reboot serial vga
+GRUB2_MODULES = at_keyboard biosdisk boot chain configfile ext2 linux ls part_msdos reboot serial vga
+GRUB2_MODULES_ISO = at_keyboard biosdisk boot chain configfile iso9660 linux ls part_msdos reboot serial vga
GRUB_TERMINALS =
GRUB_SERIAL_CONFIG =
GRUB_TERMINAL_CONFIG =
@@ -51,7 +52,7 @@ ifneq ($(CONFIG_X86_GRUB_IMAGES),)
define Image/cmdline/ext4
root=$(ROOTPART) rootfstype=ext4 rootwait
endef
-
+
define Image/cmdline/jffs2-64k
block2mtd.block2mtd=$(ROOTPART),65536,rootfs root=/dev/mtdblock0 rootfstype=jffs2 rootwait
endef
@@ -165,7 +166,31 @@ define Image/Build/squashfs
$(call prepare_generic_squashfs,$(KDIR)/root.squashfs)
endef
-define Image/Build/iso
+ifdef CONFIG_X86_USE_GRUB2
+ define Image/Build/iso
+ $(INSTALL_DIR) $(KDIR)/root.grub/boot/grub $(KDIR)/grub2
+ $(CP) $(KDIR)/bzImage $(KDIR)/root.grub/boot/vmlinuz
+ grub-mkimage \
+ -o $(KDIR)/grub2/eltorito.img \
+ -O i386-pc \
+ -c ./grub-early.cfg \
+ $(GRUB2_MODULES_ISO)
+ cat \
+ $(STAGING_DIR_HOST)/lib/grub/i386-pc/cdboot.img \
+ $(KDIR)/grub2/eltorito.img \
+ > $(KDIR)/root.grub/boot/grub/eltorito.img
+ sed \
+ -e 's#@SERIAL_CONFIG@#$(strip $(GRUB_SERIAL_CONFIG))#g' \
+ -e 's#@TERMINAL_CONFIG@#$(strip $(GRUB_TERMINAL_CONFIG))#g' \
+ -e 's#@CMDLINE@#root=/dev/sr0 rootfstype=iso9660 rootwait $(strip $(call Image/cmdline/$(1)) $(BOOTOPTS) $(GRUB_CONSOLE_CMDLINE))#g' \
+ -e 's#@TIMEOUT@#$(GRUB_TIMEOUT)#g' \
+ ./grub-iso.cfg > $(KDIR)/root.grub/boot/grub/grub.cfg
+ $(CP) $(KDIR)/bzImage $(KDIR)/root.grub/boot/vmlinuz
+ mkisofs -R -b boot/grub/eltorito.img -no-emul-boot -boot-info-table \
+ -o $(KDIR)/root.iso $(KDIR)/root.grub $(TARGET_DIR)
+ endef
+else
+ define Image/Build/iso
$(INSTALL_DIR) $(KDIR)/root.grub/boot/grub
$(CP) \
$(KDIR)/stage2_eltorito \
@@ -179,7 +204,8 @@ define Image/Build/iso
$(CP) $(KDIR)/bzImage $(KDIR)/root.grub/boot/vmlinuz
mkisofs -R -b boot/grub/stage2_eltorito -no-emul-boot -boot-load-size 4 -boot-info-table \
-o $(KDIR)/root.iso $(KDIR)/root.grub
-endef
+ endef
+endif
ifneq ($(CONFIG_X86_VDI_IMAGES),)
define Image/Build/vdi
diff --git a/target/linux/x86/image/grub-iso.cfg b/target/linux/x86/image/grub-iso.cfg
new file mode 100644
index 0000000..4d5d697
--- /dev/null
+++ b/target/linux/x86/image/grub-iso.cfg
@@ -0,0 +1,10 @@
+@SERIAL_CONFIG@
+@TERMINAL_CONFIG@
+
+set default="0"
+set timeout="@TIMEOUT@"
+set root='(cd)'
+
+menuentry "OpenWrt" {
+ linux /boot/vmlinuz @CMDLINE@ noinitrd reboot=bios
+}

View File

@ -1,24 +0,0 @@
From: jow <jow@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Thu, 17 Jan 2013 15:46:26 +0000
Subject: x86: explicitely pass staging directory to grub-mkimage instead of relying on build time defaults (#12821)
diff --git a/target/linux/x86/image/Makefile b/target/linux/x86/image/Makefile
index 8f0debd..6e2bd54 100644
--- a/target/linux/x86/image/Makefile
+++ b/target/linux/x86/image/Makefile
@@ -102,6 +102,7 @@ ifneq ($(CONFIG_X86_GRUB_IMAGES),)
$(INSTALL_DIR) $(KDIR)/root.grub/boot/grub $(KDIR)/grub2
$(CP) $(KDIR)/bzImage $(KDIR)/root.grub/boot/vmlinuz
grub-mkimage \
+ -d $(STAGING_DIR_HOST)/lib/grub/i386-pc \
-o $(KDIR)/grub2/core.img \
-O i386-pc \
-c ./grub-early.cfg \
@@ -171,6 +172,7 @@ ifdef CONFIG_X86_USE_GRUB2
$(INSTALL_DIR) $(KDIR)/root.grub/boot/grub $(KDIR)/grub2
$(CP) $(KDIR)/bzImage $(KDIR)/root.grub/boot/vmlinuz
grub-mkimage \
+ -d $(STAGING_DIR_HOST)/lib/grub/i386-pc \
-o $(KDIR)/grub2/eltorito.img \
-O i386-pc \
-c ./grub-early.cfg \

View File

@ -1,57 +0,0 @@
From: blogic <blogic@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Tue, 7 May 2013 12:35:07 +0000
Subject: grub2: Add sub package grub-editenv for target installation
grub-editenv allows to modify grub2 environment files. Add a new package
that build grub2 for the target and packs up grub-editenv.
Signed-off-by: Helmut Schaa <helmut.schaa@googlemail.com>
diff --git a/package/grub2/Makefile b/package/grub2/Makefile
index b606f54..dd490ff 100644
--- a/package/grub2/Makefile
+++ b/package/grub2/Makefile
@@ -16,7 +16,6 @@ PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
PKG_SOURCE_URL:=@GNU/grub
PKG_MD5SUM:=e927540b6eda8b024fb0391eeaa4091c
-PKG_HOST_ONLY:=1
HOST_BUILD_PARALLEL:=1
PKG_BUILD_DEPENDS:=grub2/host
@@ -32,6 +31,23 @@ define Package/grub2
DEPENDS:=@TARGET_x86
endef
+define Package/grub2-editenv
+ CATEGORY:=Utilities
+ SECTION:=utils
+ TITLE:=Grub2 Environment editor
+ URL:=http://www.gnu.org/software/grub/
+ DEPENDS:=@TARGET_x86
+endef
+
+define Package/grub2-editenv/description
+ Edit grub2 environment files.
+endef
+
+CONFIGURE_ARGS += \
+ --target=$(REAL_GNU_TARGET_NAME) \
+ --disable-werror \
+ --disable-nls
+
HOST_CONFIGURE_ARGS += \
--target=$(REAL_GNU_TARGET_NAME) \
--sbindir="$(STAGING_DIR_HOST)/bin" \
@@ -47,5 +63,11 @@ define Host/Configure
$(Host/Configure/Default)
endef
+define Package/grub2-editenv/install
+ $(INSTALL_DIR) $(1)/usr/sbin
+ $(INSTALL_BIN) $(PKG_BUILD_DIR)/grub-editenv $(1)/usr/sbin/
+endef
+
$(eval $(call HostBuild))
$(eval $(call BuildPackage,grub2))
+$(eval $(call BuildPackage,grub2-editenv))

View File

@ -1,37 +0,0 @@
From: nbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Sat, 10 Aug 2013 18:35:29 +0000
Subject: x86: Fix CONFIG_X86_GRUB_SERIAL=""
With
.config:CONFIG_X86_GRUB_SERIAL=""
which (AFAICT) is the way to tell GRUB not to use a serial console, in
target/linux/x86/image/Makefile:ifneq ($(CONFIG_X86_GRUB_SERIAL),)
$(CONFIG_X86_GRUB_SERIAL) expands to `""' (a literal double double-quote),
making the condition unconditionally false.
This patch fixes the situation by passing CONFIG_X86_GRUB_SERIAL through
qstrip before testing.
Signed-off-by: Tamas TEVESZ <ice@extreme.hu>
diff --git a/target/linux/x86/image/Makefile b/target/linux/x86/image/Makefile
index 6e2bd54..2e73519 100644
--- a/target/linux/x86/image/Makefile
+++ b/target/linux/x86/image/Makefile
@@ -27,8 +27,10 @@ ifneq ($(strip $(foreach subtarget,$(USE_ATKBD),$(CONFIG_TARGET_x86_$(subtarget)
GRUB2_MODULES += at_keyboard
endif
-ifneq ($(CONFIG_X86_GRUB_SERIAL),)
- GRUB_CONSOLE_CMDLINE += console=$(call qstrip,$(CONFIG_X86_GRUB_SERIAL)),$(CONFIG_X86_GRUB_BAUDRATE)n8
+GRUB_SERIAL:=$(call qstrip,$(CONFIG_X86_GRUB_SERIAL))
+
+ifneq ($(GRUB_SERIAL),)
+ GRUB_CONSOLE_CMDLINE += console=$(GRUB_SERIAL),$(CONFIG_X86_GRUB_BAUDRATE)n8
GRUB_SERIAL_CONFIG := serial --unit=0 --speed=$(CONFIG_X86_GRUB_BAUDRATE) --word=8 --parity=no --stop=1
GRUB_TERMINALS += serial
endif

View File

@ -1,218 +0,0 @@
From: nbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Wed, 12 Mar 2014 11:21:16 +0000
Subject: grub2: update to 2.02-beta2, fixes mac os x 10.9 support (and many other things)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
diff --git a/package/grub2/Makefile b/package/grub2/Makefile
index dd490ff..4edd92b 100644
--- a/package/grub2/Makefile
+++ b/package/grub2/Makefile
@@ -9,12 +9,12 @@ include $(TOPDIR)/rules.mk
include $(INCLUDE_DIR)/kernel.mk
PKG_NAME:=grub
-PKG_VERSION:=2.00
+PKG_VERSION:=2.02~beta2
PKG_RELEASE:=1
-PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
-PKG_SOURCE_URL:=@GNU/grub
-PKG_MD5SUM:=e927540b6eda8b024fb0391eeaa4091c
+PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
+PKG_SOURCE_URL:=http://alpha.gnu.org/gnu/grub
+PKG_MD5SUM:=be62932eade308a364ea4bbc91295930
HOST_BUILD_PARALLEL:=1
PKG_BUILD_DEPENDS:=grub2/host
diff --git a/package/grub2/patches/100-grub_setup_root.patch b/package/grub2/patches/100-grub_setup_root.patch
index 7775b2a..9619c41 100644
--- a/package/grub2/patches/100-grub_setup_root.patch
+++ b/package/grub2/patches/100-grub_setup_root.patch
@@ -1,41 +1,6 @@
--- a/util/grub-setup.c
+++ b/util/grub-setup.c
-@@ -141,12 +141,11 @@ write_rootdev (char *core_img, grub_devi
- static void
- setup (const char *dir,
- const char *boot_file, const char *core_file,
-- const char *dest, int force,
-+ const char *root, const char *dest, int force,
- int fs_probe, int allow_floppy)
- {
- char *boot_path, *core_path, *core_path_dev, *core_path_dev_full;
- char *boot_img, *core_img;
-- char *root = 0;
- size_t boot_size, core_size;
- grub_uint16_t core_sectors;
- grub_device_t root_dev = 0, dest_dev, core_dev;
-@@ -253,7 +252,10 @@ setup (const char *dir,
-
- core_dev = dest_dev;
-
-- {
-+ if (root)
-+ root_dev = grub_device_open(root);
-+
-+ if (!root_dev) {
- char **root_devices = grub_guess_root_devices (dir);
- char **cur;
- int found = 0;
-@@ -263,6 +265,8 @@ setup (const char *dir,
- char *drive;
- grub_device_t try_dev;
-
-+ if (root_dev)
-+ break;
- drive = grub_util_get_grub_dev (*cur);
- if (!drive)
- continue;
-@@ -956,6 +960,8 @@ static struct argp_option options[] = {
+@@ -87,6 +87,8 @@ static struct argp_option options[] = {
N_("install even if problems are detected"), 0},
{"skip-fs-probe",'s',0, 0,
N_("do not probe for filesystems in DEVICE"), 0},
@@ -44,7 +9,7 @@
{"verbose", 'v', 0, 0, N_("print verbose messages."), 0},
{"allow-floppy", 'a', 0, 0,
/* TRANSLATORS: The potential breakage isn't limited to floppies but it's
-@@ -993,6 +999,7 @@ struct arguments
+@@ -130,6 +132,7 @@ struct arguments
char *core_file;
char *dir;
char *dev_map;
@@ -52,7 +17,7 @@
int force;
int fs_probe;
int allow_floppy;
-@@ -1040,6 +1047,13 @@ argp_parser (int key, char *arg, struct
+@@ -178,6 +181,13 @@ argp_parser (int key, char *arg, struct
arguments->dev_map = xstrdup (arg);
break;
@@ -66,12 +31,88 @@
case 'f':
arguments->force = 1;
break;
-@@ -1172,7 +1186,7 @@ main (int argc, char *argv[])
- setup (arguments.dir ? : DEFAULT_DIRECTORY,
- arguments.boot_file ? : DEFAULT_BOOT_FILE,
- arguments.core_file ? : DEFAULT_CORE_FILE,
-- dest_dev, arguments.force,
-+ arguments.root_dev, dest_dev, arguments.force,
- arguments.fs_probe, arguments.allow_floppy);
+@@ -313,7 +323,7 @@ main (int argc, char *argv[])
+ GRUB_SETUP_FUNC (arguments.dir ? : DEFAULT_DIRECTORY,
+ arguments.boot_file ? : DEFAULT_BOOT_FILE,
+ arguments.core_file ? : DEFAULT_CORE_FILE,
+- dest_dev, arguments.force,
++ arguments.root_dev, dest_dev, arguments.force,
+ arguments.fs_probe, arguments.allow_floppy,
+ arguments.add_rs_codes);
+
+--- a/util/setup.c
++++ b/util/setup.c
+@@ -247,13 +247,12 @@ identify_partmap (grub_disk_t disk __att
+ void
+ SETUP (const char *dir,
+ const char *boot_file, const char *core_file,
+- const char *dest, int force,
++ const char *root, const char *dest, int force,
+ int fs_probe, int allow_floppy,
+ int add_rs_codes __attribute__ ((unused))) /* unused on sparc64 */
+ {
+ char *core_path;
+ char *boot_img, *core_img, *boot_path;
+- char *root = 0;
+ size_t boot_size, core_size;
+ #ifdef GRUB_SETUP_BIOS
+ grub_uint16_t core_sectors;
+@@ -307,7 +306,10 @@ SETUP (const char *dir,
+
+ core_dev = dest_dev;
+
+- {
++ if (root)
++ root_dev = grub_device_open(root);
++
++ if (!root_dev) {
+ char **root_devices = grub_guess_root_devices (dir);
+ char **cur;
+ int found = 0;
+@@ -317,6 +319,8 @@ SETUP (const char *dir,
+ char *drive;
+ grub_device_t try_dev;
+
++ if (root_dev)
++ break;
+ drive = grub_util_get_grub_dev (*cur);
+ if (!drive)
+ continue;
+--- a/include/grub/util/install.h
++++ b/include/grub/util/install.h
+@@ -182,13 +182,13 @@ grub_install_get_image_target (const cha
+ void
+ grub_util_bios_setup (const char *dir,
+ const char *boot_file, const char *core_file,
+- const char *dest, int force,
++ const char *root, const char *dest, int force,
+ int fs_probe, int allow_floppy,
+ int add_rs_codes);
+ void
+ grub_util_sparc_setup (const char *dir,
+ const char *boot_file, const char *core_file,
+- const char *dest, int force,
++ const char *root, const char *dest, int force,
+ int fs_probe, int allow_floppy,
+ int add_rs_codes);
- /* Free resources. */
+--- a/util/grub-install.c
++++ b/util/grub-install.c
+@@ -1660,7 +1660,7 @@ main (int argc, char *argv[])
+ /* Now perform the installation. */
+ if (install_bootsector)
+ grub_util_bios_setup (platdir, "boot.img", "core.img",
+- install_drive, force,
++ NULL, install_drive, force,
+ fs_probe, allow_floppy, add_rs_codes);
+ break;
+ }
+@@ -1686,7 +1686,7 @@ main (int argc, char *argv[])
+ /* Now perform the installation. */
+ if (install_bootsector)
+ grub_util_sparc_setup (platdir, "boot.img", "core.img",
+- install_device, force,
++ NULL, install_device, force,
+ fs_probe, allow_floppy,
+ 0 /* unused */ );
+ break;
diff --git a/package/grub2/patches/200-fix-gets-removal.patch b/package/grub2/patches/200-fix-gets-removal.patch
index 4370fb5..737fb97 100644
--- a/package/grub2/patches/200-fix-gets-removal.patch
+++ b/package/grub2/patches/200-fix-gets-removal.patch
@@ -1,15 +1,16 @@
--- a/grub-core/gnulib/stdio.in.h
+++ b/grub-core/gnulib/stdio.in.h
-@@ -137,12 +137,6 @@
- "use gnulib module fflush for portable POSIX compliance");
+@@ -695,13 +695,6 @@ _GL_WARN_ON_USE (getline, "getline is un
+ # endif
#endif
-/* It is very rare that the developer ever has full control of stdin,
-- so any use of gets warrants an unconditional warning. Assume it is
-- always declared, since it is required by C89. */
+- so any use of gets warrants an unconditional warning; besides, C11
+- removed it. */
-#undef gets
--_GL_WARN_ON_USE (gets, "gets is a security hole - use fgets instead");
+-#if HAVE_RAW_DECL_GETS
+-#endif
-
- #if @GNULIB_FOPEN@
- # if @REPLACE_FOPEN@
- # if !(defined __cplusplus && defined GNULIB_NAMESPACE)
+
+ #if @GNULIB_OBSTACK_PRINTF@ || @GNULIB_OBSTACK_PRINTF_POSIX@
+ struct obstack;

View File

@ -1,20 +0,0 @@
From: nbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Sun, 30 Mar 2014 19:55:39 +0000
Subject: grub2: disable libdevmapper - fix build when it's available
Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
diff --git a/package/grub2/Makefile b/package/grub2/Makefile
index 4edd92b..ed86fff 100644
--- a/package/grub2/Makefile
+++ b/package/grub2/Makefile
@@ -46,7 +46,8 @@ endef
CONFIGURE_ARGS += \
--target=$(REAL_GNU_TARGET_NAME) \
--disable-werror \
- --disable-nls
+ --disable-nls \
+ --disable-device-mapper
HOST_CONFIGURE_ARGS += \
--target=$(REAL_GNU_TARGET_NAME) \

View File

@ -1,20 +0,0 @@
From: nbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73>
Date: Sun, 30 Mar 2014 19:55:43 +0000
Subject: grub2: disable mkfont - fix build on Archlinux
Signed-off-by: Alexander Couzens <lynxis@fe80.eu>
diff --git a/package/grub2/Makefile b/package/grub2/Makefile
index ed86fff..509fb60 100644
--- a/package/grub2/Makefile
+++ b/package/grub2/Makefile
@@ -47,7 +47,8 @@ CONFIGURE_ARGS += \
--target=$(REAL_GNU_TARGET_NAME) \
--disable-werror \
--disable-nls \
- --disable-device-mapper
+ --disable-device-mapper \
+ --disable-grub-mkfont
HOST_CONFIGURE_ARGS += \
--target=$(REAL_GNU_TARGET_NAME) \

View File

@ -1,155 +0,0 @@
From: Zhao, Gang <gamerh2o@gmail.com>
Date: Wed, 21 May 2014 23:26:28 +0800
Subject: ar71xx: add support for dlink dir-615-e1
Dlink dir-615-e1 can use dir-600-a1's image, but the image can't be
uploaded through dlink's normal firmware update web page.
Add profile for dir-615-e1 so the generated image can be uploaded
through the firmware update web page.
Signed-off-by: Zhao, Gang <gamerh2o@gmail.com>
diff --git a/target/linux/ar71xx/base-files/etc/diag.sh b/target/linux/ar71xx/base-files/etc/diag.sh
index 0d01119..c86044b 100755
--- a/target/linux/ar71xx/base-files/etc/diag.sh
+++ b/target/linux/ar71xx/base-files/etc/diag.sh
@@ -61,6 +61,7 @@ get_status_led() {
status_led="db120:green:status"
;;
dir-600-a1 |\
+ dir-615-e1 |\
dir-615-e4)
status_led="d-link:green:power"
;;
diff --git a/target/linux/ar71xx/base-files/etc/uci-defaults/leds b/target/linux/ar71xx/base-files/etc/uci-defaults/leds
index f1ac9ec..98568fa 100755
--- a/target/linux/ar71xx/base-files/etc/uci-defaults/leds
+++ b/target/linux/ar71xx/base-files/etc/uci-defaults/leds
@@ -52,6 +52,7 @@ rb750)
;;
dir-600-a1|\
+dir-615-e1|\
dir-615-e4)
ucidef_set_led_netdev "wan" "WAN" "d-link:green:wan" "eth1"
ucidef_set_led_switch "lan1" "LAN1" "d-link:green:lan1" "switch0" "0x02"
diff --git a/target/linux/ar71xx/base-files/etc/uci-defaults/network b/target/linux/ar71xx/base-files/etc/uci-defaults/network
index e38a9b8..a2ac224 100755
--- a/target/linux/ar71xx/base-files/etc/uci-defaults/network
+++ b/target/linux/ar71xx/base-files/etc/uci-defaults/network
@@ -182,6 +182,7 @@ ap96 |\
airrouter |\
dir-600-a1 |\
dir-615-c1 |\
+dir-615-e1 |\
dir-615-e4 |\
ja76pf |\
rb-750 |\
diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh
index 11aa31b..9273012 100755
--- a/target/linux/ar71xx/base-files/lib/ar71xx.sh
+++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh
@@ -201,6 +201,9 @@ ar71xx_board_detect() {
*"DIR-600 rev. A1")
name="dir-600-a1"
;;
+ *"DIR-615 rev. E1")
+ name="dir-615-e1"
+ ;;
*"DIR-615 rev. E4")
name="dir-615-e4"
;;
diff --git a/target/linux/ar71xx/base-files/lib/upgrade/platform.sh b/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
index b25df6c..5fdd564 100755
--- a/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
+++ b/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
@@ -104,6 +104,7 @@ platform_check_image() {
ap83 | \
dir-600-a1 | \
dir-615-c1 | \
+ dir-615-e1 | \
dir-615-e4 | \
ew-dorin | \
ew-dorin-router | \
diff --git a/target/linux/ar71xx/files/arch/mips/ath79/mach-dir-600-a1.c b/target/linux/ar71xx/files/arch/mips/ath79/mach-dir-600-a1.c
index c0fa900..321fdce 100644
--- a/target/linux/ar71xx/files/arch/mips/ath79/mach-dir-600-a1.c
+++ b/target/linux/ar71xx/files/arch/mips/ath79/mach-dir-600-a1.c
@@ -141,6 +141,14 @@ static void __init dir_600_a1_setup(void)
MIPS_MACHINE(ATH79_MACH_DIR_600_A1, "DIR-600-A1", "D-Link DIR-600 rev. A1",
dir_600_a1_setup);
+static void __init dir_615_e1_setup(void)
+{
+ dir_600_a1_setup();
+}
+
+MIPS_MACHINE(ATH79_MACH_DIR_615_E1, "DIR-615-E1", "D-Link DIR-615 rev. E1",
+ dir_615_e1_setup);
+
static void __init dir_615_e4_setup(void)
{
dir_600_a1_setup();
diff --git a/target/linux/ar71xx/generic/profiles/d-link.mk b/target/linux/ar71xx/generic/profiles/d-link.mk
index 98fe00f..9a8ab1b 100644
--- a/target/linux/ar71xx/generic/profiles/d-link.mk
+++ b/target/linux/ar71xx/generic/profiles/d-link.mk
@@ -38,6 +38,16 @@ endef
$(eval $(call Profile,DIR615C1))
+define Profile/DIR615E1
+ NAME:=D-Link DIR-615 rev. E1
+ PACKAGES:=
+endef
+
+define Profile/DIR615E1/Description
+ Package set optimized for the D-Link DIR-615 rev. E1.
+endef
+
+$(eval $(call Profile,DIR615E1))
define Profile/DIR615E4
NAME:=D-Link DIR-615 rev. E4
diff --git a/target/linux/ar71xx/image/Makefile b/target/linux/ar71xx/image/Makefile
index a055521..11ba068 100644
--- a/target/linux/ar71xx/image/Makefile
+++ b/target/linux/ar71xx/image/Makefile
@@ -804,6 +804,7 @@ $(eval $(call SingleProfile,AthLzma,$(fs_64k),PB92,pb92,PB92,ttyS0,115200,$$(pb9
$(eval $(call SingleProfile,Cameo7240,$(fs_64k),DIR600A1,dir-600-a1,DIR-600-A1,ttyS0,115200,"AP91-AR7240-RT-090223-00"))
$(eval $(call SingleProfile,Cameo7240,$(fs_64k),DIR601A1,dir-601-a1,DIR-600-A1,ttyS0,115200,"AP91-AR7240-RT-090223-02"))
+$(eval $(call SingleProfile,Cameo7240,$(fs_64k),DIR615E1,dir-615-e1,DIR-615-E1,ttyS0,115200,"AP93-AR7240-RT-081028-00"))
$(eval $(call SingleProfile,Cameo7240,$(fs_64k),DIR615E4,dir-615-e4,DIR-615-E4,ttyS0,115200,"AP99-AR7240-RT-091105-05"))
$(eval $(call SingleProfile,Cameo7240,$(fs_64k),FR54RTR,fr-54rtr,DIR-600-A1,ttyS0,115200,"AP91-AR7240-RT-090223-01"))
diff --git a/target/linux/ar71xx/patches-3.3/610-MIPS-ath79-openwrt-machines.patch b/target/linux/ar71xx/patches-3.3/610-MIPS-ath79-openwrt-machines.patch
index 6d67f5f..c7d0220 100644
--- a/target/linux/ar71xx/patches-3.3/610-MIPS-ath79-openwrt-machines.patch
+++ b/target/linux/ar71xx/patches-3.3/610-MIPS-ath79-openwrt-machines.patch
@@ -1,6 +1,6 @@
--- a/arch/mips/ath79/machtypes.h
+++ b/arch/mips/ath79/machtypes.h
-@@ -16,18 +16,104 @@
+@@ -16,18 +16,105 @@
enum ath79_mach_type {
ATH79_MACH_GENERIC = 0,
@@ -21,6 +21,7 @@
ATH79_MACH_PB44, /* Atheros PB44 reference board */
+ ATH79_MACH_DIR_600_A1, /* D-Link DIR-600 rev. A1 */
+ ATH79_MACH_DIR_615_C1, /* D-Link DIR-615 rev. C1 */
++ ATH79_MACH_DIR_615_E1, /* D-Link DIR-615 rev. E1 */
+ ATH79_MACH_DIR_615_E4, /* D-Link DIR-615 rev. E4 */
+ ATH79_MACH_DIR_825_B1, /* D-Link DIR-825 rev. B1 */
+ ATH79_MACH_EW_DORIN, /* embedded wireless Dorin Platform */
@@ -306,7 +307,7 @@
+ select MYLOADER
+
+config ATH79_MACH_DIR_600_A1
-+ bool "D-Link DIR-600 A1/DIR-615 E4 support"
++ bool "D-Link DIR-600 A1/DIR-615 E1/DIR-615 E4 support"
+ select SOC_AR724X
+ select ATH79_DEV_AP9X_PCI if PCI
+ select ATH79_DEV_ETH

View File

@ -1,19 +0,0 @@
From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Sat, 5 Jul 2014 22:30:34 +0200
Subject: iptables: avoid file conflicts due to unneeded libip6t_*.so in ip6tables package
diff --git a/package/iptables/Makefile b/package/iptables/Makefile
index e36a093..0c7a380 100644
--- a/package/iptables/Makefile
+++ b/package/iptables/Makefile
@@ -406,10 +406,6 @@ define Package/ip6tables/install
$(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/sbin/ip6tables $(1)/usr/sbin/
$(LN) ip6tables $(1)/usr/sbin/ip6tables-save
$(LN) ip6tables $(1)/usr/sbin/ip6tables-restore
- $(INSTALL_DIR) $(1)/usr/lib/iptables
- (cd $(PKG_INSTALL_DIR)/usr/lib/iptables ; \
- $(CP) libip6t_*.so $(1)/usr/lib/iptables/ \
- )
endef
define Package/libiptc/install

View File

@ -1,73 +0,0 @@
From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Thu, 24 Jul 2014 03:00:23 +0200
Subject: mac80211: add another ath9k patch
diff --git a/package/mac80211/patches/300-pending_work.patch b/package/mac80211/patches/300-pending_work.patch
index ba05bde..6197e0e 100644
--- a/package/mac80211/patches/300-pending_work.patch
+++ b/package/mac80211/patches/300-pending_work.patch
@@ -1,3 +1,21 @@
+commit ff354dbdd743e5fe186df8cd17982db19f78231a
+Author: Felix Fietkau <nbd@openwrt.org>
+Date: Wed Jul 23 15:33:26 2014 +0200
+
+ ath9k: fix aggregation session lockup
+
+ If an aggregation session fails, frames still end up in the driver queue
+ with IEEE80211_TX_CTL_AMPDU set.
+ This causes tx for the affected station/tid to stall, since
+ ath_tx_get_tid_subframe returning packets to send.
+
+ Fix this by clearing IEEE80211_TX_CTL_AMPDU as long as no aggregation
+ session is running.
+
+ Cc: stable@vger.kernel.org
+ Reported-by: Antonio Quartulli <antonio@open-mesh.com>
+ Signed-off-by: Felix Fietkau <nbd@openwrt.org>
+
commit 38695a6e5a940e6a524523b88a33916b016fb2a1
Author: Felix Fietkau <nbd@openwrt.org>
Date: Fri Jul 11 12:06:18 2014 +0200
@@ -2990,7 +3008,23 @@ Date: Mon May 19 21:20:49 2014 +0200
if (WARN_ON(--txq->pending_frames < 0))
txq->pending_frames = 0;
-@@ -1999,6 +1997,7 @@ static void setup_frame_info(struct ieee
+@@ -887,6 +885,15 @@ ath_tx_get_tid_subframe(struct ath_softc
+
+ tx_info = IEEE80211_SKB_CB(skb);
+ tx_info->flags &= ~IEEE80211_TX_CTL_CLEAR_PS_FILT;
++
++ /*
++ * No aggregation session is running, but there may be frames
++ * from a previous session or a failed attempt in the queue.
++ * Send them out as normal data frames
++ */
++ if (!tid->active)
++ tx_info->flags &= ~IEEE80211_TX_CTL_AMPDU;
++
+ if (!(tx_info->flags & IEEE80211_TX_CTL_AMPDU)) {
+ bf->bf_state.bf_type = 0;
+ return bf;
+@@ -1999,6 +2006,7 @@ static void setup_frame_info(struct ieee
an = (struct ath_node *) sta->drv_priv;
memset(fi, 0, sizeof(*fi));
@@ -2998,7 +3032,7 @@ Date: Mon May 19 21:20:49 2014 +0200
if (hw_key)
fi->keyix = hw_key->hw_key_idx;
else if (an && ieee80211_is_data(hdr->frame_control) && an->ps_key > 0)
-@@ -2150,6 +2149,7 @@ int ath_tx_start(struct ieee80211_hw *hw
+@@ -2150,6 +2158,7 @@ int ath_tx_start(struct ieee80211_hw *hw
struct ieee80211_tx_info *info = IEEE80211_SKB_CB(skb);
struct ieee80211_sta *sta = txctl->sta;
struct ieee80211_vif *vif = info->control.vif;
@@ -3006,7 +3040,7 @@ Date: Mon May 19 21:20:49 2014 +0200
struct ath_softc *sc = hw->priv;
struct ath_txq *txq = txctl->txq;
struct ath_atx_tid *tid = NULL;
-@@ -2170,11 +2170,13 @@ int ath_tx_start(struct ieee80211_hw *hw
+@@ -2170,11 +2179,13 @@ int ath_tx_start(struct ieee80211_hw *hw
q = skb_get_queue_mapping(skb);
ath_txq_lock(sc, txq);

View File

@ -1,30 +0,0 @@
From: Matthias Schiffer <mschiffer@universe-factory.net>
Date: Sat, 26 Jul 2014 17:03:40 +0200
Subject: Reduce fw3 log spam in netifd scripts
diff --git a/package/netifd/files/lib/netifd/dhcp.script b/package/netifd/files/lib/netifd/dhcp.script
index db3fc01..a7ce0d8 100755
--- a/package/netifd/files/lib/netifd/dhcp.script
+++ b/package/netifd/files/lib/netifd/dhcp.script
@@ -50,7 +50,7 @@ setup_interface () {
ip6rd="${ip6rd#* }"
local ip6rdbr="${ip6rd%% *}"
- [ -n "$ZONE" ] || ZONE=$(fw3 network $INTERFACE)
+ [ -n "$ZONE" ] || ZONE=$(fw3 network $INTERFACE 2>/dev/null)
[ -z "$IFACE6RD" -o "$IFACE6RD" = 1 ] && IFACE6RD=${INTERFACE}_6rd
json_init
diff --git a/package/odhcp6c/files/dhcpv6.script b/package/odhcp6c/files/dhcpv6.script
index 8c1ba18..146a966 100755
--- a/package/odhcp6c/files/dhcpv6.script
+++ b/package/odhcp6c/files/dhcpv6.script
@@ -97,7 +97,7 @@ setup_interface () {
MAPRULE="$LW4O6"
fi
- [ -n "$ZONE" ] || ZONE=$(fw3 network $INTERFACE)
+ [ -n "$ZONE" ] || ZONE=$(fw3 network $INTERFACE 2>/dev/null)
if [ "$IFACE_MAP" != 0 -a -n "$MAPTYPE" -a -n "$MAPRULE" ]; then
[ -z "$IFACE_MAP" -o "$IFACE_MAP" = 1 ] && IFACE_MAP=${INTERFACE}_map

File diff suppressed because it is too large Load Diff

View File

@ -1 +1 @@
d6597ebf6203328d3519ea3c3371a493 f2469bbdb9dd44754c52e799dc02ee7f

View File

@ -82,8 +82,8 @@ $(eval $(call GluonModel,UBNT,ubnt-unifi-outdoor-squashfs,ubiquiti-unifiap-outdo
## D-Link ## D-Link
# D-Link DIR-615 rev. E1 # D-Link DIR-615 rev. E1
$(eval $(call GluonProfile,DIR615E1)) #$(eval $(call GluonProfile,DIR615E1))
$(eval $(call GluonModel,DIR615E1,dir-615-e1-squashfs,d-link-dir-615-rev-e1)) #$(eval $(call GluonModel,DIR615E1,dir-615-e1-squashfs,d-link-dir-615-rev-e1))
# D-Link DIR-825 rev. B1 # D-Link DIR-825 rev. B1
$(eval $(call GluonProfile,DIR825B1)) $(eval $(call GluonProfile,DIR825B1))

View File

@ -1,5 +1,5 @@
$(eval $(call GluonTarget,ar71xx,generic)) $(eval $(call GluonTarget,ar71xx,generic))
ifeq ($(BROKEN),1) ifneq ($(BROKEN),)
$(eval $(call GluonTarget,x86,generic)) $(eval $(call GluonTarget,x86,generic))
endif endif

File diff suppressed because it is too large Load Diff

View File

@ -1 +1 @@
fa7af62e0ef1d529ecb7f7efccc706c3 142143844bfcd7ade9ea7e57dd843e69