[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-04-27 Thread Mike Pagano
commit: dec026acc53d3de81b0674ea71bbcfdbdfe94614
Author: Mike Pagano  gentoo  org>
AuthorDate: Sat Apr 27 22:01:28 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Sat Apr 27 22:05:18 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=dec026ac

Add UBSAN_BOUNDS and UBSAN_SHIFT and dependencies

Bug: https://bugs.gentoo.org/930733

Signed-off-by: Mike Pagano  gentoo.org>

 4567_distro-Gentoo-Kconfig.patch | 14 +++---
 1 file changed, 7 insertions(+), 7 deletions(-)

diff --git a/4567_distro-Gentoo-Kconfig.patch b/4567_distro-Gentoo-Kconfig.patch
index d215166c..6134393f 100644
--- a/4567_distro-Gentoo-Kconfig.patch
+++ b/4567_distro-Gentoo-Kconfig.patch
@@ -6,9 +6,9 @@
  source "Documentation/Kconfig"
 +
 +source "distro/Kconfig"
 /dev/null  2022-08-25 07:13:06.694086407 -0400
-+++ b/distro/Kconfig   2022-08-25 13:21:55.150660724 -0400
-@@ -0,0 +1,291 @@
+--- /dev/null  2024-04-27 13:10:54.18827 -0400
 b/distro/Kconfig   2024-04-27 17:56:56.723132353 -0400
+@@ -0,0 +1,295 @@
 +menu "Gentoo Linux"
 +
 +config GENTOO_LINUX
@@ -213,6 +213,10 @@
 +  select SLAB_FREELIST_HARDENED
 +  select SHUFFLE_PAGE_ALLOCATOR
 +  select SLUB_DEBUG
++  select UBSAN
++  select CC_HAS_UBSAN_BOUNDS_STRICT if !CC_HAS_UBSAN_ARRAY_BOUNDS
++  select UBSAN_BOUNDS
++  select UBSAN_SHIFT
 +  select PAGE_POISONING
 +  select PAGE_POISONING_NO_SANITY
 +  select PAGE_POISONING_ZERO
@@ -300,9 +304,6 @@
 +  See the settings that become available for more details and 
fine-tuning.
 +
 +endmenu
--- 
-2.31.1
-
 From bd3ff0b16792c18c0614c2b95e148943209f460a Mon Sep 17 00:00:00 2001
 From: Georgy Yakovlev 
 Date: Tue, 8 Jun 2021 13:59:57 -0700
@@ -327,4 +328,3 @@ index 24c045b24..e13fc740c 100644
  This is the portion of low virtual memory which should be protected
 -- 
 2.31.1
-```



[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-04-27 Thread Mike Pagano
commit: 5100806341d2063710626ded2380d69556b5e080
Author: Mike Pagano  gentoo  org>
AuthorDate: Sat Apr 27 17:21:15 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Sat Apr 27 17:21:15 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=51008063

Remove redundant patch

Removed:
1800_gcc-plugins-stackleak-Avoid-head-text-section.patch

Signed-off-by: Mike Pagano  gentoo.org>

 _README|  4 ---
 ...plugins-stackleak-Avoid-head-text-section.patch | 36 --
 2 files changed, 40 deletions(-)

diff --git a/_README b/_README
index b08c709c..3a2ec3fd 100644
--- a/_README
+++ b/_README
@@ -171,10 +171,6 @@ Patch:  1730_parisc-Disable-prctl.patch
 From:
https://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux.git
 Desc:prctl: Temporarily disable prctl(PR_SET_MDWE) on parisc
 
-Patch:  1800_gcc-plugins-stackleak-Avoid-head-text-section.patch
-From:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
-Desc:   gcc-plugins/stackleak: Avoid .head.text section
-
 Patch:  2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
 From:   
https://lore.kernel.org/linux-bluetooth/20190522070540.48895-1-mar...@holtmann.org/raw
 Desc:   Bluetooth: Check key sizes only when Secure Simple Pairing is enabled. 
See bug #686758

diff --git a/1800_gcc-plugins-stackleak-Avoid-head-text-section.patch 
b/1800_gcc-plugins-stackleak-Avoid-head-text-section.patch
deleted file mode 100644
index 28964f01..
--- a/1800_gcc-plugins-stackleak-Avoid-head-text-section.patch
+++ /dev/null
@@ -1,36 +0,0 @@
-From e7d24c0aa8e678f41457d1304e2091cac6fd1a2e Mon Sep 17 00:00:00 2001
-From: Ard Biesheuvel 
-Date: Thu, 28 Mar 2024 07:42:57 +0100
-Subject: gcc-plugins/stackleak: Avoid .head.text section
-
-The .head.text section carries the startup code that runs with the MMU
-off or with a translation of memory that deviates from the ordinary one.
-So avoid instrumentation with the stackleak plugin, which already avoids
-.init.text and .noinstr.text entirely.
-
-Fixes: 48204aba801f1b51 ("x86/sme: Move early SME kernel encryption handling 
into .head.text")
-Reported-by: kernel test robot 
-Closes: 
https://lore.kernel.org/oe-lkp/202403221630.2692c998-oliver.s...@intel.com
-Signed-off-by: Ard Biesheuvel 
-Link: https://lore.kernel.org/r/20240328064256.2358634-2-ardb+...@google.com
-Signed-off-by: Kees Cook 

- scripts/gcc-plugins/stackleak_plugin.c | 2 ++
- 1 file changed, 2 insertions(+)
-
-diff --git a/scripts/gcc-plugins/stackleak_plugin.c 
b/scripts/gcc-plugins/stackleak_plugin.c
-index c5c2ce113c9232..d20c47d21ad835 100644
 a/scripts/gcc-plugins/stackleak_plugin.c
-+++ b/scripts/gcc-plugins/stackleak_plugin.c
-@@ -467,6 +467,8 @@ static bool stackleak_gate(void)
-   return false;
-   if (STRING_EQUAL(section, ".entry.text"))
-   return false;
-+  if (STRING_EQUAL(section, ".head.text"))
-+  return false;
-   }
- 
-   return track_frame_size >= 0;
--- 
-cgit 1.2.3-korg
-



[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-04-13 Thread Mike Pagano
commit: e9c8dc88c933d5708b1bdcded3c16b2f8b892636
Author: Mike Pagano  gentoo  org>
AuthorDate: Sat Apr 13 13:06:10 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Sat Apr 13 13:06:10 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=e9c8dc88

Linux patch 6.6.27

Signed-off-by: Mike Pagano  gentoo.org>

 _README |4 +
 1026_linux-6.6.27.patch | 4095 +++
 2 files changed, 4099 insertions(+)

diff --git a/_README b/_README
index 7ad42cd5..7a128ec9 100644
--- a/_README
+++ b/_README
@@ -147,6 +147,10 @@ Patch:  1025_linux-6.6.26.patch
 From:   https://www.kernel.org
 Desc:   Linux 6.6.26
 
+Patch:  1026_linux-6.6.27.patch
+From:   https://www.kernel.org
+Desc:   Linux 6.6.27
+
 Patch:  1510_fs-enable-link-security-restrictions-by-default.patch
 From:   
http://sources.debian.net/src/linux/3.16.7-ckt4-3/debian/patches/debian/fs-enable-link-security-restrictions-by-default.patch/
 Desc:   Enable link security restrictions by default.

diff --git a/1026_linux-6.6.27.patch b/1026_linux-6.6.27.patch
new file mode 100644
index ..d4e41272
--- /dev/null
+++ b/1026_linux-6.6.27.patch
@@ -0,0 +1,4095 @@
+diff --git a/Makefile b/Makefile
+index 77ad41bd298e0..c3077c5d57665 100644
+--- a/Makefile
 b/Makefile
+@@ -1,7 +1,7 @@
+ # SPDX-License-Identifier: GPL-2.0
+ VERSION = 6
+ PATCHLEVEL = 6
+-SUBLEVEL = 26
++SUBLEVEL = 27
+ EXTRAVERSION =
+ NAME = Hurr durr I'ma ninja sloth
+ 
+diff --git a/arch/arm/boot/dts/rockchip/rk322x.dtsi 
b/arch/arm/boot/dts/rockchip/rk322x.dtsi
+index ffc16d6b97e1b..03d9baddcbaba 100644
+--- a/arch/arm/boot/dts/rockchip/rk322x.dtsi
 b/arch/arm/boot/dts/rockchip/rk322x.dtsi
+@@ -732,14 +732,20 @@ hdmi: hdmi@200a {
+   status = "disabled";
+ 
+   ports {
+-  hdmi_in: port {
+-  #address-cells = <1>;
+-  #size-cells = <0>;
+-  hdmi_in_vop: endpoint@0 {
+-  reg = <0>;
++  #address-cells = <1>;
++  #size-cells = <0>;
++
++  hdmi_in: port@0 {
++  reg = <0>;
++
++  hdmi_in_vop: endpoint {
+   remote-endpoint = <_out_hdmi>;
+   };
+   };
++
++  hdmi_out: port@1 {
++  reg = <1>;
++  };
+   };
+   };
+ 
+diff --git a/arch/arm/boot/dts/rockchip/rk3288.dtsi 
b/arch/arm/boot/dts/rockchip/rk3288.dtsi
+index cb9cdaddffd42..8593a83599376 100644
+--- a/arch/arm/boot/dts/rockchip/rk3288.dtsi
 b/arch/arm/boot/dts/rockchip/rk3288.dtsi
+@@ -1231,27 +1231,37 @@ hdmi: hdmi@ff98 {
+   compatible = "rockchip,rk3288-dw-hdmi";
+   reg = <0x0 0xff98 0x0 0x2>;
+   reg-io-width = <4>;
+-  #sound-dai-cells = <0>;
+-  rockchip,grf = <>;
+   interrupts = ;
+   clocks = <  PCLK_HDMI_CTRL>, < SCLK_HDMI_HDCP>, < 
SCLK_HDMI_CEC>;
+   clock-names = "iahb", "isfr", "cec";
+   power-domains = < RK3288_PD_VIO>;
++  rockchip,grf = <>;
++  #sound-dai-cells = <0>;
+   status = "disabled";
+ 
+   ports {
+-  hdmi_in: port {
++  #address-cells = <1>;
++  #size-cells = <0>;
++
++  hdmi_in: port@0 {
++  reg = <0>;
+   #address-cells = <1>;
+   #size-cells = <0>;
++
+   hdmi_in_vopb: endpoint@0 {
+   reg = <0>;
+   remote-endpoint = <_out_hdmi>;
+   };
++
+   hdmi_in_vopl: endpoint@1 {
+   reg = <1>;
+   remote-endpoint = <_out_hdmi>;
+   };
+   };
++
++  hdmi_out: port@1 {
++  reg = <1>;
++  };
+   };
+   };
+ 
+diff --git a/arch/arm64/boot/dts/rockchip/rk3328.dtsi 
b/arch/arm64/boot/dts/rockchip/rk3328.dtsi
+index cc8209795c3e5..3778fe5c42a4b 100644
+--- a/arch/arm64/boot/dts/rockchip/rk3328.dtsi
 b/arch/arm64/boot/dts/rockchip/rk3328.dtsi
+@@ -743,11 +743,20 @@ hdmi: hdmi@ff3c {
+   status = "disabled";
+ 
+   ports {
+-  hdmi_in: port {
++  #address-cells = <1>;
++  #size-cells = <0>;
++
++  hdmi_in: port@0 {
++  reg = <0>;
++
+  

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-04-11 Thread Mike Pagano
commit: a16ca9d125636a20c3c6082a1fef818ed5bf887f
Author: Mike Pagano  gentoo  org>
AuthorDate: Thu Apr 11 14:48:59 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Thu Apr 11 14:48:59 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=a16ca9d1

gcc-plugins/stackleak: Avoid .head.text section

Signed-off-by: Mike Pagano  gentoo.org>

 _README|  4 +++
 ...plugins-stackleak-Avoid-head-text-section.patch | 36 ++
 2 files changed, 40 insertions(+)

diff --git a/_README b/_README
index 7661b44e..7ad42cd5 100644
--- a/_README
+++ b/_README
@@ -159,6 +159,10 @@ Patch:  1730_parisc-Disable-prctl.patch
 From:
https://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux.git
 Desc:prctl: Temporarily disable prctl(PR_SET_MDWE) on parisc
 
+Patch:  1800_gcc-plugins-stackleak-Avoid-head-text-section.patch
+From:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
+Desc:   gcc-plugins/stackleak: Avoid .head.text section
+
 Patch:  2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
 From:   
https://lore.kernel.org/linux-bluetooth/20190522070540.48895-1-mar...@holtmann.org/raw
 Desc:   Bluetooth: Check key sizes only when Secure Simple Pairing is enabled. 
See bug #686758

diff --git a/1800_gcc-plugins-stackleak-Avoid-head-text-section.patch 
b/1800_gcc-plugins-stackleak-Avoid-head-text-section.patch
new file mode 100644
index ..28964f01
--- /dev/null
+++ b/1800_gcc-plugins-stackleak-Avoid-head-text-section.patch
@@ -0,0 +1,36 @@
+From e7d24c0aa8e678f41457d1304e2091cac6fd1a2e Mon Sep 17 00:00:00 2001
+From: Ard Biesheuvel 
+Date: Thu, 28 Mar 2024 07:42:57 +0100
+Subject: gcc-plugins/stackleak: Avoid .head.text section
+
+The .head.text section carries the startup code that runs with the MMU
+off or with a translation of memory that deviates from the ordinary one.
+So avoid instrumentation with the stackleak plugin, which already avoids
+.init.text and .noinstr.text entirely.
+
+Fixes: 48204aba801f1b51 ("x86/sme: Move early SME kernel encryption handling 
into .head.text")
+Reported-by: kernel test robot 
+Closes: 
https://lore.kernel.org/oe-lkp/202403221630.2692c998-oliver.s...@intel.com
+Signed-off-by: Ard Biesheuvel 
+Link: https://lore.kernel.org/r/20240328064256.2358634-2-ardb+...@google.com
+Signed-off-by: Kees Cook 
+---
+ scripts/gcc-plugins/stackleak_plugin.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+diff --git a/scripts/gcc-plugins/stackleak_plugin.c 
b/scripts/gcc-plugins/stackleak_plugin.c
+index c5c2ce113c9232..d20c47d21ad835 100644
+--- a/scripts/gcc-plugins/stackleak_plugin.c
 b/scripts/gcc-plugins/stackleak_plugin.c
+@@ -467,6 +467,8 @@ static bool stackleak_gate(void)
+   return false;
+   if (STRING_EQUAL(section, ".entry.text"))
+   return false;
++  if (STRING_EQUAL(section, ".head.text"))
++  return false;
+   }
+ 
+   return track_frame_size >= 0;
+-- 
+cgit 1.2.3-korg
+



[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-04-04 Thread Mike Pagano
commit: 400129c9ae00f53c5d580e7397433df1994c343e
Author: Mike Pagano  gentoo  org>
AuthorDate: Thu Apr  4 19:05:56 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Thu Apr  4 19:05:56 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=400129c9

Linux patch 6.6.25

Signed-off-by: Mike Pagano  gentoo.org>

 _README |4 +
 1024_linux-6.6.25.patch | 1218 +++
 2 files changed, 1222 insertions(+)

diff --git a/_README b/_README
index 7b0bc885..cfd8c138 100644
--- a/_README
+++ b/_README
@@ -139,6 +139,10 @@ Patch:  1023_linux-6.6.24.patch
 From:   https://www.kernel.org
 Desc:   Linux 6.6.24
 
+Patch:  1024_linux-6.6.25.patch
+From:   https://www.kernel.org
+Desc:   Linux 6.6.25
+
 Patch:  1510_fs-enable-link-security-restrictions-by-default.patch
 From:   
http://sources.debian.net/src/linux/3.16.7-ckt4-3/debian/patches/debian/fs-enable-link-security-restrictions-by-default.patch/
 Desc:   Enable link security restrictions by default.

diff --git a/1024_linux-6.6.25.patch b/1024_linux-6.6.25.patch
new file mode 100644
index ..b12781ab
--- /dev/null
+++ b/1024_linux-6.6.25.patch
@@ -0,0 +1,1218 @@
+diff --git a/Makefile b/Makefile
+index b053bae9296a7..022af2a9a6d9b 100644
+--- a/Makefile
 b/Makefile
+@@ -1,7 +1,7 @@
+ # SPDX-License-Identifier: GPL-2.0
+ VERSION = 6
+ PATCHLEVEL = 6
+-SUBLEVEL = 24
++SUBLEVEL = 25
+ EXTRAVERSION =
+ NAME = Hurr durr I'ma ninja sloth
+ 
+diff --git a/include/linux/workqueue.h b/include/linux/workqueue.h
+index ad97453e7c3a3..24b1e5070f4d4 100644
+--- a/include/linux/workqueue.h
 b/include/linux/workqueue.h
+@@ -405,13 +405,6 @@ enum {
+   WQ_MAX_ACTIVE   = 512,/* I like 512, better ideas? */
+   WQ_UNBOUND_MAX_ACTIVE   = WQ_MAX_ACTIVE,
+   WQ_DFL_ACTIVE   = WQ_MAX_ACTIVE / 2,
+-
+-  /*
+-   * Per-node default cap on min_active. Unless explicitly set, min_active
+-   * is set to min(max_active, WQ_DFL_MIN_ACTIVE). For more details, see
+-   * workqueue_struct->min_active definition.
+-   */
+-  WQ_DFL_MIN_ACTIVE   = 8,
+ };
+ 
+ /*
+@@ -454,33 +447,11 @@ extern struct workqueue_struct 
*system_freezable_power_efficient_wq;
+  * alloc_workqueue - allocate a workqueue
+  * @fmt: printf format for the name of the workqueue
+  * @flags: WQ_* flags
+- * @max_active: max in-flight work items, 0 for default
++ * @max_active: max in-flight work items per CPU, 0 for default
+  * remaining args: args for @fmt
+  *
+- * For a per-cpu workqueue, @max_active limits the number of in-flight work
+- * items for each CPU. e.g. @max_active of 1 indicates that each CPU can be
+- * executing at most one work item for the workqueue.
+- *
+- * For unbound workqueues, @max_active limits the number of in-flight work 
items
+- * for the whole system. e.g. @max_active of 16 indicates that that there can 
be
+- * at most 16 work items executing for the workqueue in the whole system.
+- *
+- * As sharing the same active counter for an unbound workqueue across multiple
+- * NUMA nodes can be expensive, @max_active is distributed to each NUMA node
+- * according to the proportion of the number of online CPUs and enforced
+- * independently.
+- *
+- * Depending on online CPU distribution, a node may end up with per-node
+- * max_active which is significantly lower than @max_active, which can lead to
+- * deadlocks if the per-node concurrency limit is lower than the maximum 
number
+- * of interdependent work items for the workqueue.
+- *
+- * To guarantee forward progress regardless of online CPU distribution, the
+- * concurrency limit on every node is guaranteed to be equal to or greater 
than
+- * min_active which is set to min(@max_active, %WQ_DFL_MIN_ACTIVE). This means
+- * that the sum of per-node max_active's may be larger than @max_active.
+- *
+- * For detailed information on %WQ_* flags, please refer to
++ * Allocate a workqueue with the specified parameters.  For detailed
++ * information on WQ_* flags, please refer to
+  * Documentation/core-api/workqueue.rst.
+  *
+  * RETURNS:
+diff --git a/kernel/workqueue.c b/kernel/workqueue.c
+index 66a270e235b45..fd7b84b06d926 100644
+--- a/kernel/workqueue.c
 b/kernel/workqueue.c
+@@ -108,7 +108,7 @@ enum {
+   RESCUER_NICE_LEVEL  = MIN_NICE,
+   HIGHPRI_NICE_LEVEL  = MIN_NICE,
+ 
+-  WQ_NAME_LEN = 32,
++  WQ_NAME_LEN = 24,
+ };
+ 
+ /*
+@@ -122,9 +122,6 @@ enum {
+  *
+  * L: pool->lock protected.  Access with pool->lock held.
+  *
+- * LN: pool->lock and wq_node_nr_active->lock protected for writes. Either for
+- * reads.
+- *
+  * K: Only modified by worker while holding pool->lock. Can be safely read by
+  *self, while holding pool->lock or from IRQ context if %current is the
+  *kworker.
+@@ -146,9 +143,6 @@ enum {
+  *
+  * WR: wq->mutex protected for writes.  RCU protected for 

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-03-15 Thread Mike Pagano
commit: d7f2eae7798b540197b71b776dce3964e80f5755
Author: Mike Pagano  gentoo  org>
AuthorDate: Fri Mar 15 21:59:58 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Fri Mar 15 21:59:58 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=d7f2eae7

Linux patch 6.6.22

Signed-off-by: Mike Pagano  gentoo.org>

 _README |4 +
 1021_linux-6.6.22.patch | 2080 +++
 2 files changed, 2084 insertions(+)

diff --git a/_README b/_README
index 36b62ecd..21f53f39 100644
--- a/_README
+++ b/_README
@@ -127,6 +127,10 @@ Patch:  1020_linux-6.6.21.patch
 From:   https://www.kernel.org
 Desc:   Linux 6.6.21
 
+Patch:  1021_linux-6.6.22.patch
+From:   https://www.kernel.org
+Desc:   Linux 6.6.22
+
 Patch:  1510_fs-enable-link-security-restrictions-by-default.patch
 From:   
http://sources.debian.net/src/linux/3.16.7-ckt4-3/debian/patches/debian/fs-enable-link-security-restrictions-by-default.patch/
 Desc:   Enable link security restrictions by default.

diff --git a/1021_linux-6.6.22.patch b/1021_linux-6.6.22.patch
new file mode 100644
index ..423e9ab6
--- /dev/null
+++ b/1021_linux-6.6.22.patch
@@ -0,0 +1,2080 @@
+diff --git a/Documentation/ABI/testing/sysfs-devices-system-cpu 
b/Documentation/ABI/testing/sysfs-devices-system-cpu
+index 7ecd5c8161a61..34b6f6ab47422 100644
+--- a/Documentation/ABI/testing/sysfs-devices-system-cpu
 b/Documentation/ABI/testing/sysfs-devices-system-cpu
+@@ -519,6 +519,7 @@ What:  /sys/devices/system/cpu/vulnerabilities
+   /sys/devices/system/cpu/vulnerabilities/mds
+   /sys/devices/system/cpu/vulnerabilities/meltdown
+   /sys/devices/system/cpu/vulnerabilities/mmio_stale_data
++  /sys/devices/system/cpu/vulnerabilities/reg_file_data_sampling
+   /sys/devices/system/cpu/vulnerabilities/retbleed
+   /sys/devices/system/cpu/vulnerabilities/spec_store_bypass
+   /sys/devices/system/cpu/vulnerabilities/spectre_v1
+diff --git a/Documentation/admin-guide/hw-vuln/index.rst 
b/Documentation/admin-guide/hw-vuln/index.rst
+index de99caabf65a3..ff0b440ef2dc9 100644
+--- a/Documentation/admin-guide/hw-vuln/index.rst
 b/Documentation/admin-guide/hw-vuln/index.rst
+@@ -21,3 +21,4 @@ are configurable at compile, boot or run time.
+cross-thread-rsb
+srso
+gather_data_sampling
++   reg-file-data-sampling
+diff --git a/Documentation/admin-guide/hw-vuln/reg-file-data-sampling.rst 
b/Documentation/admin-guide/hw-vuln/reg-file-data-sampling.rst
+new file mode 100644
+index 0..0585d02b9a6cb
+--- /dev/null
 b/Documentation/admin-guide/hw-vuln/reg-file-data-sampling.rst
+@@ -0,0 +1,104 @@
++==
++Register File Data Sampling (RFDS)
++==
++
++Register File Data Sampling (RFDS) is a microarchitectural vulnerability that
++only affects Intel Atom parts(also branded as E-cores). RFDS may allow
++a malicious actor to infer data values previously used in floating point
++registers, vector registers, or integer registers. RFDS does not provide the
++ability to choose which data is inferred. CVE-2023-28746 is assigned to RFDS.
++
++Affected Processors
++===
++Below is the list of affected Intel processors [#f1]_:
++
++   ===  
++   Common name  Family_Model
++   ===  
++   ATOM_GOLDMONT   06_5CH
++   ATOM_GOLDMONT_D 06_5FH
++   ATOM_GOLDMONT_PLUS  06_7AH
++   ATOM_TREMONT_D  06_86H
++   ATOM_TREMONT06_96H
++   ALDERLAKE   06_97H
++   ALDERLAKE_L 06_9AH
++   ATOM_TREMONT_L  06_9CH
++   RAPTORLAKE  06_B7H
++   RAPTORLAKE_P06_BAH
++   ATOM_GRACEMONT  06_BEH
++   RAPTORLAKE_S06_BFH
++   ===  
++
++As an exception to this table, Intel Xeon E family parts ALDERLAKE(06_97H) and
++RAPTORLAKE(06_B7H) codenamed Catlow are not affected. They are reported as
++vulnerable in Linux because they share the same family/model with an affected
++part. Unlike their affected counterparts, they do not enumerate RFDS_CLEAR or
++CPUID.HYBRID. This information could be used to distinguish between the
++affected and unaffected parts, but it is deemed not worth adding complexity as
++the reporting is fixed automatically when these parts enumerate RFDS_NO.
++
++Mitigation
++==
++Intel released a microcode update that enables software to clear sensitive
++information using the VERW instruction. Like MDS, RFDS deploys the same
++mitigation strategy to force the CPU to clear the affected buffers before an
++attacker can extract the secrets. This is achieved by using the otherwise
++unused and obsolete VERW instruction in combination with a microcode update.
++The microcode clears the affected CPU buffers 

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-03-02 Thread Mike Pagano
commit: 716de4e052aef03d91ee22f639257565d995c4cc
Author: Mike Pagano  gentoo  org>
AuthorDate: Sat Mar  2 22:37:42 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Sat Mar  2 22:37:42 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=716de4e0

Linux patch 6.6.20

Signed-off-by: Mike Pagano  gentoo.org>

 _README |  4 
 1019_linux-6.6.20.patch | 33 +
 2 files changed, 37 insertions(+)

diff --git a/_README b/_README
index fc6a3e20..48a0b288 100644
--- a/_README
+++ b/_README
@@ -119,6 +119,10 @@ Patch:  1018_linux-6.6.19.patch
 From:   https://www.kernel.org
 Desc:   Linux 6.6.19
 
+Patch:  1019_linux-6.6.20.patch
+From:   https://www.kernel.org
+Desc:   Linux 6.6.20
+
 Patch:  1510_fs-enable-link-security-restrictions-by-default.patch
 From:   
http://sources.debian.net/src/linux/3.16.7-ckt4-3/debian/patches/debian/fs-enable-link-security-restrictions-by-default.patch/
 Desc:   Enable link security restrictions by default.

diff --git a/1019_linux-6.6.20.patch b/1019_linux-6.6.20.patch
new file mode 100644
index ..e00a3b82
--- /dev/null
+++ b/1019_linux-6.6.20.patch
@@ -0,0 +1,33 @@
+diff --git a/Makefile b/Makefile
+index 6130b6bd8d6c5..a3bdd583afcc6 100644
+--- a/Makefile
 b/Makefile
+@@ -1,7 +1,7 @@
+ # SPDX-License-Identifier: GPL-2.0
+ VERSION = 6
+ PATCHLEVEL = 6
+-SUBLEVEL = 19
++SUBLEVEL = 20
+ EXTRAVERSION =
+ NAME = Hurr durr I'ma ninja sloth
+ 
+diff --git a/fs/ntfs3/frecord.c b/fs/ntfs3/frecord.c
+index 61c51650266ef..22fe7f58ad638 100644
+--- a/fs/ntfs3/frecord.c
 b/fs/ntfs3/frecord.c
+@@ -2457,7 +2457,6 @@ int ni_read_frame(struct ntfs_inode *ni, u64 frame_vbo, 
struct page **pages,
+   struct ATTR_LIST_ENTRY *le = NULL;
+   struct runs_tree *run = >file.run;
+   u64 valid_size = ni->i_valid;
+-  loff_t i_size = i_size_read(>vfs_inode);
+   u64 vbo_disk;
+   size_t unc_size;
+   u32 frame_size, i, npages_disk, ondisk_size;
+@@ -2509,6 +2508,7 @@ int ni_read_frame(struct ntfs_inode *ni, u64 frame_vbo, 
struct page **pages,
+   err = -EOPNOTSUPP;
+   goto out1;
+ #else
++  loff_t i_size = i_size_read(>vfs_inode);
+   u32 frame_bits = ni_ext_compress_bits(ni);
+   u64 frame64 = frame_vbo >> frame_bits;
+   u64 frames, vbo_data;



[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-02-23 Thread Mike Pagano
commit: fa124cef91a9cffc778239b8f361b3f16ca95a59
Author: Mike Pagano  gentoo  org>
AuthorDate: Fri Feb 23 13:24:55 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Fri Feb 23 13:24:55 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=fa124cef

Update cpu optimization patch

Signed-off-by: Mike Pagano  gentoo.org>

 5010_enable-cpu-optimizations-universal.patch | 67 +--
 1 file changed, 33 insertions(+), 34 deletions(-)

diff --git a/5010_enable-cpu-optimizations-universal.patch 
b/5010_enable-cpu-optimizations-universal.patch
index 6edd3db9..596cade6 100644
--- a/5010_enable-cpu-optimizations-universal.patch
+++ b/5010_enable-cpu-optimizations-universal.patch
@@ -1,6 +1,6 @@
-From 70d4906b87983ed2ed5da78930a701625d881dd0 Mon Sep 17 00:00:00 2001
+From 71dd30c3e2ab2852b0290ae1f34ce1c7f8655040 Mon Sep 17 00:00:00 2001
 From: graysky 
-Date: Thu, 5 Jan 2023 14:29:37 -0500
+Date: Wed, 21 Feb 2024 08:38:13 -0500
 
 FEATURES
 This patch adds additional CPU options to the Linux kernel accessible under:
@@ -107,12 +107,12 @@ REFERENCES
  3 files changed, 528 insertions(+), 17 deletions(-)
 
 diff --git a/arch/x86/Kconfig.cpu b/arch/x86/Kconfig.cpu
-index 542377cd419d..f589971df2d3 100644
+index 87396575c..5ac6e8463 100644
 --- a/arch/x86/Kconfig.cpu
 +++ b/arch/x86/Kconfig.cpu
 @@ -157,7 +157,7 @@ config MPENTIUM4
- 
- 
+
+
  config MK6
 -  bool "K6/K6-II/K6-III"
 +  bool "AMD K6/K6-II/K6-III"
@@ -121,7 +121,7 @@ index 542377cd419d..f589971df2d3 100644
  Select this for an AMD K6-family processor.  Enables use of
 @@ -165,7 +165,7 @@ config MK6
  flags to GCC.
- 
+
  config MK7
 -  bool "Athlon/Duron/K7"
 +  bool "AMD Athlon/Duron/K7"
@@ -130,7 +130,7 @@ index 542377cd419d..f589971df2d3 100644
  Select this for an AMD Athlon K7-family processor.  Enables use of
 @@ -173,12 +173,106 @@ config MK7
  flags to GCC.
- 
+
  config MK8
 -  bool "Opteron/Athlon64/Hammer/K8"
 +  bool "AMD Opteron/Athlon64/Hammer/K8"
@@ -138,7 +138,7 @@ index 542377cd419d..f589971df2d3 100644
  Select this for an AMD Opteron or Athlon64 Hammer-family processor.
  Enables use of some extended instructions, and passes appropriate
  optimization flags to GCC.
- 
+
 +config MK8SSE3
 +  bool "AMD Opteron/Athlon64/Hammer/K8 with SSE3"
 +  help
@@ -238,17 +238,17 @@ index 542377cd419d..f589971df2d3 100644
depends on X86_32
 @@ -270,7 +364,7 @@ config MPSC
  in /proc/cpuinfo. Family 15 is an older Xeon, Family 6 a newer one.
- 
+
  config MCORE2
 -  bool "Core 2/newer Xeon"
 +  bool "Intel Core 2"
help
- 
+
  Select this for Intel Core 2 and newer Core 2 Xeons (Xeon 51xx and
 @@ -278,6 +372,8 @@ config MCORE2
  family in /proc/cpuinfo. Newer ones have 6 and older ones 15
  (not a typo)
- 
+
 +Enables -march=core2
 +
  config MATOM
@@ -257,7 +257,7 @@ index 542377cd419d..f589971df2d3 100644
 @@ -287,6 +383,212 @@ config MATOM
  accordingly optimized code. Use a recent GCC with specific Atom
  support in order to fully benefit from selecting this option.
- 
+
 +config MNEHALEM
 +  bool "Intel Nehalem"
 +  select X86_P6_NOP
@@ -470,7 +470,7 @@ index 542377cd419d..f589971df2d3 100644
 @@ -294,6 +596,50 @@ config GENERIC_CPU
  Generic x86-64 CPU.
  Run equally well on all x86-64 CPUs.
- 
+
 +config GENERIC_CPU2
 +  bool "Generic-x86-64-v2"
 +  depends on (CC_IS_GCC && GCC_VERSION > 11) || (CC_IS_CLANG && 
CLANG_VERSION >= 12)
@@ -516,7 +516,7 @@ index 542377cd419d..f589971df2d3 100644
 +Enables -march=native
 +
  endchoice
- 
+
  config X86_GENERIC
 @@ -318,9 +664,17 @@ config X86_INTERNODE_CACHE_SHIFT
  config X86_L1_CACHE_SHIFT
@@ -535,17 +535,17 @@ index 542377cd419d..f589971df2d3 100644
 -  default "5" if MWINCHIP3D || MWINCHIPC6 || MCRUSOE || MEFFICEON || 
MCYRIXIII || MK6 || MPENTIUMIII || MPENTIUMII || M686 || M586MMX || M586TSC || 
M586 || MVIAC3_2 || MGEODE_LX
 +  default "5" if MWINCHIP3D || MWINCHIPC6 || MCRUSOE || MEFFICEON || 
MCYRIXIII || MK6 || MPENTIUMIII \
 +  || MPENTIUMII || M686 || M586MMX || M586TSC || M586 || MVIAC3_2 || 
MGEODE_LX
- 
+
  config X86_F00F_BUG
def_bool y
 @@ -332,15 +686,27 @@ config X86_INVD_BUG
- 
+
  config X86_ALIGNMENT_16
def_bool y
 -  depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || MELAN || MK6 || 
M586MMX || M586TSC || M586 || M486SX || M486 || MVIAC3_2 || MGEODEGX1
 +  depends on MWINCHIP3D || MWINCHIPC6 || MCYRIXIII || MELAN || MK6 || 
M586MMX || M586TSC \
 +  || M586 || M486SX || M486 || MVIAC3_2 || MGEODEGX1
- 
+
  config X86_INTEL_USERCOPY
def_bool y
 -  depends on MPENTIUM4 || MPENTIUMM || MPENTIUMIII || MPENTIUMII || 
M586MMX || X86_GENERIC || MK8 || MK7 || MEFFICEON || MCORE2
@@ -554,7 +554,7 @@ index 542377cd419d..f589971df2d3 100644
 +  || 

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-02-22 Thread Mike Pagano
commit: 8b1aa79bdb025188987407e34065efdeba91023f
Author: Mike Pagano  gentoo  org>
AuthorDate: Thu Feb 22 13:38:33 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Thu Feb 22 13:38:33 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=8b1aa79b

ASoC: max98388: Correct the includes

Bug: https://bugs.gentoo.org/925256

Signed-off-by: Mike Pagano  gentoo.org>

 _README   |  4 
 2700_ASoC_max98388_correct_includes.patch | 39 +++
 2 files changed, 43 insertions(+)

diff --git a/_README b/_README
index 781f1dae..5bd93d3c 100644
--- a/_README
+++ b/_README
@@ -127,6 +127,10 @@ Patch:  
2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
 From:   
https://lore.kernel.org/linux-bluetooth/20190522070540.48895-1-mar...@holtmann.org/raw
 Desc:   Bluetooth: Check key sizes only when Secure Simple Pairing is enabled. 
See bug #686758
 
+Patch:  2700_ASoC_max98388_correct_includes.patch
+From:   
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/patch/sound/soc/codecs/max98388.c?id=832beb640e425b5d1a92d8c2002e6b8e0af693eb
+Desc:   ASoC: max98388: Correct the includes
+
 Patch:  2800_amdgpu-Adj-kmalloc-array-calls-for-new-Walloc-size.patch
 From:   s...@gentoo.org
 Desc:   amdgpu: Adjust kmalloc_array calls for new -Walloc-size

diff --git a/2700_ASoC_max98388_correct_includes.patch 
b/2700_ASoC_max98388_correct_includes.patch
new file mode 100644
index ..c24d6bed
--- /dev/null
+++ b/2700_ASoC_max98388_correct_includes.patch
@@ -0,0 +1,39 @@
+From 832beb640e425b5d1a92d8c2002e6b8e0af693eb Mon Sep 17 00:00:00 2001
+From: Linus Walleij 
+Date: Mon, 11 Sep 2023 10:23:51 +0200
+Subject: ASoC: max98388: Correct the includes
+
+The MAX98388 driver is using the modern GPIO descriptor API
+but uses legacy includes. Include the proper 
+header instead.
+
+Signed-off-by: Linus Walleij 
+Link: 
https://lore.kernel.org/r/20230911-descriptors-asoc-max-v2-4-b9d793fb7...@linaro.org
+Signed-off-by: Mark Brown 
+---
+ sound/soc/codecs/max98388.c | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+(limited to 'sound/soc/codecs/max98388.c')
+
+diff --git a/sound/soc/codecs/max98388.c b/sound/soc/codecs/max98388.c
+index cde5e85946cb88..078adec29312d0 100644
+--- a/sound/soc/codecs/max98388.c
 b/sound/soc/codecs/max98388.c
+@@ -3,12 +3,11 @@
+ 
+ #include 
+ #include 
+-#include 
++#include 
+ #include 
+ #include 
+ #include 
+ #include 
+-#include 
+ #include 
+ #include 
+ #include 
+-- 
+cgit 1.2.3-korg
+



[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-02-16 Thread Mike Pagano
commit: b2c55c916f83e86dd4679778fa0ddbd8fbb6d1de
Author: Mike Pagano  gentoo  org>
AuthorDate: Fri Feb 16 19:05:34 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Fri Feb 16 19:05:34 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=b2c55c91

Removed redundant patch

Removed:
2700_solo6x10-mem-resource-reduction-fix.patch

Signed-off-by: Mike Pagano  gentoo.org>

 _README|  4 --
 2700_solo6x10-mem-resource-reduction-fix.patch | 60 --
 2 files changed, 64 deletions(-)

diff --git a/_README b/_README
index 07c4e5f7..781f1dae 100644
--- a/_README
+++ b/_README
@@ -127,10 +127,6 @@ Patch:  
2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
 From:   
https://lore.kernel.org/linux-bluetooth/20190522070540.48895-1-mar...@holtmann.org/raw
 Desc:   Bluetooth: Check key sizes only when Secure Simple Pairing is enabled. 
See bug #686758
 
-Patch:  2700_solo6x10-mem-resource-reduction-fix.patch
-From:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
-Desc:   media: solo6x10: replace max(a, min(b, c)) by clamp(b, a, c)
-
 Patch:  2800_amdgpu-Adj-kmalloc-array-calls-for-new-Walloc-size.patch
 From:   s...@gentoo.org
 Desc:   amdgpu: Adjust kmalloc_array calls for new -Walloc-size

diff --git a/2700_solo6x10-mem-resource-reduction-fix.patch 
b/2700_solo6x10-mem-resource-reduction-fix.patch
deleted file mode 100644
index bfc7cd80..
--- a/2700_solo6x10-mem-resource-reduction-fix.patch
+++ /dev/null
@@ -1,60 +0,0 @@
-From 31e97d7c9ae3de072d7b424b2cf706a03ec10720 Mon Sep 17 00:00:00 2001
-From: Aurelien Jarno 
-Date: Sat, 13 Jan 2024 19:33:31 +0100
-Subject: media: solo6x10: replace max(a, min(b, c)) by clamp(b, a, c)
-
-This patch replaces max(a, min(b, c)) by clamp(b, a, c) in the solo6x10
-driver.  This improves the readability and more importantly, for the
-solo6x10-p2m.c file, this reduces on my system (x86-64, gcc 13):
-
- - the preprocessed size from 121 MiB to 4.5 MiB;
-
- - the build CPU time from 46.8 s to 1.6 s;
-
- - the build memory from 2786 MiB to 98MiB.
-
-In fine, this allows this relatively simple C file to be built on a
-32-bit system.
-
-Reported-by: Jiri Slaby 
-Closes: 
https://lore.kernel.org/lkml/18c6df0d-45ed-450c-9eda-95160a2bb...@gmail.com/
-Cc:   # v6.7+
-Suggested-by: David Laight 
-Signed-off-by: Aurelien Jarno 
-Reviewed-by: David Laight 
-Reviewed-by: Hans Verkuil 
-Signed-off-by: Linus Torvalds 

- drivers/media/pci/solo6x10/solo6x10-offsets.h | 10 +-
- 1 file changed, 5 insertions(+), 5 deletions(-)
-
-(limited to 'drivers/media/pci/solo6x10/solo6x10-offsets.h')
-
-diff --git a/drivers/media/pci/solo6x10/solo6x10-offsets.h 
b/drivers/media/pci/solo6x10/solo6x10-offsets.h
-index f414ee1316f29c..fdbb817e63601c 100644
 a/drivers/media/pci/solo6x10/solo6x10-offsets.h
-+++ b/drivers/media/pci/solo6x10/solo6x10-offsets.h
-@@ -57,16 +57,16 @@
- #define SOLO_MP4E_EXT_ADDR(__solo) \
-   (SOLO_EREF_EXT_ADDR(__solo) + SOLO_EREF_EXT_AREA(__solo))
- #define SOLO_MP4E_EXT_SIZE(__solo) \
--  max((__solo->nr_chans * 0x0008),\
--  min(((__solo->sdram_size - SOLO_MP4E_EXT_ADDR(__solo)) -\
--   __SOLO_JPEG_MIN_SIZE(__solo)), 0x00ff))
-+  clamp(__solo->sdram_size - SOLO_MP4E_EXT_ADDR(__solo) - \
-+__SOLO_JPEG_MIN_SIZE(__solo), \
-+__solo->nr_chans * 0x0008, 0x00ff)
- 
- #define __SOLO_JPEG_MIN_SIZE(__solo)  (__solo->nr_chans * 0x0008)
- #define SOLO_JPEG_EXT_ADDR(__solo) \
-   (SOLO_MP4E_EXT_ADDR(__solo) + SOLO_MP4E_EXT_SIZE(__solo))
- #define SOLO_JPEG_EXT_SIZE(__solo) \
--  max(__SOLO_JPEG_MIN_SIZE(__solo),   \
--  min((__solo->sdram_size - SOLO_JPEG_EXT_ADDR(__solo)), 0x00ff))
-+  clamp(__solo->sdram_size - SOLO_JPEG_EXT_ADDR(__solo),  \
-+__SOLO_JPEG_MIN_SIZE(__solo), 0x00ff)
- 
- #define SOLO_SDRAM_END(__solo) \
-   (SOLO_JPEG_EXT_ADDR(__solo) + SOLO_JPEG_EXT_SIZE(__solo))
--- 
-cgit 1.2.3-korg



[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-02-06 Thread Mike Pagano
commit: 0f521208256c7f4efececb3421cda662c7bbfaf6
Author: Mike Pagano  gentoo  org>
AuthorDate: Tue Feb  6 17:27:38 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Tue Feb  6 17:27:38 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=0f521208

Fix x86 compilation patch

Signed-off-by: Mike Pagano  gentoo.org>

 2700_solo6x10-mem-resource-reduction-fix.patch | 128 -
 1 file changed, 59 insertions(+), 69 deletions(-)

diff --git a/2700_solo6x10-mem-resource-reduction-fix.patch 
b/2700_solo6x10-mem-resource-reduction-fix.patch
index a0b55a8c..bfc7cd80 100644
--- a/2700_solo6x10-mem-resource-reduction-fix.patch
+++ b/2700_solo6x10-mem-resource-reduction-fix.patch
@@ -1,70 +1,60 @@
-diff --git a/2700_solo6x10-mem-resource-reduction-fix.patch 
b/2700_solo6x10-mem-resource-reduction-fix.patch
-new file mode 100644
-index ..bf406a92
 /dev/null
-+++ b/2700_solo6x10-mem-resource-reduction-fix.patch
-@@ -0,0 +1,61 @@
-+From 31e97d7c9ae3de072d7b424b2cf706a03ec10720 Mon Sep 17 00:00:00 2001
-+From: Aurelien Jarno 
-+Date: Sat, 13 Jan 2024 19:33:31 +0100
-+Subject: media: solo6x10: replace max(a, min(b, c)) by clamp(b, a, c)
-+
-+This patch replaces max(a, min(b, c)) by clamp(b, a, c) in the solo6x10
-+driver.  This improves the readability and more importantly, for the
-+solo6x10-p2m.c file, this reduces on my system (x86-64, gcc 13):
-+
-+ - the preprocessed size from 121 MiB to 4.5 MiB;
-+
-+ - the build CPU time from 46.8 s to 1.6 s;
-+
-+ - the build memory from 2786 MiB to 98MiB.
-+
-+In fine, this allows this relatively simple C file to be built on a
-+32-bit system.
-+
-+Reported-by: Jiri Slaby 
-+Closes: 
https://lore.kernel.org/lkml/18c6df0d-45ed-450c-9eda-95160a2bb...@gmail.com/
-+Cc:   # v6.7+
-+Suggested-by: David Laight 
-+Signed-off-by: Aurelien Jarno 
-+Reviewed-by: David Laight 
-+Reviewed-by: Hans Verkuil 
-+Signed-off-by: Linus Torvalds 
-+---
-+ drivers/media/pci/solo6x10/solo6x10-offsets.h | 10 +-
-+ 1 file changed, 5 insertions(+), 5 deletions(-)
-+
-+(limited to 'drivers/media/pci/solo6x10/solo6x10-offsets.h')
-+
-+diff --git a/drivers/media/pci/solo6x10/solo6x10-offsets.h 
b/drivers/media/pci/solo6x10/solo6x10-offsets.h
-+index f414ee1316f29c..fdbb817e63601c 100644
-+--- a/drivers/media/pci/solo6x10/solo6x10-offsets.h
- b/drivers/media/pci/solo6x10/solo6x10-offsets.h
-+@@ -57,16 +57,16 @@
-+ #define SOLO_MP4E_EXT_ADDR(__solo) \
-+  (SOLO_EREF_EXT_ADDR(__solo) + SOLO_EREF_EXT_AREA(__solo))
-+ #define SOLO_MP4E_EXT_SIZE(__solo) \
-+- max((__solo->nr_chans * 0x0008),\
-+- min(((__solo->sdram_size - SOLO_MP4E_EXT_ADDR(__solo)) -\
-+-  __SOLO_JPEG_MIN_SIZE(__solo)), 0x00ff))
-++ clamp(__solo->sdram_size - SOLO_MP4E_EXT_ADDR(__solo) - \
-++   __SOLO_JPEG_MIN_SIZE(__solo), \
-++   __solo->nr_chans * 0x0008, 0x00ff)
-+ 
-+ #define __SOLO_JPEG_MIN_SIZE(__solo) (__solo->nr_chans * 0x0008)
-+ #define SOLO_JPEG_EXT_ADDR(__solo) \
-+  (SOLO_MP4E_EXT_ADDR(__solo) + SOLO_MP4E_EXT_SIZE(__solo))
-+ #define SOLO_JPEG_EXT_SIZE(__solo) \
-+- max(__SOLO_JPEG_MIN_SIZE(__solo),   \
-+- min((__solo->sdram_size - SOLO_JPEG_EXT_ADDR(__solo)), 0x00ff))
-++ clamp(__solo->sdram_size - SOLO_JPEG_EXT_ADDR(__solo),  \
-++   __SOLO_JPEG_MIN_SIZE(__solo), 0x00ff)
-+ 
-+ #define SOLO_SDRAM_END(__solo) \
-+  (SOLO_JPEG_EXT_ADDR(__solo) + SOLO_JPEG_EXT_SIZE(__solo))
-+-- 
-+cgit 1.2.3-korg
-+
--- 
-cgit v1.2.3
+From 31e97d7c9ae3de072d7b424b2cf706a03ec10720 Mon Sep 17 00:00:00 2001
+From: Aurelien Jarno 
+Date: Sat, 13 Jan 2024 19:33:31 +0100
+Subject: media: solo6x10: replace max(a, min(b, c)) by clamp(b, a, c)
+
+This patch replaces max(a, min(b, c)) by clamp(b, a, c) in the solo6x10
+driver.  This improves the readability and more importantly, for the
+solo6x10-p2m.c file, this reduces on my system (x86-64, gcc 13):
+
+ - the preprocessed size from 121 MiB to 4.5 MiB;
+
+ - the build CPU time from 46.8 s to 1.6 s;
+
+ - the build memory from 2786 MiB to 98MiB.
 
+In fine, this allows this relatively simple C file to be built on a
+32-bit system.
+
+Reported-by: Jiri Slaby 
+Closes: 
https://lore.kernel.org/lkml/18c6df0d-45ed-450c-9eda-95160a2bb...@gmail.com/
+Cc:   # v6.7+
+Suggested-by: David Laight 
+Signed-off-by: Aurelien Jarno 
+Reviewed-by: David Laight 
+Reviewed-by: Hans Verkuil 
+Signed-off-by: Linus Torvalds 
+---
+ drivers/media/pci/solo6x10/solo6x10-offsets.h | 10 +-
+ 1 file changed, 5 insertions(+), 5 deletions(-)
+
+(limited to 'drivers/media/pci/solo6x10/solo6x10-offsets.h')
+
+diff --git a/drivers/media/pci/solo6x10/solo6x10-offsets.h 
b/drivers/media/pci/solo6x10/solo6x10-offsets.h
+index f414ee1316f29c..fdbb817e63601c 100644
+--- a/drivers/media/pci/solo6x10/solo6x10-offsets.h
 

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-02-06 Thread Mike Pagano
commit: 7b214aa2332c2393f4f2c4024405f60951a5c2ba
Author: Mike Pagano  gentoo  org>
AuthorDate: Tue Feb  6 15:37:54 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Tue Feb  6 15:37:54 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=7b214aa2

Fix-up unintentional patch overwrite

Signed-off-by: Mike Pagano  gentoo.org>

 ...zes-only-if-Secure-Simple-Pairing-enabled.patch | 105 +++--
 ... 2700_solo6x10-mem-resource-reduction-fix.patch |   0
 2 files changed, 36 insertions(+), 69 deletions(-)

diff --git 
a/2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch 
b/2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
index a0b55a8c..394ad48f 100644
--- a/2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
+++ b/2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
@@ -1,70 +1,37 @@
-diff --git a/2700_solo6x10-mem-resource-reduction-fix.patch 
b/2700_solo6x10-mem-resource-reduction-fix.patch
-new file mode 100644
-index ..bf406a92
 /dev/null
-+++ b/2700_solo6x10-mem-resource-reduction-fix.patch
-@@ -0,0 +1,61 @@
-+From 31e97d7c9ae3de072d7b424b2cf706a03ec10720 Mon Sep 17 00:00:00 2001
-+From: Aurelien Jarno 
-+Date: Sat, 13 Jan 2024 19:33:31 +0100
-+Subject: media: solo6x10: replace max(a, min(b, c)) by clamp(b, a, c)
-+
-+This patch replaces max(a, min(b, c)) by clamp(b, a, c) in the solo6x10
-+driver.  This improves the readability and more importantly, for the
-+solo6x10-p2m.c file, this reduces on my system (x86-64, gcc 13):
-+
-+ - the preprocessed size from 121 MiB to 4.5 MiB;
-+
-+ - the build CPU time from 46.8 s to 1.6 s;
-+
-+ - the build memory from 2786 MiB to 98MiB.
-+
-+In fine, this allows this relatively simple C file to be built on a
-+32-bit system.
-+
-+Reported-by: Jiri Slaby 
-+Closes: 
https://lore.kernel.org/lkml/18c6df0d-45ed-450c-9eda-95160a2bb...@gmail.com/
-+Cc:   # v6.7+
-+Suggested-by: David Laight 
-+Signed-off-by: Aurelien Jarno 
-+Reviewed-by: David Laight 
-+Reviewed-by: Hans Verkuil 
-+Signed-off-by: Linus Torvalds 
-+---
-+ drivers/media/pci/solo6x10/solo6x10-offsets.h | 10 +-
-+ 1 file changed, 5 insertions(+), 5 deletions(-)
-+
-+(limited to 'drivers/media/pci/solo6x10/solo6x10-offsets.h')
-+
-+diff --git a/drivers/media/pci/solo6x10/solo6x10-offsets.h 
b/drivers/media/pci/solo6x10/solo6x10-offsets.h
-+index f414ee1316f29c..fdbb817e63601c 100644
-+--- a/drivers/media/pci/solo6x10/solo6x10-offsets.h
- b/drivers/media/pci/solo6x10/solo6x10-offsets.h
-+@@ -57,16 +57,16 @@
-+ #define SOLO_MP4E_EXT_ADDR(__solo) \
-+  (SOLO_EREF_EXT_ADDR(__solo) + SOLO_EREF_EXT_AREA(__solo))
-+ #define SOLO_MP4E_EXT_SIZE(__solo) \
-+- max((__solo->nr_chans * 0x0008),\
-+- min(((__solo->sdram_size - SOLO_MP4E_EXT_ADDR(__solo)) -\
-+-  __SOLO_JPEG_MIN_SIZE(__solo)), 0x00ff))
-++ clamp(__solo->sdram_size - SOLO_MP4E_EXT_ADDR(__solo) - \
-++   __SOLO_JPEG_MIN_SIZE(__solo), \
-++   __solo->nr_chans * 0x0008, 0x00ff)
-+ 
-+ #define __SOLO_JPEG_MIN_SIZE(__solo) (__solo->nr_chans * 0x0008)
-+ #define SOLO_JPEG_EXT_ADDR(__solo) \
-+  (SOLO_MP4E_EXT_ADDR(__solo) + SOLO_MP4E_EXT_SIZE(__solo))
-+ #define SOLO_JPEG_EXT_SIZE(__solo) \
-+- max(__SOLO_JPEG_MIN_SIZE(__solo),   \
-+- min((__solo->sdram_size - SOLO_JPEG_EXT_ADDR(__solo)), 0x00ff))
-++ clamp(__solo->sdram_size - SOLO_JPEG_EXT_ADDR(__solo),  \
-++   __SOLO_JPEG_MIN_SIZE(__solo), 0x00ff)
-+ 
-+ #define SOLO_SDRAM_END(__solo) \
-+  (SOLO_JPEG_EXT_ADDR(__solo) + SOLO_JPEG_EXT_SIZE(__solo))
-+-- 
-+cgit 1.2.3-korg
-+
--- 
-cgit v1.2.3
+The encryption is only mandatory to be enforced when both sides are using
+Secure Simple Pairing and this means the key size check makes only sense
+in that case.
 
+On legacy Bluetooth 2.0 and earlier devices like mice the encryption was
+optional and thus causing an issue if the key size check is not bound to
+using Secure Simple Pairing.
+
+Fixes: d5bb334a8e17 ("Bluetooth: Align minimum encryption key size for LE and 
BR/EDR connections")
+Signed-off-by: Marcel Holtmann 
+Cc: sta...@vger.kernel.org
+---
+ net/bluetooth/hci_conn.c | 9 +++--
+ 1 file changed, 7 insertions(+), 2 deletions(-)
+
+diff --git a/net/bluetooth/hci_conn.c b/net/bluetooth/hci_conn.c
+index 3cf0764d5793..7516cdde3373 100644
+--- a/net/bluetooth/hci_conn.c
 b/net/bluetooth/hci_conn.c
+@@ -1272,8 +1272,13 @@ int hci_conn_check_link_mode(struct hci_conn *conn)
+   return 0;
+   }
+ 
+-  if (hci_conn_ssp_enabled(conn) &&
+-  !test_bit(HCI_CONN_ENCRYPT, >flags))
++  /* If Secure Simple Pairing is not enabled, then legacy connection
++   * setup is used and no encryption or key sizes can be enforced.
++   */
++  if (!hci_conn_ssp_enabled(conn))

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-02-06 Thread Mike Pagano
commit: a1866d237318ab644beeacf8aa82c9422a353970
Author: Mike Pagano  gentoo  org>
AuthorDate: Tue Feb  6 15:34:26 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Tue Feb  6 15:34:26 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=a1866d23

media: solo6x10: replace max(a, min(b, c)) by clamp(b, a, c)

Signed-off-by: Mike Pagano  gentoo.org>

 _README|   4 +
 ...zes-only-if-Secure-Simple-Pairing-enabled.patch | 105 ++---
 2 files changed, 73 insertions(+), 36 deletions(-)

diff --git a/_README b/_README
index f2e7d99c..89d72103 100644
--- a/_README
+++ b/_README
@@ -123,6 +123,10 @@ Patch:  
2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
 From:   
https://lore.kernel.org/linux-bluetooth/20190522070540.48895-1-mar...@holtmann.org/raw
 Desc:   Bluetooth: Check key sizes only when Secure Simple Pairing is enabled. 
See bug #686758
 
+Patch:  2700_solo6x10-mem-resource-reduction-fix.patch
+From:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
+Desc:   media: solo6x10: replace max(a, min(b, c)) by clamp(b, a, c)
+
 Patch:  2800_amdgpu-Adj-kmalloc-array-calls-for-new-Walloc-size.patch
 From:   s...@gentoo.org
 Desc:   amdgpu: Adjust kmalloc_array calls for new -Walloc-size

diff --git 
a/2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch 
b/2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
index 394ad48f..a0b55a8c 100644
--- a/2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
+++ b/2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
@@ -1,37 +1,70 @@
-The encryption is only mandatory to be enforced when both sides are using
-Secure Simple Pairing and this means the key size check makes only sense
-in that case.
-
-On legacy Bluetooth 2.0 and earlier devices like mice the encryption was
-optional and thus causing an issue if the key size check is not bound to
-using Secure Simple Pairing.
-
-Fixes: d5bb334a8e17 ("Bluetooth: Align minimum encryption key size for LE and 
BR/EDR connections")
-Signed-off-by: Marcel Holtmann 
-Cc: sta...@vger.kernel.org

- net/bluetooth/hci_conn.c | 9 +++--
- 1 file changed, 7 insertions(+), 2 deletions(-)
-
-diff --git a/net/bluetooth/hci_conn.c b/net/bluetooth/hci_conn.c
-index 3cf0764d5793..7516cdde3373 100644
 a/net/bluetooth/hci_conn.c
-+++ b/net/bluetooth/hci_conn.c
-@@ -1272,8 +1272,13 @@ int hci_conn_check_link_mode(struct hci_conn *conn)
-   return 0;
-   }
- 
--  if (hci_conn_ssp_enabled(conn) &&
--  !test_bit(HCI_CONN_ENCRYPT, >flags))
-+  /* If Secure Simple Pairing is not enabled, then legacy connection
-+   * setup is used and no encryption or key sizes can be enforced.
-+   */
-+  if (!hci_conn_ssp_enabled(conn))
-+  return 1;
-+
-+  if (!test_bit(HCI_CONN_ENCRYPT, >flags))
-   return 0;
- 
-   /* The minimum encryption key size needs to be enforced by the
+diff --git a/2700_solo6x10-mem-resource-reduction-fix.patch 
b/2700_solo6x10-mem-resource-reduction-fix.patch
+new file mode 100644
+index ..bf406a92
+--- /dev/null
 b/2700_solo6x10-mem-resource-reduction-fix.patch
+@@ -0,0 +1,61 @@
++From 31e97d7c9ae3de072d7b424b2cf706a03ec10720 Mon Sep 17 00:00:00 2001
++From: Aurelien Jarno 
++Date: Sat, 13 Jan 2024 19:33:31 +0100
++Subject: media: solo6x10: replace max(a, min(b, c)) by clamp(b, a, c)
++
++This patch replaces max(a, min(b, c)) by clamp(b, a, c) in the solo6x10
++driver.  This improves the readability and more importantly, for the
++solo6x10-p2m.c file, this reduces on my system (x86-64, gcc 13):
++
++ - the preprocessed size from 121 MiB to 4.5 MiB;
++
++ - the build CPU time from 46.8 s to 1.6 s;
++
++ - the build memory from 2786 MiB to 98MiB.
++
++In fine, this allows this relatively simple C file to be built on a
++32-bit system.
++
++Reported-by: Jiri Slaby 
++Closes: 
https://lore.kernel.org/lkml/18c6df0d-45ed-450c-9eda-95160a2bb...@gmail.com/
++Cc:   # v6.7+
++Suggested-by: David Laight 
++Signed-off-by: Aurelien Jarno 
++Reviewed-by: David Laight 
++Reviewed-by: Hans Verkuil 
++Signed-off-by: Linus Torvalds 
++---
++ drivers/media/pci/solo6x10/solo6x10-offsets.h | 10 +-
++ 1 file changed, 5 insertions(+), 5 deletions(-)
++
++(limited to 'drivers/media/pci/solo6x10/solo6x10-offsets.h')
++
++diff --git a/drivers/media/pci/solo6x10/solo6x10-offsets.h 
b/drivers/media/pci/solo6x10/solo6x10-offsets.h
++index f414ee1316f29c..fdbb817e63601c 100644
++--- a/drivers/media/pci/solo6x10/solo6x10-offsets.h
+ b/drivers/media/pci/solo6x10/solo6x10-offsets.h
++@@ -57,16 +57,16 @@
++ #define SOLO_MP4E_EXT_ADDR(__solo) \
++  (SOLO_EREF_EXT_ADDR(__solo) + SOLO_EREF_EXT_AREA(__solo))
++ #define SOLO_MP4E_EXT_SIZE(__solo) \
++- max((__solo->nr_chans * 0x0008),\
++- 

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-02-05 Thread Mike Pagano
commit: 7ec517119dc4c57b9d6867de01bfe9239be96888
Author: Mike Pagano  gentoo  org>
AuthorDate: Mon Feb  5 21:04:34 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Mon Feb  5 21:04:34 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=7ec51711

Remove redundant patch

Removed:
2010_ipmr-fix-kern-panic-when-forwarding-mcast-packets.patch

Signed-off-by: Mike Pagano  gentoo.org>

 _README|   4 -
 ...-kern-panic-when-forwarding-mcast-packets.patch | 165 -
 2 files changed, 169 deletions(-)

diff --git a/_README b/_README
index 2228fc5b..f2e7d99c 100644
--- a/_README
+++ b/_README
@@ -123,10 +123,6 @@ Patch:  
2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
 From:   
https://lore.kernel.org/linux-bluetooth/20190522070540.48895-1-mar...@holtmann.org/raw
 Desc:   Bluetooth: Check key sizes only when Secure Simple Pairing is enabled. 
See bug #686758
 
-Patch:  2010_ipmr-fix-kern-panic-when-forwarding-mcast-packets.patch
-From:   https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git
-Desc:   ipmr: fix kernel panic when forwarding mcast packets
-
 Patch:  2800_amdgpu-Adj-kmalloc-array-calls-for-new-Walloc-size.patch
 From:   s...@gentoo.org
 Desc:   amdgpu: Adjust kmalloc_array calls for new -Walloc-size

diff --git a/2010_ipmr-fix-kern-panic-when-forwarding-mcast-packets.patch 
b/2010_ipmr-fix-kern-panic-when-forwarding-mcast-packets.patch
deleted file mode 100644
index b8b48252..
--- a/2010_ipmr-fix-kern-panic-when-forwarding-mcast-packets.patch
+++ /dev/null
@@ -1,165 +0,0 @@
-From e622502c310f1069fd9f41cd38210553115f610a Mon Sep 17 00:00:00 2001
-From: Nicolas Dichtel 
-Date: Thu, 25 Jan 2024 15:18:47 +0100
-Subject: ipmr: fix kernel panic when forwarding mcast packets
-
-The stacktrace was:
-[   86.305548] BUG: kernel NULL pointer dereference, address: 0092
-[   86.306815] #PF: supervisor read access in kernel mode
-[   86.307717] #PF: error_code(0x) - not-present page
-[   86.308624] PGD 0 P4D 0
-[   86.309091] Oops:  [#1] PREEMPT SMP NOPTI
-[   86.309883] CPU: 2 PID: 3139 Comm: pimd Tainted: G U 
6.8.0-6wind-knet #1
-[   86.311027] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 
rel-1.11.1-0-g0551a4be2c-prebuilt.qemu-project.org 04/01/2014
-[   86.312728] RIP: 0010:ip_mr_forward (/build/work/knet/net/ipv4/ipmr.c:1985)
-[ 86.313399] Code: f9 1f 0f 87 85 03 00 00 48 8d 04 5b 48 8d 04 83 49 8d 44 c5 
00 48 8b 40 70 48 39 c2 0f 84 d9 00 00 00 49 8b 46 58 48 83 e0 fe <80> b8 92 00 
00 00 00 0f 84 55 ff ff ff 49 83 47 38 01 45 85 e4 0f
-[   86.316565] RSP: 0018:ad21c0583ae0 EFLAGS: 00010246
-[   86.317497] RAX:  RBX:  RCX: 

-[   86.318596] RDX: 9559cb46c000 RSI:  RDI: 

-[   86.319627] RBP: ad21c0583b30 R08:  R09: 

-[   86.320650] R10:  R11:  R12: 
0001
-[   86.321672] R13: 9559c093a000 R14: 9559cc00b800 R15: 
9559c09c1d80
-[   86.322873] FS:  7f85db661980() GS:955a79d0() 
knlGS:
-[   86.324291] CS:  0010 DS:  ES:  CR0: 80050033
-[   86.325314] CR2: 0092 CR3: 2f13a000 CR4: 
00350ef0
-[   86.326589] Call Trace:
-[   86.327036]  
-[   86.327434] ? show_regs (/build/work/knet/arch/x86/kernel/dumpstack.c:479)
-[   86.328049] ? __die (/build/work/knet/arch/x86/kernel/dumpstack.c:421 
/build/work/knet/arch/x86/kernel/dumpstack.c:434)
-[   86.328508] ? page_fault_oops (/build/work/knet/arch/x86/mm/fault.c:707)
-[   86.329107] ? do_user_addr_fault (/build/work/knet/arch/x86/mm/fault.c:1264)
-[   86.329756] ? srso_return_thunk 
(/build/work/knet/arch/x86/lib/retpoline.S:223)
-[   86.330350] ? __irq_work_queue_local 
(/build/work/knet/kernel/irq_work.c:111 (discriminator 1))
-[   86.331013] ? exc_page_fault 
(/build/work/knet/./arch/x86/include/asm/paravirt.h:693 
/build/work/knet/arch/x86/mm/fault.c:1515 
/build/work/knet/arch/x86/mm/fault.c:1563)
-[   86.331702] ? asm_exc_page_fault 
(/build/work/knet/./arch/x86/include/asm/idtentry.h:570)
-[   86.332468] ? ip_mr_forward (/build/work/knet/net/ipv4/ipmr.c:1985)
-[   86.333183] ? srso_return_thunk 
(/build/work/knet/arch/x86/lib/retpoline.S:223)
-[   86.333920] ipmr_mfc_add (/build/work/knet/./include/linux/rcupdate.h:782 
/build/work/knet/net/ipv4/ipmr.c:1009 /build/work/knet/net/ipv4/ipmr.c:1273)
-[   86.334583] ? __pfx_ipmr_hash_cmp (/build/work/knet/net/ipv4/ipmr.c:363)
-[   86.335357] ip_mroute_setsockopt (/build/work/knet/net/ipv4/ipmr.c:1470)
-[   86.336135] ? srso_return_thunk 
(/build/work/knet/arch/x86/lib/retpoline.S:223)
-[   86.336854] ? ip_mroute_setsockopt (/build/work/knet/net/ipv4/ipmr.c:1470)
-[   86.337679] do_ip_setsockopt (/build/work/knet/net/ipv4/ip_sockglue.c:944)
-[   

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-02-01 Thread Mike Pagano
commit: 4c4bbbce81aa627f494af184dd6edc3ed2cb4fd4
Author: Mike Pagano  gentoo  org>
AuthorDate: Thu Feb  1 23:18:32 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Thu Feb  1 23:18:32 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=4c4bbbce

ipmr: fix kernel panic when forwarding mcast packets

Bug: https://bugs.gentoo.org/923372

Signed-off-by: Mike Pagano  gentoo.org>

 _README|   4 +
 ...-kern-panic-when-forwarding-mcast-packets.patch | 165 +
 2 files changed, 169 insertions(+)

diff --git a/_README b/_README
index f27cebb4..94c47ec5 100644
--- a/_README
+++ b/_README
@@ -119,6 +119,10 @@ Patch:  
2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
 From:   
https://lore.kernel.org/linux-bluetooth/20190522070540.48895-1-mar...@holtmann.org/raw
 Desc:   Bluetooth: Check key sizes only when Secure Simple Pairing is enabled. 
See bug #686758
 
+Patch:  2010_ipmr-fix-kern-panic-when-forwarding-mcast-packets.patch
+From:   https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git
+Desc:   ipmr: fix kernel panic when forwarding mcast packets
+
 Patch:  2800_amdgpu-Adj-kmalloc-array-calls-for-new-Walloc-size.patch
 From:   s...@gentoo.org
 Desc:   amdgpu: Adjust kmalloc_array calls for new -Walloc-size

diff --git a/2010_ipmr-fix-kern-panic-when-forwarding-mcast-packets.patch 
b/2010_ipmr-fix-kern-panic-when-forwarding-mcast-packets.patch
new file mode 100644
index ..b8b48252
--- /dev/null
+++ b/2010_ipmr-fix-kern-panic-when-forwarding-mcast-packets.patch
@@ -0,0 +1,165 @@
+From e622502c310f1069fd9f41cd38210553115f610a Mon Sep 17 00:00:00 2001
+From: Nicolas Dichtel 
+Date: Thu, 25 Jan 2024 15:18:47 +0100
+Subject: ipmr: fix kernel panic when forwarding mcast packets
+
+The stacktrace was:
+[   86.305548] BUG: kernel NULL pointer dereference, address: 0092
+[   86.306815] #PF: supervisor read access in kernel mode
+[   86.307717] #PF: error_code(0x) - not-present page
+[   86.308624] PGD 0 P4D 0
+[   86.309091] Oops:  [#1] PREEMPT SMP NOPTI
+[   86.309883] CPU: 2 PID: 3139 Comm: pimd Tainted: G U 
6.8.0-6wind-knet #1
+[   86.311027] Hardware name: QEMU Standard PC (i440FX + PIIX, 1996), BIOS 
rel-1.11.1-0-g0551a4be2c-prebuilt.qemu-project.org 04/01/2014
+[   86.312728] RIP: 0010:ip_mr_forward (/build/work/knet/net/ipv4/ipmr.c:1985)
+[ 86.313399] Code: f9 1f 0f 87 85 03 00 00 48 8d 04 5b 48 8d 04 83 49 8d 44 c5 
00 48 8b 40 70 48 39 c2 0f 84 d9 00 00 00 49 8b 46 58 48 83 e0 fe <80> b8 92 00 
00 00 00 0f 84 55 ff ff ff 49 83 47 38 01 45 85 e4 0f
+[   86.316565] RSP: 0018:ad21c0583ae0 EFLAGS: 00010246
+[   86.317497] RAX:  RBX:  RCX: 

+[   86.318596] RDX: 9559cb46c000 RSI:  RDI: 

+[   86.319627] RBP: ad21c0583b30 R08:  R09: 

+[   86.320650] R10:  R11:  R12: 
0001
+[   86.321672] R13: 9559c093a000 R14: 9559cc00b800 R15: 
9559c09c1d80
+[   86.322873] FS:  7f85db661980() GS:955a79d0() 
knlGS:
+[   86.324291] CS:  0010 DS:  ES:  CR0: 80050033
+[   86.325314] CR2: 0092 CR3: 2f13a000 CR4: 
00350ef0
+[   86.326589] Call Trace:
+[   86.327036]  
+[   86.327434] ? show_regs (/build/work/knet/arch/x86/kernel/dumpstack.c:479)
+[   86.328049] ? __die (/build/work/knet/arch/x86/kernel/dumpstack.c:421 
/build/work/knet/arch/x86/kernel/dumpstack.c:434)
+[   86.328508] ? page_fault_oops (/build/work/knet/arch/x86/mm/fault.c:707)
+[   86.329107] ? do_user_addr_fault (/build/work/knet/arch/x86/mm/fault.c:1264)
+[   86.329756] ? srso_return_thunk 
(/build/work/knet/arch/x86/lib/retpoline.S:223)
+[   86.330350] ? __irq_work_queue_local 
(/build/work/knet/kernel/irq_work.c:111 (discriminator 1))
+[   86.331013] ? exc_page_fault 
(/build/work/knet/./arch/x86/include/asm/paravirt.h:693 
/build/work/knet/arch/x86/mm/fault.c:1515 
/build/work/knet/arch/x86/mm/fault.c:1563)
+[   86.331702] ? asm_exc_page_fault 
(/build/work/knet/./arch/x86/include/asm/idtentry.h:570)
+[   86.332468] ? ip_mr_forward (/build/work/knet/net/ipv4/ipmr.c:1985)
+[   86.333183] ? srso_return_thunk 
(/build/work/knet/arch/x86/lib/retpoline.S:223)
+[   86.333920] ipmr_mfc_add (/build/work/knet/./include/linux/rcupdate.h:782 
/build/work/knet/net/ipv4/ipmr.c:1009 /build/work/knet/net/ipv4/ipmr.c:1273)
+[   86.334583] ? __pfx_ipmr_hash_cmp (/build/work/knet/net/ipv4/ipmr.c:363)
+[   86.335357] ip_mroute_setsockopt (/build/work/knet/net/ipv4/ipmr.c:1470)
+[   86.336135] ? srso_return_thunk 
(/build/work/knet/arch/x86/lib/retpoline.S:223)
+[   86.336854] ? ip_mroute_setsockopt (/build/work/knet/net/ipv4/ipmr.c:1470)
+[   86.337679] do_ip_setsockopt (/build/work/knet/net/ipv4/ip_sockglue.c:944)
+[   86.338408] ? 

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-01-26 Thread Mike Pagano
commit: 31b6dfccf106853fa2a070de8cece9ea4761629c
Author: Mike Pagano  gentoo  org>
AuthorDate: Fri Jan 26 22:48:23 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Fri Jan 26 22:48:23 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=31b6dfcc

amdgpu: Adjust kmalloc_array calls for new -Walloc-size

Signed-off-by: Mike Pagano  gentoo.org>

 _README|   4 +
 ...j-kmalloc-array-calls-for-new-Walloc-size.patch | 124 +
 2 files changed, 128 insertions(+)

diff --git a/_README b/_README
index 03172d84..b187f62e 100644
--- a/_README
+++ b/_README
@@ -115,6 +115,10 @@ Patch:  
2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
 From:   
https://lore.kernel.org/linux-bluetooth/20190522070540.48895-1-mar...@holtmann.org/raw
 Desc:   Bluetooth: Check key sizes only when Secure Simple Pairing is enabled. 
See bug #686758
 
+Patch:  2800_amdgpu-Adj-kmalloc-array-calls-for-new-Walloc-size.patch
+From:   s...@gentoo.org
+Desc:   amdgpu: Adjust kmalloc_array calls for new -Walloc-size
+
 Patch:  2900_tmp513-Fix-build-issue-by-selecting-CONFIG_REG.patch
 From:   https://bugs.gentoo.org/710790
 Desc:   tmp513 requies REGMAP_I2C to build.  Select it by default in Kconfig. 
See bug #710790. Thanks to Phil Stracchino

diff --git a/2800_amdgpu-Adj-kmalloc-array-calls-for-new-Walloc-size.patch 
b/2800_amdgpu-Adj-kmalloc-array-calls-for-new-Walloc-size.patch
new file mode 100644
index ..798ac040
--- /dev/null
+++ b/2800_amdgpu-Adj-kmalloc-array-calls-for-new-Walloc-size.patch
@@ -0,0 +1,124 @@
+From: Sam James 
+To: amd-...@lists.freedesktop.org, dri-de...@lists.freedesktop.org
+Cc: linux-ker...@vger.kernel.org, Sam James 
+Subject: [PATCH] amdgpu: Adjust kmalloc_array calls for new -Walloc-size
+Date: Sun,  5 Nov 2023 16:06:50 +  [thread overview]
+Message-ID: <20231105160652.374422-1-...@gentoo.org> (raw)
+In-Reply-To: <87wmuwo7i3@gentoo.org>
+
+GCC 14 introduces a new -Walloc-size included in -Wextra which errors out
+on various files in drivers/gpu/drm/amd/amdgpu like:
+```
+amdgpu_amdkfd_gfx_v8.c:241:15: error: allocation of insufficient size ‘4’ for 
type ‘uint32_t[2]’ {aka ‘unsigned int[2]'} with size ‘8’ [-Werror=alloc-size]
+```
+
+This is because each HQD_N_REGS is actually a uint32_t[2]. Move the * 2 to
+the size argument so GCC sees we're allocating enough.
+
+Originally did 'sizeof(uint32_t) * 2' for the size but a friend suggested
+'sizeof(**dump)' better communicates the intent.
+
+Link: https://lore.kernel.org/all/87wmuwo7i3@gentoo.org/
+Signed-off-by: Sam James 
+---
+ drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_arcturus.c | 2 +-
+ drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gc_9_4_3.c | 2 +-
+ drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v7.c   | 4 ++--
+ drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v8.c   | 4 ++--
+ drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v9.c   | 4 ++--
+ 5 files changed, 8 insertions(+), 8 deletions(-)
+
+diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_arcturus.c 
b/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_arcturus.c
+index 625db444df1c..0ba15dcbe4e1 100644
+--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_arcturus.c
 b/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_arcturus.c
+@@ -200,7 +200,7 @@ int kgd_arcturus_hqd_sdma_dump(struct amdgpu_device *adev,
+ #undef HQD_N_REGS
+ #define HQD_N_REGS (19+6+7+10)
+ 
+-  *dump = kmalloc_array(HQD_N_REGS * 2, sizeof(uint32_t), GFP_KERNEL);
++  *dump = kmalloc_array(HQD_N_REGS, sizeof(**dump), GFP_KERNEL);
+   if (*dump == NULL)
+   return -ENOMEM;
+ 
+diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gc_9_4_3.c 
b/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gc_9_4_3.c
+index 490c8f5ddb60..ca7238b5535b 100644
+--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gc_9_4_3.c
 b/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gc_9_4_3.c
+@@ -141,7 +141,7 @@ static int kgd_gfx_v9_4_3_hqd_sdma_dump(struct 
amdgpu_device *adev,
+   (*dump)[i++][1] = RREG32(addr); \
+   } while (0)
+ 
+-  *dump = kmalloc_array(HQD_N_REGS * 2, sizeof(uint32_t), GFP_KERNEL);
++  *dump = kmalloc_array(HQD_N_REGS, sizeof(**dump), GFP_KERNEL);
+   if (*dump == NULL)
+   return -ENOMEM;
+ 
+diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v7.c 
b/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v7.c
+index 6bf448ab3dff..ca4a6b82817f 100644
+--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v7.c
 b/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gfx_v7.c
+@@ -214,7 +214,7 @@ static int kgd_hqd_dump(struct amdgpu_device *adev,
+   (*dump)[i++][1] = RREG32(addr); \
+   } while (0)
+ 
+-  *dump = kmalloc_array(HQD_N_REGS * 2, sizeof(uint32_t), GFP_KERNEL);
++  *dump = kmalloc_array(HQD_N_REGS, sizeof(**dump), GFP_KERNEL);
+   if (*dump == NULL)
+   return -ENOMEM;
+ 
+@@ -301,7 +301,7 @@ static int 

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-01-25 Thread Mike Pagano
commit: 61e9ad963d9ed3cf33c289e866f0cc07eb649478
Author: Mike Pagano  gentoo  org>
AuthorDate: Thu Jan 25 13:48:59 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Thu Jan 25 13:48:59 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=61e9ad96

gcc-14 patches

btrfs: fix kvcalloc() arguments order
drm: i915: Adapt to -Walloc-size
objtool: Fix calloc call for new -Walloc-size

Signed-off-by: Mike Pagano  gentoo.org>

 _README| 12 +++
 2930_gcc14-btrfs-fix-kvcalloc-args-order.patch | 37 +++
 2931_gcc14-drm-i915-Adapt-to-Walloc-size.patch | 37 +++
 ...jtool-Fix-calloc-call-for-new-Walloc-size.patch | 41 ++
 4 files changed, 127 insertions(+)

diff --git a/_README b/_README
index b98499ab..ab82fe93 100644
--- a/_README
+++ b/_README
@@ -123,6 +123,18 @@ Patch:  2920_sign-file-patch-for-libressl.patch
 From:   https://bugs.gentoo.org/717166
 Desc:   sign-file: full functionality with modern LibreSSL
 
+Patch:  2930_gcc14-btrfs-fix-kvcalloc-args-order.patch
+From:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
+Desc:   btrfs: fix kvcalloc() arguments order
+
+Patch:  2931_gcc14-drm-i915-Adapt-to-Walloc-size.patch
+From:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
+Desc:   drm: i915: Adapt to -Walloc-size
+
+Patch:  2932_gcc14-objtool-Fix-calloc-call-for-new-Walloc-size.patch
+From:   https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
+Desc:   objtool: Fix calloc call for new -Walloc-size
+
 Patch:  3000_Support-printing-firmware-info.patch
 From:   https://bugs.gentoo.org/732852
 Desc:   Print firmware info (Reqs CONFIG_GENTOO_PRINT_FIRMWARE_INFO). Thanks 
to Georgy Yakovlev

diff --git a/2930_gcc14-btrfs-fix-kvcalloc-args-order.patch 
b/2930_gcc14-btrfs-fix-kvcalloc-args-order.patch
new file mode 100644
index ..0ed049e2
--- /dev/null
+++ b/2930_gcc14-btrfs-fix-kvcalloc-args-order.patch
@@ -0,0 +1,37 @@
+Subject: [gcc-14 PATCH] btrfs: fix kvcalloc() arguments order
+
+When compiling with gcc version 14.0.0 20231220 (experimental)
+and W=1, I've noticed the following warning:
+
+fs/btrfs/send.c: In function 'btrfs_ioctl_send':
+fs/btrfs/send.c:8208:44: warning: 'kvcalloc' sizes specified with 'sizeof'
+in the earlier argument and not in the later argument 
[-Wcalloc-transposed-args]
+ 8208 | sctx->clone_roots = kvcalloc(sizeof(*sctx->clone_roots),
+  |^
+
+Since 'n' and 'size' arguments of 'kvcalloc()' are multiplied to
+calculate the final size, their actual order doesn't affect the
+result and so this is not a bug. But it's still worth to fix it.
+
+Link: 
https://lore.kernel.org/linux-btrfs/20231221084748.10094-1-dmanti...@yandex.ru/T/#u
+---
+ fs/btrfs/send.c | 4 ++--
+ 1 file changed, 2 insertions(+), 2 deletions(-)
+
+diff --git a/fs/btrfs/send.c b/fs/btrfs/send.c
+index 4e36550618e5..2d7519a6ce72 100644
+--- a/fs/btrfs/send.c
 b/fs/btrfs/send.c
+@@ -8205,8 +8205,8 @@ long btrfs_ioctl_send(struct inode *inode, struct 
btrfs_ioctl_send_args *arg)
+   goto out;
+   }
+ 
+-  sctx->clone_roots = kvcalloc(sizeof(*sctx->clone_roots),
+-   arg->clone_sources_count + 1,
++  sctx->clone_roots = kvcalloc(arg->clone_sources_count + 1,
++   sizeof(*sctx->clone_roots),
+GFP_KERNEL);
+   if (!sctx->clone_roots) {
+   ret = -ENOMEM;
+-- 
+2.43.0

diff --git a/2931_gcc14-drm-i915-Adapt-to-Walloc-size.patch 
b/2931_gcc14-drm-i915-Adapt-to-Walloc-size.patch
new file mode 100644
index ..b6f6ab38
--- /dev/null
+++ b/2931_gcc14-drm-i915-Adapt-to-Walloc-size.patch
@@ -0,0 +1,37 @@
+Subject: [gcc-14 PATCH] drm: i915: Adapt to -Walloc-size
+
+GCC 14 introduces a new -Walloc-size included in -Wextra which errors out
+like:
+```
+drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c: In function 
‘eb_copy_relocations’:
+drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c:1681:24: error: allocation of 
insufficient size ‘1’ for type ‘struct drm_i915_gem_relocation_entry’ with size 
‘32’ [-Werror=alloc-size]
+ 1681 | relocs = kvmalloc_array(size, 1, GFP_KERNEL);
+  |^
+
+```
+
+So, just swap the number of members and size arguments to match the prototype, 
as
+we're initialising 1 element of size `size`. GCC then sees we're not
+doing anything wrong.
+
+Link: 
https://lore.kernel.org/intel-gfx/20231107215538.1891359-1-...@gentoo.org/
+Signed-off-by: Sam James 
+---
+ drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c 
b/drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c
+index 683fd8d3151c..45b9d9e34b8b 100644
+--- 

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-01-15 Thread Mike Pagano
commit: c489f53b3c356043758921cd6bc5f51726c38838
Author: Mike Pagano  gentoo  org>
AuthorDate: Mon Jan 15 18:46:40 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Mon Jan 15 18:46:40 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=c489f53b

Linux patch 6.6.12

Signed-off-by: Mike Pagano  gentoo.org>

 _README |   4 ++
 1011_linux-6.6.12.patch | 115 
 2 files changed, 119 insertions(+)

diff --git a/_README b/_README
index 9b293de9..deb29f71 100644
--- a/_README
+++ b/_README
@@ -87,6 +87,10 @@ Patch:  1010_linux-6.6.11.patch
 From:   https://www.kernel.org
 Desc:   Linux 6.6.11
 
+Patch:  1011_linux-6.6.12.patch
+From:   https://www.kernel.org
+Desc:   Linux 6.6.12
+
 Patch:  1510_fs-enable-link-security-restrictions-by-default.patch
 From:   
http://sources.debian.net/src/linux/3.16.7-ckt4-3/debian/patches/debian/fs-enable-link-security-restrictions-by-default.patch/
 Desc:   Enable link security restrictions by default.

diff --git a/1011_linux-6.6.12.patch b/1011_linux-6.6.12.patch
new file mode 100644
index ..896e081e
--- /dev/null
+++ b/1011_linux-6.6.12.patch
@@ -0,0 +1,115 @@
+diff --git a/Makefile b/Makefile
+index 43edafa7f262d..a05c69afc0458 100644
+--- a/Makefile
 b/Makefile
+@@ -1,7 +1,7 @@
+ # SPDX-License-Identifier: GPL-2.0
+ VERSION = 6
+ PATCHLEVEL = 6
+-SUBLEVEL = 11
++SUBLEVEL = 12
+ EXTRAVERSION =
+ NAME = Hurr durr I'ma ninja sloth
+ 
+diff --git a/fs/nfsd/nfsctl.c b/fs/nfsd/nfsctl.c
+index 98854dd3c1502..a13e81e450718 100644
+--- a/fs/nfsd/nfsctl.c
 b/fs/nfsd/nfsctl.c
+@@ -692,6 +692,7 @@ static ssize_t __write_ports_addfd(char *buf, struct net 
*net, const struct cred
+   char *mesg = buf;
+   int fd, err;
+   struct nfsd_net *nn = net_generic(net, nfsd_net_id);
++  struct svc_serv *serv;
+ 
+   err = get_int(, );
+   if (err != 0 || fd < 0)
+@@ -702,15 +703,15 @@ static ssize_t __write_ports_addfd(char *buf, struct net 
*net, const struct cred
+   if (err != 0)
+   return err;
+ 
+-  err = svc_addsock(nn->nfsd_serv, net, fd, buf, 
SIMPLE_TRANSACTION_LIMIT, cred);
++  serv = nn->nfsd_serv;
++  err = svc_addsock(serv, net, fd, buf, SIMPLE_TRANSACTION_LIMIT, cred);
+ 
+-  if (err < 0 && !nn->nfsd_serv->sv_nrthreads && !nn->keep_active)
++  if (err < 0 && !serv->sv_nrthreads && !nn->keep_active)
+   nfsd_last_thread(net);
+-  else if (err >= 0 &&
+-   !nn->nfsd_serv->sv_nrthreads && !xchg(>keep_active, 1))
+-  svc_get(nn->nfsd_serv);
++  else if (err >= 0 && !serv->sv_nrthreads && !xchg(>keep_active, 1))
++  svc_get(serv);
+ 
+-  nfsd_put(net);
++  svc_put(serv);
+   return err;
+ }
+ 
+@@ -724,6 +725,7 @@ static ssize_t __write_ports_addxprt(char *buf, struct net 
*net, const struct cr
+   struct svc_xprt *xprt;
+   int port, err;
+   struct nfsd_net *nn = net_generic(net, nfsd_net_id);
++  struct svc_serv *serv;
+ 
+   if (sscanf(buf, "%15s %5u", transport, ) != 2)
+   return -EINVAL;
+@@ -736,32 +738,33 @@ static ssize_t __write_ports_addxprt(char *buf, struct 
net *net, const struct cr
+   if (err != 0)
+   return err;
+ 
+-  err = svc_xprt_create(nn->nfsd_serv, transport, net,
++  serv = nn->nfsd_serv;
++  err = svc_xprt_create(serv, transport, net,
+ PF_INET, port, SVC_SOCK_ANONYMOUS, cred);
+   if (err < 0)
+   goto out_err;
+ 
+-  err = svc_xprt_create(nn->nfsd_serv, transport, net,
++  err = svc_xprt_create(serv, transport, net,
+ PF_INET6, port, SVC_SOCK_ANONYMOUS, cred);
+   if (err < 0 && err != -EAFNOSUPPORT)
+   goto out_close;
+ 
+-  if (!nn->nfsd_serv->sv_nrthreads && !xchg(>keep_active, 1))
+-  svc_get(nn->nfsd_serv);
++  if (!serv->sv_nrthreads && !xchg(>keep_active, 1))
++  svc_get(serv);
+ 
+-  nfsd_put(net);
++  svc_put(serv);
+   return 0;
+ out_close:
+-  xprt = svc_find_xprt(nn->nfsd_serv, transport, net, PF_INET, port);
++  xprt = svc_find_xprt(serv, transport, net, PF_INET, port);
+   if (xprt != NULL) {
+   svc_xprt_close(xprt);
+   svc_xprt_put(xprt);
+   }
+ out_err:
+-  if (!nn->nfsd_serv->sv_nrthreads && !nn->keep_active)
++  if (!serv->sv_nrthreads && !nn->keep_active)
+   nfsd_last_thread(net);
+ 
+-  nfsd_put(net);
++  svc_put(serv);
+   return err;
+ }
+ 
+diff --git a/fs/nfsd/nfsd.h b/fs/nfsd/nfsd.h
+index 63deed27a9059..fe846a360ae18 100644
+--- a/fs/nfsd/nfsd.h
 b/fs/nfsd/nfsd.h
+@@ -96,13 +96,6 @@ int nfsd_pool_stats_open(struct inode *, struct 
file *);
+ int   nfsd_pool_stats_release(struct inode *, struct file *);
+ void  nfsd_shutdown_threads(struct net *net);
+ 
+-static 

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-01-10 Thread Mike Pagano
commit: 65f05847b176e3e8d57ec10dfd1bddf15d458209
Author: Mike Pagano  gentoo  org>
AuthorDate: Wed Jan 10 17:20:12 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Wed Jan 10 17:20:12 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=65f05847

Drop redundant path

Dropped:
2410_iwlwifi-rfkill-fix.patch

Signed-off-by: Mike Pagano  gentoo.org>

 _README   |   4 -
 2410_iwlwifi-rfkill-fix.patch | 170 --
 2 files changed, 174 deletions(-)

diff --git a/_README b/_README
index 1220fc22..9b293de9 100644
--- a/_README
+++ b/_README
@@ -103,10 +103,6 @@ Patch:  
2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
 From:   
https://lore.kernel.org/linux-bluetooth/20190522070540.48895-1-mar...@holtmann.org/raw
 Desc:   Bluetooth: Check key sizes only when Secure Simple Pairing is enabled. 
See bug #686758
 
-Patch:  2410_iwlwifi-rfkill-fix.patch
-From:   https://bugzilla.kernel.org/show_bug.cgi?id=218206
-Desc:   fix for iwlwifi pcie synchronization of IRQs before NAPI
-
 Patch:  2900_tmp513-Fix-build-issue-by-selecting-CONFIG_REG.patch
 From:   https://bugs.gentoo.org/710790
 Desc:   tmp513 requies REGMAP_I2C to build.  Select it by default in Kconfig. 
See bug #710790. Thanks to Phil Stracchino

diff --git a/2410_iwlwifi-rfkill-fix.patch b/2410_iwlwifi-rfkill-fix.patch
deleted file mode 100644
index 02994243..
--- a/2410_iwlwifi-rfkill-fix.patch
+++ /dev/null
@@ -1,170 +0,0 @@
-diff --git a/drivers/net/wireless/intel/iwlwifi/pcie/internal.h 
b/drivers/net/wireless/intel/iwlwifi/pcie/internal.h
-index 56def20374f3..abdb687e7274 100644
 a/drivers/net/wireless/intel/iwlwifi/pcie/internal.h
-+++ b/drivers/net/wireless/intel/iwlwifi/pcie/internal.h
-@@ -770,7 +770,7 @@ static inline void iwl_enable_rfkill_int(struct iwl_trans 
*trans)
-   }
- }
- 
--void iwl_pcie_handle_rfkill_irq(struct iwl_trans *trans);
-+void iwl_pcie_handle_rfkill_irq(struct iwl_trans *trans, bool from_irq);
- 
- static inline bool iwl_is_rfkill_set(struct iwl_trans *trans)
- {
-@@ -817,7 +817,7 @@ static inline bool iwl_pcie_dbg_on(struct iwl_trans *trans)
-   return (trans->dbg.dest_tlv || iwl_trans_dbg_ini_valid(trans));
- }
- 
--void iwl_trans_pcie_rf_kill(struct iwl_trans *trans, bool state);
-+void iwl_trans_pcie_rf_kill(struct iwl_trans *trans, bool state, bool 
from_irq);
- void iwl_trans_pcie_dump_regs(struct iwl_trans *trans);
- 
- #ifdef CONFIG_IWLWIFI_DEBUGFS
-@@ -853,7 +853,7 @@ void iwl_trans_pcie_gen2_fw_alive(struct iwl_trans *trans, 
u32 scd_addr);
- int iwl_trans_pcie_gen2_send_hcmd(struct iwl_trans *trans,
- struct iwl_host_cmd *cmd);
- void iwl_trans_pcie_gen2_stop_device(struct iwl_trans *trans);
--void _iwl_trans_pcie_gen2_stop_device(struct iwl_trans *trans);
-+void _iwl_trans_pcie_gen2_stop_device(struct iwl_trans *trans, bool from_irq);
- void iwl_pcie_d3_complete_suspend(struct iwl_trans *trans,
- bool test, bool reset);
- int iwl_pcie_gen2_enqueue_hcmd(struct iwl_trans *trans,
-diff --git a/drivers/net/wireless/intel/iwlwifi/pcie/rx.c 
b/drivers/net/wireless/intel/iwlwifi/pcie/rx.c
-index 146bc7bd14fb..a0d10df0c11a 100644
 a/drivers/net/wireless/intel/iwlwifi/pcie/rx.c
-+++ b/drivers/net/wireless/intel/iwlwifi/pcie/rx.c
-@@ -1783,7 +1783,7 @@ static u32 iwl_pcie_int_cause_ict(struct iwl_trans 
*trans)
-   return inta;
- }
- 
--void iwl_pcie_handle_rfkill_irq(struct iwl_trans *trans)
-+void iwl_pcie_handle_rfkill_irq(struct iwl_trans *trans, bool from_irq)
- {
-   struct iwl_trans_pcie *trans_pcie = IWL_TRANS_GET_PCIE_TRANS(trans);
-   struct isr_statistics *isr_stats = _pcie->isr_stats;
-@@ -1807,7 +1807,7 @@ void iwl_pcie_handle_rfkill_irq(struct iwl_trans *trans)
-   isr_stats->rfkill++;
- 
-   if (prev != report)
--  iwl_trans_pcie_rf_kill(trans, report);
-+  iwl_trans_pcie_rf_kill(trans, report, from_irq);
-   mutex_unlock(_pcie->mutex);
- 
-   if (hw_rfkill) {
-@@ -1947,7 +1947,7 @@ irqreturn_t iwl_pcie_irq_handler(int irq, void *dev_id)
- 
-   /* HW RF KILL switch toggled */
-   if (inta & CSR_INT_BIT_RF_KILL) {
--  iwl_pcie_handle_rfkill_irq(trans);
-+  iwl_pcie_handle_rfkill_irq(trans, true);
-   handled |= CSR_INT_BIT_RF_KILL;
-   }
- 
-@@ -2370,7 +2370,7 @@ irqreturn_t iwl_pcie_irq_msix_handler(int irq, void 
*dev_id)
- 
-   /* HW RF KILL switch toggled */
-   if (inta_hw & MSIX_HW_INT_CAUSES_REG_RF_KILL)
--  iwl_pcie_handle_rfkill_irq(trans);
-+  iwl_pcie_handle_rfkill_irq(trans, true);
- 
-   if (inta_hw & MSIX_HW_INT_CAUSES_REG_HW_ERR) {
-   IWL_ERR(trans,
-diff --git a/drivers/net/wireless/intel/iwlwifi/pcie/trans-gen2.c 
b/drivers/net/wireless/intel/iwlwifi/pcie/trans-gen2.c
-index c9e5bda8f0b7..a3b90c6422b9 100644
 

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-01-05 Thread Mike Pagano
commit: 74cc7dae5d8fef6cd8c0a213169e7d874744ac8b
Author: Mike Pagano  gentoo  org>
AuthorDate: Fri Jan  5 14:49:01 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Fri Jan  5 14:49:01 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=74cc7dae

Linux patch 6.6.10

Signed-off-by: Mike Pagano  gentoo.org>

 _README |4 +
 1009_linux-6.6.10.patch | 3079 +++
 2 files changed, 3083 insertions(+)

diff --git a/_README b/_README
index ba4ab189..254c9fb5 100644
--- a/_README
+++ b/_README
@@ -79,6 +79,10 @@ Patch:  1008_linux-6.6.9.patch
 From:   https://www.kernel.org
 Desc:   Linux 6.6.9
 
+Patch:  1009_linux-6.6.10.patch
+From:   https://www.kernel.org
+Desc:   Linux 6.6.10
+
 Patch:  1510_fs-enable-link-security-restrictions-by-default.patch
 From:   
http://sources.debian.net/src/linux/3.16.7-ckt4-3/debian/patches/debian/fs-enable-link-security-restrictions-by-default.patch/
 Desc:   Enable link security restrictions by default.

diff --git a/1009_linux-6.6.10.patch b/1009_linux-6.6.10.patch
new file mode 100644
index ..acf6fba3
--- /dev/null
+++ b/1009_linux-6.6.10.patch
@@ -0,0 +1,3079 @@
+diff --git a/Makefile b/Makefile
+index 4d1d5e925bb28..50a862316e156 100644
+--- a/Makefile
 b/Makefile
+@@ -1,7 +1,7 @@
+ # SPDX-License-Identifier: GPL-2.0
+ VERSION = 6
+ PATCHLEVEL = 6
+-SUBLEVEL = 9
++SUBLEVEL = 10
+ EXTRAVERSION =
+ NAME = Hurr durr I'ma ninja sloth
+ 
+diff --git a/arch/powerpc/Kconfig b/arch/powerpc/Kconfig
+index d5d5388973ac7..4640cee33f123 100644
+--- a/arch/powerpc/Kconfig
 b/arch/powerpc/Kconfig
+@@ -607,10 +607,10 @@ config ARCH_SUPPORTS_KEXEC
+   def_bool PPC_BOOK3S || PPC_E500 || (44x && !SMP)
+ 
+ config ARCH_SUPPORTS_KEXEC_FILE
+-  def_bool PPC64 && CRYPTO=y && CRYPTO_SHA256=y
++  def_bool PPC64
+ 
+ config ARCH_SUPPORTS_KEXEC_PURGATORY
+-  def_bool KEXEC_FILE
++  def_bool y
+ 
+ config ARCH_SELECTS_KEXEC_FILE
+   def_bool y
+diff --git a/arch/riscv/Kconfig b/arch/riscv/Kconfig
+index 6688cbbed0b42..9e6d442773eea 100644
+--- a/arch/riscv/Kconfig
 b/arch/riscv/Kconfig
+@@ -686,9 +686,7 @@ config ARCH_SELECTS_KEXEC_FILE
+   select KEXEC_ELF
+ 
+ config ARCH_SUPPORTS_KEXEC_PURGATORY
+-  def_bool KEXEC_FILE
+-  depends on CRYPTO=y
+-  depends on CRYPTO_SHA256=y
++  def_bool ARCH_SUPPORTS_KEXEC_FILE
+ 
+ config ARCH_SUPPORTS_CRASH_DUMP
+   def_bool y
+diff --git a/arch/s390/Kconfig b/arch/s390/Kconfig
+index ae29e4392664a..bd4782f23f66d 100644
+--- a/arch/s390/Kconfig
 b/arch/s390/Kconfig
+@@ -252,13 +252,13 @@ config ARCH_SUPPORTS_KEXEC
+   def_bool y
+ 
+ config ARCH_SUPPORTS_KEXEC_FILE
+-  def_bool CRYPTO && CRYPTO_SHA256 && CRYPTO_SHA256_S390
++  def_bool y
+ 
+ config ARCH_SUPPORTS_KEXEC_SIG
+   def_bool MODULE_SIG_FORMAT
+ 
+ config ARCH_SUPPORTS_KEXEC_PURGATORY
+-  def_bool KEXEC_FILE
++  def_bool y
+ 
+ config ARCH_SUPPORTS_CRASH_DUMP
+   def_bool y
+diff --git a/arch/x86/Kconfig b/arch/x86/Kconfig
+index 66bfabae88149..fe3292e310d48 100644
+--- a/arch/x86/Kconfig
 b/arch/x86/Kconfig
+@@ -2034,7 +2034,7 @@ config ARCH_SUPPORTS_KEXEC
+   def_bool y
+ 
+ config ARCH_SUPPORTS_KEXEC_FILE
+-  def_bool X86_64 && CRYPTO && CRYPTO_SHA256
++  def_bool X86_64
+ 
+ config ARCH_SELECTS_KEXEC_FILE
+   def_bool y
+@@ -2042,7 +2042,7 @@ config ARCH_SELECTS_KEXEC_FILE
+   select HAVE_IMA_KEXEC if IMA
+ 
+ config ARCH_SUPPORTS_KEXEC_PURGATORY
+-  def_bool KEXEC_FILE
++  def_bool y
+ 
+ config ARCH_SUPPORTS_KEXEC_SIG
+   def_bool y
+diff --git a/drivers/nvme/host/fc.c b/drivers/nvme/host/fc.c
+index a15b37750d6e9..206f1b4e5eb1c 100644
+--- a/drivers/nvme/host/fc.c
 b/drivers/nvme/host/fc.c
+@@ -2548,24 +2548,17 @@ nvme_fc_error_recovery(struct nvme_fc_ctrl *ctrl, char 
*errmsg)
+* the controller.  Abort any ios on the association and let the
+* create_association error path resolve things.
+*/
+-  enum nvme_ctrl_state state;
+-  unsigned long flags;
+-
+-  spin_lock_irqsave(>lock, flags);
+-  state = ctrl->ctrl.state;
+-  if (state == NVME_CTRL_CONNECTING) {
+-  set_bit(ASSOC_FAILED, >flags);
+-  spin_unlock_irqrestore(>lock, flags);
++  if (ctrl->ctrl.state == NVME_CTRL_CONNECTING) {
+   __nvme_fc_abort_outstanding_ios(ctrl, true);
++  set_bit(ASSOC_FAILED, >flags);
+   dev_warn(ctrl->ctrl.device,
+   "NVME-FC{%d}: transport error during (re)connect\n",
+   ctrl->cnum);
+   return;
+   }
+-  spin_unlock_irqrestore(>lock, flags);
+ 
+   /* Otherwise, only proceed if in LIVE state - e.g. on first error */
+-  if (state != NVME_CTRL_LIVE)
++  if (ctrl->ctrl.state != NVME_CTRL_LIVE)
+   return;
+ 
+   dev_warn(ctrl->ctrl.device,
+@@ -3179,16 

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2024-01-04 Thread Mike Pagano
commit: 360e6b6a041b776ef0623be73a0d67c7571baa73
Author: Mike Pagano  gentoo  org>
AuthorDate: Thu Jan  4 15:36:31 2024 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Thu Jan  4 15:36:31 2024 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=360e6b6a

Update CPU Optimization patch

Signed-off-by: Mike Pagano  gentoo.org>

 _README   | 2 +-
 5010_enable-cpu-optimizations-universal.patch | 6 --
 2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/_README b/_README
index f89b37ae..ba4ab189 100644
--- a/_README
+++ b/_README
@@ -121,4 +121,4 @@ Desc:   Add Gentoo Linux support config settings and 
defaults.
 
 Patch:  5010_enable-cpu-optimizations-universal.patch
 From:   https://github.com/graysky2/kernel_compiler_patch
-Desc:   Kernel >= 5.15 patch enables gcc = v11.1+ optimizations for additional 
CPUs.
+Desc:   Kernel >= 5.17 patch enables gcc = v11.1+ optimizations for additional 
CPUs.

diff --git a/5010_enable-cpu-optimizations-universal.patch 
b/5010_enable-cpu-optimizations-universal.patch
index 7a1b717a..6edd3db9 100644
--- a/5010_enable-cpu-optimizations-universal.patch
+++ b/5010_enable-cpu-optimizations-universal.patch
@@ -13,9 +13,10 @@ offered which are good for supported Intel or AMD CPUs:
 • x86-64-v3
 • x86-64-v4
 
-Users of glibc 2.33 and above can see which level is supported by current
-hardware by running:
+Users of glibc 2.33 and above can see which level is supported by running:
   /lib/ld-linux-x86-64.so.2 --help | grep supported
+Or
+  /lib64/ld-linux-x86-64.so.2 --help | grep supported
 
 Alternatively, compare the flags from /proc/cpuinfo to this list.[1]
 
@@ -787,3 +788,4 @@ index 75884d2cdec3..02c1386eb653 100644
  #elif defined CONFIG_MCRUSOE
 -- 
 2.39.0
+



[gentoo-commits] proj/linux-patches:6.6 commit in: /

2023-12-17 Thread Mike Pagano
commit: 49d4dedd2db5c4f1379f79ae560bfca8c394c577
Author: Mike Pagano  gentoo  org>
AuthorDate: Sun Dec 17 14:54:07 2023 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Sun Dec 17 14:54:07 2023 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=49d4dedd

Removed redundant patch

Removed
1805_mm-disable-CONFIG-PER-VMA-LOCK-by-def.patch

Reported fix is upstream at:
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit/?id=fb49c455323ff8319a123dd312be9082c49a23a5

Reported-by: Kerin Millar

Signed-off-by: Mike Pagano  gentoo.org>

 _README  |  4 ---
 1805_mm-disable-CONFIG-PER-VMA-LOCK-by-def.patch | 35 
 2 files changed, 39 deletions(-)

diff --git a/_README b/_README
index caebb97e..868b82dc 100644
--- a/_README
+++ b/_README
@@ -83,10 +83,6 @@ Patch:  1730_parisc-Disable-prctl.patch
 From:
https://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux.git
 Desc:prctl: Temporarily disable prctl(PR_SET_MDWE) on parisc
 
-Patch:  1805_mm-disable-CONFIG-PER-VMA-LOCK-by-def.patch
-From:   https://lore.kernel.org/all/20230703182150.2193578-1-sur...@google.com/
-Desc:   mm: disable CONFIG_PER_VMA_LOCK by default until its fixed
-
 Patch:  2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
 From:   
https://lore.kernel.org/linux-bluetooth/20190522070540.48895-1-mar...@holtmann.org/raw
 Desc:   Bluetooth: Check key sizes only when Secure Simple Pairing is enabled. 
See bug #686758

diff --git a/1805_mm-disable-CONFIG-PER-VMA-LOCK-by-def.patch 
b/1805_mm-disable-CONFIG-PER-VMA-LOCK-by-def.patch
deleted file mode 100644
index c98255a6..
--- a/1805_mm-disable-CONFIG-PER-VMA-LOCK-by-def.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-Subject: [PATCH 1/1] mm: disable CONFIG_PER_VMA_LOCK by default until its fixed
-Date: Mon,  3 Jul 2023 11:21:50 -0700  [thread overview]
-Message-ID: <20230703182150.2193578-1-sur...@google.com> (raw)
-
-A memory corruption was reported in [1] with bisection pointing to the
-patch [2] enabling per-VMA locks for x86.
-Disable per-VMA locks config to prevent this issue while the problem is
-being investigated. This is expected to be a temporary measure.
-
-[1] https://bugzilla.kernel.org/show_bug.cgi?id=217624
-[2] https://lore.kernel.org/all/20230227173632.3292573-30-sur...@google.com
-
-Reported-by: Jiri Slaby 
-Reported-by: Jacob Young 
-Fixes: 0bff0aaea03e ("x86/mm: try VMA lock-based page fault handling first")
-Signed-off-by: Suren Baghdasaryan 

- mm/Kconfig | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/mm/Kconfig b/mm/Kconfig
-index 09130434e30d..de94b2497600 100644
 a/mm/Kconfig
-+++ b/mm/Kconfig
-@@ -1224,7 +1224,7 @@ config ARCH_SUPPORTS_PER_VMA_LOCK
-def_bool n
- 
- config PER_VMA_LOCK
--  def_bool y
-+  bool "Enable per-vma locking during page fault handling."
-   depends on ARCH_SUPPORTS_PER_VMA_LOCK && MMU && SMP
-   help
- Allow per-vma locking during page fault handling.
--- 
-2.41.0.255.g8b1d071c50-goog



[gentoo-commits] proj/linux-patches:6.6 commit in: /

2023-12-11 Thread Mike Pagano
commit: 46aed29aa002a2e1749a3c2c051333bb86ccf53f
Author: Mike Pagano  gentoo  org>
AuthorDate: Mon Dec 11 14:18:57 2023 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Mon Dec 11 14:18:57 2023 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=46aed29a

Linux patch 6.6.6

Signed-off-by: Mike Pagano  gentoo.org>

 _README|   4 ++
 1005_linux-6.6.6.patch | 122 +
 2 files changed, 126 insertions(+)

diff --git a/_README b/_README
index 5f653f8c..5f6d8661 100644
--- a/_README
+++ b/_README
@@ -63,6 +63,10 @@ Patch:  1004_linux-6.6.5.patch
 From:   https://www.kernel.org
 Desc:   Linux 6.6.5
 
+Patch:  1005_linux-6.6.6.patch
+From:   https://www.kernel.org
+Desc:   Linux 6.6.6
+
 Patch:  1510_fs-enable-link-security-restrictions-by-default.patch
 From:   
http://sources.debian.net/src/linux/3.16.7-ckt4-3/debian/patches/debian/fs-enable-link-security-restrictions-by-default.patch/
 Desc:   Enable link security restrictions by default.

diff --git a/1005_linux-6.6.6.patch b/1005_linux-6.6.6.patch
new file mode 100644
index ..7339aa3d
--- /dev/null
+++ b/1005_linux-6.6.6.patch
@@ -0,0 +1,122 @@
+diff --git a/Makefile b/Makefile
+index ee4e504a3e78e..1eefa893f048b 100644
+--- a/Makefile
 b/Makefile
+@@ -1,7 +1,7 @@
+ # SPDX-License-Identifier: GPL-2.0
+ VERSION = 6
+ PATCHLEVEL = 6
+-SUBLEVEL = 5
++SUBLEVEL = 6
+ EXTRAVERSION =
+ NAME = Hurr durr I'ma ninja sloth
+ 
+diff --git a/net/wireless/core.h b/net/wireless/core.h
+index f0a3a23176385..e536c0b615a09 100644
+--- a/net/wireless/core.h
 b/net/wireless/core.h
+@@ -299,7 +299,6 @@ struct cfg80211_cqm_config {
+   u32 rssi_hyst;
+   s32 last_rssi_event_value;
+   enum nl80211_cqm_rssi_threshold_event last_rssi_event_type;
+-  bool use_range_api;
+   int n_rssi_thresholds;
+   s32 rssi_thresholds[] __counted_by(n_rssi_thresholds);
+ };
+diff --git a/net/wireless/nl80211.c b/net/wireless/nl80211.c
+index 6a82dd876f278..931a03f4549c9 100644
+--- a/net/wireless/nl80211.c
 b/net/wireless/nl80211.c
+@@ -12824,6 +12824,10 @@ static int cfg80211_cqm_rssi_update(struct 
cfg80211_registered_device *rdev,
+   int i, n, low_index;
+   int err;
+ 
++  /* RSSI reporting disabled? */
++  if (!cqm_config)
++  return rdev_set_cqm_rssi_range_config(rdev, dev, 0, 0);
++
+   /*
+* Obtain current RSSI value if possible, if not and no RSSI threshold
+* event has been received yet, we should receive an event after a
+@@ -12898,6 +12902,18 @@ static int nl80211_set_cqm_rssi(struct genl_info 
*info,
+   wdev->iftype != NL80211_IFTYPE_P2P_CLIENT)
+   return -EOPNOTSUPP;
+ 
++  if (n_thresholds <= 1 && rdev->ops->set_cqm_rssi_config) {
++  if (n_thresholds == 0 || thresholds[0] == 0) /* Disabling */
++  return rdev_set_cqm_rssi_config(rdev, dev, 0, 0);
++
++  return rdev_set_cqm_rssi_config(rdev, dev,
++  thresholds[0], hysteresis);
++  }
++
++  if (!wiphy_ext_feature_isset(>wiphy,
++   NL80211_EXT_FEATURE_CQM_RSSI_LIST))
++  return -EOPNOTSUPP;
++
+   if (n_thresholds == 1 && thresholds[0] == 0) /* Disabling */
+   n_thresholds = 0;
+ 
+@@ -12905,20 +12921,6 @@ static int nl80211_set_cqm_rssi(struct genl_info 
*info,
+   old = rcu_dereference_protected(wdev->cqm_config,
+   lockdep_is_held(>mtx));
+ 
+-  /* if already disabled just succeed */
+-  if (!n_thresholds && !old)
+-  return 0;
+-
+-  if (n_thresholds > 1) {
+-  if (!wiphy_ext_feature_isset(>wiphy,
+-   NL80211_EXT_FEATURE_CQM_RSSI_LIST) 
||
+-  !rdev->ops->set_cqm_rssi_range_config)
+-  return -EOPNOTSUPP;
+-  } else {
+-  if (!rdev->ops->set_cqm_rssi_config)
+-  return -EOPNOTSUPP;
+-  }
+-
+   if (n_thresholds) {
+   cqm_config = kzalloc(struct_size(cqm_config, rssi_thresholds,
+n_thresholds),
+@@ -12933,26 +12935,13 @@ static int nl80211_set_cqm_rssi(struct genl_info 
*info,
+   memcpy(cqm_config->rssi_thresholds, thresholds,
+  flex_array_size(cqm_config, rssi_thresholds,
+  n_thresholds));
+-  cqm_config->use_range_api = n_thresholds > 1 ||
+-  !rdev->ops->set_cqm_rssi_config;
+ 
+   rcu_assign_pointer(wdev->cqm_config, cqm_config);
+-
+-  if (cqm_config->use_range_api)
+-  err = cfg80211_cqm_rssi_update(rdev, dev, cqm_config);
+-  else
+-  err = rdev_set_cqm_rssi_config(rdev, dev,
+-  

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2023-12-08 Thread Mike Pagano
commit: 46c364bd4721d6072b435991e5a499506523b4a9
Author: Mike Pagano  gentoo  org>
AuthorDate: Fri Dec  8 12:01:20 2023 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Fri Dec  8 12:01:20 2023 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=46c364bd

Remove redundant patch

Removed:
2010_Fix_randomize_layout_crash_in_struct_neigh.patch

Signed-off-by: Mike Pagano  gentoo.org>

 _README|  4 --
 ...ix_randomize_layout_crash_in_struct_neigh.patch | 44 --
 2 files changed, 48 deletions(-)

diff --git a/_README b/_README
index 32c2f2be..5f653f8c 100644
--- a/_README
+++ b/_README
@@ -83,10 +83,6 @@ Patch:  
2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
 From:   
https://lore.kernel.org/linux-bluetooth/20190522070540.48895-1-mar...@holtmann.org/raw
 Desc:   Bluetooth: Check key sizes only when Secure Simple Pairing is enabled. 
See bug #686758
 
-Patch:  2010_Fix_randomize_layout_crash_in_struct_neigh.patch
-From:   
https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git/commit/?id=45b3fae4675d
-Desc:   neighbour: Fix __randomize_layout crash in struct neighbour
-
 Patch:  2410_iwlwifi-rfkill-fix.patch
 From:   https://bugzilla.kernel.org/show_bug.cgi?id=218206
 Desc:   fix for iwlwifi pcie synchronization of IRQs before NAPI

diff --git a/2010_Fix_randomize_layout_crash_in_struct_neigh.patch 
b/2010_Fix_randomize_layout_crash_in_struct_neigh.patch
deleted file mode 100644
index 8ee50b2f..
--- a/2010_Fix_randomize_layout_crash_in_struct_neigh.patch
+++ /dev/null
@@ -1,44 +0,0 @@
-From 45b3fae4675dc1d4ee2d7aefa19d85ee4f891377 Mon Sep 17 00:00:00 2001
-From: "Gustavo A. R. Silva" 
-Date: Sat, 25 Nov 2023 15:33:58 -0600
-Subject: neighbour: Fix __randomize_layout crash in struct neighbour
-
-Previously, one-element and zero-length arrays were treated as true
-flexible arrays, even though they are actually "fake" flex arrays.
-The __randomize_layout would leave them untouched at the end of the
-struct, similarly to proper C99 flex-array members.
-
-However, this approach changed with commit 1ee60356c2dc ("gcc-plugins:
-randstruct: Only warn about true flexible arrays"). Now, only C99
-flexible-array members will remain untouched at the end of the struct,
-while one-element and zero-length arrays will be subject to randomization.
-
-Fix a `__randomize_layout` crash in `struct neighbour` by transforming
-zero-length array `primary_key` into a proper C99 flexible-array member.
-
-Fixes: 1ee60356c2dc ("gcc-plugins: randstruct: Only warn about true flexible 
arrays")
-Closes: 
https://lore.kernel.org/linux-hardening/20231124102458.gb1503...@e124191.cambridge.arm.com/
-Signed-off-by: Gustavo A. R. Silva 
-Reviewed-by: Kees Cook 
-Tested-by: Joey Gouly 
-Link: https://lore.kernel.org/r/ZWJoRsJGnCPdJ3+2@work
-Signed-off-by: Paolo Abeni 

- include/net/neighbour.h | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/include/net/neighbour.h b/include/net/neighbour.h
-index 07022bb0d44d4b..0d28172193fa63 100644
 a/include/net/neighbour.h
-+++ b/include/net/neighbour.h
-@@ -162,7 +162,7 @@ struct neighbour {
-   struct rcu_head rcu;
-   struct net_device   *dev;
-   netdevice_tracker   dev_tracker;
--  u8  primary_key[0];
-+  u8  primary_key[];
- } __randomize_layout;
- 
- struct neigh_ops {
--- 
-cgit 



[gentoo-commits] proj/linux-patches:6.6 commit in: /

2023-12-07 Thread Mike Pagano
commit: d935f504f8fe5c97868abc23c401bfdb91c7cc4a
Author: Mike Pagano  gentoo  org>
AuthorDate: Thu Dec  7 18:52:37 2023 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Thu Dec  7 18:52:37 2023 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=d935f504

Remove revert, add upstream proposed fix

Removed:
2400_rvrt-iwlwifi-pcie-sycn-IRQs-before-NAPI.patch

See: https://bugzilla.kernel.org/show_bug.cgi?id=218206

Signed-off-by: Mike Pagano  gentoo.org>

 _README|   6 +-
 2400_rvrt-iwlwifi-pcie-sycn-IRQs-before-NAPI.patch |  20 ---
 2410_iwlwifi-rfkill-fix.patch  | 170 +
 3 files changed, 173 insertions(+), 23 deletions(-)

diff --git a/_README b/_README
index 31c2e3cb..dab55135 100644
--- a/_README
+++ b/_README
@@ -83,9 +83,9 @@ Patch:  2010_Fix_randomize_layout_crash_in_struct_neigh.patch
 From:   
https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git/commit/?id=45b3fae4675d
 Desc:   neighbour: Fix __randomize_layout crash in struct neighbour
 
-Patch:  2400_rvrt-iwlwifi-pcie-sycn-IRQs-before-NAPI.patch
-From:   https://bugs.gentoo.org/918128
-Desc:   revert: wifi: iwlwifi: pcie: synchronize IRQs before NAPI
+Patch:  2410_iwlwifi-rfkill-fix.patch
+From:   https://bugzilla.kernel.org/show_bug.cgi?id=218206
+Desc:   fix for iwlwifi pcie synchronization of IRQs before NAPI
 
 Patch:  2900_tmp513-Fix-build-issue-by-selecting-CONFIG_REG.patch
 From:   https://bugs.gentoo.org/710790

diff --git a/2400_rvrt-iwlwifi-pcie-sycn-IRQs-before-NAPI.patch 
b/2400_rvrt-iwlwifi-pcie-sycn-IRQs-before-NAPI.patch
deleted file mode 100644
index 8f6996aa..
--- a/2400_rvrt-iwlwifi-pcie-sycn-IRQs-before-NAPI.patch
+++ /dev/null
@@ -1,20 +0,0 @@
 a/drivers/net/wireless/intel/iwlwifi/pcie/trans-gen2.c 2023-12-03 
06:18:46.682462627 -0500
-+++ b//drivers/net/wireless/intel/iwlwifi/pcie/trans-gen2.c2023-12-03 
06:20:00.912230659 -0500
-@@ -161,7 +161,6 @@ void _iwl_trans_pcie_gen2_stop_device(st
-   if (test_and_clear_bit(STATUS_DEVICE_ENABLED, >status)) {
-   IWL_DEBUG_INFO(trans,
-  "DEVICE_ENABLED bit was set and is now 
cleared\n");
--  iwl_pcie_synchronize_irqs(trans);
-   iwl_pcie_rx_napi_sync(trans);
-   iwl_txq_gen2_tx_free(trans);
-   iwl_pcie_rx_stop(trans);
 a/drivers/net/wireless/intel/iwlwifi/pcie/trans.c  2023-12-03 
06:18:54.135764993 -0500
-+++ b//drivers/net/wireless/intel/iwlwifi/pcie/trans.c 2023-12-03 
06:20:20.688858491 -0500
-@@ -1263,7 +1263,6 @@ static void _iwl_trans_pcie_stop_device(
-   if (test_and_clear_bit(STATUS_DEVICE_ENABLED, >status)) {
-   IWL_DEBUG_INFO(trans,
-  "DEVICE_ENABLED bit was set and is now 
cleared\n");
--  iwl_pcie_synchronize_irqs(trans);
-   iwl_pcie_rx_napi_sync(trans);
-   iwl_pcie_tx_stop(trans);
-   iwl_pcie_rx_stop(trans);

diff --git a/2410_iwlwifi-rfkill-fix.patch b/2410_iwlwifi-rfkill-fix.patch
new file mode 100644
index ..02994243
--- /dev/null
+++ b/2410_iwlwifi-rfkill-fix.patch
@@ -0,0 +1,170 @@
+diff --git a/drivers/net/wireless/intel/iwlwifi/pcie/internal.h 
b/drivers/net/wireless/intel/iwlwifi/pcie/internal.h
+index 56def20374f3..abdb687e7274 100644
+--- a/drivers/net/wireless/intel/iwlwifi/pcie/internal.h
 b/drivers/net/wireless/intel/iwlwifi/pcie/internal.h
+@@ -770,7 +770,7 @@ static inline void iwl_enable_rfkill_int(struct iwl_trans 
*trans)
+   }
+ }
+ 
+-void iwl_pcie_handle_rfkill_irq(struct iwl_trans *trans);
++void iwl_pcie_handle_rfkill_irq(struct iwl_trans *trans, bool from_irq);
+ 
+ static inline bool iwl_is_rfkill_set(struct iwl_trans *trans)
+ {
+@@ -817,7 +817,7 @@ static inline bool iwl_pcie_dbg_on(struct iwl_trans *trans)
+   return (trans->dbg.dest_tlv || iwl_trans_dbg_ini_valid(trans));
+ }
+ 
+-void iwl_trans_pcie_rf_kill(struct iwl_trans *trans, bool state);
++void iwl_trans_pcie_rf_kill(struct iwl_trans *trans, bool state, bool 
from_irq);
+ void iwl_trans_pcie_dump_regs(struct iwl_trans *trans);
+ 
+ #ifdef CONFIG_IWLWIFI_DEBUGFS
+@@ -853,7 +853,7 @@ void iwl_trans_pcie_gen2_fw_alive(struct iwl_trans *trans, 
u32 scd_addr);
+ int iwl_trans_pcie_gen2_send_hcmd(struct iwl_trans *trans,
+ struct iwl_host_cmd *cmd);
+ void iwl_trans_pcie_gen2_stop_device(struct iwl_trans *trans);
+-void _iwl_trans_pcie_gen2_stop_device(struct iwl_trans *trans);
++void _iwl_trans_pcie_gen2_stop_device(struct iwl_trans *trans, bool from_irq);
+ void iwl_pcie_d3_complete_suspend(struct iwl_trans *trans,
+ bool test, bool reset);
+ int iwl_pcie_gen2_enqueue_hcmd(struct iwl_trans *trans,
+diff --git a/drivers/net/wireless/intel/iwlwifi/pcie/rx.c 
b/drivers/net/wireless/intel/iwlwifi/pcie/rx.c
+index 146bc7bd14fb..a0d10df0c11a 100644

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2023-12-03 Thread Mike Pagano
commit: 40d705a362f51b9c736ad76e22f140f873ab2695
Author: Mike Pagano  gentoo  org>
AuthorDate: Sun Dec  3 11:23:37 2023 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Sun Dec  3 11:23:37 2023 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=40d705a3

revert: wifi: iwlwifi: pcie: synchronize IRQs before NAPI

Bug: https://bugs.gentoo.org/918128

Signed-off-by: Mike Pagano  gentoo.org>

 _README|  4 
 2400_rvrt-iwlwifi-pcie-sycn-IRQs-before-NAPI.patch | 20 
 2 files changed, 24 insertions(+)

diff --git a/_README b/_README
index d9fb1cc7..31c2e3cb 100644
--- a/_README
+++ b/_README
@@ -83,6 +83,10 @@ Patch:  2010_Fix_randomize_layout_crash_in_struct_neigh.patch
 From:   
https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git/commit/?id=45b3fae4675d
 Desc:   neighbour: Fix __randomize_layout crash in struct neighbour
 
+Patch:  2400_rvrt-iwlwifi-pcie-sycn-IRQs-before-NAPI.patch
+From:   https://bugs.gentoo.org/918128
+Desc:   revert: wifi: iwlwifi: pcie: synchronize IRQs before NAPI
+
 Patch:  2900_tmp513-Fix-build-issue-by-selecting-CONFIG_REG.patch
 From:   https://bugs.gentoo.org/710790
 Desc:   tmp513 requies REGMAP_I2C to build.  Select it by default in Kconfig. 
See bug #710790. Thanks to Phil Stracchino

diff --git a/2400_rvrt-iwlwifi-pcie-sycn-IRQs-before-NAPI.patch 
b/2400_rvrt-iwlwifi-pcie-sycn-IRQs-before-NAPI.patch
new file mode 100644
index ..8f6996aa
--- /dev/null
+++ b/2400_rvrt-iwlwifi-pcie-sycn-IRQs-before-NAPI.patch
@@ -0,0 +1,20 @@
+--- a/drivers/net/wireless/intel/iwlwifi/pcie/trans-gen2.c 2023-12-03 
06:18:46.682462627 -0500
 b//drivers/net/wireless/intel/iwlwifi/pcie/trans-gen2.c2023-12-03 
06:20:00.912230659 -0500
+@@ -161,7 +161,6 @@ void _iwl_trans_pcie_gen2_stop_device(st
+   if (test_and_clear_bit(STATUS_DEVICE_ENABLED, >status)) {
+   IWL_DEBUG_INFO(trans,
+  "DEVICE_ENABLED bit was set and is now 
cleared\n");
+-  iwl_pcie_synchronize_irqs(trans);
+   iwl_pcie_rx_napi_sync(trans);
+   iwl_txq_gen2_tx_free(trans);
+   iwl_pcie_rx_stop(trans);
+--- a/drivers/net/wireless/intel/iwlwifi/pcie/trans.c  2023-12-03 
06:18:54.135764993 -0500
 b//drivers/net/wireless/intel/iwlwifi/pcie/trans.c 2023-12-03 
06:20:20.688858491 -0500
+@@ -1263,7 +1263,6 @@ static void _iwl_trans_pcie_stop_device(
+   if (test_and_clear_bit(STATUS_DEVICE_ENABLED, >status)) {
+   IWL_DEBUG_INFO(trans,
+  "DEVICE_ENABLED bit was set and is now 
cleared\n");
+-  iwl_pcie_synchronize_irqs(trans);
+   iwl_pcie_rx_napi_sync(trans);
+   iwl_pcie_tx_stop(trans);
+   iwl_pcie_rx_stop(trans);



[gentoo-commits] proj/linux-patches:6.6 commit in: /

2023-12-01 Thread Mike Pagano
commit: 5a401bdbc54d08387ac3f7d4d815e21e6f460d63
Author: Mike Pagano  gentoo  org>
AuthorDate: Fri Dec  1 10:30:29 2023 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Fri Dec  1 10:30:29 2023 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=5a401bdb

neighbour: Fix __randomize_layout crash in struct neighbour

Bug: https://bugs.gentoo.org/918128

Signed-off-by: Mike Pagano  gentoo.org>

 _README|  4 ++
 ...ix_randomize_layout_crash_in_struct_neigh.patch | 44 ++
 2 files changed, 48 insertions(+)

diff --git a/_README b/_README
index cbd5f55a..45e6e938 100644
--- a/_README
+++ b/_README
@@ -75,6 +75,10 @@ Patch:  
2000_BT-Check-key-sizes-only-if-Secure-Simple-Pairing-enabled.patch
 From:   
https://lore.kernel.org/linux-bluetooth/20190522070540.48895-1-mar...@holtmann.org/raw
 Desc:   Bluetooth: Check key sizes only when Secure Simple Pairing is enabled. 
See bug #686758
 
+Patch:  2010_Fix_randomize_layout_crash_in_struct_neigh.patch
+From:   
https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git/commit/?id=45b3fae4675d
+Desc:   neighbour: Fix __randomize_layout crash in struct neighbour
+
 Patch:  2900_tmp513-Fix-build-issue-by-selecting-CONFIG_REG.patch
 From:   https://bugs.gentoo.org/710790
 Desc:   tmp513 requies REGMAP_I2C to build.  Select it by default in Kconfig. 
See bug #710790. Thanks to Phil Stracchino

diff --git a/2010_Fix_randomize_layout_crash_in_struct_neigh.patch 
b/2010_Fix_randomize_layout_crash_in_struct_neigh.patch
new file mode 100644
index ..8ee50b2f
--- /dev/null
+++ b/2010_Fix_randomize_layout_crash_in_struct_neigh.patch
@@ -0,0 +1,44 @@
+From 45b3fae4675dc1d4ee2d7aefa19d85ee4f891377 Mon Sep 17 00:00:00 2001
+From: "Gustavo A. R. Silva" 
+Date: Sat, 25 Nov 2023 15:33:58 -0600
+Subject: neighbour: Fix __randomize_layout crash in struct neighbour
+
+Previously, one-element and zero-length arrays were treated as true
+flexible arrays, even though they are actually "fake" flex arrays.
+The __randomize_layout would leave them untouched at the end of the
+struct, similarly to proper C99 flex-array members.
+
+However, this approach changed with commit 1ee60356c2dc ("gcc-plugins:
+randstruct: Only warn about true flexible arrays"). Now, only C99
+flexible-array members will remain untouched at the end of the struct,
+while one-element and zero-length arrays will be subject to randomization.
+
+Fix a `__randomize_layout` crash in `struct neighbour` by transforming
+zero-length array `primary_key` into a proper C99 flexible-array member.
+
+Fixes: 1ee60356c2dc ("gcc-plugins: randstruct: Only warn about true flexible 
arrays")
+Closes: 
https://lore.kernel.org/linux-hardening/20231124102458.gb1503...@e124191.cambridge.arm.com/
+Signed-off-by: Gustavo A. R. Silva 
+Reviewed-by: Kees Cook 
+Tested-by: Joey Gouly 
+Link: https://lore.kernel.org/r/ZWJoRsJGnCPdJ3+2@work
+Signed-off-by: Paolo Abeni 
+---
+ include/net/neighbour.h | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/include/net/neighbour.h b/include/net/neighbour.h
+index 07022bb0d44d4b..0d28172193fa63 100644
+--- a/include/net/neighbour.h
 b/include/net/neighbour.h
+@@ -162,7 +162,7 @@ struct neighbour {
+   struct rcu_head rcu;
+   struct net_device   *dev;
+   netdevice_tracker   dev_tracker;
+-  u8  primary_key[0];
++  u8  primary_key[];
+ } __randomize_layout;
+ 
+ struct neigh_ops {
+-- 
+cgit 



[gentoo-commits] proj/linux-patches:6.6 commit in: /

2023-11-19 Thread Mike Pagano
commit: 43bb3290045425ac89ef055e23ca1ba63f267465
Author: Mike Pagano  gentoo  org>
AuthorDate: Sun Nov 19 15:18:02 2023 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Sun Nov 19 15:18:02 2023 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=43bb3290

prctl: Temporarily disable prctl(PR_SET_MDWE) on parisc

Signed-off-by: Mike Pagano  gentoo.org>

 _README |  4 
 1730_parisc-Disable-prctl.patch | 51 +
 2 files changed, 55 insertions(+)

diff --git a/_README b/_README
index b98c4b39..2e6346ff 100644
--- a/_README
+++ b/_README
@@ -59,6 +59,10 @@ Patch:  
1720_parisc-gen-mmap-top-down-layout-and-brk-randomization.patch
 From:  
https://lore.kernel.org/linux-parisc/ZVH2qeS1bG7%2F1J%2Fl@p100/T/#u
 Desc:  Fix the mmap_base() calculation to include the 
stack-grows-upwards case
 
+Patch:  1730_parisc-Disable-prctl.patch
+From:
https://git.kernel.org/pub/scm/linux/kernel/git/deller/parisc-linux.git
+Desc:prctl: Temporarily disable prctl(PR_SET_MDWE) on parisc
+
 Patch:  1805_mm-disable-CONFIG-PER-VMA-LOCK-by-def.patch
 From:   https://lore.kernel.org/all/20230703182150.2193578-1-sur...@google.com/
 Desc:   mm: disable CONFIG_PER_VMA_LOCK by default until its fixed

diff --git a/1730_parisc-Disable-prctl.patch b/1730_parisc-Disable-prctl.patch
new file mode 100644
index ..f892d6a1
--- /dev/null
+++ b/1730_parisc-Disable-prctl.patch
@@ -0,0 +1,51 @@
+From 339b41ec357c24c02ed4aed6267dbfd443ee1e8e Mon Sep 17 00:00:00 2001
+From: Helge Deller 
+Date: Mon, 13 Nov 2023 16:06:18 +0100
+Subject: prctl: Temporarily disable prctl(PR_SET_MDWE) on parisc
+
+systemd-254 tries to use prctl(PR_SET_MDWE) for systemd's
+MemoryDenyWriteExecute functionality, but fails on PA-RISC/HPPA which
+still needs executable stacks.
+
+Temporarily disable prctl(PR_SET_MDWE) by returning -ENODEV on parisc
+for now. Note that we can't return -EINVAL since systemd will then try
+to use seccomp instead.
+
+Reported-by: Sam James 
+Signed-off-by: Helge Deller 
+Link: https://lore.kernel.org/all/875y2jro9a@gentoo.org/
+Link: https://github.com/systemd/systemd/issues/29775.
+Cc:  # v6.3+
+---
+ kernel/sys.c | 10 --
+ 1 file changed, 8 insertions(+), 2 deletions(-)
+
+diff --git a/kernel/sys.c b/kernel/sys.c
+index 420d9cb9cc8e2..8e3eaf650d07d 100644
+--- a/kernel/sys.c
 b/kernel/sys.c
+@@ -2700,10 +2700,16 @@ SYSCALL_DEFINE5(prctl, int, option, unsigned long, 
arg2, unsigned long, arg3,
+   break;
+ #endif
+   case PR_SET_MDWE:
+-  error = prctl_set_mdwe(arg2, arg3, arg4, arg5);
++  if (IS_ENABLED(CONFIG_PARISC))
++  error = -EINVAL;
++  else
++  error = prctl_set_mdwe(arg2, arg3, arg4, arg5);
+   break;
+   case PR_GET_MDWE:
+-  error = prctl_get_mdwe(arg2, arg3, arg4, arg5);
++  if (IS_ENABLED(CONFIG_PARISC))
++  error = -EINVAL;
++  else
++  error = prctl_get_mdwe(arg2, arg3, arg4, arg5);
+   break;
+   case PR_SET_VMA:
+   error = prctl_set_vma(arg2, arg3, arg4, arg5);
+-- 
+cgit
+Filename: fallback-exec-stack.patch. Size: 2kb. View raw, copy, hex, or 
download this file.
+View source code, the removal or expiry stories, or read the about page.
+
+This website does not claim ownership of, copyright on, and assumes no 
liability for provided content. Toggle color scheme.



[gentoo-commits] proj/linux-patches:6.6 commit in: /

2023-11-08 Thread Mike Pagano
commit: e47454f1268c89d9232c88ae0fd9580e30e52ac1
Author: Mike Pagano  gentoo  org>
AuthorDate: Wed Nov  8 11:51:46 2023 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Wed Nov  8 11:51:46 2023 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=e47454f1

Linux patch 6.6.1

Signed-off-by: Mike Pagano  gentoo.org>

 _README|4 +
 1000_linux-6.6.1.patch | 1531 
 2 files changed, 1535 insertions(+)

diff --git a/_README b/_README
index aed4554c..bb74cf79 100644
--- a/_README
+++ b/_README
@@ -43,6 +43,10 @@ EXPERIMENTAL
 Individual Patch Descriptions:
 --
 
+Patch:  1000_linux-6.6.1.patch
+From:   https://www.kernel.org
+Desc:   Linux 6.6.1
+
 Patch:  1510_fs-enable-link-security-restrictions-by-default.patch
 From:   
http://sources.debian.net/src/linux/3.16.7-ckt4-3/debian/patches/debian/fs-enable-link-security-restrictions-by-default.patch/
 Desc:   Enable link security restrictions by default.

diff --git a/1000_linux-6.6.1.patch b/1000_linux-6.6.1.patch
new file mode 100644
index ..e487d1d9
--- /dev/null
+++ b/1000_linux-6.6.1.patch
@@ -0,0 +1,1531 @@
+diff --git a/Documentation/devicetree/bindings/serial/rs485.yaml 
b/Documentation/devicetree/bindings/serial/rs485.yaml
+index 303a443d9e29b..9418fd66a8e95 100644
+--- a/Documentation/devicetree/bindings/serial/rs485.yaml
 b/Documentation/devicetree/bindings/serial/rs485.yaml
+@@ -29,6 +29,10 @@ properties:
+   default: 0
+   maximum: 100
+ 
++  rs485-rts-active-high:
++description: drive RTS high when sending (this is the default).
++$ref: /schemas/types.yaml#/definitions/flag
++
+   rs485-rts-active-low:
+ description: drive RTS low when sending (default is high).
+ $ref: /schemas/types.yaml#/definitions/flag
+diff --git a/Makefile b/Makefile
+index 5c418efbe89b6..f8c14da7c7bc7 100644
+--- a/Makefile
 b/Makefile
+@@ -1,7 +1,7 @@
+ # SPDX-License-Identifier: GPL-2.0
+ VERSION = 6
+ PATCHLEVEL = 6
+-SUBLEVEL = 0
++SUBLEVEL = 1
+ EXTRAVERSION =
+ NAME = Hurr durr I'ma ninja sloth
+ 
+diff --git a/drivers/bluetooth/hci_bcm4377.c b/drivers/bluetooth/hci_bcm4377.c
+index 19ad0e7886462..a617578356953 100644
+--- a/drivers/bluetooth/hci_bcm4377.c
 b/drivers/bluetooth/hci_bcm4377.c
+@@ -512,6 +512,7 @@ struct bcm4377_hw {
+   unsigned long disable_aspm : 1;
+   unsigned long broken_ext_scan : 1;
+   unsigned long broken_mws_transport_config : 1;
++  unsigned long broken_le_coded : 1;
+ 
+   int (*send_calibration)(struct bcm4377_data *bcm4377);
+   int (*send_ptb)(struct bcm4377_data *bcm4377,
+@@ -2372,6 +2373,8 @@ static int bcm4377_probe(struct pci_dev *pdev, const 
struct pci_device_id *id)
+   set_bit(HCI_QUIRK_BROKEN_MWS_TRANSPORT_CONFIG, >quirks);
+   if (bcm4377->hw->broken_ext_scan)
+   set_bit(HCI_QUIRK_BROKEN_EXT_SCAN, >quirks);
++  if (bcm4377->hw->broken_le_coded)
++  set_bit(HCI_QUIRK_BROKEN_LE_CODED, >quirks);
+ 
+   pci_set_drvdata(pdev, bcm4377);
+   hci_set_drvdata(hdev, bcm4377);
+@@ -2461,6 +2464,7 @@ static const struct bcm4377_hw bcm4377_hw_variants[] = {
+   .bar0_core2_window2 = 0x18107000,
+   .has_bar0_core2_window2 = true,
+   .broken_mws_transport_config = true,
++  .broken_le_coded = true,
+   .send_calibration = bcm4378_send_calibration,
+   .send_ptb = bcm4378_send_ptb,
+   },
+@@ -2474,6 +2478,7 @@ static const struct bcm4377_hw bcm4377_hw_variants[] = {
+   .has_bar0_core2_window2 = true,
+   .clear_pciecfg_subsystem_ctrl_bit19 = true,
+   .broken_mws_transport_config = true,
++  .broken_le_coded = true,
+   .send_calibration = bcm4387_send_calibration,
+   .send_ptb = bcm4378_send_ptb,
+   },
+diff --git a/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c 
b/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c
+index b87bfecb7755a..a8e79104b684e 100644
+--- a/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c
 b/drivers/gpu/drm/amd/display/dc/dce/dce_dmcu.c
+@@ -586,7 +586,8 @@ static void dcn10_dmcu_set_psr_enable(struct dmcu *dmcu, 
bool enable, bool wait)
+   if (state == PSR_STATE0)
+   break;
+   }
+-  fsleep(500);
++  /* must *not* be fsleep - this can be called from high 
irq levels */
++  udelay(500);
+   }
+ 
+   /* assert if max retry hit */
+diff --git a/drivers/gpu/drm/amd/display/dc/dce/dmub_psr.c 
b/drivers/gpu/drm/amd/display/dc/dce/dmub_psr.c
+index 0f24b6fbd2201..4704c9c85ee6f 100644
+--- a/drivers/gpu/drm/amd/display/dc/dce/dmub_psr.c
 b/drivers/gpu/drm/amd/display/dc/dce/dmub_psr.c
+@@ 

[gentoo-commits] proj/linux-patches:6.6 commit in: /

2023-10-30 Thread Mike Pagano
commit: dc67ca51dcde0aa0d217936bb08e650f5a0a8087
Author: Mike Pagano  gentoo  org>
AuthorDate: Mon Oct 30 11:29:50 2023 +
Commit: Mike Pagano  gentoo  org>
CommitDate: Mon Oct 30 11:29:50 2023 +
URL:https://gitweb.gentoo.org/proj/linux-patches.git/commit/?id=dc67ca51

Remove incompatible patch

Removed:
1500_XATTR_USER_PREFIX.patch

Signed-off-by: Mike Pagano  gentoo.org>

 _README  |  4 ---
 1500_XATTR_USER_PREFIX.patch | 66 
 2 files changed, 70 deletions(-)

diff --git a/_README b/_README
index 1efa027c..aed4554c 100644
--- a/_README
+++ b/_README
@@ -43,10 +43,6 @@ EXPERIMENTAL
 Individual Patch Descriptions:
 --
 
-Patch:  1500_XATTR_USER_PREFIX.patch
-From:   https://bugs.gentoo.org/show_bug.cgi?id=470644
-Desc:   Support for namespace user.pax.* on tmpfs.
-
 Patch:  1510_fs-enable-link-security-restrictions-by-default.patch
 From:   
http://sources.debian.net/src/linux/3.16.7-ckt4-3/debian/patches/debian/fs-enable-link-security-restrictions-by-default.patch/
 Desc:   Enable link security restrictions by default.

diff --git a/1500_XATTR_USER_PREFIX.patch b/1500_XATTR_USER_PREFIX.patch
deleted file mode 100644
index fac3eed7..
--- a/1500_XATTR_USER_PREFIX.patch
+++ /dev/null
@@ -1,66 +0,0 @@
-From: Anthony G. Basile 
-
-This patch adds support for a restricted user-controlled namespace on
-tmpfs filesystem used to house PaX flags.  The namespace must be of the
-form user.pax.* and its value cannot exceed a size of 8 bytes.
-
-This is needed even on all Gentoo systems so that XATTR_PAX flags
-are preserved for users who might build packages using portage on
-a tmpfs system with a non-hardened kernel and then switch to a
-hardened kernel with XATTR_PAX enabled.
-
-The namespace is added to any user with Extended Attribute support
-enabled for tmpfs.  Users who do not enable xattrs will not have
-the XATTR_PAX flags preserved.
-
-
 a/include/uapi/linux/xattr.h   2022-11-22 05:56:58.175733644 -0500
-+++ b/include/uapi/linux/xattr.h   2022-11-22 06:04:26.394834989 -0500
-@@ -81,5 +81,9 @@
- #define XATTR_POSIX_ACL_DEFAULT  "posix_acl_default"
- #define XATTR_NAME_POSIX_ACL_DEFAULT XATTR_SYSTEM_PREFIX 
XATTR_POSIX_ACL_DEFAULT
- 
-+/* User namespace */
-+#define XATTR_PAX_PREFIX XATTR_USER_PREFIX "pax."
-+#define XATTR_PAX_FLAGS_SUFFIX "flags"
-+#define XATTR_NAME_PAX_FLAGS XATTR_PAX_PREFIX XATTR_PAX_FLAGS_SUFFIX
- 
- #endif /* _UAPI_LINUX_XATTR_H */
 a/mm/shmem.c   2022-11-22 05:57:29.011626215 -0500
-+++ b/mm/shmem.c   2022-11-22 06:03:33.165939400 -0500
-@@ -3297,6 +3297,14 @@ static int shmem_xattr_handler_set(const
-   struct shmem_inode_info *info = SHMEM_I(inode);
-   int err;
- 
-+
-+  if (!strncmp(name, XATTR_USER_PREFIX, XATTR_USER_PREFIX_LEN)) {
-+  if (strcmp(name, XATTR_NAME_PAX_FLAGS))
-+  return -EOPNOTSUPP;
-+  if (size > 8)
-+  return -EINVAL;
-+  }
-+
-   name = xattr_full_name(handler, name);
-   err = simple_xattr_set(>xattrs, name, value, size, flags, NULL);
-   if (!err) {
-@@ -3312,6 +3320,12 @@ static const struct xattr_handler shmem_
-   .set = shmem_xattr_handler_set,
- };
- 
-+static const struct xattr_handler shmem_user_xattr_handler = {
-+  .prefix = XATTR_USER_PREFIX,
-+  .get = shmem_xattr_handler_get,
-+  .set = shmem_xattr_handler_set,
-+};
-+
- static const struct xattr_handler shmem_trusted_xattr_handler = {
-   .prefix = XATTR_TRUSTED_PREFIX,
-   .get = shmem_xattr_handler_get,
-@@ -3325,6 +3339,7 @@ static const struct xattr_handler *shmem
- #endif
-   _security_xattr_handler,
-   _trusted_xattr_handler,
-+  _user_xattr_handler,
-   NULL
- };
-