Skip to content

Commit

Permalink
chore: autopublish 2024-09-16T00:43:50Z
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Sep 16, 2024
1 parent dd67dc0 commit 2442803
Show file tree
Hide file tree
Showing 15 changed files with 170 additions and 176 deletions.
77 changes: 76 additions & 1 deletion sys-kernel/surface-sources/files/6.10/0001-secureboot.patch
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
From 252c5b2e65865a2a3aa6a5400f204c47d22490ee Mon Sep 17 00:00:00 2001
From f042429d0ea3d440fa70f9c51c8197bb208f0a88 Mon Sep 17 00:00:00 2001
From: Maximilian Luz <[email protected]>
Date: Sun, 9 Jun 2024 19:48:58 +0200
Subject: [PATCH] Revert "efi/x86: Set the PE/COFF header's NX compat flag
Expand Down Expand Up @@ -35,3 +35,78 @@ index b5c79f43359b..a1bbedd989e4 100644
--
2.46.0

From db11088db25ece8759f2db44ae62b144575a3649 Mon Sep 17 00:00:00 2001
From: "J. Eduardo" <[email protected]>
Date: Sun, 25 Aug 2024 14:17:45 +0200
Subject: [PATCH] PM: hibernate: Add a lockdown_hibernate parameter

This allows the user to tell the kernel that they know better (namely,
they secured their swap properly), and that it can enable hibernation.

Signed-off-by: Kelvie Wong <[email protected]>
Link: https://github.com/linux-surface/kernel/pull/158
Link: https://gist.github.com/brknkfr/95d1925ccdbb7a2d18947c168dfabbee
Patchset: secureboot
---
Documentation/admin-guide/kernel-parameters.txt | 5 +++++
kernel/power/hibernate.c | 10 +++++++++-
2 files changed, 14 insertions(+), 1 deletion(-)

diff --git a/Documentation/admin-guide/kernel-parameters.txt b/Documentation/admin-guide/kernel-parameters.txt
index c82446cef8e2..2ae1a6fda7f9 100644
--- a/Documentation/admin-guide/kernel-parameters.txt
+++ b/Documentation/admin-guide/kernel-parameters.txt
@@ -3000,6 +3000,11 @@
to extract confidential information from the kernel
are also disabled.

+ lockdown_hibernate [HIBERNATION]
+ Enable hibernation even if lockdown is enabled. Enable this only if
+ your swap is encrypted and secured properly, as an attacker can
+ modify the kernel offline during hibernation.
+
locktorture.acq_writer_lim= [KNL]
Set the time limit in jiffies for a lock
acquisition. Acquisitions exceeding this limit
diff --git a/kernel/power/hibernate.c b/kernel/power/hibernate.c
index 0a213f69a9e4..8e4f9dcc9f4c 100644
--- a/kernel/power/hibernate.c
+++ b/kernel/power/hibernate.c
@@ -37,6 +37,7 @@
#include "power.h"


+static int lockdown_hibernate;
static int nocompress;
static int noresume;
static int nohibernate;
@@ -92,7 +93,7 @@ void hibernate_release(void)
bool hibernation_available(void)
{
return nohibernate == 0 &&
- !security_locked_down(LOCKDOWN_HIBERNATION) &&
+ (lockdown_hibernate || !security_locked_down(LOCKDOWN_HIBERNATION)) &&
!secretmem_active() && !cxl_mem_active();
}

@@ -1422,6 +1423,12 @@ static int __init nohibernate_setup(char *str)
return 1;
}

+static int __init lockdown_hibernate_setup(char *str)
+{
+ lockdown_hibernate = 1;
+ return 1;
+}
+
static const char * const comp_alg_enabled[] = {
#if IS_ENABLED(CONFIG_CRYPTO_LZO)
COMPRESSION_ALGO_LZO,
@@ -1480,3 +1487,4 @@ __setup("hibernate=", hibernate_setup);
__setup("resumewait", resumewait_setup);
__setup("resumedelay=", resumedelay_setup);
__setup("nohibernate", nohibernate_setup);
+__setup("lockdown_hibernate", lockdown_hibernate_setup);
--
2.46.0

Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
From 1146270e92aee0b612dfe695bcf8f7131a19bcf3 Mon Sep 17 00:00:00 2001
From 3b00df63072f59df6b111ad853b87094b3536442 Mon Sep 17 00:00:00 2001
From: Tsuchiya Yuto <[email protected]>
Date: Sun, 18 Oct 2020 16:42:44 +0900
Subject: [PATCH] (surface3-oemb) add DMI matches for Surface 3 with broken DMI
Expand Down
8 changes: 4 additions & 4 deletions sys-kernel/surface-sources/files/6.10/0003-mwifiex.patch
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
From 800e9cfe84a3eadd4dc9ae700940068e77fa8a12 Mon Sep 17 00:00:00 2001
From 4ed887721124fdef2427143d1df5c56f42527b7e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jonas=20Dre=C3=9Fler?= <[email protected]>
Date: Tue, 3 Nov 2020 13:28:04 +0100
Subject: [PATCH] mwifiex: Add quirk resetting the PCI bridge on MS Surface
Expand Down Expand Up @@ -165,7 +165,7 @@ index d6ff964aec5b..5d30ae39d65e 100644
--
2.46.0

From d51c5a356fee57c99a8d181825f8f941f34749d7 Mon Sep 17 00:00:00 2001
From 894aa28465f66434a8c253eee50347f682c40117 Mon Sep 17 00:00:00 2001
From: Tsuchiya Yuto <[email protected]>
Date: Sun, 4 Oct 2020 00:11:49 +0900
Subject: [PATCH] mwifiex: pcie: disable bridge_d3 for Surface gen4+
Expand Down Expand Up @@ -320,7 +320,7 @@ index 5d30ae39d65e..c14eb56eb911 100644
--
2.46.0

From 317cde3654592dcb3e072d0d2fe7b4e5598cc078 Mon Sep 17 00:00:00 2001
From bca01a7cadbd3152491c45ae9d427478447cc483 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Jonas=20Dre=C3=9Fler?= <[email protected]>
Date: Thu, 25 Mar 2021 11:33:02 +0100
Subject: [PATCH] Bluetooth: btusb: Lower passive lescan interval on Marvell
Expand Down Expand Up @@ -356,7 +356,7 @@ Patchset: mwifiex
1 file changed, 15 insertions(+)

diff --git a/drivers/bluetooth/btusb.c b/drivers/bluetooth/btusb.c
index 789c492df6fa..1e766b6c1f9a 100644
index 0927f51867c2..3d3573829631 100644
--- a/drivers/bluetooth/btusb.c
+++ b/drivers/bluetooth/btusb.c
@@ -65,6 +65,7 @@ static struct usb_driver btusb_driver;
Expand Down
2 changes: 1 addition & 1 deletion sys-kernel/surface-sources/files/6.10/0004-ath10k.patch
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
From 268a79fb66862ef22294397a425fd074fc336c34 Mon Sep 17 00:00:00 2001
From 285063f8ccb7722b6eb27a6401fed87c86fd2e7f Mon Sep 17 00:00:00 2001
From: Maximilian Luz <[email protected]>
Date: Sat, 27 Feb 2021 00:45:52 +0100
Subject: [PATCH] ath10k: Add module parameters to override board files
Expand Down
8 changes: 4 additions & 4 deletions sys-kernel/surface-sources/files/6.10/0005-ipts.patch
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
From 9904c59dbdd422b811974893bab69fc5b4bc9a03 Mon Sep 17 00:00:00 2001
From 60cbae0f851d06cd4c356b29377ecbadfb08f874 Mon Sep 17 00:00:00 2001
From: Dorian Stoll <[email protected]>
Date: Thu, 30 Jul 2020 13:21:53 +0200
Subject: [PATCH] mei: me: Add Icelake device ID for iTouch
Expand Down Expand Up @@ -37,7 +37,7 @@ index 6589635f8ba3..a1df48a434e2 100644
--
2.46.0

From b0d9ceae2f95a4e4093b07580bedc10821374555 Mon Sep 17 00:00:00 2001
From 681a57dea0faeceb03b50752abbafb85341b981c Mon Sep 17 00:00:00 2001
From: Liban Hannan <[email protected]>
Date: Tue, 12 Apr 2022 23:31:12 +0100
Subject: [PATCH] iommu: Use IOMMU passthrough mode for IPTS
Expand All @@ -61,7 +61,7 @@ Patchset: ipts
1 file changed, 29 insertions(+)

diff --git a/drivers/iommu/intel/iommu.c b/drivers/iommu/intel/iommu.c
index f55ec1fd7942..8d95579436a9 100644
index e9bea0305c26..6ee97bf7b6a9 100644
--- a/drivers/iommu/intel/iommu.c
+++ b/drivers/iommu/intel/iommu.c
@@ -40,6 +40,11 @@
Expand Down Expand Up @@ -144,7 +144,7 @@ index f55ec1fd7942..8d95579436a9 100644
--
2.46.0

From ee1ebc3f9ec7a8418f418902817b5c5f4b51c21d Mon Sep 17 00:00:00 2001
From 56f5368c0bfde7b931fcb183cc779db625978f51 Mon Sep 17 00:00:00 2001
From: Dorian Stoll <[email protected]>
Date: Sun, 11 Dec 2022 12:00:59 +0100
Subject: [PATCH] hid: Add support for Intel Precise Touch and Stylus
Expand Down
4 changes: 2 additions & 2 deletions sys-kernel/surface-sources/files/6.10/0006-ithc.patch
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
From 0d0e07366b425e953d6dab698d62dbe9a7546994 Mon Sep 17 00:00:00 2001
From 19b03c0a9c68f00487ed8c07163e819da9c63fdd Mon Sep 17 00:00:00 2001
From: Dorian Stoll <[email protected]>
Date: Sun, 11 Dec 2022 12:03:38 +0100
Subject: [PATCH] iommu: intel: Disable source id verification for ITHC
Expand Down Expand Up @@ -39,7 +39,7 @@ index e4a70886678c..961a33b87c24 100644
--
2.46.0

From 19a947aa5cc417bd43656cf9d8bf010abdc6bc3f Mon Sep 17 00:00:00 2001
From 9f355143af2087aff4c4c1a6db46e6595e8ec5d4 Mon Sep 17 00:00:00 2001
From: quo <[email protected]>
Date: Sun, 11 Dec 2022 12:10:54 +0100
Subject: [PATCH] hid: Add support for Intel Touch Host Controller
Expand Down
81 changes: 13 additions & 68 deletions sys-kernel/surface-sources/files/6.10/0007-surface-sam.patch
Original file line number Diff line number Diff line change
@@ -1,59 +1,4 @@
From 17af44bcfe971e7b9dddad3735fad70bbda3fbf9 Mon Sep 17 00:00:00 2001
From: Maximilian Luz <[email protected]>
Date: Fri, 19 Apr 2024 20:41:47 +0200
Subject: [PATCH] platform/surface: aggregator: Fix warning when controller is
destroyed in probe

There is a small window in ssam_serial_hub_probe() where the controller
is initialized but has not been started yet. Specifically, between
ssam_controller_init() and ssam_controller_start(). Any failure in this
window, for example caused by a failure of serdev_device_open(),
currently results in an incorrect warning being emitted.

In particular, any failure in this window results in the controller
being destroyed via ssam_controller_destroy(). This function checks the
state of the controller and, in an attempt to validate that the
controller has been cleanly shut down before we try and deallocate any
resources, emits a warning if that state is not SSAM_CONTROLLER_STOPPED.

However, since we have only just initialized the controller and have not
yet started it, its state is SSAM_CONTROLLER_INITIALIZED. Note that this
is the only point at which the controller has this state, as it will
change after we start the controller with ssam_controller_start() and
never revert back. Further, at this point no communication has taken
place and the sender and receiver threads have not been started yet (and
we may not even have an open serdev device either).

Therefore, it is perfectly safe to call ssam_controller_destroy() with a
state of SSAM_CONTROLLER_INITIALIZED. This, however, means that the
warning currently being emitted is incorrect. Fix it by extending the
check.

Fixes: c167b9c7e3d6 ("platform/surface: Add Surface Aggregator subsystem")
Signed-off-by: Maximilian Luz <[email protected]>
Patchset: surface-sam
---
drivers/platform/surface/aggregator/controller.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/platform/surface/aggregator/controller.c b/drivers/platform/surface/aggregator/controller.c
index 7fc602e01487..7e89f547999b 100644
--- a/drivers/platform/surface/aggregator/controller.c
+++ b/drivers/platform/surface/aggregator/controller.c
@@ -1354,7 +1354,8 @@ void ssam_controller_destroy(struct ssam_controller *ctrl)
if (ctrl->state == SSAM_CONTROLLER_UNINITIALIZED)
return;

- WARN_ON(ctrl->state != SSAM_CONTROLLER_STOPPED);
+ WARN_ON(ctrl->state != SSAM_CONTROLLER_STOPPED &&
+ ctrl->state != SSAM_CONTROLLER_INITIALIZED);

/*
* Note: New events could still have been received after the previous
--
2.46.0

From 00b833401e8060eb50db269e0681383454a74848 Mon Sep 17 00:00:00 2001
From 1c0c81136657ad8656e5d713d0d8282d70413e53 Mon Sep 17 00:00:00 2001
From: Maximilian Luz <[email protected]>
Date: Sun, 22 Oct 2023 14:57:11 +0200
Subject: [PATCH] platform/surface: aggregator_registry: Add support for
Expand Down Expand Up @@ -86,7 +31,7 @@ index 1c4d74db08c9..f826489dc69d 100644
--
2.46.0

From 9e13165394bf1898d05c7d5a4a5adb1767d2307e Mon Sep 17 00:00:00 2001
From 74e058609a1229cfd478690ae2ad0fbb209ee6ed Mon Sep 17 00:00:00 2001
From: Maximilian Luz <[email protected]>
Date: Mon, 20 Nov 2023 19:47:00 +0100
Subject: [PATCH] platform/surface: aggregator_registry: Add support for
Expand Down Expand Up @@ -156,7 +101,7 @@ index f826489dc69d..ef59a7b66667 100644
--
2.46.0

From 83719d2cd70ad6ac1df993782e757ded15e881cc Mon Sep 17 00:00:00 2001
From 61ed1a703286c45a6f9de31053a8041e7e54cd4d Mon Sep 17 00:00:00 2001
From: Maximilian Luz <[email protected]>
Date: Sun, 9 Jun 2024 20:05:57 +0200
Subject: [PATCH] platform/surface: aggregator_registry: Add support for
Expand All @@ -174,7 +119,7 @@ Patchset: surface-sam
1 file changed, 19 insertions(+)

diff --git a/drivers/platform/surface/surface_aggregator_registry.c b/drivers/platform/surface/surface_aggregator_registry.c
index ef59a7b66667..70a2ea5a1957 100644
index ef59a7b66667..a20ccf49731c 100644
--- a/drivers/platform/surface/surface_aggregator_registry.c
+++ b/drivers/platform/surface/surface_aggregator_registry.c
@@ -273,6 +273,22 @@ static const struct software_node *ssam_node_group_sl5[] = {
Expand Down Expand Up @@ -205,15 +150,15 @@ index ef59a7b66667..70a2ea5a1957 100644
{ "MSHW0350", (unsigned long)ssam_node_group_sl5 },

+ /* Surface Laptop 6 */
+ { "MSHW0530", (unsigned long)ssam_node_group_sl5 },
+ { "MSHW0530", (unsigned long)ssam_node_group_sl6 },
+
/* Surface Laptop Go 1 */
{ "MSHW0118", (unsigned long)ssam_node_group_slg1 },

--
2.46.0

From c188646846cc6e9db1134eb62208d088ce615312 Mon Sep 17 00:00:00 2001
From be2709e2a0ddebba3887d730a2e61b7bec2a06f2 Mon Sep 17 00:00:00 2001
From: Maximilian Luz <[email protected]>
Date: Sat, 30 Dec 2023 18:07:54 +0100
Subject: [PATCH] hwmon: Add thermal sensor driver for Surface Aggregator
Expand Down Expand Up @@ -441,7 +386,7 @@ index 000000000000..48c3e826713f
--
2.46.0

From 31d334453ebc65b7868bf33b1963553586e64fa3 Mon Sep 17 00:00:00 2001
From 15ba0027e4d72f580255f8776ee251c94f81cab1 Mon Sep 17 00:00:00 2001
From: Maximilian Luz <[email protected]>
Date: Sat, 30 Dec 2023 18:12:23 +0100
Subject: [PATCH] hwmon: surface_temp: Add support for sensor names
Expand Down Expand Up @@ -636,7 +581,7 @@ index 48c3e826713f..4c08926139db 100644
--
2.46.0

From 36174000616d130e9b4655d69eb3bd5b07adbecb Mon Sep 17 00:00:00 2001
From b80e50b1a90e22d3a200b085cac567905e56543c Mon Sep 17 00:00:00 2001
From: Maximilian Luz <[email protected]>
Date: Mon, 10 Jun 2024 21:47:47 +0200
Subject: [PATCH] platform/surface: aggregator_registry: Add fan and thermal
Expand All @@ -648,7 +593,7 @@ Patchset: surface-sam
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/platform/surface/surface_aggregator_registry.c b/drivers/platform/surface/surface_aggregator_registry.c
index 70a2ea5a1957..6b568804f70b 100644
index a20ccf49731c..2b20c74bbe6d 100644
--- a/drivers/platform/surface/surface_aggregator_registry.c
+++ b/drivers/platform/surface/surface_aggregator_registry.c
@@ -265,7 +265,9 @@ static const struct software_node *ssam_node_group_sl5[] = {
Expand All @@ -665,7 +610,7 @@ index 70a2ea5a1957..6b568804f70b 100644
--
2.46.0

From e32f317be4ad620fb6683b62ad9e883f37e17f57 Mon Sep 17 00:00:00 2001
From 06973bc3db29f5d009d4de6298e0496490c811ee Mon Sep 17 00:00:00 2001
From: Maximilian Luz <[email protected]>
Date: Mon, 10 Jun 2024 21:48:02 +0200
Subject: [PATCH] platform/surface: aggregator_registry: Add fan and thermal
Expand All @@ -677,7 +622,7 @@ Patchset: surface-sam
1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/platform/surface/surface_aggregator_registry.c b/drivers/platform/surface/surface_aggregator_registry.c
index 6b568804f70b..9046df95c043 100644
index 2b20c74bbe6d..1e7e7ebeb074 100644
--- a/drivers/platform/surface/surface_aggregator_registry.c
+++ b/drivers/platform/surface/surface_aggregator_registry.c
@@ -312,7 +312,9 @@ static const struct software_node *ssam_node_group_sls2[] = {
Expand All @@ -694,7 +639,7 @@ index 6b568804f70b..9046df95c043 100644
--
2.46.0

From ebf64f6dcf1bdf0dbe80b5ec5e3d4b8a6cfab41e Mon Sep 17 00:00:00 2001
From 01cab9f250e8dc4b6a2e784467487f7eb03e7afe Mon Sep 17 00:00:00 2001
From: Maximilian Luz <[email protected]>
Date: Fri, 28 Jun 2024 22:31:37 +0200
Subject: [PATCH] platform/surface: aggregator_registry: Add Support for
Expand All @@ -706,7 +651,7 @@ Patchset: surface-sam
1 file changed, 22 insertions(+)

diff --git a/drivers/platform/surface/surface_aggregator_registry.c b/drivers/platform/surface/surface_aggregator_registry.c
index 9046df95c043..058f4edd8b66 100644
index 1e7e7ebeb074..ec9eb4d375b9 100644
--- a/drivers/platform/surface/surface_aggregator_registry.c
+++ b/drivers/platform/surface/surface_aggregator_registry.c
@@ -377,6 +377,25 @@ static const struct software_node *ssam_node_group_sp9[] = {
Expand Down
Loading

0 comments on commit 2442803

Please sign in to comment.