* FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree
@ 2026-03-17 11:47 gregkh
2026-03-17 16:22 ` [PATCH 6.12.y] drm/xe/sync: Cleanup partially initialized sync on parse failure Shuicheng Lin
2026-03-17 16:27 ` FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree Lin, Shuicheng
0 siblings, 2 replies; 10+ messages in thread
From: gregkh @ 2026-03-17 11:47 UTC (permalink / raw)
To: shuicheng.lin, matthew.brost, rodrigo.vivi; +Cc: stable
The patch below does not apply to the 6.12-stable tree.
If someone wants it applied there, or to any other stable or longterm
tree, then please email the backport, including the original git commit
id to <stable@vger.kernel.org>.
To reproduce the conflict and resubmit, you may use the following commands:
git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.12.y
git checkout FETCH_HEAD
git cherry-pick -x 1bfd7575092420ba5a0b944953c95b74a5646ff8
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<stable@vger.kernel.org>' --in-reply-to '2026031732-size-unfasten-2bf3@gregkh' --subject-prefix 'PATCH 6.12.y' HEAD^..
Possible dependencies:
thanks,
greg k-h
------------------ original commit in Linus's tree ------------------
From 1bfd7575092420ba5a0b944953c95b74a5646ff8 Mon Sep 17 00:00:00 2001
From: Shuicheng Lin <shuicheng.lin@intel.com>
Date: Thu, 19 Feb 2026 23:35:18 +0000
Subject: [PATCH] drm/xe/sync: Cleanup partially initialized sync on parse
failure
xe_sync_entry_parse() can allocate references (syncobj, fence, chain fence,
or user fence) before hitting a later failure path. Several of those paths
returned directly, leaving partially initialized state and leaking refs.
Route these error paths through a common free_sync label and call
xe_sync_entry_cleanup(sync) before returning the error.
Fixes: dd08ebf6c352 ("drm/xe: Introduce a new DRM driver for Intel GPUs")
Cc: Matthew Brost <matthew.brost@intel.com>
Signed-off-by: Shuicheng Lin <shuicheng.lin@intel.com>
Reviewed-by: Matthew Brost <matthew.brost@intel.com>
Signed-off-by: Matthew Brost <matthew.brost@intel.com>
Link: https://patch.msgid.link/20260219233516.2938172-5-shuicheng.lin@intel.com
(cherry picked from commit f939bdd9207a5d1fc55cced5459858480686ce22)
Cc: stable@vger.kernel.org
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
diff --git a/drivers/gpu/drm/xe/xe_sync.c b/drivers/gpu/drm/xe/xe_sync.c
index eb136390dafd..ebf6c96d7a41 100644
--- a/drivers/gpu/drm/xe/xe_sync.c
+++ b/drivers/gpu/drm/xe/xe_sync.c
@@ -146,8 +146,10 @@ int xe_sync_entry_parse(struct xe_device *xe, struct xe_file *xef,
if (!signal) {
sync->fence = drm_syncobj_fence_get(sync->syncobj);
- if (XE_IOCTL_DBG(xe, !sync->fence))
- return -EINVAL;
+ if (XE_IOCTL_DBG(xe, !sync->fence)) {
+ err = -EINVAL;
+ goto free_sync;
+ }
}
break;
@@ -167,17 +169,21 @@ int xe_sync_entry_parse(struct xe_device *xe, struct xe_file *xef,
if (signal) {
sync->chain_fence = dma_fence_chain_alloc();
- if (!sync->chain_fence)
- return -ENOMEM;
+ if (!sync->chain_fence) {
+ err = -ENOMEM;
+ goto free_sync;
+ }
} else {
sync->fence = drm_syncobj_fence_get(sync->syncobj);
- if (XE_IOCTL_DBG(xe, !sync->fence))
- return -EINVAL;
+ if (XE_IOCTL_DBG(xe, !sync->fence)) {
+ err = -EINVAL;
+ goto free_sync;
+ }
err = dma_fence_chain_find_seqno(&sync->fence,
sync_in.timeline_value);
if (err)
- return err;
+ goto free_sync;
}
break;
@@ -216,6 +222,10 @@ int xe_sync_entry_parse(struct xe_device *xe, struct xe_file *xef,
sync->timeline_value = sync_in.timeline_value;
return 0;
+
+free_sync:
+ xe_sync_entry_cleanup(sync);
+ return err;
}
ALLOW_ERROR_INJECTION(xe_sync_entry_parse, ERRNO);
^ permalink raw reply related [flat|nested] 10+ messages in thread
* [PATCH 6.12.y] drm/xe/sync: Cleanup partially initialized sync on parse failure
2026-03-17 11:47 FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree gregkh
@ 2026-03-17 16:22 ` Shuicheng Lin
2026-03-17 16:27 ` FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree Lin, Shuicheng
1 sibling, 0 replies; 10+ messages in thread
From: Shuicheng Lin @ 2026-03-17 16:22 UTC (permalink / raw)
To: stable; +Cc: Shuicheng Lin, Matthew Brost, Rodrigo Vivi
xe_sync_entry_parse() can allocate references (syncobj, fence, chain fence,
or user fence) before hitting a later failure path. Several of those paths
returned directly, leaving partially initialized state and leaking refs.
Route these error paths through a common free_sync label and call
xe_sync_entry_cleanup(sync) before returning the error.
Fixes: dd08ebf6c352 ("drm/xe: Introduce a new DRM driver for Intel GPUs")
Cc: Matthew Brost <matthew.brost@intel.com>
Signed-off-by: Shuicheng Lin <shuicheng.lin@intel.com>
Reviewed-by: Matthew Brost <matthew.brost@intel.com>
Signed-off-by: Matthew Brost <matthew.brost@intel.com>
Link: https://patch.msgid.link/20260219233516.2938172-5-shuicheng.lin@intel.com
(cherry picked from commit f939bdd9207a5d1fc55cced5459858480686ce22)
Cc: stable@vger.kernel.org
Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
(cherry picked from commit 1bfd7575092420ba5a0b944953c95b74a5646ff8)
Signed-off-by: Shuicheng Lin <shuicheng.lin@intel.com>
---
drivers/gpu/drm/xe/xe_sync.c | 24 +++++++++++++++++-------
1 file changed, 17 insertions(+), 7 deletions(-)
diff --git a/drivers/gpu/drm/xe/xe_sync.c b/drivers/gpu/drm/xe/xe_sync.c
index dd7bd766ae18..6affdd0a8095 100644
--- a/drivers/gpu/drm/xe/xe_sync.c
+++ b/drivers/gpu/drm/xe/xe_sync.c
@@ -142,8 +142,10 @@ int xe_sync_entry_parse(struct xe_device *xe, struct xe_file *xef,
if (!signal) {
sync->fence = drm_syncobj_fence_get(sync->syncobj);
- if (XE_IOCTL_DBG(xe, !sync->fence))
- return -EINVAL;
+ if (XE_IOCTL_DBG(xe, !sync->fence)) {
+ err = -EINVAL;
+ goto free_sync;
+ }
}
break;
@@ -163,17 +165,21 @@ int xe_sync_entry_parse(struct xe_device *xe, struct xe_file *xef,
if (signal) {
sync->chain_fence = dma_fence_chain_alloc();
- if (!sync->chain_fence)
- return -ENOMEM;
+ if (!sync->chain_fence) {
+ err = -ENOMEM;
+ goto free_sync;
+ }
} else {
sync->fence = drm_syncobj_fence_get(sync->syncobj);
- if (XE_IOCTL_DBG(xe, !sync->fence))
- return -EINVAL;
+ if (XE_IOCTL_DBG(xe, !sync->fence)) {
+ err = -EINVAL;
+ goto free_sync;
+ }
err = dma_fence_chain_find_seqno(&sync->fence,
sync_in.timeline_value);
if (err)
- return err;
+ goto free_sync;
}
break;
@@ -207,6 +213,10 @@ int xe_sync_entry_parse(struct xe_device *xe, struct xe_file *xef,
sync->timeline_value = sync_in.timeline_value;
return 0;
+
+free_sync:
+ xe_sync_entry_cleanup(sync);
+ return err;
}
int xe_sync_entry_add_deps(struct xe_sync_entry *sync, struct xe_sched_job *job)
--
2.50.1
^ permalink raw reply related [flat|nested] 10+ messages in thread
* RE: FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree
2026-03-17 11:47 FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree gregkh
2026-03-17 16:22 ` [PATCH 6.12.y] drm/xe/sync: Cleanup partially initialized sync on parse failure Shuicheng Lin
@ 2026-03-17 16:27 ` Lin, Shuicheng
2026-03-17 16:31 ` gregkh
1 sibling, 1 reply; 10+ messages in thread
From: Lin, Shuicheng @ 2026-03-17 16:27 UTC (permalink / raw)
To: gregkh@linuxfoundation.org, Brost, Matthew, Vivi, Rodrigo
Cc: stable@vger.kernel.org
On Tue, Mar 17, 2026 4:48 AM gregkh wrote:
> The patch below does not apply to the 6.12-stable tree.
> If someone wants it applied there, or to any other stable or longterm tree,
> then please email the backport, including the original git commit id to
> <stable@vger.kernel.org>.
>
> To reproduce the conflict and resubmit, you may use the following commands:
>
> git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
> linux-6.12.y git checkout FETCH_HEAD git cherry-pick -x
> 1bfd7575092420ba5a0b944953c95b74a5646ff8
> # <resolve conflicts, build, test, etc.> git commit -s git send-email --to
> '<stable@vger.kernel.org>' --in-reply-to '2026031732-size-unfasten-
> 2bf3@gregkh' --subject-prefix 'PATCH 6.12.y' HEAD^..
I cannot reproduce the failure with upper cmd.
The patch could be applied successfully without conflict.
Anyway, I follow the instructions re-send the patch.
Let me know if it still has issue.
Thanks.
Shuicheng
>
> Possible dependencies:
>
>
>
> thanks,
>
> greg k-h
>
> ------------------ original commit in Linus's tree ------------------
>
> From 1bfd7575092420ba5a0b944953c95b74a5646ff8 Mon Sep 17
> 00:00:00 2001
> From: Shuicheng Lin <shuicheng.lin@intel.com>
> Date: Thu, 19 Feb 2026 23:35:18 +0000
> Subject: [PATCH] drm/xe/sync: Cleanup partially initialized sync on parse
> failure
>
> xe_sync_entry_parse() can allocate references (syncobj, fence, chain fence, or
> user fence) before hitting a later failure path. Several of those paths returned
> directly, leaving partially initialized state and leaking refs.
>
> Route these error paths through a common free_sync label and call
> xe_sync_entry_cleanup(sync) before returning the error.
>
> Fixes: dd08ebf6c352 ("drm/xe: Introduce a new DRM driver for Intel GPUs")
> Cc: Matthew Brost <matthew.brost@intel.com>
> Signed-off-by: Shuicheng Lin <shuicheng.lin@intel.com>
> Reviewed-by: Matthew Brost <matthew.brost@intel.com>
> Signed-off-by: Matthew Brost <matthew.brost@intel.com>
> Link: https://patch.msgid.link/20260219233516.2938172-5-
> shuicheng.lin@intel.com
> (cherry picked from commit
> f939bdd9207a5d1fc55cced5459858480686ce22)
> Cc: stable@vger.kernel.org
> Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
>
> diff --git a/drivers/gpu/drm/xe/xe_sync.c b/drivers/gpu/drm/xe/xe_sync.c
> index eb136390dafd..ebf6c96d7a41 100644
> --- a/drivers/gpu/drm/xe/xe_sync.c
> +++ b/drivers/gpu/drm/xe/xe_sync.c
> @@ -146,8 +146,10 @@ int xe_sync_entry_parse(struct xe_device *xe, struct
> xe_file *xef,
>
> if (!signal) {
> sync->fence = drm_syncobj_fence_get(sync-
> >syncobj);
> - if (XE_IOCTL_DBG(xe, !sync->fence))
> - return -EINVAL;
> + if (XE_IOCTL_DBG(xe, !sync->fence)) {
> + err = -EINVAL;
> + goto free_sync;
> + }
> }
> break;
>
> @@ -167,17 +169,21 @@ int xe_sync_entry_parse(struct xe_device *xe,
> struct xe_file *xef,
>
> if (signal) {
> sync->chain_fence = dma_fence_chain_alloc();
> - if (!sync->chain_fence)
> - return -ENOMEM;
> + if (!sync->chain_fence) {
> + err = -ENOMEM;
> + goto free_sync;
> + }
> } else {
> sync->fence = drm_syncobj_fence_get(sync-
> >syncobj);
> - if (XE_IOCTL_DBG(xe, !sync->fence))
> - return -EINVAL;
> + if (XE_IOCTL_DBG(xe, !sync->fence)) {
> + err = -EINVAL;
> + goto free_sync;
> + }
>
> err = dma_fence_chain_find_seqno(&sync->fence,
>
> sync_in.timeline_value);
> if (err)
> - return err;
> + goto free_sync;
> }
> break;
>
> @@ -216,6 +222,10 @@ int xe_sync_entry_parse(struct xe_device *xe, struct
> xe_file *xef,
> sync->timeline_value = sync_in.timeline_value;
>
> return 0;
> +
> +free_sync:
> + xe_sync_entry_cleanup(sync);
> + return err;
> }
> ALLOW_ERROR_INJECTION(xe_sync_entry_parse, ERRNO);
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree
2026-03-17 16:27 ` FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree Lin, Shuicheng
@ 2026-03-17 16:31 ` gregkh
2026-03-17 17:10 ` Lin, Shuicheng
0 siblings, 1 reply; 10+ messages in thread
From: gregkh @ 2026-03-17 16:31 UTC (permalink / raw)
To: Lin, Shuicheng; +Cc: Brost, Matthew, Vivi, Rodrigo, stable@vger.kernel.org
On Tue, Mar 17, 2026 at 04:27:46PM +0000, Lin, Shuicheng wrote:
> On Tue, Mar 17, 2026 4:48 AM gregkh wrote:
> > The patch below does not apply to the 6.12-stable tree.
> > If someone wants it applied there, or to any other stable or longterm tree,
> > then please email the backport, including the original git commit id to
> > <stable@vger.kernel.org>.
> >
> > To reproduce the conflict and resubmit, you may use the following commands:
> >
> > git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
> > linux-6.12.y git checkout FETCH_HEAD git cherry-pick -x
> > 1bfd7575092420ba5a0b944953c95b74a5646ff8
> > # <resolve conflicts, build, test, etc.> git commit -s git send-email --to
> > '<stable@vger.kernel.org>' --in-reply-to '2026031732-size-unfasten-
> > 2bf3@gregkh' --subject-prefix 'PATCH 6.12.y' HEAD^..
>
> I cannot reproduce the failure with upper cmd.
> The patch could be applied successfully without conflict.
> Anyway, I follow the instructions re-send the patch.
> Let me know if it still has issue.
Try building it after it is applied and notice how it breaks the build :(
thanks,
greg k-h
^ permalink raw reply [flat|nested] 10+ messages in thread
* RE: FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree
2026-03-17 16:31 ` gregkh
@ 2026-03-17 17:10 ` Lin, Shuicheng
2026-03-18 12:25 ` gregkh
0 siblings, 1 reply; 10+ messages in thread
From: Lin, Shuicheng @ 2026-03-17 17:10 UTC (permalink / raw)
To: gregkh@linuxfoundation.org
Cc: Brost, Matthew, Vivi, Rodrigo, stable@vger.kernel.org
On Tue, Mar 17, 2026 9:32 AM greg k-h wrote:
> On Tue, Mar 17, 2026 at 04:27:46PM +0000, Lin, Shuicheng wrote:
> > On Tue, Mar 17, 2026 4:48 AM gregkh wrote:
> > > The patch below does not apply to the 6.12-stable tree.
> > > If someone wants it applied there, or to any other stable or
> > > longterm tree, then please email the backport, including the
> > > original git commit id to <stable@vger.kernel.org>.
> > >
> > > To reproduce the conflict and resubmit, you may use the following
> commands:
> > >
> > > git fetch
> > > https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
> > > linux-6.12.y git checkout FETCH_HEAD git cherry-pick -x
> > > 1bfd7575092420ba5a0b944953c95b74a5646ff8
> > > # <resolve conflicts, build, test, etc.> git commit -s git
> > > send-email --to '<stable@vger.kernel.org>' --in-reply-to
> > > '2026031732-size-unfasten- 2bf3@gregkh' --subject-prefix 'PATCH 6.12.y'
> HEAD^..
> >
> > I cannot reproduce the failure with upper cmd.
> > The patch could be applied successfully without conflict.
> > Anyway, I follow the instructions re-send the patch.
> > Let me know if it still has issue.
>
> Try building it after it is applied and notice how it breaks the build :(
I tried to do it, and it could build successfully.
I checked the code and cannot find what will cause the build failure.
Could you please share me the failure signature?
Thanks.
Shuicheng
>
> thanks,
>
> greg k-h
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree
2026-03-17 17:10 ` Lin, Shuicheng
@ 2026-03-18 12:25 ` gregkh
2026-03-18 16:26 ` Lin, Shuicheng
0 siblings, 1 reply; 10+ messages in thread
From: gregkh @ 2026-03-18 12:25 UTC (permalink / raw)
To: Lin, Shuicheng; +Cc: Brost, Matthew, Vivi, Rodrigo, stable@vger.kernel.org
On Tue, Mar 17, 2026 at 05:10:53PM +0000, Lin, Shuicheng wrote:
> On Tue, Mar 17, 2026 9:32 AM greg k-h wrote:
> > On Tue, Mar 17, 2026 at 04:27:46PM +0000, Lin, Shuicheng wrote:
> > > On Tue, Mar 17, 2026 4:48 AM gregkh wrote:
> > > > The patch below does not apply to the 6.12-stable tree.
> > > > If someone wants it applied there, or to any other stable or
> > > > longterm tree, then please email the backport, including the
> > > > original git commit id to <stable@vger.kernel.org>.
> > > >
> > > > To reproduce the conflict and resubmit, you may use the following
> > commands:
> > > >
> > > > git fetch
> > > > https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/
> > > > linux-6.12.y git checkout FETCH_HEAD git cherry-pick -x
> > > > 1bfd7575092420ba5a0b944953c95b74a5646ff8
> > > > # <resolve conflicts, build, test, etc.> git commit -s git
> > > > send-email --to '<stable@vger.kernel.org>' --in-reply-to
> > > > '2026031732-size-unfasten- 2bf3@gregkh' --subject-prefix 'PATCH 6.12.y'
> > HEAD^..
> > >
> > > I cannot reproduce the failure with upper cmd.
> > > The patch could be applied successfully without conflict.
> > > Anyway, I follow the instructions re-send the patch.
> > > Let me know if it still has issue.
> >
> > Try building it after it is applied and notice how it breaks the build :(
>
> I tried to do it, and it could build successfully.
> I checked the code and cannot find what will cause the build failure.
> Could you please share me the failure signature?
CC [M] drivers/gpu/drm/xe/xe_sync.o
drivers/gpu/drm/xe/xe_sync.c: In function ‘xe_sync_entry_parse’:
drivers/gpu/drm/xe/xe_sync.c:182:33: error: label ‘free_sync’ used but not defined
182 | goto free_sync;
| ^~~~
drivers/gpu/drm/xe/xe_sync.c: In function ‘xe_sync_entry_add_deps’:
drivers/gpu/drm/xe/xe_sync.c:228:16: error: ‘err’ undeclared (first use in this function)
228 | return err;
| ^~~
drivers/gpu/drm/xe/xe_sync.c:228:16: note: each undeclared identifier is reported only once for each function it appears in
drivers/gpu/drm/xe/xe_sync.c:226:1: error: label ‘free_sync’ defined but not used [-Werror=unused-label]
226 | free_sync:
| ^~~~~~~~~
cc1: all warnings being treated as errors
^ permalink raw reply [flat|nested] 10+ messages in thread
* RE: FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree
2026-03-18 12:25 ` gregkh
@ 2026-03-18 16:26 ` Lin, Shuicheng
2026-03-18 16:58 ` gregkh
0 siblings, 1 reply; 10+ messages in thread
From: Lin, Shuicheng @ 2026-03-18 16:26 UTC (permalink / raw)
To: gregkh@linuxfoundation.org
Cc: Brost, Matthew, Vivi, Rodrigo, stable@vger.kernel.org
On Wed, Mar 18, 2026 5:25 AM gregkh wrote:
> On Tue, Mar 17, 2026 at 05:10:53PM +0000, Lin, Shuicheng wrote:
> > On Tue, Mar 17, 2026 9:32 AM greg k-h wrote:
> > > On Tue, Mar 17, 2026 at 04:27:46PM +0000, Lin, Shuicheng wrote:
> > > > On Tue, Mar 17, 2026 4:48 AM gregkh wrote:
> > > > > The patch below does not apply to the 6.12-stable tree.
> > > > > If someone wants it applied there, or to any other stable or
> > > > > longterm tree, then please email the backport, including the
> > > > > original git commit id to <stable@vger.kernel.org>.
> > > > >
> > > > > To reproduce the conflict and resubmit, you may use the
> > > > > following
> > > commands:
> > > > >
> > > > > git fetch
> > > > > https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
> > > > > / linux-6.12.y git checkout FETCH_HEAD git cherry-pick -x
> > > > > 1bfd7575092420ba5a0b944953c95b74a5646ff8
> > > > > # <resolve conflicts, build, test, etc.> git commit -s git
> > > > > send-email --to '<stable@vger.kernel.org>' --in-reply-to
> > > > > '2026031732-size-unfasten- 2bf3@gregkh' --subject-prefix 'PATCH
> 6.12.y'
> > > HEAD^..
> > > >
> > > > I cannot reproduce the failure with upper cmd.
> > > > The patch could be applied successfully without conflict.
> > > > Anyway, I follow the instructions re-send the patch.
> > > > Let me know if it still has issue.
> > >
> > > Try building it after it is applied and notice how it breaks the
> > > build :(
> >
> > I tried to do it, and it could build successfully.
> > I checked the code and cannot find what will cause the build failure.
> > Could you please share me the failure signature?
>
> CC [M] drivers/gpu/drm/xe/xe_sync.o
> drivers/gpu/drm/xe/xe_sync.c: In function ‘xe_sync_entry_parse’:
> drivers/gpu/drm/xe/xe_sync.c:182:33: error: label ‘free_sync’ used but not
> defined
> 182 | goto free_sync;
> | ^~~~
Thanks for the log.
It seems the patch is not applied correctly and cause the build failure.
For the original patch 1bfd75750924 ("drm/xe/sync: Cleanup partially initialized sync on parse failure"),
all the change is within function xe_sync_entry_parse().
This "free_sync" label is added at the end of xe_sync_entry_parse(), and some error path use goto to jump to this label.
For this and below err, it seems the last part of this patch is applied to function xe_sync_entry_add_deps(), which is the function after xe_sync_entry_parse().
The err should be due to "free_sync" label is added to function xe_sync_entry_add_deps() instead of xe_sync_entry_parse().
Could you please help me confirm it?
Thanks.
Shuicheng
> drivers/gpu/drm/xe/xe_sync.c: In function ‘xe_sync_entry_add_deps’:
> drivers/gpu/drm/xe/xe_sync.c:228:16: error: ‘err’ undeclared (first use in this
> function)
> 228 | return err;
> | ^~~
> drivers/gpu/drm/xe/xe_sync.c:228:16: note: each undeclared identifier is
> reported only once for each function it appears in
> drivers/gpu/drm/xe/xe_sync.c:226:1: error: label ‘free_sync’ defined but not
> used [-Werror=unused-label]
> 226 | free_sync:
> | ^~~~~~~~~
> cc1: all warnings being treated as errors
>
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree
2026-03-18 16:26 ` Lin, Shuicheng
@ 2026-03-18 16:58 ` gregkh
2026-03-18 17:20 ` Lin, Shuicheng
0 siblings, 1 reply; 10+ messages in thread
From: gregkh @ 2026-03-18 16:58 UTC (permalink / raw)
To: Lin, Shuicheng; +Cc: Brost, Matthew, Vivi, Rodrigo, stable@vger.kernel.org
On Wed, Mar 18, 2026 at 04:26:44PM +0000, Lin, Shuicheng wrote:
> On Wed, Mar 18, 2026 5:25 AM gregkh wrote:
> > On Tue, Mar 17, 2026 at 05:10:53PM +0000, Lin, Shuicheng wrote:
> > > On Tue, Mar 17, 2026 9:32 AM greg k-h wrote:
> > > > On Tue, Mar 17, 2026 at 04:27:46PM +0000, Lin, Shuicheng wrote:
> > > > > On Tue, Mar 17, 2026 4:48 AM gregkh wrote:
> > > > > > The patch below does not apply to the 6.12-stable tree.
> > > > > > If someone wants it applied there, or to any other stable or
> > > > > > longterm tree, then please email the backport, including the
> > > > > > original git commit id to <stable@vger.kernel.org>.
> > > > > >
> > > > > > To reproduce the conflict and resubmit, you may use the
> > > > > > following
> > > > commands:
> > > > > >
> > > > > > git fetch
> > > > > > https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
> > > > > > / linux-6.12.y git checkout FETCH_HEAD git cherry-pick -x
> > > > > > 1bfd7575092420ba5a0b944953c95b74a5646ff8
> > > > > > # <resolve conflicts, build, test, etc.> git commit -s git
> > > > > > send-email --to '<stable@vger.kernel.org>' --in-reply-to
> > > > > > '2026031732-size-unfasten- 2bf3@gregkh' --subject-prefix 'PATCH
> > 6.12.y'
> > > > HEAD^..
> > > > >
> > > > > I cannot reproduce the failure with upper cmd.
> > > > > The patch could be applied successfully without conflict.
> > > > > Anyway, I follow the instructions re-send the patch.
> > > > > Let me know if it still has issue.
> > > >
> > > > Try building it after it is applied and notice how it breaks the
> > > > build :(
> > >
> > > I tried to do it, and it could build successfully.
> > > I checked the code and cannot find what will cause the build failure.
> > > Could you please share me the failure signature?
> >
> > CC [M] drivers/gpu/drm/xe/xe_sync.o
> > drivers/gpu/drm/xe/xe_sync.c: In function ‘xe_sync_entry_parse’:
> > drivers/gpu/drm/xe/xe_sync.c:182:33: error: label ‘free_sync’ used but not
> > defined
> > 182 | goto free_sync;
> > | ^~~~
>
> Thanks for the log.
> It seems the patch is not applied correctly and cause the build failure.
> For the original patch 1bfd75750924 ("drm/xe/sync: Cleanup partially initialized sync on parse failure"),
> all the change is within function xe_sync_entry_parse().
> This "free_sync" label is added at the end of xe_sync_entry_parse(), and some error path use goto to jump to this label.
>
> For this and below err, it seems the last part of this patch is applied to function xe_sync_entry_add_deps(), which is the function after xe_sync_entry_parse().
> The err should be due to "free_sync" label is added to function xe_sync_entry_add_deps() instead of xe_sync_entry_parse().
> Could you please help me confirm it?
It's best if you can send a properly backported patch for us to apply.
thanks,
greg k-h
^ permalink raw reply [flat|nested] 10+ messages in thread
* RE: FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree
2026-03-18 16:58 ` gregkh
@ 2026-03-18 17:20 ` Lin, Shuicheng
2026-03-19 9:48 ` gregkh
0 siblings, 1 reply; 10+ messages in thread
From: Lin, Shuicheng @ 2026-03-18 17:20 UTC (permalink / raw)
To: gregkh@linuxfoundation.org
Cc: Brost, Matthew, Vivi, Rodrigo, stable@vger.kernel.org
On Wed, Mar 18, 2026 9:59 AM greg k-h wrote:
> On Wed, Mar 18, 2026 at 04:26:44PM +0000, Lin, Shuicheng wrote:
> > On Wed, Mar 18, 2026 5:25 AM gregkh wrote:
> > > On Tue, Mar 17, 2026 at 05:10:53PM +0000, Lin, Shuicheng wrote:
> > > > On Tue, Mar 17, 2026 9:32 AM greg k-h wrote:
> > > > > On Tue, Mar 17, 2026 at 04:27:46PM +0000, Lin, Shuicheng wrote:
> > > > > > On Tue, Mar 17, 2026 4:48 AM gregkh wrote:
> > > > > > > The patch below does not apply to the 6.12-stable tree.
> > > > > > > If someone wants it applied there, or to any other stable or
> > > > > > > longterm tree, then please email the backport, including the
> > > > > > > original git commit id to <stable@vger.kernel.org>.
> > > > > > >
> > > > > > > To reproduce the conflict and resubmit, you may use the
> > > > > > > following
> > > > > commands:
> > > > > > >
> > > > > > > git fetch
> > > > > > > https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
> > > > > > > .git / linux-6.12.y git checkout FETCH_HEAD git cherry-pick
> > > > > > > -x
> > > > > > > 1bfd7575092420ba5a0b944953c95b74a5646ff8
> > > > > > > # <resolve conflicts, build, test, etc.> git commit -s git
> > > > > > > send-email --to '<stable@vger.kernel.org>' --in-reply-to
> > > > > > > '2026031732-size-unfasten- 2bf3@gregkh' --subject-prefix
> > > > > > > 'PATCH
> > > 6.12.y'
> > > > > HEAD^..
> > > > > >
> > > > > > I cannot reproduce the failure with upper cmd.
> > > > > > The patch could be applied successfully without conflict.
> > > > > > Anyway, I follow the instructions re-send the patch.
> > > > > > Let me know if it still has issue.
> > > > >
> > > > > Try building it after it is applied and notice how it breaks the
> > > > > build :(
> > > >
> > > > I tried to do it, and it could build successfully.
> > > > I checked the code and cannot find what will cause the build failure.
> > > > Could you please share me the failure signature?
> > >
> > > CC [M] drivers/gpu/drm/xe/xe_sync.o
> > > drivers/gpu/drm/xe/xe_sync.c: In function ‘xe_sync_entry_parse’:
> > > drivers/gpu/drm/xe/xe_sync.c:182:33: error: label ‘free_sync’ used
> > > but not defined
> > > 182 | goto free_sync;
> > > | ^~~~
> >
> > Thanks for the log.
> > It seems the patch is not applied correctly and cause the build failure.
> > For the original patch 1bfd75750924 ("drm/xe/sync: Cleanup partially
> > initialized sync on parse failure"), all the change is within function
> xe_sync_entry_parse().
> > This "free_sync" label is added at the end of xe_sync_entry_parse(), and
> some error path use goto to jump to this label.
> >
> > For this and below err, it seems the last part of this patch is applied to
> function xe_sync_entry_add_deps(), which is the function after
> xe_sync_entry_parse().
> > The err should be due to "free_sync" label is added to function
> xe_sync_entry_add_deps() instead of xe_sync_entry_parse().
> > Could you please help me confirm it?
>
> It's best if you can send a properly backported patch for us to apply.
Yes. I did re-send the patch yesterday following below cmd. The problem is that I cannot reproduce the failure.
"
git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.12.y
git checkout FETCH_HEAD
git cherry-pick -x 1bfd7575092420ba5a0b944953c95b74a5646ff8
git commit -s --amend
git send-email --to '<stable@vger.kernel.org>' --in-reply-to '2026031732-size-unfasten-2bf3@gregkh' --subject-prefix 'PATCH 6.12.y' HEAD^..
"
There is no conflict and I could pass build.
Not sure what is the difference and lead to the issue.
Could you please have a try again with the patch I sent yesterday?
Thanks.
Shuicheng
>
> thanks,
>
> greg k-h
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree
2026-03-18 17:20 ` Lin, Shuicheng
@ 2026-03-19 9:48 ` gregkh
0 siblings, 0 replies; 10+ messages in thread
From: gregkh @ 2026-03-19 9:48 UTC (permalink / raw)
To: Lin, Shuicheng; +Cc: Brost, Matthew, Vivi, Rodrigo, stable@vger.kernel.org
On Wed, Mar 18, 2026 at 05:20:05PM +0000, Lin, Shuicheng wrote:
> On Wed, Mar 18, 2026 9:59 AM greg k-h wrote:
> > On Wed, Mar 18, 2026 at 04:26:44PM +0000, Lin, Shuicheng wrote:
> > > On Wed, Mar 18, 2026 5:25 AM gregkh wrote:
> > > > On Tue, Mar 17, 2026 at 05:10:53PM +0000, Lin, Shuicheng wrote:
> > > > > On Tue, Mar 17, 2026 9:32 AM greg k-h wrote:
> > > > > > On Tue, Mar 17, 2026 at 04:27:46PM +0000, Lin, Shuicheng wrote:
> > > > > > > On Tue, Mar 17, 2026 4:48 AM gregkh wrote:
> > > > > > > > The patch below does not apply to the 6.12-stable tree.
> > > > > > > > If someone wants it applied there, or to any other stable or
> > > > > > > > longterm tree, then please email the backport, including the
> > > > > > > > original git commit id to <stable@vger.kernel.org>.
> > > > > > > >
> > > > > > > > To reproduce the conflict and resubmit, you may use the
> > > > > > > > following
> > > > > > commands:
> > > > > > > >
> > > > > > > > git fetch
> > > > > > > > https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux
> > > > > > > > .git / linux-6.12.y git checkout FETCH_HEAD git cherry-pick
> > > > > > > > -x
> > > > > > > > 1bfd7575092420ba5a0b944953c95b74a5646ff8
> > > > > > > > # <resolve conflicts, build, test, etc.> git commit -s git
> > > > > > > > send-email --to '<stable@vger.kernel.org>' --in-reply-to
> > > > > > > > '2026031732-size-unfasten- 2bf3@gregkh' --subject-prefix
> > > > > > > > 'PATCH
> > > > 6.12.y'
> > > > > > HEAD^..
> > > > > > >
> > > > > > > I cannot reproduce the failure with upper cmd.
> > > > > > > The patch could be applied successfully without conflict.
> > > > > > > Anyway, I follow the instructions re-send the patch.
> > > > > > > Let me know if it still has issue.
> > > > > >
> > > > > > Try building it after it is applied and notice how it breaks the
> > > > > > build :(
> > > > >
> > > > > I tried to do it, and it could build successfully.
> > > > > I checked the code and cannot find what will cause the build failure.
> > > > > Could you please share me the failure signature?
> > > >
> > > > CC [M] drivers/gpu/drm/xe/xe_sync.o
> > > > drivers/gpu/drm/xe/xe_sync.c: In function ‘xe_sync_entry_parse’:
> > > > drivers/gpu/drm/xe/xe_sync.c:182:33: error: label ‘free_sync’ used
> > > > but not defined
> > > > 182 | goto free_sync;
> > > > | ^~~~
> > >
> > > Thanks for the log.
> > > It seems the patch is not applied correctly and cause the build failure.
> > > For the original patch 1bfd75750924 ("drm/xe/sync: Cleanup partially
> > > initialized sync on parse failure"), all the change is within function
> > xe_sync_entry_parse().
> > > This "free_sync" label is added at the end of xe_sync_entry_parse(), and
> > some error path use goto to jump to this label.
> > >
> > > For this and below err, it seems the last part of this patch is applied to
> > function xe_sync_entry_add_deps(), which is the function after
> > xe_sync_entry_parse().
> > > The err should be due to "free_sync" label is added to function
> > xe_sync_entry_add_deps() instead of xe_sync_entry_parse().
> > > Could you please help me confirm it?
> >
> > It's best if you can send a properly backported patch for us to apply.
>
> Yes. I did re-send the patch yesterday following below cmd. The problem is that I cannot reproduce the failure.
> "
> git fetch https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/ linux-6.12.y
> git checkout FETCH_HEAD
> git cherry-pick -x 1bfd7575092420ba5a0b944953c95b74a5646ff8
> git commit -s --amend
> git send-email --to '<stable@vger.kernel.org>' --in-reply-to '2026031732-size-unfasten-2bf3@gregkh' --subject-prefix 'PATCH 6.12.y' HEAD^..
> "
> There is no conflict and I could pass build.
> Not sure what is the difference and lead to the issue.
> Could you please have a try again with the patch I sent yesterday?
Your patch applied properly, thanks.
greg k-h
^ permalink raw reply [flat|nested] 10+ messages in thread
end of thread, other threads:[~2026-03-19 9:48 UTC | newest]
Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-03-17 11:47 FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree gregkh
2026-03-17 16:22 ` [PATCH 6.12.y] drm/xe/sync: Cleanup partially initialized sync on parse failure Shuicheng Lin
2026-03-17 16:27 ` FAILED: patch "[PATCH] drm/xe/sync: Cleanup partially initialized sync on parse" failed to apply to 6.12-stable tree Lin, Shuicheng
2026-03-17 16:31 ` gregkh
2026-03-17 17:10 ` Lin, Shuicheng
2026-03-18 12:25 ` gregkh
2026-03-18 16:26 ` Lin, Shuicheng
2026-03-18 16:58 ` gregkh
2026-03-18 17:20 ` Lin, Shuicheng
2026-03-19 9:48 ` gregkh
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox