kernel: split patches folder up into backport, pending and hack folders
* properly format/comment all patches * merge debloat patches * merge Kconfig patches * merge swconfig patches * merge hotplug patches * drop 200-fix_localversion.patch - upstream * drop 222-arm_zimage_none.patch - unused * drop 252-mv_cesa_depends.patch - no longer required * drop 410-mtd-move-forward-declaration-of-struct-mtd_info.patch - unused * drop 661-fq_codel_keep_dropped_stats.patch - outdated * drop 702-phy_add_aneg_done_function.patch - upstream * drop 840-rtc7301.patch - unused * drop 841-rtc_pt7c4338.patch - upstream * drop 921-use_preinit_as_init.patch - unused * drop spio-gpio-old and gpio-mmc - unused Signed-off-by: John Crispin <john@phrozen.org>
This commit is contained in:
parent
de350550ef
commit
74d00a8c38
747 changed files with 3743 additions and 2699 deletions
|
@ -11,7 +11,7 @@ ifneq ($(DUMP),1)
|
||||||
all: compile
|
all: compile
|
||||||
endif
|
endif
|
||||||
|
|
||||||
KERNEL_FILE_DEPENDS=$(GENERIC_PATCH_DIR) $(PATCH_DIR) $(GENERIC_FILES_DIR) $(FILES_DIR)
|
KERNEL_FILE_DEPENDS=$(BACKPORT_PATCH_DIR) $(GENERIC_PATCH_DIR) $(GENERIC_HACK_DIR) $(PATCH_DIR) $(GENERIC_FILES_DIR) $(FILES_DIR)
|
||||||
STAMP_PREPARED=$(LINUX_DIR)/.prepared$(if $(QUILT)$(DUMP),,_$(shell $(call find_md5,$(KERNEL_FILE_DEPENDS),)))
|
STAMP_PREPARED=$(LINUX_DIR)/.prepared$(if $(QUILT)$(DUMP),,_$(shell $(call find_md5,$(KERNEL_FILE_DEPENDS),)))
|
||||||
STAMP_CONFIGURED:=$(LINUX_DIR)/.configured
|
STAMP_CONFIGURED:=$(LINUX_DIR)/.configured
|
||||||
include $(INCLUDE_DIR)/download.mk
|
include $(INCLUDE_DIR)/download.mk
|
||||||
|
|
|
@ -97,7 +97,13 @@ define Kernel/Patch/Default
|
||||||
$(if $(QUILT),rm -rf $(PKG_BUILD_DIR)/patches; mkdir -p $(PKG_BUILD_DIR)/patches)
|
$(if $(QUILT),rm -rf $(PKG_BUILD_DIR)/patches; mkdir -p $(PKG_BUILD_DIR)/patches)
|
||||||
$(if $(kernel_files),$(CP) $(kernel_files) $(LINUX_DIR)/)
|
$(if $(kernel_files),$(CP) $(kernel_files) $(LINUX_DIR)/)
|
||||||
find $(LINUX_DIR)/ -name \*.rej -or -name \*.orig | $(XARGS) rm -f
|
find $(LINUX_DIR)/ -name \*.rej -or -name \*.orig | $(XARGS) rm -f
|
||||||
|
if [ -d $(GENERIC_PLATFORM_DIR)/patches$(if $(wildcard $(GENERIC_PLATFORM_DIR)/patches-$(KERNEL_PATCHVER)),-$(KERNEL_PATCHVER)) ]; then \
|
||||||
|
echo "generic patches directory is present. please move your patches to the pending directory" ; \
|
||||||
|
exit 1; \
|
||||||
|
fi
|
||||||
|
$(call PatchDir,$(PKG_BUILD_DIR),$(GENERIC_BACKPORT_DIR),generic-backport/)
|
||||||
$(call PatchDir,$(PKG_BUILD_DIR),$(GENERIC_PATCH_DIR),generic/)
|
$(call PatchDir,$(PKG_BUILD_DIR),$(GENERIC_PATCH_DIR),generic/)
|
||||||
|
$(call PatchDir,$(PKG_BUILD_DIR),$(GENERIC_HACK_DIR),generic-hack/)
|
||||||
$(call PatchDir,$(PKG_BUILD_DIR),$(PATCH_DIR),platform/)
|
$(call PatchDir,$(PKG_BUILD_DIR),$(PATCH_DIR),platform/)
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
@ -124,7 +130,9 @@ define Quilt/Refresh/Kernel
|
||||||
echo "All kernel patches must start with either generic/ or platform/"; \
|
echo "All kernel patches must start with either generic/ or platform/"; \
|
||||||
false; \
|
false; \
|
||||||
}
|
}
|
||||||
|
$(call Quilt/RefreshDir,$(PKG_BUILD_DIR),$(GENERIC_BACKPORT_DIR),generic-backport/)
|
||||||
$(call Quilt/RefreshDir,$(PKG_BUILD_DIR),$(GENERIC_PATCH_DIR),generic/)
|
$(call Quilt/RefreshDir,$(PKG_BUILD_DIR),$(GENERIC_PATCH_DIR),generic/)
|
||||||
|
$(call Quilt/RefreshDir,$(PKG_BUILD_DIR),$(GENERIC_HACK_DIR),generic-hack/)
|
||||||
$(call Quilt/RefreshDir,$(PKG_BUILD_DIR),$(PATCH_DIR),platform/)
|
$(call Quilt/RefreshDir,$(PKG_BUILD_DIR),$(PATCH_DIR),platform/)
|
||||||
endef
|
endef
|
||||||
|
|
||||||
|
|
|
@ -104,7 +104,9 @@ ifneq ($(TARGET_BUILD)$(if $(DUMP),,1),)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
GENERIC_PLATFORM_DIR := $(TOPDIR)/target/linux/generic
|
GENERIC_PLATFORM_DIR := $(TOPDIR)/target/linux/generic
|
||||||
GENERIC_PATCH_DIR := $(GENERIC_PLATFORM_DIR)/patches$(if $(wildcard $(GENERIC_PLATFORM_DIR)/patches-$(KERNEL_PATCHVER)),-$(KERNEL_PATCHVER))
|
GENERIC_BACKPORT_DIR := $(GENERIC_PLATFORM_DIR)/backport$(if $(wildcard $(GENERIC_PLATFORM_DIR)/backport-$(KERNEL_PATCHVER)),-$(KERNEL_PATCHVER))
|
||||||
|
GENERIC_PATCH_DIR := $(GENERIC_PLATFORM_DIR)/pending$(if $(wildcard $(GENERIC_PLATFORM_DIR)/pending-$(KERNEL_PATCHVER)),-$(KERNEL_PATCHVER))
|
||||||
|
GENERIC_HACK_DIR := $(GENERIC_PLATFORM_DIR)/hack$(if $(wildcard $(GENERIC_PLATFORM_DIR)/hack-$(KERNEL_PATCHVER)),-$(KERNEL_PATCHVER))
|
||||||
GENERIC_FILES_DIR := $(foreach dir,$(wildcard $(GENERIC_PLATFORM_DIR)/files $(GENERIC_PLATFORM_DIR)/files-$(KERNEL_PATCHVER)),"$(dir)")
|
GENERIC_FILES_DIR := $(foreach dir,$(wildcard $(GENERIC_PLATFORM_DIR)/files $(GENERIC_PLATFORM_DIR)/files-$(KERNEL_PATCHVER)),"$(dir)")
|
||||||
|
|
||||||
__config_name_list = $(1)/config-$(KERNEL_PATCHVER) $(1)/config-default
|
__config_name_list = $(1)/config-$(KERNEL_PATCHVER) $(1)/config-default
|
||||||
|
|
|
@ -1,13 +1,19 @@
|
||||||
|
From 13b1ecc3401653a355798eb1dee10cc1608202f4 Mon Sep 17 00:00:00 2001
|
||||||
From: Felix Fietkau <nbd@nbd.name>
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
Date: Mon, 18 Jan 2016 12:27:49 +0100
|
Date: Mon, 18 Jan 2016 12:27:49 +0100
|
||||||
Subject: [PATCH] Kbuild: don't hardcode path to awk in scripts/ld-version.sh
|
Subject: [PATCH 33/34] Kbuild: don't hardcode path to awk in
|
||||||
|
scripts/ld-version.sh
|
||||||
|
|
||||||
On some systems /usr/bin/awk does not exist, or is broken. Find it via
|
On some systems /usr/bin/awk does not exist, or is broken. Find it via
|
||||||
$PATH instead.
|
$PATH instead.
|
||||||
|
|
||||||
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
---
|
---
|
||||||
|
scripts/ld-version.sh | 4 +++-
|
||||||
|
1 file changed, 3 insertions(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/scripts/ld-version.sh b/scripts/ld-version.sh
|
||||||
|
index d135882e2c40..66e6e5ed1b7b 100755
|
||||||
--- a/scripts/ld-version.sh
|
--- a/scripts/ld-version.sh
|
||||||
+++ b/scripts/ld-version.sh
|
+++ b/scripts/ld-version.sh
|
||||||
@@ -1,5 +1,6 @@
|
@@ -1,5 +1,6 @@
|
||||||
|
@ -23,3 +29,6 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
exit
|
exit
|
||||||
}
|
}
|
||||||
+'
|
+'
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,6 +1,18 @@
|
||||||
|
From 173019b66dcc9d68ad9333aa744dad1e369b5aa8 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Sun, 9 Jul 2017 00:26:53 +0200
|
||||||
|
Subject: [PATCH 34/34] kernel: add compile fix for linux 4.9 on x86
|
||||||
|
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
---
|
||||||
|
Makefile | 4 ++--
|
||||||
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/Makefile b/Makefile
|
||||||
|
index dd0a67d6e392..6e37f6bb669a 100644
|
||||||
--- a/Makefile
|
--- a/Makefile
|
||||||
+++ b/Makefile
|
+++ b/Makefile
|
||||||
@@ -414,8 +414,8 @@ KERNELRELEASE = $(shell cat include/conf
|
@@ -420,8 +420,8 @@ KERNELRELEASE = $(shell cat include/config/kernel.release 2> /dev/null)
|
||||||
KERNELVERSION = $(VERSION)$(if $(PATCHLEVEL),.$(PATCHLEVEL)$(if $(SUBLEVEL),.$(SUBLEVEL)))$(EXTRAVERSION)
|
KERNELVERSION = $(VERSION)$(if $(PATCHLEVEL),.$(PATCHLEVEL)$(if $(SUBLEVEL),.$(SUBLEVEL)))$(EXTRAVERSION)
|
||||||
|
|
||||||
export VERSION PATCHLEVEL SUBLEVEL KERNELRELEASE KERNELVERSION
|
export VERSION PATCHLEVEL SUBLEVEL KERNELRELEASE KERNELVERSION
|
||||||
|
@ -11,3 +23,6 @@
|
||||||
export MAKE AWK GENKSYMS INSTALLKERNEL PERL PYTHON UTS_MACHINE
|
export MAKE AWK GENKSYMS INSTALLKERNEL PERL PYTHON UTS_MACHINE
|
||||||
export HOSTCXX HOSTCXXFLAGS LDFLAGS_MODULE CHECK CHECKFLAGS
|
export HOSTCXX HOSTCXXFLAGS LDFLAGS_MODULE CHECK CHECKFLAGS
|
||||||
|
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,4 +1,7 @@
|
||||||
Subject: netfilter: conntrack: cache route for forwarded connections
|
From c4d66e57455f5384128753674cc0f9e02db5e1f6 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Florian Westphal <fw@strlen.de>
|
||||||
|
Date: Sun, 9 Jul 2017 08:58:30 +0200
|
||||||
|
Subject: [PATCH] netfilter: conntrack: cache route for forwarded connections
|
||||||
|
|
||||||
... to avoid per-packet FIB lookup if possible.
|
... to avoid per-packet FIB lookup if possible.
|
||||||
|
|
||||||
|
@ -22,7 +25,18 @@ Julian Anastasov suggested to add NETDEV_UNREGISTER handler to
|
||||||
avoid holding on to dsts of 'frozen' conntracks.
|
avoid holding on to dsts of 'frozen' conntracks.
|
||||||
|
|
||||||
Signed-off-by: Florian Westphal <fw@strlen.de>
|
Signed-off-by: Florian Westphal <fw@strlen.de>
|
||||||
|
---
|
||||||
|
include/net/netfilter/nf_conntrack_extend.h | 4 +
|
||||||
|
include/net/netfilter/nf_conntrack_rtcache.h | 34 +++
|
||||||
|
net/netfilter/Kconfig | 12 +
|
||||||
|
net/netfilter/Makefile | 3 +
|
||||||
|
net/netfilter/nf_conntrack_rtcache.c | 413 +++++++++++++++++++++++++++
|
||||||
|
5 files changed, 466 insertions(+)
|
||||||
|
create mode 100644 include/net/netfilter/nf_conntrack_rtcache.h
|
||||||
|
create mode 100644 net/netfilter/nf_conntrack_rtcache.c
|
||||||
|
|
||||||
|
diff --git a/include/net/netfilter/nf_conntrack_extend.h b/include/net/netfilter/nf_conntrack_extend.h
|
||||||
|
index 1c3035dda31f..0988c7dfa604 100644
|
||||||
--- a/include/net/netfilter/nf_conntrack_extend.h
|
--- a/include/net/netfilter/nf_conntrack_extend.h
|
||||||
+++ b/include/net/netfilter/nf_conntrack_extend.h
|
+++ b/include/net/netfilter/nf_conntrack_extend.h
|
||||||
@@ -27,6 +27,9 @@ enum nf_ct_ext_id {
|
@@ -27,6 +27,9 @@ enum nf_ct_ext_id {
|
||||||
|
@ -43,6 +57,9 @@ Signed-off-by: Florian Westphal <fw@strlen.de>
|
||||||
|
|
||||||
/* Extensions: optional stuff which isn't permanently in struct. */
|
/* Extensions: optional stuff which isn't permanently in struct. */
|
||||||
struct nf_ct_ext {
|
struct nf_ct_ext {
|
||||||
|
diff --git a/include/net/netfilter/nf_conntrack_rtcache.h b/include/net/netfilter/nf_conntrack_rtcache.h
|
||||||
|
new file mode 100644
|
||||||
|
index 000000000000..e2fb30243354
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/include/net/netfilter/nf_conntrack_rtcache.h
|
+++ b/include/net/netfilter/nf_conntrack_rtcache.h
|
||||||
@@ -0,0 +1,34 @@
|
@@ -0,0 +1,34 @@
|
||||||
|
@ -80,6 +97,8 @@ Signed-off-by: Florian Westphal <fw@strlen.de>
|
||||||
+{
|
+{
|
||||||
+ return rtc->cached_dst[dir].iif;
|
+ return rtc->cached_dst[dir].iif;
|
||||||
+}
|
+}
|
||||||
|
diff --git a/net/netfilter/Kconfig b/net/netfilter/Kconfig
|
||||||
|
index e8d56d9a4df2..82af5ba64088 100644
|
||||||
--- a/net/netfilter/Kconfig
|
--- a/net/netfilter/Kconfig
|
||||||
+++ b/net/netfilter/Kconfig
|
+++ b/net/netfilter/Kconfig
|
||||||
@@ -114,6 +114,18 @@ config NF_CONNTRACK_EVENTS
|
@@ -114,6 +114,18 @@ config NF_CONNTRACK_EVENTS
|
||||||
|
@ -101,9 +120,11 @@ Signed-off-by: Florian Westphal <fw@strlen.de>
|
||||||
config NF_CONNTRACK_TIMEOUT
|
config NF_CONNTRACK_TIMEOUT
|
||||||
bool 'Connection tracking timeout'
|
bool 'Connection tracking timeout'
|
||||||
depends on NETFILTER_ADVANCED
|
depends on NETFILTER_ADVANCED
|
||||||
|
diff --git a/net/netfilter/Makefile b/net/netfilter/Makefile
|
||||||
|
index c23c3c84416f..8adef51367f9 100644
|
||||||
--- a/net/netfilter/Makefile
|
--- a/net/netfilter/Makefile
|
||||||
+++ b/net/netfilter/Makefile
|
+++ b/net/netfilter/Makefile
|
||||||
@@ -16,6 +16,9 @@ obj-$(CONFIG_NETFILTER_NETLINK_LOG) += n
|
@@ -16,6 +16,9 @@ obj-$(CONFIG_NETFILTER_NETLINK_LOG) += nfnetlink_log.o
|
||||||
# connection tracking
|
# connection tracking
|
||||||
obj-$(CONFIG_NF_CONNTRACK) += nf_conntrack.o
|
obj-$(CONFIG_NF_CONNTRACK) += nf_conntrack.o
|
||||||
|
|
||||||
|
@ -113,6 +134,9 @@ Signed-off-by: Florian Westphal <fw@strlen.de>
|
||||||
# SCTP protocol connection tracking
|
# SCTP protocol connection tracking
|
||||||
obj-$(CONFIG_NF_CT_PROTO_DCCP) += nf_conntrack_proto_dccp.o
|
obj-$(CONFIG_NF_CT_PROTO_DCCP) += nf_conntrack_proto_dccp.o
|
||||||
obj-$(CONFIG_NF_CT_PROTO_GRE) += nf_conntrack_proto_gre.o
|
obj-$(CONFIG_NF_CT_PROTO_GRE) += nf_conntrack_proto_gre.o
|
||||||
|
diff --git a/net/netfilter/nf_conntrack_rtcache.c b/net/netfilter/nf_conntrack_rtcache.c
|
||||||
|
new file mode 100644
|
||||||
|
index 000000000000..fb073d01960d
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/net/netfilter/nf_conntrack_rtcache.c
|
+++ b/net/netfilter/nf_conntrack_rtcache.c
|
||||||
@@ -0,0 +1,413 @@
|
@@ -0,0 +1,413 @@
|
||||||
|
@ -529,3 +553,6 @@ Signed-off-by: Florian Westphal <fw@strlen.de>
|
||||||
+MODULE_LICENSE("GPL");
|
+MODULE_LICENSE("GPL");
|
||||||
+MODULE_AUTHOR("Florian Westphal <fw@strlen.de>");
|
+MODULE_AUTHOR("Florian Westphal <fw@strlen.de>");
|
||||||
+MODULE_DESCRIPTION("Conntrack route cache extension");
|
+MODULE_DESCRIPTION("Conntrack route cache extension");
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -106,7 +106,7 @@ Signed-off-by: Linus Lüssing <linus.luessing@c0d3.blue>
|
||||||
if (prev == port)
|
if (prev == port)
|
||||||
--- a/net/bridge/br_mdb.c
|
--- a/net/bridge/br_mdb.c
|
||||||
+++ b/net/bridge/br_mdb.c
|
+++ b/net/bridge/br_mdb.c
|
||||||
@@ -532,7 +532,7 @@ static int br_mdb_add_group(struct net_b
|
@@ -531,7 +531,7 @@ static int br_mdb_add_group(struct net_b
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,8 +26,8 @@ Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
|
||||||
|
|
||||||
--- a/drivers/mtd/spi-nor/spi-nor.c
|
--- a/drivers/mtd/spi-nor/spi-nor.c
|
||||||
+++ b/drivers/mtd/spi-nor/spi-nor.c
|
+++ b/drivers/mtd/spi-nor/spi-nor.c
|
||||||
@@ -1263,6 +1263,13 @@ static int spansion_quad_enable(struct s
|
@@ -1256,6 +1256,13 @@ static int spansion_quad_enable(struct s
|
||||||
return ret;
|
return -EINVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
+ ret = spi_nor_wait_till_ready(nor);
|
+ ret = spi_nor_wait_till_ready(nor);
|
|
@ -206,7 +206,7 @@ Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
|
||||||
if (ret < 0)
|
if (ret < 0)
|
||||||
goto write_err;
|
goto write_err;
|
||||||
written = ret;
|
written = ret;
|
||||||
@@ -1319,6 +1408,47 @@ static int spi_nor_check(struct spi_nor
|
@@ -1312,6 +1401,47 @@ static int spi_nor_check(struct spi_nor
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -254,7 +254,7 @@ Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
|
||||||
int spi_nor_scan(struct spi_nor *nor, const char *name, enum read_mode mode)
|
int spi_nor_scan(struct spi_nor *nor, const char *name, enum read_mode mode)
|
||||||
{
|
{
|
||||||
const struct flash_info *info = NULL;
|
const struct flash_info *info = NULL;
|
||||||
@@ -1367,6 +1497,14 @@ int spi_nor_scan(struct spi_nor *nor, co
|
@@ -1360,6 +1490,14 @@ int spi_nor_scan(struct spi_nor *nor, co
|
||||||
mutex_init(&nor->lock);
|
mutex_init(&nor->lock);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -269,7 +269,7 @@ Signed-off-by: Cyrille Pitchen <cyrille.pitchen@atmel.com>
|
||||||
* Atmel, SST, Intel/Numonyx, and others serial NOR tend to power up
|
* Atmel, SST, Intel/Numonyx, and others serial NOR tend to power up
|
||||||
* with the software protection bits set
|
* with the software protection bits set
|
||||||
*/
|
*/
|
||||||
@@ -1524,6 +1662,12 @@ int spi_nor_scan(struct spi_nor *nor, co
|
@@ -1517,6 +1655,12 @@ int spi_nor_scan(struct spi_nor *nor, co
|
||||||
|
|
||||||
nor->read_dummy = spi_nor_read_dummy_cycles(nor);
|
nor->read_dummy = spi_nor_read_dummy_cycles(nor);
|
||||||
|
|
|
@ -95,7 +95,7 @@ Acked-by: Marek Vasut <marek.vasut@gmail.com>
|
||||||
static struct seq_rw_config stfsm_s25fl_write4_configs[] = {
|
static struct seq_rw_config stfsm_s25fl_write4_configs[] = {
|
||||||
--- a/drivers/mtd/spi-nor/spi-nor.c
|
--- a/drivers/mtd/spi-nor/spi-nor.c
|
||||||
+++ b/drivers/mtd/spi-nor/spi-nor.c
|
+++ b/drivers/mtd/spi-nor/spi-nor.c
|
||||||
@@ -1632,16 +1632,16 @@ int spi_nor_scan(struct spi_nor *nor, co
|
@@ -1625,16 +1625,16 @@ int spi_nor_scan(struct spi_nor *nor, co
|
||||||
/* Dedicated 4-byte command set */
|
/* Dedicated 4-byte command set */
|
||||||
switch (nor->flash_read) {
|
switch (nor->flash_read) {
|
||||||
case SPI_NOR_QUAD:
|
case SPI_NOR_QUAD:
|
|
@ -116,7 +116,7 @@ Acked-by: Marek Vasut <marek.vasut@gmail.com>
|
||||||
/* Enable/disable 4-byte addressing mode. */
|
/* Enable/disable 4-byte addressing mode. */
|
||||||
static inline int set_4byte(struct spi_nor *nor, const struct flash_info *info,
|
static inline int set_4byte(struct spi_nor *nor, const struct flash_info *info,
|
||||||
int enable)
|
int enable)
|
||||||
@@ -1628,27 +1704,10 @@ int spi_nor_scan(struct spi_nor *nor, co
|
@@ -1621,27 +1697,10 @@ int spi_nor_scan(struct spi_nor *nor, co
|
||||||
else if (mtd->size > 0x1000000) {
|
else if (mtd->size > 0x1000000) {
|
||||||
/* enable 4-byte addressing if the device exceeds 16MiB */
|
/* enable 4-byte addressing if the device exceeds 16MiB */
|
||||||
nor->addr_width = 4;
|
nor->addr_width = 4;
|
29
target/linux/generic/hack-4.9/202-reduce_module_size.patch
Normal file
29
target/linux/generic/hack-4.9/202-reduce_module_size.patch
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
From fd66884da2f96d2a7ea73f58b1b86251b959a913 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Fri, 7 Jul 2017 16:56:19 +0200
|
||||||
|
Subject: kernel: strip unnecessary symbol table information from kernel modules
|
||||||
|
|
||||||
|
reduces default squashfs size on ar71xx by about 4k
|
||||||
|
|
||||||
|
lede-commit: 058d331a39077f159ca8922f1f422a1346d6aa67
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
---
|
||||||
|
Makefile | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/Makefile b/Makefile
|
||||||
|
index a40b373eba3a..984eb5907d00 100644
|
||||||
|
--- a/Makefile
|
||||||
|
+++ b/Makefile
|
||||||
|
@@ -407,7 +407,7 @@ KBUILD_CFLAGS_KERNEL :=
|
||||||
|
KBUILD_AFLAGS := -D__ASSEMBLY__ $(call cc-option,-fno-PIE)
|
||||||
|
KBUILD_AFLAGS_MODULE := -DMODULE
|
||||||
|
KBUILD_CFLAGS_MODULE := -DMODULE
|
||||||
|
-KBUILD_LDFLAGS_MODULE := -T $(srctree)/scripts/module-common.lds
|
||||||
|
+KBUILD_LDFLAGS_MODULE = -T $(srctree)/scripts/module-common.lds $(if $(CONFIG_PROFILING),,-s)
|
||||||
|
|
||||||
|
# Read KERNELRELEASE from include/config/kernel.release (if it exists)
|
||||||
|
KERNELRELEASE = $(shell cat include/config/kernel.release 2> /dev/null)
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,8 +1,19 @@
|
||||||
|
From a779a482fb9b9f8fcdf8b2519c789b4b9bb5dd05 Mon Sep 17 00:00:00 2001
|
||||||
From: Felix Fietkau <nbd@nbd.name>
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
Subject: [PATCH] build: add a hack for removing non-essential module info
|
Date: Fri, 7 Jul 2017 16:56:48 +0200
|
||||||
|
Subject: build: add a hack for removing non-essential module info
|
||||||
|
|
||||||
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
---
|
---
|
||||||
|
include/linux/module.h | 13 ++++++++-----
|
||||||
|
include/linux/moduleparam.h | 15 ++++++++++++---
|
||||||
|
init/Kconfig | 7 +++++++
|
||||||
|
kernel/module.c | 5 ++++-
|
||||||
|
scripts/mod/modpost.c | 12 ++++++++++++
|
||||||
|
5 files changed, 43 insertions(+), 9 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/include/linux/module.h b/include/linux/module.h
|
||||||
|
index 0c3207d26ac0..08b58474bfd2 100644
|
||||||
--- a/include/linux/module.h
|
--- a/include/linux/module.h
|
||||||
+++ b/include/linux/module.h
|
+++ b/include/linux/module.h
|
||||||
@@ -159,6 +159,7 @@ extern void cleanup_module(void);
|
@@ -159,6 +159,7 @@ extern void cleanup_module(void);
|
||||||
|
@ -29,7 +40,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
/* Creates an alias so file2alias.c can find device table. */
|
/* Creates an alias so file2alias.c can find device table. */
|
||||||
#define MODULE_DEVICE_TABLE(type, name) \
|
#define MODULE_DEVICE_TABLE(type, name) \
|
||||||
extern const typeof(name) __mod_##type##__##name##_device_table \
|
extern const typeof(name) __mod_##type##__##name##_device_table \
|
||||||
@@ -234,7 +235,9 @@ extern const typeof(name) __mod_##type##
|
@@ -234,7 +235,9 @@ extern const typeof(name) __mod_##type##__##name##_device_table \
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#if defined(MODULE) || !defined(CONFIG_SYSFS)
|
#if defined(MODULE) || !defined(CONFIG_SYSFS)
|
||||||
|
@ -40,7 +51,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
#else
|
#else
|
||||||
#define MODULE_VERSION(_version) \
|
#define MODULE_VERSION(_version) \
|
||||||
static struct module_version_attribute ___modver_attr = { \
|
static struct module_version_attribute ___modver_attr = { \
|
||||||
@@ -256,7 +259,7 @@ extern const typeof(name) __mod_##type##
|
@@ -256,7 +259,7 @@ extern const typeof(name) __mod_##type##__##name##_device_table \
|
||||||
/* Optional firmware file (or files) needed by the module
|
/* Optional firmware file (or files) needed by the module
|
||||||
* format is simply firmware file name. Multiple firmware
|
* format is simply firmware file name. Multiple firmware
|
||||||
* files require multiple MODULE_FIRMWARE() specifiers */
|
* files require multiple MODULE_FIRMWARE() specifiers */
|
||||||
|
@ -49,6 +60,8 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
|
||||||
struct notifier_block;
|
struct notifier_block;
|
||||||
|
|
||||||
|
diff --git a/include/linux/moduleparam.h b/include/linux/moduleparam.h
|
||||||
|
index 52666d90ca94..f0db3592906a 100644
|
||||||
--- a/include/linux/moduleparam.h
|
--- a/include/linux/moduleparam.h
|
||||||
+++ b/include/linux/moduleparam.h
|
+++ b/include/linux/moduleparam.h
|
||||||
@@ -16,6 +16,16 @@
|
@@ -16,6 +16,16 @@
|
||||||
|
@ -68,7 +81,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
#ifdef MODULE
|
#ifdef MODULE
|
||||||
#define __MODULE_INFO(tag, name, info) \
|
#define __MODULE_INFO(tag, name, info) \
|
||||||
static const char __UNIQUE_ID(name)[] \
|
static const char __UNIQUE_ID(name)[] \
|
||||||
@@ -23,8 +33,7 @@ static const char __UNIQUE_ID(name)[]
|
@@ -23,8 +33,7 @@ static const char __UNIQUE_ID(name)[] \
|
||||||
= __stringify(tag) "=" info
|
= __stringify(tag) "=" info
|
||||||
#else /* !MODULE */
|
#else /* !MODULE */
|
||||||
/* This struct is here for syntactic coherency, it is not used */
|
/* This struct is here for syntactic coherency, it is not used */
|
||||||
|
@ -78,7 +91,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
#endif
|
#endif
|
||||||
#define __MODULE_PARM_TYPE(name, _type) \
|
#define __MODULE_PARM_TYPE(name, _type) \
|
||||||
__MODULE_INFO(parmtype, name##type, #name ":" _type)
|
__MODULE_INFO(parmtype, name##type, #name ":" _type)
|
||||||
@@ -32,7 +41,7 @@ static const char __UNIQUE_ID(name)[]
|
@@ -32,7 +41,7 @@ static const char __UNIQUE_ID(name)[] \
|
||||||
/* One for each parameter, describing how to use it. Some files do
|
/* One for each parameter, describing how to use it. Some files do
|
||||||
multiple of these per line, so can't just use MODULE_INFO. */
|
multiple of these per line, so can't just use MODULE_INFO. */
|
||||||
#define MODULE_PARM_DESC(_parm, desc) \
|
#define MODULE_PARM_DESC(_parm, desc) \
|
||||||
|
@ -87,9 +100,11 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
|
||||||
struct kernel_param;
|
struct kernel_param;
|
||||||
|
|
||||||
|
diff --git a/init/Kconfig b/init/Kconfig
|
||||||
|
index 34407f15e6d3..9f2c0cabbc97 100644
|
||||||
--- a/init/Kconfig
|
--- a/init/Kconfig
|
||||||
+++ b/init/Kconfig
|
+++ b/init/Kconfig
|
||||||
@@ -2106,6 +2106,13 @@ config TRIM_UNUSED_KSYMS
|
@@ -2095,6 +2095,13 @@ config TRIM_UNUSED_KSYMS
|
||||||
|
|
||||||
If unsure, or if you need to build out-of-tree modules, say N.
|
If unsure, or if you need to build out-of-tree modules, say N.
|
||||||
|
|
||||||
|
@ -103,9 +118,11 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
endif # MODULES
|
endif # MODULES
|
||||||
|
|
||||||
config MODULES_TREE_LOOKUP
|
config MODULES_TREE_LOOKUP
|
||||||
|
diff --git a/kernel/module.c b/kernel/module.c
|
||||||
|
index 0e54d5bf0097..80b5ac4181c6 100644
|
||||||
--- a/kernel/module.c
|
--- a/kernel/module.c
|
||||||
+++ b/kernel/module.c
|
+++ b/kernel/module.c
|
||||||
@@ -2945,9 +2945,11 @@ static struct module *setup_load_info(st
|
@@ -2945,9 +2945,11 @@ static struct module *setup_load_info(struct load_info *info, int flags)
|
||||||
|
|
||||||
static int check_modinfo(struct module *mod, struct load_info *info, int flags)
|
static int check_modinfo(struct module *mod, struct load_info *info, int flags)
|
||||||
{
|
{
|
||||||
|
@ -118,7 +135,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
if (flags & MODULE_INIT_IGNORE_VERMAGIC)
|
if (flags & MODULE_INIT_IGNORE_VERMAGIC)
|
||||||
modmagic = NULL;
|
modmagic = NULL;
|
||||||
|
|
||||||
@@ -2968,6 +2970,7 @@ static int check_modinfo(struct module *
|
@@ -2968,6 +2970,7 @@ static int check_modinfo(struct module *mod, struct load_info *info, int flags)
|
||||||
mod->name);
|
mod->name);
|
||||||
add_taint_module(mod, TAINT_OOT_MODULE, LOCKDEP_STILL_OK);
|
add_taint_module(mod, TAINT_OOT_MODULE, LOCKDEP_STILL_OK);
|
||||||
}
|
}
|
||||||
|
@ -126,6 +143,8 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
|
||||||
if (get_modinfo(info, "staging")) {
|
if (get_modinfo(info, "staging")) {
|
||||||
add_taint_module(mod, TAINT_CRAP, LOCKDEP_STILL_OK);
|
add_taint_module(mod, TAINT_CRAP, LOCKDEP_STILL_OK);
|
||||||
|
diff --git a/scripts/mod/modpost.c b/scripts/mod/modpost.c
|
||||||
|
index bd8349759095..80f214adbe44 100644
|
||||||
--- a/scripts/mod/modpost.c
|
--- a/scripts/mod/modpost.c
|
||||||
+++ b/scripts/mod/modpost.c
|
+++ b/scripts/mod/modpost.c
|
||||||
@@ -1964,7 +1964,9 @@ static void read_symbols(char *modname)
|
@@ -1964,7 +1964,9 @@ static void read_symbols(char *modname)
|
||||||
|
@ -138,7 +157,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
}
|
}
|
||||||
if (!is_vmlinux(modname) ||
|
if (!is_vmlinux(modname) ||
|
||||||
(is_vmlinux(modname) && vmlinux_section_warnings))
|
(is_vmlinux(modname) && vmlinux_section_warnings))
|
||||||
@@ -2108,7 +2110,9 @@ static void add_header(struct buffer *b,
|
@@ -2108,7 +2110,9 @@ static void add_header(struct buffer *b, struct module *mod)
|
||||||
buf_printf(b, "#include <linux/vermagic.h>\n");
|
buf_printf(b, "#include <linux/vermagic.h>\n");
|
||||||
buf_printf(b, "#include <linux/compiler.h>\n");
|
buf_printf(b, "#include <linux/compiler.h>\n");
|
||||||
buf_printf(b, "\n");
|
buf_printf(b, "\n");
|
||||||
|
@ -148,7 +167,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
buf_printf(b, "\n");
|
buf_printf(b, "\n");
|
||||||
buf_printf(b, "__visible struct module __this_module\n");
|
buf_printf(b, "__visible struct module __this_module\n");
|
||||||
buf_printf(b, "__attribute__((section(\".gnu.linkonce.this_module\"))) = {\n");
|
buf_printf(b, "__attribute__((section(\".gnu.linkonce.this_module\"))) = {\n");
|
||||||
@@ -2125,16 +2129,20 @@ static void add_header(struct buffer *b,
|
@@ -2125,16 +2129,20 @@ static void add_header(struct buffer *b, struct module *mod)
|
||||||
|
|
||||||
static void add_intree_flag(struct buffer *b, int is_intree)
|
static void add_intree_flag(struct buffer *b, int is_intree)
|
||||||
{
|
{
|
||||||
|
@ -169,7 +188,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
}
|
}
|
||||||
|
|
||||||
/* In kernel, this size is defined in linux/module.h;
|
/* In kernel, this size is defined in linux/module.h;
|
||||||
@@ -2238,11 +2246,13 @@ static void add_depends(struct buffer *b
|
@@ -2238,11 +2246,13 @@ static void add_depends(struct buffer *b, struct module *mod,
|
||||||
|
|
||||||
static void add_srcversion(struct buffer *b, struct module *mod)
|
static void add_srcversion(struct buffer *b, struct module *mod)
|
||||||
{
|
{
|
||||||
|
@ -193,3 +212,6 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
add_srcversion(&buf, mod);
|
add_srcversion(&buf, mod);
|
||||||
|
|
||||||
sprintf(fname, "%s.mod.c", mod->name);
|
sprintf(fname, "%s.mod.c", mod->name);
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,11 +1,23 @@
|
||||||
Disable modules.order to improve build performance.
|
From c9ef4ab0f54356ee9f91d9676ea0ec123840ddc7 Mon Sep 17 00:00:00 2001
|
||||||
This file is not needed for anything in LEDE
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Fri, 7 Jul 2017 16:57:33 +0200
|
||||||
|
Subject: kernel: do not build modules.order
|
||||||
|
|
||||||
|
It is not needed for anything on the system and skipping this saves some
|
||||||
|
build time, especially in cases where there is nothing to do.
|
||||||
|
|
||||||
|
lede-commit: afc1675833a7bf5df094f59f7250369520646d04
|
||||||
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
---
|
---
|
||||||
|
Makefile | 2 --
|
||||||
|
scripts/Makefile.build | 2 +-
|
||||||
|
2 files changed, 1 insertion(+), 3 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/Makefile b/Makefile
|
||||||
|
index 984eb5907d00..cce1c68e48ae 100644
|
||||||
--- a/Makefile
|
--- a/Makefile
|
||||||
+++ b/Makefile
|
+++ b/Makefile
|
||||||
@@ -1196,7 +1196,6 @@ all: modules
|
@@ -1193,7 +1193,6 @@ all: modules
|
||||||
|
|
||||||
PHONY += modules
|
PHONY += modules
|
||||||
modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux) modules.builtin
|
modules: $(vmlinux-dirs) $(if $(KBUILD_BUILTIN),vmlinux) modules.builtin
|
||||||
|
@ -13,7 +25,7 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
@$(kecho) ' Building modules, stage 2.';
|
@$(kecho) ' Building modules, stage 2.';
|
||||||
$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost
|
$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modpost
|
||||||
$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.fwinst obj=firmware __fw_modbuild
|
$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.fwinst obj=firmware __fw_modbuild
|
||||||
@@ -1226,7 +1225,6 @@ _modinst_:
|
@@ -1223,7 +1222,6 @@ _modinst_:
|
||||||
rm -f $(MODLIB)/build ; \
|
rm -f $(MODLIB)/build ; \
|
||||||
ln -s $(CURDIR) $(MODLIB)/build ; \
|
ln -s $(CURDIR) $(MODLIB)/build ; \
|
||||||
fi
|
fi
|
||||||
|
@ -21,6 +33,8 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
@cp -f $(objtree)/modules.builtin $(MODLIB)/
|
@cp -f $(objtree)/modules.builtin $(MODLIB)/
|
||||||
$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modinst
|
$(Q)$(MAKE) -f $(srctree)/scripts/Makefile.modinst
|
||||||
|
|
||||||
|
diff --git a/scripts/Makefile.build b/scripts/Makefile.build
|
||||||
|
index 7675d11ee65e..108d73273788 100644
|
||||||
--- a/scripts/Makefile.build
|
--- a/scripts/Makefile.build
|
||||||
+++ b/scripts/Makefile.build
|
+++ b/scripts/Makefile.build
|
||||||
@@ -93,7 +93,7 @@ modorder-target := $(obj)/modules.order
|
@@ -93,7 +93,7 @@ modorder-target := $(obj)/modules.order
|
||||||
|
@ -32,3 +46,6 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
$(subdir-ym) $(always)
|
$(subdir-ym) $(always)
|
||||||
@:
|
@:
|
||||||
|
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,6 +1,23 @@
|
||||||
|
From db7c30dcd9a0391bf13b62c9f91e144d762ef43a Mon Sep 17 00:00:00 2001
|
||||||
|
From: Florian Fainelli <f.fainelli@gmail.com>
|
||||||
|
Date: Fri, 7 Jul 2017 17:00:49 +0200
|
||||||
|
Subject: Add an OSX specific patch to make the kernel be compiled
|
||||||
|
|
||||||
|
lede-commit: 3fc2a24f0422b2f55f9ed43f116db3111f700526
|
||||||
|
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
|
||||||
|
---
|
||||||
|
scripts/kconfig/Makefile | 3 +
|
||||||
|
scripts/mod/elf.h | 3007 ++++++++++++++++++++++++++++++++++++++++++++
|
||||||
|
scripts/mod/mk_elfconfig.c | 4 +
|
||||||
|
scripts/mod/modpost.h | 4 +
|
||||||
|
4 files changed, 3018 insertions(+)
|
||||||
|
create mode 100644 scripts/mod/elf.h
|
||||||
|
|
||||||
|
diff --git a/scripts/kconfig/Makefile b/scripts/kconfig/Makefile
|
||||||
|
index 90a091b6ae4d..f9620652e70a 100644
|
||||||
--- a/scripts/kconfig/Makefile
|
--- a/scripts/kconfig/Makefile
|
||||||
+++ b/scripts/kconfig/Makefile
|
+++ b/scripts/kconfig/Makefile
|
||||||
@@ -163,6 +163,9 @@ check-lxdialog := $(srctree)/$(src)/lxd
|
@@ -163,6 +163,9 @@ check-lxdialog := $(srctree)/$(src)/lxdialog/check-lxdialog.sh
|
||||||
# we really need to do so. (Do not call gcc as part of make mrproper)
|
# we really need to do so. (Do not call gcc as part of make mrproper)
|
||||||
HOST_EXTRACFLAGS += $(shell $(CONFIG_SHELL) $(check-lxdialog) -ccflags) \
|
HOST_EXTRACFLAGS += $(shell $(CONFIG_SHELL) $(check-lxdialog) -ccflags) \
|
||||||
-DLOCALE
|
-DLOCALE
|
||||||
|
@ -10,34 +27,9 @@
|
||||||
|
|
||||||
# ===========================================================================
|
# ===========================================================================
|
||||||
# Shared Makefile for the various kconfig executables:
|
# Shared Makefile for the various kconfig executables:
|
||||||
--- a/scripts/mod/mk_elfconfig.c
|
diff --git a/scripts/mod/elf.h b/scripts/mod/elf.h
|
||||||
+++ b/scripts/mod/mk_elfconfig.c
|
new file mode 100644
|
||||||
@@ -1,7 +1,11 @@
|
index 000000000000..036a176345eb
|
||||||
#include <stdio.h>
|
|
||||||
#include <stdlib.h>
|
|
||||||
#include <string.h>
|
|
||||||
+#ifndef __APPLE__
|
|
||||||
#include <elf.h>
|
|
||||||
+#else
|
|
||||||
+#include "elf.h"
|
|
||||||
+#endif
|
|
||||||
|
|
||||||
int
|
|
||||||
main(int argc, char **argv)
|
|
||||||
--- a/scripts/mod/modpost.h
|
|
||||||
+++ b/scripts/mod/modpost.h
|
|
||||||
@@ -7,7 +7,11 @@
|
|
||||||
#include <sys/mman.h>
|
|
||||||
#include <fcntl.h>
|
|
||||||
#include <unistd.h>
|
|
||||||
+#if !(defined(__APPLE__) || defined(__CYGWIN__))
|
|
||||||
#include <elf.h>
|
|
||||||
+#else
|
|
||||||
+#include "elf.h"
|
|
||||||
+#endif
|
|
||||||
|
|
||||||
#include "elfconfig.h"
|
|
||||||
|
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/scripts/mod/elf.h
|
+++ b/scripts/mod/elf.h
|
||||||
@@ -0,0 +1,3007 @@
|
@@ -0,0 +1,3007 @@
|
||||||
|
@ -3048,3 +3040,38 @@
|
||||||
+#define R_TILEGX_NUM 130
|
+#define R_TILEGX_NUM 130
|
||||||
+
|
+
|
||||||
+#endif /* elf.h */
|
+#endif /* elf.h */
|
||||||
|
diff --git a/scripts/mod/mk_elfconfig.c b/scripts/mod/mk_elfconfig.c
|
||||||
|
index a4fd71d71d65..5ec3740ebb3c 100644
|
||||||
|
--- a/scripts/mod/mk_elfconfig.c
|
||||||
|
+++ b/scripts/mod/mk_elfconfig.c
|
||||||
|
@@ -1,7 +1,11 @@
|
||||||
|
#include <stdio.h>
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <string.h>
|
||||||
|
+#ifndef __APPLE__
|
||||||
|
#include <elf.h>
|
||||||
|
+#else
|
||||||
|
+#include "elf.h"
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
int
|
||||||
|
main(int argc, char **argv)
|
||||||
|
diff --git a/scripts/mod/modpost.h b/scripts/mod/modpost.h
|
||||||
|
index 6a5e1515123b..237c50d2ec6c 100644
|
||||||
|
--- a/scripts/mod/modpost.h
|
||||||
|
+++ b/scripts/mod/modpost.h
|
||||||
|
@@ -7,7 +7,11 @@
|
||||||
|
#include <sys/mman.h>
|
||||||
|
#include <fcntl.h>
|
||||||
|
#include <unistd.h>
|
||||||
|
+#if !(defined(__APPLE__) || defined(__CYGWIN__))
|
||||||
|
#include <elf.h>
|
||||||
|
+#else
|
||||||
|
+#include "elf.h"
|
||||||
|
+#endif
|
||||||
|
|
||||||
|
#include "elfconfig.h"
|
||||||
|
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -0,0 +1,49 @@
|
||||||
|
From 7f698012384ccb1ed10cc758acfd085096fdb307 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Fri, 7 Jul 2017 17:02:03 +0200
|
||||||
|
Subject: kernel: fix linux 4.9 host tools portability issues
|
||||||
|
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
---
|
||||||
|
tools/build/Build.include | 2 +-
|
||||||
|
tools/perf/pmu-events/jevents.c | 1 +
|
||||||
|
tools/perf/pmu-events/json.c | 1 -
|
||||||
|
3 files changed, 2 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/tools/build/Build.include b/tools/build/Build.include
|
||||||
|
index 1dcb95e76f70..9d6f97a7c1aa 100644
|
||||||
|
--- a/tools/build/Build.include
|
||||||
|
+++ b/tools/build/Build.include
|
||||||
|
@@ -95,4 +95,4 @@ cxx_flags = -Wp,-MD,$(depfile),-MT,$@ $(CXXFLAGS) -D"BUILD_STR(s)=\#s" $(CXXFLAG
|
||||||
|
###
|
||||||
|
## HOSTCC C flags
|
||||||
|
|
||||||
|
-host_c_flags = -Wp,-MD,$(depfile),-MT,$@ $(CHOSTFLAGS) -D"BUILD_STR(s)=\#s" $(CHOSTFLAGS_$(basetarget).o) $(CHOSTFLAGS_$(obj))
|
||||||
|
+host_c_flags = -MD -MF $(depfile) -MT $@ $(CHOSTFLAGS) -D"BUILD_STR(s)=\#s" $(CHOSTFLAGS_$(basetarget).o) $(CHOSTFLAGS_$(obj))
|
||||||
|
diff --git a/tools/perf/pmu-events/jevents.c b/tools/perf/pmu-events/jevents.c
|
||||||
|
index 41611d7f9873..51333bee190c 100644
|
||||||
|
--- a/tools/perf/pmu-events/jevents.c
|
||||||
|
+++ b/tools/perf/pmu-events/jevents.c
|
||||||
|
@@ -35,6 +35,7 @@
|
||||||
|
#include <stdlib.h>
|
||||||
|
#include <errno.h>
|
||||||
|
#include <string.h>
|
||||||
|
+#include <strings.h>
|
||||||
|
#include <ctype.h>
|
||||||
|
#include <unistd.h>
|
||||||
|
#include <stdarg.h>
|
||||||
|
diff --git a/tools/perf/pmu-events/json.c b/tools/perf/pmu-events/json.c
|
||||||
|
index f67bbb0aa36e..a72c70a97fab 100644
|
||||||
|
--- a/tools/perf/pmu-events/json.c
|
||||||
|
+++ b/tools/perf/pmu-events/json.c
|
||||||
|
@@ -38,7 +38,6 @@
|
||||||
|
#include <unistd.h>
|
||||||
|
#include "jsmn.h"
|
||||||
|
#include "json.h"
|
||||||
|
-#include <linux/kernel.h>
|
||||||
|
|
||||||
|
|
||||||
|
static char *mapfile(const char *fn, size_t *size)
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,3 +1,19 @@
|
||||||
|
From 48232d3d931c95953ce2ddfe7da7bb164aef6a73 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Fri, 7 Jul 2017 17:03:16 +0200
|
||||||
|
Subject: linux-3.6: fix portability of some includes files in tools/ used on the host
|
||||||
|
|
||||||
|
lede-commit: 6040b1d29ab1f047c5e49b748abcb6a3196add28
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
---
|
||||||
|
tools/include/tools/be_byteshift.h | 4 ++++
|
||||||
|
tools/include/tools/le_byteshift.h | 4 ++++
|
||||||
|
tools/include/tools/linux_types.h | 22 ++++++++++++++++++++++
|
||||||
|
3 files changed, 30 insertions(+)
|
||||||
|
create mode 100644 tools/include/tools/linux_types.h
|
||||||
|
|
||||||
|
diff --git a/tools/include/tools/be_byteshift.h b/tools/include/tools/be_byteshift.h
|
||||||
|
index 84c17d836578..ed9932e97bd4 100644
|
||||||
--- a/tools/include/tools/be_byteshift.h
|
--- a/tools/include/tools/be_byteshift.h
|
||||||
+++ b/tools/include/tools/be_byteshift.h
|
+++ b/tools/include/tools/be_byteshift.h
|
||||||
@@ -1,6 +1,10 @@
|
@@ -1,6 +1,10 @@
|
||||||
|
@ -11,6 +27,8 @@
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
|
|
||||||
static inline uint16_t __get_unaligned_be16(const uint8_t *p)
|
static inline uint16_t __get_unaligned_be16(const uint8_t *p)
|
||||||
|
diff --git a/tools/include/tools/le_byteshift.h b/tools/include/tools/le_byteshift.h
|
||||||
|
index 8fe9f2488ec7..2e387b5226d9 100644
|
||||||
--- a/tools/include/tools/le_byteshift.h
|
--- a/tools/include/tools/le_byteshift.h
|
||||||
+++ b/tools/include/tools/le_byteshift.h
|
+++ b/tools/include/tools/le_byteshift.h
|
||||||
@@ -1,6 +1,10 @@
|
@@ -1,6 +1,10 @@
|
||||||
|
@ -24,6 +42,9 @@
|
||||||
#include <stdint.h>
|
#include <stdint.h>
|
||||||
|
|
||||||
static inline uint16_t __get_unaligned_le16(const uint8_t *p)
|
static inline uint16_t __get_unaligned_le16(const uint8_t *p)
|
||||||
|
diff --git a/tools/include/tools/linux_types.h b/tools/include/tools/linux_types.h
|
||||||
|
new file mode 100644
|
||||||
|
index 000000000000..f07ef8293ebc
|
||||||
--- /dev/null
|
--- /dev/null
|
||||||
+++ b/tools/include/tools/linux_types.h
|
+++ b/tools/include/tools/linux_types.h
|
||||||
@@ -0,0 +1,22 @@
|
@@ -0,0 +1,22 @@
|
||||||
|
@ -49,3 +70,6 @@
|
||||||
+typedef uint64_t __le64;
|
+typedef uint64_t __le64;
|
||||||
+
|
+
|
||||||
+#endif
|
+#endif
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
29
target/linux/generic/hack-4.9/214-spidev_h_portability.patch
Normal file
29
target/linux/generic/hack-4.9/214-spidev_h_portability.patch
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
From be9be95ff10e16a5b4ad36f903978d0cc5747024 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Fri, 7 Jul 2017 17:04:08 +0200
|
||||||
|
Subject: kernel: fix linux/spi/spidev.h portability issues with musl
|
||||||
|
|
||||||
|
Felix will try to get this define included into musl
|
||||||
|
|
||||||
|
lede-commit: 795e7cf60de19e7a076a46874fab7bb88b43bbff
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
---
|
||||||
|
include/uapi/linux/spi/spidev.h | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/include/uapi/linux/spi/spidev.h b/include/uapi/linux/spi/spidev.h
|
||||||
|
index dd5f21e75805..e5e8fea8b068 100644
|
||||||
|
--- a/include/uapi/linux/spi/spidev.h
|
||||||
|
+++ b/include/uapi/linux/spi/spidev.h
|
||||||
|
@@ -111,7 +111,7 @@ struct spi_ioc_transfer {
|
||||||
|
|
||||||
|
/* not all platforms use <asm-generic/ioctl.h> or _IOC_TYPECHECK() ... */
|
||||||
|
#define SPI_MSGSIZE(N) \
|
||||||
|
- ((((N)*(sizeof (struct spi_ioc_transfer))) < (1 << _IOC_SIZEBITS)) \
|
||||||
|
+ ((((N)*(sizeof (struct spi_ioc_transfer))) < (1 << 13)) \
|
||||||
|
? ((N)*(sizeof (struct spi_ioc_transfer))) : 0)
|
||||||
|
#define SPI_IOC_MESSAGE(N) _IOW(SPI_IOC_MAGIC, 0, char[SPI_MSGSIZE(N)])
|
||||||
|
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
|
From e3d8676f5722b7622685581e06e8f53e6138e3ab Mon Sep 17 00:00:00 2001
|
||||||
From: Felix Fietkau <nbd@nbd.name>
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Sat, 15 Jul 2017 23:42:36 +0200
|
||||||
use -ffunction-sections, -fdata-sections and --gc-sections
|
Subject: use -ffunction-sections, -fdata-sections and --gc-sections
|
||||||
|
|
||||||
In combination with kernel symbol export stripping this significantly reduces
|
In combination with kernel symbol export stripping this significantly reduces
|
||||||
the kernel image size. Used on both ARM and MIPS architectures.
|
the kernel image size. Used on both ARM and MIPS architectures.
|
||||||
|
@ -9,7 +10,187 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
Signed-off-by: Jonas Gorski <jogo@openwrt.org>
|
Signed-off-by: Jonas Gorski <jogo@openwrt.org>
|
||||||
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
|
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
|
||||||
---
|
---
|
||||||
|
Makefile | 10 +++----
|
||||||
|
arch/arm/Kconfig | 1 +
|
||||||
|
arch/arm/boot/compressed/Makefile | 1 +
|
||||||
|
arch/arm/kernel/vmlinux.lds.S | 26 ++++++++--------
|
||||||
|
arch/mips/Kconfig | 1 +
|
||||||
|
arch/mips/kernel/vmlinux.lds.S | 4 +--
|
||||||
|
include/asm-generic/vmlinux.lds.h | 63 ++++++++++++++++++++-------------------
|
||||||
|
7 files changed, 55 insertions(+), 51 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/Makefile b/Makefile
|
||||||
|
index 42435dfa5fc3..66cdf6a59b53 100644
|
||||||
|
--- a/Makefile
|
||||||
|
+++ b/Makefile
|
||||||
|
@@ -410,6 +410,11 @@ KBUILD_AFLAGS_MODULE := -DMODULE
|
||||||
|
KBUILD_CFLAGS_MODULE := -DMODULE
|
||||||
|
KBUILD_LDFLAGS_MODULE = -T $(srctree)/scripts/module-common.lds $(if $(CONFIG_PROFILING),,-s)
|
||||||
|
|
||||||
|
+ifdef CONFIG_LD_DEAD_CODE_DATA_ELIMINATION
|
||||||
|
+KBUILD_CFLAGS_KERNEL += $(call cc-option,-ffunction-sections,)
|
||||||
|
+KBUILD_CFLAGS_KERNEL += $(call cc-option,-fdata-sections,)
|
||||||
|
+endif
|
||||||
|
+
|
||||||
|
# Read KERNELRELEASE from include/config/kernel.release (if it exists)
|
||||||
|
KERNELRELEASE = $(shell cat include/config/kernel.release 2> /dev/null)
|
||||||
|
KERNELVERSION = $(VERSION)$(if $(PATCHLEVEL),.$(PATCHLEVEL)$(if $(SUBLEVEL),.$(SUBLEVEL)))$(EXTRAVERSION)
|
||||||
|
@@ -631,11 +636,6 @@ include arch/$(SRCARCH)/Makefile
|
||||||
|
KBUILD_CFLAGS += $(call cc-option,-fno-delete-null-pointer-checks,)
|
||||||
|
KBUILD_CFLAGS += $(call cc-disable-warning,frame-address,)
|
||||||
|
|
||||||
|
-ifdef CONFIG_LD_DEAD_CODE_DATA_ELIMINATION
|
||||||
|
-KBUILD_CFLAGS += $(call cc-option,-ffunction-sections,)
|
||||||
|
-KBUILD_CFLAGS += $(call cc-option,-fdata-sections,)
|
||||||
|
-endif
|
||||||
|
-
|
||||||
|
ifdef CONFIG_CC_OPTIMIZE_FOR_SIZE
|
||||||
|
KBUILD_CFLAGS += -Os $(call cc-disable-warning,maybe-uninitialized,) $(EXTRA_OPTIMIZATION)
|
||||||
|
else
|
||||||
|
diff --git a/arch/arm/Kconfig b/arch/arm/Kconfig
|
||||||
|
index b5d529fdffab..7f69418bf02c 100644
|
||||||
|
--- a/arch/arm/Kconfig
|
||||||
|
+++ b/arch/arm/Kconfig
|
||||||
|
@@ -81,6 +81,7 @@ config ARM
|
||||||
|
select HAVE_UID16
|
||||||
|
select HAVE_VIRT_CPU_ACCOUNTING_GEN
|
||||||
|
select IRQ_FORCED_THREADING
|
||||||
|
+ select LD_DEAD_CODE_DATA_ELIMINATION
|
||||||
|
select MODULES_USE_ELF_REL
|
||||||
|
select NO_BOOTMEM
|
||||||
|
select OF_EARLY_FLATTREE if OF
|
||||||
|
diff --git a/arch/arm/boot/compressed/Makefile b/arch/arm/boot/compressed/Makefile
|
||||||
|
index d50430c40045..6bdeb009a46d 100644
|
||||||
|
--- a/arch/arm/boot/compressed/Makefile
|
||||||
|
+++ b/arch/arm/boot/compressed/Makefile
|
||||||
|
@@ -102,6 +102,7 @@ ifeq ($(CONFIG_FUNCTION_TRACER),y)
|
||||||
|
ORIG_CFLAGS := $(KBUILD_CFLAGS)
|
||||||
|
KBUILD_CFLAGS = $(subst -pg, , $(ORIG_CFLAGS))
|
||||||
|
endif
|
||||||
|
+KBUILD_CFLAGS_KERNEL := $(patsubst -f%-sections,,$(KBUILD_CFLAGS_KERNEL))
|
||||||
|
|
||||||
|
# -fstack-protector-strong triggers protection checks in this code,
|
||||||
|
# but it is being used too early to link to meaningful stack_chk logic.
|
||||||
|
diff --git a/arch/arm/kernel/vmlinux.lds.S b/arch/arm/kernel/vmlinux.lds.S
|
||||||
|
index f7f55df0bf7b..e9d70c92d99f 100644
|
||||||
|
--- a/arch/arm/kernel/vmlinux.lds.S
|
||||||
|
+++ b/arch/arm/kernel/vmlinux.lds.S
|
||||||
|
@@ -17,7 +17,7 @@
|
||||||
|
#define PROC_INFO \
|
||||||
|
. = ALIGN(4); \
|
||||||
|
VMLINUX_SYMBOL(__proc_info_begin) = .; \
|
||||||
|
- *(.proc.info.init) \
|
||||||
|
+ KEEP(*(.proc.info.init)) \
|
||||||
|
VMLINUX_SYMBOL(__proc_info_end) = .;
|
||||||
|
|
||||||
|
#define HYPERVISOR_TEXT \
|
||||||
|
@@ -28,11 +28,11 @@
|
||||||
|
#define IDMAP_TEXT \
|
||||||
|
ALIGN_FUNCTION(); \
|
||||||
|
VMLINUX_SYMBOL(__idmap_text_start) = .; \
|
||||||
|
- *(.idmap.text) \
|
||||||
|
+ KEEP(*(.idmap.text)) \
|
||||||
|
VMLINUX_SYMBOL(__idmap_text_end) = .; \
|
||||||
|
. = ALIGN(PAGE_SIZE); \
|
||||||
|
VMLINUX_SYMBOL(__hyp_idmap_text_start) = .; \
|
||||||
|
- *(.hyp.idmap.text) \
|
||||||
|
+ KEEP(*(.hyp.idmap.text)) \
|
||||||
|
VMLINUX_SYMBOL(__hyp_idmap_text_end) = .;
|
||||||
|
|
||||||
|
#ifdef CONFIG_HOTPLUG_CPU
|
||||||
|
@@ -105,7 +105,7 @@ SECTIONS
|
||||||
|
_stext = .; /* Text and read-only data */
|
||||||
|
IDMAP_TEXT
|
||||||
|
__exception_text_start = .;
|
||||||
|
- *(.exception.text)
|
||||||
|
+ KEEP(*(.exception.text))
|
||||||
|
__exception_text_end = .;
|
||||||
|
IRQENTRY_TEXT
|
||||||
|
SOFTIRQENTRY_TEXT
|
||||||
|
@@ -134,7 +134,7 @@ SECTIONS
|
||||||
|
__ex_table : AT(ADDR(__ex_table) - LOAD_OFFSET) {
|
||||||
|
__start___ex_table = .;
|
||||||
|
#ifdef CONFIG_MMU
|
||||||
|
- *(__ex_table)
|
||||||
|
+ KEEP(*(__ex_table))
|
||||||
|
#endif
|
||||||
|
__stop___ex_table = .;
|
||||||
|
}
|
||||||
|
@@ -146,12 +146,12 @@ SECTIONS
|
||||||
|
. = ALIGN(8);
|
||||||
|
.ARM.unwind_idx : {
|
||||||
|
__start_unwind_idx = .;
|
||||||
|
- *(.ARM.exidx*)
|
||||||
|
+ KEEP(*(.ARM.exidx*))
|
||||||
|
__stop_unwind_idx = .;
|
||||||
|
}
|
||||||
|
.ARM.unwind_tab : {
|
||||||
|
__start_unwind_tab = .;
|
||||||
|
- *(.ARM.extab*)
|
||||||
|
+ KEEP(*(.ARM.extab*))
|
||||||
|
__stop_unwind_tab = .;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
@@ -171,14 +171,14 @@ SECTIONS
|
||||||
|
*/
|
||||||
|
__vectors_start = .;
|
||||||
|
.vectors 0xffff0000 : AT(__vectors_start) {
|
||||||
|
- *(.vectors)
|
||||||
|
+ KEEP(*(.vectors))
|
||||||
|
}
|
||||||
|
. = __vectors_start + SIZEOF(.vectors);
|
||||||
|
__vectors_end = .;
|
||||||
|
|
||||||
|
__stubs_start = .;
|
||||||
|
.stubs ADDR(.vectors) + 0x1000 : AT(__stubs_start) {
|
||||||
|
- *(.stubs)
|
||||||
|
+ KEEP(*(.stubs))
|
||||||
|
}
|
||||||
|
. = __stubs_start + SIZEOF(.stubs);
|
||||||
|
__stubs_end = .;
|
||||||
|
@@ -194,24 +194,24 @@ SECTIONS
|
||||||
|
}
|
||||||
|
.init.arch.info : {
|
||||||
|
__arch_info_begin = .;
|
||||||
|
- *(.arch.info.init)
|
||||||
|
+ KEEP(*(.arch.info.init))
|
||||||
|
__arch_info_end = .;
|
||||||
|
}
|
||||||
|
.init.tagtable : {
|
||||||
|
__tagtable_begin = .;
|
||||||
|
- *(.taglist.init)
|
||||||
|
+ KEEP(*(.taglist.init))
|
||||||
|
__tagtable_end = .;
|
||||||
|
}
|
||||||
|
#ifdef CONFIG_SMP_ON_UP
|
||||||
|
.init.smpalt : {
|
||||||
|
__smpalt_begin = .;
|
||||||
|
- *(.alt.smp.init)
|
||||||
|
+ KEEP(*(.alt.smp.init))
|
||||||
|
__smpalt_end = .;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
.init.pv_table : {
|
||||||
|
__pv_table_begin = .;
|
||||||
|
- *(.pv_table)
|
||||||
|
+ KEEP(*(.pv_table))
|
||||||
|
__pv_table_end = .;
|
||||||
|
}
|
||||||
|
.init.data : {
|
||||||
|
diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
|
||||||
|
index 3a97487b8b81..05e7bfeab2f9 100644
|
||||||
|
--- a/arch/mips/Kconfig
|
||||||
|
+++ b/arch/mips/Kconfig
|
||||||
|
@@ -55,6 +55,7 @@ config MIPS
|
||||||
|
select CLONE_BACKWARDS
|
||||||
|
select HAVE_DEBUG_STACKOVERFLOW
|
||||||
|
select HAVE_CC_STACKPROTECTOR
|
||||||
|
+ select LD_DEAD_CODE_DATA_ELIMINATION
|
||||||
|
select CPU_PM if CPU_IDLE
|
||||||
|
select ARCH_HAS_TICK_BROADCAST if GENERIC_CLOCKEVENTS_BROADCAST
|
||||||
|
select ARCH_BINFMT_ELF_STATE
|
||||||
|
diff --git a/arch/mips/kernel/vmlinux.lds.S b/arch/mips/kernel/vmlinux.lds.S
|
||||||
|
index d5de67591735..de5f682b5597 100644
|
||||||
--- a/arch/mips/kernel/vmlinux.lds.S
|
--- a/arch/mips/kernel/vmlinux.lds.S
|
||||||
+++ b/arch/mips/kernel/vmlinux.lds.S
|
+++ b/arch/mips/kernel/vmlinux.lds.S
|
||||||
@@ -71,7 +71,7 @@ SECTIONS
|
@@ -71,7 +71,7 @@ SECTIONS
|
||||||
|
@ -30,6 +211,8 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
|
||||||
__mips_machines_end = .;
|
__mips_machines_end = .;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
diff --git a/include/asm-generic/vmlinux.lds.h b/include/asm-generic/vmlinux.lds.h
|
||||||
|
index 31e1d639abed..83784d9492b1 100644
|
||||||
--- a/include/asm-generic/vmlinux.lds.h
|
--- a/include/asm-generic/vmlinux.lds.h
|
||||||
+++ b/include/asm-generic/vmlinux.lds.h
|
+++ b/include/asm-generic/vmlinux.lds.h
|
||||||
@@ -114,7 +114,7 @@
|
@@ -114,7 +114,7 @@
|
||||||
|
@ -250,163 +433,6 @@ Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
|
||||||
VMLINUX_SYMBOL(__setup_end) = .;
|
VMLINUX_SYMBOL(__setup_end) = .;
|
||||||
|
|
||||||
#define INIT_CALLS_LEVEL(level) \
|
#define INIT_CALLS_LEVEL(level) \
|
||||||
--- a/arch/arm/kernel/vmlinux.lds.S
|
--
|
||||||
+++ b/arch/arm/kernel/vmlinux.lds.S
|
2.11.0
|
||||||
@@ -17,7 +17,7 @@
|
|
||||||
#define PROC_INFO \
|
|
||||||
. = ALIGN(4); \
|
|
||||||
VMLINUX_SYMBOL(__proc_info_begin) = .; \
|
|
||||||
- *(.proc.info.init) \
|
|
||||||
+ KEEP(*(.proc.info.init)) \
|
|
||||||
VMLINUX_SYMBOL(__proc_info_end) = .;
|
|
||||||
|
|
||||||
#define HYPERVISOR_TEXT \
|
|
||||||
@@ -28,11 +28,11 @@
|
|
||||||
#define IDMAP_TEXT \
|
|
||||||
ALIGN_FUNCTION(); \
|
|
||||||
VMLINUX_SYMBOL(__idmap_text_start) = .; \
|
|
||||||
- *(.idmap.text) \
|
|
||||||
+ KEEP(*(.idmap.text)) \
|
|
||||||
VMLINUX_SYMBOL(__idmap_text_end) = .; \
|
|
||||||
. = ALIGN(PAGE_SIZE); \
|
|
||||||
VMLINUX_SYMBOL(__hyp_idmap_text_start) = .; \
|
|
||||||
- *(.hyp.idmap.text) \
|
|
||||||
+ KEEP(*(.hyp.idmap.text)) \
|
|
||||||
VMLINUX_SYMBOL(__hyp_idmap_text_end) = .;
|
|
||||||
|
|
||||||
#ifdef CONFIG_HOTPLUG_CPU
|
|
||||||
@@ -105,7 +105,7 @@ SECTIONS
|
|
||||||
_stext = .; /* Text and read-only data */
|
|
||||||
IDMAP_TEXT
|
|
||||||
__exception_text_start = .;
|
|
||||||
- *(.exception.text)
|
|
||||||
+ KEEP(*(.exception.text))
|
|
||||||
__exception_text_end = .;
|
|
||||||
IRQENTRY_TEXT
|
|
||||||
SOFTIRQENTRY_TEXT
|
|
||||||
@@ -134,7 +134,7 @@ SECTIONS
|
|
||||||
__ex_table : AT(ADDR(__ex_table) - LOAD_OFFSET) {
|
|
||||||
__start___ex_table = .;
|
|
||||||
#ifdef CONFIG_MMU
|
|
||||||
- *(__ex_table)
|
|
||||||
+ KEEP(*(__ex_table))
|
|
||||||
#endif
|
|
||||||
__stop___ex_table = .;
|
|
||||||
}
|
|
||||||
@@ -146,12 +146,12 @@ SECTIONS
|
|
||||||
. = ALIGN(8);
|
|
||||||
.ARM.unwind_idx : {
|
|
||||||
__start_unwind_idx = .;
|
|
||||||
- *(.ARM.exidx*)
|
|
||||||
+ KEEP(*(.ARM.exidx*))
|
|
||||||
__stop_unwind_idx = .;
|
|
||||||
}
|
|
||||||
.ARM.unwind_tab : {
|
|
||||||
__start_unwind_tab = .;
|
|
||||||
- *(.ARM.extab*)
|
|
||||||
+ KEEP(*(.ARM.extab*))
|
|
||||||
__stop_unwind_tab = .;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
@@ -171,14 +171,14 @@ SECTIONS
|
|
||||||
*/
|
|
||||||
__vectors_start = .;
|
|
||||||
.vectors 0xffff0000 : AT(__vectors_start) {
|
|
||||||
- *(.vectors)
|
|
||||||
+ KEEP(*(.vectors))
|
|
||||||
}
|
|
||||||
. = __vectors_start + SIZEOF(.vectors);
|
|
||||||
__vectors_end = .;
|
|
||||||
|
|
||||||
__stubs_start = .;
|
|
||||||
.stubs ADDR(.vectors) + 0x1000 : AT(__stubs_start) {
|
|
||||||
- *(.stubs)
|
|
||||||
+ KEEP(*(.stubs))
|
|
||||||
}
|
|
||||||
. = __stubs_start + SIZEOF(.stubs);
|
|
||||||
__stubs_end = .;
|
|
||||||
@@ -194,24 +194,24 @@ SECTIONS
|
|
||||||
}
|
|
||||||
.init.arch.info : {
|
|
||||||
__arch_info_begin = .;
|
|
||||||
- *(.arch.info.init)
|
|
||||||
+ KEEP(*(.arch.info.init))
|
|
||||||
__arch_info_end = .;
|
|
||||||
}
|
|
||||||
.init.tagtable : {
|
|
||||||
__tagtable_begin = .;
|
|
||||||
- *(.taglist.init)
|
|
||||||
+ KEEP(*(.taglist.init))
|
|
||||||
__tagtable_end = .;
|
|
||||||
}
|
|
||||||
#ifdef CONFIG_SMP_ON_UP
|
|
||||||
.init.smpalt : {
|
|
||||||
__smpalt_begin = .;
|
|
||||||
- *(.alt.smp.init)
|
|
||||||
+ KEEP(*(.alt.smp.init))
|
|
||||||
__smpalt_end = .;
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
.init.pv_table : {
|
|
||||||
__pv_table_begin = .;
|
|
||||||
- *(.pv_table)
|
|
||||||
+ KEEP(*(.pv_table))
|
|
||||||
__pv_table_end = .;
|
|
||||||
}
|
|
||||||
.init.data : {
|
|
||||||
--- a/arch/arm/boot/compressed/Makefile
|
|
||||||
+++ b/arch/arm/boot/compressed/Makefile
|
|
||||||
@@ -102,6 +102,7 @@ ifeq ($(CONFIG_FUNCTION_TRACER),y)
|
|
||||||
ORIG_CFLAGS := $(KBUILD_CFLAGS)
|
|
||||||
KBUILD_CFLAGS = $(subst -pg, , $(ORIG_CFLAGS))
|
|
||||||
endif
|
|
||||||
+KBUILD_CFLAGS_KERNEL := $(patsubst -f%-sections,,$(KBUILD_CFLAGS_KERNEL))
|
|
||||||
|
|
||||||
# -fstack-protector-strong triggers protection checks in this code,
|
|
||||||
# but it is being used too early to link to meaningful stack_chk logic.
|
|
||||||
--- a/arch/arm/Kconfig
|
|
||||||
+++ b/arch/arm/Kconfig
|
|
||||||
@@ -81,6 +81,7 @@ config ARM
|
|
||||||
select HAVE_UID16
|
|
||||||
select HAVE_VIRT_CPU_ACCOUNTING_GEN
|
|
||||||
select IRQ_FORCED_THREADING
|
|
||||||
+ select LD_DEAD_CODE_DATA_ELIMINATION
|
|
||||||
select MODULES_USE_ELF_REL
|
|
||||||
select NO_BOOTMEM
|
|
||||||
select OF_EARLY_FLATTREE if OF
|
|
||||||
--- a/arch/mips/Kconfig
|
|
||||||
+++ b/arch/mips/Kconfig
|
|
||||||
@@ -55,6 +55,7 @@ config MIPS
|
|
||||||
select CLONE_BACKWARDS
|
|
||||||
select HAVE_DEBUG_STACKOVERFLOW
|
|
||||||
select HAVE_CC_STACKPROTECTOR
|
|
||||||
+ select LD_DEAD_CODE_DATA_ELIMINATION
|
|
||||||
select CPU_PM if CPU_IDLE
|
|
||||||
select ARCH_HAS_TICK_BROADCAST if GENERIC_CLOCKEVENTS_BROADCAST
|
|
||||||
select ARCH_BINFMT_ELF_STATE
|
|
||||||
--- a/Makefile
|
|
||||||
+++ b/Makefile
|
|
||||||
@@ -409,6 +409,11 @@ KBUILD_AFLAGS_MODULE := -DMODULE
|
|
||||||
KBUILD_CFLAGS_MODULE := -DMODULE
|
|
||||||
KBUILD_LDFLAGS_MODULE = -T $(srctree)/scripts/module-common.lds $(if $(CONFIG_PROFILING),,-s)
|
|
||||||
|
|
||||||
+ifdef CONFIG_LD_DEAD_CODE_DATA_ELIMINATION
|
|
||||||
+KBUILD_CFLAGS_KERNEL += $(call cc-option,-ffunction-sections,)
|
|
||||||
+KBUILD_CFLAGS_KERNEL += $(call cc-option,-fdata-sections,)
|
|
||||||
+endif
|
|
||||||
+
|
|
||||||
# Read KERNELRELEASE from include/config/kernel.release (if it exists)
|
|
||||||
KERNELRELEASE = $(shell cat include/config/kernel.release 2> /dev/null)
|
|
||||||
KERNELVERSION = $(VERSION)$(if $(PATCHLEVEL),.$(PATCHLEVEL)$(if $(SUBLEVEL),.$(SUBLEVEL)))$(EXTRAVERSION)
|
|
||||||
@@ -633,11 +638,6 @@ KBUILD_CFLAGS += $(call cc-disable-warni
|
|
||||||
KBUILD_CFLAGS += $(call cc-disable-warning, format-overflow)
|
|
||||||
KBUILD_CFLAGS += $(call cc-disable-warning, int-in-bool-context)
|
|
||||||
|
|
||||||
-ifdef CONFIG_LD_DEAD_CODE_DATA_ELIMINATION
|
|
||||||
-KBUILD_CFLAGS += $(call cc-option,-ffunction-sections,)
|
|
||||||
-KBUILD_CFLAGS += $(call cc-option,-fdata-sections,)
|
|
||||||
-endif
|
|
||||||
-
|
|
||||||
ifdef CONFIG_CC_OPTIMIZE_FOR_SIZE
|
|
||||||
KBUILD_CFLAGS += -Os $(call cc-disable-warning,maybe-uninitialized,) $(EXTRA_OPTIMIZATION)
|
|
||||||
else
|
|
|
@ -1,3 +1,18 @@
|
||||||
|
From b14784e7883390c20ed3ff904892255404a5914b Mon Sep 17 00:00:00 2001
|
||||||
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Fri, 7 Jul 2017 17:05:53 +0200
|
||||||
|
Subject: add an optional config option for stripping all unnecessary symbol exports from the kernel image
|
||||||
|
|
||||||
|
lede-commit: bb5a40c64b7c4f4848509fa0a6625055fc9e66cc
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
---
|
||||||
|
include/asm-generic/vmlinux.lds.h | 18 +++++++++++++++---
|
||||||
|
include/linux/export.h | 9 ++++++++-
|
||||||
|
scripts/Makefile.build | 2 +-
|
||||||
|
3 files changed, 24 insertions(+), 5 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/include/asm-generic/vmlinux.lds.h b/include/asm-generic/vmlinux.lds.h
|
||||||
|
index 83784d9492b1..189b5c7a0758 100644
|
||||||
--- a/include/asm-generic/vmlinux.lds.h
|
--- a/include/asm-generic/vmlinux.lds.h
|
||||||
+++ b/include/asm-generic/vmlinux.lds.h
|
+++ b/include/asm-generic/vmlinux.lds.h
|
||||||
@@ -54,6 +54,16 @@
|
@@ -54,6 +54,16 @@
|
||||||
|
@ -52,17 +67,8 @@
|
||||||
*(.discard) \
|
*(.discard) \
|
||||||
*(.discard.*) \
|
*(.discard.*) \
|
||||||
}
|
}
|
||||||
--- a/scripts/Makefile.build
|
diff --git a/include/linux/export.h b/include/linux/export.h
|
||||||
+++ b/scripts/Makefile.build
|
index 2a0f61fbc731..889331d9643d 100644
|
||||||
@@ -398,7 +398,7 @@ targets += $(extra-y) $(MAKECMDGOALS) $(
|
|
||||||
# Linker scripts preprocessor (.lds.S -> .lds)
|
|
||||||
# ---------------------------------------------------------------------------
|
|
||||||
quiet_cmd_cpp_lds_S = LDS $@
|
|
||||||
- cmd_cpp_lds_S = $(CPP) $(cpp_flags) -P -C -U$(ARCH) \
|
|
||||||
+ cmd_cpp_lds_S = $(CPP) $(EXTRA_LDSFLAGS) $(cpp_flags) -P -C -U$(ARCH) \
|
|
||||||
-D__ASSEMBLY__ -DLINKER_SCRIPT -o $@ $<
|
|
||||||
|
|
||||||
$(obj)/%.lds: $(src)/%.lds.S FORCE
|
|
||||||
--- a/include/linux/export.h
|
--- a/include/linux/export.h
|
||||||
+++ b/include/linux/export.h
|
+++ b/include/linux/export.h
|
||||||
@@ -53,12 +53,19 @@ extern struct module __this_module;
|
@@ -53,12 +53,19 @@ extern struct module __this_module;
|
||||||
|
@ -86,3 +92,19 @@
|
||||||
= VMLINUX_SYMBOL_STR(sym); \
|
= VMLINUX_SYMBOL_STR(sym); \
|
||||||
static const struct kernel_symbol __ksymtab_##sym \
|
static const struct kernel_symbol __ksymtab_##sym \
|
||||||
__used \
|
__used \
|
||||||
|
diff --git a/scripts/Makefile.build b/scripts/Makefile.build
|
||||||
|
index 108d73273788..76a0e450123c 100644
|
||||||
|
--- a/scripts/Makefile.build
|
||||||
|
+++ b/scripts/Makefile.build
|
||||||
|
@@ -398,7 +398,7 @@ targets += $(extra-y) $(MAKECMDGOALS) $(always)
|
||||||
|
# Linker scripts preprocessor (.lds.S -> .lds)
|
||||||
|
# ---------------------------------------------------------------------------
|
||||||
|
quiet_cmd_cpp_lds_S = LDS $@
|
||||||
|
- cmd_cpp_lds_S = $(CPP) $(cpp_flags) -P -C -U$(ARCH) \
|
||||||
|
+ cmd_cpp_lds_S = $(CPP) $(EXTRA_LDSFLAGS) $(cpp_flags) -P -C -U$(ARCH) \
|
||||||
|
-D__ASSEMBLY__ -DLINKER_SCRIPT -o $@ $<
|
||||||
|
|
||||||
|
$(obj)/%.lds: $(src)/%.lds.S FORCE
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,6 +1,33 @@
|
||||||
|
From b3d00b452467f621317953d9e4c6f9ae8dcfd271 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Imre Kaloz <kaloz@openwrt.org>
|
||||||
|
Date: Fri, 7 Jul 2017 17:06:55 +0200
|
||||||
|
Subject: use the openwrt lzma options for now
|
||||||
|
|
||||||
|
lede-commit: 548de949f392049420a6a1feeef118b30ab8ea8c
|
||||||
|
Signed-off-by: Imre Kaloz <kaloz@openwrt.org>
|
||||||
|
---
|
||||||
|
lib/decompress.c | 1 +
|
||||||
|
scripts/Makefile.lib | 2 +-
|
||||||
|
scripts/gen_initramfs_list.sh | 10 +++++-----
|
||||||
|
3 files changed, 7 insertions(+), 6 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/lib/decompress.c b/lib/decompress.c
|
||||||
|
index 62696dff5730..d91a26e1a1b2 100644
|
||||||
|
--- a/lib/decompress.c
|
||||||
|
+++ b/lib/decompress.c
|
||||||
|
@@ -48,6 +48,7 @@ static const struct compress_format compressed_formats[] __initconst = {
|
||||||
|
{ {0x1f, 0x9e}, "gzip", gunzip },
|
||||||
|
{ {0x42, 0x5a}, "bzip2", bunzip2 },
|
||||||
|
{ {0x5d, 0x00}, "lzma", unlzma },
|
||||||
|
+ { {0x6d, 0x00}, "lzma-openwrt", unlzma },
|
||||||
|
{ {0xfd, 0x37}, "xz", unxz },
|
||||||
|
{ {0x89, 0x4c}, "lzo", unlzo },
|
||||||
|
{ {0x02, 0x21}, "lz4", unlz4 },
|
||||||
|
diff --git a/scripts/Makefile.lib b/scripts/Makefile.lib
|
||||||
|
index 0a07f9014944..5324c072c598 100644
|
||||||
--- a/scripts/Makefile.lib
|
--- a/scripts/Makefile.lib
|
||||||
+++ b/scripts/Makefile.lib
|
+++ b/scripts/Makefile.lib
|
||||||
@@ -344,7 +344,7 @@ cmd_bzip2 = (cat $(filter-out FORCE,$^)
|
@@ -344,7 +344,7 @@ cmd_bzip2 = (cat $(filter-out FORCE,$^) | \
|
||||||
|
|
||||||
quiet_cmd_lzma = LZMA $@
|
quiet_cmd_lzma = LZMA $@
|
||||||
cmd_lzma = (cat $(filter-out FORCE,$^) | \
|
cmd_lzma = (cat $(filter-out FORCE,$^) | \
|
||||||
|
@ -9,6 +36,8 @@
|
||||||
(rm -f $@ ; false)
|
(rm -f $@ ; false)
|
||||||
|
|
||||||
quiet_cmd_lzo = LZO $@
|
quiet_cmd_lzo = LZO $@
|
||||||
|
diff --git a/scripts/gen_initramfs_list.sh b/scripts/gen_initramfs_list.sh
|
||||||
|
index 0055b07b03b6..7710113e6a72 100755
|
||||||
--- a/scripts/gen_initramfs_list.sh
|
--- a/scripts/gen_initramfs_list.sh
|
||||||
+++ b/scripts/gen_initramfs_list.sh
|
+++ b/scripts/gen_initramfs_list.sh
|
||||||
@@ -229,7 +229,7 @@ cpio_list=
|
@@ -229,7 +229,7 @@ cpio_list=
|
||||||
|
@ -46,13 +75,6 @@
|
||||||
|| (rm -f ${output_file} ; false)
|
|| (rm -f ${output_file} ; false)
|
||||||
fi
|
fi
|
||||||
[ -z ${cpio_file} ] && rm ${cpio_tfile}
|
[ -z ${cpio_file} ] && rm ${cpio_tfile}
|
||||||
--- a/lib/decompress.c
|
--
|
||||||
+++ b/lib/decompress.c
|
2.11.0
|
||||||
@@ -48,6 +48,7 @@ static const struct compress_format comp
|
|
||||||
{ {0x1f, 0x9e}, "gzip", gunzip },
|
|
||||||
{ {0x42, 0x5a}, "bzip2", bunzip2 },
|
|
||||||
{ {0x5d, 0x00}, "lzma", unlzma },
|
|
||||||
+ { {0x6d, 0x00}, "lzma-openwrt", unlzma },
|
|
||||||
{ {0xfd, 0x37}, "xz", unxz },
|
|
||||||
{ {0x89, 0x4c}, "lzo", unlzo },
|
|
||||||
{ {0x02, 0x21}, "lz4", unlz4 },
|
|
|
@ -1,3 +1,14 @@
|
||||||
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Subject: hack: net: remove bogus netfilter dependencies
|
||||||
|
|
||||||
|
lede-commit: 589d2a377dee27d206fc3725325309cf649e4df6
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
---
|
||||||
|
net/netfilter/Kconfig | 2 --
|
||||||
|
1 file changed, 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/net/netfilter/Kconfig b/net/netfilter/Kconfig
|
||||||
|
index 82af5ba64088..65fe84db77ec 100644
|
||||||
--- a/net/netfilter/Kconfig
|
--- a/net/netfilter/Kconfig
|
||||||
+++ b/net/netfilter/Kconfig
|
+++ b/net/netfilter/Kconfig
|
||||||
@@ -218,7 +218,6 @@ config NF_CONNTRACK_FTP
|
@@ -218,7 +218,6 @@ config NF_CONNTRACK_FTP
|
||||||
|
@ -16,3 +27,6 @@
|
||||||
default m if NETFILTER_ADVANCED=n
|
default m if NETFILTER_ADVANCED=n
|
||||||
---help---
|
---help---
|
||||||
This option adds a `TCPMSS' target, which allows you to alter the
|
This option adds a `TCPMSS' target, which allows you to alter the
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
212
target/linux/generic/hack-4.9/251-sound_kconfig.patch
Normal file
212
target/linux/generic/hack-4.9/251-sound_kconfig.patch
Normal file
|
@ -0,0 +1,212 @@
|
||||||
|
From da3c50704f14132f4adf80d48e9a4cd5d46e54c9 Mon Sep 17 00:00:00 2001
|
||||||
|
From: John Crispin <john@phrozen.org>
|
||||||
|
Date: Fri, 7 Jul 2017 17:09:21 +0200
|
||||||
|
Subject: kconfig: owrt specifc dependencies
|
||||||
|
|
||||||
|
Signed-off-by: John Crispin <john@phrozen.org>
|
||||||
|
---
|
||||||
|
crypto/Kconfig | 10 +++++-----
|
||||||
|
drivers/bcma/Kconfig | 1 +
|
||||||
|
drivers/ssb/Kconfig | 3 ++-
|
||||||
|
lib/Kconfig | 8 ++++----
|
||||||
|
net/netfilter/Kconfig | 2 +-
|
||||||
|
net/wireless/Kconfig | 17 ++++++++++-------
|
||||||
|
sound/core/Kconfig | 4 ++--
|
||||||
|
7 files changed, 25 insertions(+), 20 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/crypto/Kconfig b/crypto/Kconfig
|
||||||
|
index 84d71482bf08..e3552d1c1b84 100644
|
||||||
|
--- a/crypto/Kconfig
|
||||||
|
+++ b/crypto/Kconfig
|
||||||
|
@@ -32,7 +32,7 @@ config CRYPTO_FIPS
|
||||||
|
this is.
|
||||||
|
|
||||||
|
config CRYPTO_ALGAPI
|
||||||
|
- tristate
|
||||||
|
+ tristate "ALGAPI"
|
||||||
|
select CRYPTO_ALGAPI2
|
||||||
|
help
|
||||||
|
This option provides the API for cryptographic algorithms.
|
||||||
|
@@ -41,7 +41,7 @@ config CRYPTO_ALGAPI2
|
||||||
|
tristate
|
||||||
|
|
||||||
|
config CRYPTO_AEAD
|
||||||
|
- tristate
|
||||||
|
+ tristate "AEAD"
|
||||||
|
select CRYPTO_AEAD2
|
||||||
|
select CRYPTO_ALGAPI
|
||||||
|
|
||||||
|
@@ -52,7 +52,7 @@ config CRYPTO_AEAD2
|
||||||
|
select CRYPTO_RNG2
|
||||||
|
|
||||||
|
config CRYPTO_BLKCIPHER
|
||||||
|
- tristate
|
||||||
|
+ tristate "BLKCIPHER"
|
||||||
|
select CRYPTO_BLKCIPHER2
|
||||||
|
select CRYPTO_ALGAPI
|
||||||
|
|
||||||
|
@@ -63,7 +63,7 @@ config CRYPTO_BLKCIPHER2
|
||||||
|
select CRYPTO_WORKQUEUE
|
||||||
|
|
||||||
|
config CRYPTO_HASH
|
||||||
|
- tristate
|
||||||
|
+ tristate "HASH"
|
||||||
|
select CRYPTO_HASH2
|
||||||
|
select CRYPTO_ALGAPI
|
||||||
|
|
||||||
|
@@ -72,7 +72,7 @@ config CRYPTO_HASH2
|
||||||
|
select CRYPTO_ALGAPI2
|
||||||
|
|
||||||
|
config CRYPTO_RNG
|
||||||
|
- tristate
|
||||||
|
+ tristate "RNG"
|
||||||
|
select CRYPTO_RNG2
|
||||||
|
select CRYPTO_ALGAPI
|
||||||
|
|
||||||
|
diff --git a/drivers/bcma/Kconfig b/drivers/bcma/Kconfig
|
||||||
|
index b5c48a8d485f..6cb52081b9ef 100644
|
||||||
|
--- a/drivers/bcma/Kconfig
|
||||||
|
+++ b/drivers/bcma/Kconfig
|
||||||
|
@@ -17,6 +17,7 @@ config BCMA
|
||||||
|
config BCMA_BLOCKIO
|
||||||
|
bool
|
||||||
|
depends on BCMA
|
||||||
|
+ default y
|
||||||
|
|
||||||
|
config BCMA_HOST_PCI_POSSIBLE
|
||||||
|
bool
|
||||||
|
diff --git a/drivers/ssb/Kconfig b/drivers/ssb/Kconfig
|
||||||
|
index d8e4219c2324..a20c168cb7c2 100644
|
||||||
|
--- a/drivers/ssb/Kconfig
|
||||||
|
+++ b/drivers/ssb/Kconfig
|
||||||
|
@@ -29,6 +29,7 @@ config SSB_SPROM
|
||||||
|
config SSB_BLOCKIO
|
||||||
|
bool
|
||||||
|
depends on SSB
|
||||||
|
+ default y
|
||||||
|
|
||||||
|
config SSB_PCIHOST_POSSIBLE
|
||||||
|
bool
|
||||||
|
@@ -49,7 +50,7 @@ config SSB_PCIHOST
|
||||||
|
config SSB_B43_PCI_BRIDGE
|
||||||
|
bool
|
||||||
|
depends on SSB_PCIHOST
|
||||||
|
- default n
|
||||||
|
+ default y
|
||||||
|
|
||||||
|
config SSB_PCMCIAHOST_POSSIBLE
|
||||||
|
bool
|
||||||
|
diff --git a/lib/Kconfig b/lib/Kconfig
|
||||||
|
index 260a80e313b9..d1b788fff727 100644
|
||||||
|
--- a/lib/Kconfig
|
||||||
|
+++ b/lib/Kconfig
|
||||||
|
@@ -334,16 +334,16 @@ config BCH_CONST_T
|
||||||
|
# Textsearch support is select'ed if needed
|
||||||
|
#
|
||||||
|
config TEXTSEARCH
|
||||||
|
- bool
|
||||||
|
+ boolean "Textsearch support"
|
||||||
|
|
||||||
|
config TEXTSEARCH_KMP
|
||||||
|
- tristate
|
||||||
|
+ tristate "Textsearch KMP"
|
||||||
|
|
||||||
|
config TEXTSEARCH_BM
|
||||||
|
- tristate
|
||||||
|
+ tristate "Textsearch BM"
|
||||||
|
|
||||||
|
config TEXTSEARCH_FSM
|
||||||
|
- tristate
|
||||||
|
+ tristate "Textsearch FSM"
|
||||||
|
|
||||||
|
config BTREE
|
||||||
|
bool
|
||||||
|
diff --git a/net/netfilter/Kconfig b/net/netfilter/Kconfig
|
||||||
|
index e8d56d9a4df2..0fb924661988 100644
|
||||||
|
--- a/net/netfilter/Kconfig
|
||||||
|
+++ b/net/netfilter/Kconfig
|
||||||
|
@@ -10,7 +10,7 @@ config NETFILTER_INGRESS
|
||||||
|
infrastructure.
|
||||||
|
|
||||||
|
config NETFILTER_NETLINK
|
||||||
|
- tristate
|
||||||
|
+ tristate "Netfilter NFNETLINK interface"
|
||||||
|
|
||||||
|
config NETFILTER_NETLINK_ACCT
|
||||||
|
tristate "Netfilter NFACCT over NFNETLINK interface"
|
||||||
|
diff --git a/net/wireless/Kconfig b/net/wireless/Kconfig
|
||||||
|
index 6c606120abfe..bd299de9440c 100644
|
||||||
|
--- a/net/wireless/Kconfig
|
||||||
|
+++ b/net/wireless/Kconfig
|
||||||
|
@@ -1,5 +1,5 @@
|
||||||
|
config WIRELESS_EXT
|
||||||
|
- bool
|
||||||
|
+ bool "Wireless extensions"
|
||||||
|
|
||||||
|
config WEXT_CORE
|
||||||
|
def_bool y
|
||||||
|
@@ -11,10 +11,10 @@ config WEXT_PROC
|
||||||
|
depends on WEXT_CORE
|
||||||
|
|
||||||
|
config WEXT_SPY
|
||||||
|
- bool
|
||||||
|
+ bool "WEXT_SPY"
|
||||||
|
|
||||||
|
config WEXT_PRIV
|
||||||
|
- bool
|
||||||
|
+ bool "WEXT_PRIV"
|
||||||
|
|
||||||
|
config CFG80211
|
||||||
|
tristate "cfg80211 - wireless configuration API"
|
||||||
|
@@ -188,7 +188,7 @@ config CFG80211_WEXT_EXPORT
|
||||||
|
wext compatibility symbols to be exported.
|
||||||
|
|
||||||
|
config LIB80211
|
||||||
|
- tristate
|
||||||
|
+ tristate "LIB80211"
|
||||||
|
default n
|
||||||
|
help
|
||||||
|
This options enables a library of common routines used
|
||||||
|
@@ -197,13 +197,16 @@ config LIB80211
|
||||||
|
Drivers should select this themselves if needed.
|
||||||
|
|
||||||
|
config LIB80211_CRYPT_WEP
|
||||||
|
- tristate
|
||||||
|
+ tristate "LIB80211_CRYPT_WEP"
|
||||||
|
+ select LIB80211
|
||||||
|
|
||||||
|
config LIB80211_CRYPT_CCMP
|
||||||
|
- tristate
|
||||||
|
+ tristate "LIB80211_CRYPT_CCMP"
|
||||||
|
+ select LIB80211
|
||||||
|
|
||||||
|
config LIB80211_CRYPT_TKIP
|
||||||
|
- tristate
|
||||||
|
+ tristate "LIB80211_CRYPT_TKIP"
|
||||||
|
+ select LIB80211
|
||||||
|
|
||||||
|
config LIB80211_DEBUG
|
||||||
|
bool "lib80211 debugging messages"
|
||||||
|
diff --git a/sound/core/Kconfig b/sound/core/Kconfig
|
||||||
|
index 9749f9e8b45c..9639a67e7e9b 100644
|
||||||
|
--- a/sound/core/Kconfig
|
||||||
|
+++ b/sound/core/Kconfig
|
||||||
|
@@ -16,13 +16,13 @@ config SND_DMAENGINE_PCM
|
||||||
|
tristate
|
||||||
|
|
||||||
|
config SND_HWDEP
|
||||||
|
- tristate
|
||||||
|
+ tristate "Sound hardware support"
|
||||||
|
|
||||||
|
config SND_RAWMIDI
|
||||||
|
tristate
|
||||||
|
|
||||||
|
config SND_COMPRESS_OFFLOAD
|
||||||
|
- tristate
|
||||||
|
+ tristate "Compression offloading support"
|
||||||
|
|
||||||
|
config SND_JACK
|
||||||
|
bool
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,3 +1,19 @@
|
||||||
|
From 811d9e2268a62b830cfe93cd8bc929afcb8b198b Mon Sep 17 00:00:00 2001
|
||||||
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Sat, 15 Jul 2017 21:12:38 +0200
|
||||||
|
Subject: kernel: move regmap bloat out of the kernel image if it is only being used in modules
|
||||||
|
|
||||||
|
lede-commit: 96f39119815028073583e4fca3a9c5fe9141e998
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
---
|
||||||
|
drivers/base/regmap/Kconfig | 15 ++++++++++-----
|
||||||
|
drivers/base/regmap/Makefile | 12 ++++++++----
|
||||||
|
drivers/base/regmap/regmap.c | 3 +++
|
||||||
|
include/linux/regmap.h | 2 +-
|
||||||
|
4 files changed, 22 insertions(+), 10 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/drivers/base/regmap/Kconfig b/drivers/base/regmap/Kconfig
|
||||||
|
index 48b3fc1ee514..c4cb7592392b 100644
|
||||||
--- a/drivers/base/regmap/Kconfig
|
--- a/drivers/base/regmap/Kconfig
|
||||||
+++ b/drivers/base/regmap/Kconfig
|
+++ b/drivers/base/regmap/Kconfig
|
||||||
@@ -3,9 +3,8 @@
|
@@ -3,9 +3,8 @@
|
||||||
|
@ -40,17 +56,8 @@
|
||||||
config REGMAP_IRQ
|
config REGMAP_IRQ
|
||||||
+ select REGMAP
|
+ select REGMAP
|
||||||
bool
|
bool
|
||||||
--- a/include/linux/regmap.h
|
diff --git a/drivers/base/regmap/Makefile b/drivers/base/regmap/Makefile
|
||||||
+++ b/include/linux/regmap.h
|
index 6271ea9b758a..f23c58a050aa 100644
|
||||||
@@ -135,7 +135,7 @@ struct reg_sequence {
|
|
||||||
pollret ?: ((cond) ? 0 : -ETIMEDOUT); \
|
|
||||||
})
|
|
||||||
|
|
||||||
-#ifdef CONFIG_REGMAP
|
|
||||||
+#if IS_ENABLED(CONFIG_REGMAP)
|
|
||||||
|
|
||||||
enum regmap_endian {
|
|
||||||
/* Unspecified -> 0 -> Backwards compatible default */
|
|
||||||
--- a/drivers/base/regmap/Makefile
|
--- a/drivers/base/regmap/Makefile
|
||||||
+++ b/drivers/base/regmap/Makefile
|
+++ b/drivers/base/regmap/Makefile
|
||||||
@@ -1,10 +1,14 @@
|
@@ -1,10 +1,14 @@
|
||||||
|
@ -72,6 +79,8 @@
|
||||||
obj-$(CONFIG_REGMAP_AC97) += regmap-ac97.o
|
obj-$(CONFIG_REGMAP_AC97) += regmap-ac97.o
|
||||||
obj-$(CONFIG_REGMAP_I2C) += regmap-i2c.o
|
obj-$(CONFIG_REGMAP_I2C) += regmap-i2c.o
|
||||||
obj-$(CONFIG_REGMAP_SPI) += regmap-spi.o
|
obj-$(CONFIG_REGMAP_SPI) += regmap-spi.o
|
||||||
|
diff --git a/drivers/base/regmap/regmap.c b/drivers/base/regmap/regmap.c
|
||||||
|
index ae63bb0875ea..2ac56b4f525e 100644
|
||||||
--- a/drivers/base/regmap/regmap.c
|
--- a/drivers/base/regmap/regmap.c
|
||||||
+++ b/drivers/base/regmap/regmap.c
|
+++ b/drivers/base/regmap/regmap.c
|
||||||
@@ -13,6 +13,7 @@
|
@@ -13,6 +13,7 @@
|
||||||
|
@ -88,3 +97,19 @@
|
||||||
postcore_initcall(regmap_initcall);
|
postcore_initcall(regmap_initcall);
|
||||||
+
|
+
|
||||||
+MODULE_LICENSE("GPL");
|
+MODULE_LICENSE("GPL");
|
||||||
|
diff --git a/include/linux/regmap.h b/include/linux/regmap.h
|
||||||
|
index f6673132431d..95c7db29448b 100644
|
||||||
|
--- a/include/linux/regmap.h
|
||||||
|
+++ b/include/linux/regmap.h
|
||||||
|
@@ -135,7 +135,7 @@ struct reg_sequence {
|
||||||
|
pollret ?: ((cond) ? 0 : -ETIMEDOUT); \
|
||||||
|
})
|
||||||
|
|
||||||
|
-#ifdef CONFIG_REGMAP
|
||||||
|
+#if IS_ENABLED(CONFIG_REGMAP)
|
||||||
|
|
||||||
|
enum regmap_endian {
|
||||||
|
/* Unspecified -> 0 -> Backwards compatible default */
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,3 +1,19 @@
|
||||||
|
From fd1799b0bf5efa46dd3e6dfbbf3955564807e508 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Fri, 7 Jul 2017 17:12:51 +0200
|
||||||
|
Subject: kernel: prevent cryptomgr from pulling in useless extra dependencies for tests that are not run
|
||||||
|
|
||||||
|
Reduces kernel size after LZMA by about 5k on MIPS
|
||||||
|
|
||||||
|
lede-commit: 044c316167e076479a344c59905e5b435b84a77f
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
---
|
||||||
|
crypto/Kconfig | 13 ++++++-------
|
||||||
|
crypto/algboss.c | 4 ++++
|
||||||
|
2 files changed, 10 insertions(+), 7 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/crypto/Kconfig b/crypto/Kconfig
|
||||||
|
index e3552d1c1b84..17be110ad162 100644
|
||||||
--- a/crypto/Kconfig
|
--- a/crypto/Kconfig
|
||||||
+++ b/crypto/Kconfig
|
+++ b/crypto/Kconfig
|
||||||
@@ -132,12 +132,12 @@ config CRYPTO_MANAGER
|
@@ -132,12 +132,12 @@ config CRYPTO_MANAGER
|
||||||
|
@ -27,9 +43,11 @@
|
||||||
help
|
help
|
||||||
Disable run-time self tests that normally take place at
|
Disable run-time self tests that normally take place at
|
||||||
algorithm registration.
|
algorithm registration.
|
||||||
|
diff --git a/crypto/algboss.c b/crypto/algboss.c
|
||||||
|
index 6e39d9c05b98..4bde25d62ec7 100644
|
||||||
--- a/crypto/algboss.c
|
--- a/crypto/algboss.c
|
||||||
+++ b/crypto/algboss.c
|
+++ b/crypto/algboss.c
|
||||||
@@ -248,12 +248,16 @@ static int cryptomgr_schedule_test(struc
|
@@ -248,12 +248,16 @@ static int cryptomgr_schedule_test(struct crypto_alg *alg)
|
||||||
type = alg->cra_flags;
|
type = alg->cra_flags;
|
||||||
|
|
||||||
/* This piece of crap needs to disappear into per-type test hooks. */
|
/* This piece of crap needs to disappear into per-type test hooks. */
|
||||||
|
@ -46,3 +64,6 @@
|
||||||
|
|
||||||
param->type = type;
|
param->type = type;
|
||||||
|
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,3 +1,46 @@
|
||||||
|
From 236c1acdfef5958010ac9814a9872e0a46fd78ee Mon Sep 17 00:00:00 2001
|
||||||
|
From: John Crispin <john@phrozen.org>
|
||||||
|
Date: Fri, 7 Jul 2017 17:13:44 +0200
|
||||||
|
Subject: rfkill: add fake rfkill support
|
||||||
|
|
||||||
|
allow building of modules depending on RFKILL even if RFKILL is not enabled.
|
||||||
|
|
||||||
|
Signed-off-by: John Crispin <john@phrozen.org>
|
||||||
|
---
|
||||||
|
include/linux/rfkill.h | 2 +-
|
||||||
|
net/Makefile | 2 +-
|
||||||
|
net/rfkill/Kconfig | 14 +++++++++-----
|
||||||
|
net/rfkill/Makefile | 2 +-
|
||||||
|
4 files changed, 12 insertions(+), 8 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/include/linux/rfkill.h b/include/linux/rfkill.h
|
||||||
|
index e6a0031d1b1f..21cf4dab0b9a 100644
|
||||||
|
--- a/include/linux/rfkill.h
|
||||||
|
+++ b/include/linux/rfkill.h
|
||||||
|
@@ -64,7 +64,7 @@ struct rfkill_ops {
|
||||||
|
int (*set_block)(void *data, bool blocked);
|
||||||
|
};
|
||||||
|
|
||||||
|
-#if defined(CONFIG_RFKILL) || defined(CONFIG_RFKILL_MODULE)
|
||||||
|
+#if defined(CONFIG_RFKILL_FULL) || defined(CONFIG_RFKILL_FULL_MODULE)
|
||||||
|
/**
|
||||||
|
* rfkill_alloc - allocate rfkill structure
|
||||||
|
* @name: name of the struct -- the string is not copied internally
|
||||||
|
diff --git a/net/Makefile b/net/Makefile
|
||||||
|
index 4cafaa2b4667..6566175e6c0a 100644
|
||||||
|
--- a/net/Makefile
|
||||||
|
+++ b/net/Makefile
|
||||||
|
@@ -51,7 +51,7 @@ obj-$(CONFIG_MAC80211) += mac80211/
|
||||||
|
obj-$(CONFIG_TIPC) += tipc/
|
||||||
|
obj-$(CONFIG_NETLABEL) += netlabel/
|
||||||
|
obj-$(CONFIG_IUCV) += iucv/
|
||||||
|
-obj-$(CONFIG_RFKILL) += rfkill/
|
||||||
|
+obj-$(CONFIG_RFKILL_FULL) += rfkill/
|
||||||
|
obj-$(CONFIG_NET_9P) += 9p/
|
||||||
|
obj-$(CONFIG_CAIF) += caif/
|
||||||
|
ifneq ($(CONFIG_DCB),)
|
||||||
|
diff --git a/net/rfkill/Kconfig b/net/rfkill/Kconfig
|
||||||
|
index 868f1ad0415a..159b6ebeacd8 100644
|
||||||
--- a/net/rfkill/Kconfig
|
--- a/net/rfkill/Kconfig
|
||||||
+++ b/net/rfkill/Kconfig
|
+++ b/net/rfkill/Kconfig
|
||||||
@@ -1,7 +1,11 @@
|
@@ -1,7 +1,11 @@
|
||||||
|
@ -45,6 +88,8 @@
|
||||||
depends on GPIOLIB || COMPILE_TEST
|
depends on GPIOLIB || COMPILE_TEST
|
||||||
default n
|
default n
|
||||||
help
|
help
|
||||||
|
diff --git a/net/rfkill/Makefile b/net/rfkill/Makefile
|
||||||
|
index 311768783f4a..dbb01a8645af 100644
|
||||||
--- a/net/rfkill/Makefile
|
--- a/net/rfkill/Makefile
|
||||||
+++ b/net/rfkill/Makefile
|
+++ b/net/rfkill/Makefile
|
||||||
@@ -4,6 +4,6 @@
|
@@ -4,6 +4,6 @@
|
||||||
|
@ -55,25 +100,6 @@
|
||||||
+obj-$(CONFIG_RFKILL_FULL) += rfkill.o
|
+obj-$(CONFIG_RFKILL_FULL) += rfkill.o
|
||||||
obj-$(CONFIG_RFKILL_REGULATOR) += rfkill-regulator.o
|
obj-$(CONFIG_RFKILL_REGULATOR) += rfkill-regulator.o
|
||||||
obj-$(CONFIG_RFKILL_GPIO) += rfkill-gpio.o
|
obj-$(CONFIG_RFKILL_GPIO) += rfkill-gpio.o
|
||||||
--- a/net/Makefile
|
--
|
||||||
+++ b/net/Makefile
|
2.11.0
|
||||||
@@ -51,7 +51,7 @@ obj-$(CONFIG_MAC80211) += mac80211/
|
|
||||||
obj-$(CONFIG_TIPC) += tipc/
|
|
||||||
obj-$(CONFIG_NETLABEL) += netlabel/
|
|
||||||
obj-$(CONFIG_IUCV) += iucv/
|
|
||||||
-obj-$(CONFIG_RFKILL) += rfkill/
|
|
||||||
+obj-$(CONFIG_RFKILL_FULL) += rfkill/
|
|
||||||
obj-$(CONFIG_NET_9P) += 9p/
|
|
||||||
obj-$(CONFIG_CAIF) += caif/
|
|
||||||
ifneq ($(CONFIG_DCB),)
|
|
||||||
--- a/include/linux/rfkill.h
|
|
||||||
+++ b/include/linux/rfkill.h
|
|
||||||
@@ -64,7 +64,7 @@ struct rfkill_ops {
|
|
||||||
int (*set_block)(void *data, bool blocked);
|
|
||||||
};
|
|
||||||
|
|
||||||
-#if defined(CONFIG_RFKILL) || defined(CONFIG_RFKILL_MODULE)
|
|
||||||
+#if defined(CONFIG_RFKILL_FULL) || defined(CONFIG_RFKILL_FULL_MODULE)
|
|
||||||
/**
|
|
||||||
* rfkill_alloc - allocate rfkill structure
|
|
||||||
* @name: name of the struct -- the string is not copied internally
|
|
|
@ -0,0 +1,45 @@
|
||||||
|
From: John Crispin <john@phrozen.org>
|
||||||
|
Subject: hack: kernel: add generic image_cmdline hack to MIPS targets
|
||||||
|
|
||||||
|
lede-commit: d59f5b3a987a48508257a0ddbaeadc7909f9f976
|
||||||
|
Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
|
||||||
|
---
|
||||||
|
arch/mips/Kconfig | 4 ++++
|
||||||
|
arch/mips/kernel/head.S | 6 ++++++
|
||||||
|
2 files changed, 10 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/arch/mips/Kconfig b/arch/mips/Kconfig
|
||||||
|
index 6a56d75f7e8b..03fbb7b46e7f 100644
|
||||||
|
--- a/arch/mips/Kconfig
|
||||||
|
+++ b/arch/mips/Kconfig
|
||||||
|
@@ -1149,6 +1149,10 @@ config SYNC_R4K
|
||||||
|
config MIPS_MACHINE
|
||||||
|
def_bool n
|
||||||
|
|
||||||
|
+config IMAGE_CMDLINE_HACK
|
||||||
|
+ bool "OpenWrt specific image command line hack"
|
||||||
|
+ default n
|
||||||
|
+
|
||||||
|
config NO_IOPORT_MAP
|
||||||
|
def_bool n
|
||||||
|
|
||||||
|
diff --git a/arch/mips/kernel/head.S b/arch/mips/kernel/head.S
|
||||||
|
index cf052204eb0a..f7327fae5473 100644
|
||||||
|
--- a/arch/mips/kernel/head.S
|
||||||
|
+++ b/arch/mips/kernel/head.S
|
||||||
|
@@ -79,6 +79,12 @@ FEXPORT(__kernel_entry)
|
||||||
|
j kernel_entry
|
||||||
|
#endif
|
||||||
|
|
||||||
|
+#ifdef CONFIG_IMAGE_CMDLINE_HACK
|
||||||
|
+ .ascii "CMDLINE:"
|
||||||
|
+EXPORT(__image_cmdline)
|
||||||
|
+ .fill 0x400
|
||||||
|
+#endif /* CONFIG_IMAGE_CMDLINE_HACK */
|
||||||
|
+
|
||||||
|
__REF
|
||||||
|
|
||||||
|
NESTED(kernel_entry, 16, sp) # kernel entry point
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -0,0 +1,31 @@
|
||||||
|
From 107c0964cb8db7ca28ac5199426414fdab3c274d Mon Sep 17 00:00:00 2001
|
||||||
|
From: "Alexandros C. Couloumbis" <alex@ozo.com>
|
||||||
|
Date: Fri, 7 Jul 2017 17:14:51 +0200
|
||||||
|
Subject: hack: arch: powerpc: drop register save/restore library from modules
|
||||||
|
|
||||||
|
Upstream GCC uses a libgcc function for saving/restoring registers. This
|
||||||
|
makes the code bigger, and upstream kernels need to carry that function
|
||||||
|
for every single kernel module. Our GCC is patched to avoid those
|
||||||
|
references, so we can drop the extra bloat for modules.
|
||||||
|
|
||||||
|
lede-commit: e8e1084654f50904e6bf77b70b2de3f137d7b3ec
|
||||||
|
Signed-off-by: Alexandros C. Couloumbis <alex@ozo.com>
|
||||||
|
---
|
||||||
|
arch/powerpc/Makefile | 1 -
|
||||||
|
1 file changed, 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/arch/powerpc/Makefile b/arch/powerpc/Makefile
|
||||||
|
index 617dece67924..1146daa8e4c2 100644
|
||||||
|
--- a/arch/powerpc/Makefile
|
||||||
|
+++ b/arch/powerpc/Makefile
|
||||||
|
@@ -179,7 +179,6 @@ else
|
||||||
|
CHECKFLAGS += -D__LITTLE_ENDIAN__
|
||||||
|
endif
|
||||||
|
|
||||||
|
-KBUILD_LDFLAGS_MODULE += arch/powerpc/lib/crtsavres.o
|
||||||
|
|
||||||
|
ifeq ($(CONFIG_476FPE_ERR46),y)
|
||||||
|
KBUILD_LDFLAGS_MODULE += --ppc476-workaround \
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -1,14 +1,21 @@
|
||||||
|
From c6905cfdeb31a5c049db3da434b10fa0d3e83569 Mon Sep 17 00:00:00 2001
|
||||||
From: Felix Fietkau <nbd@nbd.name>
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
Subject: [PATCH] bridge: only accept EAP locally
|
Date: Fri, 7 Jul 2017 17:18:54 +0200
|
||||||
|
Subject: bridge: only accept EAP locally
|
||||||
|
|
||||||
When bridging, do not forward EAP frames to other ports, only deliver
|
When bridging, do not forward EAP frames to other ports, only deliver
|
||||||
them locally, regardless of the state.
|
them locally, regardless of the state.
|
||||||
|
|
||||||
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
---
|
---
|
||||||
|
net/bridge/br_input.c | 7 +++++--
|
||||||
|
1 file changed, 5 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/net/bridge/br_input.c b/net/bridge/br_input.c
|
||||||
|
index 267b46af407f..48fa08f32c2a 100644
|
||||||
--- a/net/bridge/br_input.c
|
--- a/net/bridge/br_input.c
|
||||||
+++ b/net/bridge/br_input.c
|
+++ b/net/bridge/br_input.c
|
||||||
@@ -164,11 +164,14 @@ int br_handle_frame_finish(struct net *n
|
@@ -164,11 +164,14 @@ int br_handle_frame_finish(struct net *net, struct sock *sk, struct sk_buff *skb
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -25,3 +32,6 @@ Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
if (IS_ENABLED(CONFIG_INET) && skb->protocol == htons(ETH_P_ARP))
|
if (IS_ENABLED(CONFIG_INET) && skb->protocol == htons(ETH_P_ARP))
|
||||||
br_do_proxy_arp(skb, br, vid, p);
|
br_do_proxy_arp(skb, br, vid, p);
|
||||||
|
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,10 +1,22 @@
|
||||||
|
From e988390850731aa1697ed09d47b0932fac1af175 Mon Sep 17 00:00:00 2001
|
||||||
From: Felix Fietkau <nbd@nbd.name>
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
Subject: [PATCH] bridge: port isolate
|
Date: Fri, 7 Jul 2017 17:20:03 +0200
|
||||||
|
Subject: bridge: port isolate
|
||||||
|
|
||||||
Isolating individual bridge ports
|
Isolating individual bridge ports
|
||||||
|
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
---
|
---
|
||||||
--- a/include/linux/if_bridge.h
|
include/linux/if_bridge.h | 1 +
|
||||||
+++ b/include/linux/if_bridge.h
|
net/bridge/br_forward.c | 5 +++++
|
||||||
|
net/bridge/br_input.c | 3 +++
|
||||||
|
net/bridge/br_sysfs_if.c | 2 ++
|
||||||
|
4 files changed, 11 insertions(+)
|
||||||
|
|
||||||
|
Index: linux-4.9.34/include/linux/if_bridge.h
|
||||||
|
===================================================================
|
||||||
|
--- linux-4.9.34.orig/include/linux/if_bridge.h
|
||||||
|
+++ linux-4.9.34/include/linux/if_bridge.h
|
||||||
@@ -47,6 +47,7 @@ struct br_ip_list {
|
@@ -47,6 +47,7 @@ struct br_ip_list {
|
||||||
#define BR_PROXYARP_WIFI BIT(10)
|
#define BR_PROXYARP_WIFI BIT(10)
|
||||||
#define BR_MCAST_FLOOD BIT(11)
|
#define BR_MCAST_FLOOD BIT(11)
|
||||||
|
@ -13,26 +25,10 @@ Isolating individual bridge ports
|
||||||
|
|
||||||
#define BR_DEFAULT_AGEING_TIME (300 * HZ)
|
#define BR_DEFAULT_AGEING_TIME (300 * HZ)
|
||||||
|
|
||||||
--- a/net/bridge/br_sysfs_if.c
|
Index: linux-4.9.34/net/bridge/br_forward.c
|
||||||
+++ b/net/bridge/br_sysfs_if.c
|
===================================================================
|
||||||
@@ -172,6 +172,7 @@ BRPORT_ATTR_FLAG(unicast_flood, BR_FLOOD
|
--- linux-4.9.34.orig/net/bridge/br_forward.c
|
||||||
BRPORT_ATTR_FLAG(proxyarp, BR_PROXYARP);
|
+++ linux-4.9.34/net/bridge/br_forward.c
|
||||||
BRPORT_ATTR_FLAG(proxyarp_wifi, BR_PROXYARP_WIFI);
|
|
||||||
BRPORT_ATTR_FLAG(multicast_flood, BR_MCAST_FLOOD);
|
|
||||||
+BRPORT_ATTR_FLAG(isolate_mode, BR_ISOLATE_MODE);
|
|
||||||
|
|
||||||
#ifdef CONFIG_BRIDGE_IGMP_SNOOPING
|
|
||||||
static ssize_t show_multicast_router(struct net_bridge_port *p, char *buf)
|
|
||||||
@@ -220,6 +221,7 @@ static const struct brport_attribute *br
|
|
||||||
&brport_attr_proxyarp,
|
|
||||||
&brport_attr_proxyarp_wifi,
|
|
||||||
&brport_attr_multicast_flood,
|
|
||||||
+ &brport_attr_isolate_mode,
|
|
||||||
NULL
|
|
||||||
};
|
|
||||||
|
|
||||||
--- a/net/bridge/br_forward.c
|
|
||||||
+++ b/net/bridge/br_forward.c
|
|
||||||
@@ -141,6 +141,9 @@ static int deliver_clone(const struct ne
|
@@ -141,6 +141,9 @@ static int deliver_clone(const struct ne
|
||||||
void br_forward(const struct net_bridge_port *to,
|
void br_forward(const struct net_bridge_port *to,
|
||||||
struct sk_buff *skb, bool local_rcv, bool local_orig)
|
struct sk_buff *skb, bool local_rcv, bool local_orig)
|
||||||
|
@ -52,8 +48,10 @@ Isolating individual bridge ports
|
||||||
/* Do not flood unicast traffic to ports that turn it off */
|
/* Do not flood unicast traffic to ports that turn it off */
|
||||||
if (pkt_type == BR_PKT_UNICAST && !(p->flags & BR_FLOOD))
|
if (pkt_type == BR_PKT_UNICAST && !(p->flags & BR_FLOOD))
|
||||||
continue;
|
continue;
|
||||||
--- a/net/bridge/br_input.c
|
Index: linux-4.9.34/net/bridge/br_input.c
|
||||||
+++ b/net/bridge/br_input.c
|
===================================================================
|
||||||
|
--- linux-4.9.34.orig/net/bridge/br_input.c
|
||||||
|
+++ linux-4.9.34/net/bridge/br_input.c
|
||||||
@@ -175,6 +175,9 @@ int br_handle_frame_finish(struct net *n
|
@@ -175,6 +175,9 @@ int br_handle_frame_finish(struct net *n
|
||||||
if (IS_ENABLED(CONFIG_INET) && skb->protocol == htons(ETH_P_ARP))
|
if (IS_ENABLED(CONFIG_INET) && skb->protocol == htons(ETH_P_ARP))
|
||||||
br_do_proxy_arp(skb, br, vid, p);
|
br_do_proxy_arp(skb, br, vid, p);
|
||||||
|
@ -64,3 +62,23 @@ Isolating individual bridge ports
|
||||||
switch (pkt_type) {
|
switch (pkt_type) {
|
||||||
case BR_PKT_MULTICAST:
|
case BR_PKT_MULTICAST:
|
||||||
mdst = br_mdb_get(br, skb, vid);
|
mdst = br_mdb_get(br, skb, vid);
|
||||||
|
Index: linux-4.9.34/net/bridge/br_sysfs_if.c
|
||||||
|
===================================================================
|
||||||
|
--- linux-4.9.34.orig/net/bridge/br_sysfs_if.c
|
||||||
|
+++ linux-4.9.34/net/bridge/br_sysfs_if.c
|
||||||
|
@@ -172,6 +172,7 @@ BRPORT_ATTR_FLAG(unicast_flood, BR_FLOOD
|
||||||
|
BRPORT_ATTR_FLAG(proxyarp, BR_PROXYARP);
|
||||||
|
BRPORT_ATTR_FLAG(proxyarp_wifi, BR_PROXYARP_WIFI);
|
||||||
|
BRPORT_ATTR_FLAG(multicast_flood, BR_MCAST_FLOOD);
|
||||||
|
+BRPORT_ATTR_FLAG(isolate_mode, BR_ISOLATE_MODE);
|
||||||
|
|
||||||
|
#ifdef CONFIG_BRIDGE_IGMP_SNOOPING
|
||||||
|
static ssize_t show_multicast_router(struct net_bridge_port *p, char *buf)
|
||||||
|
@@ -220,6 +221,7 @@ static const struct brport_attribute *br
|
||||||
|
&brport_attr_proxyarp,
|
||||||
|
&brport_attr_proxyarp_wifi,
|
||||||
|
&brport_attr_multicast_flood,
|
||||||
|
+ &brport_attr_isolate_mode,
|
||||||
|
NULL
|
||||||
|
};
|
||||||
|
|
29
target/linux/generic/hack-4.9/651-wireless_mesh_header.patch
Normal file
29
target/linux/generic/hack-4.9/651-wireless_mesh_header.patch
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
From 6d3bc769657b0ee7c7506dad9911111c4226a7ea Mon Sep 17 00:00:00 2001
|
||||||
|
From: Imre Kaloz <kaloz@openwrt.org>
|
||||||
|
Date: Fri, 7 Jul 2017 17:21:05 +0200
|
||||||
|
Subject: mac80211: increase wireless mesh header size
|
||||||
|
|
||||||
|
lede-commit 3d4466cfd8f75f717efdb1f96fdde3c70d865fc1
|
||||||
|
Signed-off-by: Imre Kaloz <kaloz@openwrt.org>
|
||||||
|
---
|
||||||
|
include/linux/netdevice.h | 4 ++--
|
||||||
|
1 file changed, 2 insertions(+), 2 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h
|
||||||
|
index 780e7171f548..6e0f2c79f79a 100644
|
||||||
|
--- a/include/linux/netdevice.h
|
||||||
|
+++ b/include/linux/netdevice.h
|
||||||
|
@@ -137,8 +137,8 @@ static inline bool dev_xmit_complete(int rc)
|
||||||
|
|
||||||
|
#if defined(CONFIG_HYPERV_NET)
|
||||||
|
# define LL_MAX_HEADER 128
|
||||||
|
-#elif defined(CONFIG_WLAN) || IS_ENABLED(CONFIG_AX25)
|
||||||
|
-# if defined(CONFIG_MAC80211_MESH)
|
||||||
|
+#elif defined(CONFIG_WLAN) || IS_ENABLED(CONFIG_AX25) || 1
|
||||||
|
+# if defined(CONFIG_MAC80211_MESH) || 1
|
||||||
|
# define LL_MAX_HEADER 128
|
||||||
|
# else
|
||||||
|
# define LL_MAX_HEADER 96
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
26
target/linux/generic/hack-4.9/660-fq_codel_defaults.patch
Normal file
26
target/linux/generic/hack-4.9/660-fq_codel_defaults.patch
Normal file
|
@ -0,0 +1,26 @@
|
||||||
|
From a6ccb238939b25851474a279b20367fd24a0e816 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Fri, 7 Jul 2017 17:21:53 +0200
|
||||||
|
Subject: hack: net: fq_codel: tune defaults for small devices
|
||||||
|
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
---
|
||||||
|
net/sched/sch_fq_codel.c | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/net/sched/sch_fq_codel.c b/net/sched/sch_fq_codel.c
|
||||||
|
index a5ea0e9b6be4..4467b95795bf 100644
|
||||||
|
--- a/net/sched/sch_fq_codel.c
|
||||||
|
+++ b/net/sched/sch_fq_codel.c
|
||||||
|
@@ -479,7 +479,7 @@ static int fq_codel_init(struct Qdisc *sch, struct nlattr *opt)
|
||||||
|
|
||||||
|
sch->limit = 10*1024;
|
||||||
|
q->flows_cnt = 1024;
|
||||||
|
- q->memory_limit = 32 << 20; /* 32 MBytes */
|
||||||
|
+ q->memory_limit = 4 << 20; /* 4 MBytes */
|
||||||
|
q->drop_batch_size = 64;
|
||||||
|
q->quantum = psched_mtu(qdisc_dev(sch));
|
||||||
|
q->perturbation = prandom_u32();
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,35 +1,19 @@
|
||||||
--- a/net/sched/Kconfig
|
From 1d418f7e88035ed7a94073f6354246c66e9193e9 Mon Sep 17 00:00:00 2001
|
||||||
+++ b/net/sched/Kconfig
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
@@ -3,8 +3,9 @@
|
Date: Fri, 7 Jul 2017 17:22:58 +0200
|
||||||
#
|
Subject: fq_codel: switch default qdisc from pfifo_fast to fq_codel and remove pfifo_fast
|
||||||
|
|
||||||
menuconfig NET_SCHED
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
- bool "QoS and/or fair queueing"
|
---
|
||||||
+ def_bool y
|
include/net/sch_generic.h | 3 ++-
|
||||||
select NET_SCH_FIFO
|
net/sched/Kconfig | 3 ++-
|
||||||
+ select NET_SCH_FQ_CODEL
|
net/sched/sch_api.c | 2 +-
|
||||||
---help---
|
net/sched/sch_fq_codel.c | 3 ++-
|
||||||
When the kernel has several packets to send out over a network
|
net/sched/sch_generic.c | 4 ++--
|
||||||
device, it has to decide which ones to send first, which ones to
|
5 files changed, 9 insertions(+), 6 deletions(-)
|
||||||
--- a/net/sched/sch_fq_codel.c
|
|
||||||
+++ b/net/sched/sch_fq_codel.c
|
diff --git a/include/net/sch_generic.h b/include/net/sch_generic.h
|
||||||
@@ -705,7 +705,7 @@ static const struct Qdisc_class_ops fq_c
|
index e6aa0a249672..9eeb368d7eea 100644
|
||||||
.walk = fq_codel_walk,
|
|
||||||
};
|
|
||||||
|
|
||||||
-static struct Qdisc_ops fq_codel_qdisc_ops __read_mostly = {
|
|
||||||
+struct Qdisc_ops fq_codel_qdisc_ops __read_mostly = {
|
|
||||||
.cl_ops = &fq_codel_class_ops,
|
|
||||||
.id = "fq_codel",
|
|
||||||
.priv_size = sizeof(struct fq_codel_sched_data),
|
|
||||||
@@ -720,6 +720,7 @@ static struct Qdisc_ops fq_codel_qdisc_o
|
|
||||||
.dump_stats = fq_codel_dump_stats,
|
|
||||||
.owner = THIS_MODULE,
|
|
||||||
};
|
|
||||||
+EXPORT_SYMBOL(fq_codel_qdisc_ops);
|
|
||||||
|
|
||||||
static int __init fq_codel_module_init(void)
|
|
||||||
{
|
|
||||||
--- a/include/net/sch_generic.h
|
--- a/include/net/sch_generic.h
|
||||||
+++ b/include/net/sch_generic.h
|
+++ b/include/net/sch_generic.h
|
||||||
@@ -339,12 +339,13 @@ extern struct Qdisc_ops noop_qdisc_ops;
|
@@ -339,12 +339,13 @@ extern struct Qdisc_ops noop_qdisc_ops;
|
||||||
|
@ -47,6 +31,57 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
struct Qdisc_class_common {
|
struct Qdisc_class_common {
|
||||||
|
diff --git a/net/sched/Kconfig b/net/sched/Kconfig
|
||||||
|
index 87956a768d1b..89c6db93cb63 100644
|
||||||
|
--- a/net/sched/Kconfig
|
||||||
|
+++ b/net/sched/Kconfig
|
||||||
|
@@ -3,8 +3,9 @@
|
||||||
|
#
|
||||||
|
|
||||||
|
menuconfig NET_SCHED
|
||||||
|
- bool "QoS and/or fair queueing"
|
||||||
|
+ def_bool y
|
||||||
|
select NET_SCH_FIFO
|
||||||
|
+ select NET_SCH_FQ_CODEL
|
||||||
|
---help---
|
||||||
|
When the kernel has several packets to send out over a network
|
||||||
|
device, it has to decide which ones to send first, which ones to
|
||||||
|
diff --git a/net/sched/sch_api.c b/net/sched/sch_api.c
|
||||||
|
index 206dc24add3a..9b5cfb6ac64b 100644
|
||||||
|
--- a/net/sched/sch_api.c
|
||||||
|
+++ b/net/sched/sch_api.c
|
||||||
|
@@ -1976,7 +1976,7 @@ static int __init pktsched_init(void)
|
||||||
|
return err;
|
||||||
|
}
|
||||||
|
|
||||||
|
- register_qdisc(&pfifo_fast_ops);
|
||||||
|
+ register_qdisc(&fq_codel_qdisc_ops);
|
||||||
|
register_qdisc(&pfifo_qdisc_ops);
|
||||||
|
register_qdisc(&bfifo_qdisc_ops);
|
||||||
|
register_qdisc(&pfifo_head_drop_qdisc_ops);
|
||||||
|
diff --git a/net/sched/sch_fq_codel.c b/net/sched/sch_fq_codel.c
|
||||||
|
index 4467b95795bf..2ebbf50658e5 100644
|
||||||
|
--- a/net/sched/sch_fq_codel.c
|
||||||
|
+++ b/net/sched/sch_fq_codel.c
|
||||||
|
@@ -705,7 +705,7 @@ static const struct Qdisc_class_ops fq_codel_class_ops = {
|
||||||
|
.walk = fq_codel_walk,
|
||||||
|
};
|
||||||
|
|
||||||
|
-static struct Qdisc_ops fq_codel_qdisc_ops __read_mostly = {
|
||||||
|
+struct Qdisc_ops fq_codel_qdisc_ops __read_mostly = {
|
||||||
|
.cl_ops = &fq_codel_class_ops,
|
||||||
|
.id = "fq_codel",
|
||||||
|
.priv_size = sizeof(struct fq_codel_sched_data),
|
||||||
|
@@ -720,6 +720,7 @@ static struct Qdisc_ops fq_codel_qdisc_ops __read_mostly = {
|
||||||
|
.dump_stats = fq_codel_dump_stats,
|
||||||
|
.owner = THIS_MODULE,
|
||||||
|
};
|
||||||
|
+EXPORT_SYMBOL(fq_codel_qdisc_ops);
|
||||||
|
|
||||||
|
static int __init fq_codel_module_init(void)
|
||||||
|
{
|
||||||
|
diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c
|
||||||
|
index 6cfb6e9038c2..97de97e3c5e2 100644
|
||||||
--- a/net/sched/sch_generic.c
|
--- a/net/sched/sch_generic.c
|
||||||
+++ b/net/sched/sch_generic.c
|
+++ b/net/sched/sch_generic.c
|
||||||
@@ -31,7 +31,7 @@
|
@@ -31,7 +31,7 @@
|
||||||
|
@ -58,7 +93,7 @@
|
||||||
EXPORT_SYMBOL(default_qdisc_ops);
|
EXPORT_SYMBOL(default_qdisc_ops);
|
||||||
|
|
||||||
/* Main transmission queue. */
|
/* Main transmission queue. */
|
||||||
@@ -759,7 +759,7 @@ static void attach_one_default_qdisc(str
|
@@ -759,7 +759,7 @@ static void attach_one_default_qdisc(struct net_device *dev,
|
||||||
void *_unused)
|
void *_unused)
|
||||||
{
|
{
|
||||||
struct Qdisc *qdisc;
|
struct Qdisc *qdisc;
|
||||||
|
@ -67,14 +102,6 @@
|
||||||
|
|
||||||
if (dev->priv_flags & IFF_NO_QUEUE)
|
if (dev->priv_flags & IFF_NO_QUEUE)
|
||||||
ops = &noqueue_qdisc_ops;
|
ops = &noqueue_qdisc_ops;
|
||||||
--- a/net/sched/sch_api.c
|
--
|
||||||
+++ b/net/sched/sch_api.c
|
2.11.0
|
||||||
@@ -1979,7 +1979,7 @@ static int __init pktsched_init(void)
|
|
||||||
return err;
|
|
||||||
}
|
|
||||||
|
|
||||||
- register_qdisc(&pfifo_fast_ops);
|
|
||||||
+ register_qdisc(&fq_codel_qdisc_ops);
|
|
||||||
register_qdisc(&pfifo_qdisc_ops);
|
|
||||||
register_qdisc(&bfifo_qdisc_ops);
|
|
||||||
register_qdisc(&pfifo_head_drop_qdisc_ops);
|
|
|
@ -1,6 +1,18 @@
|
||||||
|
From b531d492d5ef1cf9dba0f4888eb5fd8624a6d762 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Fri, 7 Jul 2017 17:23:42 +0200
|
||||||
|
Subject: net: sched: switch default qdisc from pfifo_fast to fq_codel and remove pfifo_fast
|
||||||
|
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
---
|
||||||
|
net/sched/sch_generic.c | 140 ------------------------------------------------
|
||||||
|
1 file changed, 140 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/net/sched/sch_generic.c b/net/sched/sch_generic.c
|
||||||
|
index 97de97e3c5e2..a62de9e4e897 100644
|
||||||
--- a/net/sched/sch_generic.c
|
--- a/net/sched/sch_generic.c
|
||||||
+++ b/net/sched/sch_generic.c
|
+++ b/net/sched/sch_generic.c
|
||||||
@@ -449,146 +449,6 @@ struct Qdisc_ops noqueue_qdisc_ops __rea
|
@@ -449,146 +449,6 @@ struct Qdisc_ops noqueue_qdisc_ops __read_mostly = {
|
||||||
.owner = THIS_MODULE,
|
.owner = THIS_MODULE,
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -147,3 +159,6 @@
|
||||||
static struct lock_class_key qdisc_tx_busylock;
|
static struct lock_class_key qdisc_tx_busylock;
|
||||||
static struct lock_class_key qdisc_running_key;
|
static struct lock_class_key qdisc_running_key;
|
||||||
|
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,3 +1,17 @@
|
||||||
|
From 36e516290611e613aa92996cb4339561452695b4 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Fri, 7 Jul 2017 17:24:23 +0200
|
||||||
|
Subject: net: swconfig: adds openwrt switch layer
|
||||||
|
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
---
|
||||||
|
drivers/net/phy/Kconfig | 83 +++++++++++++++++++++++++++++++++++++++++++++++
|
||||||
|
drivers/net/phy/Makefile | 15 +++++++++
|
||||||
|
include/uapi/linux/Kbuild | 1 +
|
||||||
|
3 files changed, 99 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/drivers/net/phy/Kconfig b/drivers/net/phy/Kconfig
|
||||||
|
index 2651c8d8de2f..a920adb78fea 100644
|
||||||
--- a/drivers/net/phy/Kconfig
|
--- a/drivers/net/phy/Kconfig
|
||||||
+++ b/drivers/net/phy/Kconfig
|
+++ b/drivers/net/phy/Kconfig
|
||||||
@@ -147,6 +147,89 @@ config MDIO_XGENE
|
@@ -147,6 +147,89 @@ config MDIO_XGENE
|
||||||
|
@ -90,6 +104,8 @@
|
||||||
comment "MII PHY device drivers"
|
comment "MII PHY device drivers"
|
||||||
|
|
||||||
config AMD_PHY
|
config AMD_PHY
|
||||||
|
diff --git a/drivers/net/phy/Makefile b/drivers/net/phy/Makefile
|
||||||
|
index e58667d111e7..542b6be8953a 100644
|
||||||
--- a/drivers/net/phy/Makefile
|
--- a/drivers/net/phy/Makefile
|
||||||
+++ b/drivers/net/phy/Makefile
|
+++ b/drivers/net/phy/Makefile
|
||||||
@@ -5,6 +5,21 @@ libphy-$(CONFIG_SWPHY) += swphy.o
|
@@ -5,6 +5,21 @@ libphy-$(CONFIG_SWPHY) += swphy.o
|
||||||
|
@ -114,6 +130,8 @@
|
||||||
obj-$(CONFIG_MDIO_BCM_IPROC) += mdio-bcm-iproc.o
|
obj-$(CONFIG_MDIO_BCM_IPROC) += mdio-bcm-iproc.o
|
||||||
obj-$(CONFIG_MDIO_BCM_UNIMAC) += mdio-bcm-unimac.o
|
obj-$(CONFIG_MDIO_BCM_UNIMAC) += mdio-bcm-unimac.o
|
||||||
obj-$(CONFIG_MDIO_BITBANG) += mdio-bitbang.o
|
obj-$(CONFIG_MDIO_BITBANG) += mdio-bitbang.o
|
||||||
|
diff --git a/include/uapi/linux/Kbuild b/include/uapi/linux/Kbuild
|
||||||
|
index cd2be1c8e9fb..ccdd8d586ab8 100644
|
||||||
--- a/include/uapi/linux/Kbuild
|
--- a/include/uapi/linux/Kbuild
|
||||||
+++ b/include/uapi/linux/Kbuild
|
+++ b/include/uapi/linux/Kbuild
|
||||||
@@ -399,6 +399,7 @@ header-y += stddef.h
|
@@ -399,6 +399,7 @@ header-y += stddef.h
|
||||||
|
@ -124,3 +142,6 @@
|
||||||
header-y += synclink.h
|
header-y += synclink.h
|
||||||
header-y += sync_file.h
|
header-y += sync_file.h
|
||||||
header-y += sysctl.h
|
header-y += sysctl.h
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
|
@ -1,5 +1,22 @@
|
||||||
--- a/include/linux/netdevice.h
|
From ffe387740bbe88dd88bbe04d6375902708003d6e Mon Sep 17 00:00:00 2001
|
||||||
+++ b/include/linux/netdevice.h
|
From: Felix Fietkau <nbd@nbd.name>
|
||||||
|
Date: Fri, 7 Jul 2017 17:25:00 +0200
|
||||||
|
Subject: net: add packet mangeling patch
|
||||||
|
|
||||||
|
Signed-off-by: Felix Fietkau <nbd@nbd.name>
|
||||||
|
---
|
||||||
|
include/linux/netdevice.h | 11 +++++++++++
|
||||||
|
include/linux/skbuff.h | 14 ++++----------
|
||||||
|
net/Kconfig | 6 ++++++
|
||||||
|
net/core/dev.c | 18 ++++++++++++++----
|
||||||
|
net/core/skbuff.c | 17 +++++++++++++++++
|
||||||
|
net/ethernet/eth.c | 6 ++++++
|
||||||
|
6 files changed, 58 insertions(+), 14 deletions(-)
|
||||||
|
|
||||||
|
Index: linux-4.9.34/include/linux/netdevice.h
|
||||||
|
===================================================================
|
||||||
|
--- linux-4.9.34.orig/include/linux/netdevice.h
|
||||||
|
+++ linux-4.9.34/include/linux/netdevice.h
|
||||||
@@ -1398,6 +1398,7 @@ enum netdev_priv_flags {
|
@@ -1398,6 +1398,7 @@ enum netdev_priv_flags {
|
||||||
IFF_RXFH_CONFIGURED = 1<<25,
|
IFF_RXFH_CONFIGURED = 1<<25,
|
||||||
IFF_PHONY_HEADROOM = 1<<26,
|
IFF_PHONY_HEADROOM = 1<<26,
|
||||||
|
@ -39,8 +56,10 @@
|
||||||
/*
|
/*
|
||||||
* Cache lines mostly used on receive path (including eth_type_trans())
|
* Cache lines mostly used on receive path (including eth_type_trans())
|
||||||
*/
|
*/
|
||||||
--- a/include/linux/skbuff.h
|
Index: linux-4.9.34/include/linux/skbuff.h
|
||||||
+++ b/include/linux/skbuff.h
|
===================================================================
|
||||||
|
--- linux-4.9.34.orig/include/linux/skbuff.h
|
||||||
|
+++ linux-4.9.34/include/linux/skbuff.h
|
||||||
@@ -2334,6 +2334,10 @@ static inline int pskb_trim(struct sk_bu
|
@@ -2334,6 +2334,10 @@ static inline int pskb_trim(struct sk_bu
|
||||||
return (len < skb->len) ? __pskb_trim(skb, len) : 0;
|
return (len < skb->len) ? __pskb_trim(skb, len) : 0;
|
||||||
}
|
}
|
||||||
|
@ -69,8 +88,10 @@
|
||||||
static inline struct sk_buff *netdev_alloc_skb_ip_align(struct net_device *dev,
|
static inline struct sk_buff *netdev_alloc_skb_ip_align(struct net_device *dev,
|
||||||
unsigned int length)
|
unsigned int length)
|
||||||
{
|
{
|
||||||
--- a/net/Kconfig
|
Index: linux-4.9.34/net/Kconfig
|
||||||
+++ b/net/Kconfig
|
===================================================================
|
||||||
|
--- linux-4.9.34.orig/net/Kconfig
|
||||||
|
+++ linux-4.9.34/net/Kconfig
|
||||||
@@ -25,6 +25,12 @@ menuconfig NET
|
@@ -25,6 +25,12 @@ menuconfig NET
|
||||||
|
|
||||||
if NET
|
if NET
|
||||||
|
@ -84,9 +105,11 @@
|
||||||
config WANT_COMPAT_NETLINK_MESSAGES
|
config WANT_COMPAT_NETLINK_MESSAGES
|
||||||
bool
|
bool
|
||||||
help
|
help
|
||||||
--- a/net/core/dev.c
|
Index: linux-4.9.34/net/core/dev.c
|
||||||
+++ b/net/core/dev.c
|
===================================================================
|
||||||
@@ -2932,10 +2932,20 @@ static int xmit_one(struct sk_buff *skb,
|
--- linux-4.9.34.orig/net/core/dev.c
|
||||||
|
+++ linux-4.9.34/net/core/dev.c
|
||||||
|
@@ -2931,10 +2931,20 @@ static int xmit_one(struct sk_buff *skb,
|
||||||
if (!list_empty(&ptype_all) || !list_empty(&dev->ptype_all))
|
if (!list_empty(&ptype_all) || !list_empty(&dev->ptype_all))
|
||||||
dev_queue_xmit_nit(skb, dev);
|
dev_queue_xmit_nit(skb, dev);
|
||||||
|
|
||||||
|
@ -111,8 +134,10 @@
|
||||||
|
|
||||||
return rc;
|
return rc;
|
||||||
}
|
}
|
||||||
--- a/net/core/skbuff.c
|
Index: linux-4.9.34/net/core/skbuff.c
|
||||||
+++ b/net/core/skbuff.c
|
===================================================================
|
||||||
|
--- linux-4.9.34.orig/net/core/skbuff.c
|
||||||
|
+++ linux-4.9.34/net/core/skbuff.c
|
||||||
@@ -64,6 +64,7 @@
|
@@ -64,6 +64,7 @@
|
||||||
#include <linux/errqueue.h>
|
#include <linux/errqueue.h>
|
||||||
#include <linux/prefetch.h>
|
#include <linux/prefetch.h>
|
||||||
|
@ -144,8 +169,10 @@
|
||||||
void skb_add_rx_frag(struct sk_buff *skb, int i, struct page *page, int off,
|
void skb_add_rx_frag(struct sk_buff *skb, int i, struct page *page, int off,
|
||||||
int size, unsigned int truesize)
|
int size, unsigned int truesize)
|
||||||
{
|
{
|
||||||
--- a/net/ethernet/eth.c
|
Index: linux-4.9.34/net/ethernet/eth.c
|
||||||
+++ b/net/ethernet/eth.c
|
===================================================================
|
||||||
|
--- linux-4.9.34.orig/net/ethernet/eth.c
|
||||||
|
+++ linux-4.9.34/net/ethernet/eth.c
|
||||||
@@ -171,6 +171,12 @@ __be16 eth_type_trans(struct sk_buff *sk
|
@@ -171,6 +171,12 @@ __be16 eth_type_trans(struct sk_buff *sk
|
||||||
const struct ethhdr *eth;
|
const struct ethhdr *eth;
|
||||||
|
|
|
@ -1,9 +1,33 @@
|
||||||
Register switch connected to srab
|
From 3cb240533ab787899dc7f17aa7d6c5b4810e2e58 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Hauke Mehrtens <hauke@hauke-m.de>
|
||||||
|
Date: Fri, 7 Jul 2017 17:26:01 +0200
|
||||||
|
Subject: bcm53xx: bgmac: use srab switch driver
|
||||||
|
|
||||||
|
use the srab switch driver on these SoCs.
|
||||||
|
|
||||||
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
|
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
|
||||||
|
---
|
||||||
|
drivers/net/ethernet/broadcom/bgmac-bcma.c | 1 +
|
||||||
|
drivers/net/ethernet/broadcom/bgmac.c | 24 ++++++++++++++++++++++++
|
||||||
|
drivers/net/ethernet/broadcom/bgmac.h | 4 ++++
|
||||||
|
3 files changed, 29 insertions(+)
|
||||||
|
|
||||||
--- a/drivers/net/ethernet/broadcom/bgmac.c
|
Index: linux-4.9.34/drivers/net/ethernet/broadcom/bgmac-bcma.c
|
||||||
+++ b/drivers/net/ethernet/broadcom/bgmac.c
|
===================================================================
|
||||||
|
--- linux-4.9.34.orig/drivers/net/ethernet/broadcom/bgmac-bcma.c
|
||||||
|
+++ linux-4.9.34/drivers/net/ethernet/broadcom/bgmac-bcma.c
|
||||||
|
@@ -230,6 +230,7 @@ static int bgmac_probe(struct bcma_devic
|
||||||
|
bgmac->feature_flags |= BGMAC_FEAT_CLKCTLST;
|
||||||
|
bgmac->feature_flags |= BGMAC_FEAT_NO_RESET;
|
||||||
|
bgmac->feature_flags |= BGMAC_FEAT_FORCE_SPEED_2500;
|
||||||
|
+ bgmac->feature_flags |= BGMAC_FEAT_SRAB;
|
||||||
|
break;
|
||||||
|
case BCMA_CHIP_ID_BCM53573:
|
||||||
|
bgmac->feature_flags |= BGMAC_FEAT_CLKCTLST;
|
||||||
|
Index: linux-4.9.34/drivers/net/ethernet/broadcom/bgmac.c
|
||||||
|
===================================================================
|
||||||
|
--- linux-4.9.34.orig/drivers/net/ethernet/broadcom/bgmac.c
|
||||||
|
+++ linux-4.9.34/drivers/net/ethernet/broadcom/bgmac.c
|
||||||
@@ -11,6 +11,7 @@
|
@@ -11,6 +11,7 @@
|
||||||
|
|
||||||
#include <linux/bcma/bcma.h>
|
#include <linux/bcma/bcma.h>
|
||||||
|
@ -56,8 +80,10 @@ Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
|
||||||
unregister_netdev(bgmac->net_dev);
|
unregister_netdev(bgmac->net_dev);
|
||||||
phy_disconnect(bgmac->net_dev->phydev);
|
phy_disconnect(bgmac->net_dev->phydev);
|
||||||
netif_napi_del(&bgmac->napi);
|
netif_napi_del(&bgmac->napi);
|
||||||
--- a/drivers/net/ethernet/broadcom/bgmac.h
|
Index: linux-4.9.34/drivers/net/ethernet/broadcom/bgmac.h
|
||||||
+++ b/drivers/net/ethernet/broadcom/bgmac.h
|
===================================================================
|
||||||
|
--- linux-4.9.34.orig/drivers/net/ethernet/broadcom/bgmac.h
|
||||||
|
+++ linux-4.9.34/drivers/net/ethernet/broadcom/bgmac.h
|
||||||
@@ -409,6 +409,7 @@
|
@@ -409,6 +409,7 @@
|
||||||
#define BGMAC_FEAT_CC4_IF_SW_TYPE BIT(17)
|
#define BGMAC_FEAT_CC4_IF_SW_TYPE BIT(17)
|
||||||
#define BGMAC_FEAT_CC4_IF_SW_TYPE_RGMII BIT(18)
|
#define BGMAC_FEAT_CC4_IF_SW_TYPE_RGMII BIT(18)
|
||||||
|
@ -76,13 +102,3 @@ Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
|
||||||
};
|
};
|
||||||
|
|
||||||
struct bgmac *bgmac_alloc(struct device *dev);
|
struct bgmac *bgmac_alloc(struct device *dev);
|
||||||
--- a/drivers/net/ethernet/broadcom/bgmac-bcma.c
|
|
||||||
+++ b/drivers/net/ethernet/broadcom/bgmac-bcma.c
|
|
||||||
@@ -230,6 +230,7 @@ static int bgmac_probe(struct bcma_devic
|
|
||||||
bgmac->feature_flags |= BGMAC_FEAT_CLKCTLST;
|
|
||||||
bgmac->feature_flags |= BGMAC_FEAT_NO_RESET;
|
|
||||||
bgmac->feature_flags |= BGMAC_FEAT_FORCE_SPEED_2500;
|
|
||||||
+ bgmac->feature_flags |= BGMAC_FEAT_SRAB;
|
|
||||||
break;
|
|
||||||
case BCMA_CHIP_ID_BCM53573:
|
|
||||||
bgmac->feature_flags |= BGMAC_FEAT_CLKCTLST;
|
|
59
target/linux/generic/hack-4.9/835-misc-owl_loader.patch
Normal file
59
target/linux/generic/hack-4.9/835-misc-owl_loader.patch
Normal file
|
@ -0,0 +1,59 @@
|
||||||
|
From dd36f935973d91644449bd9749f6062a2bed821b Mon Sep 17 00:00:00 2001
|
||||||
|
From: Christian Lamparter <chunkeey@googlemail.com>
|
||||||
|
Date: Fri, 7 Jul 2017 17:26:46 +0200
|
||||||
|
Subject: misc: owl-loader for delayed Atheros ath9k fixup
|
||||||
|
|
||||||
|
Some devices (like the Cisco Meraki Z1 Cloud Managed Teleworker Gateway)
|
||||||
|
need to be able to initialize the PCIe wifi device. Normally, this is done
|
||||||
|
during the early stages of booting linux, because the necessary init code
|
||||||
|
is read from the memory mapped SPI and passed to pci_enable_ath9k_fixup.
|
||||||
|
However,this isn't possible for devices which have the init code for the
|
||||||
|
Atheros chip stored on NAND in an UBI volume. Hence, this module can be
|
||||||
|
used to initialze the chip when the user-space is ready to extract the
|
||||||
|
init code.
|
||||||
|
|
||||||
|
Signed-off-by: Martin Blumenstingl <martin.blumenstingl@googlemail.com>
|
||||||
|
Signed-off-by: Christian Lamparter <chunkeey@googlemail.com>
|
||||||
|
---
|
||||||
|
drivers/misc/Kconfig | 12 ++++++++++++
|
||||||
|
drivers/misc/Makefile | 1 +
|
||||||
|
2 files changed, 13 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/drivers/misc/Kconfig b/drivers/misc/Kconfig
|
||||||
|
index 64971baf11fa..50d2eaa75d41 100644
|
||||||
|
--- a/drivers/misc/Kconfig
|
||||||
|
+++ b/drivers/misc/Kconfig
|
||||||
|
@@ -151,6 +151,18 @@ config SGI_IOC4
|
||||||
|
If you have an SGI Altix with an IOC4-based card say Y.
|
||||||
|
Otherwise say N.
|
||||||
|
|
||||||
|
+config OWL_LOADER
|
||||||
|
+ tristate "Owl loader for initializing Atheros PCI(e) Wifi chips"
|
||||||
|
+ depends on PCI
|
||||||
|
+ ---help---
|
||||||
|
+ This kernel module helps to initialize certain Qualcomm
|
||||||
|
+ Atheros' PCI(e) Wifi chips, which have the init data
|
||||||
|
+ (which contains the PCI device ID for example) stored
|
||||||
|
+ together with the calibration data in the file system.
|
||||||
|
+
|
||||||
|
+ This is necessary for devices like the Cisco Meraki Z1, say M.
|
||||||
|
+ Otherwise say N.
|
||||||
|
+
|
||||||
|
config TIFM_CORE
|
||||||
|
tristate "TI Flash Media interface support"
|
||||||
|
depends on PCI
|
||||||
|
diff --git a/drivers/misc/Makefile b/drivers/misc/Makefile
|
||||||
|
index 31983366090a..48c7e74a6e5a 100644
|
||||||
|
--- a/drivers/misc/Makefile
|
||||||
|
+++ b/drivers/misc/Makefile
|
||||||
|
@@ -12,6 +12,7 @@ obj-$(CONFIG_ATMEL_TCLIB) += atmel_tclib.o
|
||||||
|
obj-$(CONFIG_DUMMY_IRQ) += dummy-irq.o
|
||||||
|
obj-$(CONFIG_ICS932S401) += ics932s401.o
|
||||||
|
obj-$(CONFIG_LKDTM) += lkdtm.o
|
||||||
|
+obj-$(CONFIG_OWL_LOADER) += owl-loader.o
|
||||||
|
obj-$(CONFIG_TIFM_CORE) += tifm_core.o
|
||||||
|
obj-$(CONFIG_TIFM_7XX1) += tifm_7xx1.o
|
||||||
|
obj-$(CONFIG_PHANTOM) += phantom.o
|
||||||
|
--
|
||||||
|
2.11.0
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue