Update OpenWrt base, packages and LuCI
This commit is contained in:
parent
c11f88397d
commit
d610ba31ff
6
modules
6
modules
@ -1,10 +1,10 @@
|
||||
GLUON_FEEDS='openwrt gluon routing luci'
|
||||
|
||||
OPENWRT_REPO=git://git.openwrt.org/15.05/openwrt.git
|
||||
OPENWRT_COMMIT=363508bcabd8e9205f5fffc8ff282439e61d618f
|
||||
OPENWRT_COMMIT=23395d539f4a45d8bed611e7f9c64275cd1cce0e
|
||||
|
||||
PACKAGES_OPENWRT_REPO=git://github.com/openwrt/packages.git
|
||||
PACKAGES_OPENWRT_COMMIT=f8a70fc188673d0ae8739b0a3095f7f61335fc10
|
||||
PACKAGES_OPENWRT_COMMIT=9622fe984bba3a4547f48bc507ebaba7637eb2b0
|
||||
PACKAGES_OPENWRT_BRANCH=for-15.05
|
||||
|
||||
PACKAGES_GLUON_REPO=git://github.com/freifunk-gluon/packages.git
|
||||
@ -15,5 +15,5 @@ PACKAGES_ROUTING_REPO=git://github.com/openwrt-routing/packages.git
|
||||
PACKAGES_ROUTING_COMMIT=ae65d4fe027592652376f8dbd3ff2ef37f5a84bc
|
||||
|
||||
PACKAGES_LUCI_REPO=git://github.com/openwrt/luci.git
|
||||
PACKAGES_LUCI_COMMIT=8832d534e96d3a934bd02711884371fc78a0d506
|
||||
PACKAGES_LUCI_COMMIT=cdcdfd2594634804ab09dc8105e46116edce0cd6
|
||||
PACKAGES_LUCI_BRANCH=for-15.05
|
||||
|
@ -0,0 +1,72 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Tue, 9 Feb 2016 18:22:29 +0100
|
||||
Subject: ath10k-firmware: add Candela Technologies firmware for QCA988X
|
||||
|
||||
diff --git a/package/firmware/ath10k-firmware/Makefile b/package/firmware/ath10k-firmware/Makefile
|
||||
index b03d644..7d4d449 100644
|
||||
--- a/package/firmware/ath10k-firmware/Makefile
|
||||
+++ b/package/firmware/ath10k-firmware/Makefile
|
||||
@@ -44,6 +44,26 @@ define Download/ath10k-firmware-qca988x
|
||||
endef
|
||||
$(eval $(call Download,ath10k-firmware-qca988x))
|
||||
|
||||
+
|
||||
+define Package/ath10k-firmware-qca988x-ct
|
||||
+$(Package/ath10k-firmware-default)
|
||||
+ TITLE:=ath10k firmware for QCA988x devices (Candela Technologies version)
|
||||
+ CONFLICTS:=ath10k-firmware-qca988x
|
||||
+endef
|
||||
+
|
||||
+QCA988X_CT_FIRMWARE_FILE:=firmware-5-ct-full-community.bin
|
||||
+
|
||||
+define Download/ath10k-firmware-qca988x-ct
|
||||
+ # See http://www.candelatech.com/ath10k.php
|
||||
+ #URL:=http://www.candelatech.com/downloads/ath10k-10-2/
|
||||
+ # Update to beta version (will switch back to official URL after v2 release)
|
||||
+ URL:=https://home.universe-factory.net/neoraider/
|
||||
+ FILE:=$(QCA988X_CT_FIRMWARE_FILE)
|
||||
+ MD5SUM:=9aa205cfd6b98e695ca8e9ae6d1bcb6b
|
||||
+endef
|
||||
+$(eval $(call Download,ath10k-firmware-qca988x-ct))
|
||||
+
|
||||
+
|
||||
define Package/ath10k-firmware-qca99x0
|
||||
$(Package/ath10k-firmware-default)
|
||||
TITLE:=ath10k firmware for QCA99x0 devices
|
||||
@@ -79,6 +99,16 @@ define Package/ath10k-firmware-qca988x/install
|
||||
$(1)/lib/firmware/ath10k/QCA988X/hw2.0/firmware-5.bin
|
||||
endef
|
||||
|
||||
+define Package/ath10k-firmware-qca988x-ct/install
|
||||
+ $(INSTALL_DIR) $(1)/lib/firmware/ath10k/QCA988X/hw2.0
|
||||
+ $(INSTALL_DATA) \
|
||||
+ $(PKG_BUILD_DIR)/QCA988X/board.bin \
|
||||
+ $(1)/lib/firmware/ath10k/QCA988X/hw2.0/
|
||||
+ $(INSTALL_DATA) \
|
||||
+ $(DL_DIR)/$(QCA988X_CT_FIRMWARE_FILE) \
|
||||
+ $(1)/lib/firmware/ath10k/QCA988X/hw2.0/firmware-5.bin
|
||||
+endef
|
||||
+
|
||||
define Package/ath10k-firmware-qca6174/install
|
||||
$(INSTALL_DIR) $(1)/lib/firmware/ath10k
|
||||
$(CP) $(PKG_BUILD_DIR)/QCA6174 $(1)/lib/firmware/ath10k/
|
||||
@@ -98,5 +128,6 @@ define Package/ath10k-firmware-qca99x0/install
|
||||
endef
|
||||
|
||||
$(eval $(call BuildPackage,ath10k-firmware-qca988x))
|
||||
+$(eval $(call BuildPackage,ath10k-firmware-qca988x-ct))
|
||||
$(eval $(call BuildPackage,ath10k-firmware-qca99x0))
|
||||
$(eval $(call BuildPackage,ath10k-firmware-qca6174))
|
||||
diff --git a/package/kernel/mac80211/Makefile b/package/kernel/mac80211/Makefile
|
||||
index 30da1cf..cd8d670 100644
|
||||
--- a/package/kernel/mac80211/Makefile
|
||||
+++ b/package/kernel/mac80211/Makefile
|
||||
@@ -247,7 +247,7 @@ define KernelPackage/ath10k
|
||||
$(call KernelPackage/mac80211/Default)
|
||||
TITLE:=Atheros 802.11ac wireless cards support
|
||||
URL:=https://wireless.wiki.kernel.org/en/users/Drivers/ath10k
|
||||
- DEPENDS+= @PCI_SUPPORT +kmod-ath +@DRIVER_11N_SUPPORT +@DRIVER_11W_SUPPORT +@KERNEL_RELAY +ath10k-firmware-qca988x
|
||||
+ DEPENDS+= @PCI_SUPPORT +kmod-ath +@DRIVER_11N_SUPPORT +@DRIVER_11W_SUPPORT +@KERNEL_RELAY
|
||||
FILES:= \
|
||||
$(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath10k/ath10k_core.ko \
|
||||
$(PKG_BUILD_DIR)/drivers/net/wireless/ath/ath10k/ath10k_pci.ko
|
File diff suppressed because it is too large
Load Diff
@ -1,39 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Sun, 21 Jun 2015 22:50:48 +0200
|
||||
Subject: ar71xx: add support for tp-link wr740n v5.0 (EU)
|
||||
|
||||
TP-Link ships wr740n v5.0 to Romania (so probably everywhere except
|
||||
China) with 4 MB flash and 32 MB memory (confirmed by their local
|
||||
support). This patch adds support for the v5.0 clone of v4, i just
|
||||
tested it on my own v5.0 router and it works.
|
||||
|
||||
Signed-off-by: Daniel Petre <daniel.petre@posteo.net>
|
||||
|
||||
diff --git a/target/linux/ar71xx/image/Makefile b/target/linux/ar71xx/image/Makefile
|
||||
index 013a215..37ce8a4 100644
|
||||
--- a/target/linux/ar71xx/image/Makefile
|
||||
+++ b/target/linux/ar71xx/image/Makefile
|
||||
@@ -501,6 +501,14 @@ define Device/tl-wr740n-v4
|
||||
CONSOLE := ttyATH0,115200
|
||||
endef
|
||||
|
||||
+define Device/tl-wr740n-v5
|
||||
+ $(Device/tplink-4mlzma)
|
||||
+ BOARDNAME := TL-WR741ND-v4
|
||||
+ DEVICE_PROFILE := TLWR740
|
||||
+ TPLINK_HWID := 0x07400005
|
||||
+ CONSOLE := ttyATH0,115200
|
||||
+endef
|
||||
+
|
||||
define Device/tl-wr741nd-v1
|
||||
$(Device/tplink-4m)
|
||||
BOARDNAME := TL-WR741ND
|
||||
@@ -530,7 +538,7 @@ define Device/tl-wr743nd-v2
|
||||
TPLINK_HWID := 0x07430002
|
||||
CONSOLE := ttyATH0,115200
|
||||
endef
|
||||
-TARGET_DEVICES += tl-wr740n-v4 tl-wr741nd-v1 tl-wr741nd-v2 tl-wr741nd-v4 tl-wr743nd-v2
|
||||
+TARGET_DEVICES += tl-wr740n-v4 tl-wr740n-v5 tl-wr741nd-v1 tl-wr741nd-v2 tl-wr741nd-v4 tl-wr743nd-v2
|
||||
|
||||
define Device/tl-wr841n-v8
|
||||
$(Device/tplink-4mlzma)
|
@ -1,35 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Sun, 21 Jun 2015 22:48:04 +0200
|
||||
Subject: ar71xx: add support for TL-WR741ND v5
|
||||
|
||||
This device is identical to the TL-WR740N v5, it even uses the same HWID (which
|
||||
wasn't the case for older TL-WR741ND revisions).
|
||||
|
||||
diff --git a/target/linux/ar71xx/image/Makefile b/target/linux/ar71xx/image/Makefile
|
||||
index 37ce8a4..8a25832 100644
|
||||
--- a/target/linux/ar71xx/image/Makefile
|
||||
+++ b/target/linux/ar71xx/image/Makefile
|
||||
@@ -531,6 +531,14 @@ define Device/tl-wr741nd-v4
|
||||
CONSOLE := ttyATH0,115200
|
||||
endef
|
||||
|
||||
+define Device/tl-wr741nd-v5
|
||||
+ $(Device/tplink-4mlzma)
|
||||
+ BOARDNAME := TL-WR741ND-v4
|
||||
+ DEVICE_PROFILE := TLWR741
|
||||
+ TPLINK_HWID := 0x07400005
|
||||
+ CONSOLE := ttyATH0,115200
|
||||
+endef
|
||||
+
|
||||
define Device/tl-wr743nd-v2
|
||||
$(Device/tplink-4mlzma)
|
||||
BOARDNAME := TL-WR741ND-v4
|
||||
@@ -538,7 +546,7 @@ define Device/tl-wr743nd-v2
|
||||
TPLINK_HWID := 0x07430002
|
||||
CONSOLE := ttyATH0,115200
|
||||
endef
|
||||
-TARGET_DEVICES += tl-wr740n-v4 tl-wr740n-v5 tl-wr741nd-v1 tl-wr741nd-v2 tl-wr741nd-v4 tl-wr743nd-v2
|
||||
+TARGET_DEVICES += tl-wr740n-v4 tl-wr740n-v5 tl-wr741nd-v1 tl-wr741nd-v2 tl-wr741nd-v4 tl-wr741nd-v5 tl-wr743nd-v2
|
||||
|
||||
define Device/tl-wr841n-v8
|
||||
$(Device/tplink-4mlzma)
|
@ -1,87 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Fri, 17 Jul 2015 20:51:23 +0200
|
||||
Subject: brcm2708: Implement sysupgrade
|
||||
|
||||
Implement sysupgrade for Raspberry Pi, similar to the way it is done on x86:
|
||||
The config files are saved in the boot partition and moved to where they are
|
||||
normally expected in preinit.
|
||||
|
||||
Also add optional gzip compression for the SD card image, since this can save
|
||||
a lot of space (76M vs 6M), also similar to x86.
|
||||
|
||||
Signed-off-by: Bruno Randolf <br1@einfach.org>
|
||||
|
||||
diff --git a/target/linux/brcm2708/Makefile b/target/linux/brcm2708/Makefile
|
||||
index 30f6e1d..015aa9c 100644
|
||||
--- a/target/linux/brcm2708/Makefile
|
||||
+++ b/target/linux/brcm2708/Makefile
|
||||
@@ -19,7 +19,7 @@ SUBTARGETS:=bcm2708 bcm2709
|
||||
KERNEL_PATCHVER:=3.18
|
||||
|
||||
include $(INCLUDE_DIR)/target.mk
|
||||
-DEFAULT_PACKAGES += brcm2708-gpu-fw kmod-usb-hid kmod-sound-core kmod-sound-arm-bcm2835
|
||||
+DEFAULT_PACKAGES += brcm2708-gpu-fw kmod-usb-hid kmod-sound-core kmod-sound-arm-bcm2835 kmod-fs-vfat kmod-nls-cp437 kmod-nls-iso8859-1
|
||||
|
||||
define Target/Description
|
||||
Build firmware image for Broadcom BCM2708/BCM2709 SoC devices.
|
||||
diff --git a/target/linux/brcm2708/base-files/lib/preinit/79_move_config b/target/linux/brcm2708/base-files/lib/preinit/79_move_config
|
||||
new file mode 100644
|
||||
index 0000000..7bcea7b
|
||||
--- /dev/null
|
||||
+++ b/target/linux/brcm2708/base-files/lib/preinit/79_move_config
|
||||
@@ -0,0 +1,18 @@
|
||||
+#!/bin/sh
|
||||
+# Copyright (C) 2015 OpenWrt.org
|
||||
+
|
||||
+BOOTPART=/dev/mmcblk0p1
|
||||
+
|
||||
+move_config() {
|
||||
+ if [ -b $BOOTPART ]; then
|
||||
+ insmod nls_cp437
|
||||
+ insmod nls_iso8859-1
|
||||
+ insmod fat
|
||||
+ insmod vfat
|
||||
+ mount -t vfat -o rw,noatime $BOOTPART /mnt
|
||||
+ [ -f /mnt/sysupgrade.tgz ] && mv -f /mnt/sysupgrade.tgz /
|
||||
+ umount /mnt
|
||||
+ fi
|
||||
+}
|
||||
+
|
||||
+boot_hook_add preinit_mount_root move_config
|
||||
diff --git a/target/linux/brcm2708/base-files/lib/upgrade/platform.sh b/target/linux/brcm2708/base-files/lib/upgrade/platform.sh
|
||||
new file mode 100644
|
||||
index 0000000..3e1ee00
|
||||
--- /dev/null
|
||||
+++ b/target/linux/brcm2708/base-files/lib/upgrade/platform.sh
|
||||
@@ -0,0 +1,17 @@
|
||||
+platform_check_image() {
|
||||
+ # i know no way to verify the image
|
||||
+ return 0;
|
||||
+}
|
||||
+
|
||||
+platform_do_upgrade() {
|
||||
+ sync
|
||||
+ get_image "$1" | dd of=/dev/mmcblk0 bs=2M conv=fsync
|
||||
+ sleep 1
|
||||
+}
|
||||
+
|
||||
+platform_copy_config() {
|
||||
+ mount -t vfat -o rw,noatime /dev/mmcblk0p1 /mnt
|
||||
+ cp -af "$CONF_TAR" /mnt/
|
||||
+ sync
|
||||
+ umount /mnt
|
||||
+}
|
||||
diff --git a/target/linux/brcm2708/image/Makefile b/target/linux/brcm2708/image/Makefile
|
||||
index e70bdd0..2c18baf 100644
|
||||
--- a/target/linux/brcm2708/image/Makefile
|
||||
+++ b/target/linux/brcm2708/image/Makefile
|
||||
@@ -28,6 +28,9 @@ define Image/Build/RaspberryPi
|
||||
mcopy -i $(KDIR)/boot.img $(KDIR)/Image ::kernel.img # Copy OpenWrt built kernel
|
||||
./gen_rpi_sdcard_img.sh $(BIN_DIR)/$(IMG_PREFIX)-sdcard-vfat-$(1).img $(KDIR)/boot.img $(KDIR)/root.$(1) \
|
||||
$(CONFIG_BRCM2708_SD_BOOT_PARTSIZE) $(CONFIG_TARGET_ROOTFS_PARTSIZE)
|
||||
+ ifneq ($(CONFIG_TARGET_IMAGES_GZIP),)
|
||||
+ gzip -f9n $(BIN_DIR)/$(IMG_PREFIX)-sdcard-vfat-$(1).img
|
||||
+ endif
|
||||
endef
|
||||
|
||||
define Image/Build
|
@ -1,131 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 16 Jul 2015 22:01:02 +0200
|
||||
Subject: sunxi: fix uboot install location
|
||||
|
||||
Install uboot files to KERNEL_BUILD_DIR instead of BIN_DIR to fix the
|
||||
ImageBuilder. Similar fixes are necessary for many (all?) other uboot
|
||||
targets.
|
||||
|
||||
Also remove the DTS copy command, BIN_DIR was unnecessarily cluttered with
|
||||
DTS files unrelated to the chosen profile.
|
||||
|
||||
diff --git a/package/boot/uboot-sunxi/Makefile b/package/boot/uboot-sunxi/Makefile
|
||||
index 14ba922..9032600 100644
|
||||
--- a/package/boot/uboot-sunxi/Makefile
|
||||
+++ b/package/boot/uboot-sunxi/Makefile
|
||||
@@ -6,6 +6,7 @@
|
||||
#
|
||||
|
||||
include $(TOPDIR)/rules.mk
|
||||
+include $(INCLUDE_DIR)/kernel.mk
|
||||
|
||||
PKG_NAME:=u-boot
|
||||
PKG_VERSION:=2015.01
|
||||
@@ -16,7 +17,7 @@ PKG_SOURCE_URL:= \
|
||||
|
||||
PKG_MD5SUM:=7f08dc9e98a71652bd6968888ed6ec95
|
||||
|
||||
-PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
|
||||
+PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/$(PKG_NAME)-$(BUILD_VARIANT)/$(PKG_NAME)-$(PKG_VERSION)
|
||||
|
||||
PKG_LICENSE:=GPL-2.0 GPL-2.0+
|
||||
PKG_LICENSE_FILES:=Licenses/README
|
||||
@@ -136,16 +137,16 @@ define Build/Compile
|
||||
endef
|
||||
|
||||
define Package/uboot/install/default
|
||||
- $(INSTALL_DIR) $(BIN_DIR)/uboot-$(BOARD)-$(1)
|
||||
$(CP) $(PKG_BUILD_DIR)/u-boot.bin \
|
||||
- $(BIN_DIR)/uboot-$(BOARD)-$(1)/openwrt-$(BOARD)-$(1)-u-boot.bin
|
||||
+ $(KERNEL_BUILD_DIR)/uboot-$(BOARD)-$(1)-u-boot.bin
|
||||
$(CP) $(PKG_BUILD_DIR)/spl/sunxi-spl.bin \
|
||||
- $(BIN_DIR)/uboot-$(BOARD)-$(1)/openwrt-$(BOARD)-$(1)-spl.bin
|
||||
+ $(KERNEL_BUILD_DIR)/uboot-$(BOARD)-$(1)-spl.bin
|
||||
$(CP) $(PKG_BUILD_DIR)/u-boot-sunxi-with-spl.bin \
|
||||
- $(BIN_DIR)/uboot-$(BOARD)-$(1)/openwrt-$(BOARD)-$(1)-u-boot-with-spl.bin
|
||||
+ $(KERNEL_BUILD_DIR)/uboot-$(BOARD)-$(1)-u-boot-with-spl.bin
|
||||
$(CP) uEnv.txt \
|
||||
- $(BIN_DIR)/uboot-$(BOARD)-$(1)/openwrt-$(BOARD)-$(1)-uEnv.txt
|
||||
- mkimage -C none -A arm -T script -d $(BIN_DIR)/uboot-$(BOARD)-$(1)/openwrt-$(BOARD)-$(1)-uEnv.txt $(BIN_DIR)/uboot-$(BOARD)-$(1)/openwrt-$(BOARD)-$(1)-boot.scr
|
||||
+ $(KERNEL_BUILD_DIR)/uboot-$(BOARD)-$(1)-uEnv.txt
|
||||
+ mkimage -C none -A arm -T script -d $(KERNEL_BUILD_DIR)/uboot-$(BOARD)-$(1)-uEnv.txt \
|
||||
+ $(KERNEL_BUILD_DIR)/uboot-$(BOARD)-$(1)-boot.scr
|
||||
endef
|
||||
|
||||
define Package/uboot/install/template
|
||||
diff --git a/target/linux/sunxi/image/Makefile b/target/linux/sunxi/image/Makefile
|
||||
index 6fcd61f..19ab935 100644
|
||||
--- a/target/linux/sunxi/image/Makefile
|
||||
+++ b/target/linux/sunxi/image/Makefile
|
||||
@@ -11,28 +11,12 @@ include $(INCLUDE_DIR)/host.mk
|
||||
FAT32_BLOCK_SIZE=1024
|
||||
FAT32_BLOCKS=$(shell echo $$(($(CONFIG_SUNXI_SD_BOOT_PARTSIZE)*1024*1024/$(FAT32_BLOCK_SIZE))))
|
||||
|
||||
-BOARDS:= \
|
||||
- sun4i-a10-cubieboard \
|
||||
- sun4i-a10-olinuxino-lime \
|
||||
- sun4i-a10-pcduino \
|
||||
- sun5i-a13-olinuxino \
|
||||
- sun6i-a31-colombus \
|
||||
- sun6i-a31-m9 \
|
||||
- sun7i-a20-bananapi \
|
||||
- sun7i-a20-bananapro \
|
||||
- sun7i-a20-cubieboard2 \
|
||||
- sun7i-a20-cubietruck \
|
||||
- sun7i-a20-olinuxino-lime \
|
||||
- sun7i-a20-olinuxino-micro \
|
||||
- sun7i-a20-pcduino3 \
|
||||
- sun7i-a20-lamobo-r1
|
||||
-
|
||||
define Image/BuildKernel
|
||||
mkimage -A arm -O linux -T kernel -C none \
|
||||
-a 0x40008000 -e 0x40008000 \
|
||||
-n 'ARM OpenWrt Linux-$(LINUX_VERSION)' \
|
||||
-d $(KDIR)/zImage $(BIN_DIR)/$(IMG_PREFIX)-uImage
|
||||
-
|
||||
+
|
||||
ifneq ($(CONFIG_TARGET_ROOTFS_INITRAMFS),)
|
||||
$(CP) $(KDIR)/zImage-initramfs $(BIN_DIR)/$(IMG_PREFIX)-zImage-initramfs
|
||||
echo -ne '\x00\x00\x00\x00' >> $(BIN_DIR)/$(IMG_PREFIX)-zImage-initramfs
|
||||
@@ -42,27 +26,23 @@ define Image/BuildKernel
|
||||
$(BIN_DIR)/$(IMG_PREFIX)-uImage-initramfs \
|
||||
)
|
||||
endif
|
||||
-
|
||||
- $(foreach board,$(BOARDS),
|
||||
- $(CP) $(DTS_DIR)/$(board).dtb $(BIN_DIR)/
|
||||
- )
|
||||
endef
|
||||
|
||||
define Image/Build/SDCard
|
||||
rm -f $(KDIR)/boot.img
|
||||
mkdosfs $(KDIR)/boot.img -C $(FAT32_BLOCKS)
|
||||
-
|
||||
- mcopy -i $(KDIR)/boot.img $(BIN_DIR)/uboot-sunxi-$(PROFILE)/$(IMG_PREFIX)-$(PROFILE)-boot.scr ::boot.scr
|
||||
- mcopy -i $(KDIR)/boot.img $(BIN_DIR)/$(2).dtb ::dtb
|
||||
+
|
||||
+ mcopy -i $(KDIR)/boot.img $(KDIR)/uboot-sunxi-$(PROFILE)-boot.scr ::boot.scr
|
||||
+ mcopy -i $(KDIR)/boot.img $(DTS_DIR)/$(2).dtb ::dtb
|
||||
mcopy -i $(KDIR)/boot.img $(BIN_DIR)/$(IMG_PREFIX)-uImage ::uImage
|
||||
-
|
||||
+
|
||||
./gen_sunxi_sdcard_img.sh \
|
||||
$(BIN_DIR)/$(IMG_PREFIX)-$(PROFILE)-sdcard-vfat-$(1).img \
|
||||
$(KDIR)/boot.img \
|
||||
$(KDIR)/root.$(1) \
|
||||
$(CONFIG_SUNXI_SD_BOOT_PARTSIZE) \
|
||||
$(CONFIG_TARGET_ROOTFS_PARTSIZE) \
|
||||
- $(BIN_DIR)/uboot-sunxi-$(PROFILE)/$(IMG_PREFIX)-$(PROFILE)-u-boot-with-spl.bin
|
||||
+ $(KDIR)/uboot-sunxi-$(PROFILE)-u-boot-with-spl.bin
|
||||
endef
|
||||
|
||||
define Image/Build/Profile/A10-OLinuXino-Lime
|
||||
@@ -124,7 +104,7 @@ endef
|
||||
define Image/Build
|
||||
$(call Image/Build/$(1),$(1))
|
||||
$(call Image/Build/Profile/$(PROFILE),$(1))
|
||||
-
|
||||
+
|
||||
dd if=$(KDIR)/root.$(1) of=$(BIN_DIR)/$(IMG_PREFIX)-root.$(1) bs=128k conv=sync
|
||||
endef
|
||||
|
@ -1,21 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 16 Jul 2015 22:13:59 +0200
|
||||
Subject: sunxi: respect CONFIG_TARGET_IMAGES_GZIP
|
||||
|
||||
The ext4 images are huge uncompressed.
|
||||
|
||||
diff --git a/target/linux/sunxi/image/Makefile b/target/linux/sunxi/image/Makefile
|
||||
index 19ab935..d3f4409 100644
|
||||
--- a/target/linux/sunxi/image/Makefile
|
||||
+++ b/target/linux/sunxi/image/Makefile
|
||||
@@ -43,6 +43,10 @@ define Image/Build/SDCard
|
||||
$(CONFIG_SUNXI_SD_BOOT_PARTSIZE) \
|
||||
$(CONFIG_TARGET_ROOTFS_PARTSIZE) \
|
||||
$(KDIR)/uboot-sunxi-$(PROFILE)-u-boot-with-spl.bin
|
||||
+
|
||||
+ ifneq ($(CONFIG_TARGET_IMAGES_GZIP),)
|
||||
+ gzip -f9n $(BIN_DIR)/$(IMG_PREFIX)-$(PROFILE)-sdcard-vfat-$(1).img
|
||||
+ endif
|
||||
endef
|
||||
|
||||
define Image/Build/Profile/A10-OLinuXino-Lime
|
@ -1,62 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Sat, 18 Jul 2015 17:13:23 +0200
|
||||
Subject: odhcp6c: add option "sourcefilter" to disable source filter
|
||||
|
||||
Signed-off-by: Steven Barth <steven@midlink.org>
|
||||
|
||||
diff --git a/package/network/ipv6/odhcp6c/Makefile b/package/network/ipv6/odhcp6c/Makefile
|
||||
index 5bf43bd..75de54c 100644
|
||||
--- a/package/network/ipv6/odhcp6c/Makefile
|
||||
+++ b/package/network/ipv6/odhcp6c/Makefile
|
||||
@@ -8,7 +8,7 @@
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=odhcp6c
|
||||
-PKG_VERSION:=2015-07-13
|
||||
+PKG_VERSION:=2015-07-18
|
||||
PKG_RELEASE=$(PKG_SOURCE_VERSION)
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
||||
diff --git a/package/network/ipv6/odhcp6c/files/dhcpv6.script b/package/network/ipv6/odhcp6c/files/dhcpv6.script
|
||||
index b8cbddb..33f6d9b 100755
|
||||
--- a/package/network/ipv6/odhcp6c/files/dhcpv6.script
|
||||
+++ b/package/network/ipv6/odhcp6c/files/dhcpv6.script
|
||||
@@ -76,7 +76,7 @@ setup_interface () {
|
||||
done
|
||||
|
||||
for entry in $RA_ROUTES; do
|
||||
- local duplicate=0
|
||||
+ local duplicate=$NOSOURCEFILTER
|
||||
local addr="${entry%%/*}"
|
||||
entry="${entry#*/}"
|
||||
local mask="${entry%%,*}"
|
||||
diff --git a/package/network/ipv6/odhcp6c/files/dhcpv6.sh b/package/network/ipv6/odhcp6c/files/dhcpv6.sh
|
||||
index adcb100..4a453fd 100755
|
||||
--- a/package/network/ipv6/odhcp6c/files/dhcpv6.sh
|
||||
+++ b/package/network/ipv6/odhcp6c/files/dhcpv6.sh
|
||||
@@ -28,14 +28,15 @@ proto_dhcpv6_init_config() {
|
||||
proto_config_add_boolean delegate
|
||||
proto_config_add_int "soltimeout"
|
||||
proto_config_add_boolean fakeroutes
|
||||
+ proto_config_add_boolean sourcefilter
|
||||
}
|
||||
|
||||
proto_dhcpv6_setup() {
|
||||
local config="$1"
|
||||
local iface="$2"
|
||||
|
||||
- local reqaddress reqprefix clientid reqopts noslaaconly forceprefix norelease ip6prefix iface_dslite iface_map iface_464xlat ifaceid userclass vendorclass delegate zone_dslite zone_map zone_464xlat zone soltimeout fakeroutes
|
||||
- json_get_vars reqaddress reqprefix clientid reqopts noslaaconly forceprefix norelease ip6prefix iface_dslite iface_map iface_464xlat ifaceid userclass vendorclass delegate zone_dslite zone_map zone_464xlat zone soltimeout fakeroutes
|
||||
+ local reqaddress reqprefix clientid reqopts noslaaconly forceprefix norelease ip6prefix iface_dslite iface_map iface_464xlat ifaceid userclass vendorclass delegate zone_dslite zone_map zone_464xlat zone soltimeout fakeroutes sourcefilter
|
||||
+ json_get_vars reqaddress reqprefix clientid reqopts noslaaconly forceprefix norelease ip6prefix iface_dslite iface_map iface_464xlat ifaceid userclass vendorclass delegate zone_dslite zone_map zone_464xlat zone soltimeout fakeroutes sourcefilter
|
||||
|
||||
|
||||
# Configure
|
||||
@@ -76,6 +77,7 @@ proto_dhcpv6_setup() {
|
||||
[ -n "$zone_464xlat" ] && proto_export "ZONE_464XLAT=$zone_464xlat"
|
||||
[ -n "$zone" ] && proto_export "ZONE=$zone"
|
||||
[ "$fakeroutes" != "0" ] && proto_export "FAKE_ROUTES=1"
|
||||
+ [ "$sourcefilter" = "0" ] && proto_export "NOSOURCEFILTER=1"
|
||||
|
||||
proto_export "INTERFACE=$config"
|
||||
proto_run_command "$config" odhcp6c \
|
@ -1,26 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 23 Jul 2015 01:31:05 +0200
|
||||
Subject: ar71xx: fix wndr3700_board_detect for some NETGEAR WNDR3700v2
|
||||
|
||||
There are a few NETGEAR devices which don't terminate the model name in the
|
||||
ART with a NUL byte, at least some NETGEAR WNDR3700v2. The current awk
|
||||
expression doesn't match 0xFF bytes, so AR71XX_MODEL contains lots of
|
||||
trailing 0xFF garbage in this case.
|
||||
|
||||
Fix this by matching for the first non-printable character and explicitly
|
||||
setting LC_CTYPE=C (probably not strictly necessary on OpenWrt, but will
|
||||
definitely work like this, even when awk supports locales and LANG is set).
|
||||
|
||||
diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
index 839abc7..af92b01 100755
|
||||
--- a/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
+++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
@@ -38,7 +38,7 @@ wndr3700_board_detect() {
|
||||
;;
|
||||
"33373031")
|
||||
# Use awk to remove everything after the first zero byte
|
||||
- model="$(ar71xx_get_mtd_offset_size_format art 41 32 %c | awk 'BEGIN{FS="[[:cntrl:]]"} {print $1; exit}')"
|
||||
+ model="$(ar71xx_get_mtd_offset_size_format art 41 32 %c | LC_CTYPE=C awk -v 'FS=[^[:print:]]' '{print $1; exit}')"
|
||||
case $model in
|
||||
$'\xff'*)
|
||||
if [ "${model:24:1}" = 'N' ]; then
|
@ -1,47 +0,0 @@
|
||||
From: Nils Schneider <nils@nilsschneider.net>
|
||||
Date: Fri, 24 Jul 2015 21:52:12 +0200
|
||||
Subject: mac80211: set mcast-rate for mesh point interfaces
|
||||
|
||||
In order to set the multicast rate for mesh point interfaces the "mesh join"
|
||||
was made explicit and moved to mac80211_setup_vif(), similar to how it is
|
||||
done for IBSS interfaces.
|
||||
|
||||
Previously, the mesh join was made implicit in case authentication (i.e.
|
||||
$key) was not used when creating the interface in mac80211_prepare_vif(),
|
||||
while using authentication would create the interface first, then join
|
||||
later in mac80211_setup_vif() by starting authsae.
|
||||
|
||||
Signed-off-by: Nils Schneider <nils@nilsschneider.net>
|
||||
|
||||
diff --git a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
|
||||
index 2a8d2f9..8d31a80 100644
|
||||
--- a/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
|
||||
+++ b/package/kernel/mac80211/files/lib/netifd/wireless/mac80211.sh
|
||||
@@ -455,12 +455,7 @@ mac80211_prepare_vif() {
|
||||
}
|
||||
;;
|
||||
mesh)
|
||||
- json_get_vars key mesh_id
|
||||
- if [ -n "$key" ]; then
|
||||
- iw phy "$phy" interface add "$ifname" type mp
|
||||
- else
|
||||
- iw phy "$phy" interface add "$ifname" type mp mesh_id "$mesh_id"
|
||||
- fi
|
||||
+ iw phy "$phy" interface add "$ifname" type mp
|
||||
;;
|
||||
monitor)
|
||||
iw phy "$phy" interface add "$ifname" type monitor
|
||||
@@ -603,6 +598,13 @@ mac80211_setup_vif() {
|
||||
wireless_vif_parse_encryption
|
||||
mac80211_setup_supplicant || failed=1
|
||||
fi
|
||||
+ else
|
||||
+ json_get_vars mesh_id mcast_rate
|
||||
+
|
||||
+ mcval=
|
||||
+ [ -n "$mcast_rate" ] && wpa_supplicant_add_rate mcval "$mcast_rate"
|
||||
+
|
||||
+ iw dev "$ifname" mesh join "$mesh_id" ${mcval:+mcast-rate $mcval}
|
||||
fi
|
||||
|
||||
for var in $MP_CONFIG_INT $MP_CONFIG_BOOL $MP_CONFIG_STRING; do
|
@ -1,57 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 6 Aug 2015 03:01:38 +0200
|
||||
Subject: ar71xx: fix ethernet initialization on QCA953x-based boards (TP-Link TL-WR841N/ND v9, Compex WPJ531)
|
||||
|
||||
The initialization routines for these boards were relying on some (wrong)
|
||||
defaults for the QCA953x ethernet. Make these defaults explicit to prevent
|
||||
breaking them when the QCA953x defaults are fixed.
|
||||
|
||||
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
|
||||
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
|
||||
index c28afc6..3e5c2a2 100644
|
||||
--- 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
|
||||
@@ -109,12 +109,18 @@ static void __init tl_ap143_setup(void)
|
||||
ath79_register_mdio(0, 0x0);
|
||||
|
||||
/* LAN */
|
||||
+ ath79_eth1_data.phy_if_mode = PHY_INTERFACE_MODE_GMII;
|
||||
+ ath79_eth1_data.duplex = DUPLEX_FULL;
|
||||
+ ath79_switch_data.phy_poll_mask |= BIT(4);
|
||||
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_eth0_data.duplex = DUPLEX_FULL;
|
||||
+ ath79_eth0_data.speed = SPEED_100;
|
||||
+ ath79_eth0_data.phy_mask = BIT(4);
|
||||
ath79_init_mac(ath79_eth0_data.mac_addr, mac, 1);
|
||||
ath79_register_eth(0);
|
||||
|
||||
diff --git a/target/linux/ar71xx/files/arch/mips/ath79/mach-wpj531.c b/target/linux/ar71xx/files/arch/mips/ath79/mach-wpj531.c
|
||||
index bc13d70..e665a2e 100644
|
||||
--- a/target/linux/ar71xx/files/arch/mips/ath79/mach-wpj531.c
|
||||
+++ b/target/linux/ar71xx/files/arch/mips/ath79/mach-wpj531.c
|
||||
@@ -105,12 +105,19 @@ static void __init common_setup(void)
|
||||
ath79_register_mdio(0, 0x0);
|
||||
|
||||
/* LAN */
|
||||
+ ath79_eth0_data.duplex = DUPLEX_FULL;
|
||||
+ ath79_eth0_data.phy_if_mode = PHY_INTERFACE_MODE_MII;
|
||||
+ ath79_eth0_data.speed = SPEED_100;
|
||||
+ ath79_eth0_data.phy_mask = BIT(4);
|
||||
ath79_init_mac(ath79_eth0_data.mac_addr, mac, 0);
|
||||
ath79_register_eth(0);
|
||||
|
||||
/* WAN */
|
||||
ath79_switch_data.phy4_mii_en = 1;
|
||||
+ ath79_eth1_data.duplex = DUPLEX_FULL;
|
||||
ath79_eth1_data.phy_if_mode = PHY_INTERFACE_MODE_MII;
|
||||
+ ath79_eth1_data.speed = SPEED_100;
|
||||
+ ath79_switch_data.phy_poll_mask |= BIT(4);
|
||||
ath79_init_mac(ath79_eth1_data.mac_addr, mac, 1);
|
||||
ath79_register_eth(1);
|
||||
|
@ -1,909 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 6 Aug 2015 03:01:47 +0200
|
||||
Subject: ar71xx: rework patch for qca953x/956x
|
||||
|
||||
Patch cherry-picked from the following location:
|
||||
https://www.codeaurora.org/cgit/quic/qsdk/oss/system/openwrt/commit/?h=release/coconut_ioe4531_2.0&id=5c357bf6c763e4140dddcc9a3bc5f005525a9c0e
|
||||
|
||||
Changelist,
|
||||
- add more register defines
|
||||
- add EHCI support
|
||||
- fix GPIO pin count to 18
|
||||
- fix chained irq disabled
|
||||
- fix GMAC0/GMAC1 initial
|
||||
- fix WMAC irq number to 47
|
||||
- merge the changes of dev-eth.c from the patch to file.
|
||||
|
||||
Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org>
|
||||
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
|
||||
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 ae3db4c..ff94e2e 100644
|
||||
--- a/target/linux/ar71xx/files/arch/mips/ath79/dev-eth.c
|
||||
+++ b/target/linux/ar71xx/files/arch/mips/ath79/dev-eth.c
|
||||
@@ -198,6 +198,8 @@ void __init ath79_register_mdio(unsigned int id, u32 phy_mask)
|
||||
case ATH79_SOC_AR9330:
|
||||
case ATH79_SOC_AR9331:
|
||||
case ATH79_SOC_QCA9533:
|
||||
+ case ATH79_SOC_QCA9561:
|
||||
+ case ATH79_SOC_TP9343:
|
||||
mdio_dev = &ath79_mdio1_device;
|
||||
mdio_data = &ath79_mdio1_data;
|
||||
break;
|
||||
@@ -256,6 +258,8 @@ void __init ath79_register_mdio(unsigned int id, u32 phy_mask)
|
||||
break;
|
||||
|
||||
case ATH79_SOC_QCA9533:
|
||||
+ case ATH79_SOC_QCA9561:
|
||||
+ case ATH79_SOC_TP9343:
|
||||
mdio_data->builtin_switch = 1;
|
||||
break;
|
||||
|
||||
@@ -571,6 +575,8 @@ static void __init ath79_init_eth_pll_data(unsigned int id)
|
||||
case ATH79_SOC_QCA9533:
|
||||
case ATH79_SOC_QCA9556:
|
||||
case ATH79_SOC_QCA9558:
|
||||
+ case ATH79_SOC_QCA9561:
|
||||
+ case ATH79_SOC_TP9343:
|
||||
pll_10 = AR934X_PLL_VAL_10;
|
||||
pll_100 = AR934X_PLL_VAL_100;
|
||||
pll_1000 = AR934X_PLL_VAL_1000;
|
||||
@@ -627,6 +633,8 @@ static int __init ath79_setup_phy_if_mode(unsigned int id,
|
||||
case ATH79_SOC_AR9330:
|
||||
case ATH79_SOC_AR9331:
|
||||
case ATH79_SOC_QCA9533:
|
||||
+ case ATH79_SOC_QCA9561:
|
||||
+ case ATH79_SOC_TP9343:
|
||||
pdata->phy_if_mode = PHY_INTERFACE_MODE_MII;
|
||||
break;
|
||||
|
||||
@@ -687,7 +695,8 @@ 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:
|
||||
+ case ATH79_SOC_QCA9561:
|
||||
+ case ATH79_SOC_TP9343:
|
||||
pdata->phy_if_mode = PHY_INTERFACE_MODE_GMII;
|
||||
break;
|
||||
|
||||
@@ -697,6 +706,7 @@ static int __init ath79_setup_phy_if_mode(unsigned int id,
|
||||
case ATH79_SOC_AR9341:
|
||||
case ATH79_SOC_AR9342:
|
||||
case ATH79_SOC_AR9344:
|
||||
+ case ATH79_SOC_QCA9533:
|
||||
switch (pdata->phy_if_mode) {
|
||||
case PHY_INTERFACE_MODE_MII:
|
||||
case PHY_INTERFACE_MODE_GMII:
|
||||
@@ -986,6 +996,7 @@ void __init ath79_register_eth(unsigned int id)
|
||||
case ATH79_SOC_AR9341:
|
||||
case ATH79_SOC_AR9342:
|
||||
case ATH79_SOC_AR9344:
|
||||
+ case ATH79_SOC_QCA9533:
|
||||
if (id == 0) {
|
||||
pdata->reset_bit = AR934X_RESET_GE0_MAC |
|
||||
AR934X_RESET_GE0_MDIO;
|
||||
@@ -1017,7 +1028,8 @@ void __init ath79_register_eth(unsigned int id)
|
||||
pdata->fifo_cfg3 = 0x01f00140;
|
||||
break;
|
||||
|
||||
- case ATH79_SOC_QCA9533:
|
||||
+ case ATH79_SOC_QCA9561:
|
||||
+ case ATH79_SOC_TP9343:
|
||||
if (id == 0) {
|
||||
pdata->reset_bit = AR933X_RESET_GE0_MAC |
|
||||
AR933X_RESET_GE0_MDIO;
|
||||
@@ -1123,6 +1135,8 @@ void __init ath79_register_eth(unsigned int id)
|
||||
case ATH79_SOC_AR9330:
|
||||
case ATH79_SOC_AR9331:
|
||||
case ATH79_SOC_QCA9533:
|
||||
+ case ATH79_SOC_QCA9561:
|
||||
+ case ATH79_SOC_TP9343:
|
||||
pdata->mii_bus_dev = &ath79_mdio1_device.dev;
|
||||
break;
|
||||
|
||||
diff --git a/target/linux/ar71xx/patches-3.18/707-MIPS-ath79-add-support-for-QCA953x-SoC.patch b/target/linux/ar71xx/patches-3.18/707-MIPS-ath79-add-support-for-QCA953x-SoC.patch
|
||||
index 5041619..403897a 100644
|
||||
--- a/target/linux/ar71xx/patches-3.18/707-MIPS-ath79-add-support-for-QCA953x-SoC.patch
|
||||
+++ b/target/linux/ar71xx/patches-3.18/707-MIPS-ath79-add-support-for-QCA953x-SoC.patch
|
||||
@@ -44,7 +44,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
config ATH79_NVRAM
|
||||
--- a/arch/mips/ath79/clock.c
|
||||
+++ b/arch/mips/ath79/clock.c
|
||||
-@@ -350,6 +350,91 @@ static void __init ar934x_clocks_init(vo
|
||||
+@@ -350,6 +350,91 @@ static void __init ar934x_clocks_init(void)
|
||||
iounmap(dpll_base);
|
||||
}
|
||||
|
||||
@@ -175,6 +175,48 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
soc_is_qca955x()) {
|
||||
ath79_uart_data[0].uartclk = uart_clk_rate;
|
||||
platform_device_register(&ath79_uart_device);
|
||||
+--- a/arch/mips/ath79/dev-usb.c
|
||||
++++ b/arch/mips/ath79/dev-usb.c
|
||||
+@@ -236,6 +236,30 @@ static void __init ar934x_usb_setup(void)
|
||||
+ &ath79_ehci_pdata_v2, sizeof(ath79_ehci_pdata_v2));
|
||||
+ }
|
||||
+
|
||||
++static void __init qca953x_usb_setup(void)
|
||||
++{
|
||||
++ u32 bootstrap;
|
||||
++
|
||||
++ bootstrap = ath79_reset_rr(QCA953X_RESET_REG_BOOTSTRAP);
|
||||
++
|
||||
++ ath79_device_reset_set(QCA953X_RESET_USBSUS_OVERRIDE);
|
||||
++ udelay(1000);
|
||||
++
|
||||
++ ath79_device_reset_clear(QCA953X_RESET_USB_PHY);
|
||||
++ udelay(1000);
|
||||
++
|
||||
++ ath79_device_reset_clear(QCA953X_RESET_USB_PHY_ANALOG);
|
||||
++ udelay(1000);
|
||||
++
|
||||
++ ath79_device_reset_clear(QCA953X_RESET_USB_HOST);
|
||||
++ udelay(1000);
|
||||
++
|
||||
++ ath79_usb_register("ehci-platform", -1,
|
||||
++ QCA953X_EHCI_BASE, QCA953X_EHCI_SIZE,
|
||||
++ ATH79_CPU_IRQ(3),
|
||||
++ &ath79_ehci_pdata_v2, sizeof(ath79_ehci_pdata_v2));
|
||||
++}
|
||||
++
|
||||
+ static void qca955x_usb_reset_notifier(struct platform_device *pdev)
|
||||
+ {
|
||||
+ u32 base;
|
||||
+@@ -286,6 +310,8 @@ void __init ath79_register_usb(void)
|
||||
+ ar933x_usb_setup();
|
||||
+ else if (soc_is_ar934x())
|
||||
+ ar934x_usb_setup();
|
||||
++ else if (soc_is_qca953x())
|
||||
++ qca953x_usb_setup();
|
||||
+ else if (soc_is_qca955x())
|
||||
+ qca955x_usb_setup();
|
||||
+ else
|
||||
--- a/arch/mips/ath79/dev-wmac.c
|
||||
+++ b/arch/mips/ath79/dev-wmac.c
|
||||
@@ -101,7 +101,7 @@ static int ar933x_wmac_reset(void)
|
||||
@@ -186,7 +228,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
{
|
||||
return ath79_soc_rev;
|
||||
}
|
||||
-@@ -126,7 +126,7 @@ static void __init ar933x_wmac_setup(voi
|
||||
+@@ -126,7 +126,7 @@ static void __init ar933x_wmac_setup(void)
|
||||
ath79_wmac_data.is_clk_25mhz = true;
|
||||
|
||||
if (ath79_soc_rev == 1)
|
||||
@@ -195,8 +237,8 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
|
||||
ath79_wmac_data.external_reset = ar933x_wmac_reset;
|
||||
}
|
||||
-@@ -149,6 +149,26 @@ static void ar934x_wmac_setup(void)
|
||||
- ath79_wmac_data.is_clk_25mhz = true;
|
||||
+@@ -151,6 +151,26 @@ static void ar934x_wmac_setup(void)
|
||||
+ ath79_wmac_data.get_mac_revision = ar93xx_get_soc_revision;
|
||||
}
|
||||
|
||||
+static void qca953x_wmac_setup(void)
|
||||
@@ -207,8 +249,8 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
+
|
||||
+ 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(2);
|
||||
-+ ath79_wmac_resources[1].end = ATH79_CPU_IRQ(2);
|
||||
++ ath79_wmac_resources[1].start = ATH79_IP2_IRQ(1);
|
||||
++ ath79_wmac_resources[1].end = ATH79_IP2_IRQ(1);
|
||||
+
|
||||
+ t = ath79_reset_rr(QCA953X_RESET_REG_BOOTSTRAP);
|
||||
+ if (t & QCA953X_BOOTSTRAP_REF_CLK_40)
|
||||
@@ -222,7 +264,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
static void qca955x_wmac_setup(void)
|
||||
{
|
||||
u32 t;
|
||||
-@@ -366,6 +386,8 @@ void __init ath79_register_wmac(u8 *cal_
|
||||
+@@ -368,6 +388,8 @@ void __init ath79_register_wmac(u8 *cal_data, u8 *mac_addr)
|
||||
ar933x_wmac_setup();
|
||||
else if (soc_is_ar934x())
|
||||
ar934x_wmac_setup();
|
||||
@@ -244,6 +286,24 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
_prom_putchar = prom_putchar_ar71xx;
|
||||
--- a/arch/mips/ath79/gpio.c
|
||||
+++ b/arch/mips/ath79/gpio.c
|
||||
+@@ -148,7 +148,7 @@ static void __iomem *ath79_gpio_get_function_reg(void)
|
||||
+ soc_is_ar913x() ||
|
||||
+ soc_is_ar933x())
|
||||
+ reg = AR71XX_GPIO_REG_FUNC;
|
||||
+- else if (soc_is_ar934x())
|
||||
++ else if (soc_is_ar934x() || soc_is_qca953x())
|
||||
+ reg = AR934X_GPIO_REG_FUNC;
|
||||
+ else
|
||||
+ BUG();
|
||||
+@@ -187,7 +187,7 @@ void __init ath79_gpio_output_select(unsigned gpio, u8 val)
|
||||
+ unsigned int reg;
|
||||
+ u32 t, s;
|
||||
+
|
||||
+- BUG_ON(!soc_is_ar934x());
|
||||
++ BUG_ON(!soc_is_ar934x() && !soc_is_qca953x());
|
||||
+
|
||||
+ if (gpio >= AR934X_GPIO_COUNT)
|
||||
+ return;
|
||||
@@ -224,6 +224,8 @@ void __init ath79_gpio_init(void)
|
||||
ath79_gpio_count = AR933X_GPIO_COUNT;
|
||||
else if (soc_is_ar934x())
|
||||
@@ -264,7 +324,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
}
|
||||
--- a/arch/mips/ath79/irq.c
|
||||
+++ b/arch/mips/ath79/irq.c
|
||||
-@@ -106,6 +106,7 @@ static void __init ath79_misc_irq_init(v
|
||||
+@@ -106,6 +106,7 @@ static void __init ath79_misc_irq_init(void)
|
||||
else if (soc_is_ar724x() ||
|
||||
soc_is_ar933x() ||
|
||||
soc_is_ar934x() ||
|
||||
@@ -272,19 +332,80 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
soc_is_qca955x())
|
||||
ath79_misc_irq_chip.irq_ack = ar724x_misc_irq_ack;
|
||||
else
|
||||
-@@ -352,6 +353,9 @@ void __init arch_init_irq(void)
|
||||
+@@ -153,6 +154,38 @@ static void ar934x_ip2_irq_init(void)
|
||||
+ irq_set_chained_handler(ATH79_CPU_IRQ(2), ar934x_ip2_irq_dispatch);
|
||||
+ }
|
||||
+
|
||||
++static void qca953x_ip2_irq_dispatch(unsigned int irq, struct irq_desc *desc)
|
||||
++{
|
||||
++ u32 status;
|
||||
++
|
||||
++ disable_irq_nosync(irq);
|
||||
++
|
||||
++ status = ath79_reset_rr(QCA953X_RESET_REG_PCIE_WMAC_INT_STATUS);
|
||||
++
|
||||
++ if (status & QCA953X_PCIE_WMAC_INT_PCIE_ALL) {
|
||||
++ ath79_ddr_wb_flush(QCA953X_DDR_REG_FLUSH_PCIE);
|
||||
++ generic_handle_irq(ATH79_IP2_IRQ(0));
|
||||
++ } else if (status & QCA953X_PCIE_WMAC_INT_WMAC_ALL) {
|
||||
++ ath79_ddr_wb_flush(QCA953X_DDR_REG_FLUSH_WMAC);
|
||||
++ generic_handle_irq(ATH79_IP2_IRQ(1));
|
||||
++ } else {
|
||||
++ spurious_interrupt();
|
||||
++ }
|
||||
++
|
||||
++ enable_irq(irq);
|
||||
++}
|
||||
++
|
||||
++static void qca953x_irq_init(void)
|
||||
++{
|
||||
++ int i;
|
||||
++
|
||||
++ for (i = ATH79_IP2_IRQ_BASE;
|
||||
++ i < ATH79_IP2_IRQ_BASE + ATH79_IP2_IRQ_COUNT; i++)
|
||||
++ irq_set_chip_and_handler(i, &dummy_irq_chip, handle_level_irq);
|
||||
++
|
||||
++ irq_set_chained_handler(ATH79_CPU_IRQ(2), qca953x_ip2_irq_dispatch);
|
||||
++}
|
||||
++
|
||||
+ static void qca955x_ip2_irq_dispatch(unsigned int irq, struct irq_desc *desc)
|
||||
+ {
|
||||
+ u32 status;
|
||||
+@@ -335,6 +368,12 @@ static void ar934x_ip3_handler(void)
|
||||
+ do_IRQ(ATH79_CPU_IRQ(3));
|
||||
+ }
|
||||
+
|
||||
++static void qca953x_ip3_handler(void)
|
||||
++{
|
||||
++ ath79_ddr_wb_flush(QCA953X_DDR_REG_FLUSH_USB);
|
||||
++ do_IRQ(ATH79_CPU_IRQ(3));
|
||||
++}
|
||||
++
|
||||
+ void __init arch_init_irq(void)
|
||||
+ {
|
||||
+ if (soc_is_ar71xx()) {
|
||||
+@@ -352,6 +391,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;
|
||||
++ ath79_ip3_handler = qca953x_ip3_handler;
|
||||
} else if (soc_is_qca955x()) {
|
||||
ath79_ip2_handler = ath79_default_ip2_handler;
|
||||
ath79_ip3_handler = ath79_default_ip3_handler;
|
||||
+@@ -365,6 +407,8 @@ void __init arch_init_irq(void)
|
||||
+
|
||||
+ if (soc_is_ar934x())
|
||||
+ ar934x_ip2_irq_init();
|
||||
++ else if (soc_is_qca953x())
|
||||
++ qca953x_irq_init();
|
||||
+ else if (soc_is_qca955x())
|
||||
+ qca955x_irq_init();
|
||||
+ }
|
||||
--- a/arch/mips/ath79/setup.c
|
||||
+++ b/arch/mips/ath79/setup.c
|
||||
-@@ -59,6 +59,7 @@ static void __init ath79_detect_sys_type
|
||||
+@@ -60,6 +60,7 @@ static void __init ath79_detect_sys_type(void)
|
||||
u32 major;
|
||||
u32 minor;
|
||||
u32 rev = 0;
|
||||
@@ -292,7 +413,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
|
||||
id = ath79_reset_rr(AR71XX_RESET_REG_REV_ID);
|
||||
major = id & REV_ID_MAJOR_MASK;
|
||||
-@@ -151,6 +152,16 @@ static void __init ath79_detect_sys_type
|
||||
+@@ -152,6 +153,16 @@ static void __init ath79_detect_sys_type(void)
|
||||
rev = id & AR934X_REV_ID_REVISION_MASK;
|
||||
break;
|
||||
|
||||
@@ -309,38 +430,60 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
case REV_ID_MAJOR_QCA9556:
|
||||
ath79_soc = ATH79_SOC_QCA9556;
|
||||
chip = "9556";
|
||||
-@@ -169,9 +180,9 @@ static void __init ath79_detect_sys_type
|
||||
+@@ -170,7 +181,7 @@ static void __init ath79_detect_sys_type(void)
|
||||
|
||||
ath79_soc_rev = rev;
|
||||
|
||||
- if (soc_is_qca955x())
|
||||
-- sprintf(ath79_sys_type, "Qualcomm Atheros QCA%s rev %u",
|
||||
-- chip, rev);
|
||||
+ if (soc_is_qca953x() || soc_is_qca955x())
|
||||
-+ sprintf(ath79_sys_type, "Qualcomm Atheros QCA%s ver %u rev %u",
|
||||
-+ chip, ver, rev);
|
||||
+ sprintf(ath79_sys_type, "Qualcomm Atheros QCA%s rev %u",
|
||||
+ chip, rev);
|
||||
else
|
||||
- sprintf(ath79_sys_type, "Atheros AR%s rev %u", chip, rev);
|
||||
- pr_info("SoC: %s\n", ath79_sys_type);
|
||||
--- a/arch/mips/include/asm/mach-ath79/ar71xx_regs.h
|
||||
+++ b/arch/mips/include/asm/mach-ath79/ar71xx_regs.h
|
||||
-@@ -105,6 +105,9 @@
|
||||
+@@ -105,6 +105,21 @@
|
||||
#define AR934X_SRIF_BASE (AR71XX_APB_BASE + 0x00116000)
|
||||
#define AR934X_SRIF_SIZE 0x1000
|
||||
|
||||
++#define QCA953X_GMAC_BASE (AR71XX_APB_BASE + 0x00070000)
|
||||
++#define QCA953X_GMAC_SIZE 0x14
|
||||
+#define QCA953X_WMAC_BASE (AR71XX_APB_BASE + 0x00100000)
|
||||
+#define QCA953X_WMAC_SIZE 0x20000
|
||||
++#define QCA953X_EHCI_BASE 0x1b000000
|
||||
++#define QCA953X_EHCI_SIZE 0x200
|
||||
++#define QCA953X_SRIF_BASE (AR71XX_APB_BASE + 0x00116000)
|
||||
++#define QCA953X_SRIF_SIZE 0x1000
|
||||
++
|
||||
++#define QCA953X_PCI_CFG_BASE0 0x14000000
|
||||
++#define QCA953X_PCI_CTRL_BASE0 (AR71XX_APB_BASE + 0x000f0000)
|
||||
++#define QCA953X_PCI_CRP_BASE0 (AR71XX_APB_BASE + 0x000c0000)
|
||||
++#define QCA953X_PCI_MEM_BASE0 0x10000000
|
||||
++#define QCA953X_PCI_MEM_SIZE 0x02000000
|
||||
+
|
||||
#define QCA955X_PCI_MEM_BASE0 0x10000000
|
||||
#define QCA955X_PCI_MEM_BASE1 0x12000000
|
||||
#define QCA955X_PCI_MEM_SIZE 0x02000000
|
||||
-@@ -279,6 +282,43 @@
|
||||
+@@ -173,6 +188,12 @@
|
||||
+ #define AR934X_DDR_REG_FLUSH_PCIE 0xa8
|
||||
+ #define AR934X_DDR_REG_FLUSH_WMAC 0xac
|
||||
+
|
||||
++#define QCA953X_DDR_REG_FLUSH_GE0 0x9c
|
||||
++#define QCA953X_DDR_REG_FLUSH_GE1 0xa0
|
||||
++#define QCA953X_DDR_REG_FLUSH_USB 0xa4
|
||||
++#define QCA953X_DDR_REG_FLUSH_PCIE 0xa8
|
||||
++#define QCA953X_DDR_REG_FLUSH_WMAC 0xac
|
||||
++
|
||||
+ /*
|
||||
+ * PLL block
|
||||
+ */
|
||||
+@@ -279,6 +300,44 @@
|
||||
|
||||
#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_SWITCH_CLOCK_CONTROL_REG 0x24
|
||||
+#define QCA953X_PLL_ETH_XMII_CONTROL_REG 0x2c
|
||||
+#define QCA953X_PLL_ETH_SGMII_CONTROL_REG 0x48
|
||||
+
|
||||
@@ -351,7 +494,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
+#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_CPU_CONFIG_OUTDIV_MASK 0x7
|
||||
+
|
||||
+#define QCA953X_PLL_DDR_CONFIG_NFRAC_SHIFT 0
|
||||
+#define QCA953X_PLL_DDR_CONFIG_NFRAC_MASK 0x3ff
|
||||
@@ -378,27 +521,85 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
#define QCA955X_PLL_CPU_CONFIG_REG 0x00
|
||||
#define QCA955X_PLL_DDR_CONFIG_REG 0x04
|
||||
#define QCA955X_PLL_CLK_CTRL_REG 0x08
|
||||
-@@ -355,6 +395,10 @@
|
||||
+@@ -355,6 +414,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 QCA953X_RESET_REG_PCIE_WMAC_INT_STATUS 0xac
|
||||
+
|
||||
#define QCA955X_RESET_REG_RESET_MODULE 0x1c
|
||||
#define QCA955X_RESET_REG_BOOTSTRAP 0xb0
|
||||
#define QCA955X_RESET_REG_EXT_INT_STATUS 0xac
|
||||
-@@ -503,6 +547,8 @@
|
||||
+@@ -450,6 +513,27 @@
|
||||
+ #define AR934X_RESET_MBOX BIT(1)
|
||||
+ #define AR934X_RESET_I2S BIT(0)
|
||||
+
|
||||
++#define QCA953X_RESET_USB_EXT_PWR BIT(29)
|
||||
++#define QCA953X_RESET_EXTERNAL BIT(28)
|
||||
++#define QCA953X_RESET_RTC BIT(27)
|
||||
++#define QCA953X_RESET_FULL_CHIP BIT(24)
|
||||
++#define QCA953X_RESET_GE1_MDIO BIT(23)
|
||||
++#define QCA953X_RESET_GE0_MDIO BIT(22)
|
||||
++#define QCA953X_RESET_CPU_NMI BIT(21)
|
||||
++#define QCA953X_RESET_CPU_COLD BIT(20)
|
||||
++#define QCA953X_RESET_DDR BIT(16)
|
||||
++#define QCA953X_RESET_USB_PHY_PLL_PWD_EXT BIT(15)
|
||||
++#define QCA953X_RESET_GE1_MAC BIT(13)
|
||||
++#define QCA953X_RESET_ETH_SWITCH_ANALOG BIT(12)
|
||||
++#define QCA953X_RESET_USB_PHY_ANALOG BIT(11)
|
||||
++#define QCA953X_RESET_GE0_MAC BIT(9)
|
||||
++#define QCA953X_RESET_ETH_SWITCH BIT(8)
|
||||
++#define QCA953X_RESET_PCIE_PHY BIT(7)
|
||||
++#define QCA953X_RESET_PCIE BIT(6)
|
||||
++#define QCA953X_RESET_USB_HOST BIT(5)
|
||||
++#define QCA953X_RESET_USB_PHY BIT(4)
|
||||
++#define QCA953X_RESET_USBSUS_OVERRIDE BIT(3)
|
||||
++
|
||||
+ #define QCA955X_RESET_HOST BIT(31)
|
||||
+ #define QCA955X_RESET_SLIC BIT(30)
|
||||
+ #define QCA955X_RESET_HDMA BIT(29)
|
||||
+@@ -503,6 +587,13 @@
|
||||
#define AR934X_BOOTSTRAP_SDRAM_DISABLED BIT(1)
|
||||
#define AR934X_BOOTSTRAP_DDR1 BIT(0)
|
||||
|
||||
++#define QCA953X_BOOTSTRAP_SW_OPTION2 BIT(12)
|
||||
++#define QCA953X_BOOTSTRAP_SW_OPTION1 BIT(11)
|
||||
++#define QCA953X_BOOTSTRAP_EJTAG_MODE BIT(5)
|
||||
+#define QCA953X_BOOTSTRAP_REF_CLK_40 BIT(4)
|
||||
++#define QCA953X_BOOTSTRAP_SDRAM_DISABLED BIT(1)
|
||||
++#define QCA953X_BOOTSTRAP_DDR1 BIT(0)
|
||||
+
|
||||
#define QCA955X_BOOTSTRAP_REF_CLK_40 BIT(4)
|
||||
|
||||
#define AR934X_PCIE_WMAC_INT_WMAC_MISC BIT(0)
|
||||
-@@ -565,6 +611,8 @@
|
||||
+@@ -523,6 +614,24 @@
|
||||
+ AR934X_PCIE_WMAC_INT_PCIE_RC1 | AR934X_PCIE_WMAC_INT_PCIE_RC2 | \
|
||||
+ AR934X_PCIE_WMAC_INT_PCIE_RC3)
|
||||
+
|
||||
++#define QCA953X_PCIE_WMAC_INT_WMAC_MISC BIT(0)
|
||||
++#define QCA953X_PCIE_WMAC_INT_WMAC_TX BIT(1)
|
||||
++#define QCA953X_PCIE_WMAC_INT_WMAC_RXLP BIT(2)
|
||||
++#define QCA953X_PCIE_WMAC_INT_WMAC_RXHP BIT(3)
|
||||
++#define QCA953X_PCIE_WMAC_INT_PCIE_RC BIT(4)
|
||||
++#define QCA953X_PCIE_WMAC_INT_PCIE_RC0 BIT(5)
|
||||
++#define QCA953X_PCIE_WMAC_INT_PCIE_RC1 BIT(6)
|
||||
++#define QCA953X_PCIE_WMAC_INT_PCIE_RC2 BIT(7)
|
||||
++#define QCA953X_PCIE_WMAC_INT_PCIE_RC3 BIT(8)
|
||||
++#define QCA953X_PCIE_WMAC_INT_WMAC_ALL \
|
||||
++ (QCA953X_PCIE_WMAC_INT_WMAC_MISC | QCA953X_PCIE_WMAC_INT_WMAC_TX | \
|
||||
++ QCA953X_PCIE_WMAC_INT_WMAC_RXLP | QCA953X_PCIE_WMAC_INT_WMAC_RXHP)
|
||||
++
|
||||
++#define QCA953X_PCIE_WMAC_INT_PCIE_ALL \
|
||||
++ (QCA953X_PCIE_WMAC_INT_PCIE_RC | QCA953X_PCIE_WMAC_INT_PCIE_RC0 | \
|
||||
++ QCA953X_PCIE_WMAC_INT_PCIE_RC1 | QCA953X_PCIE_WMAC_INT_PCIE_RC2 | \
|
||||
++ QCA953X_PCIE_WMAC_INT_PCIE_RC3)
|
||||
++
|
||||
+ #define QCA955X_EXT_INT_WMAC_MISC BIT(0)
|
||||
+ #define QCA955X_EXT_INT_WMAC_TX BIT(1)
|
||||
+ #define QCA955X_EXT_INT_WMAC_RXLP BIT(2)
|
||||
+@@ -565,6 +674,8 @@
|
||||
#define REV_ID_MAJOR_AR9341 0x0120
|
||||
#define REV_ID_MAJOR_AR9342 0x1120
|
||||
#define REV_ID_MAJOR_AR9344 0x2120
|
||||
@@ -407,7 +608,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
#define REV_ID_MAJOR_QCA9556 0x0130
|
||||
#define REV_ID_MAJOR_QCA9558 0x1130
|
||||
|
||||
-@@ -587,6 +635,8 @@
|
||||
+@@ -587,6 +698,8 @@
|
||||
|
||||
#define AR934X_REV_ID_REVISION_MASK 0xf
|
||||
|
||||
@@ -416,14 +617,81 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
#define QCA955X_REV_ID_REVISION_MASK 0xf
|
||||
|
||||
/*
|
||||
-@@ -640,6 +690,7 @@
|
||||
+@@ -634,12 +747,32 @@
|
||||
+ #define AR934X_GPIO_REG_OUT_FUNC5 0x40
|
||||
+ #define AR934X_GPIO_REG_FUNC 0x6c
|
||||
+
|
||||
++#define QCA953X_GPIO_REG_OUT_FUNC0 0x2c
|
||||
++#define QCA953X_GPIO_REG_OUT_FUNC1 0x30
|
||||
++#define QCA953X_GPIO_REG_OUT_FUNC2 0x34
|
||||
++#define QCA953X_GPIO_REG_OUT_FUNC3 0x38
|
||||
++#define QCA953X_GPIO_REG_OUT_FUNC4 0x3c
|
||||
++#define QCA953X_GPIO_REG_IN_ENABLE0 0x44
|
||||
++#define QCA953X_GPIO_REG_FUNC 0x6c
|
||||
++
|
||||
++#define QCA953X_GPIO_OUT_MUX_SPI_CS1 10
|
||||
++#define QCA953X_GPIO_OUT_MUX_SPI_CS2 11
|
||||
++#define QCA953X_GPIO_OUT_MUX_SPI_CS0 9
|
||||
++#define QCA953X_GPIO_OUT_MUX_SPI_CLK 8
|
||||
++#define QCA953X_GPIO_OUT_MUX_SPI_MOSI 12
|
||||
++#define QCA953X_GPIO_OUT_MUX_LED_LINK1 41
|
||||
++#define QCA953X_GPIO_OUT_MUX_LED_LINK2 42
|
||||
++#define QCA953X_GPIO_OUT_MUX_LED_LINK3 43
|
||||
++#define QCA953X_GPIO_OUT_MUX_LED_LINK4 44
|
||||
++#define QCA953X_GPIO_OUT_MUX_LED_LINK5 45
|
||||
++
|
||||
+ #define AR71XX_GPIO_COUNT 16
|
||||
+ #define AR7240_GPIO_COUNT 18
|
||||
+ #define AR7241_GPIO_COUNT 20
|
||||
#define AR913X_GPIO_COUNT 22
|
||||
#define AR933X_GPIO_COUNT 30
|
||||
#define AR934X_GPIO_COUNT 23
|
||||
-+#define QCA953X_GPIO_COUNT 24
|
||||
++#define QCA953X_GPIO_COUNT 18
|
||||
#define QCA955X_GPIO_COUNT 24
|
||||
|
||||
/*
|
||||
+@@ -663,6 +796,24 @@
|
||||
+ #define AR934X_SRIF_DPLL2_OUTDIV_SHIFT 13
|
||||
+ #define AR934X_SRIF_DPLL2_OUTDIV_MASK 0x7
|
||||
+
|
||||
++#define QCA953X_SRIF_CPU_DPLL1_REG 0x1c0
|
||||
++#define QCA953X_SRIF_CPU_DPLL2_REG 0x1c4
|
||||
++#define QCA953X_SRIF_CPU_DPLL3_REG 0x1c8
|
||||
++
|
||||
++#define QCA953X_SRIF_DDR_DPLL1_REG 0x240
|
||||
++#define QCA953X_SRIF_DDR_DPLL2_REG 0x244
|
||||
++#define QCA953X_SRIF_DDR_DPLL3_REG 0x248
|
||||
++
|
||||
++#define QCA953X_SRIF_DPLL1_REFDIV_SHIFT 27
|
||||
++#define QCA953X_SRIF_DPLL1_REFDIV_MASK 0x1f
|
||||
++#define QCA953X_SRIF_DPLL1_NINT_SHIFT 18
|
||||
++#define QCA953X_SRIF_DPLL1_NINT_MASK 0x1ff
|
||||
++#define QCA953X_SRIF_DPLL1_NFRAC_MASK 0x0003ffff
|
||||
++
|
||||
++#define QCA953X_SRIF_DPLL2_LOCAL_PLL BIT(30)
|
||||
++#define QCA953X_SRIF_DPLL2_OUTDIV_SHIFT 13
|
||||
++#define QCA953X_SRIF_DPLL2_OUTDIV_MASK 0x7
|
||||
++
|
||||
+ #define AR71XX_GPIO_FUNC_STEREO_EN BIT(17)
|
||||
+ #define AR71XX_GPIO_FUNC_SLIC_EN BIT(16)
|
||||
+ #define AR71XX_GPIO_FUNC_SPI_CS2_EN BIT(13)
|
||||
+@@ -804,6 +955,16 @@
|
||||
+ #define AR934X_ETH_CFG_RDV_DELAY_SHIFT 16
|
||||
+
|
||||
+ /*
|
||||
++ * QCA953X GMAC Interface
|
||||
++ */
|
||||
++#define QCA953X_GMAC_REG_ETH_CFG 0x00
|
||||
++
|
||||
++#define QCA953X_ETH_CFG_SW_ONLY_MODE BIT(6)
|
||||
++#define QCA953X_ETH_CFG_SW_PHY_SWAP BIT(7)
|
||||
++#define QCA953X_ETH_CFG_SW_APB_ACCESS BIT(9)
|
||||
++#define QCA953X_ETH_CFG_SW_ACC_MSB_FIRST BIT(13)
|
||||
++
|
||||
++/*
|
||||
+ * QCA955X GMAC Interface
|
||||
+ */
|
||||
+
|
||||
--- 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 {
|
||||
diff --git a/target/linux/ar71xx/patches-3.18/735-MIPS-ath79-add-support-for-QCA956x-SoC.patch b/target/linux/ar71xx/patches-3.18/735-MIPS-ath79-add-support-for-QCA956x-SoC.patch
|
||||
index 491a7aa..2bdc744 100644
|
||||
--- a/target/linux/ar71xx/patches-3.18/735-MIPS-ath79-add-support-for-QCA956x-SoC.patch
|
||||
+++ b/target/linux/ar71xx/patches-3.18/735-MIPS-ath79-add-support-for-QCA956x-SoC.patch
|
||||
@@ -142,74 +142,9 @@
|
||||
ath79_uart_data[0].uartclk = uart_clk_rate;
|
||||
platform_device_register(&ath79_uart_device);
|
||||
} else if (soc_is_ar933x()) {
|
||||
---- a/arch/mips/ath79/dev-eth.c
|
||||
-+++ b/arch/mips/ath79/dev-eth.c
|
||||
-@@ -198,6 +198,8 @@ void __init ath79_register_mdio(unsigned
|
||||
- case ATH79_SOC_AR9330:
|
||||
- case ATH79_SOC_AR9331:
|
||||
- case ATH79_SOC_QCA9533:
|
||||
-+ case ATH79_SOC_QCA9561:
|
||||
-+ case ATH79_SOC_TP9343:
|
||||
- mdio_dev = &ath79_mdio1_device;
|
||||
- mdio_data = &ath79_mdio1_data;
|
||||
- break;
|
||||
-@@ -256,6 +258,8 @@ void __init ath79_register_mdio(unsigned
|
||||
- break;
|
||||
-
|
||||
- case ATH79_SOC_QCA9533:
|
||||
-+ case ATH79_SOC_QCA9561:
|
||||
-+ case ATH79_SOC_TP9343:
|
||||
- mdio_data->builtin_switch = 1;
|
||||
- break;
|
||||
-
|
||||
-@@ -571,6 +575,8 @@ static void __init ath79_init_eth_pll_da
|
||||
- case ATH79_SOC_QCA9533:
|
||||
- case ATH79_SOC_QCA9556:
|
||||
- case ATH79_SOC_QCA9558:
|
||||
-+ case ATH79_SOC_QCA9561:
|
||||
-+ case ATH79_SOC_TP9343:
|
||||
- pll_10 = AR934X_PLL_VAL_10;
|
||||
- pll_100 = AR934X_PLL_VAL_100;
|
||||
- pll_1000 = AR934X_PLL_VAL_1000;
|
||||
-@@ -627,6 +633,8 @@ static int __init ath79_setup_phy_if_mod
|
||||
- case ATH79_SOC_AR9330:
|
||||
- case ATH79_SOC_AR9331:
|
||||
- case ATH79_SOC_QCA9533:
|
||||
-+ case ATH79_SOC_QCA9561:
|
||||
-+ case ATH79_SOC_TP9343:
|
||||
- pdata->phy_if_mode = PHY_INTERFACE_MODE_MII;
|
||||
- break;
|
||||
-
|
||||
-@@ -688,6 +696,8 @@ static int __init ath79_setup_phy_if_mod
|
||||
- case ATH79_SOC_AR9330:
|
||||
- case ATH79_SOC_AR9331:
|
||||
- case ATH79_SOC_QCA9533:
|
||||
-+ case ATH79_SOC_QCA9561:
|
||||
-+ case ATH79_SOC_TP9343:
|
||||
- pdata->phy_if_mode = PHY_INTERFACE_MODE_GMII;
|
||||
- break;
|
||||
-
|
||||
-@@ -1018,6 +1028,8 @@ void __init ath79_register_eth(unsigned
|
||||
- break;
|
||||
-
|
||||
- case ATH79_SOC_QCA9533:
|
||||
-+ case ATH79_SOC_QCA9561:
|
||||
-+ case ATH79_SOC_TP9343:
|
||||
- if (id == 0) {
|
||||
- pdata->reset_bit = AR933X_RESET_GE0_MAC |
|
||||
- AR933X_RESET_GE0_MDIO;
|
||||
-@@ -1123,6 +1135,8 @@ void __init ath79_register_eth(unsigned
|
||||
- case ATH79_SOC_AR9330:
|
||||
- case ATH79_SOC_AR9331:
|
||||
- case ATH79_SOC_QCA9533:
|
||||
-+ case ATH79_SOC_QCA9561:
|
||||
-+ case ATH79_SOC_TP9343:
|
||||
- pdata->mii_bus_dev = &ath79_mdio1_device.dev;
|
||||
- break;
|
||||
-
|
||||
--- a/arch/mips/ath79/dev-usb.c
|
||||
+++ b/arch/mips/ath79/dev-usb.c
|
||||
-@@ -272,6 +272,19 @@ static void __init qca955x_usb_setup(voi
|
||||
+@@ -296,6 +296,19 @@ static void __init qca955x_usb_setup(voi
|
||||
&ath79_ehci_pdata_v2, sizeof(ath79_ehci_pdata_v2));
|
||||
}
|
||||
|
||||
@@ -229,8 +164,8 @@
|
||||
void __init ath79_register_usb(void)
|
||||
{
|
||||
if (soc_is_ar71xx())
|
||||
-@@ -288,6 +301,8 @@ void __init ath79_register_usb(void)
|
||||
- ar934x_usb_setup();
|
||||
+@@ -314,6 +327,8 @@ void __init ath79_register_usb(void)
|
||||
+ qca953x_usb_setup();
|
||||
else if (soc_is_qca955x())
|
||||
qca955x_usb_setup();
|
||||
+ else if (soc_is_qca9561())
|
||||
@@ -291,9 +226,9 @@
|
||||
soc_is_ar913x() ||
|
||||
soc_is_ar933x())
|
||||
reg = AR71XX_GPIO_REG_FUNC;
|
||||
-- else if (soc_is_ar934x())
|
||||
+- else if (soc_is_ar934x() || soc_is_qca953x())
|
||||
+ else if (soc_is_ar934x() ||
|
||||
-+ soc_is_qca956x())
|
||||
++ soc_is_qca953x() || soc_is_qca956x())
|
||||
reg = AR934X_GPIO_REG_FUNC;
|
||||
else
|
||||
BUG();
|
||||
@@ -326,7 +261,7 @@
|
||||
ath79_misc_irq_chip.irq_ack = ar724x_misc_irq_ack;
|
||||
else
|
||||
BUG();
|
||||
-@@ -236,6 +237,99 @@ static void qca955x_irq_init(void)
|
||||
+@@ -268,6 +269,97 @@ static void qca955x_irq_init(void)
|
||||
irq_set_chained_handler(ATH79_CPU_IRQ(3), qca955x_ip3_irq_dispatch);
|
||||
}
|
||||
|
||||
@@ -406,15 +341,13 @@
|
||||
+
|
||||
+ for (i = ATH79_IP2_IRQ_BASE;
|
||||
+ i < ATH79_IP2_IRQ_BASE + ATH79_IP2_IRQ_COUNT; i++)
|
||||
-+ irq_set_chip_and_handler(i, &dummy_irq_chip,
|
||||
-+ handle_level_irq);
|
||||
++ irq_set_chip_and_handler(i, &dummy_irq_chip, handle_level_irq);
|
||||
+
|
||||
+ irq_set_chained_handler(ATH79_CPU_IRQ(2), qca956x_ip2_irq_dispatch);
|
||||
+
|
||||
+ for (i = ATH79_IP3_IRQ_BASE;
|
||||
+ i < ATH79_IP3_IRQ_BASE + ATH79_IP3_IRQ_COUNT; i++)
|
||||
-+ irq_set_chip_and_handler(i, &dummy_irq_chip,
|
||||
-+ handle_level_irq);
|
||||
++ irq_set_chip_and_handler(i, &dummy_irq_chip, handle_level_irq);
|
||||
+
|
||||
+ irq_set_chained_handler(ATH79_CPU_IRQ(3), qca956x_ip3_irq_dispatch);
|
||||
+
|
||||
@@ -426,7 +359,7 @@
|
||||
asmlinkage void plat_irq_dispatch(void)
|
||||
{
|
||||
unsigned long pending;
|
||||
-@@ -359,6 +453,9 @@ void __init arch_init_irq(void)
|
||||
+@@ -397,6 +489,9 @@ void __init arch_init_irq(void)
|
||||
} else if (soc_is_qca955x()) {
|
||||
ath79_ip2_handler = ath79_default_ip2_handler;
|
||||
ath79_ip3_handler = ath79_default_ip3_handler;
|
||||
@@ -436,8 +369,8 @@
|
||||
} else {
|
||||
BUG();
|
||||
}
|
||||
-@@ -371,4 +468,6 @@ void __init arch_init_irq(void)
|
||||
- ar934x_ip2_irq_init();
|
||||
+@@ -411,4 +506,6 @@ void __init arch_init_irq(void)
|
||||
+ qca953x_irq_init();
|
||||
else if (soc_is_qca955x())
|
||||
qca955x_irq_init();
|
||||
+ else if (soc_is_qca956x())
|
||||
@@ -519,7 +452,7 @@
|
||||
return -ENODEV;
|
||||
--- a/arch/mips/ath79/setup.c
|
||||
+++ b/arch/mips/ath79/setup.c
|
||||
-@@ -175,15 +175,30 @@ static void __init ath79_detect_sys_type
|
||||
+@@ -175,14 +175,29 @@ static void __init ath79_detect_sys_type
|
||||
rev = id & QCA955X_REV_ID_REVISION_MASK;
|
||||
break;
|
||||
|
||||
@@ -542,18 +475,18 @@
|
||||
ath79_soc_rev = rev;
|
||||
|
||||
- if (soc_is_qca953x() || soc_is_qca955x())
|
||||
+- sprintf(ath79_sys_type, "Qualcomm Atheros QCA%s rev %u",
|
||||
+ if (soc_is_qca953x() || soc_is_qca955x() || soc_is_qca9561())
|
||||
- sprintf(ath79_sys_type, "Qualcomm Atheros QCA%s ver %u rev %u",
|
||||
- chip, ver, rev);
|
||||
++ sprintf(ath79_sys_type, "Qualcomm Atheros QCA%s ver %u rev %u",
|
||||
++ chip, ver, rev);
|
||||
+ else if (soc_is_tp9343())
|
||||
+ sprintf(ath79_sys_type, "Qualcomm Atheros TP%s rev %u",
|
||||
-+ chip, rev);
|
||||
+ chip, rev);
|
||||
else
|
||||
sprintf(ath79_sys_type, "Atheros AR%s rev %u", chip, rev);
|
||||
- pr_info("SoC: %s\n", ath79_sys_type);
|
||||
--- a/arch/mips/include/asm/mach-ath79/ar71xx_regs.h
|
||||
+++ b/arch/mips/include/asm/mach-ath79/ar71xx_regs.h
|
||||
-@@ -131,6 +131,23 @@
|
||||
+@@ -143,6 +143,23 @@
|
||||
#define QCA955X_NFC_BASE 0x1b800200
|
||||
#define QCA955X_NFC_SIZE 0xb8
|
||||
|
||||
@@ -577,7 +510,7 @@
|
||||
#define AR9300_OTP_BASE 0x14000
|
||||
#define AR9300_OTP_STATUS 0x15f18
|
||||
#define AR9300_OTP_STATUS_TYPE 0x7
|
||||
-@@ -356,6 +373,49 @@
|
||||
+@@ -375,6 +392,49 @@
|
||||
#define QCA955X_PLL_CLK_CTRL_DDRCLK_FROM_DDRPLL BIT(21)
|
||||
#define QCA955X_PLL_CLK_CTRL_AHBCLK_FROM_DDRPLL BIT(24)
|
||||
|
||||
@@ -627,7 +560,7 @@
|
||||
/*
|
||||
* USB_CONFIG block
|
||||
*/
|
||||
-@@ -403,6 +463,11 @@
|
||||
+@@ -422,6 +482,11 @@
|
||||
#define QCA955X_RESET_REG_BOOTSTRAP 0xb0
|
||||
#define QCA955X_RESET_REG_EXT_INT_STATUS 0xac
|
||||
|
||||
@@ -639,7 +572,7 @@
|
||||
#define MISC_INT_ETHSW BIT(12)
|
||||
#define MISC_INT_TIMER4 BIT(10)
|
||||
#define MISC_INT_TIMER3 BIT(9)
|
||||
-@@ -551,6 +616,8 @@
|
||||
+@@ -596,6 +661,8 @@
|
||||
|
||||
#define QCA955X_BOOTSTRAP_REF_CLK_40 BIT(4)
|
||||
|
||||
@@ -648,7 +581,7 @@
|
||||
#define AR934X_PCIE_WMAC_INT_WMAC_MISC BIT(0)
|
||||
#define AR934X_PCIE_WMAC_INT_WMAC_TX BIT(1)
|
||||
#define AR934X_PCIE_WMAC_INT_WMAC_RXLP BIT(2)
|
||||
-@@ -600,6 +667,37 @@
|
||||
+@@ -663,6 +730,37 @@
|
||||
QCA955X_EXT_INT_PCIE_RC2_INT1 | QCA955X_EXT_INT_PCIE_RC2_INT2 | \
|
||||
QCA955X_EXT_INT_PCIE_RC2_INT3)
|
||||
|
||||
@@ -686,7 +619,7 @@
|
||||
#define REV_ID_MAJOR_MASK 0xfff0
|
||||
#define REV_ID_MAJOR_AR71XX 0x00a0
|
||||
#define REV_ID_MAJOR_AR913X 0x00b0
|
||||
-@@ -615,6 +713,8 @@
|
||||
+@@ -678,6 +776,8 @@
|
||||
#define REV_ID_MAJOR_QCA9533_V2 0x0160
|
||||
#define REV_ID_MAJOR_QCA9556 0x0130
|
||||
#define REV_ID_MAJOR_QCA9558 0x1130
|
||||
@@ -695,7 +628,7 @@
|
||||
|
||||
#define AR71XX_REV_ID_MINOR_MASK 0x3
|
||||
#define AR71XX_REV_ID_MINOR_AR7130 0x0
|
||||
-@@ -639,6 +739,8 @@
|
||||
+@@ -702,6 +802,8 @@
|
||||
|
||||
#define QCA955X_REV_ID_REVISION_MASK 0xf
|
||||
|
||||
@@ -704,9 +637,9 @@
|
||||
/*
|
||||
* SPI block
|
||||
*/
|
||||
-@@ -684,6 +786,19 @@
|
||||
- #define AR934X_GPIO_REG_OUT_FUNC5 0x40
|
||||
- #define AR934X_GPIO_REG_FUNC 0x6c
|
||||
+@@ -766,6 +868,19 @@
|
||||
+ #define QCA953X_GPIO_OUT_MUX_LED_LINK4 44
|
||||
+ #define QCA953X_GPIO_OUT_MUX_LED_LINK5 45
|
||||
|
||||
+#define QCA956X_GPIO_REG_OUT_FUNC0 0x2c
|
||||
+#define QCA956X_GPIO_REG_OUT_FUNC1 0x30
|
||||
@@ -724,9 +657,9 @@
|
||||
#define AR71XX_GPIO_COUNT 16
|
||||
#define AR7240_GPIO_COUNT 18
|
||||
#define AR7241_GPIO_COUNT 20
|
||||
-@@ -692,6 +807,7 @@
|
||||
+@@ -774,6 +889,7 @@
|
||||
#define AR934X_GPIO_COUNT 23
|
||||
- #define QCA953X_GPIO_COUNT 24
|
||||
+ #define QCA953X_GPIO_COUNT 18
|
||||
#define QCA955X_GPIO_COUNT 24
|
||||
+#define QCA956X_GPIO_COUNT 23
|
||||
|
||||
diff --git a/target/linux/ar71xx/patches-3.18/736-MIPS-ath79-fix-chained-irq-disable.patch b/target/linux/ar71xx/patches-3.18/736-MIPS-ath79-fix-chained-irq-disable.patch
|
||||
index 8cb38d3..8c0cc95 100644
|
||||
--- a/target/linux/ar71xx/patches-3.18/736-MIPS-ath79-fix-chained-irq-disable.patch
|
||||
+++ b/target/linux/ar71xx/patches-3.18/736-MIPS-ath79-fix-chained-irq-disable.patch
|
||||
@@ -19,7 +19,16 @@
|
||||
|
||||
irq_set_chained_handler(ATH79_CPU_IRQ(2), ar934x_ip2_irq_dispatch);
|
||||
}
|
||||
-@@ -224,15 +225,13 @@ static void qca955x_irq_init(void)
|
||||
+@@ -182,7 +183,7 @@ static void qca953x_irq_init(void)
|
||||
+
|
||||
+ for (i = ATH79_IP2_IRQ_BASE;
|
||||
+ i < ATH79_IP2_IRQ_BASE + ATH79_IP2_IRQ_COUNT; i++)
|
||||
+- irq_set_chip_and_handler(i, &dummy_irq_chip, handle_level_irq);
|
||||
++ irq_set_chip_and_handler(i, &ip2_chip, handle_level_irq);
|
||||
+
|
||||
+ irq_set_chained_handler(ATH79_CPU_IRQ(2), qca953x_ip2_irq_dispatch);
|
||||
+ }
|
||||
+@@ -256,15 +257,13 @@ static void qca955x_irq_init(void)
|
||||
|
||||
for (i = ATH79_IP2_IRQ_BASE;
|
||||
i < ATH79_IP2_IRQ_BASE + ATH79_IP2_IRQ_COUNT; i++)
|
||||
@@ -37,25 +46,23 @@
|
||||
|
||||
irq_set_chained_handler(ATH79_CPU_IRQ(3), qca955x_ip3_irq_dispatch);
|
||||
}
|
||||
-@@ -313,15 +312,13 @@ static void qca956x_irq_init(void)
|
||||
+@@ -345,13 +344,13 @@ static void qca956x_irq_init(void)
|
||||
|
||||
for (i = ATH79_IP2_IRQ_BASE;
|
||||
i < ATH79_IP2_IRQ_BASE + ATH79_IP2_IRQ_COUNT; i++)
|
||||
-- irq_set_chip_and_handler(i, &dummy_irq_chip,
|
||||
-- handle_level_irq);
|
||||
+- irq_set_chip_and_handler(i, &dummy_irq_chip, handle_level_irq);
|
||||
+ irq_set_chip_and_handler(i, &ip2_chip, handle_level_irq);
|
||||
|
||||
irq_set_chained_handler(ATH79_CPU_IRQ(2), qca956x_ip2_irq_dispatch);
|
||||
|
||||
for (i = ATH79_IP3_IRQ_BASE;
|
||||
i < ATH79_IP3_IRQ_BASE + ATH79_IP3_IRQ_COUNT; i++)
|
||||
-- irq_set_chip_and_handler(i, &dummy_irq_chip,
|
||||
-- handle_level_irq);
|
||||
+- irq_set_chip_and_handler(i, &dummy_irq_chip, handle_level_irq);
|
||||
+ irq_set_chip_and_handler(i, &ip3_chip, handle_level_irq);
|
||||
|
||||
irq_set_chained_handler(ATH79_CPU_IRQ(3), qca956x_ip3_irq_dispatch);
|
||||
|
||||
-@@ -430,8 +427,35 @@ static void ar934x_ip3_handler(void)
|
||||
+@@ -466,8 +465,35 @@ static void qca953x_ip3_handler(void)
|
||||
do_IRQ(ATH79_CPU_IRQ(3));
|
||||
}
|
||||
|
@ -1,44 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Fri, 7 Aug 2015 18:45:42 +0200
|
||||
Subject: base-files: default_postinst: propagate the real postinst return code
|
||||
|
||||
Using the postinst script for sanity checks and expecting opkg to fail
|
||||
if the postinst didn't return 0 was possible in Barrier Breaker, propagate
|
||||
the real postinst return code through default_postinst to restore this
|
||||
behaviour.
|
||||
|
||||
diff --git a/package/base-files/files/lib/functions.sh b/package/base-files/files/lib/functions.sh
|
||||
index 8d045fa..2f78d67 100755
|
||||
--- a/package/base-files/files/lib/functions.sh
|
||||
+++ b/package/base-files/files/lib/functions.sh
|
||||
@@ -174,7 +174,8 @@ default_prerm() {
|
||||
}
|
||||
|
||||
default_postinst() {
|
||||
- local pkgname rusers
|
||||
+ local pkgname rusers ret
|
||||
+ ret=0
|
||||
pkgname=$(basename ${1%.*})
|
||||
rusers=$(grep "Require-User:" ${IPKG_INSTROOT}/usr/lib/opkg/info/${pkgname}.control)
|
||||
[ -n "$rusers" ] && {
|
||||
@@ -215,7 +216,10 @@ default_postinst() {
|
||||
done
|
||||
}
|
||||
|
||||
- [ -f ${IPKG_INSTROOT}/usr/lib/opkg/info/${pkgname}.postinst-pkg ] && ( . ${IPKG_INSTROOT}/usr/lib/opkg/info/${pkgname}.postinst-pkg )
|
||||
+ if [ -f ${IPKG_INSTROOT}/usr/lib/opkg/info/${pkgname}.postinst-pkg ]; then
|
||||
+ ( . ${IPKG_INSTROOT}/usr/lib/opkg/info/${pkgname}.postinst-pkg )
|
||||
+ ret=$?
|
||||
+ fi
|
||||
[ -n "${IPKG_INSTROOT}" ] || rm -f /tmp/luci-indexcache 2>/dev/null
|
||||
|
||||
[ "$PKG_UPGRADE" = "1" ] || for i in `cat ${IPKG_INSTROOT}/usr/lib/opkg/info/${pkgname}.list | grep "^/etc/init.d/"`; do
|
||||
@@ -225,7 +229,7 @@ default_postinst() {
|
||||
$i start
|
||||
}
|
||||
done
|
||||
- return 0
|
||||
+ return $ret
|
||||
}
|
||||
|
||||
include() {
|
@ -1,22 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Fri, 28 Aug 2015 10:43:55 +0200
|
||||
Subject: opkg: work around unconditional libopenssl build dependency
|
||||
|
||||
As the OpenWrt build system only resolves build dependencies per directory,
|
||||
all opkg variants were causing libopenssl to be downloaded and built,
|
||||
not only opkg-smime. Fix this by applying the same workaround as in
|
||||
ustream-ssl.
|
||||
|
||||
diff --git a/package/system/opkg/Makefile b/package/system/opkg/Makefile
|
||||
index 76688f5..3e39cf8 100644
|
||||
--- a/package/system/opkg/Makefile
|
||||
+++ b/package/system/opkg/Makefile
|
||||
@@ -72,7 +72,7 @@ endef
|
||||
define Package/opkg-smime
|
||||
$(call Package/opkg/Default)
|
||||
TITLE+= (with S/MIME signature support)
|
||||
- DEPENDS+=+libopenssl
|
||||
+ DEPENDS+=+PACKAGE_opkg-smime:libopenssl
|
||||
VARIANT:=smime
|
||||
endef
|
||||
|
@ -1,22 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Fri, 28 Aug 2015 10:46:11 +0200
|
||||
Subject: hostapd: work around unconditional libopenssl build dependency
|
||||
|
||||
As the OpenWrt build system only resolves build dependencies per directory,
|
||||
all hostapd variants were causing libopenssl to be downloaded and built,
|
||||
not only wpad-mesh. Fix this by applying the same workaround as in
|
||||
ustream-ssl.
|
||||
|
||||
diff --git a/package/network/services/hostapd/Makefile b/package/network/services/hostapd/Makefile
|
||||
index c16cb11..c39b6b4 100644
|
||||
--- a/package/network/services/hostapd/Makefile
|
||||
+++ b/package/network/services/hostapd/Makefile
|
||||
@@ -177,7 +177,7 @@ endef
|
||||
define Package/wpad-mesh
|
||||
$(call Package/wpad/Default)
|
||||
TITLE+= (with 802.11s mesh and SAE support)
|
||||
- DEPENDS:=$(DRV_DEPENDS) +libubus +libopenssl +@CONFIG_WPA_SUPPLICANT_OPENSSL @(!TARGET_uml||BROKEN)
|
||||
+ DEPENDS:=$(DRV_DEPENDS) +libubus +PACKAGE_wpad-mesh:libopenssl +@CONFIG_WPA_SUPPLICANT_OPENSSL @(!TARGET_uml||BROKEN)
|
||||
CONFLICTS:=@WPA_SUPPLICANT_INTERNAL
|
||||
VARIANT:=wpad-mesh
|
||||
endef
|
@ -1,77 +0,0 @@
|
||||
From: Nils Schneider <nils@nilsschneider.net>
|
||||
Date: Thu, 3 Sep 2015 18:07:17 +0200
|
||||
Subject: odhcp6c: minor fixes
|
||||
|
||||
Better synchronize RA & DHCPv6 events
|
||||
Accumulate some events to avoid flooding
|
||||
Restart softwires for address and prefix changes
|
||||
|
||||
Signed-off-by: Steven Barth <steven@midlink.org>
|
||||
|
||||
diff --git a/package/network/ipv6/odhcp6c/Makefile b/package/network/ipv6/odhcp6c/Makefile
|
||||
index 75de54c..aa81e02 100644
|
||||
--- a/package/network/ipv6/odhcp6c/Makefile
|
||||
+++ b/package/network/ipv6/odhcp6c/Makefile
|
||||
@@ -8,14 +8,14 @@
|
||||
include $(TOPDIR)/rules.mk
|
||||
|
||||
PKG_NAME:=odhcp6c
|
||||
-PKG_VERSION:=2015-07-18
|
||||
+PKG_VERSION:=2015-07-29
|
||||
PKG_RELEASE=$(PKG_SOURCE_VERSION)
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2
|
||||
PKG_SOURCE_SUBDIR:=$(PKG_NAME)-$(PKG_VERSION)
|
||||
PKG_SOURCE_URL:=https://github.com/sbyx/odhcp6c.git
|
||||
PKG_SOURCE_PROTO:=git
|
||||
-PKG_SOURCE_VERSION:=024525798c5f6aba3af9b2ef7b3af2f3c14f1db8
|
||||
+PKG_SOURCE_VERSION:=dc186d6d2b0dd4ad23ca5fc69c00e81f796ff6d9
|
||||
PKG_MAINTAINER:=Steven Barth <steven@midlink.org>
|
||||
PKG_LICENSE:=GPL-2.0
|
||||
|
||||
diff --git a/package/network/ipv6/odhcp6c/files/dhcpv6.script b/package/network/ipv6/odhcp6c/files/dhcpv6.script
|
||||
index 33f6d9b..677d35f 100755
|
||||
--- a/package/network/ipv6/odhcp6c/files/dhcpv6.script
|
||||
+++ b/package/network/ipv6/odhcp6c/files/dhcpv6.script
|
||||
@@ -5,6 +5,8 @@
|
||||
|
||||
setup_interface () {
|
||||
local device="$1"
|
||||
+ local prefsig=""
|
||||
+ local addrsig=""
|
||||
proto_init_update "*" 1
|
||||
|
||||
# Merge RA-DNS
|
||||
@@ -34,6 +36,7 @@ setup_interface () {
|
||||
|
||||
for prefix in $PREFIXES; do
|
||||
proto_add_ipv6_prefix "$prefix"
|
||||
+ prefsig="$prefsig ${prefix%%,*}"
|
||||
local entry="${prefix#*/}"
|
||||
entry="${entry#*,}"
|
||||
entry="${entry#*,}"
|
||||
@@ -68,6 +71,7 @@ setup_interface () {
|
||||
local valid="${entry%%,*}"
|
||||
|
||||
proto_add_ipv6_address "$addr" "$mask" "$preferred" "$valid" 1
|
||||
+ addrsig="$addrsig $addr/$mask"
|
||||
|
||||
if [ -z "$RA_ADDRESSES" -a -z "$RA_ROUTES" -a \
|
||||
-z "$RA_DNS" -a "$FAKE_ROUTES" = 1 ]; then
|
||||
@@ -136,6 +140,8 @@ setup_interface () {
|
||||
json_add_string ifname "@$INTERFACE"
|
||||
json_add_string proto map
|
||||
json_add_string type "$MAPTYPE"
|
||||
+ json_add_string _prefsig "$prefsig"
|
||||
+ [ "$MAPTYPE" = lw4o6 ] && json_add_string _addrsig "$addrsig"
|
||||
json_add_string rule "$MAPRULE"
|
||||
json_add_string tunlink "$INTERFACE"
|
||||
[ -n "$ZONE_MAP" ] || ZONE_MAP=$ZONE
|
||||
@@ -163,6 +169,7 @@ setup_interface () {
|
||||
json_add_string ifname "@$INTERFACE"
|
||||
json_add_string proto "464xlat"
|
||||
json_add_string tunlink "$INTERFACE"
|
||||
+ json_add_string _addrsig "$addrsig"
|
||||
[ -n "$ZONE_464XLAT" ] || ZONE_464XLAT=$ZONE
|
||||
[ -n "$ZONE_464XLAT" ] && json_add_string zone "$ZONE_464XLAT"
|
||||
[ -n "$IFACE_464XLAT_DELEGATE" ] && json_add_boolean delegate "$IFACE_464XLAT_DELEGATE"
|
@ -1,31 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Sun, 11 Oct 2015 18:00:27 +0200
|
||||
Subject: ar71xx: add support for TP-LINK TL-WR841N/ND v10
|
||||
|
||||
diff --git a/target/linux/ar71xx/image/Makefile b/target/linux/ar71xx/image/Makefile
|
||||
index 8a25832..3a17420 100644
|
||||
--- a/target/linux/ar71xx/image/Makefile
|
||||
+++ b/target/linux/ar71xx/image/Makefile
|
||||
@@ -562,6 +562,13 @@ define Device/tl-wr841n-v9
|
||||
TPLINK_HWID := 0x08410009
|
||||
endef
|
||||
|
||||
+define Device/tl-wr841n-v10
|
||||
+ $(Device/tplink-4mlzma)
|
||||
+ BOARDNAME := TL-WR841N-v9
|
||||
+ DEVICE_PROFILE := TLWR841
|
||||
+ TPLINK_HWID := 0x08410010
|
||||
+endef
|
||||
+
|
||||
define Device/tl-wr842n-v2
|
||||
$(Device/tplink-8mlzma)
|
||||
BOARDNAME := TL-WR842N-v2
|
||||
@@ -582,7 +589,7 @@ define Device/tl-wr847n-v8
|
||||
DEVICE_PROFILE := TLWR841
|
||||
TPLINK_HWID := 0x08470008
|
||||
endef
|
||||
-TARGET_DEVICES += tl-wr841n-v8 tl-wr841n-v9 tl-wr842n-v2 tl-wr843nd-v1 tl-wr847n-v8
|
||||
+TARGET_DEVICES += tl-wr841n-v8 tl-wr841n-v9 tl-wr841n-v10 tl-wr842n-v2 tl-wr843nd-v1 tl-wr847n-v8
|
||||
|
||||
define Device/tl-wr941nd-v5
|
||||
$(Device/tplink-4mlzma)
|
@ -1,40 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Sun, 11 Oct 2015 18:13:35 +0200
|
||||
Subject: base-files: add /etc/profile.d support
|
||||
|
||||
OpenWrt should support an optional /etc/profile.d directory like
|
||||
most other Linux distributions. This allows packages to install
|
||||
their own scripts into /etc/profile.d/ directory.
|
||||
|
||||
The file suffix should make clear, that these scripts
|
||||
are (sourced) shell-snippets. If the user needs e.g. php or lua,
|
||||
one must make sure that the interpreter is called.
|
||||
The reverse failsafe test makes sure, that the effective returncode is 0.
|
||||
|
||||
A typcal usecase is the inclusion of private helpers,
|
||||
special variables or aliases, which at the moment needs
|
||||
patching the sourcecode and is not well maintainable.
|
||||
Now the builder can simply add there files.
|
||||
|
||||
v1 initial work of Hendrik Lüth <hendrik@linux-nerds.de>
|
||||
v2 changes regarding RFC (e.g. thomas.langer@lantiq.com)
|
||||
v3 changes regarding RFC (e.g. mschiffer@universe-factory.net)
|
||||
v4 keep it simple and mimic OpenWrt style
|
||||
|
||||
Signed-off-by: Bastian Bittorf <bittorf@bluebottle.com>
|
||||
|
||||
diff --git a/package/base-files/files/etc/profile b/package/base-files/files/etc/profile
|
||||
index 3dd58e1..577b63b 100644
|
||||
--- a/package/base-files/files/etc/profile
|
||||
+++ b/package/base-files/files/etc/profile
|
||||
@@ -14,3 +14,10 @@ export PS1='\u@\h:\w\$ '
|
||||
|
||||
[ -x /usr/bin/arp ] || arp() { cat /proc/net/arp; }
|
||||
[ -x /usr/bin/ldd ] || ldd() { LD_TRACE_LOADED_OBJECTS=1 $*; }
|
||||
+
|
||||
+[ -n "$FAILSAFE" ] || {
|
||||
+ for FILE in /etc/profile.d/*.sh; do
|
||||
+ [ -e "$FILE" ] && . "$FILE"
|
||||
+ done
|
||||
+ unset FILE
|
||||
+}
|
@ -1,49 +0,0 @@
|
||||
From: Andre Kasper <andre.kasper@gmx.de>
|
||||
Date: Mon, 12 Oct 2015 02:31:05 +0200
|
||||
Subject: Kernel: Realtek 8150 and Realtek 8152 based USB-to-Ethernet converters
|
||||
|
||||
This patch adds the kernel modules to for the very common Realtek RTL8150 and Realtek 8152 based USB-to-Ethernet converters.
|
||||
After this patch the following packages can be added to targets (or site.mk):
|
||||
kmod-usb-net-rtl8150
|
||||
kmod-usb-net-rtl8152
|
||||
|
||||
The modules are already available in openwrt trunk, but not in Chaos Calmer. This patch is just a temporary backport.
|
||||
The modules are needed for Futros with additional USB-Ethernet-Interface and VMs with dedicated USB-NIC
|
||||
|
||||
diff --git a/package/kernel/linux/modules/usb.mk b/package/kernel/linux/modules/usb.mk
|
||||
index d1ff455..86f452e 100644
|
||||
--- a/package/kernel/linux/modules/usb.mk
|
||||
+++ b/package/kernel/linux/modules/usb.mk
|
||||
@@ -1554,3 +1554,32 @@ define KernelPackage/usb3/description
|
||||
endef
|
||||
|
||||
$(eval $(call KernelPackage,usb3))
|
||||
+
|
||||
+define KernelPackage/usb-net-rtl8150
|
||||
+ TITLE:=Kernel module for USB-to-Ethernet Realtek convertors
|
||||
+ KCONFIG:=CONFIG_USB_RTL8150
|
||||
+ FILES:=$(LINUX_DIR)/drivers/$(USBNET_DIR)/rtl8150.ko
|
||||
+ AUTOLOAD:=$(call AutoProbe,rtl8150)
|
||||
+ $(call AddDepends/usb-net)
|
||||
+endef
|
||||
+
|
||||
+define KernelPackage/usb-net-rtl8150/description
|
||||
+ Kernel module for USB-to-Ethernet Realtek 8150 convertors
|
||||
+endef
|
||||
+
|
||||
+$(eval $(call KernelPackage,usb-net-rtl8150))
|
||||
+
|
||||
+
|
||||
+define KernelPackage/usb-net-rtl8152
|
||||
+ TITLE:=Kernel module for USB-to-Ethernet Realtek convertors
|
||||
+ KCONFIG:=CONFIG_USB_RTL8152
|
||||
+ FILES:=$(LINUX_DIR)/drivers/$(USBNET_DIR)/r8152.ko
|
||||
+ AUTOLOAD:=$(call AutoProbe,r8152)
|
||||
+ $(call AddDepends/usb-net)
|
||||
+endef
|
||||
+
|
||||
+define KernelPackage/usb-net-rtl8152/description
|
||||
+ Kernel module for USB-to-Ethernet Realtek 8152 USB2.0/3.0 convertors
|
||||
+endef
|
||||
+
|
||||
+$(eval $(call KernelPackage,usb-net-rtl8152))
|
@ -1,107 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 15 Oct 2015 20:03:51 +0200
|
||||
Subject: tools/firmware-utils: tplink-safeloader: clean up code
|
||||
|
||||
There is no reason for the internal functions not to be static.
|
||||
|
||||
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
|
||||
diff --git a/tools/firmware-utils/src/tplink-safeloader.c b/tools/firmware-utils/src/tplink-safeloader.c
|
||||
index 9c5bb54..4607a1d 100644
|
||||
--- a/tools/firmware-utils/src/tplink-safeloader.c
|
||||
+++ b/tools/firmware-utils/src/tplink-safeloader.c
|
||||
@@ -152,7 +152,7 @@ static const unsigned char cpe510_support_list[] =
|
||||
|
||||
|
||||
/** Allocates a new image partition */
|
||||
-struct image_partition_entry alloc_image_partition(const char *name, size_t len) {
|
||||
+static struct image_partition_entry alloc_image_partition(const char *name, size_t len) {
|
||||
struct image_partition_entry entry = {name, len, malloc(len)};
|
||||
if (!entry.data)
|
||||
error(1, errno, "malloc");
|
||||
@@ -161,12 +161,12 @@ struct image_partition_entry alloc_image_partition(const char *name, size_t len)
|
||||
}
|
||||
|
||||
/** Frees an image partition */
|
||||
-void free_image_partition(struct image_partition_entry entry) {
|
||||
+static void free_image_partition(struct image_partition_entry entry) {
|
||||
free(entry.data);
|
||||
}
|
||||
|
||||
/** Generates the partition-table partition */
|
||||
-struct image_partition_entry make_partition_table(const struct flash_partition_entry *p) {
|
||||
+static struct image_partition_entry make_partition_table(const struct flash_partition_entry *p) {
|
||||
struct image_partition_entry entry = alloc_image_partition("partition-table", 0x800);
|
||||
|
||||
char *s = (char *)entry.data, *end = (char *)(s+entry.size);
|
||||
@@ -202,7 +202,7 @@ static inline uint8_t bcd(uint8_t v) {
|
||||
|
||||
|
||||
/** Generates the soft-version partition */
|
||||
-struct image_partition_entry make_soft_version(uint32_t rev) {
|
||||
+static struct image_partition_entry make_soft_version(uint32_t rev) {
|
||||
struct image_partition_entry entry = alloc_image_partition("soft-version", sizeof(struct soft_version));
|
||||
struct soft_version *s = (struct soft_version *)entry.data;
|
||||
|
||||
@@ -233,14 +233,14 @@ struct image_partition_entry make_soft_version(uint32_t rev) {
|
||||
}
|
||||
|
||||
/** Generates the support-list partition */
|
||||
-struct image_partition_entry make_support_list(const unsigned char *support_list, size_t len) {
|
||||
+static struct image_partition_entry make_support_list(const unsigned char *support_list, size_t len) {
|
||||
struct image_partition_entry entry = alloc_image_partition("support-list", len);
|
||||
memcpy(entry.data, support_list, len);
|
||||
return entry;
|
||||
}
|
||||
|
||||
/** Creates a new image partition with an arbitrary name from a file */
|
||||
-struct image_partition_entry read_file(const char *part_name, const char *filename, bool add_jffs2_eof) {
|
||||
+static struct image_partition_entry read_file(const char *part_name, const char *filename, bool add_jffs2_eof) {
|
||||
struct stat statbuf;
|
||||
|
||||
if (stat(filename, &statbuf) < 0)
|
||||
@@ -300,7 +300,7 @@ struct image_partition_entry read_file(const char *part_name, const char *filena
|
||||
|
||||
I think partition-table must be the first partition in the firmware image.
|
||||
*/
|
||||
-void put_partitions(uint8_t *buffer, const struct image_partition_entry *parts) {
|
||||
+static void put_partitions(uint8_t *buffer, const struct image_partition_entry *parts) {
|
||||
size_t i;
|
||||
char *image_pt = (char *)buffer, *end = image_pt + 0x800;
|
||||
|
||||
@@ -325,7 +325,7 @@ void put_partitions(uint8_t *buffer, const struct image_partition_entry *parts)
|
||||
}
|
||||
|
||||
/** Generates and writes the image MD5 checksum */
|
||||
-void put_md5(uint8_t *md5, uint8_t *buffer, unsigned int len) {
|
||||
+static void put_md5(uint8_t *md5, uint8_t *buffer, unsigned int len) {
|
||||
MD5_CTX ctx;
|
||||
|
||||
MD5_Init(&ctx);
|
||||
@@ -349,7 +349,7 @@ void put_md5(uint8_t *md5, uint8_t *buffer, unsigned int len) {
|
||||
1014-1813 Image partition table (2048 bytes, padded with 0xff)
|
||||
1814-xxxx Firmware partitions
|
||||
*/
|
||||
-void * generate_factory_image(const unsigned char *vendor, size_t vendor_len, const struct image_partition_entry *parts, size_t *len) {
|
||||
+static void * generate_factory_image(const unsigned char *vendor, size_t vendor_len, const struct image_partition_entry *parts, size_t *len) {
|
||||
*len = 0x1814;
|
||||
|
||||
size_t i;
|
||||
@@ -381,7 +381,7 @@ void * generate_factory_image(const unsigned char *vendor, size_t vendor_len, co
|
||||
should be generalized when TP-LINK starts building its safeloader into hardware with
|
||||
different flash layouts.
|
||||
*/
|
||||
-void * generate_sysupgrade_image(const struct flash_partition_entry *flash_parts, const struct image_partition_entry *image_parts, size_t *len) {
|
||||
+static void * generate_sysupgrade_image(const struct flash_partition_entry *flash_parts, const struct image_partition_entry *image_parts, size_t *len) {
|
||||
const struct flash_partition_entry *flash_os_image = &flash_parts[5];
|
||||
const struct flash_partition_entry *flash_soft_version = &flash_parts[6];
|
||||
const struct flash_partition_entry *flash_support_list = &flash_parts[7];
|
||||
@@ -459,7 +459,7 @@ static void do_cpe510(const char *output, const char *kernel_image, const char *
|
||||
|
||||
|
||||
/** Usage output */
|
||||
-void usage(const char *argv0) {
|
||||
+static void usage(const char *argv0) {
|
||||
fprintf(stderr,
|
||||
"Usage: %s [OPTIONS...]\n"
|
||||
"\n"
|
@ -1,126 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 15 Oct 2015 21:01:25 +0200
|
||||
Subject: tools/firmware-utils: tplink-safeloader: fix support-list format, clean up vendor information
|
||||
|
||||
The first 4 bytes of the support list and the vendor information are
|
||||
supposed to contain the length of these fields.
|
||||
|
||||
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
|
||||
diff --git a/tools/firmware-utils/src/tplink-safeloader.c b/tools/firmware-utils/src/tplink-safeloader.c
|
||||
index 4607a1d..66658aa 100644
|
||||
--- a/tools/firmware-utils/src/tplink-safeloader.c
|
||||
+++ b/tools/firmware-utils/src/tplink-safeloader.c
|
||||
@@ -103,7 +103,7 @@ static const uint8_t md5_salt[16] = {
|
||||
|
||||
|
||||
/** Vendor information for CPE210/220/510/520 */
|
||||
-static const unsigned char cpe510_vendor[] = "\x00\x00\x00\x1f""CPE510(TP-LINK|UN|N300-5):1.0\r\n";
|
||||
+static const char cpe510_vendor[] = "CPE510(TP-LINK|UN|N300-5):1.0\r\n";
|
||||
|
||||
|
||||
/**
|
||||
@@ -133,14 +133,13 @@ static const struct flash_partition_entry cpe510_partitions[] = {
|
||||
The stock images also contain strings for two more devices: BS510 and BS210.
|
||||
At the moment, there exists no public information about these devices.
|
||||
*/
|
||||
-static const unsigned char cpe510_support_list[] =
|
||||
- "\x00\x00\x00\xc8\x00\x00\x00\x00"
|
||||
+static const char cpe510_support_list[] =
|
||||
"SupportList:\r\n"
|
||||
"CPE510(TP-LINK|UN|N300-5):1.0\r\n"
|
||||
"CPE520(TP-LINK|UN|N300-5):1.0\r\n"
|
||||
"CPE210(TP-LINK|UN|N300-2):1.0\r\n"
|
||||
"CPE220(TP-LINK|UN|N300-2):1.0\r\n"
|
||||
- "\r\n\xff";
|
||||
+ "\r\n";
|
||||
|
||||
#define error(_ret, _errno, _str, ...) \
|
||||
do { \
|
||||
@@ -151,6 +150,14 @@ static const unsigned char cpe510_support_list[] =
|
||||
} while (0)
|
||||
|
||||
|
||||
+/** Stores a uint32 as big endian */
|
||||
+static inline void put32(uint8_t *buf, uint32_t val) {
|
||||
+ buf[0] = val >> 24;
|
||||
+ buf[1] = val >> 16;
|
||||
+ buf[2] = val >> 8;
|
||||
+ buf[3] = val;
|
||||
+}
|
||||
+
|
||||
/** Allocates a new image partition */
|
||||
static struct image_partition_entry alloc_image_partition(const char *name, size_t len) {
|
||||
struct image_partition_entry entry = {name, len, malloc(len)};
|
||||
@@ -233,9 +240,15 @@ static struct image_partition_entry make_soft_version(uint32_t rev) {
|
||||
}
|
||||
|
||||
/** Generates the support-list partition */
|
||||
-static struct image_partition_entry make_support_list(const unsigned char *support_list, size_t len) {
|
||||
- struct image_partition_entry entry = alloc_image_partition("support-list", len);
|
||||
- memcpy(entry.data, support_list, len);
|
||||
+static struct image_partition_entry make_support_list(const char *support_list) {
|
||||
+ size_t len = strlen(support_list);
|
||||
+ struct image_partition_entry entry = alloc_image_partition("support-list", len + 9);
|
||||
+
|
||||
+ put32(entry.data, len);
|
||||
+ memset(entry.data+4, 0, 4);
|
||||
+ memcpy(entry.data+8, support_list, len);
|
||||
+ entry.data[len+8] = '\xff';
|
||||
+
|
||||
return entry;
|
||||
}
|
||||
|
||||
@@ -344,12 +357,13 @@ static void put_md5(uint8_t *md5, uint8_t *buffer, unsigned int len) {
|
||||
----------- -----
|
||||
0000-0003 Image size (4 bytes, big endian)
|
||||
0004-0013 MD5 hash (hash of a 16 byte salt and the image data starting with byte 0x14)
|
||||
- 0014-1013 Vendor information (4096 bytes, padded with 0xff; there seem to be older
|
||||
+ 0014-0017 Vendor information length (without padding) (4 bytes, big endian)
|
||||
+ 0018-1013 Vendor information (4092 bytes, padded with 0xff; there seem to be older
|
||||
(VxWorks-based) TP-LINK devices which use a smaller vendor information block)
|
||||
1014-1813 Image partition table (2048 bytes, padded with 0xff)
|
||||
1814-xxxx Firmware partitions
|
||||
*/
|
||||
-static void * generate_factory_image(const unsigned char *vendor, size_t vendor_len, const struct image_partition_entry *parts, size_t *len) {
|
||||
+static void * generate_factory_image(const char *vendor, const struct image_partition_entry *parts, size_t *len) {
|
||||
*len = 0x1814;
|
||||
|
||||
size_t i;
|
||||
@@ -360,13 +374,12 @@ static void * generate_factory_image(const unsigned char *vendor, size_t vendor_
|
||||
if (!image)
|
||||
error(1, errno, "malloc");
|
||||
|
||||
- image[0] = *len >> 24;
|
||||
- image[1] = *len >> 16;
|
||||
- image[2] = *len >> 8;
|
||||
- image[3] = *len;
|
||||
+ put32(image, *len);
|
||||
|
||||
- memcpy(image+0x14, vendor, vendor_len);
|
||||
- memset(image+0x14+vendor_len, 0xff, 4096-vendor_len);
|
||||
+ size_t vendor_len = strlen(vendor);
|
||||
+ put32(image+0x14, vendor_len);
|
||||
+ memcpy(image+0x18, vendor, vendor_len);
|
||||
+ memset(image+0x18+vendor_len, 0xff, 4092-vendor_len);
|
||||
|
||||
put_partitions(image + 0x1014, parts);
|
||||
put_md5(image+0x04, image+0x14, *len-0x14);
|
||||
@@ -430,7 +443,7 @@ static void do_cpe510(const char *output, const char *kernel_image, const char *
|
||||
|
||||
parts[0] = make_partition_table(cpe510_partitions);
|
||||
parts[1] = make_soft_version(rev);
|
||||
- parts[2] = make_support_list(cpe510_support_list, sizeof(cpe510_support_list)-1);
|
||||
+ parts[2] = make_support_list(cpe510_support_list);
|
||||
parts[3] = read_file("os-image", kernel_image, false);
|
||||
parts[4] = read_file("file-system", rootfs_image, add_jffs2_eof);
|
||||
|
||||
@@ -439,7 +452,7 @@ static void do_cpe510(const char *output, const char *kernel_image, const char *
|
||||
if (sysupgrade)
|
||||
image = generate_sysupgrade_image(cpe510_partitions, parts, &len);
|
||||
else
|
||||
- image = generate_factory_image(cpe510_vendor, sizeof(cpe510_vendor)-1, parts, &len);
|
||||
+ image = generate_factory_image(cpe510_vendor, parts, &len);
|
||||
|
||||
FILE *file = fopen(output, "wb");
|
||||
if (!file)
|
@ -1,38 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 15 Oct 2015 21:56:40 +0200
|
||||
Subject: tools/firmware-utils: tplink-safeloader: add version 1.1 support to CPE210/220/510/520
|
||||
|
||||
The hardware is identical to version 1.0, add the new models to the support
|
||||
list.
|
||||
|
||||
Also remove the empty line at the end of the support list, the current
|
||||
stock images don't have it either.
|
||||
|
||||
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
|
||||
diff --git a/tools/firmware-utils/src/tplink-safeloader.c b/tools/firmware-utils/src/tplink-safeloader.c
|
||||
index 66658aa..77a894b 100644
|
||||
--- a/tools/firmware-utils/src/tplink-safeloader.c
|
||||
+++ b/tools/firmware-utils/src/tplink-safeloader.c
|
||||
@@ -129,17 +129,17 @@ static const struct flash_partition_entry cpe510_partitions[] = {
|
||||
|
||||
/**
|
||||
The support list for CPE210/220/510/520
|
||||
-
|
||||
- The stock images also contain strings for two more devices: BS510 and BS210.
|
||||
- At the moment, there exists no public information about these devices.
|
||||
*/
|
||||
static const char cpe510_support_list[] =
|
||||
"SupportList:\r\n"
|
||||
"CPE510(TP-LINK|UN|N300-5):1.0\r\n"
|
||||
+ "CPE510(TP-LINK|UN|N300-5):1.1\r\n"
|
||||
"CPE520(TP-LINK|UN|N300-5):1.0\r\n"
|
||||
+ "CPE520(TP-LINK|UN|N300-5):1.1\r\n"
|
||||
"CPE210(TP-LINK|UN|N300-2):1.0\r\n"
|
||||
+ "CPE210(TP-LINK|UN|N300-2):1.1\r\n"
|
||||
"CPE220(TP-LINK|UN|N300-2):1.0\r\n"
|
||||
- "\r\n";
|
||||
+ "CPE220(TP-LINK|UN|N300-2):1.1\r\n";
|
||||
|
||||
#define error(_ret, _errno, _str, ...) \
|
||||
do { \
|
@ -1,181 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 22 Oct 2015 00:33:25 +0200
|
||||
Subject: ar71xx: fix ath79_soc_rev value for QCA9531 ver. 2
|
||||
|
||||
ath9k expects to get revision id 2 for the QCA9531 ver. 2 rev. 0. This
|
||||
fixes the very low TX power on some devices like the TP-LINK
|
||||
TL-WR841ND v10.
|
||||
|
||||
As ath79_soc_rev is only used to get the revision number to ath9k on the
|
||||
QCA9533, just set it to the expected value on the ver. 2.
|
||||
|
||||
diff --git a/target/linux/ar71xx/patches-3.18/707-MIPS-ath79-add-support-for-QCA953x-SoC.patch b/target/linux/ar71xx/patches-3.18/707-MIPS-ath79-add-support-for-QCA953x-SoC.patch
|
||||
index 403897a..cf10af3 100644
|
||||
--- a/target/linux/ar71xx/patches-3.18/707-MIPS-ath79-add-support-for-QCA953x-SoC.patch
|
||||
+++ b/target/linux/ar71xx/patches-3.18/707-MIPS-ath79-add-support-for-QCA953x-SoC.patch
|
||||
@@ -44,7 +44,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
config ATH79_NVRAM
|
||||
--- a/arch/mips/ath79/clock.c
|
||||
+++ b/arch/mips/ath79/clock.c
|
||||
-@@ -350,6 +350,91 @@ static void __init ar934x_clocks_init(void)
|
||||
+@@ -350,6 +350,91 @@ static void __init ar934x_clocks_init(vo
|
||||
iounmap(dpll_base);
|
||||
}
|
||||
|
||||
@@ -177,7 +177,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
platform_device_register(&ath79_uart_device);
|
||||
--- a/arch/mips/ath79/dev-usb.c
|
||||
+++ b/arch/mips/ath79/dev-usb.c
|
||||
-@@ -236,6 +236,30 @@ static void __init ar934x_usb_setup(void)
|
||||
+@@ -236,6 +236,30 @@ static void __init ar934x_usb_setup(void
|
||||
&ath79_ehci_pdata_v2, sizeof(ath79_ehci_pdata_v2));
|
||||
}
|
||||
|
||||
@@ -228,7 +228,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
{
|
||||
return ath79_soc_rev;
|
||||
}
|
||||
-@@ -126,7 +126,7 @@ static void __init ar933x_wmac_setup(void)
|
||||
+@@ -126,7 +126,7 @@ static void __init ar933x_wmac_setup(voi
|
||||
ath79_wmac_data.is_clk_25mhz = true;
|
||||
|
||||
if (ath79_soc_rev == 1)
|
||||
@@ -237,8 +237,8 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
|
||||
ath79_wmac_data.external_reset = ar933x_wmac_reset;
|
||||
}
|
||||
-@@ -151,6 +151,26 @@ static void ar934x_wmac_setup(void)
|
||||
- ath79_wmac_data.get_mac_revision = ar93xx_get_soc_revision;
|
||||
+@@ -149,6 +149,26 @@ static void ar934x_wmac_setup(void)
|
||||
+ ath79_wmac_data.is_clk_25mhz = true;
|
||||
}
|
||||
|
||||
+static void qca953x_wmac_setup(void)
|
||||
@@ -264,7 +264,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
static void qca955x_wmac_setup(void)
|
||||
{
|
||||
u32 t;
|
||||
-@@ -368,6 +388,8 @@ void __init ath79_register_wmac(u8 *cal_data, u8 *mac_addr)
|
||||
+@@ -366,6 +386,8 @@ void __init ath79_register_wmac(u8 *cal_
|
||||
ar933x_wmac_setup();
|
||||
else if (soc_is_ar934x())
|
||||
ar934x_wmac_setup();
|
||||
@@ -286,7 +286,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
_prom_putchar = prom_putchar_ar71xx;
|
||||
--- a/arch/mips/ath79/gpio.c
|
||||
+++ b/arch/mips/ath79/gpio.c
|
||||
-@@ -148,7 +148,7 @@ static void __iomem *ath79_gpio_get_function_reg(void)
|
||||
+@@ -148,7 +148,7 @@ static void __iomem *ath79_gpio_get_func
|
||||
soc_is_ar913x() ||
|
||||
soc_is_ar933x())
|
||||
reg = AR71XX_GPIO_REG_FUNC;
|
||||
@@ -295,7 +295,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
reg = AR934X_GPIO_REG_FUNC;
|
||||
else
|
||||
BUG();
|
||||
-@@ -187,7 +187,7 @@ void __init ath79_gpio_output_select(unsigned gpio, u8 val)
|
||||
+@@ -187,7 +187,7 @@ void __init ath79_gpio_output_select(uns
|
||||
unsigned int reg;
|
||||
u32 t, s;
|
||||
|
||||
@@ -324,7 +324,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
}
|
||||
--- a/arch/mips/ath79/irq.c
|
||||
+++ b/arch/mips/ath79/irq.c
|
||||
-@@ -106,6 +106,7 @@ static void __init ath79_misc_irq_init(void)
|
||||
+@@ -106,6 +106,7 @@ static void __init ath79_misc_irq_init(v
|
||||
else if (soc_is_ar724x() ||
|
||||
soc_is_ar933x() ||
|
||||
soc_is_ar934x() ||
|
||||
@@ -405,7 +405,7 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
}
|
||||
--- a/arch/mips/ath79/setup.c
|
||||
+++ b/arch/mips/ath79/setup.c
|
||||
-@@ -60,6 +60,7 @@ static void __init ath79_detect_sys_type(void)
|
||||
+@@ -59,6 +59,7 @@ static void __init ath79_detect_sys_type
|
||||
u32 major;
|
||||
u32 minor;
|
||||
u32 rev = 0;
|
||||
@@ -413,12 +413,13 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
|
||||
id = ath79_reset_rr(AR71XX_RESET_REG_REV_ID);
|
||||
major = id & REV_ID_MAJOR_MASK;
|
||||
-@@ -152,6 +153,16 @@ static void __init ath79_detect_sys_type(void)
|
||||
+@@ -151,6 +152,17 @@ static void __init ath79_detect_sys_type
|
||||
rev = id & AR934X_REV_ID_REVISION_MASK;
|
||||
break;
|
||||
|
||||
+ case REV_ID_MAJOR_QCA9533_V2:
|
||||
+ ver = 2;
|
||||
++ ath79_soc_rev = 2;
|
||||
+ /* drop through */
|
||||
+
|
||||
+ case REV_ID_MAJOR_QCA9533:
|
||||
@@ -430,15 +431,23 @@ meaning of the bits CPUCLK_FROM_CPUPLL and DDRCLK_FROM_DDRPLL is reversed.
|
||||
case REV_ID_MAJOR_QCA9556:
|
||||
ath79_soc = ATH79_SOC_QCA9556;
|
||||
chip = "9556";
|
||||
-@@ -170,7 +181,7 @@ static void __init ath79_detect_sys_type(void)
|
||||
+@@ -167,11 +179,12 @@ static void __init ath79_detect_sys_type
|
||||
+ panic("ath79: unknown SoC, id:0x%08x", id);
|
||||
+ }
|
||||
|
||||
- ath79_soc_rev = rev;
|
||||
+- ath79_soc_rev = rev;
|
||||
++ if (ver == 1)
|
||||
++ ath79_soc_rev = rev;
|
||||
|
||||
- if (soc_is_qca955x())
|
||||
+- sprintf(ath79_sys_type, "Qualcomm Atheros QCA%s rev %u",
|
||||
+- chip, rev);
|
||||
+ if (soc_is_qca953x() || soc_is_qca955x())
|
||||
- sprintf(ath79_sys_type, "Qualcomm Atheros QCA%s rev %u",
|
||||
- chip, rev);
|
||||
++ sprintf(ath79_sys_type, "Qualcomm Atheros QCA%s ver %u rev %u",
|
||||
++ chip, ver, rev);
|
||||
else
|
||||
+ sprintf(ath79_sys_type, "Atheros AR%s rev %u", chip, rev);
|
||||
+ pr_info("SoC: %s\n", ath79_sys_type);
|
||||
--- a/arch/mips/include/asm/mach-ath79/ar71xx_regs.h
|
||||
+++ b/arch/mips/include/asm/mach-ath79/ar71xx_regs.h
|
||||
@@ -105,6 +105,21 @@
|
||||
diff --git a/target/linux/ar71xx/patches-3.18/735-MIPS-ath79-add-support-for-QCA956x-SoC.patch b/target/linux/ar71xx/patches-3.18/735-MIPS-ath79-add-support-for-QCA956x-SoC.patch
|
||||
index 2bdc744..eecccdc 100644
|
||||
--- a/target/linux/ar71xx/patches-3.18/735-MIPS-ath79-add-support-for-QCA956x-SoC.patch
|
||||
+++ b/target/linux/ar71xx/patches-3.18/735-MIPS-ath79-add-support-for-QCA956x-SoC.patch
|
||||
@@ -452,7 +452,7 @@
|
||||
return -ENODEV;
|
||||
--- a/arch/mips/ath79/setup.c
|
||||
+++ b/arch/mips/ath79/setup.c
|
||||
-@@ -175,14 +175,29 @@ static void __init ath79_detect_sys_type
|
||||
+@@ -176,6 +176,18 @@ static void __init ath79_detect_sys_type
|
||||
rev = id & QCA955X_REV_ID_REVISION_MASK;
|
||||
break;
|
||||
|
||||
@@ -471,19 +471,20 @@
|
||||
default:
|
||||
panic("ath79: unknown SoC, id:0x%08x", id);
|
||||
}
|
||||
-
|
||||
- ath79_soc_rev = rev;
|
||||
+@@ -183,9 +195,12 @@ static void __init ath79_detect_sys_type
|
||||
+ if (ver == 1)
|
||||
+ ath79_soc_rev = rev;
|
||||
|
||||
- if (soc_is_qca953x() || soc_is_qca955x())
|
||||
-- sprintf(ath79_sys_type, "Qualcomm Atheros QCA%s rev %u",
|
||||
+ if (soc_is_qca953x() || soc_is_qca955x() || soc_is_qca9561())
|
||||
-+ sprintf(ath79_sys_type, "Qualcomm Atheros QCA%s ver %u rev %u",
|
||||
-+ chip, ver, rev);
|
||||
+ sprintf(ath79_sys_type, "Qualcomm Atheros QCA%s ver %u rev %u",
|
||||
+ chip, ver, rev);
|
||||
+ else if (soc_is_tp9343())
|
||||
+ sprintf(ath79_sys_type, "Qualcomm Atheros TP%s rev %u",
|
||||
- chip, rev);
|
||||
++ chip, rev);
|
||||
else
|
||||
sprintf(ath79_sys_type, "Atheros AR%s rev %u", chip, rev);
|
||||
+ pr_info("SoC: %s\n", ath79_sys_type);
|
||||
--- a/arch/mips/include/asm/mach-ath79/ar71xx_regs.h
|
||||
+++ b/arch/mips/include/asm/mach-ath79/ar71xx_regs.h
|
||||
@@ -143,6 +143,23 @@
|
@ -1,82 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Sat, 24 Oct 2015 21:53:10 +0200
|
||||
Subject: mac80211: fix crash when using mesh (11s) VIF together with another VIF
|
||||
|
||||
Using a 802.11s mesh VIF together with a different VIF (e.g. IBSS) led to
|
||||
a panic.
|
||||
|
||||
Steps to reproduce:
|
||||
|
||||
rmmod mac80211_hwsim
|
||||
insmod /lib/modules/3.18.21/mac80211_hwsim.ko channels=2
|
||||
iw phy phy2 interface add ibss2 type ibss
|
||||
iw phy phy2 interface add mesh2 type mp
|
||||
iw phy phy3 interface add ibss3 type ibss
|
||||
iw phy phy3 interface add mesh3 type mp
|
||||
ip link set ibss2 up
|
||||
ip link set mesh2 up
|
||||
ip link set ibss3 up
|
||||
ip link set mesh3 up
|
||||
iw dev ibss2 ibss join foo 2412
|
||||
iw dev ibss3 ibss join foo 2412
|
||||
# Ensure that ibss2 and ibss3 are associated, otherwise leave and join
|
||||
# on ibss3 again
|
||||
iw dev mesh2 mesh join bar
|
||||
iw dev mesh3 mesh join bar
|
||||
|
||||
The patch has also been submitted upstream.
|
||||
|
||||
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
|
||||
diff --git a/package/kernel/mac80211/patches/339-mac80211-fix-crash-on-mesh-local-link-ID-generation-.patch b/package/kernel/mac80211/patches/339-mac80211-fix-crash-on-mesh-local-link-ID-generation-.patch
|
||||
new file mode 100644
|
||||
index 0000000..5784b98
|
||||
--- /dev/null
|
||||
+++ b/package/kernel/mac80211/patches/339-mac80211-fix-crash-on-mesh-local-link-ID-generation-.patch
|
||||
@@ -0,0 +1,46 @@
|
||||
+From 604f8b1964b8380eddf1f03dbdafa7a1c13d80d6 Mon Sep 17 00:00:00 2001
|
||||
+Message-Id: <604f8b1964b8380eddf1f03dbdafa7a1c13d80d6.1445716231.git.mschiffer@universe-factory.net>
|
||||
+From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
+Date: Sat, 24 Oct 2015 21:25:51 +0200
|
||||
+Subject: [PATCH] mac80211: fix crash on mesh local link ID generation with
|
||||
+ VIFs
|
||||
+
|
||||
+llid_in_use needs to be limited to stations of the same VIF, otherwise it
|
||||
+will cause a NULL deref as the sta_info of non-mesh-VIFs don't have
|
||||
+sta->mesh set.
|
||||
+
|
||||
+Steps to reproduce:
|
||||
+
|
||||
+ modprobe mac80211_hwsim channels=2
|
||||
+ iw phy phy0 interface add ibss0 type ibss
|
||||
+ iw phy phy0 interface add mesh0 type mp
|
||||
+ iw phy phy1 interface add ibss1 type ibss
|
||||
+ iw phy phy1 interface add mesh1 type mp
|
||||
+ ip link set ibss0 up
|
||||
+ ip link set mesh0 up
|
||||
+ ip link set ibss1 up
|
||||
+ ip link set mesh1 up
|
||||
+ iw dev ibss0 ibss join foo 2412
|
||||
+ iw dev ibss1 ibss join foo 2412
|
||||
+ # Ensure that ibss0 and ibss1 are actually associated; I often need to
|
||||
+ # leave and join the cell on ibss1 a second time.
|
||||
+ iw dev mesh0 mesh join bar
|
||||
+ iw dev mesh1 mesh join bar # crash
|
||||
+
|
||||
+Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
+---
|
||||
+ net/mac80211/mesh_plink.c | 3 +++
|
||||
+ 1 file changed, 3 insertions(+)
|
||||
+
|
||||
+--- a/net/mac80211/mesh_plink.c
|
||||
++++ b/net/mac80211/mesh_plink.c
|
||||
+@@ -646,6 +646,9 @@ static bool llid_in_use(struct ieee80211
|
||||
+
|
||||
+ rcu_read_lock();
|
||||
+ list_for_each_entry_rcu(sta, &local->sta_list, list) {
|
||||
++ if (sdata != sta->sdata)
|
||||
++ continue;
|
||||
++
|
||||
+ if (!memcmp(&sta->mesh->llid, &llid, sizeof(llid))) {
|
||||
+ in_use = true;
|
||||
+ break;
|
@ -1,70 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Tue, 10 Mar 2015 13:17:14 +0100
|
||||
Subject: ath10k: add Candelatech community firmware as an additional choice
|
||||
|
||||
diff --git a/package/kernel/mac80211/Makefile b/package/kernel/mac80211/Makefile
|
||||
index 566e156..1dc1816 100644
|
||||
--- a/package/kernel/mac80211/Makefile
|
||||
+++ b/package/kernel/mac80211/Makefile
|
||||
@@ -270,6 +270,29 @@ Atheros IEEE 802.11ac family of chipsets. For now only
|
||||
PCI is supported.
|
||||
endef
|
||||
|
||||
+define KernelPackage/ath10k/config
|
||||
+ if PACKAGE_kmod-ath10k
|
||||
+ choice
|
||||
+ prompt "ath10k firmware flavour"
|
||||
+ default ATH10K_AP_FW
|
||||
+ help
|
||||
+ This option allows you to choose between different ath10k firmwares.
|
||||
+
|
||||
+ config ATH10K_AP_FW
|
||||
+ bool "Firmware optimized for AP operation"
|
||||
+ help
|
||||
+ Use the ath10k firmware optimized for access point operation.
|
||||
+ Supports only AP mode, will crash in IBSS (ad-hoc) mode.
|
||||
+
|
||||
+ config ATH10K_CT_COMMUNITY_FW
|
||||
+ bool "Firmware by Candela Technologies (community version)"
|
||||
+ help
|
||||
+ Supports both AP and IBSS (ad-hoc) mode. Doesn't support
|
||||
+ encryption when using multiple VIFs.
|
||||
+ endchoice
|
||||
+ endif
|
||||
+ endef
|
||||
+
|
||||
PKG_ATH10K_LINUX_FIRMWARE_NAME:=ath10k-firmware
|
||||
PKG_ATH10K_LINUX_FIRMWARE_VERSION:=b46f3e01a6c1f9150fb4612ef53611d714565842
|
||||
PKG_ATH10K_LINUX_FIRMWARE_SOURCE:=$(PKG_ATH10K_LINUX_FIRMWARE_NAME)-$(PKG_ATH10K_LINUX_FIRMWARE_VERSION).tar.bz2
|
||||
@@ -288,6 +311,14 @@ define Download/ath10k-firmware
|
||||
endef
|
||||
$(eval $(call Download,ath10k-firmware))
|
||||
|
||||
+ATH10K_CT_COMMUNITY_FW:=firmware-2-ct-full-community-14.bin
|
||||
+define Download/ath10k-firmware-ct-community
|
||||
+ FILE:=$(ATH10K_CT_COMMUNITY_FW)
|
||||
+ URL:=http://www.candelatech.com/downloads/
|
||||
+ MD5SUM:=800799459c20c1683138c74b3ba58f25
|
||||
+endef
|
||||
+$(eval $(call Download,ath10k-firmware-ct-community))
|
||||
+
|
||||
|
||||
#Broadcom firmware
|
||||
ifneq ($(CONFIG_B43_FW_6_30),)
|
||||
@@ -1854,9 +1885,16 @@ define KernelPackage/ath10k/install
|
||||
$(INSTALL_DATA) \
|
||||
$(PKG_BUILD_DIR)/$(PKG_ATH10K_LINUX_FIRMWARE_SUBDIR)/ath10k/QCA988X/hw2.0/board.bin \
|
||||
$(1)/lib/firmware/ath10k/QCA988X/hw2.0/
|
||||
+ifeq ($(CONFIG_ATH10K_AP_FW),y)
|
||||
$(INSTALL_DATA) \
|
||||
$(PKG_BUILD_DIR)/$(PKG_ATH10K_LINUX_FIRMWARE_SUBDIR)/10.2.4/untested/firmware-5.bin_10.2.4.70-2 \
|
||||
$(1)/lib/firmware/ath10k/QCA988X/hw2.0/firmware-5.bin
|
||||
+endif
|
||||
+ifeq ($(CONFIG_ATH10K_CT_COMMUNITY_FW),y)
|
||||
+ $(INSTALL_DATA) \
|
||||
+ $(DL_DIR)/$(ATH10K_CT_COMMUNITY_FW) \
|
||||
+ $(1)/lib/firmware/ath10k/QCA988X/hw2.0/firmware-2.bin
|
||||
+endif
|
||||
endef
|
||||
|
||||
define KernelPackage/b43/install
|
@ -1,35 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Tue, 1 Sep 2015 19:59:16 +0200
|
||||
Subject: mac80211: ath9k: add correct MAC/BB name for ar9561
|
||||
|
||||
diff --git a/package/kernel/mac80211/patches/546-ath9k_add-correct-MAC-BB-name-for-ar9561.patch b/package/kernel/mac80211/patches/546-ath9k_add-correct-MAC-BB-name-for-ar9561.patch
|
||||
new file mode 100644
|
||||
index 0000000..a2a2c78
|
||||
--- /dev/null
|
||||
+++ b/package/kernel/mac80211/patches/546-ath9k_add-correct-MAC-BB-name-for-ar9561.patch
|
||||
@@ -0,0 +1,25 @@
|
||||
+From 1165dd900cc8de3addbc8bef7e6196b07799d25e Mon Sep 17 00:00:00 2001
|
||||
+From: Miaoqing Pan <miaoqing@qca.qualcomm.com>
|
||||
+Date: Wed, 12 Aug 2015 14:20:46 +0800
|
||||
+Subject: ath9k: add correct MAC/BB name for ar9561
|
||||
+
|
||||
+MAC/BB name is"????" if the MAC/BB is unknown.
|
||||
+
|
||||
+Signed-off-by: Miaoqing Pan <miaoqing@qca.qualcomm.com>
|
||||
+Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
|
||||
+
|
||||
+diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c
|
||||
+index a31a680..1dd0339 100644
|
||||
+--- a/drivers/net/wireless/ath/ath9k/hw.c
|
||||
++++ b/drivers/net/wireless/ath/ath9k/hw.c
|
||||
+@@ -3186,6 +3186,7 @@ static struct {
|
||||
+ { AR_SREV_VERSION_9550, "9550" },
|
||||
+ { AR_SREV_VERSION_9565, "9565" },
|
||||
+ { AR_SREV_VERSION_9531, "9531" },
|
||||
++ { AR_SREV_VERSION_9561, "9561" },
|
||||
+ };
|
||||
+
|
||||
+ /* For devices with external radios */
|
||||
+--
|
||||
+cgit v0.10.2
|
||||
+
|
@ -1,330 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Mon, 2 Nov 2015 19:21:20 +0100
|
||||
Subject: ar71xx: add support for TP-LINK TL-WR941ND v6 (international version)
|
||||
|
||||
diff --git a/target/linux/ar71xx/base-files/etc/diag.sh b/target/linux/ar71xx/base-files/etc/diag.sh
|
||||
index 89fe53c..3e80c32 100644
|
||||
--- a/target/linux/ar71xx/base-files/etc/diag.sh
|
||||
+++ b/target/linux/ar71xx/base-files/etc/diag.sh
|
||||
@@ -279,7 +279,8 @@ get_status_led() {
|
||||
tl-wdr4300 | \
|
||||
tl-wr703n | \
|
||||
tl-wr710n | \
|
||||
- tl-wr720n-v3)
|
||||
+ tl-wr720n-v3 | \
|
||||
+ tl-wr941nd-v6)
|
||||
status_led="tp-link:blue:system"
|
||||
;;
|
||||
tl-wr841n-v9)
|
||||
diff --git a/target/linux/ar71xx/base-files/etc/uci-defaults/01_leds b/target/linux/ar71xx/base-files/etc/uci-defaults/01_leds
|
||||
index 5241db2..11b3fa0 100644
|
||||
--- a/target/linux/ar71xx/base-files/etc/uci-defaults/01_leds
|
||||
+++ b/target/linux/ar71xx/base-files/etc/uci-defaults/01_leds
|
||||
@@ -460,6 +460,15 @@ tl-wr941nd-v5)
|
||||
ucidef_set_led_wlan "wlan" "WLAN" "tp-link:green:wlan" "phy0tpt"
|
||||
;;
|
||||
|
||||
+tl-wr941nd-v6)
|
||||
+ ucidef_set_led_netdev "wan" "WAN" "tp-link:blue:wan" "eth0"
|
||||
+ ucidef_set_led_switch "lan1" "LAN1" "tp-link:blue:lan1" "switch0" "0x10"
|
||||
+ ucidef_set_led_switch "lan2" "LAN2" "tp-link:blue:lan2" "switch0" "0x08"
|
||||
+ ucidef_set_led_switch "lan3" "LAN3" "tp-link:blue:lan3" "switch0" "0x04"
|
||||
+ ucidef_set_led_switch "lan4" "LAN4" "tp-link:blue:lan4" "switch0" "0x02"
|
||||
+ ucidef_set_led_wlan "wlan" "WLAN" "tp-link:blue:wlan" "phy0tpt"
|
||||
+ ;;
|
||||
+
|
||||
tl-wa830re-v2)
|
||||
ucidef_set_led_netdev "lan" "LAN" "tp-link:green:lan" "eth0"
|
||||
ucidef_set_led_wlan "wlan" "WLAN" "tp-link:green:wlan" "phy0tpt"
|
||||
diff --git a/target/linux/ar71xx/base-files/etc/uci-defaults/02_network b/target/linux/ar71xx/base-files/etc/uci-defaults/02_network
|
||||
index 5c38c54..2f0855c 100755
|
||||
--- a/target/linux/ar71xx/base-files/etc/uci-defaults/02_network
|
||||
+++ b/target/linux/ar71xx/base-files/etc/uci-defaults/02_network
|
||||
@@ -226,6 +226,7 @@ tl-mr3420-v2 |\
|
||||
tl-wr841n-v8 |\
|
||||
tl-wr842n-v2 |\
|
||||
tl-wr941nd-v5 |\
|
||||
+tl-wr941nd-v6 |\
|
||||
wnr2000-v3 |\
|
||||
wnr2000-v4 |\
|
||||
wnr2200 |\
|
||||
diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
index af92b01..9c7c139 100755
|
||||
--- a/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
+++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
@@ -799,6 +799,9 @@ ar71xx_board_detect() {
|
||||
*"TL-WR941N/ND v5")
|
||||
name="tl-wr941nd-v5"
|
||||
;;
|
||||
+ *"TL-WR941N/ND v6")
|
||||
+ name="tl-wr941nd-v6"
|
||||
+ ;;
|
||||
*"TL-WR703N v1")
|
||||
name="tl-wr703n"
|
||||
;;
|
||||
diff --git a/target/linux/ar71xx/base-files/lib/preinit/05_set_preinit_iface_ar71xx b/target/linux/ar71xx/base-files/lib/preinit/05_set_preinit_iface_ar71xx
|
||||
index f11ea8c..fd337e1 100644
|
||||
--- a/target/linux/ar71xx/base-files/lib/preinit/05_set_preinit_iface_ar71xx
|
||||
+++ b/target/linux/ar71xx/base-files/lib/preinit/05_set_preinit_iface_ar71xx
|
||||
@@ -35,6 +35,7 @@ set_preinit_iface() {
|
||||
tl-wr720n-v3 |\
|
||||
tl-wr841n-v8 |\
|
||||
tl-wr842n-v2 |\
|
||||
+ tl-wr941nd-v6 |\
|
||||
wnr2000-v3 |\
|
||||
wnr2200 |\
|
||||
wnr612-v2 |\
|
||||
diff --git a/target/linux/ar71xx/base-files/lib/upgrade/platform.sh b/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
|
||||
index ab69e4f..f181a63 100755
|
||||
--- a/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
|
||||
+++ b/target/linux/ar71xx/base-files/lib/upgrade/platform.sh
|
||||
@@ -354,6 +354,7 @@ platform_check_image() {
|
||||
tl-wr842n-v2 | \
|
||||
tl-wr941nd | \
|
||||
tl-wr941nd-v5 | \
|
||||
+ tl-wr941nd-v6 | \
|
||||
tl-wr1041n-v2 | \
|
||||
tl-wr1043nd | \
|
||||
tl-wr1043nd-v2 | \
|
||||
diff --git a/target/linux/ar71xx/config-3.18 b/target/linux/ar71xx/config-3.18
|
||||
index e9b3c7c..84b5844 100644
|
||||
--- a/target/linux/ar71xx/config-3.18
|
||||
+++ b/target/linux/ar71xx/config-3.18
|
||||
@@ -132,6 +132,7 @@ 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_TL_WR941ND_V6=y
|
||||
CONFIG_ATH79_MACH_TUBE2H=y
|
||||
CONFIG_ATH79_MACH_UBNT=y
|
||||
CONFIG_ATH79_MACH_UBNT_XM=y
|
||||
diff --git a/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr941nd-v6.c b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr941nd-v6.c
|
||||
new file mode 100644
|
||||
index 0000000..8c788e2
|
||||
--- /dev/null
|
||||
+++ b/target/linux/ar71xx/files/arch/mips/ath79/mach-tl-wr941nd-v6.c
|
||||
@@ -0,0 +1,149 @@
|
||||
+/*
|
||||
+ * TP-LINK TL-WR941N/ND v6 board support
|
||||
+ *
|
||||
+ * Copyright (C) 2015 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_WR941ND_V6_GPIO_LED_QSS 3
|
||||
+#define TL_WR941ND_V6_GPIO_LED_WAN 14
|
||||
+#define TL_WR941ND_V6_GPIO_LED_WAN_RED 15
|
||||
+#define TL_WR941ND_V6_GPIO_LED_LAN1 7
|
||||
+#define TL_WR941ND_V6_GPIO_LED_LAN2 6
|
||||
+#define TL_WR941ND_V6_GPIO_LED_LAN3 5
|
||||
+#define TL_WR941ND_V6_GPIO_LED_LAN4 4
|
||||
+#define TL_WR941ND_V6_GPIO_LED_WLAN 8
|
||||
+#define TL_WR941ND_V6_GPIO_LED_SYSTEM 18
|
||||
+
|
||||
+#define TL_WR941ND_V6_GPIO_BTN_RESET 1
|
||||
+#define TL_WR941ND_V6_GPIO_BTN_RFKILL 2
|
||||
+
|
||||
+#define TL_WR941ND_V6_KEYS_POLL_INTERVAL 20
|
||||
+#define TL_WR941ND_V6_KEYS_DEBOUNCE_INTERVAL (3 * TL_WR941ND_V6_KEYS_POLL_INTERVAL)
|
||||
+
|
||||
+
|
||||
+static struct gpio_led tl_wr941nd_v6_leds_gpio[] __initdata = {
|
||||
+ {
|
||||
+ .name = "tp-link:blue:qss",
|
||||
+ .gpio = TL_WR941ND_V6_GPIO_LED_QSS,
|
||||
+ .active_low = 1,
|
||||
+ },
|
||||
+ {
|
||||
+ .name = "tp-link:blue:wan",
|
||||
+ .gpio = TL_WR941ND_V6_GPIO_LED_WAN,
|
||||
+ .active_low = 1,
|
||||
+ },
|
||||
+ {
|
||||
+ .name = "tp-link:red:wan",
|
||||
+ .gpio = TL_WR941ND_V6_GPIO_LED_WAN_RED,
|
||||
+ .active_low = 0,
|
||||
+ },
|
||||
+ {
|
||||
+ .name = "tp-link:blue:lan1",
|
||||
+ .gpio = TL_WR941ND_V6_GPIO_LED_LAN1,
|
||||
+ .active_low = 1,
|
||||
+ },
|
||||
+ {
|
||||
+ .name = "tp-link:blue:lan2",
|
||||
+ .gpio = TL_WR941ND_V6_GPIO_LED_LAN2,
|
||||
+ .active_low = 1,
|
||||
+ },
|
||||
+ {
|
||||
+ .name = "tp-link:blue:lan3",
|
||||
+ .gpio = TL_WR941ND_V6_GPIO_LED_LAN3,
|
||||
+ .active_low = 1,
|
||||
+ },
|
||||
+ {
|
||||
+ .name = "tp-link:blue:lan4",
|
||||
+ .gpio = TL_WR941ND_V6_GPIO_LED_LAN4,
|
||||
+ .active_low = 1,
|
||||
+ },
|
||||
+ {
|
||||
+ .name = "tp-link:blue:wlan",
|
||||
+ .gpio = TL_WR941ND_V6_GPIO_LED_WLAN,
|
||||
+ .active_low = 1,
|
||||
+ },
|
||||
+ {
|
||||
+ .name = "tp-link:blue:system",
|
||||
+ .gpio = TL_WR941ND_V6_GPIO_LED_SYSTEM,
|
||||
+ .active_low = 1,
|
||||
+ },
|
||||
+};
|
||||
+
|
||||
+static struct gpio_keys_button tl_wr941nd_v6_gpio_keys[] __initdata = {
|
||||
+ {
|
||||
+ .desc = "Reset button",
|
||||
+ .type = EV_KEY,
|
||||
+ .code = KEY_RESTART,
|
||||
+ .debounce_interval = TL_WR941ND_V6_KEYS_DEBOUNCE_INTERVAL,
|
||||
+ .gpio = TL_WR941ND_V6_GPIO_BTN_RESET,
|
||||
+ .active_low = 1,
|
||||
+ }, {
|
||||
+ .desc = "RFKILL button",
|
||||
+ .type = EV_KEY,
|
||||
+ .code = KEY_RFKILL,
|
||||
+ .debounce_interval = TL_WR941ND_V6_KEYS_DEBOUNCE_INTERVAL,
|
||||
+ .gpio = TL_WR941ND_V6_GPIO_BTN_RFKILL,
|
||||
+ .active_low = 1,
|
||||
+ }
|
||||
+};
|
||||
+
|
||||
+
|
||||
+static const char *tl_wr941n_v6_part_probes[] = {
|
||||
+ "tp-link",
|
||||
+ NULL,
|
||||
+};
|
||||
+
|
||||
+static struct flash_platform_data tl_wr941n_v6_flash_data = {
|
||||
+ .part_probes = tl_wr941n_v6_part_probes,
|
||||
+};
|
||||
+
|
||||
+
|
||||
+static void __init tl_wr941nd_v6_setup(void)
|
||||
+{
|
||||
+ u8 *mac = (u8 *) KSEG1ADDR(0x1f01fc00);
|
||||
+ u8 *ee = (u8 *) KSEG1ADDR(0x1fff1000);
|
||||
+
|
||||
+ ath79_register_m25p80(&tl_wr941n_v6_flash_data);
|
||||
+
|
||||
+ ath79_register_leds_gpio(-1, ARRAY_SIZE(tl_wr941nd_v6_leds_gpio),
|
||||
+ tl_wr941nd_v6_leds_gpio);
|
||||
+
|
||||
+ ath79_register_gpio_keys_polled(-1, TL_WR941ND_V6_KEYS_POLL_INTERVAL,
|
||||
+ ARRAY_SIZE(tl_wr941nd_v6_gpio_keys),
|
||||
+ tl_wr941nd_v6_gpio_keys);
|
||||
+
|
||||
+ ath79_register_mdio(0, 0x0);
|
||||
+
|
||||
+ ath79_init_mac(ath79_eth0_data.mac_addr, mac, 1);
|
||||
+ ath79_init_mac(ath79_eth1_data.mac_addr, mac, -1);
|
||||
+
|
||||
+ ath79_switch_data.phy4_mii_en = 1;
|
||||
+
|
||||
+ ath79_register_eth(0);
|
||||
+ ath79_register_eth(1);
|
||||
+
|
||||
+ ath79_register_wmac(ee, mac);
|
||||
+
|
||||
+}
|
||||
+
|
||||
+MIPS_MACHINE(ATH79_MACH_TL_WR941ND_V6, "TL-WR941ND-v6", "TP-LINK TL-WR941N/ND v6",
|
||||
+ tl_wr941nd_v6_setup);
|
||||
diff --git a/target/linux/ar71xx/image/Makefile b/target/linux/ar71xx/image/Makefile
|
||||
index 3a17420..cc25be7 100644
|
||||
--- a/target/linux/ar71xx/image/Makefile
|
||||
+++ b/target/linux/ar71xx/image/Makefile
|
||||
@@ -600,7 +600,7 @@ endef
|
||||
|
||||
define Device/tl-wr941nd-v6
|
||||
$(Device/tplink-4mlzma)
|
||||
- BOARDNAME := TL-WDR3500
|
||||
+ BOARDNAME := TL-WR941ND-v6
|
||||
DEVICE_PROFILE := TLWR941
|
||||
TPLINK_HWID := 0x09410006
|
||||
endef
|
||||
diff --git a/target/linux/ar71xx/patches-3.18/610-MIPS-ath79-openwrt-machines.patch b/target/linux/ar71xx/patches-3.18/610-MIPS-ath79-openwrt-machines.patch
|
||||
index 2fa041b..185cb9c 100644
|
||||
--- a/target/linux/ar71xx/patches-3.18/610-MIPS-ath79-openwrt-machines.patch
|
||||
+++ b/target/linux/ar71xx/patches-3.18/610-MIPS-ath79-openwrt-machines.patch
|
||||
@@ -1,6 +1,6 @@
|
||||
--- a/arch/mips/ath79/machtypes.h
|
||||
+++ b/arch/mips/ath79/machtypes.h
|
||||
-@@ -16,22 +16,197 @@
|
||||
+@@ -16,22 +16,198 @@
|
||||
|
||||
enum ath79_mach_type {
|
||||
ATH79_MACH_GENERIC = 0,
|
||||
@@ -148,6 +148,7 @@
|
||||
+ ATH79_MACH_TL_WR842N_V2, /* TP-LINK TL-WR842N/ND v2 */
|
||||
+ ATH79_MACH_TL_WR941ND, /* TP-LINK TL-WR941ND */
|
||||
+ ATH79_MACH_TL_WR941ND_V5, /* TP-LINK TL-WR941ND v5 */
|
||||
++ ATH79_MACH_TL_WR941ND_V6, /* TP-LINK TL-WR941ND v6 */
|
||||
+ ATH79_MACH_TUBE2H, /* Alfa Network Tube2H */
|
||||
+ ATH79_MACH_UBNT_AIRGW, /* Ubiquiti AirGateway */
|
||||
ATH79_MACH_UBNT_AIRROUTER, /* Ubiquiti AirRouter */
|
||||
@@ -271,7 +272,7 @@
|
||||
config ATH79_MACH_AP121
|
||||
bool "Atheros AP121 reference board"
|
||||
select SOC_AR933X
|
||||
-@@ -11,62 +75,1041 @@ config ATH79_MACH_AP121
|
||||
+@@ -11,62 +75,1050 @@ config ATH79_MACH_AP121
|
||||
select ATH79_DEV_M25P80
|
||||
select ATH79_DEV_USB
|
||||
select ATH79_DEV_WMAC
|
||||
@@ -1246,6 +1247,15 @@
|
||||
+ select ATH79_DEV_M25P80
|
||||
+ select ATH79_DEV_WMAC
|
||||
+
|
||||
++config ATH79_MACH_TL_WR941ND_V6
|
||||
++ bool "TP-LINK TL-WR941ND v6 support"
|
||||
++ select SOC_QCA956X
|
||||
++ 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_WR1041N_V2
|
||||
+ bool "TP-LINK TL-WR1041N v2 support"
|
||||
+ select SOC_AR934X
|
||||
@@ -1474,7 +1484,7 @@
|
||||
endif
|
||||
--- a/arch/mips/ath79/Makefile
|
||||
+++ b/arch/mips/ath79/Makefile
|
||||
-@@ -38,9 +38,126 @@ obj-$(CONFIG_ATH79_ROUTERBOOT) += route
|
||||
+@@ -38,9 +38,127 @@ obj-$(CONFIG_ATH79_ROUTERBOOT) += route
|
||||
#
|
||||
# Machines
|
||||
#
|
||||
@@ -1566,6 +1576,7 @@
|
||||
+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_WR941ND_V6) += mach-tl-wr941nd-v6.o
|
||||
+obj-$(CONFIG_ATH79_MACH_TL_WR1041N_V2) += mach-tl-wr1041n-v2.o
|
||||
+obj-$(CONFIG_ATH79_MACH_TL_WR1043ND) += mach-tl-wr1043nd.o
|
||||
+obj-$(CONFIG_ATH79_MACH_TL_WR1043ND_V2) += mach-tl-wr1043nd-v2.o
|
@ -1,25 +0,0 @@
|
||||
From: Andreas Ziegler <github@andreas-ziegler.de>
|
||||
Date: Thu, 5 Nov 2015 15:48:09 +0100
|
||||
Subject: ar71xx: add support for TP-Link TL-WR1043ND v3
|
||||
|
||||
diff --git a/target/linux/ar71xx/image/Makefile b/target/linux/ar71xx/image/Makefile
|
||||
index cc25be7..4b29d9c 100644
|
||||
--- a/target/linux/ar71xx/image/Makefile
|
||||
+++ b/target/linux/ar71xx/image/Makefile
|
||||
@@ -2023,6 +2023,7 @@ $(eval $(call SingleProfile,TPLINK,64kraw,TLWR941NV4,tl-wr941nd-v4,TL-WR741ND,tt
|
||||
$(eval $(call SingleProfile,TPLINK,64kraw,TLWR1043V1,tl-wr1043nd-v1,TL-WR1043ND,ttyS0,115200,0x10430001,1,8M))
|
||||
|
||||
$(eval $(call SingleProfile,TPLINK-LZMA,64kraw,TLWR1043V2,tl-wr1043nd-v2,TL-WR1043ND-v2,ttyS0,115200,0x10430002,1,8M))
|
||||
+$(eval $(call SingleProfile,TPLINK-LZMA,64kraw,TLWR1043V3,tl-wr1043nd-v3,TL-WR1043ND-v2,ttyS0,115200,0x10430003,1,8M))
|
||||
$(eval $(call SingleProfile,TPLINK-LZMA,64kraw,TLWR2543,tl-wr2543-v1,TL-WR2543N,ttyS0,115200,0x25430001,1,8Mlzma,-v 3.13.99))
|
||||
|
||||
$(eval $(call SingleProfile,TPLINK-SAFELOADER,64kraw,CPE510,cpe210-220-510-520,CPE510,ttyS0,115200,$$(cpe510_mtdlayout),CPE510))
|
||||
@@ -2087,7 +2088,7 @@ $(eval $(call MultiProfile,TLWR743,TLWR743NV1))
|
||||
$(eval $(call MultiProfile,TLWR841,TLWR841NV15 TLWR841NV3 TLWR841NV5 TLWR841NV7))
|
||||
$(eval $(call MultiProfile,TLWR842,TLWR842V1))
|
||||
$(eval $(call MultiProfile,TLWR941,TLWR941NV2 TLWR941NV3 TLWR941NV4))
|
||||
-$(eval $(call MultiProfile,TLWR1043,TLWR1043V1 TLWR1043V2))
|
||||
+$(eval $(call MultiProfile,TLWR1043,TLWR1043V1 TLWR1043V2 TLWR1043V3))
|
||||
$(eval $(call MultiProfile,TLWDR4300,TLWDR3500V1 TLWDR3600V1 TLWDR4300V1 TLWDR4300V1IL TLWDR4310V1 MW4530RV1))
|
||||
$(eval $(call MultiProfile,TUBE2H,TUBE2H8M TUBE2H16M))
|
||||
$(eval $(call MultiProfile,UBNT,UBNTAIRROUTER UBNTRS UBNTRSPRO UBNTLSSR71 UBNTBULLETM UBNTROCKETM UBNTROCKETMXW UBNTNANOM UBNTNANOMXW UBNTLOCOXW UBNTUNIFI UBNTUNIFIOUTDOOR UBNTUNIFIOUTDOORPLUS UAPPRO UBNTAIRGW))
|
@ -1,197 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Wed, 18 Nov 2015 02:01:55 +0100
|
||||
Subject: ar71xx: backport ath10k calibration data load changes
|
||||
|
||||
The mac80211 update makes is necessary to backport this change as well for
|
||||
ath10k to load.
|
||||
|
||||
diff --git a/target/linux/ar71xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata b/target/linux/ar71xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata
|
||||
index dd3f546..7111630 100644
|
||||
--- a/target/linux/ar71xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata
|
||||
+++ b/target/linux/ar71xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata
|
||||
@@ -8,50 +8,83 @@ ath10kcal_die() {
|
||||
ath10kcal_from_file() {
|
||||
local source=$1
|
||||
local offset=$2
|
||||
- local target=$3
|
||||
+ local count=$3
|
||||
|
||||
- dd if=$source of=$target bs=1 skip=$offset count=2116 2>/dev/null || \
|
||||
+ dd if=$source of=/lib/firmware/$FIRMWARE bs=1 skip=$offset count=$count 2>/dev/null || \
|
||||
ath10kcal_die "failed to extract calibration data from $source"
|
||||
}
|
||||
|
||||
+ath10kcal_extract() {
|
||||
+ local part=$1
|
||||
+ local offset=$2
|
||||
+ local count=$3
|
||||
+ local mtd
|
||||
+
|
||||
+ mtd=$(find_mtd_chardev $part)
|
||||
+ [ -n "$mtd" ] || \
|
||||
+ ath10kcal_die "no mtd device found for partition $part"
|
||||
+
|
||||
+ dd if=$mtd of=/lib/firmware/$FIRMWARE bs=1 skip=$offset count=$count 2>/dev/null || \
|
||||
+ ath10kcal_die "failed to extract calibration data from $mtd"
|
||||
+}
|
||||
+
|
||||
+ath10kcal_patch_mac() {
|
||||
+ local mac=$1
|
||||
+
|
||||
+ [ -z "$mac" ] && return
|
||||
+
|
||||
+ macaddr_2bin $mac | dd of=/lib/firmware/$FIRMWARE conv=notrunc bs=1 seek=6 count=6
|
||||
+}
|
||||
+
|
||||
[ -e /lib/firmware/$FIRMWARE ] && exit 0
|
||||
|
||||
. /lib/ar71xx.sh
|
||||
. /lib/functions.sh
|
||||
. /lib/functions/system.sh
|
||||
|
||||
-ath10kcal_mac=""
|
||||
-ath10kcal_tmp="/tmp/ath10k-caldata.bin"
|
||||
-
|
||||
board=$(ar71xx_board_name)
|
||||
|
||||
case "$FIRMWARE" in
|
||||
-"ath10k/cal-pci-0000:01:00.0.bin")
|
||||
- case $board in
|
||||
- rb-911g-5hpacd)
|
||||
- ath10kcal_from_file "/sys/firmware/routerboot/ext_wlan_data" 20480 $ath10kcal_tmp
|
||||
- ;;
|
||||
- esac
|
||||
- ;;
|
||||
-
|
||||
"ath10k/cal-pci-0000:00:00.0.bin")
|
||||
case $board in
|
||||
dlan-pro-1200-ac)
|
||||
- ath10kcal_from_file $(find_mtd_part "art") 20480 $ath10kcal_tmp
|
||||
+ ath10kcal_extract "art" 20480 2116
|
||||
+ ;;
|
||||
+ mc-mac1200r)
|
||||
+ ath10kcal_extract "art" 20480 2116
|
||||
+ ath10kcal_patch_mac $(macaddr_add $(cat /sys/class/net/eth1/address) -1)
|
||||
+ ;;
|
||||
+ r6100)
|
||||
+ ath10kcal_extract "caldata" 20480 2116
|
||||
+ ath10kcal_patch_mac $(macaddr_add $(cat /sys/class/net/eth1/address) +2)
|
||||
+ ;;
|
||||
+ qihoo-c301)
|
||||
+ ath10kcal_extract "radiocfg" 20480 2116
|
||||
+ ath10kcal_patch_mac $(mtd_get_mac_ascii devdata wlan5mac)
|
||||
;;
|
||||
esr1750 | \
|
||||
epg5000)
|
||||
- ath10kcal_from_file $(find_mtd_part "caldata") 20480 $ath10kcal_tmp
|
||||
+ ath10kcal_extract "caldata" 20480 2116
|
||||
+ ath10kcal_patch_mac $(macaddr_add $(cat /sys/class/net/eth0/address) +1)
|
||||
+ ;;
|
||||
+ esac
|
||||
+ ;;
|
||||
+"ath10k/cal-pci-0000:01:00.0.bin")
|
||||
+ case $board in
|
||||
+ archer-c5 | \
|
||||
+ archer-c7)
|
||||
+ ath10kcal_extract "art" 20480 2116
|
||||
+ ath10kcal_patch_mac $(macaddr_add $(cat /sys/class/net/eth1/address) -2)
|
||||
+ ;;
|
||||
+ nbg6716)
|
||||
+ ath10kcal_extract "RFdata" 20480 2116
|
||||
+ ;;
|
||||
+ rb-911g-5hpacd)
|
||||
+ ath10kcal_from_file "/sys/firmware/routerboot/ext_wlan_data" 20480 2116
|
||||
;;
|
||||
esac
|
||||
;;
|
||||
-
|
||||
*)
|
||||
exit 1
|
||||
;;
|
||||
esac
|
||||
-
|
||||
-[ -f $ath10kcal_tmp ] && {
|
||||
- cp $ath10kcal_tmp /lib/firmware/$FIRMWARE
|
||||
- rm -f $ath10kcal_tmp
|
||||
-}
|
||||
diff --git a/target/linux/ar71xx/base-files/lib/preinit/81_load_ath10k_board_bin b/target/linux/ar71xx/base-files/lib/preinit/81_load_ath10k_board_bin
|
||||
deleted file mode 100644
|
||||
index 9a32dfc..0000000
|
||||
--- a/target/linux/ar71xx/base-files/lib/preinit/81_load_ath10k_board_bin
|
||||
+++ /dev/null
|
||||
@@ -1,75 +0,0 @@
|
||||
-#!/bin/sh
|
||||
-
|
||||
-. /lib/functions/system.sh
|
||||
-. /lib/ar71xx.sh
|
||||
-
|
||||
-do_load_ath10k_board_bin() {
|
||||
- # load board.bin
|
||||
- case $(ar71xx_board_name) in
|
||||
- nbg6716)
|
||||
- dd if=/dev/mtdblock2 \
|
||||
- bs=1 skip=20480 count=2116 \
|
||||
- of=/tmp/ath10k-board.bin
|
||||
- ;;
|
||||
- archer-c5 | \
|
||||
- archer-c7)
|
||||
- local mac
|
||||
- mac=$(macaddr_add $(cat /sys/class/net/eth1/address) -2)
|
||||
-
|
||||
- dd if=/dev/mtdblock4 \
|
||||
- bs=1 skip=20480 count=6 \
|
||||
- of=/tmp/ath10k-board.bin
|
||||
- macaddr_2bin $mac >> /tmp/ath10k-board.bin
|
||||
- dd if=/dev/mtdblock4 \
|
||||
- bs=1 skip=20492 count=2104 >> /tmp/ath10k-board.bin
|
||||
- ;;
|
||||
- mc-mac1200r)
|
||||
- local mac
|
||||
- mac=$(macaddr_add $(cat /sys/class/net/eth1/address) -1)
|
||||
-
|
||||
- dd if=/dev/mtdblock4 \
|
||||
- bs=1 skip=20480 count=6 \
|
||||
- of=/tmp/ath10k-board.bin
|
||||
- macaddr_2bin $mac >> /tmp/ath10k-board.bin
|
||||
- dd if=/dev/mtdblock4 \
|
||||
- bs=1 skip=20492 count=2104 >> /tmp/ath10k-board.bin
|
||||
- ;;
|
||||
- r6100)
|
||||
- local mac
|
||||
- mac=$(macaddr_add $(cat /sys/class/net/eth1/address) +2)
|
||||
-
|
||||
- dd if=/dev/mtdblock2 \
|
||||
- bs=1 skip=20480 count=6 \
|
||||
- of=/tmp/ath10k-board.bin
|
||||
- macaddr_2bin $mac >> /tmp/ath10k-board.bin
|
||||
- dd if=/dev/mtdblock2 \
|
||||
- bs=1 skip=20492 count=2104 >> /tmp/ath10k-board.bin
|
||||
- ;;
|
||||
- qihoo-c301)
|
||||
- local mac
|
||||
-
|
||||
- mac=$(mtd_get_mac_ascii devdata wlan5mac)
|
||||
-
|
||||
- if [ -z "$mac" ]; then
|
||||
- mac=$(macaddr_add $(cat /sys/class/net/eth0/address) -2)
|
||||
- fi
|
||||
-
|
||||
- dd if=/dev/mtdblock10 \
|
||||
- bs=1 skip=20480 count=6 \
|
||||
- of=/tmp/ath10k-board.bin
|
||||
- macaddr_2bin $mac >> /tmp/ath10k-board.bin
|
||||
- dd if=/dev/mtdblock10 \
|
||||
- bs=1 skip=20492 count=2104 >> /tmp/ath10k-board.bin
|
||||
-
|
||||
- ;;
|
||||
- esac
|
||||
- [ -f /tmp/ath10k-board.bin ] || {
|
||||
- return
|
||||
- }
|
||||
- cmp -s /tmp/ath10k-board.bin /lib/firmware/ath10k/QCA988X/hw2.0/board.bin || {
|
||||
- cp /tmp/ath10k-board.bin /lib/firmware/ath10k/QCA988X/hw2.0/board.bin
|
||||
- rm /tmp/ath10k-board.bin
|
||||
- }
|
||||
-}
|
||||
-
|
||||
-boot_hook_add preinit_main do_load_ath10k_board_bin
|
@ -1,20 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 19 Nov 2015 23:29:17 +0100
|
||||
Subject: ar71xx: fix AR71XX_MODEL on TP-Link TL-WR703N
|
||||
|
||||
The hwid check was wrong, causing the AR71XX_MODEL value to end with a
|
||||
space (as $hwver was unset).
|
||||
|
||||
diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
index 9c7c139..388cf38 100755
|
||||
--- a/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
+++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
@@ -122,7 +122,7 @@ tplink_board_detect() {
|
||||
"3C0002"*)
|
||||
model="MINIBOX_V1"
|
||||
;;
|
||||
- "070300"*)
|
||||
+ "070301"*)
|
||||
model="TP-Link TL-WR703N"
|
||||
;;
|
||||
"071000"*)
|
@ -1,46 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Fri, 20 Nov 2015 15:09:03 +0100
|
||||
Subject: ar71xx: fix wndr3700_board_detect for some NETGEAR WNDR3700v2 (again)
|
||||
|
||||
When fixing the model string for WNDR3700v2 which contain a model string
|
||||
followed by 0xff in r46455, the match for other versions of the WNDR3700v2
|
||||
which just contain lots of 0xff broke (as the 0xff $model is checked for
|
||||
is stripped off).
|
||||
|
||||
Fix by stripping off non-printable characters only for the actual output
|
||||
string, but not for the internal matching.
|
||||
|
||||
diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
index 388cf38..daebaa4 100755
|
||||
--- a/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
+++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
@@ -37,8 +37,9 @@ wndr3700_board_detect() {
|
||||
machine="NETGEAR WNDR3700"
|
||||
;;
|
||||
"33373031")
|
||||
- # Use awk to remove everything after the first zero byte
|
||||
- model="$(ar71xx_get_mtd_offset_size_format art 41 32 %c | LC_CTYPE=C awk -v 'FS=[^[:print:]]' '{print $1; exit}')"
|
||||
+ model="$(ar71xx_get_mtd_offset_size_format art 41 32 %c)"
|
||||
+ # Use awk to remove everything unprintable
|
||||
+ model_stripped="$(echo -n "$model" | LC_CTYPE=C awk -v 'FS=[^[:print:]]' '{print $1; exit}')"
|
||||
case $model in
|
||||
$'\xff'*)
|
||||
if [ "${model:24:1}" = 'N' ]; then
|
||||
@@ -48,14 +49,14 @@ wndr3700_board_detect() {
|
||||
fi
|
||||
;;
|
||||
'29763654+16+64'*)
|
||||
- machine="NETGEAR ${model:14}"
|
||||
+ machine="NETGEAR ${model_stripped:14}"
|
||||
;;
|
||||
'29763654+16+128'*)
|
||||
- machine="NETGEAR ${model:15}"
|
||||
+ machine="NETGEAR ${model_stripped:15}"
|
||||
;;
|
||||
*)
|
||||
# Unknown ID
|
||||
- machine="NETGEAR $model"
|
||||
+ machine="NETGEAR ${model_stripped}"
|
||||
esac
|
||||
esac
|
||||
|
@ -1,17 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Sat, 21 Nov 2015 18:35:49 +0100
|
||||
Subject: CC: base-files: add missing public key
|
||||
|
||||
Add the secondary package signature key to the 15.05 sources so that people
|
||||
building the release have the same keys as people using precompiled images.
|
||||
|
||||
Signed-off-by: Jo-Philipp Wich <jow@openwrt.org>
|
||||
|
||||
diff --git a/package/base-files/files/etc/opkg/keys/de98a2dd1d0f8a07 b/package/base-files/files/etc/opkg/keys/de98a2dd1d0f8a07
|
||||
new file mode 100644
|
||||
index 0000000..5e3088c
|
||||
--- /dev/null
|
||||
+++ b/package/base-files/files/etc/opkg/keys/de98a2dd1d0f8a07
|
||||
@@ -0,0 +1,2 @@
|
||||
+untrusted comment: openwrt.org 15.05 release key
|
||||
+RWTemKLdHQ+KBxOILy8gyk+5PaDVdfyJ32TFnY/jnQOrBAd1wobbLNYz
|
@ -1,17 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Sat, 28 Nov 2015 22:40:40 +0100
|
||||
Subject: acx-mac80211: mark as BROKEN to avoid compile failure on mipsel targets
|
||||
|
||||
diff --git a/package/kernel/acx-mac80211/Makefile b/package/kernel/acx-mac80211/Makefile
|
||||
index 1820e7a..fb17a46 100644
|
||||
--- a/package/kernel/acx-mac80211/Makefile
|
||||
+++ b/package/kernel/acx-mac80211/Makefile
|
||||
@@ -30,7 +30,7 @@ include $(INCLUDE_DIR)/package.mk
|
||||
define KernelPackage/acx-mac80211
|
||||
SUBMENU:=Wireless Drivers
|
||||
TITLE:=ACX1xx mac80211 driver
|
||||
- DEPENDS:=@(PCI_SUPPORT||TARGET_ar7) @!TARGET_cobalt @mipsel +kmod-mac80211
|
||||
+ DEPENDS:=@(PCI_SUPPORT||TARGET_ar7) @!TARGET_cobalt @mipsel +kmod-mac80211 @BROKEN
|
||||
FILES:=$(PKG_BUILD_DIR)/acx-mac80211.ko
|
||||
AUTOLOAD:=$(call AutoLoad,50,mac80211 acx-mac80211)
|
||||
MAINTAINER:=Florian Fainelli <florian@openwrt.org>
|
@ -1,24 +0,0 @@
|
||||
From: Ranlvor <ranlvor@starletp9.de>
|
||||
Date: Sun, 6 Dec 2015 16:12:55 +0100
|
||||
Subject: OpenSSL: Added source/old to PKG_SOURCE_URL
|
||||
|
||||
OpenSSL moves old versions of the library from http://www.openssl.org/source/
|
||||
to http://www.openssl.org/source/old/1.0.2/ breaking the old links. That
|
||||
behavior breaks the OpenWRT-build every time OpenSSL releases a new version.
|
||||
|
||||
This patch adds http://www.openssl.org/source/old/1.0.2/ to the PKG_SOURCE_URL
|
||||
of OpenSSL to avoid breaking the build whenever OpenSSL releases a new
|
||||
version.
|
||||
|
||||
diff --git a/package/libs/openssl/Makefile b/package/libs/openssl/Makefile
|
||||
index 7f0da8b..039e1ab 100644
|
||||
--- a/package/libs/openssl/Makefile
|
||||
+++ b/package/libs/openssl/Makefile
|
||||
@@ -16,6 +16,7 @@ PKG_BUILD_PARALLEL:=1
|
||||
|
||||
PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
|
||||
PKG_SOURCE_URL:=http://www.openssl.org/source/ \
|
||||
+ http://www.openssl.org/source/old/1.0.2/ \
|
||||
ftp://ftp.funet.fi/pub/crypt/mirrors/ftp.openssl.org/source \
|
||||
ftp://ftp.sunet.se/pub/security/tools/net/openssl/source/
|
||||
PKG_MD5SUM:=38dd619b2e77cbac69b99f52a053d25a
|
@ -1,23 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Tue, 8 Dec 2015 19:51:05 +0100
|
||||
Subject: Revert "bzip2: extend/fix the Host/Install rule to install libbz2.so files"
|
||||
|
||||
This reverts commit f5ebfb02fc5f539e89393b8186f7ecd768402f12.
|
||||
|
||||
diff --git a/package/utils/bzip2/Makefile b/package/utils/bzip2/Makefile
|
||||
index ba47cfb..e1c7b97 100644
|
||||
--- a/package/utils/bzip2/Makefile
|
||||
+++ b/package/utils/bzip2/Makefile
|
||||
@@ -97,10 +97,9 @@ HOST_CONFIGURE_ARGS+= \
|
||||
--prefix=$(STAGING_DIR_HOST)
|
||||
|
||||
define Host/Install
|
||||
- $(INSTALL_DIR) $(STAGING_DIR_HOST)/bin/ $(STAGING_DIR_HOST)/usr/lib
|
||||
+ $(INSTALL_DIR) $(STAGING_DIR_HOST)/bin/
|
||||
$(MAKE) -C $(HOST_BUILD_DIR) PREFIX=$(STAGING_DIR_HOST)/usr/ install
|
||||
- $(CP) $(HOST_BUILD_DIR)/libbz2.so* $(STAGING_DIR_HOST)/usr/lib/
|
||||
- $(CP) $(HOST_BUILD_DIR)/libbz2.so.1.0 $(STAGING_DIR_HOST)/usr/lib/libbz2.so
|
||||
+# $(INSTALL_BIN) $(HOST_BUILD_DIR)/Parser/pgen $(STAGING_DIR_HOST)/bin/pgen2
|
||||
endef
|
||||
|
||||
$(eval $(call HostBuild))
|
@ -1,29 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Sat, 2 Jan 2016 23:36:25 +0100
|
||||
Subject: ar71xx: another fix to wndr3700_board_detect
|
||||
|
||||
My last bugfix (r47538) introduced a new bug in wndr3700_board_detect
|
||||
(again...).
|
||||
|
||||
Assigning the result of ar71xx_get_mtd_offset_size_format to the model
|
||||
variable before stripping of garbage using awk will cause all NUL bytes to
|
||||
be removed before awk is applied, leading to model strings like
|
||||
"NETGEAR WNDRMACv2NETGEAR", where a NUL byte after the v2 is supposed to
|
||||
terminate the string.
|
||||
|
||||
Fix by calling ar71xx_get_mtd_offset_size_format twice, once piping to awk
|
||||
directly.
|
||||
|
||||
diff --git a/target/linux/ar71xx/base-files/lib/ar71xx.sh b/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
index daebaa4..d0abf42 100755
|
||||
--- a/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
+++ b/target/linux/ar71xx/base-files/lib/ar71xx.sh
|
||||
@@ -39,7 +39,7 @@ wndr3700_board_detect() {
|
||||
"33373031")
|
||||
model="$(ar71xx_get_mtd_offset_size_format art 41 32 %c)"
|
||||
# Use awk to remove everything unprintable
|
||||
- model_stripped="$(echo -n "$model" | LC_CTYPE=C awk -v 'FS=[^[:print:]]' '{print $1; exit}')"
|
||||
+ model_stripped="$(ar71xx_get_mtd_offset_size_format art 41 32 %c | LC_CTYPE=C awk -v 'FS=[^[:print:]]' '{print $1; exit}')"
|
||||
case $model in
|
||||
$'\xff'*)
|
||||
if [ "${model:24:1}" = 'N' ]; then
|
@ -1,87 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Sat, 6 Feb 2016 07:35:33 +0100
|
||||
Subject: kernel: fix keyring reference leak (CVE-2016-0728)
|
||||
|
||||
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
|
||||
|
||||
diff --git a/target/linux/generic/patches-3.18/010-KEYS-Fix-keyring-ref-leak-in-join_session_keyring.patch b/target/linux/generic/patches-3.18/010-KEYS-Fix-keyring-ref-leak-in-join_session_keyring.patch
|
||||
new file mode 100644
|
||||
index 0000000..9c6a969
|
||||
--- /dev/null
|
||||
+++ b/target/linux/generic/patches-3.18/010-KEYS-Fix-keyring-ref-leak-in-join_session_keyring.patch
|
||||
@@ -0,0 +1,75 @@
|
||||
+From 7ca88764d45c209791e8813131c1457c2e9e51e7 Mon Sep 17 00:00:00 2001
|
||||
+From: Yevgeny Pats <yevgeny@perception-point.io>
|
||||
+Date: Mon, 11 Jan 2016 12:05:28 +0000
|
||||
+Subject: KEYS: Fix keyring ref leak in join_session_keyring()
|
||||
+
|
||||
+If a thread is asked to join as a session keyring the keyring that's already
|
||||
+set as its session, we leak a keyring reference.
|
||||
+
|
||||
+This can be tested with the following program:
|
||||
+
|
||||
+ #include <stddef.h>
|
||||
+ #include <stdio.h>
|
||||
+ #include <sys/types.h>
|
||||
+ #include <keyutils.h>
|
||||
+
|
||||
+ int main(int argc, const char *argv[])
|
||||
+ {
|
||||
+ int i = 0;
|
||||
+ key_serial_t serial;
|
||||
+
|
||||
+ serial = keyctl(KEYCTL_JOIN_SESSION_KEYRING,
|
||||
+ "leaked-keyring");
|
||||
+ if (serial < 0) {
|
||||
+ perror("keyctl");
|
||||
+ return -1;
|
||||
+ }
|
||||
+
|
||||
+ if (keyctl(KEYCTL_SETPERM, serial,
|
||||
+ KEY_POS_ALL | KEY_USR_ALL) < 0) {
|
||||
+ perror("keyctl");
|
||||
+ return -1;
|
||||
+ }
|
||||
+
|
||||
+ for (i = 0; i < 100; i++) {
|
||||
+ serial = keyctl(KEYCTL_JOIN_SESSION_KEYRING,
|
||||
+ "leaked-keyring");
|
||||
+ if (serial < 0) {
|
||||
+ perror("keyctl");
|
||||
+ return -1;
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ return 0;
|
||||
+ }
|
||||
+
|
||||
+If, after the program has run, there something like the following line in
|
||||
+/proc/keys:
|
||||
+
|
||||
+3f3d898f I--Q--- 100 perm 3f3f0000 0 0 keyring leaked-keyring: empty
|
||||
+
|
||||
+with a usage count of 100 * the number of times the program has been run,
|
||||
+then the kernel is malfunctioning. If leaked-keyring has zero usages or
|
||||
+has been garbage collected, then the problem is fixed.
|
||||
+
|
||||
+Reported-by: Yevgeny Pats <yevgeny@perception-point.io>
|
||||
+Signed-off-by: David Howells <dhowells@redhat.com>
|
||||
+---
|
||||
+ security/keys/process_keys.c | 1 +
|
||||
+ 1 file changed, 1 insertion(+)
|
||||
+
|
||||
+diff --git a/security/keys/process_keys.c b/security/keys/process_keys.c
|
||||
+index a3f85d2..e6d50172 100644
|
||||
+--- a/security/keys/process_keys.c
|
||||
++++ b/security/keys/process_keys.c
|
||||
+@@ -794,6 +794,7 @@ long join_session_keyring(const char *name)
|
||||
+ ret = PTR_ERR(keyring);
|
||||
+ goto error2;
|
||||
+ } else if (keyring == new->session_keyring) {
|
||||
++ key_put(keyring);
|
||||
+ ret = 0;
|
||||
+ goto error2;
|
||||
+ }
|
||||
+--
|
||||
+2.7.0.rc3
|
||||
+
|
@ -1,19 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Sun, 28 Feb 2016 02:29:56 +0100
|
||||
Subject: brcm2708-gpu-fw: move pkg build dir to kernel build dir to fix rebuild bugs after cleaning the kernel tree
|
||||
|
||||
Backport of r48732
|
||||
|
||||
diff --git a/package/kernel/brcm2708-gpu-fw/Makefile b/package/kernel/brcm2708-gpu-fw/Makefile
|
||||
index eee85e0..286984b 100644
|
||||
--- a/package/kernel/brcm2708-gpu-fw/Makefile
|
||||
+++ b/package/kernel/brcm2708-gpu-fw/Makefile
|
||||
@@ -16,7 +16,7 @@ PKG_SOURCE:=$(PKG_REV).tar.gz
|
||||
PKG_SOURCE_URL:=https://github.com/Hexxeh/rpi-firmware/archive/
|
||||
PKG_MD5SUM:=f5683c1dcb255714942f7c9fd61b3a0a
|
||||
|
||||
-PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME)/rpi-firmware-$(PKG_REV)
|
||||
+PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/$(PKG_NAME)/rpi-firmware-$(PKG_REV)
|
||||
|
||||
include $(INCLUDE_DIR)/package.mk
|
||||
|
@ -1,21 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Sun, 28 Feb 2016 03:42:29 +0100
|
||||
Subject: kernel/gpio_keys: load module on pre-init
|
||||
|
||||
fix rescue mode on wdr4900
|
||||
|
||||
Backport of r48793
|
||||
|
||||
diff --git a/package/kernel/linux/modules/input.mk b/package/kernel/linux/modules/input.mk
|
||||
index 86ff33c..eed9aa2 100644
|
||||
--- a/package/kernel/linux/modules/input.mk
|
||||
+++ b/package/kernel/linux/modules/input.mk
|
||||
@@ -75,7 +75,7 @@ define KernelPackage/input-gpio-keys
|
||||
CONFIG_KEYBOARD_GPIO \
|
||||
CONFIG_INPUT_KEYBOARD=y
|
||||
FILES:=$(LINUX_DIR)/drivers/input/keyboard/gpio_keys.ko
|
||||
- AUTOLOAD:=$(call AutoProbe,gpio_keys)
|
||||
+ AUTOLOAD:=$(call AutoProbe,gpio_keys,1)
|
||||
endef
|
||||
|
||||
define KernelPackage/input-gpio-keys/description
|
@ -1,36 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Sun, 28 Feb 2016 04:49:51 +0100
|
||||
Subject: ar71xx/lzma-loader: fix O32 ABI conformance
|
||||
|
||||
According to the calling convention of the o32 ABI the caller
|
||||
function must reserve stack space for $a0-$a3 registers in case
|
||||
the callee needs to save its arguments.
|
||||
|
||||
The assembly code of the loader does not reserve stack space for
|
||||
these registers thus when the 'loader_main' function needs to save
|
||||
its arguments, those will be stored in the 'workspace' area instead
|
||||
of the stack.
|
||||
|
||||
Because the workspace area is also used by other part of the code, the
|
||||
saved register values gets overwritten and this often leads to failed
|
||||
kernel boots.
|
||||
|
||||
Fix the code to reserve stack space for the registers to avoid this
|
||||
error.
|
||||
|
||||
Backport of r48279
|
||||
|
||||
diff --git a/target/linux/ar71xx/image/lzma-loader/src/head.S b/target/linux/ar71xx/image/lzma-loader/src/head.S
|
||||
index 543996a..47a7c9b 100644
|
||||
--- a/target/linux/ar71xx/image/lzma-loader/src/head.S
|
||||
+++ b/target/linux/ar71xx/image/lzma-loader/src/head.S
|
||||
@@ -109,6 +109,9 @@ __bss_check:
|
||||
/* Setup new "C" stack */
|
||||
la sp, _stack
|
||||
|
||||
+ /* reserve stack space for a0-a3 registers */
|
||||
+ subu sp, 16
|
||||
+
|
||||
/* jump to the decompressor routine */
|
||||
la t0, loader_main
|
||||
jr t0
|
@ -1,64 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 25 Feb 2016 21:39:03 +0100
|
||||
Subject: firmware-utils: mkfwimage: add -Wall, fix obvious bugs causing compile warnings
|
||||
|
||||
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
|
||||
diff --git a/tools/firmware-utils/Makefile b/tools/firmware-utils/Makefile
|
||||
index bd69cb4..6d88845 100644
|
||||
--- a/tools/firmware-utils/Makefile
|
||||
+++ b/tools/firmware-utils/Makefile
|
||||
@@ -32,7 +32,7 @@ define Host/Compile
|
||||
$(call cc,mkzynfw)
|
||||
$(call cc,lzma2eva,-lz)
|
||||
$(call cc,mkcasfw)
|
||||
- $(call cc,mkfwimage,-lz)
|
||||
+ $(call cc,mkfwimage,-lz -Wall)
|
||||
$(call cc,mkfwimage2,-lz)
|
||||
$(call cc,imagetag imagetag_cmdline cyg_crc32)
|
||||
$(call cc,add_header)
|
||||
diff --git a/tools/firmware-utils/src/mkfwimage.c b/tools/firmware-utils/src/mkfwimage.c
|
||||
index e3a03c1..00bf439 100644
|
||||
--- a/tools/firmware-utils/src/mkfwimage.c
|
||||
+++ b/tools/firmware-utils/src/mkfwimage.c
|
||||
@@ -104,8 +104,6 @@ typedef struct part_data {
|
||||
|
||||
#define OPTIONS "B:hv:m:o:r:k:"
|
||||
|
||||
-static int debug = 0;
|
||||
-
|
||||
typedef struct image_info {
|
||||
char magic[16];
|
||||
char version[256];
|
||||
@@ -236,9 +234,9 @@ static int create_image_layout(const char* kernelfile, const char* rootfsfile, c
|
||||
fw_layout_t* p;
|
||||
|
||||
p = &fw_layout_data[0];
|
||||
- while ((strlen(p->name) != 0) && (strncmp(p->name, board_name, sizeof(board_name)) != 0))
|
||||
+ while (*p->name && (strcmp(p->name, board_name) != 0))
|
||||
p++;
|
||||
- if (p->name == NULL) {
|
||||
+ if (!*p->name) {
|
||||
printf("BUG! Unable to find default fw layout!\n");
|
||||
exit(-1);
|
||||
}
|
||||
@@ -247,7 +245,7 @@ static int create_image_layout(const char* kernelfile, const char* rootfsfile, c
|
||||
strcpy(kernel->partition_name, "kernel");
|
||||
kernel->partition_index = 1;
|
||||
kernel->partition_baseaddr = p->kern_start;
|
||||
- if ( (kernel->partition_length = filelength(kernelfile)) < 0) return (-1);
|
||||
+ if ( (kernel->partition_length = filelength(kernelfile)) == (u_int32_t)-1) return (-1);
|
||||
kernel->partition_memaddr = p->kern_entry;
|
||||
kernel->partition_entryaddr = p->kern_entry;
|
||||
strncpy(kernel->filename, kernelfile, sizeof(kernel->filename));
|
||||
@@ -263,8 +261,8 @@ static int create_image_layout(const char* kernelfile, const char* rootfsfile, c
|
||||
rootfs->partition_entryaddr = 0x00000000;
|
||||
strncpy(rootfs->filename, rootfsfile, sizeof(rootfs->filename));
|
||||
|
||||
-printf("kernel: %d 0x%08x\n", kernel->partition_length, kernel->partition_baseaddr);
|
||||
-printf("root: %d 0x%08x\n", rootfs->partition_length, rootfs->partition_baseaddr);
|
||||
+ printf("kernel: %d 0x%08x\n", kernel->partition_length, kernel->partition_baseaddr);
|
||||
+ printf("root: %d 0x%08x\n", rootfs->partition_length, rootfs->partition_baseaddr);
|
||||
im->part_count = 2;
|
||||
|
||||
return 0;
|
@ -1,39 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 25 Feb 2016 21:40:19 +0100
|
||||
Subject: ar71xx, firmware-utils: split ubdev01 flash layout from XM
|
||||
|
||||
The ubdev01 profile defines its own MTDPARTS with smaller firmware
|
||||
partition, so give it its own UBNT_BOARD in mkfwimage.
|
||||
|
||||
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
|
||||
diff --git a/target/linux/ar71xx/image/Makefile b/target/linux/ar71xx/image/Makefile
|
||||
index 4b29d9c..0806f15 100644
|
||||
--- a/target/linux/ar71xx/image/Makefile
|
||||
+++ b/target/linux/ar71xx/image/Makefile
|
||||
@@ -2031,7 +2031,7 @@ $(eval $(call SingleProfile,TPLINK-SAFELOADER,64kraw,CPE510,cpe210-220-510-520,C
|
||||
$(eval $(call SingleProfile,UAPPRO,64k,UAPPRO,ubnt-uap-pro,UAP-PRO,ttyS0,115200,BZ,BZ,ar934x))
|
||||
$(eval $(call SingleProfile,UAPPRO,64k,UBNTUNIFIOUTDOORPLUS,ubnt-unifi-outdoor-plus,UBNT-UOP,ttyS0,115200,BZ,BZ,ar7240))
|
||||
|
||||
-$(eval $(call SingleProfile,UBDEV,64kraw,UBDEV01,ubdev01,UBNT-UF,ttyS0,115200,XM,XM,ar7240))
|
||||
+$(eval $(call SingleProfile,UBDEV,64kraw,UBDEV01,ubdev01,UBNT-UF,ttyS0,115200,UBDEV01,XM,ar7240))
|
||||
|
||||
$(eval $(call SingleProfile,UBNT,64k,UBNTRS,ubnt-rs,UBNT-RS,ttyS0,115200,RS,RSx,ar7100))
|
||||
$(eval $(call SingleProfile,UBNT,64k,UBNTRSPRO,ubnt-rspro,UBNT-RSPRO,ttyS0,115200,RSPRO,RSPRO,ar7100pro))
|
||||
diff --git a/tools/firmware-utils/src/mkfwimage.c b/tools/firmware-utils/src/mkfwimage.c
|
||||
index 00bf439..5dae284 100644
|
||||
--- a/tools/firmware-utils/src/mkfwimage.c
|
||||
+++ b/tools/firmware-utils/src/mkfwimage.c
|
||||
@@ -81,6 +81,12 @@ fw_layout_t fw_layout_data[] = {
|
||||
.kern_entry = 0x80002000,
|
||||
.firmware_max_length= 0x006A0000,
|
||||
},
|
||||
+ {
|
||||
+ .name = "UBDEV01",
|
||||
+ .kern_start = 0x9f050000,
|
||||
+ .kern_entry = 0x80002000,
|
||||
+ .firmware_max_length= 0x006A0000,
|
||||
+ },
|
||||
{ .name = "",
|
||||
},
|
||||
};
|
@ -1,45 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 25 Feb 2016 21:42:14 +0100
|
||||
Subject: firmware-utils: mkfwimage: fix firmware_max_length for XM layout
|
||||
|
||||
The new u-boot version bundled with the 5.6.x firmwares from Ubiquiti gets
|
||||
confused by the smaller rootfs partition size; this can lead to various
|
||||
issues:
|
||||
|
||||
1. We've gotten reports that flashing from the 5.6.x stock firmware to
|
||||
OpenWrt will brick devices; I wasn't able to reproduce this myself
|
||||
2. Flashing from 5.5.x stock firmware to OpenWrt and back to stock (via
|
||||
TFTP recovery), following by an update to 5.6.x via web interface can
|
||||
yield a bricked device with the following properties:
|
||||
- It can't be booted without entering commands over a serial console, as
|
||||
u-boot supplies the wrong MTD layout
|
||||
- The web interface won't accept any image with the original flash
|
||||
layout, so stock firmware upgrades are impossible
|
||||
- As the TFTP recovery doesn't update u-boot, returning to the old
|
||||
u-boot from firmware 5.5.x is impossible
|
||||
|
||||
To recover from 2., creating an OpenWrt image which doesn't set u-boot as
|
||||
read-only and flashing a backup of the old u-boot from there is the only
|
||||
way known to me. (Fixing the mtdparts variable in u-boot-env from OpenWrt
|
||||
might also work; settings this from u-boot over serial didn't have
|
||||
any permanent effect.)
|
||||
|
||||
Fix all of this by setting the correct flash layout also used by the stock
|
||||
firmware. Flashing has been tested from both firmware 5.5.x and 5.6.x. The
|
||||
fixed layout also matches the mtdparts defined by OpenWrt.
|
||||
|
||||
Signed-off-by: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
|
||||
diff --git a/tools/firmware-utils/src/mkfwimage.c b/tools/firmware-utils/src/mkfwimage.c
|
||||
index 5dae284..d8d5239 100644
|
||||
--- a/tools/firmware-utils/src/mkfwimage.c
|
||||
+++ b/tools/firmware-utils/src/mkfwimage.c
|
||||
@@ -79,7 +79,7 @@ fw_layout_t fw_layout_data[] = {
|
||||
.name = "XM",
|
||||
.kern_start = 0x9f050000,
|
||||
.kern_entry = 0x80002000,
|
||||
- .firmware_max_length= 0x006A0000,
|
||||
+ .firmware_max_length= 0x00760000,
|
||||
},
|
||||
{
|
||||
.name = "UBDEV01",
|
@ -1,22 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Fri, 26 Feb 2016 04:24:06 +0100
|
||||
Subject: kernel: disable software protection bits for macronix flash chips at init
|
||||
|
||||
Backport of r47626
|
||||
|
||||
diff --git a/target/linux/generic/patches-3.18/465-m25p80-mx-disable-software-protection.patch b/target/linux/generic/patches-3.18/465-m25p80-mx-disable-software-protection.patch
|
||||
new file mode 100644
|
||||
index 0000000..d7d7eec
|
||||
--- /dev/null
|
||||
+++ b/target/linux/generic/patches-3.18/465-m25p80-mx-disable-software-protection.patch
|
||||
@@ -0,0 +1,10 @@
|
||||
+--- a/drivers/mtd/spi-nor/spi-nor.c
|
||||
++++ b/drivers/mtd/spi-nor/spi-nor.c
|
||||
+@@ -962,6 +962,7 @@ int spi_nor_scan(struct spi_nor *nor, co
|
||||
+
|
||||
+ if (JEDEC_MFR(info->jedec_id) == CFI_MFR_ATMEL ||
|
||||
+ JEDEC_MFR(info->jedec_id) == CFI_MFR_INTEL ||
|
||||
++ JEDEC_MFR(info->jedec_id) == CFI_MFR_MACRONIX ||
|
||||
+ JEDEC_MFR(info->jedec_id) == CFI_MFR_SST) {
|
||||
+ write_enable(nor);
|
||||
+ write_sr(nor, 0);
|
@ -1,24 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Wed, 2 Mar 2016 18:26:15 +0100
|
||||
Subject: x86/generic: enable pata_atiixp driver
|
||||
|
||||
This enables booting from devices that use an ATI PATA controller for
|
||||
the boot device, such as the embedded CF cards in Fujitsu-Siemens Futro
|
||||
thin-clients.
|
||||
|
||||
Signed-off-by: Felix Kaechele <heffer@fedoraproject.org>
|
||||
|
||||
Backport of r48861
|
||||
|
||||
diff --git a/target/linux/x86/generic/config-default b/target/linux/x86/generic/config-default
|
||||
index eb4b357..9e963bf 100644
|
||||
--- a/target/linux/x86/generic/config-default
|
||||
+++ b/target/linux/x86/generic/config-default
|
||||
@@ -153,6 +153,7 @@ CONFIG_NLS=y
|
||||
CONFIG_NO_HZ=y
|
||||
# CONFIG_PANASONIC_LAPTOP is not set
|
||||
CONFIG_PATA_AMD=y
|
||||
+CONFIG_PATA_ATIIXP=y
|
||||
CONFIG_PATA_LEGACY=y
|
||||
CONFIG_PATA_MPIIX=y
|
||||
CONFIG_PATA_OLDPIIX=y
|
@ -1,20 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Tue, 8 Mar 2016 04:13:13 +0100
|
||||
Subject: kernel: update to 3.18.24
|
||||
|
||||
diff --git a/include/kernel-version.mk b/include/kernel-version.mk
|
||||
index 6060776..647fbc5 100644
|
||||
--- a/include/kernel-version.mk
|
||||
+++ b/include/kernel-version.mk
|
||||
@@ -2,9 +2,9 @@
|
||||
|
||||
LINUX_RELEASE?=1
|
||||
|
||||
-LINUX_VERSION-3.18 = .23
|
||||
+LINUX_VERSION-3.18 = .24
|
||||
|
||||
-LINUX_KERNEL_MD5SUM-3.18.23 = dc6d265ab38716be3676ac294b481ad8
|
||||
+LINUX_KERNEL_MD5SUM-3.18.24 = ceb97aed20611aff4b177d52ffca3b5c
|
||||
|
||||
ifdef KERNEL_PATCHVER
|
||||
LINUX_VERSION:=$(KERNEL_PATCHVER)$(strip $(LINUX_VERSION-$(KERNEL_PATCHVER)))
|
@ -1,17 +0,0 @@
|
||||
From: Matthias Schiffer <mschiffer@universe-factory.net>
|
||||
Date: Thu, 21 May 2015 02:34:01 +0200
|
||||
Subject: luci-base: depend on libubus-lua
|
||||
|
||||
diff --git a/modules/luci-base/Makefile b/modules/luci-base/Makefile
|
||||
index 80bbda1..55c21eb 100644
|
||||
--- a/modules/luci-base/Makefile
|
||||
+++ b/modules/luci-base/Makefile
|
||||
@@ -12,7 +12,7 @@ LUCI_TYPE:=mod
|
||||
LUCI_BASENAME:=base
|
||||
|
||||
LUCI_TITLE:=LuCI core libraries
|
||||
-LUCI_DEPENDS:=+lua +libuci-lua +luci-lib-nixio +luci-lib-ip +rpcd
|
||||
+LUCI_DEPENDS:=+lua +libuci-lua +libubus-lua +luci-lib-nixio +luci-lib-ip +rpcd
|
||||
|
||||
PKG_SOURCE:=LuaSrcDiet-0.12.1.tar.bz2
|
||||
PKG_SOURCE_URL:=https://luasrcdiet.googlecode.com/files
|
@ -6,15 +6,15 @@ LuCI's authentication won't work without rpcd, but we aren't using the
|
||||
authentication anyways. Users who need it can just install rpcd explicitly.
|
||||
|
||||
diff --git a/modules/luci-base/Makefile b/modules/luci-base/Makefile
|
||||
index 55c21eb..7a1009c 100644
|
||||
index 54506b0..4457034 100644
|
||||
--- a/modules/luci-base/Makefile
|
||||
+++ b/modules/luci-base/Makefile
|
||||
@@ -12,7 +12,7 @@ LUCI_TYPE:=mod
|
||||
LUCI_BASENAME:=base
|
||||
|
||||
LUCI_TITLE:=LuCI core libraries
|
||||
-LUCI_DEPENDS:=+lua +libuci-lua +libubus-lua +luci-lib-nixio +luci-lib-ip +rpcd
|
||||
+LUCI_DEPENDS:=+lua +libuci-lua +libubus-lua +luci-lib-nixio +luci-lib-ip
|
||||
-LUCI_DEPENDS:=+lua +libuci-lua +luci-lib-nixio +luci-lib-ip +rpcd +libubus-lua
|
||||
+LUCI_DEPENDS:=+lua +libuci-lua +luci-lib-nixio +luci-lib-ip +libubus-lua
|
||||
|
||||
PKG_SOURCE:=LuaSrcDiet-0.12.1.tar.bz2
|
||||
PKG_SOURCE_URL:=https://luasrcdiet.googlecode.com/files
|
@ -3,7 +3,7 @@ Date: Wed, 30 Dec 2015 01:00:49 +0100
|
||||
Subject: lua-cjson: add host build support
|
||||
|
||||
diff --git a/lang/lua-cjson/Makefile b/lang/lua-cjson/Makefile
|
||||
index fd489f2..90c8f98 100644
|
||||
index fbdcf17..1adfeb3 100644
|
||||
--- a/lang/lua-cjson/Makefile
|
||||
+++ b/lang/lua-cjson/Makefile
|
||||
@@ -20,6 +20,7 @@ PKG_MD5SUM:=24f270663e9f6ca8ba2a02cef19f7963
|
||||
|
@ -16,7 +16,7 @@ $(eval $(call GluonModelAlias,CPE510,tp-link-cpe510-v1.0,tp-link-cpe520-v1.1))
|
||||
|
||||
# TL-WA701N/ND v1, v2
|
||||
$(eval $(call GluonProfile,TLWA701))
|
||||
$(eval $(call GluonModel,TLWA701,tl-wa701n-v1,tp-link-tl-wa701n-nd-v1))
|
||||
$(eval $(call GluonModel,TLWA701,tl-wa701nd-v1,tp-link-tl-wa701n-nd-v1))
|
||||
$(eval $(call GluonModel,TLWA701,tl-wa701nd-v2,tp-link-tl-wa701n-nd-v2))
|
||||
|
||||
# TL-WA7510 v1
|
||||
@ -56,14 +56,14 @@ $(eval $(call GluonProfile,TLWA801))
|
||||
$(eval $(call GluonModel,TLWA801,tl-wa801nd-v1,tp-link-tl-wa801n-nd-v1))
|
||||
$(eval $(call GluonModel,TLWA801,tl-wa801nd-v2,tp-link-tl-wa801n-nd-v2))
|
||||
|
||||
# TL-WR841N/ND v3, v5, v7, v8, v9
|
||||
# TL-WR841N/ND v3, v5, v7, v8, v9, v10
|
||||
$(eval $(call GluonProfile,TLWR841))
|
||||
$(eval $(call GluonModel,TLWR841,tl-wr841nd-v3,tp-link-tl-wr841n-nd-v3))
|
||||
$(eval $(call GluonModel,TLWR841,tl-wr841nd-v5,tp-link-tl-wr841n-nd-v5))
|
||||
$(eval $(call GluonModel,TLWR841,tl-wr841nd-v7,tp-link-tl-wr841n-nd-v7))
|
||||
$(eval $(call GluonModel,TLWR841,tl-wr841n-v8,tp-link-tl-wr841n-nd-v8))
|
||||
$(eval $(call GluonModel,TLWR841,tl-wr841n-v9,tp-link-tl-wr841n-nd-v9))
|
||||
$(eval $(call GluonModel,TLWR841,tl-wr841n-v10,tp-link-tl-wr841n-nd-v10))
|
||||
$(eval $(call GluonModel,TLWR841,tl-wr841-v3,tp-link-tl-wr841n-nd-v3))
|
||||
$(eval $(call GluonModel,TLWR841,tl-wr841-v5,tp-link-tl-wr841n-nd-v5))
|
||||
$(eval $(call GluonModel,TLWR841,tl-wr841-v7,tp-link-tl-wr841n-nd-v7))
|
||||
$(eval $(call GluonModel,TLWR841,tl-wr841-v8,tp-link-tl-wr841n-nd-v8))
|
||||
$(eval $(call GluonModel,TLWR841,tl-wr841-v9,tp-link-tl-wr841n-nd-v9))
|
||||
$(eval $(call GluonModel,TLWR841,tl-wr841-v10,tp-link-tl-wr841n-nd-v10))
|
||||
|
||||
# TL-WR842N/ND v1, v2
|
||||
$(eval $(call GluonProfile,TLWR842))
|
||||
|
Loading…
Reference in New Issue
Block a user