Skip to content

Commit 0bfc78e

Browse files
update arch patchset
1 parent 38625c3 commit 0bfc78e

9 files changed

+221
-75
lines changed

linux/0001-ZEN-Add-sysctl-and-CONFIG-to-disallow-unprivileged-C.patch

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
From 08fe90ab87115393074127f17be88ff9bfcf304a Mon Sep 17 00:00:00 2001
1+
From 63373079bd756247f2ea9e3b22baef0b67cfb7dd Mon Sep 17 00:00:00 2001
22
From: "Jan Alexander Steffens (heftig)" <jan.steffens@gmail.com>
33
Date: Mon, 16 Sep 2019 04:53:20 +0200
4-
Subject: [PATCH 1/4] ZEN: Add sysctl and CONFIG to disallow unprivileged
4+
Subject: [PATCH 1/7] ZEN: Add sysctl and CONFIG to disallow unprivileged
55
CLONE_NEWUSER
66

77
Our default behavior continues to match the vanilla kernel.
@@ -14,7 +14,7 @@ Our default behavior continues to match the vanilla kernel.
1414
5 files changed, 53 insertions(+)
1515

1616
diff --git a/include/linux/user_namespace.h b/include/linux/user_namespace.h
17-
index 45f09bec02c4..87b20e2ee274 100644
17+
index 45f09bec02c48..87b20e2ee2744 100644
1818
--- a/include/linux/user_namespace.h
1919
+++ b/include/linux/user_namespace.h
2020
@@ -148,6 +148,8 @@ static inline void set_userns_rlimit_max(struct user_namespace *ns,
@@ -36,7 +36,7 @@ index 45f09bec02c4..87b20e2ee274 100644
3636
{
3737
return &init_user_ns;
3838
diff --git a/init/Kconfig b/init/Kconfig
39-
index 32c24950c4ce..f17ef1360063 100644
39+
index 32c24950c4ced..f17ef13600635 100644
4040
--- a/init/Kconfig
4141
+++ b/init/Kconfig
4242
@@ -1225,6 +1225,22 @@ config USER_NS
@@ -63,7 +63,7 @@ index 32c24950c4ce..f17ef1360063 100644
6363
bool "PID Namespaces"
6464
default y
6565
diff --git a/kernel/fork.c b/kernel/fork.c
66-
index 41c964104b58..915ad6dae416 100644
66+
index 8103ffd217e97..f405763e06ae9 100644
6767
--- a/kernel/fork.c
6868
+++ b/kernel/fork.c
6969
@@ -100,6 +100,10 @@
@@ -77,7 +77,7 @@ index 41c964104b58..915ad6dae416 100644
7777
#include <asm/pgalloc.h>
7878
#include <linux/uaccess.h>
7979
#include <asm/mmu_context.h>
80-
@@ -2266,6 +2270,10 @@ __latent_entropy struct task_struct *copy_process(
80+
@@ -2267,6 +2271,10 @@ __latent_entropy struct task_struct *copy_process(
8181
if ((clone_flags & (CLONE_NEWUSER|CLONE_FS)) == (CLONE_NEWUSER|CLONE_FS))
8282
return ERR_PTR(-EINVAL);
8383

@@ -88,7 +88,7 @@ index 41c964104b58..915ad6dae416 100644
8888
/*
8989
* Thread groups must share signals as well, and detached threads
9090
* can only be started up within the thread group.
91-
@@ -3419,6 +3427,12 @@ int ksys_unshare(unsigned long unshare_flags)
91+
@@ -3420,6 +3428,12 @@ int ksys_unshare(unsigned long unshare_flags)
9292
if (unshare_flags & CLONE_NEWNS)
9393
unshare_flags |= CLONE_FS;
9494

@@ -102,7 +102,7 @@ index 41c964104b58..915ad6dae416 100644
102102
if (err)
103103
goto bad_unshare_out;
104104
diff --git a/kernel/sysctl.c b/kernel/sysctl.c
105-
index bfe53e835524..c64fa2b70a78 100644
105+
index bfe53e8355245..c64fa2b70a78d 100644
106106
--- a/kernel/sysctl.c
107107
+++ b/kernel/sysctl.c
108108
@@ -80,6 +80,9 @@
@@ -132,7 +132,7 @@ index bfe53e835524..c64fa2b70a78 100644
132132
{
133133
.procname = "tainted",
134134
diff --git a/kernel/user_namespace.c b/kernel/user_namespace.c
135-
index 1d8e47bed3f1..fec01d016a35 100644
135+
index 1d8e47bed3f11..fec01d016a351 100644
136136
--- a/kernel/user_namespace.c
137137
+++ b/kernel/user_namespace.c
138138
@@ -22,6 +22,13 @@

linux/0001-netfilter-nf_tables-unbind-non-anonymous-set-if-rule.patch

Lines changed: 0 additions & 30 deletions
This file was deleted.

linux/0002-netfilter-nf_tables-unbind-non-anonymous-set-if-rule.patch

Lines changed: 0 additions & 33 deletions
This file was deleted.
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
From 069e524939a815a637e923d4063e4b0e0f52ea13 Mon Sep 17 00:00:00 2001
2+
From: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
3+
Date: Wed, 17 May 2023 15:29:31 +0300
4+
Subject: [PATCH 2/7] tpm: tpm_tis: Disable interrupts *only* for AEON UPX-i11
5+
6+
Further restrict with DMI_PRODUCT_VERSION.
7+
8+
Cc: stable@vger.kernel.org # v6.4+
9+
Link: https://lore.kernel.org/linux-integrity/20230517122931.22385-1-peter.ujfalusi@linux.intel.com/
10+
Fixes: 95a9359ee22f ("tpm: tpm_tis: Disable interrupts for AEON UPX-i11")
11+
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
12+
Reviewed-by: Jarkko Sakkinen <jarkko@kernel.org>
13+
Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
14+
---
15+
drivers/char/tpm/tpm_tis.c | 1 +
16+
1 file changed, 1 insertion(+)
17+
18+
diff --git a/drivers/char/tpm/tpm_tis.c b/drivers/char/tpm/tpm_tis.c
19+
index 7db3593941eaa..9cb4e81fc5486 100644
20+
--- a/drivers/char/tpm/tpm_tis.c
21+
+++ b/drivers/char/tpm/tpm_tis.c
22+
@@ -143,6 +143,7 @@ static const struct dmi_system_id tpm_tis_dmi_table[] = {
23+
.ident = "UPX-TGL",
24+
.matches = {
25+
DMI_MATCH(DMI_SYS_VENDOR, "AAEON"),
26+
+ DMI_MATCH(DMI_PRODUCT_VERSION, "UPX-TGL"),
27+
},
28+
},
29+
{}
30+
--
31+
2.41.0
32+
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
From 530ad4f3240a3b6e448bd301cc632e7c44cac9b2 Mon Sep 17 00:00:00 2001
2+
From: Christian Hesse <mail@eworm.de>
3+
Date: Mon, 10 Jul 2023 23:16:09 +0200
4+
Subject: [PATCH 3/7] tpm/tpm_tis: Disable interrupts for Framework Laptop
5+
Intel 12th gen
6+
7+
This device suffer an irq storm, so add it in tpm_tis_dmi_table to
8+
force polling.
9+
10+
Cc: stable@vger.kernel.org # v6.4+
11+
Link: https://community.frame.work/t/boot-and-shutdown-hangs-with-arch-linux-kernel-6-4-1-mainline-and-arch/33118
12+
Fixes: e644b2f498d2 ("tpm, tpm_tis: Enable interrupt test")
13+
Reported-by: <roubro1991@gmail.com>
14+
Closes: https://bugzilla.kernel.org/show_bug.cgi?id=217631
15+
Signed-off-by: Christian Hesse <mail@eworm.de>
16+
Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
17+
---
18+
drivers/char/tpm/tpm_tis.c | 8 ++++++++
19+
1 file changed, 8 insertions(+)
20+
21+
diff --git a/drivers/char/tpm/tpm_tis.c b/drivers/char/tpm/tpm_tis.c
22+
index 9cb4e81fc5486..5dd391ed3320e 100644
23+
--- a/drivers/char/tpm/tpm_tis.c
24+
+++ b/drivers/char/tpm/tpm_tis.c
25+
@@ -114,6 +114,14 @@ static int tpm_tis_disable_irq(const struct dmi_system_id *d)
26+
}
27+
28+
static const struct dmi_system_id tpm_tis_dmi_table[] = {
29+
+ {
30+
+ .callback = tpm_tis_disable_irq,
31+
+ .ident = "Framework Laptop (12th Gen Intel Core)",
32+
+ .matches = {
33+
+ DMI_MATCH(DMI_SYS_VENDOR, "Framework"),
34+
+ DMI_MATCH(DMI_PRODUCT_NAME, "Laptop (12th Gen Intel Core)"),
35+
+ },
36+
+ },
37+
{
38+
.callback = tpm_tis_disable_irq,
39+
.ident = "ThinkPad T490s",
40+
--
41+
2.41.0
42+
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
From 07c0bd0d251db0ac13064f46534a22e070a9379f Mon Sep 17 00:00:00 2001
2+
From: Christian Hesse <mail@eworm.de>
3+
Date: Mon, 10 Jul 2023 23:16:10 +0200
4+
Subject: [PATCH 4/7] tpm/tpm_tis: Disable interrupts for Framework Laptop
5+
Intel 13th gen
6+
7+
This device suffer an irq storm, so add it in tpm_tis_dmi_table to
8+
force polling.
9+
10+
Cc: stable@vger.kernel.org # v6.4+
11+
Link: https://community.frame.work/t/boot-and-shutdown-hangs-with-arch-linux-kernel-6-4-1-mainline-and-arch/33118
12+
Fixes: e644b2f498d2 ("tpm, tpm_tis: Enable interrupt test")
13+
Reported-by: <roubro1991@gmail.com>
14+
Closes: https://bugzilla.kernel.org/show_bug.cgi?id=217631
15+
Signed-off-by: Christian Hesse <mail@eworm.de>
16+
Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
17+
---
18+
drivers/char/tpm/tpm_tis.c | 8 ++++++++
19+
1 file changed, 8 insertions(+)
20+
21+
diff --git a/drivers/char/tpm/tpm_tis.c b/drivers/char/tpm/tpm_tis.c
22+
index 5dd391ed3320e..4e4426965cd03 100644
23+
--- a/drivers/char/tpm/tpm_tis.c
24+
+++ b/drivers/char/tpm/tpm_tis.c
25+
@@ -122,6 +122,14 @@ static const struct dmi_system_id tpm_tis_dmi_table[] = {
26+
DMI_MATCH(DMI_PRODUCT_NAME, "Laptop (12th Gen Intel Core)"),
27+
},
28+
},
29+
+ {
30+
+ .callback = tpm_tis_disable_irq,
31+
+ .ident = "Framework Laptop (13th Gen Intel Core)",
32+
+ .matches = {
33+
+ DMI_MATCH(DMI_SYS_VENDOR, "Framework"),
34+
+ DMI_MATCH(DMI_PRODUCT_NAME, "Laptop (13th Gen Intel Core)"),
35+
+ },
36+
+ },
37+
{
38+
.callback = tpm_tis_disable_irq,
39+
.ident = "ThinkPad T490s",
40+
--
41+
2.41.0
42+
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
From 4abd126fb6e7ed77ee5a286132a5afc133dd24bc Mon Sep 17 00:00:00 2001
2+
From: Florian Bezdeka <florian@bezdeka.de>
3+
Date: Tue, 20 Jun 2023 13:11:01 +0200
4+
Subject: [PATCH 5/7] tpm/tpm_tis: Disable interrupts for Lenovo L590 devices
5+
6+
The Lenovo L590 suffers from an irq storm issue like the T490, T490s
7+
and P360 Tiny, so add an entry for it to tpm_tis_dmi_table and force
8+
polling.
9+
10+
Cc: stable@vger.kernel.org # v6.4+
11+
Link: https://bugzilla.redhat.com/show_bug.cgi?id=2214069#c0
12+
Fixes: e644b2f498d2 ("tpm, tpm_tis: Enable interrupt test")
13+
Signed-off-by: Florian Bezdeka <florian@bezdeka.de>
14+
Reviewed-by: Jerry Snitselaar <jsnitsel@redhat.com>
15+
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
16+
Signed-off-by: Jarkko Sakkinen <jarkko@kernel.org>
17+
---
18+
drivers/char/tpm/tpm_tis.c | 8 ++++++++
19+
1 file changed, 8 insertions(+)
20+
21+
diff --git a/drivers/char/tpm/tpm_tis.c b/drivers/char/tpm/tpm_tis.c
22+
index 4e4426965cd03..cc42cf3de960f 100644
23+
--- a/drivers/char/tpm/tpm_tis.c
24+
+++ b/drivers/char/tpm/tpm_tis.c
25+
@@ -154,6 +154,14 @@ static const struct dmi_system_id tpm_tis_dmi_table[] = {
26+
DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad L490"),
27+
},
28+
},
29+
+ {
30+
+ .callback = tpm_tis_disable_irq,
31+
+ .ident = "ThinkPad L590",
32+
+ .matches = {
33+
+ DMI_MATCH(DMI_SYS_VENDOR, "LENOVO"),
34+
+ DMI_MATCH(DMI_PRODUCT_VERSION, "ThinkPad L590"),
35+
+ },
36+
+ },
37+
{
38+
.callback = tpm_tis_disable_irq,
39+
.ident = "UPX-TGL",
40+
--
41+
2.41.0
42+
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
From 5718acc67b7101c5c5d834b4699b58710f619171 Mon Sep 17 00:00:00 2001
2+
From: =?UTF-8?q?Tomasz=20Mo=C5=84?= <tomasz.mon@nordicsemi.no>
3+
Date: Thu, 13 Jul 2023 12:25:14 +0200
4+
Subject: [PATCH 6/7] Bluetooth: btusb: Fix bluetooth on Intel Macbook 2014
5+
MIME-Version: 1.0
6+
Content-Type: text/plain; charset=UTF-8
7+
Content-Transfer-Encoding: 8bit
8+
9+
Commit c13380a55522 ("Bluetooth: btusb: Do not require hardcoded
10+
interface numbers") inadvertedly broke bluetooth on Intel Macbook 2014.
11+
The intention was to keep behavior intact when BTUSB_IFNUM_2 is set and
12+
otherwise allow any interface numbers. The problem is that the new logic
13+
condition omits the case where bInterfaceNumber is 0.
14+
15+
Fix BTUSB_IFNUM_2 handling by allowing both interface number 0 and 2
16+
when the flag is set.
17+
18+
Fixes: c13380a55522 ("Bluetooth: btusb: Do not require hardcoded interface numbers")
19+
Reported-by: John Holland <johnbholland@icloud.com>
20+
Closes: https://bugzilla.kernel.org/show_bug.cgi?id=217651
21+
Signed-off-by: Tomasz Moń <tomasz.mon@nordicsemi.no>
22+
Tested-by: John Holland<johnbholland@icloud.com>
23+
Signed-off-by: Luiz Augusto von Dentz <luiz.von.dentz@intel.com>
24+
Cherry-picked-for: https://bugs.archlinux.org/task/78980
25+
---
26+
drivers/bluetooth/btusb.c | 1 +
27+
1 file changed, 1 insertion(+)
28+
29+
diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
30+
index 2a8e2bb038f58..50e23762ec5e9 100644
31+
--- a/drivers/bluetooth/btusb.c
32+
+++ b/drivers/bluetooth/btusb.c
33+
@@ -4099,6 +4099,7 @@ static int btusb_probe(struct usb_interface *intf,
34+
BT_DBG("intf %p id %p", intf, id);
35+
36+
if ((id->driver_info & BTUSB_IFNUM_2) &&
37+
+ (intf->cur_altsetting->desc.bInterfaceNumber != 0) &&
38+
(intf->cur_altsetting->desc.bInterfaceNumber != 2))
39+
return -ENODEV;
40+
41+
--
42+
2.41.0
43+

linux/PKGBUILD

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,11 @@ source=(
3535

3636
# Arch Linux patches
3737
0001-ZEN-Add-sysctl-and-CONFIG-to-disallow-unprivileged-C.patch
38-
0002-netfilter-nf_tables-unbind-non-anonymous-set-if-rule.patch
38+
0002-tpm-tpm_tis-Disable-interrupts-only-for-AEON-UPX-i11.patch
39+
0003-tpm-tpm_tis-Disable-interrupts-for-Framework-Laptop-.patch
40+
0004-tpm-tpm_tis-Disable-interrupts-for-Framework-Laptop-.patch
41+
0005-tpm-tpm_tis-Disable-interrupts-for-Lenovo-L590-devic.patch
42+
0006-Bluetooth-btusb-Fix-bluetooth-on-Intel-Macbook-2014.patch
3943

4044
# ChimeraOS specific patches
4145
# Some patches from TKG Team
@@ -65,8 +69,12 @@ validpgpkeys=(
6569
)
6670
b2sums=('1ab6c93da986dac6a07a5e3bc764f9d2a5bb9b8989321244455d894690634ac04364e6a3f960e8674f47ae22fc4ed09b18aa60cbf279636083e61aa6524f8a59'
6771
'2a44934a12b21f28cbb12dca410d3cca118c906cd94f14865a6243b4497ce4ba4bd07045d37b92b5654909a1d4d1d676f630c96630b2d0b78eb74c0be3a7fcc9'
68-
'2ac7ee27dd8171f53b913211a2db5f0106a90c151d33561380bfba1dd24c8b5abdd2f917f1a0b185a2ef6654c61ec6f1e4f7bdb5cdc94c9c936b7847ef60cca8'
69-
'dca0be9f3adc515f63721549aa359b40810fe2164157784adb7313ac032f8954ba725e6f6781b44606d0c8377e7fd900da5298a142a09cd8754ac60cf526ed0b'
72+
'ad5d71652af8dc9dfa262fd60edb209535f4a1dc4abe64939f1924912b9630251311c84c4868ba4633c02062c3678f1deaebe72b1e227d2187f68ea97bdb4432'
73+
'0308340dc1d10e7a00fb4111b3c12d5122552e70e6b029f826352bc5995fa8b925a06f5897bf81ada735fae587e675275e2fe129068d866bc7f69ff3835ebac6'
74+
'e57a5bdac4b3b87e780964c90d575178ae4f462a73f5f412b23aecc9dc05ffc9d7acaee288b4cab19a6adbad9b14a37b1212a274ce98a979d6038a010fc11879'
75+
'1b70b2c7c2010f898bf3cfdd0db0d5c0942f1754b56f32cadcdda9776b338fc444f6ceaa9a5da130a85df17d446dcb62fd567011ddbc1a47e12979417e4a2b9f'
76+
'5027c4f9084393a78f8dbef7d93b48c0d2cf484e04bced4e7359a15dbb40a5b0bc61ca9d424eb320fd2f00d52495c30b0886d891338a744c62cfec0d6c0f9db1'
77+
'85ca3c2d0b05ae13b3b526eb23523fa8702a728294af65033e4d1be46d38663800f39bdd7ec7b4fc837836b9150a0c76bfc84d1be59e410ec23570613aad697e'
7078
'e2e364387efe34a1a392cdf9801b6f164d84de428edd8e43ccb1f12690019078db297b9dcf61a5dd4a83ca40dca8f25d9117e240c1ffd8b969d81e4dc6e972fd'
7179
'0aabd614b3318880fe940d4f3eb93f8b7f0e91892864f95d5b12eabfce1650ef036bf4e2ccee8b391c8a3cef4ff1ff7661b118a4f72d82214dbf713743809f78'
7280
'5a578620cc03574218a22c1eebbba91047815f0c7b0b3f2f3d1eb5534aa17254f0ea5f061cadfe7bbe3b32f0a20b2008e28a494cfd7be84600c4b6a89afd6940'

0 commit comments

Comments
 (0)