From 48372baf14b9631b948d2b97ba65c67d50057968 Mon Sep 17 00:00:00 2001 From: Konstantin Demin Date: Thu, 17 Jul 2025 22:56:59 +0300 Subject: [PATCH] release 6.15.7 --- debian/.gitignore | 1 + debian/changelog | 7 ++ debian/config/amd64/config.cloud | 12 +-- debian/config/amd64/config.mobile | 13 +-- debian/config/amd64/config.vm | 12 +-- debian/config/config | 10 +-- debian/linux-misc-tools.manpages | 2 + ...uilding-ashmem-and-binder-as-modules.patch | 90 ------------------- ...oid-enable-building-binder-as-module.patch | 53 +++++++++++ ...as-mitigation-against-local-exploits.patch | 41 --------- ... => export-symbols-needed-by-binder.patch} | 47 +++++++--- ...211-mark-copy_mesh_setup-as-noinline.patch | 2 +- .../binder/0001-binder-turn-into-module.patch | 2 +- ...-rq_affinity-to-force-complete-I-O-r.patch | 2 +- debian/patches/series | 5 +- debian/rules.d/tools/bootconfig/Makefile | 22 +++++ debian/rules.d/tools/firmware/Makefile | 5 ++ debian/rules.d/tools/thermal/Makefile | 43 +++++++++ debian/rules.real | 12 +++ debian/templates/tools-unversioned.control.in | 21 +++++ 20 files changed, 212 insertions(+), 190 deletions(-) create mode 100644 debian/linux-misc-tools.manpages delete mode 100644 debian/patches/debian/android-enable-building-ashmem-and-binder-as-modules.patch create mode 100644 debian/patches/debian/android-enable-building-binder-as-module.patch delete mode 100644 debian/patches/debian/dccp-disable-auto-loading-as-mitigation-against-local-exploits.patch rename debian/patches/debian/{export-symbols-needed-by-android-drivers.patch => export-symbols-needed-by-binder.patch} (75%) create mode 100644 debian/rules.d/tools/bootconfig/Makefile create mode 100644 debian/rules.d/tools/firmware/Makefile create mode 100644 debian/rules.d/tools/thermal/Makefile diff --git a/debian/.gitignore b/debian/.gitignore index c2abf73..0dd9736 100644 --- a/debian/.gitignore +++ b/debian/.gitignore @@ -27,6 +27,7 @@ /rules.gen !/linux-bpf-dev.* !/linux-cpupower.* +!/linux-misc-tools.* !/linux-perf.* # Ignore compiled Python files diff --git a/debian/changelog b/debian/changelog index 1dbb293..4028aa1 100644 --- a/debian/changelog +++ b/debian/changelog @@ -1,3 +1,10 @@ +linux (6.15.7-1) sid; urgency=medium + + * New upstream stable update: + https://www.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.15.7 + + -- Konstantin Demin Thu, 17 Jul 2025 22:21:12 +0300 + linux (6.15.6-1) sid; urgency=medium * New upstream stable update: diff --git a/debian/config/amd64/config.cloud b/debian/config/amd64/config.cloud index dcd1762..8637db7 100644 --- a/debian/config/amd64/config.cloud +++ b/debian/config/amd64/config.cloud @@ -2135,17 +2135,6 @@ CONFIG_MAX_SKB_FRAGS=19 ## # CONFIG_CAN is not set -## -## file: net/dccp/Kconfig -## -# CONFIG_IP_DCCP_DEBUG is not set - -## -## file: net/dccp/ccids/Kconfig -## -# CONFIG_IP_DCCP_CCID2_DEBUG is not set -# CONFIG_IP_DCCP_CCID3_DEBUG is not set - ## ## file: net/ieee802154/Kconfig ## @@ -2370,6 +2359,7 @@ CONFIG_IP_VS_PROTO_AH_ESP=y CONFIG_KEXEC_CORE=y CONFIG_LZ4HC_COMPRESS=m CONFIG_LZ4_COMPRESS=m +# CONFIG_MDIO_BUS is not set CONFIG_MFD_CORE=m CONFIG_ND_BTT=m CONFIG_ND_PFN=m diff --git a/debian/config/amd64/config.mobile b/debian/config/amd64/config.mobile index d35a050..2ea4af7 100644 --- a/debian/config/amd64/config.mobile +++ b/debian/config/amd64/config.mobile @@ -7626,17 +7626,6 @@ CONFIG_CAN_ISOTP=m ## CONFIG_CAN_J1939=m -## -## file: net/dccp/Kconfig -## -CONFIG_IP_DCCP_DEBUG=y - -## -## file: net/dccp/ccids/Kconfig -## -CONFIG_IP_DCCP_CCID2_DEBUG=y -CONFIG_IP_DCCP_CCID3_DEBUG=y - ## ## file: net/ieee802154/Kconfig ## @@ -8803,7 +8792,6 @@ CONFIG_IOMMUFD_DRIVER_CORE=y CONFIG_IOMMU_HELPER=y CONFIG_IPMI_DMI_DECODE=y CONFIG_IPMI_PLAT_DATA=y -CONFIG_IP_DCCP_TFRC_DEBUG=y CONFIG_IRQCHIP=y CONFIG_IRQ_SIM=y CONFIG_ISA_BUS_API=y @@ -8829,6 +8817,7 @@ CONFIG_MADERA_IRQ=m CONFIG_MAPPING_DIRTY_HELPERS=y CONFIG_MCTP_FLOWS=y CONFIG_MDIO=m +CONFIG_MDIO_BUS=m CONFIG_MDIO_BUS_MUX=m CONFIG_MDIO_CAVIUM=m CONFIG_MDIO_I2C=m diff --git a/debian/config/amd64/config.vm b/debian/config/amd64/config.vm index a37a7df..b874085 100644 --- a/debian/config/amd64/config.vm +++ b/debian/config/amd64/config.vm @@ -3656,17 +3656,6 @@ CONFIG_NET_9P_RDMA=m ## # CONFIG_CAN is not set -## -## file: net/dccp/Kconfig -## -# CONFIG_IP_DCCP_DEBUG is not set - -## -## file: net/dccp/ccids/Kconfig -## -# CONFIG_IP_DCCP_CCID2_DEBUG is not set -# CONFIG_IP_DCCP_CCID3_DEBUG is not set - ## ## file: net/ieee802154/Kconfig ## @@ -3967,6 +3956,7 @@ CONFIG_LZ4HC_COMPRESS=m CONFIG_LZ4_COMPRESS=m CONFIG_MAPPING_DIRTY_HELPERS=y CONFIG_MCTP_FLOWS=y +CONFIG_MDIO_BUS=m CONFIG_MFD_CORE=m CONFIG_MOUSE_PS2_SMBUS=y CONFIG_ND_BTT=m diff --git a/debian/config/config b/debian/config/config index bcced84..95a68ee 100644 --- a/debian/config/config +++ b/debian/config/config @@ -2766,12 +2766,7 @@ CONFIG_CEPH_LIB=m ## ## file: net/dccp/Kconfig ## -CONFIG_IP_DCCP=m - -## -## file: net/dccp/ccids/Kconfig -## -CONFIG_IP_DCCP_CCID3=y +# CONFIG_IP_DCCP is not set ## ## file: net/dns_resolver/Kconfig @@ -4012,7 +4007,6 @@ CONFIG_ILLEGAL_POINTER_VALUE=0xdead000000000000 # CONFIG_IMA_SECURE_AND_OR_TRUSTED_BOOT is not set CONFIG_INET6_TUNNEL=m CONFIG_INET6_XFRM_TUNNEL=m -CONFIG_INET_DCCP_DIAG=m CONFIG_INET_MPTCP_DIAG=y CONFIG_INET_SCTP_DIAG=m CONFIG_INET_TCP_DIAG=y @@ -4040,7 +4034,6 @@ CONFIG_IPV6_FOU_TUNNEL=m CONFIG_IPV6_NDISC_NODETYPE=y CONFIG_IPV6_SEG6_BPF=y CONFIG_IPVLAN_L3S=y -CONFIG_IP_DCCP_TFRC_LIB=y CONFIG_IP_MROUTE_COMMON=y CONFIG_IP_ROUTE_CLASSID=y CONFIG_IRQ_BYPASS_MANAGER=m @@ -4088,7 +4081,6 @@ CONFIG_LRU_GEN_WALKS_MMU=y CONFIG_LZ4_DECOMPRESS=y CONFIG_LZO_COMPRESS=y CONFIG_LZO_DECOMPRESS=y -CONFIG_MDIO_BUS=m CONFIG_MDIO_DEVRES=m CONFIG_MEMORY_BALLOON=y CONFIG_MEMORY_ISOLATION=y diff --git a/debian/linux-misc-tools.manpages b/debian/linux-misc-tools.manpages new file mode 100644 index 0000000..6a3e00c --- /dev/null +++ b/debian/linux-misc-tools.manpages @@ -0,0 +1,2 @@ +tools/thermal/thermometer/thermometer.8 +tools/thermal/tmon/tmon.8 diff --git a/debian/patches/debian/android-enable-building-ashmem-and-binder-as-modules.patch b/debian/patches/debian/android-enable-building-ashmem-and-binder-as-modules.patch deleted file mode 100644 index f45877b..0000000 --- a/debian/patches/debian/android-enable-building-ashmem-and-binder-as-modules.patch +++ /dev/null @@ -1,90 +0,0 @@ -From: Ben Hutchings -Date: Fri, 22 Jun 2018 17:27:00 +0100 -Subject: android: Enable building ashmem and binder as modules -Bug-Debian: https://bugs.debian.org/901492 - -We want to enable use of the Android ashmem and binder drivers to -support Anbox, but they should not be built-in as that would waste -resources and increase security attack surface on systems that don't -need them. - -- Add a MODULE_LICENSE declaration to ashmem -- Change the Makefiles to build each driver as an object with the - "_linux" suffix (which is what Anbox expects) -- Change config symbol types to tristate - -Update: -In upstream commit 721412ed3d titled "staging: remove ashmem" the ashmem -driver was removed entirely. Secondary commit message: -"The mainline replacement for ashmem is memfd, so remove the legacy -code from drivers/staging/" -Consequently, the ashmem part of this patch has been removed. ---- - drivers/android/Kconfig | 2 +- - drivers/android/Makefile | 7 ++++--- - drivers/android/binder_alloc.c | 2 +- - 3 files changed, 6 insertions(+), 5 deletions(-) - ---- a/drivers/android/Kconfig -+++ b/drivers/android/Kconfig -@@ -2,7 +2,7 @@ - menu "Android" - - config ANDROID_BINDER_IPC -- bool "Android Binder IPC Driver" -+ tristate "Android Binder IPC Driver" - depends on MMU - default n - help ---- a/drivers/android/Makefile -+++ b/drivers/android/Makefile -@@ -1,6 +1,7 @@ - # SPDX-License-Identifier: GPL-2.0-only - ccflags-y += -I$(src) # needed for trace events - --obj-$(CONFIG_ANDROID_BINDERFS) += binderfs.o --obj-$(CONFIG_ANDROID_BINDER_IPC) += binder.o binder_alloc.o --obj-$(CONFIG_ANDROID_BINDER_IPC_SELFTEST) += binder_alloc_selftest.o -+obj-$(CONFIG_ANDROID_BINDER_IPC) += binder_linux.o -+binder_linux-y := binder.o binder_alloc.o -+binder_linux-$(CONFIG_ANDROID_BINDERFS) += binderfs.o -+binder_linux-$(CONFIG_ANDROID_BINDER_IPC_SELFTEST) += binder_alloc_selftest.o ---- a/drivers/android/binder_alloc.c -+++ b/drivers/android/binder_alloc.c -@@ -38,7 +38,7 @@ enum { - }; - static uint32_t binder_alloc_debug_mask = BINDER_DEBUG_USER_ERROR; - --module_param_named(debug_mask, binder_alloc_debug_mask, -+module_param_named(alloc_debug_mask, binder_alloc_debug_mask, - uint, 0644); - - #define binder_alloc_debug(mask, x...) \ ---- a/mm/list_lru.c -+++ b/mm/list_lru.c -@@ -175,6 +175,7 @@ bool list_lru_add(struct list_lru *lru, - unlock_list_lru(l, false); - return false; - } -+EXPORT_SYMBOL_GPL(list_lru_add); - - bool list_lru_add_obj(struct list_lru *lru, struct list_head *item) - { -@@ -212,6 +213,7 @@ bool list_lru_del(struct list_lru *lru, - unlock_list_lru(l, false); - return false; - } -+EXPORT_SYMBOL_GPL(list_lru_del); - - bool list_lru_del_obj(struct list_lru *lru, struct list_head *item) - { ---- a/mm/memory.c -+++ b/mm/memory.c -@@ -6569,6 +6569,7 @@ inval: - count_vm_vma_lock_event(VMA_LOCK_ABORT); - return NULL; - } -+EXPORT_SYMBOL_GPL(lock_vma_under_rcu); - #endif /* CONFIG_PER_VMA_LOCK */ - - #ifndef __PAGETABLE_P4D_FOLDED diff --git a/debian/patches/debian/android-enable-building-binder-as-module.patch b/debian/patches/debian/android-enable-building-binder-as-module.patch new file mode 100644 index 0000000..128a956 --- /dev/null +++ b/debian/patches/debian/android-enable-building-binder-as-module.patch @@ -0,0 +1,53 @@ +From: Ben Hutchings +Date: Tue, 08 Jul 2025 13:30:55 +0200 +Subject: android: Enable building binder as module +Bug-Debian: https://bugs.debian.org/901492 + +We want to enable use of the Android binder driver to support +Waydroid, but it should not be built-in as that would waste resources +and increase security attack surface on systems that don't need it. + +- Change the Makefiles to build the driver as an object with the + "_linux" suffix (which is what Waydroid expects) +- Change config symbol types to tristate +--- + drivers/android/Kconfig | 2 +- + drivers/android/Makefile | 7 ++++--- + drivers/android/binder_alloc.c | 2 +- + 3 files changed, 6 insertions(+), 5 deletions(-) + +--- a/drivers/android/Kconfig ++++ b/drivers/android/Kconfig +@@ -2,7 +2,7 @@ + menu "Android" + + config ANDROID_BINDER_IPC +- bool "Android Binder IPC Driver" ++ tristate "Android Binder IPC Driver" + depends on MMU + default n + help +--- a/drivers/android/Makefile ++++ b/drivers/android/Makefile +@@ -1,6 +1,7 @@ + # SPDX-License-Identifier: GPL-2.0-only + ccflags-y += -I$(src) # needed for trace events + +-obj-$(CONFIG_ANDROID_BINDERFS) += binderfs.o +-obj-$(CONFIG_ANDROID_BINDER_IPC) += binder.o binder_alloc.o +-obj-$(CONFIG_ANDROID_BINDER_IPC_SELFTEST) += binder_alloc_selftest.o ++obj-$(CONFIG_ANDROID_BINDER_IPC) += binder_linux.o ++binder_linux-y := binder.o binder_alloc.o ++binder_linux-$(CONFIG_ANDROID_BINDERFS) += binderfs.o ++binder_linux-$(CONFIG_ANDROID_BINDER_IPC_SELFTEST) += binder_alloc_selftest.o +--- a/drivers/android/binder_alloc.c ++++ b/drivers/android/binder_alloc.c +@@ -38,7 +38,7 @@ enum { + }; + static uint32_t binder_alloc_debug_mask = BINDER_DEBUG_USER_ERROR; + +-module_param_named(debug_mask, binder_alloc_debug_mask, ++module_param_named(alloc_debug_mask, binder_alloc_debug_mask, + uint, 0644); + + #define binder_alloc_debug(mask, x...) \ diff --git a/debian/patches/debian/dccp-disable-auto-loading-as-mitigation-against-local-exploits.patch b/debian/patches/debian/dccp-disable-auto-loading-as-mitigation-against-local-exploits.patch deleted file mode 100644 index 48b11e6..0000000 --- a/debian/patches/debian/dccp-disable-auto-loading-as-mitigation-against-local-exploits.patch +++ /dev/null @@ -1,41 +0,0 @@ -From: Ben Hutchings -Date: Thu, 16 Feb 2017 19:09:17 +0000 -Subject: dccp: Disable auto-loading as mitigation against local exploits -Forwarded: not-needed - -We can mitigate the effect of vulnerabilities in obscure protocols by -preventing unprivileged users from loading the modules, so that they -are only exploitable on systems where the administrator has chosen to -load the protocol. - -The 'dccp' protocol is not actively maintained or widely used. -Therefore disable auto-loading. - -Signed-off-by: Ben Hutchings ---- ---- a/net/dccp/ipv4.c -+++ b/net/dccp/ipv4.c -@@ -1094,8 +1094,8 @@ module_exit(dccp_v4_exit); - * values directly, Also cover the case where the protocol is not specified, - * i.e. net-pf-PF_INET-proto-0-type-SOCK_DCCP - */ --MODULE_ALIAS_NET_PF_PROTO_TYPE(PF_INET, 33, 6); --MODULE_ALIAS_NET_PF_PROTO_TYPE(PF_INET, 0, 6); -+/* MODULE_ALIAS_NET_PF_PROTO_TYPE(PF_INET, 33, 6); */ -+/* MODULE_ALIAS_NET_PF_PROTO_TYPE(PF_INET, 0, 6); */ - MODULE_LICENSE("GPL"); - MODULE_AUTHOR("Arnaldo Carvalho de Melo "); - MODULE_DESCRIPTION("DCCP - Datagram Congestion Controlled Protocol"); ---- a/net/dccp/ipv6.c -+++ b/net/dccp/ipv6.c -@@ -1167,8 +1167,8 @@ module_exit(dccp_v6_exit); - * values directly, Also cover the case where the protocol is not specified, - * i.e. net-pf-PF_INET6-proto-0-type-SOCK_DCCP - */ --MODULE_ALIAS_NET_PF_PROTO_TYPE(PF_INET6, 33, 6); --MODULE_ALIAS_NET_PF_PROTO_TYPE(PF_INET6, 0, 6); -+/* MODULE_ALIAS_NET_PF_PROTO_TYPE(PF_INET6, 33, 6); */ -+/* MODULE_ALIAS_NET_PF_PROTO_TYPE(PF_INET6, 0, 6); */ - MODULE_LICENSE("GPL"); - MODULE_AUTHOR("Arnaldo Carvalho de Melo "); - MODULE_DESCRIPTION("DCCPv6 - Datagram Congestion Controlled Protocol"); diff --git a/debian/patches/debian/export-symbols-needed-by-android-drivers.patch b/debian/patches/debian/export-symbols-needed-by-binder.patch similarity index 75% rename from debian/patches/debian/export-symbols-needed-by-android-drivers.patch rename to debian/patches/debian/export-symbols-needed-by-binder.patch index 68de285..f655a7b 100644 --- a/debian/patches/debian/export-symbols-needed-by-android-drivers.patch +++ b/debian/patches/debian/export-symbols-needed-by-binder.patch @@ -1,5 +1,5 @@ From: Ben Hutchings -Date: Mon, 05 Aug 2024 03:26:48 +0200 +Date: Tue, 08 Jul 2025 13:32:21 +0200 Subject: Export symbols needed by binder Bug-Debian: https://bugs.debian.org/901492 @@ -10,15 +10,16 @@ and increase security attack surface on systems that don't need it. Export the currently un-exported symbols it depends on. --- - fs/file.c | 1 + - ipc/msgutil.c | 1 + - ipc/namespace.c | 1 + - kernel/sched/syscalls.c | 1 + - kernel/sched/wait.c | 1 + - kernel/task_work.c | 1 + - mm/memory.c | 1 + - security/security.c | 4 ++++ - 8 files changed, 11 insertions(+) + fs/file.c | 1 + + ipc/msgutil.c | 1 + + ipc/namespace.c | 1 + + kernel/sched/syscalls.c | 1 + + kernel/sched/wait.c | 1 + + kernel/task_work.c | 1 + + mm/list_lru.c | 2 ++ + mm/memory.c | 2 ++ + security/security.c | 4 ++++ + 9 files changed, 14 insertions(+) --- a/fs/file.c +++ b/fs/file.c @@ -80,6 +81,24 @@ Export the currently un-exported symbols it depends on. /** * task_work_cancel_match - cancel a pending work added by task_work_add() +--- a/mm/list_lru.c ++++ b/mm/list_lru.c +@@ -175,6 +175,7 @@ bool list_lru_add(struct list_lru *lru, + unlock_list_lru(l, false); + return false; + } ++EXPORT_SYMBOL_GPL(list_lru_add); + + bool list_lru_add_obj(struct list_lru *lru, struct list_head *item) + { +@@ -212,6 +213,7 @@ bool list_lru_del(struct list_lru *lru, + unlock_list_lru(l, false); + return false; + } ++EXPORT_SYMBOL_GPL(list_lru_del); + + bool list_lru_del_obj(struct list_lru *lru, struct list_head *item) + { --- a/mm/memory.c +++ b/mm/memory.c @@ -2020,6 +2020,7 @@ void zap_page_range_single(struct vm_are @@ -90,6 +109,14 @@ Export the currently un-exported symbols it depends on. /** * zap_vma_ptes - remove ptes mapping the vma +@@ -6568,6 +6569,7 @@ inval: + count_vm_vma_lock_event(VMA_LOCK_ABORT); + return NULL; + } ++EXPORT_SYMBOL_GPL(lock_vma_under_rcu); + #endif /* CONFIG_PER_VMA_LOCK */ + + #ifndef __PAGETABLE_P4D_FOLDED --- a/security/security.c +++ b/security/security.c @@ -996,6 +996,7 @@ int security_binder_set_context_mgr(cons diff --git a/debian/patches/patchset-pf/kbuild/0002-wifi-mac80211-mark-copy_mesh_setup-as-noinline.patch b/debian/patches/patchset-pf/kbuild/0002-wifi-mac80211-mark-copy_mesh_setup-as-noinline.patch index e4f798d..83e9064 100644 --- a/debian/patches/patchset-pf/kbuild/0002-wifi-mac80211-mark-copy_mesh_setup-as-noinline.patch +++ b/debian/patches/patchset-pf/kbuild/0002-wifi-mac80211-mark-copy_mesh_setup-as-noinline.patch @@ -24,7 +24,7 @@ Signed-off-by: Oleksandr Natalenko --- a/net/mac80211/cfg.c +++ b/net/mac80211/cfg.c -@@ -2501,7 +2501,7 @@ static inline bool _chg_mesh_attr(enum n +@@ -2515,7 +2515,7 @@ static inline bool _chg_mesh_attr(enum n return (mask >> (parm-1)) & 0x1; } diff --git a/debian/patches/patchset-xanmod/binder/0001-binder-turn-into-module.patch b/debian/patches/patchset-xanmod/binder/0001-binder-turn-into-module.patch index 8759d86..30ad1e7 100644 --- a/debian/patches/patchset-xanmod/binder/0001-binder-turn-into-module.patch +++ b/debian/patches/patchset-xanmod/binder/0001-binder-turn-into-module.patch @@ -185,7 +185,7 @@ Signed-off-by: Alexandre Frade return container_of(ns, struct ipc_namespace, ns); --- a/mm/vmalloc.c +++ b/mm/vmalloc.c -@@ -3182,6 +3182,7 @@ struct vm_struct *get_vm_area(unsigned l +@@ -3190,6 +3190,7 @@ struct vm_struct *get_vm_area(unsigned l NUMA_NO_NODE, GFP_KERNEL, __builtin_return_address(0)); } diff --git a/debian/patches/patchset-xanmod/xanmod/0007-XANMOD-block-Set-rq_affinity-to-force-complete-I-O-r.patch b/debian/patches/patchset-xanmod/xanmod/0007-XANMOD-block-Set-rq_affinity-to-force-complete-I-O-r.patch index 7ce12cd..7c8dbcd 100644 --- a/debian/patches/patchset-xanmod/xanmod/0007-XANMOD-block-Set-rq_affinity-to-force-complete-I-O-r.patch +++ b/debian/patches/patchset-xanmod/xanmod/0007-XANMOD-block-Set-rq_affinity-to-force-complete-I-O-r.patch @@ -11,7 +11,7 @@ Signed-off-by: Alexandre Frade --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h -@@ -647,7 +647,8 @@ enum { +@@ -652,7 +652,8 @@ enum { QUEUE_FLAG_MAX }; diff --git a/debian/patches/series b/debian/patches/series index 74b4505..e6ab81d 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -14,8 +14,8 @@ debian/arch-sh4-fix-uimage-build.patch debian/tools-perf-perf-read-vdso-in-libexec.patch debian/tools-perf-install-python-bindings.patch debian/wireless-add-debian-wireless-regdb-certificates.patch -debian/export-symbols-needed-by-android-drivers.patch -debian/android-enable-building-ashmem-and-binder-as-modules.patch +debian/export-symbols-needed-by-binder.patch +debian/android-enable-building-binder-as-module.patch debian/documentation-drop-sphinx-version-check.patch debian/perf-traceevent-support-asciidoctor-for-documentatio.patch debian/kbuild-look-for-module.lds-under-arch-directory-too.patch @@ -34,7 +34,6 @@ bugfix/all/radeon-amdgpu-firmware-is-required-for-drm-and-kms-on-r600-onward.pat # Change some defaults for security reasons debian/af_802154-Disable-auto-loading-as-mitigation-against.patch debian/rds-Disable-auto-loading-as-mitigation-against-local.patch -debian/dccp-disable-auto-loading-as-mitigation-against-local-exploits.patch debian/hamradio-disable-auto-loading-as-mitigation-against-local-exploits.patch debian/fs-enable-link-security-restrictions-by-default.patch diff --git a/debian/rules.d/tools/bootconfig/Makefile b/debian/rules.d/tools/bootconfig/Makefile new file mode 100644 index 0000000..76a9aa5 --- /dev/null +++ b/debian/rules.d/tools/bootconfig/Makefile @@ -0,0 +1,22 @@ +include $(top_rulesdir)/Makefile.inc + +# bootconfig does not support appending user CFLAGS or LDFLAGS, +# so we have to specify the include directory too. +MAKE_BOOTCONFIG := $(MAKE) -C $(top_srcdir)/tools/bootconfig \ + O=$(CURDIR) \ + CFLAGS='$(CFLAGS) $(CPPFLAGS) -Iinclude $(LDFLAGS)' + +# Default target (all) includes running tests. If this is not wanted +# (e.g. for cross-builds), build the bootconfig target instead. +ifeq ($(filter nocheck,$(DEB_BUILD_OPTIONS)),) +BUILD_TARGET := all +else +BUILD_TARGET := $(CURDIR)/bootconfig +endif + +all: + $(MAKE_BOOTCONFIG) $(BUILD_TARGET) + +install: + mkdir -p $(DESTDIR)/usr/bin + $(MAKE_BOOTCONFIG) install diff --git a/debian/rules.d/tools/firmware/Makefile b/debian/rules.d/tools/firmware/Makefile new file mode 100644 index 0000000..dd80540 --- /dev/null +++ b/debian/rules.d/tools/firmware/Makefile @@ -0,0 +1,5 @@ +PROGS = ihex2fw + +installdir = /usr/bin + +include $(top_rulesdir)/Makefile.inc diff --git a/debian/rules.d/tools/thermal/Makefile b/debian/rules.d/tools/thermal/Makefile new file mode 100644 index 0000000..97208da --- /dev/null +++ b/debian/rules.d/tools/thermal/Makefile @@ -0,0 +1,43 @@ +srcdir := $(top_srcdir)/tools/thermal + +include $(top_rulesdir)/Makefile.inc + +MAKE_THERMAL_LIB = $(MAKE) -C $(srcdir)/lib \ + O=$(CURDIR)/lib \ + EXTRA_CFLAGS='$(CFLAGS) $(CPPFLAGS)' \ + LDFLAGS='$(LDFLAGS)' \ + SRCARCH=$(ARCH) \ + V=1 + +# thermometer does not support OOT build, so we copy the +# source before building. +# thermometer does not support appending user CFLAGS or LDFLAGS, +# so we have to specify the include directory and libraries too. +# Use the static libthermal_tools so we don't have to support it +# as a shared library. +MAKE_THERMOMETER = $(MAKE) -C thermometer \ + CC='$(CC)' CFLAGS='$(CFLAGS) $(CPPFLAGS) -I$(srcdir)/lib' \ + LD='$(CROSS_COMPILE)-ld' LDFLAGS='$(LDFLAGS) $(CURDIR)/lib/libthermal_tools.a -lconfig' + +# tmon does not support OOT build, so we copy the source before +# building. Use the make -I option to allow it to include other +# Makefiles in the source tree. +# tmon expects us to set INSTALL_ROOT instead of DESTDIR (?!). +MAKE_TMON = $(MAKE) -C tmon -I $(srcdir)/tmon \ + INSTALL_ROOT=$(DESTDIR) \ + CC='$(CC)' CFLAGS='$(CFLAGS) $(CPPFLAGS)' \ + LDFLAGS='$(LDFLAGS)' + +all: + mkdir -p lib + rsync -a $(srcdir)/thermometer $(srcdir)/tmon . +# We do not want a shared library, and the shared library link does +# not include LDFLAGS so blhc will complain about it + $(MAKE_THERMAL_LIB) fixdep + $(MAKE_THERMAL_LIB) $(CURDIR)/lib/libthermal_tools.a + $(MAKE_THERMOMETER) + $(MAKE_TMON) + +install: + install -D -m755 thermometer/thermometer $(DESTDIR)/usr/bin/ + $(MAKE_TMON) install diff --git a/debian/rules.real b/debian/rules.real index 479b46b..f3ad273 100644 --- a/debian/rules.real +++ b/debian/rules.real @@ -546,6 +546,18 @@ binary_sdsi: build_sdsi $(call make-tools,tools/arch/x86/intel_sdsi) install $(dh_binary_post) +build_misc-tools: $(STAMPS_DIR)/build-tools-headers + $(call make-tools,tools/bootconfig) + $(call make-tools,tools/firmware) + $(call make-tools,tools/thermal) + +binary_misc-tools: build_misc-tools + $(dh_binary_pre) + $(call make-tools,tools/bootconfig) install + $(call make-tools,tools/firmware) install + $(call make-tools,tools/thermal) install + $(dh_binary_post) + setup_%: @: diff --git a/debian/templates/tools-unversioned.control.in b/debian/templates/tools-unversioned.control.in index 168f696..c38c774 100644 --- a/debian/templates/tools-unversioned.control.in +++ b/debian/templates/tools-unversioned.control.in @@ -166,3 +166,24 @@ Description: Intel On Demand (SDSi) provisioning tool . intel_sdsi allows the configuration of additional CPU features through a license activation process. + +Package: linux-misc-tools +Meta-Rules-Target: misc-tools +Build-Profiles: +Architecture: linux-any +Build-Depends: +# thermometer + libconfig-dev, +# tmon + libncurses-dev, +# debian/rules.d/tools/thermal + rsync, +Depends: ${shlibs:Depends}, ${misc:Depends} +Section: admin +Description: miscellaneous tools from the Linux source tree + This package provides the commands: + . + * bootconfig: Manipulate boot config blobs in initramfs images + * ihex2fw: Convert object files from Intel hex format to binary format + * thermometer: Create profile of thermal zones + * tmon: Monitor and test thermal management