Skip to contentSkip to conversation

FAILED: patch "[PATCH] drm/msm: fix missing wq allocation error handling" failed to apply to 5.4-stable tree

PATCH [email protected] 1 participant 1 message May 13, 2023

Subsystems (3)
lore
Share & tools
lore

[email protected]

author maintainer
#0 lore raw

The patch below does not apply to the 5.4-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 <[email protected]>.

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-5.4.y
git checkout FETCH_HEAD
git cherry-pick -x ca090c837b430752038b24e56dd182010d77f6f6
# <resolve conflicts, build, test, etc.>
git commit -s
git send-email --to '<[email protected]>' --in-reply-to '2023051305-bronzing-output-dbca@gregkh' --subject-prefix 'PATCH 5.4.y' HEAD^..

Possible dependencies:

ca090c837b43 ("drm/msm: fix missing wq allocation error handling") dfa70344d1b5 ("Revert "drm/msm: Add missing check and destroy for alloc_ordered_workqueue"") 643b7d0869cc ("drm/msm: Add missing check and destroy for alloc_ordered_workqueue") 2027e5b3413d ("drm/msm: Initialize MDSS irq domain at probe time") ec919e6e7146 ("drm/msm: Allocate msm_drm_private early and pass it as driver data") 83b965d118cb ("Merge remote-tracking branch 'drm/drm-next' into msm-next-staging")

thanks,

greg k-h

------------------ original commit in Linus's tree ------------------

From ca090c837b430752038b24e56dd182010d77f6f6 Mon Sep 17 00:00:00 2001
From: Johan Hovold <[email protected]>
Date: Mon, 6 Mar 2023 11:07:19 +0100
Subject: [PATCH] drm/msm: fix missing wq allocation error handling

Add the missing sanity check to handle workqueue allocation failures.

Fixes c8afe684c95c ("drm/msm: basic KMS driver for snapdragon")
Cc Rob Clark <[email protected]>

Patchwork: https://patchwork.freedesktop.org/patch/525102/

drivers/gpu/drm/msm/msm_drv.c +4 -0
index 4d85ca0ba0c1..2a9a363afe50 100644
@@ -433,6 +433,10 @@ static int msm_drm_init(struct device *dev, const struct drm_driver *drv)
 	priv->dev = ddev;
 
 	priv->wq = alloc_ordered_workqueue("msm", 0);
+	if (!priv->wq) {
+		ret = -ENOMEM;
+		goto err_put_dev;
+	}
 
 	INIT_LIST_HEAD(&priv->objects);
 	mutex_init(&priv->obj_lock);