From: Sasha Levin Date: Mon, 2 Mar 2026 00:51:22 +0000 (-0500) Subject: Fixes for all trees X-Git-Tag: v6.19.6~4 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=b5d33dd51ff49b6d147c1ef45440692735dcb69f;p=thirdparty%2Fkernel%2Fstable-queue.git Fixes for all trees Signed-off-by: Sasha Levin --- diff --git a/queue-6.12/drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch b/queue-6.12/drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch new file mode 100644 index 0000000000..2e9345085b --- /dev/null +++ b/queue-6.12/drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch @@ -0,0 +1,98 @@ +From 851fa0ece6d805ad83696480a04aa6d142af2669 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 15 Dec 2025 14:09:08 +0200 +Subject: drm/i915/wakeref: clean up INTEL_WAKEREF_PUT_* flag macros + +From: Jani Nikula + +[ Upstream commit 524696a19e34598c9173fdd5b32fb7e5d16a91d3 ] + +Commit 469c1c9eb6c9 ("kernel-doc: Issue warnings that were silently +discarded") started emitting warnings for cases that were previously +silently discarded. One such case is in intel_wakeref.h: + +Warning: drivers/gpu/drm/i915/intel_wakeref.h:156 expecting prototype + for __intel_wakeref_put(). Prototype was for INTEL_WAKEREF_PUT_ASYNC() + instead + +Arguably kernel-doc should be able to handle this, as it's valid C, but +having the flags defined between the function declarator and the body is +just asking for trouble. Move the INTEL_WAKEREF_PUT_* macros away from +there, making kernel-doc's life easier. + +While at it, reduce the unnecessary abstraction levels by removing the +enum, and append _MASK to INTEL_WAKEREF_PUT_DELAY for clarity. + +Cc: Andy Shevchenko +Cc: Jonathan Corbet +Acked-by: Randy Dunlap +Tested-by: Randy Dunlap +Link: https://patch.msgid.link/20251215120908.3515578-1-jani.nikula@intel.com +Signed-off-by: Jani Nikula +Signed-off-by: Sasha Levin +--- + drivers/gpu/drm/i915/intel_wakeref.c | 2 +- + drivers/gpu/drm/i915/intel_wakeref.h | 14 +++++--------- + 2 files changed, 6 insertions(+), 10 deletions(-) + +diff --git a/drivers/gpu/drm/i915/intel_wakeref.c b/drivers/gpu/drm/i915/intel_wakeref.c +index dea2f63184f89..40fbf2ccaee21 100644 +--- a/drivers/gpu/drm/i915/intel_wakeref.c ++++ b/drivers/gpu/drm/i915/intel_wakeref.c +@@ -78,7 +78,7 @@ void __intel_wakeref_put_last(struct intel_wakeref *wf, unsigned long flags) + /* Assume we are not in process context and so cannot sleep. */ + if (flags & INTEL_WAKEREF_PUT_ASYNC || !mutex_trylock(&wf->mutex)) { + mod_delayed_work(wf->i915->unordered_wq, &wf->work, +- FIELD_GET(INTEL_WAKEREF_PUT_DELAY, flags)); ++ FIELD_GET(INTEL_WAKEREF_PUT_DELAY_MASK, flags)); + return; + } + +diff --git a/drivers/gpu/drm/i915/intel_wakeref.h b/drivers/gpu/drm/i915/intel_wakeref.h +index 68aa3be482515..ca4c4a91a49fd 100644 +--- a/drivers/gpu/drm/i915/intel_wakeref.h ++++ b/drivers/gpu/drm/i915/intel_wakeref.h +@@ -131,17 +131,16 @@ intel_wakeref_get_if_active(struct intel_wakeref *wf) + return atomic_inc_not_zero(&wf->count); + } + +-enum { +- INTEL_WAKEREF_PUT_ASYNC_BIT = 0, +- __INTEL_WAKEREF_PUT_LAST_BIT__ +-}; +- + static inline void + intel_wakeref_might_get(struct intel_wakeref *wf) + { + might_lock(&wf->mutex); + } + ++/* flags for __intel_wakeref_put() and __intel_wakeref_put_last */ ++#define INTEL_WAKEREF_PUT_ASYNC BIT(0) ++#define INTEL_WAKEREF_PUT_DELAY_MASK GENMASK(BITS_PER_LONG - 1, 1) ++ + /** + * __intel_wakeref_put: Release the wakeref + * @wf: the wakeref +@@ -157,9 +156,6 @@ intel_wakeref_might_get(struct intel_wakeref *wf) + */ + static inline void + __intel_wakeref_put(struct intel_wakeref *wf, unsigned long flags) +-#define INTEL_WAKEREF_PUT_ASYNC BIT(INTEL_WAKEREF_PUT_ASYNC_BIT) +-#define INTEL_WAKEREF_PUT_DELAY \ +- GENMASK(BITS_PER_LONG - 1, __INTEL_WAKEREF_PUT_LAST_BIT__) + { + INTEL_WAKEREF_BUG_ON(atomic_read(&wf->count) <= 0); + if (unlikely(!atomic_add_unless(&wf->count, -1, 1))) +@@ -184,7 +180,7 @@ intel_wakeref_put_delay(struct intel_wakeref *wf, unsigned long delay) + { + __intel_wakeref_put(wf, + INTEL_WAKEREF_PUT_ASYNC | +- FIELD_PREP(INTEL_WAKEREF_PUT_DELAY, delay)); ++ FIELD_PREP(INTEL_WAKEREF_PUT_DELAY_MASK, delay)); + } + + static inline void +-- +2.51.0 + diff --git a/queue-6.12/series b/queue-6.12/series index 5e6542e7eb..d28c52636a 100644 --- a/queue-6.12/series +++ b/queue-6.12/series @@ -950,3 +950,4 @@ tracing-fix-checking-of-freed-trace_event_file-for-h.patch tracing-wake-up-poll-waiters-for-hist-files-when-rem.patch ntb-ntb_transport-fix-too-small-buffer-for-debugfs_n.patch alsa-pcm-revert-bufs-move-in-snd_pcm_xfern_frames_io.patch +drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch diff --git a/queue-6.18/drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch b/queue-6.18/drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch new file mode 100644 index 0000000000..86ed994439 --- /dev/null +++ b/queue-6.18/drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch @@ -0,0 +1,98 @@ +From cc13c6904d2d8185dc8d689c66d51ccf1991cdca Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 15 Dec 2025 14:09:08 +0200 +Subject: drm/i915/wakeref: clean up INTEL_WAKEREF_PUT_* flag macros + +From: Jani Nikula + +[ Upstream commit 524696a19e34598c9173fdd5b32fb7e5d16a91d3 ] + +Commit 469c1c9eb6c9 ("kernel-doc: Issue warnings that were silently +discarded") started emitting warnings for cases that were previously +silently discarded. One such case is in intel_wakeref.h: + +Warning: drivers/gpu/drm/i915/intel_wakeref.h:156 expecting prototype + for __intel_wakeref_put(). Prototype was for INTEL_WAKEREF_PUT_ASYNC() + instead + +Arguably kernel-doc should be able to handle this, as it's valid C, but +having the flags defined between the function declarator and the body is +just asking for trouble. Move the INTEL_WAKEREF_PUT_* macros away from +there, making kernel-doc's life easier. + +While at it, reduce the unnecessary abstraction levels by removing the +enum, and append _MASK to INTEL_WAKEREF_PUT_DELAY for clarity. + +Cc: Andy Shevchenko +Cc: Jonathan Corbet +Acked-by: Randy Dunlap +Tested-by: Randy Dunlap +Link: https://patch.msgid.link/20251215120908.3515578-1-jani.nikula@intel.com +Signed-off-by: Jani Nikula +Signed-off-by: Sasha Levin +--- + drivers/gpu/drm/i915/intel_wakeref.c | 2 +- + drivers/gpu/drm/i915/intel_wakeref.h | 14 +++++--------- + 2 files changed, 6 insertions(+), 10 deletions(-) + +diff --git a/drivers/gpu/drm/i915/intel_wakeref.c b/drivers/gpu/drm/i915/intel_wakeref.c +index 7fa194de5d35b..5bd75a35d0a39 100644 +--- a/drivers/gpu/drm/i915/intel_wakeref.c ++++ b/drivers/gpu/drm/i915/intel_wakeref.c +@@ -78,7 +78,7 @@ void __intel_wakeref_put_last(struct intel_wakeref *wf, unsigned long flags) + /* Assume we are not in process context and so cannot sleep. */ + if (flags & INTEL_WAKEREF_PUT_ASYNC || !mutex_trylock(&wf->mutex)) { + mod_delayed_work(wf->i915->unordered_wq, &wf->work, +- FIELD_GET(INTEL_WAKEREF_PUT_DELAY, flags)); ++ FIELD_GET(INTEL_WAKEREF_PUT_DELAY_MASK, flags)); + return; + } + +diff --git a/drivers/gpu/drm/i915/intel_wakeref.h b/drivers/gpu/drm/i915/intel_wakeref.h +index a2894a56e18fc..81308bac34bab 100644 +--- a/drivers/gpu/drm/i915/intel_wakeref.h ++++ b/drivers/gpu/drm/i915/intel_wakeref.h +@@ -128,17 +128,16 @@ intel_wakeref_get_if_active(struct intel_wakeref *wf) + return atomic_inc_not_zero(&wf->count); + } + +-enum { +- INTEL_WAKEREF_PUT_ASYNC_BIT = 0, +- __INTEL_WAKEREF_PUT_LAST_BIT__ +-}; +- + static inline void + intel_wakeref_might_get(struct intel_wakeref *wf) + { + might_lock(&wf->mutex); + } + ++/* flags for __intel_wakeref_put() and __intel_wakeref_put_last */ ++#define INTEL_WAKEREF_PUT_ASYNC BIT(0) ++#define INTEL_WAKEREF_PUT_DELAY_MASK GENMASK(BITS_PER_LONG - 1, 1) ++ + /** + * __intel_wakeref_put: Release the wakeref + * @wf: the wakeref +@@ -154,9 +153,6 @@ intel_wakeref_might_get(struct intel_wakeref *wf) + */ + static inline void + __intel_wakeref_put(struct intel_wakeref *wf, unsigned long flags) +-#define INTEL_WAKEREF_PUT_ASYNC BIT(INTEL_WAKEREF_PUT_ASYNC_BIT) +-#define INTEL_WAKEREF_PUT_DELAY \ +- GENMASK(BITS_PER_LONG - 1, __INTEL_WAKEREF_PUT_LAST_BIT__) + { + INTEL_WAKEREF_BUG_ON(atomic_read(&wf->count) <= 0); + if (unlikely(!atomic_add_unless(&wf->count, -1, 1))) +@@ -181,7 +177,7 @@ intel_wakeref_put_delay(struct intel_wakeref *wf, unsigned long delay) + { + __intel_wakeref_put(wf, + INTEL_WAKEREF_PUT_ASYNC | +- FIELD_PREP(INTEL_WAKEREF_PUT_DELAY, delay)); ++ FIELD_PREP(INTEL_WAKEREF_PUT_DELAY_MASK, delay)); + } + + static inline void +-- +2.51.0 + diff --git a/queue-6.18/series b/queue-6.18/series index fc053d4386..1c8d7957e7 100644 --- a/queue-6.18/series +++ b/queue-6.18/series @@ -749,3 +749,4 @@ rust-list-add-unsafe-blocks-for-container_of-and-saf.patch ntb-ntb_transport-fix-too-small-buffer-for-debugfs_n.patch alsa-pcm-revert-bufs-move-in-snd_pcm_xfern_frames_io.patch revert-acpi-processor-update-cpuidle-driver-check-in.patch +drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch diff --git a/queue-6.19/drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch b/queue-6.19/drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch new file mode 100644 index 0000000000..4a2f0e42a0 --- /dev/null +++ b/queue-6.19/drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch @@ -0,0 +1,98 @@ +From ce0e5eb7c2ff7cec89e6ea94092902f6a16fd888 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 15 Dec 2025 14:09:08 +0200 +Subject: drm/i915/wakeref: clean up INTEL_WAKEREF_PUT_* flag macros + +From: Jani Nikula + +[ Upstream commit 524696a19e34598c9173fdd5b32fb7e5d16a91d3 ] + +Commit 469c1c9eb6c9 ("kernel-doc: Issue warnings that were silently +discarded") started emitting warnings for cases that were previously +silently discarded. One such case is in intel_wakeref.h: + +Warning: drivers/gpu/drm/i915/intel_wakeref.h:156 expecting prototype + for __intel_wakeref_put(). Prototype was for INTEL_WAKEREF_PUT_ASYNC() + instead + +Arguably kernel-doc should be able to handle this, as it's valid C, but +having the flags defined between the function declarator and the body is +just asking for trouble. Move the INTEL_WAKEREF_PUT_* macros away from +there, making kernel-doc's life easier. + +While at it, reduce the unnecessary abstraction levels by removing the +enum, and append _MASK to INTEL_WAKEREF_PUT_DELAY for clarity. + +Cc: Andy Shevchenko +Cc: Jonathan Corbet +Acked-by: Randy Dunlap +Tested-by: Randy Dunlap +Link: https://patch.msgid.link/20251215120908.3515578-1-jani.nikula@intel.com +Signed-off-by: Jani Nikula +Signed-off-by: Sasha Levin +--- + drivers/gpu/drm/i915/intel_wakeref.c | 2 +- + drivers/gpu/drm/i915/intel_wakeref.h | 14 +++++--------- + 2 files changed, 6 insertions(+), 10 deletions(-) + +diff --git a/drivers/gpu/drm/i915/intel_wakeref.c b/drivers/gpu/drm/i915/intel_wakeref.c +index b1883dccc22af..98e7cee4e1dcc 100644 +--- a/drivers/gpu/drm/i915/intel_wakeref.c ++++ b/drivers/gpu/drm/i915/intel_wakeref.c +@@ -80,7 +80,7 @@ void __intel_wakeref_put_last(struct intel_wakeref *wf, unsigned long flags) + /* Assume we are not in process context and so cannot sleep. */ + if (flags & INTEL_WAKEREF_PUT_ASYNC || !mutex_trylock(&wf->mutex)) { + mod_delayed_work(wf->i915->unordered_wq, &wf->work, +- FIELD_GET(INTEL_WAKEREF_PUT_DELAY, flags)); ++ FIELD_GET(INTEL_WAKEREF_PUT_DELAY_MASK, flags)); + return; + } + +diff --git a/drivers/gpu/drm/i915/intel_wakeref.h b/drivers/gpu/drm/i915/intel_wakeref.h +index a2894a56e18fc..81308bac34bab 100644 +--- a/drivers/gpu/drm/i915/intel_wakeref.h ++++ b/drivers/gpu/drm/i915/intel_wakeref.h +@@ -128,17 +128,16 @@ intel_wakeref_get_if_active(struct intel_wakeref *wf) + return atomic_inc_not_zero(&wf->count); + } + +-enum { +- INTEL_WAKEREF_PUT_ASYNC_BIT = 0, +- __INTEL_WAKEREF_PUT_LAST_BIT__ +-}; +- + static inline void + intel_wakeref_might_get(struct intel_wakeref *wf) + { + might_lock(&wf->mutex); + } + ++/* flags for __intel_wakeref_put() and __intel_wakeref_put_last */ ++#define INTEL_WAKEREF_PUT_ASYNC BIT(0) ++#define INTEL_WAKEREF_PUT_DELAY_MASK GENMASK(BITS_PER_LONG - 1, 1) ++ + /** + * __intel_wakeref_put: Release the wakeref + * @wf: the wakeref +@@ -154,9 +153,6 @@ intel_wakeref_might_get(struct intel_wakeref *wf) + */ + static inline void + __intel_wakeref_put(struct intel_wakeref *wf, unsigned long flags) +-#define INTEL_WAKEREF_PUT_ASYNC BIT(INTEL_WAKEREF_PUT_ASYNC_BIT) +-#define INTEL_WAKEREF_PUT_DELAY \ +- GENMASK(BITS_PER_LONG - 1, __INTEL_WAKEREF_PUT_LAST_BIT__) + { + INTEL_WAKEREF_BUG_ON(atomic_read(&wf->count) <= 0); + if (unlikely(!atomic_add_unless(&wf->count, -1, 1))) +@@ -181,7 +177,7 @@ intel_wakeref_put_delay(struct intel_wakeref *wf, unsigned long delay) + { + __intel_wakeref_put(wf, + INTEL_WAKEREF_PUT_ASYNC | +- FIELD_PREP(INTEL_WAKEREF_PUT_DELAY, delay)); ++ FIELD_PREP(INTEL_WAKEREF_PUT_DELAY_MASK, delay)); + } + + static inline void +-- +2.51.0 + diff --git a/queue-6.19/series b/queue-6.19/series index 06db46a650..046810692f 100644 --- a/queue-6.19/series +++ b/queue-6.19/series @@ -841,3 +841,4 @@ rust-list-add-unsafe-blocks-for-container_of-and-saf.patch ntb-ntb_transport-fix-too-small-buffer-for-debugfs_n.patch alsa-pcm-revert-bufs-move-in-snd_pcm_xfern_frames_io.patch revert-acpi-processor-update-cpuidle-driver-check-in.patch +drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch diff --git a/queue-6.6/drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch b/queue-6.6/drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch new file mode 100644 index 0000000000..870ebf54ee --- /dev/null +++ b/queue-6.6/drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch @@ -0,0 +1,98 @@ +From 1e2a2377dffca770244c79bab5456baa91edc252 Mon Sep 17 00:00:00 2001 +From: Sasha Levin +Date: Mon, 15 Dec 2025 14:09:08 +0200 +Subject: drm/i915/wakeref: clean up INTEL_WAKEREF_PUT_* flag macros + +From: Jani Nikula + +[ Upstream commit 524696a19e34598c9173fdd5b32fb7e5d16a91d3 ] + +Commit 469c1c9eb6c9 ("kernel-doc: Issue warnings that were silently +discarded") started emitting warnings for cases that were previously +silently discarded. One such case is in intel_wakeref.h: + +Warning: drivers/gpu/drm/i915/intel_wakeref.h:156 expecting prototype + for __intel_wakeref_put(). Prototype was for INTEL_WAKEREF_PUT_ASYNC() + instead + +Arguably kernel-doc should be able to handle this, as it's valid C, but +having the flags defined between the function declarator and the body is +just asking for trouble. Move the INTEL_WAKEREF_PUT_* macros away from +there, making kernel-doc's life easier. + +While at it, reduce the unnecessary abstraction levels by removing the +enum, and append _MASK to INTEL_WAKEREF_PUT_DELAY for clarity. + +Cc: Andy Shevchenko +Cc: Jonathan Corbet +Acked-by: Randy Dunlap +Tested-by: Randy Dunlap +Link: https://patch.msgid.link/20251215120908.3515578-1-jani.nikula@intel.com +Signed-off-by: Jani Nikula +Signed-off-by: Sasha Levin +--- + drivers/gpu/drm/i915/intel_wakeref.c | 2 +- + drivers/gpu/drm/i915/intel_wakeref.h | 14 +++++--------- + 2 files changed, 6 insertions(+), 10 deletions(-) + +diff --git a/drivers/gpu/drm/i915/intel_wakeref.c b/drivers/gpu/drm/i915/intel_wakeref.c +index 718f2f1b6174d..a2bffa4a4dd15 100644 +--- a/drivers/gpu/drm/i915/intel_wakeref.c ++++ b/drivers/gpu/drm/i915/intel_wakeref.c +@@ -76,7 +76,7 @@ void __intel_wakeref_put_last(struct intel_wakeref *wf, unsigned long flags) + /* Assume we are not in process context and so cannot sleep. */ + if (flags & INTEL_WAKEREF_PUT_ASYNC || !mutex_trylock(&wf->mutex)) { + mod_delayed_work(wf->i915->unordered_wq, &wf->work, +- FIELD_GET(INTEL_WAKEREF_PUT_DELAY, flags)); ++ FIELD_GET(INTEL_WAKEREF_PUT_DELAY_MASK, flags)); + return; + } + +diff --git a/drivers/gpu/drm/i915/intel_wakeref.h b/drivers/gpu/drm/i915/intel_wakeref.h +index ec881b0973689..9923628d706cc 100644 +--- a/drivers/gpu/drm/i915/intel_wakeref.h ++++ b/drivers/gpu/drm/i915/intel_wakeref.h +@@ -119,17 +119,16 @@ intel_wakeref_get_if_active(struct intel_wakeref *wf) + return atomic_inc_not_zero(&wf->count); + } + +-enum { +- INTEL_WAKEREF_PUT_ASYNC_BIT = 0, +- __INTEL_WAKEREF_PUT_LAST_BIT__ +-}; +- + static inline void + intel_wakeref_might_get(struct intel_wakeref *wf) + { + might_lock(&wf->mutex); + } + ++/* flags for __intel_wakeref_put() and __intel_wakeref_put_last */ ++#define INTEL_WAKEREF_PUT_ASYNC BIT(0) ++#define INTEL_WAKEREF_PUT_DELAY_MASK GENMASK(BITS_PER_LONG - 1, 1) ++ + /** + * __intel_wakeref_put: Release the wakeref + * @wf: the wakeref +@@ -145,9 +144,6 @@ intel_wakeref_might_get(struct intel_wakeref *wf) + */ + static inline void + __intel_wakeref_put(struct intel_wakeref *wf, unsigned long flags) +-#define INTEL_WAKEREF_PUT_ASYNC BIT(INTEL_WAKEREF_PUT_ASYNC_BIT) +-#define INTEL_WAKEREF_PUT_DELAY \ +- GENMASK(BITS_PER_LONG - 1, __INTEL_WAKEREF_PUT_LAST_BIT__) + { + INTEL_WAKEREF_BUG_ON(atomic_read(&wf->count) <= 0); + if (unlikely(!atomic_add_unless(&wf->count, -1, 1))) +@@ -172,7 +168,7 @@ intel_wakeref_put_delay(struct intel_wakeref *wf, unsigned long delay) + { + __intel_wakeref_put(wf, + INTEL_WAKEREF_PUT_ASYNC | +- FIELD_PREP(INTEL_WAKEREF_PUT_DELAY, delay)); ++ FIELD_PREP(INTEL_WAKEREF_PUT_DELAY_MASK, delay)); + } + + static inline void +-- +2.51.0 + diff --git a/queue-6.6/series b/queue-6.6/series index 6382f1c605..34c124e3ee 100644 --- a/queue-6.6/series +++ b/queue-6.6/series @@ -680,3 +680,4 @@ net-nfc-nci-fix-parameter-validation-for-packet-data.patch tracing-fix-checking-of-freed-trace_event_file-for-h.patch tracing-wake-up-poll-waiters-for-hist-files-when-rem.patch ntb-ntb_transport-fix-too-small-buffer-for-debugfs_n.patch +drm-i915-wakeref-clean-up-intel_wakeref_put_-flag-ma.patch