From: Dave Airlie Date: Tue, 19 Dec 2006 07:03:20 +0000 (+1100) Subject: fix irq args compatiblity with pre 2.6.19 X-Git-Tag: libdrm-2.3.1~471 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=303307d25484f3f7179e6967697d28369a73dca9;p=platform%2Fupstream%2Flibdrm.git fix irq args compatiblity with pre 2.6.19 --- diff --git a/linux-core/drm_compat.h b/linux-core/drm_compat.h index a1a9439..c4e80e9 100644 --- a/linux-core/drm_compat.h +++ b/linux-core/drm_compat.h @@ -57,6 +57,12 @@ #define module_param(name, type, perm) #endif +/* older kernels had different irq args */ +#if (LINUX_VERSION_CODE < KERNEL_VERSION(2,6,19)) +#undef DRM_IRQ_ARGS +#define DRM_IRQ_ARGS int irq, void *arg, struct pt_regs *regs +#endif + #ifndef list_for_each_safe #define list_for_each_safe(pos, n, head) \ for (pos = (head)->next, n = pos->next; pos != (head); \ diff --git a/linux-core/drm_os_linux.h b/linux-core/drm_os_linux.h index 4270097..49ba2fb 100644 --- a/linux-core/drm_os_linux.h +++ b/linux-core/drm_os_linux.h @@ -56,7 +56,7 @@ drm_device_t *dev = priv->head->dev /** IRQ handler arguments and return type and values */ -#define DRM_IRQ_ARGS int irq, void *arg, struct pt_regs *regs +#define DRM_IRQ_ARGS int irq, void *arg /** backwards compatibility with old irq return values */ #ifndef IRQ_HANDLED typedef void irqreturn_t;