summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/radeon/radeon_irq_kms.c
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2012-09-17 14:40:31 +1000
committerAlex Deucher <alexander.deucher@amd.com>2013-11-01 12:43:14 -0400
commit10ebc0bc09344ab6310309169efc73dfe6c23d72 (patch)
tree9d93730a567190aa7b57d91999565273bc002dc0 /drivers/gpu/drm/radeon/radeon_irq_kms.c
parent7473e830c400b2ebf54937a4f075279f7713a2b7 (diff)
downloadtalos-obmc-linux-10ebc0bc09344ab6310309169efc73dfe6c23d72.tar.gz
talos-obmc-linux-10ebc0bc09344ab6310309169efc73dfe6c23d72.zip
drm/radeon: add runtime PM support (v2)
This hooks radeon up to the runtime PM system to enable dynamic power management for secondary GPUs in switchable and powerxpress laptops. v2: agd5f: clean up, add module parameter Signed-off-by: Dave Airlie <airlied@redhat.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/radeon/radeon_irq_kms.c')
-rw-r--r--drivers/gpu/drm/radeon/radeon_irq_kms.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_irq_kms.c b/drivers/gpu/drm/radeon/radeon_irq_kms.c
index cc9e8482cf30..ec6240b00469 100644
--- a/drivers/gpu/drm/radeon/radeon_irq_kms.c
+++ b/drivers/gpu/drm/radeon/radeon_irq_kms.c
@@ -32,6 +32,8 @@
#include "radeon.h"
#include "atom.h"
+#include <linux/pm_runtime.h>
+
#define RADEON_WAIT_IDLE_TIMEOUT 200
/**
@@ -47,8 +49,12 @@ irqreturn_t radeon_driver_irq_handler_kms(DRM_IRQ_ARGS)
{
struct drm_device *dev = (struct drm_device *) arg;
struct radeon_device *rdev = dev->dev_private;
+ irqreturn_t ret;
- return radeon_irq_process(rdev);
+ ret = radeon_irq_process(rdev);
+ if (ret == IRQ_HANDLED)
+ pm_runtime_mark_last_busy(dev->dev);
+ return ret;
}
/*
OpenPOWER on IntegriCloud