PKGBUILDs/core/linux-gru/0002-Revert-CHROMIUM-drm-rockchip-Add-PSR-residency-debug.patch

90 lines
2.8 KiB
Diff
Raw Normal View History

2017-10-20 01:05:08 +00:00
From 7d6e59980fd7ce4e0c2b878e5e9436b49c89c005 Mon Sep 17 00:00:00 2001
2017-04-07 00:53:47 +00:00
From: Kevin Mihelich <kevin@archlinuxarm.org>
Date: Wed, 5 Apr 2017 22:55:05 -0600
2017-10-20 01:05:08 +00:00
Subject: [PATCH 2/3] Revert "CHROMIUM: drm: rockchip: Add PSR residency debug
2017-04-07 00:53:47 +00:00
entry"
This reverts commit 9f416401b95d3f1dee2ffb12e0e27339fce3ce1b.
---
drivers/gpu/drm/rockchip/analogix_dp-rockchip.c | 21 +--------------------
1 file changed, 1 insertion(+), 20 deletions(-)
diff --git a/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c b/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c
2017-09-11 00:54:05 +00:00
index 9e953ee0d003..8d52abeb3f0b 100644
2017-04-07 00:53:47 +00:00
--- a/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c
+++ b/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c
@@ -13,7 +13,6 @@
*/
#include <linux/component.h>
-#include <linux/debugfs.h>
#include <linux/mfd/syscon.h>
#include <linux/of_device.h>
#include <linux/of_graph.h>
@@ -68,17 +67,12 @@ struct rockchip_dp_device {
struct analogix_dp_device *adp;
struct analogix_dp_plat_data plat_data;
-
- struct dentry *debugfs_psr;
- u64 psr_active_ms;
- ktime_t psr_start_time;
};
static int analogix_dp_psr_set(struct drm_encoder *encoder, bool enabled)
{
struct rockchip_dp_device *dp = to_dp(encoder);
struct drm_crtc *crtc = dp->encoder.crtc;
- s64 delta_ms;
int ret;
2017-09-11 00:54:05 +00:00
dev_dbg(dp->dev, "%s PSR...\n", enabled ? "enable" : "disable");
@@ -100,7 +94,6 @@ static int analogix_dp_psr_set(struct drm_encoder *encoder, bool enabled)
2017-04-07 00:53:47 +00:00
return ret;
}
rockchip_drm_set_win_enabled(crtc, false);
- dp->psr_start_time = ktime_get();
} else {
rockchip_drm_set_win_enabled(crtc, true);
ret = analogix_dp_disable_psr(dp->adp);
2017-09-11 00:54:05 +00:00
@@ -108,9 +101,6 @@ static int analogix_dp_psr_set(struct drm_encoder *encoder, bool enabled)
2017-04-07 00:53:47 +00:00
dev_err(dp->dev, "failed to disable psr %d\n", ret);
return ret;
}
- delta_ms = ktime_ms_delta(ktime_get(), dp->psr_start_time);
- if (!WARN_ON(delta_ms < 0))
- dp->psr_active_ms += delta_ms;
}
return 0;
}
2017-09-11 00:54:05 +00:00
@@ -394,17 +384,9 @@ static int rockchip_dp_bind(struct device *dev, struct device *master,
2017-04-07 00:53:47 +00:00
dp->plat_data.power_off = rockchip_dp_powerdown;
dp->plat_data.get_modes = rockchip_dp_get_modes;
- dp->debugfs_psr = debugfs_create_u64("psr_active_ms", S_IRUGO,
- drm_dev->primary->debugfs_root,
- &dp->psr_active_ms);
- if (IS_ERR(dp->debugfs_psr))
- return PTR_ERR(dp->debugfs_psr);
-
dp->adp = analogix_dp_bind(dev, dp->drm_dev, &dp->plat_data);
- if (IS_ERR(dp->adp)) {
- debugfs_remove(dp->debugfs_psr);
+ if (IS_ERR(dp->adp))
return PTR_ERR(dp->adp);
- }
rockchip_drm_psr_register(&dp->encoder, analogix_dp_psr_set);
2017-09-11 00:54:05 +00:00
@@ -419,7 +401,6 @@ static void rockchip_dp_unbind(struct device *dev, struct device *master,
2017-04-07 00:53:47 +00:00
rockchip_drm_psr_unregister(&dp->encoder);
analogix_dp_unbind(dp->adp);
- debugfs_remove(dp->debugfs_psr);
dp->adp = ERR_PTR(-ENODEV);
}
--
2017-10-20 01:05:08 +00:00
2.14.2
2017-04-07 00:53:47 +00:00