From 1ade6a4f7f09d5d6f6fc449e6bfa92b5e2d063c2 Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Mon, 22 Dec 2025 20:52:33 +0100 Subject: [PATCH 01/11] USB: core: Discard pm_runtime_put() return value To allow the return type of pm_runtime_put() to be changed to void in the future, modify usb_autopm_put_interface_async() to discard the return value of pm_runtime_put(). That value is merely used in a debug comment printed by the function in question and it is not a particularly useful piece of information because pm_runtime_put() does not guarantee that the device will be suspended even if it successfully queues up a work item to check whether or not the device can be suspended. Signed-off-by: Rafael J. Wysocki Acked-by: Alan Stern Acked-by: Greg Kroah-Hartman Link: https://patch.msgid.link/5058509.GXAFRqVoOG@rafael.j.wysocki --- drivers/usb/core/driver.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/drivers/usb/core/driver.c b/drivers/usb/core/driver.c index d29edc7c616a..2f5958bc4f7f 100644 --- a/drivers/usb/core/driver.c +++ b/drivers/usb/core/driver.c @@ -1810,13 +1810,11 @@ EXPORT_SYMBOL_GPL(usb_autopm_put_interface); void usb_autopm_put_interface_async(struct usb_interface *intf) { struct usb_device *udev = interface_to_usbdev(intf); - int status; usb_mark_last_busy(udev); - status = pm_runtime_put(&intf->dev); - dev_vdbg(&intf->dev, "%s: cnt %d -> %d\n", - __func__, atomic_read(&intf->dev.power.usage_count), - status); + pm_runtime_put(&intf->dev); + dev_vdbg(&intf->dev, "%s: cnt %d\n", + __func__, atomic_read(&intf->dev.power.usage_count)); } EXPORT_SYMBOL_GPL(usb_autopm_put_interface_async); From 88dcab0650fd31072ed07a0d26fce5bbbbd8e7a1 Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Mon, 22 Dec 2025 20:59:58 +0100 Subject: [PATCH 02/11] drm/imagination: Discard pm_runtime_put() return value The Imagination DRM driver defines pvr_power_put() to pass the return value of pm_runtime_put() to the caller, but then it never uses the return value of pvr_power_put(). Modify pvr_power_put() to discard the pm_runtime_put() return value and change its return type to void. No intentional functional impact. This will facilitate a planned change of the pm_runtime_put() return type to void in the future. Signed-off-by: Rafael J. Wysocki Reviewed-by: Matt Coster Link: https://patch.msgid.link/8642685.T7Z3S40VBb@rafael.j.wysocki --- drivers/gpu/drm/imagination/pvr_power.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/imagination/pvr_power.h b/drivers/gpu/drm/imagination/pvr_power.h index b853d092242c..c34252bda078 100644 --- a/drivers/gpu/drm/imagination/pvr_power.h +++ b/drivers/gpu/drm/imagination/pvr_power.h @@ -30,12 +30,12 @@ pvr_power_get(struct pvr_device *pvr_dev) return pm_runtime_resume_and_get(drm_dev->dev); } -static __always_inline int +static __always_inline void pvr_power_put(struct pvr_device *pvr_dev) { struct drm_device *drm_dev = from_pvr_device(pvr_dev); - return pm_runtime_put(drm_dev->dev); + pm_runtime_put(drm_dev->dev); } int pvr_power_domains_init(struct pvr_device *pvr_dev); From c9f7b0e6b903a68780684c30773e3b591b10deaa Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Mon, 22 Dec 2025 21:03:25 +0100 Subject: [PATCH 03/11] media: ccs: Discard pm_runtime_put() return value Passing the pm_runtime_put() return value to callers is not particularly useful. Returning an error code from pm_runtime_put() merely means that it has not queued up a work item to check whether or not the device can be suspended and there are many perfectly valid situations in which that can happen, like after writing "on" to the devices' runtime PM "control" attribute in sysfs for one example. It also happens when the kernel is configured with CONFIG_PM unset. Accordingly, update ccs_post_streamoff() to simply discard the return value of pm_runtime_put() and always return success to the caller. This will facilitate a planned change of the pm_runtime_put() return type to void in the future. Signed-off-by: Rafael J. Wysocki Acked-by: Sakari Ailus Link: https://patch.msgid.link/22966634.EfDdHjke4D@rafael.j.wysocki --- drivers/media/i2c/ccs/ccs-core.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/media/i2c/ccs/ccs-core.c b/drivers/media/i2c/ccs/ccs-core.c index f8523140784c..0d7b922fd4c4 100644 --- a/drivers/media/i2c/ccs/ccs-core.c +++ b/drivers/media/i2c/ccs/ccs-core.c @@ -1974,7 +1974,9 @@ static int ccs_post_streamoff(struct v4l2_subdev *subdev) struct ccs_sensor *sensor = to_ccs_sensor(subdev); struct i2c_client *client = v4l2_get_subdevdata(&sensor->src->sd); - return pm_runtime_put(&client->dev); + pm_runtime_put(&client->dev); + + return 0; } static int ccs_enum_mbus_code(struct v4l2_subdev *subdev, From f52defa7b830abbba6b26df503ca42c0b2f20abe Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Mon, 22 Dec 2025 21:07:46 +0100 Subject: [PATCH 04/11] watchdog: rz: Discard pm_runtime_put() return values Failing a watchdog stop due to pm_runtime_put() returning a negative value is not particularly useful. Returning an error code from pm_runtime_put() merely means that it has not queued up a work item to check whether or not the device can be suspended and there are many perfectly valid situations in which that can happen, like after writing "on" to the devices' runtime PM "control" attribute in sysfs for one example. It also happens when the kernel is configured with CONFIG_PM unset. Accordingly, update rzg2l_wdt_stop() and rzv2h_wdt_stop() to simply discard the return value of pm_runtime_put(). This will facilitate a planned change of the pm_runtime_put() return type to void in the future. Signed-off-by: Rafael J. Wysocki Reviewed-by: Guenter Roeck Link: https://patch.msgid.link/3340071.5fSG56mABF@rafael.j.wysocki --- drivers/watchdog/rzg2l_wdt.c | 4 +--- drivers/watchdog/rzv2h_wdt.c | 4 +--- 2 files changed, 2 insertions(+), 6 deletions(-) diff --git a/drivers/watchdog/rzg2l_wdt.c b/drivers/watchdog/rzg2l_wdt.c index 1c9aa366d0a0..509f9dffdacd 100644 --- a/drivers/watchdog/rzg2l_wdt.c +++ b/drivers/watchdog/rzg2l_wdt.c @@ -132,9 +132,7 @@ static int rzg2l_wdt_stop(struct watchdog_device *wdev) if (ret) return ret; - ret = pm_runtime_put(wdev->parent); - if (ret < 0) - return ret; + pm_runtime_put(wdev->parent); return 0; } diff --git a/drivers/watchdog/rzv2h_wdt.c b/drivers/watchdog/rzv2h_wdt.c index a694786837e1..f93647934db7 100644 --- a/drivers/watchdog/rzv2h_wdt.c +++ b/drivers/watchdog/rzv2h_wdt.c @@ -174,9 +174,7 @@ static int rzv2h_wdt_stop(struct watchdog_device *wdev) if (priv->of_data->wdtdcr) rzt2h_wdt_wdtdcr_count_stop(priv); - ret = pm_runtime_put(wdev->parent); - if (ret < 0) - return ret; + pm_runtime_put(wdev->parent); return 0; } From 7b8de72b4001a7e2071c69b6bcc95ac21ca01094 Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Mon, 22 Dec 2025 21:09:22 +0100 Subject: [PATCH 05/11] watchdog: rzv2h_wdt: Discard pm_runtime_put() return value Failing device probe due to pm_runtime_put() returning an error is not particularly useful. Returning an error code from pm_runtime_put() merely means that it has not queued up a work item to check whether or not the device can be suspended and there are many perfectly valid situations in which that can happen, like after writing "on" to the devices' runtime PM "control" attribute in sysfs for one example. It also happens when the kernel is configured with CONFIG_PM unset. Accordingly, update rzt2h_wdt_wdtdcr_init() to simply discard the return value of pm_runtime_put() and return success to the caller after invoking that function. This will facilitate a planned change of the pm_runtime_put() return type to void in the future. Signed-off-by: Rafael J. Wysocki Reviewed-by: Guenter Roeck Link: https://patch.msgid.link/1867890.VLH7GnMWUR@rafael.j.wysocki --- drivers/watchdog/rzv2h_wdt.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/watchdog/rzv2h_wdt.c b/drivers/watchdog/rzv2h_wdt.c index f93647934db7..3b6abb66a1da 100644 --- a/drivers/watchdog/rzv2h_wdt.c +++ b/drivers/watchdog/rzv2h_wdt.c @@ -268,9 +268,7 @@ static int rzt2h_wdt_wdtdcr_init(struct platform_device *pdev, rzt2h_wdt_wdtdcr_count_stop(priv); - ret = pm_runtime_put(&pdev->dev); - if (ret < 0) - return ret; + pm_runtime_put(&pdev->dev); return 0; } From d33976be6cecfe340a52b365ecf706a0c55d543d Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Mon, 22 Dec 2025 21:24:19 +0100 Subject: [PATCH 06/11] hwspinlock: omap: Discard pm_runtime_put() return value Failing driver probe due to pm_runtime_put() returning a negative value is not particularly useful. Returning an error code from pm_runtime_put() merely means that it has not queued up a work item to check whether or not the device can be suspended and there are many perfectly valid situations in which that can happen, like after writing "on" to the devices' runtime PM "control" attribute in sysfs for one example. It also happens when the kernel has been configured with CONFIG_PM unset. Accordingly, update omap_hwspinlock_probe() to simply discard the return value of pm_runtime_put(). This will facilitate a planned change of the pm_runtime_put() return type to void in the future. Signed-off-by: Rafael J. Wysocki Acked-by: Bjorn Andersson Link: https://patch.msgid.link/883243465.0ifERbkFSE@rafael.j.wysocki --- drivers/hwspinlock/omap_hwspinlock.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/hwspinlock/omap_hwspinlock.c b/drivers/hwspinlock/omap_hwspinlock.c index 27b47b8623c0..3a9a5678737b 100644 --- a/drivers/hwspinlock/omap_hwspinlock.c +++ b/drivers/hwspinlock/omap_hwspinlock.c @@ -101,9 +101,7 @@ static int omap_hwspinlock_probe(struct platform_device *pdev) * runtime PM will make sure the clock of this module is * enabled again iff at least one lock is requested */ - ret = pm_runtime_put(&pdev->dev); - if (ret < 0) - return ret; + pm_runtime_put(&pdev->dev); /* one of the four lsb's must be set, and nothing else */ if (hweight_long(i & 0xf) != 1 || i > 8) From 01eafccacc707da2db2a9eb4be56c9367e42323f Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Mon, 22 Dec 2025 21:25:57 +0100 Subject: [PATCH 07/11] coresight: Discard pm_runtime_put() return values Failing a debugfs write due to pm_runtime_put() returning a negative value is not particularly useful. Returning an error code from pm_runtime_put() merely means that it has not queued up a work item to check whether or not the device can be suspended and there are many perfectly valid situations in which that can happen, like after writing "on" to the devices' runtime PM "control" attribute in sysfs for one example. It also happens when the kernel has been configured with CONFIG_PM unset, in which case debug_disable_func() in the coresight driver will always return an error. For this reason, update debug_disable_func() to simply discard the return value of pm_runtime_put(), change its return type to void, and propagate that change to debug_func_knob_write(). This will facilitate a planned change of the pm_runtime_put() return type to void in the future. Signed-off-by: Rafael J. Wysocki Acked-by: Suzuki K Poulose Link: https://patch.msgid.link/2058657.yKVeVyVuyW@rafael.j.wysocki --- drivers/hwtracing/coresight/coresight-cpu-debug.c | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/drivers/hwtracing/coresight/coresight-cpu-debug.c b/drivers/hwtracing/coresight/coresight-cpu-debug.c index 5f21366406aa..629614278e46 100644 --- a/drivers/hwtracing/coresight/coresight-cpu-debug.c +++ b/drivers/hwtracing/coresight/coresight-cpu-debug.c @@ -451,10 +451,10 @@ err: return ret; } -static int debug_disable_func(void) +static void debug_disable_func(void) { struct debug_drvdata *drvdata; - int cpu, ret, err = 0; + int cpu; /* * Disable debug power domains, records the error and keep @@ -466,12 +466,8 @@ static int debug_disable_func(void) if (!drvdata) continue; - ret = pm_runtime_put(drvdata->dev); - if (ret < 0) - err = ret; + pm_runtime_put(drvdata->dev); } - - return err; } static ssize_t debug_func_knob_write(struct file *f, @@ -492,7 +488,7 @@ static ssize_t debug_func_knob_write(struct file *f, if (val) ret = debug_enable_func(); else - ret = debug_disable_func(); + debug_disable_func(); if (ret) { pr_err("%s: unable to %s debug function: %d\n", From 6401e43479a809b7a5a930d76c363f4b5705ed00 Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Mon, 22 Dec 2025 21:27:44 +0100 Subject: [PATCH 08/11] platform/chrome: cros_hps_i2c: Discard pm_runtime_put() return value Passing pm_runtime_put() return value to the callers is not particularly useful. Returning an error code from pm_runtime_put() merely means that it has not queued up a work item to check whether or not the device can be suspended and there are many perfectly valid situations in which that can happen, like after writing "on" to the devices' runtime PM "control" attribute in sysfs for one example. It also happens when the kernel is configured with CONFIG_PM unset. Accordingly, update hps_release() to simply discard the return value of pm_runtime_put() and always return success to the caller. This will facilitate a planned change of the pm_runtime_put() return type to void in the future. Signed-off-by: Rafael J. Wysocki Acked-by: Tzung-Bi Shih Link: https://patch.msgid.link/2302270.NgBsaNRSFp@rafael.j.wysocki --- drivers/platform/chrome/cros_hps_i2c.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/drivers/platform/chrome/cros_hps_i2c.c b/drivers/platform/chrome/cros_hps_i2c.c index 6b479cfe3f73..ac6498c593e3 100644 --- a/drivers/platform/chrome/cros_hps_i2c.c +++ b/drivers/platform/chrome/cros_hps_i2c.c @@ -46,7 +46,9 @@ static int hps_release(struct inode *inode, struct file *file) struct hps_drvdata, misc_device); struct device *dev = &hps->client->dev; - return pm_runtime_put(dev); + pm_runtime_put(dev); + + return 0; } static const struct file_operations hps_fops = { From bf91b35a46ceef08a1e64c54b0e611fcae531e7a Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Mon, 22 Dec 2025 21:31:45 +0100 Subject: [PATCH 09/11] scsi: ufs: core: Discard pm_runtime_put() return values The ufshcd driver defines ufshcd_rpm_put() to return an int, but that return value is never used. It also passes the return value of pm_runtime_put() to the caller which is not very useful. Returning an error code from pm_runtime_put() merely means that it has not queued up a work item to check whether or not the device can be suspended and there are many perfectly valid situations in which that can happen, like after writing "on" to the devices' runtime PM "control" attribute in sysfs for one example. Modify ufshcd_rpm_put() to discard the pm_runtime_put() return value and change its return type to void. No intentional functional impact. This will facilitate a planned change of the pm_runtime_put() return type to void in the future. Signed-off-by: Rafael J. Wysocki Reviewed-by: Bart Van Assche Reviewed-by: Martin K. Petersen Link: https://patch.msgid.link/2781685.BddDVKsqQX@rafael.j.wysocki --- drivers/ufs/core/ufshcd-priv.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/ufs/core/ufshcd-priv.h b/drivers/ufs/core/ufshcd-priv.h index 4259f499382f..27b18b0cc058 100644 --- a/drivers/ufs/core/ufshcd-priv.h +++ b/drivers/ufs/core/ufshcd-priv.h @@ -348,9 +348,9 @@ static inline int ufshcd_rpm_resume(struct ufs_hba *hba) return pm_runtime_resume(&hba->ufs_device_wlun->sdev_gendev); } -static inline int ufshcd_rpm_put(struct ufs_hba *hba) +static inline void ufshcd_rpm_put(struct ufs_hba *hba) { - return pm_runtime_put(&hba->ufs_device_wlun->sdev_gendev); + pm_runtime_put(&hba->ufs_device_wlun->sdev_gendev); } /** From e9df6eba060c6db2f7f3fd8666d1af0a369d6f7b Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Thu, 8 Jan 2026 16:05:37 +0100 Subject: [PATCH 10/11] genirq/chip: Change irq_chip_pm_put() return type to void The irq_chip_pm_put() return value is only used in __irq_do_set_handler() to trigger a WARN_ON() if it is negative, but doing so is not useful because irq_chip_pm_put() simply passes the pm_runtime_put() return value to its callers. Returning an error code from pm_runtime_put() merely means that it has not queued up a work item to check whether or not the device can be suspended and there are many perfectly valid situations in which that can happen, like after writing "on" to the devices' runtime PM "control" attribute in sysfs for one example. For this reason, modify irq_chip_pm_put() to discard the pm_runtime_put() return value, change its return type to void, and drop the WARN_ON() around the irq_chip_pm_put() invocation from __irq_do_set_handler(). Also update the irq_chip_pm_put() kerneldoc comment to be more accurate. This will facilitate a planned change of the pm_runtime_put() return type to void in the future. Signed-off-by: Rafael J. Wysocki Reviewed-by: Thomas Gleixner Link: https://patch.msgid.link/5075294.31r3eYUQgx@rafael.j.wysocki --- include/linux/irq.h | 2 +- kernel/irq/chip.c | 22 +++++++++++----------- 2 files changed, 12 insertions(+), 12 deletions(-) diff --git a/include/linux/irq.h b/include/linux/irq.h index 4a9f1d7b08c3..ef0816fdc6f2 100644 --- a/include/linux/irq.h +++ b/include/linux/irq.h @@ -658,7 +658,7 @@ extern void handle_fasteoi_nmi(struct irq_desc *desc); extern int irq_chip_compose_msi_msg(struct irq_data *data, struct msi_msg *msg); extern int irq_chip_pm_get(struct irq_data *data); -extern int irq_chip_pm_put(struct irq_data *data); +extern void irq_chip_pm_put(struct irq_data *data); #ifdef CONFIG_IRQ_DOMAIN_HIERARCHY extern void handle_fasteoi_ack_irq(struct irq_desc *desc); extern void handle_fasteoi_mask_irq(struct irq_desc *desc); diff --git a/kernel/irq/chip.c b/kernel/irq/chip.c index 678f094d261a..23f22f3d5207 100644 --- a/kernel/irq/chip.c +++ b/kernel/irq/chip.c @@ -974,7 +974,7 @@ __irq_do_set_handler(struct irq_desc *desc, irq_flow_handler_t handle, irq_state_set_disabled(desc); if (is_chained) { desc->action = NULL; - WARN_ON(irq_chip_pm_put(irq_desc_get_irq_data(desc))); + irq_chip_pm_put(irq_desc_get_irq_data(desc)); } desc->depth = 1; } @@ -1530,20 +1530,20 @@ int irq_chip_pm_get(struct irq_data *data) } /** - * irq_chip_pm_put - Disable power for an IRQ chip + * irq_chip_pm_put - Drop a PM reference on an IRQ chip * @data: Pointer to interrupt specific data * - * Disable the power to the IRQ chip referenced by the interrupt data - * structure, belongs. Note that power will only be disabled, once this - * function has been called for all IRQs that have called irq_chip_pm_get(). + * Drop a power management reference, acquired via irq_chip_pm_get(), on the IRQ + * chip represented by the interrupt data structure. + * + * Note that this will not disable power to the IRQ chip until this function + * has been called for all IRQs that have called irq_chip_pm_get() and it may + * not disable power at all (if user space prevents that, for example). */ -int irq_chip_pm_put(struct irq_data *data) +void irq_chip_pm_put(struct irq_data *data) { struct device *dev = irq_get_pm_device(data); - int retval = 0; - if (IS_ENABLED(CONFIG_PM) && dev) - retval = pm_runtime_put(dev); - - return (retval < 0) ? retval : 0; + if (dev) + pm_runtime_put(dev); } From 75e8635832a2e45d2a910c247eddd6b65d5ce6e1 Mon Sep 17 00:00:00 2001 From: "Rafael J. Wysocki" Date: Thu, 8 Jan 2026 16:17:17 +0100 Subject: [PATCH 11/11] drm: Discard pm_runtime_put() return value Multiple DRM drivers use the pm_runtime_put() return value for printing debug or even error messages and all of those messages are at least somewhat misleading. Returning an error code from pm_runtime_put() merely means that it has not queued up a work item to check whether or not the device can be suspended and there are many perfectly valid situations in which that can happen, like after writing "on" to the devices' runtime PM "control" attribute in sysfs for one example. It also happens when the kernel has been configured with CONFIG_PM unset. For this reason, modify all of those drivers to simply discard the pm_runtime_put() return value which is what they should be doing. This will facilitate a planned change of the pm_runtime_put() return type to void in the future. Signed-off-by: Rafael J. Wysocki Acked-by: Dave Stevenson Acked-by: Liviu Dudau Link: https://patch.msgid.link/2256082.irdbgypaU6@rafael.j.wysocki --- drivers/gpu/drm/arm/malidp_crtc.c | 6 +----- drivers/gpu/drm/bridge/imx/imx8qm-ldb.c | 4 +--- drivers/gpu/drm/bridge/imx/imx8qxp-ldb.c | 4 +--- drivers/gpu/drm/bridge/imx/imx8qxp-pixel-combiner.c | 5 +---- drivers/gpu/drm/bridge/imx/imx8qxp-pxl2dpi.c | 5 +---- drivers/gpu/drm/imx/dc/dc-crtc.c | 12 +++--------- drivers/gpu/drm/vc4/vc4_hdmi.c | 5 +---- drivers/gpu/drm/vc4/vc4_vec.c | 12 ++---------- 8 files changed, 11 insertions(+), 42 deletions(-) diff --git a/drivers/gpu/drm/arm/malidp_crtc.c b/drivers/gpu/drm/arm/malidp_crtc.c index d72c22dcf685..e61cf362abdf 100644 --- a/drivers/gpu/drm/arm/malidp_crtc.c +++ b/drivers/gpu/drm/arm/malidp_crtc.c @@ -77,7 +77,6 @@ static void malidp_crtc_atomic_disable(struct drm_crtc *crtc, crtc); struct malidp_drm *malidp = crtc_to_malidp_device(crtc); struct malidp_hw_device *hwdev = malidp->dev; - int err; /* always disable planes on the CRTC that is being turned off */ drm_atomic_helper_disable_planes_on_crtc(old_state, false); @@ -87,10 +86,7 @@ static void malidp_crtc_atomic_disable(struct drm_crtc *crtc, clk_disable_unprepare(hwdev->pxlclk); - err = pm_runtime_put(crtc->dev->dev); - if (err < 0) { - DRM_DEBUG_DRIVER("Failed to disable runtime power management: %d\n", err); - } + pm_runtime_put(crtc->dev->dev); } static const struct gamma_curve_segment { diff --git a/drivers/gpu/drm/bridge/imx/imx8qm-ldb.c b/drivers/gpu/drm/bridge/imx/imx8qm-ldb.c index 47aa65938e6a..fc67e7ed653d 100644 --- a/drivers/gpu/drm/bridge/imx/imx8qm-ldb.c +++ b/drivers/gpu/drm/bridge/imx/imx8qm-ldb.c @@ -280,9 +280,7 @@ static void imx8qm_ldb_bridge_atomic_disable(struct drm_bridge *bridge, clk_disable_unprepare(imx8qm_ldb->clk_bypass); clk_disable_unprepare(imx8qm_ldb->clk_pixel); - ret = pm_runtime_put(dev); - if (ret < 0) - DRM_DEV_ERROR(dev, "failed to put runtime PM: %d\n", ret); + pm_runtime_put(dev); } static const u32 imx8qm_ldb_bus_output_fmts[] = { diff --git a/drivers/gpu/drm/bridge/imx/imx8qxp-ldb.c b/drivers/gpu/drm/bridge/imx/imx8qxp-ldb.c index 122502968927..d70f3c9b3925 100644 --- a/drivers/gpu/drm/bridge/imx/imx8qxp-ldb.c +++ b/drivers/gpu/drm/bridge/imx/imx8qxp-ldb.c @@ -282,9 +282,7 @@ static void imx8qxp_ldb_bridge_atomic_disable(struct drm_bridge *bridge, if (is_split && companion) companion->funcs->atomic_disable(companion, state); - ret = pm_runtime_put(dev); - if (ret < 0) - DRM_DEV_ERROR(dev, "failed to put runtime PM: %d\n", ret); + pm_runtime_put(dev); } static const u32 imx8qxp_ldb_bus_output_fmts[] = { diff --git a/drivers/gpu/drm/bridge/imx/imx8qxp-pixel-combiner.c b/drivers/gpu/drm/bridge/imx/imx8qxp-pixel-combiner.c index 8517b1c953d4..8e64b5404561 100644 --- a/drivers/gpu/drm/bridge/imx/imx8qxp-pixel-combiner.c +++ b/drivers/gpu/drm/bridge/imx/imx8qxp-pixel-combiner.c @@ -181,11 +181,8 @@ static void imx8qxp_pc_bridge_atomic_disable(struct drm_bridge *bridge, { struct imx8qxp_pc_channel *ch = bridge->driver_private; struct imx8qxp_pc *pc = ch->pc; - int ret; - ret = pm_runtime_put(pc->dev); - if (ret < 0) - DRM_DEV_ERROR(pc->dev, "failed to put runtime PM: %d\n", ret); + pm_runtime_put(pc->dev); } static const u32 imx8qxp_pc_bus_output_fmts[] = { diff --git a/drivers/gpu/drm/bridge/imx/imx8qxp-pxl2dpi.c b/drivers/gpu/drm/bridge/imx/imx8qxp-pxl2dpi.c index 111310acab2c..82a2bba375ad 100644 --- a/drivers/gpu/drm/bridge/imx/imx8qxp-pxl2dpi.c +++ b/drivers/gpu/drm/bridge/imx/imx8qxp-pxl2dpi.c @@ -127,11 +127,8 @@ static void imx8qxp_pxl2dpi_bridge_atomic_disable(struct drm_bridge *bridge, struct drm_atomic_state *state) { struct imx8qxp_pxl2dpi *p2d = bridge->driver_private; - int ret; - ret = pm_runtime_put(p2d->dev); - if (ret < 0) - DRM_DEV_ERROR(p2d->dev, "failed to put runtime PM: %d\n", ret); + pm_runtime_put(p2d->dev); if (p2d->companion) p2d->companion->funcs->atomic_disable(p2d->companion, state); diff --git a/drivers/gpu/drm/imx/dc/dc-crtc.c b/drivers/gpu/drm/imx/dc/dc-crtc.c index 31d3a982deaf..608c610662dc 100644 --- a/drivers/gpu/drm/imx/dc/dc-crtc.c +++ b/drivers/gpu/drm/imx/dc/dc-crtc.c @@ -300,7 +300,7 @@ dc_crtc_atomic_disable(struct drm_crtc *crtc, struct drm_atomic_state *state) drm_atomic_get_new_crtc_state(state, crtc); struct dc_drm_device *dc_drm = to_dc_drm_device(crtc->dev); struct dc_crtc *dc_crtc = to_dc_crtc(crtc); - int idx, ret; + int idx; if (!drm_dev_enter(crtc->dev, &idx)) goto out; @@ -313,16 +313,10 @@ dc_crtc_atomic_disable(struct drm_crtc *crtc, struct drm_atomic_state *state) dc_fg_disable_clock(dc_crtc->fg); /* request pixel engine power-off as plane is off too */ - ret = pm_runtime_put(dc_drm->pe->dev); - if (ret) - dc_crtc_err(crtc, "failed to put DC pixel engine RPM: %d\n", - ret); + pm_runtime_put(dc_drm->pe->dev); /* request display engine power-off when CRTC is disabled */ - ret = pm_runtime_put(dc_crtc->de->dev); - if (ret < 0) - dc_crtc_err(crtc, "failed to put DC display engine RPM: %d\n", - ret); + pm_runtime_put(dc_crtc->de->dev); drm_dev_exit(idx); diff --git a/drivers/gpu/drm/vc4/vc4_hdmi.c b/drivers/gpu/drm/vc4/vc4_hdmi.c index 1798d1156d10..4504e38ce844 100644 --- a/drivers/gpu/drm/vc4/vc4_hdmi.c +++ b/drivers/gpu/drm/vc4/vc4_hdmi.c @@ -848,7 +848,6 @@ static void vc4_hdmi_encoder_post_crtc_powerdown(struct drm_encoder *encoder, struct vc4_hdmi *vc4_hdmi = encoder_to_vc4_hdmi(encoder); struct drm_device *drm = vc4_hdmi->connector.dev; unsigned long flags; - int ret; int idx; mutex_lock(&vc4_hdmi->mutex); @@ -867,9 +866,7 @@ static void vc4_hdmi_encoder_post_crtc_powerdown(struct drm_encoder *encoder, clk_disable_unprepare(vc4_hdmi->pixel_bvb_clock); clk_disable_unprepare(vc4_hdmi->pixel_clock); - ret = pm_runtime_put(&vc4_hdmi->pdev->dev); - if (ret < 0) - drm_err(drm, "Failed to release power domain: %d\n", ret); + pm_runtime_put(&vc4_hdmi->pdev->dev); drm_dev_exit(idx); diff --git a/drivers/gpu/drm/vc4/vc4_vec.c b/drivers/gpu/drm/vc4/vc4_vec.c index b84fad2a5b23..b0b271d93b27 100644 --- a/drivers/gpu/drm/vc4/vc4_vec.c +++ b/drivers/gpu/drm/vc4/vc4_vec.c @@ -542,7 +542,7 @@ static void vc4_vec_encoder_disable(struct drm_encoder *encoder, { struct drm_device *drm = encoder->dev; struct vc4_vec *vec = encoder_to_vc4_vec(encoder); - int idx, ret; + int idx; if (!drm_dev_enter(drm, &idx)) return; @@ -556,17 +556,9 @@ static void vc4_vec_encoder_disable(struct drm_encoder *encoder, clk_disable_unprepare(vec->clock); - ret = pm_runtime_put(&vec->pdev->dev); - if (ret < 0) { - drm_err(drm, "Failed to release power domain: %d\n", ret); - goto err_dev_exit; - } + pm_runtime_put(&vec->pdev->dev); drm_dev_exit(idx); - return; - -err_dev_exit: - drm_dev_exit(idx); } static void vc4_vec_encoder_enable(struct drm_encoder *encoder,