summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/include/cgs_linux.h
diff options
context:
space:
mode:
authorAlex Deucher <alexander.deucher@amd.com>2016-03-29 18:28:50 -0400
committerAlex Deucher <alexander.deucher@amd.com>2017-03-29 23:53:37 -0400
commitd766e6a393383c60a55bdcc72586f21a1ff12509 (patch)
tree2850bdf21e89a7bd48c8d08cd7ff6463ad955214 /drivers/gpu/drm/amd/include/cgs_linux.h
parent832be4041d4999e008839d12d1efe118da27bd99 (diff)
downloadlinux-d766e6a393383c60a55bdcc72586f21a1ff12509.tar.bz2
drm/amdgpu: switch ih handling to two levels (v3)
Newer asics have a two levels of irq ids now: client id - the IP src id - the interrupt src within the IP v2: integrated Christian's comments. v3: fix rebase fail in SI and CIK Signed-off-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Ken Wang <Qingqing.Wang@amd.com> Reviewed-by: Ken Wang <Qingqing.Wang@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/include/cgs_linux.h')
-rw-r--r--drivers/gpu/drm/amd/include/cgs_linux.h19
1 files changed, 10 insertions, 9 deletions
diff --git a/drivers/gpu/drm/amd/include/cgs_linux.h b/drivers/gpu/drm/amd/include/cgs_linux.h
index ca4f6007a9b3..bc7446c1d22e 100644
--- a/drivers/gpu/drm/amd/include/cgs_linux.h
+++ b/drivers/gpu/drm/amd/include/cgs_linux.h
@@ -66,7 +66,8 @@ typedef int (*cgs_irq_handler_func_t)(void *private_data,
*
* Return: 0 on success, -errno otherwise
*/
-typedef int (*cgs_add_irq_source_t)(struct cgs_device *cgs_device, unsigned src_id,
+typedef int (*cgs_add_irq_source_t)(void *cgs_device, unsigned client_id,
+ unsigned src_id,
unsigned num_types,
cgs_irq_source_set_func_t set,
cgs_irq_handler_func_t handler,
@@ -83,7 +84,7 @@ typedef int (*cgs_add_irq_source_t)(struct cgs_device *cgs_device, unsigned src_
*
* Return: 0 on success, -errno otherwise
*/
-typedef int (*cgs_irq_get_t)(struct cgs_device *cgs_device, unsigned src_id, unsigned type);
+typedef int (*cgs_irq_get_t)(void *cgs_device, unsigned client_id, unsigned src_id, unsigned type);
/**
* cgs_irq_put() - Indicate IRQ source is no longer needed
@@ -98,7 +99,7 @@ typedef int (*cgs_irq_get_t)(struct cgs_device *cgs_device, unsigned src_id, uns
*
* Return: 0 on success, -errno otherwise
*/
-typedef int (*cgs_irq_put_t)(struct cgs_device *cgs_device, unsigned src_id, unsigned type);
+typedef int (*cgs_irq_put_t)(void *cgs_device, unsigned client_id, unsigned src_id, unsigned type);
struct cgs_os_ops {
/* IRQ handling */
@@ -107,12 +108,12 @@ struct cgs_os_ops {
cgs_irq_put_t irq_put;
};
-#define cgs_add_irq_source(dev,src_id,num_types,set,handler,private_data) \
- CGS_OS_CALL(add_irq_source,dev,src_id,num_types,set,handler, \
+#define cgs_add_irq_source(dev,client_id,src_id,num_types,set,handler,private_data) \
+ CGS_OS_CALL(add_irq_source,dev,client_id,src_id,num_types,set,handler, \
private_data)
-#define cgs_irq_get(dev,src_id,type) \
- CGS_OS_CALL(irq_get,dev,src_id,type)
-#define cgs_irq_put(dev,src_id,type) \
- CGS_OS_CALL(irq_put,dev,src_id,type)
+#define cgs_irq_get(dev,client_id,src_id,type) \
+ CGS_OS_CALL(irq_get,dev,client_id,src_id,type)
+#define cgs_irq_put(dev,client_id,src_id,type) \
+ CGS_OS_CALL(irq_put,dev,client_id,src_id,type)
#endif /* _CGS_LINUX_H */