aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/i915_irq.c
diff options
context:
space:
mode:
authorJani Nikula <jani.nikula@intel.com>2014-03-31 07:27:17 -0400
committerDaniel Vetter <daniel.vetter@ffwll.ch>2014-03-31 09:32:44 -0400
commit2d1013dd82bda51e48c612a2907708d2343bb0ed (patch)
tree33a12ab2f925f18fa90840036e72034917e5f87d /drivers/gpu/drm/i915/i915_irq.c
parent3e31c6c0179212a1f28ba2b41b4d3c352e9fed8b (diff)
drm/i915/irq: prefer struct drm_i915_private to drm_i915_private_t
Also drop any unnecessary casts. No functional changes. Signed-off-by: Jani Nikula <jani.nikula@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_irq.c')
-rw-r--r--drivers/gpu/drm/i915/i915_irq.c110
1 files changed, 55 insertions, 55 deletions
diff --git a/drivers/gpu/drm/i915/i915_irq.c b/drivers/gpu/drm/i915/i915_irq.c
index 72e26e2be301..26f217d63a3c 100644
--- a/drivers/gpu/drm/i915/i915_irq.c
+++ b/drivers/gpu/drm/i915/i915_irq.c
@@ -82,7 +82,7 @@ static const u32 hpd_status_i915[] = { /* i915 and valleyview are the same */
82 82
83/* For display hotplug interrupt */ 83/* For display hotplug interrupt */
84static void 84static void
85ironlake_enable_display_irq(drm_i915_private_t *dev_priv, u32 mask) 85ironlake_enable_display_irq(struct drm_i915_private *dev_priv, u32 mask)
86{ 86{
87 assert_spin_locked(&dev_priv->irq_lock); 87 assert_spin_locked(&dev_priv->irq_lock);
88 88
@@ -100,7 +100,7 @@ ironlake_enable_display_irq(drm_i915_private_t *dev_priv, u32 mask)
100} 100}
101 101
102static void 102static void
103ironlake_disable_display_irq(drm_i915_private_t *dev_priv, u32 mask) 103ironlake_disable_display_irq(struct drm_i915_private *dev_priv, u32 mask)
104{ 104{
105 assert_spin_locked(&dev_priv->irq_lock); 105 assert_spin_locked(&dev_priv->irq_lock);
106 106
@@ -596,7 +596,7 @@ i915_disable_pipestat(struct drm_i915_private *dev_priv, enum pipe pipe,
596 */ 596 */
597static void i915_enable_asle_pipestat(struct drm_device *dev) 597static void i915_enable_asle_pipestat(struct drm_device *dev)
598{ 598{
599 drm_i915_private_t *dev_priv = dev->dev_private; 599 struct drm_i915_private *dev_priv = dev->dev_private;
600 unsigned long irqflags; 600 unsigned long irqflags;
601 601
602 if (!dev_priv->opregion.asle || !IS_MOBILE(dev)) 602 if (!dev_priv->opregion.asle || !IS_MOBILE(dev))
@@ -624,7 +624,7 @@ static void i915_enable_asle_pipestat(struct drm_device *dev)
624static int 624static int
625i915_pipe_enabled(struct drm_device *dev, int pipe) 625i915_pipe_enabled(struct drm_device *dev, int pipe)
626{ 626{
627 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 627 struct drm_i915_private *dev_priv = dev->dev_private;
628 628
629 if (drm_core_check_feature(dev, DRIVER_MODESET)) { 629 if (drm_core_check_feature(dev, DRIVER_MODESET)) {
630 /* Locking is horribly broken here, but whatever. */ 630 /* Locking is horribly broken here, but whatever. */
@@ -648,7 +648,7 @@ static u32 i8xx_get_vblank_counter(struct drm_device *dev, int pipe)
648 */ 648 */
649static u32 i915_get_vblank_counter(struct drm_device *dev, int pipe) 649static u32 i915_get_vblank_counter(struct drm_device *dev, int pipe)
650{ 650{
651 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 651 struct drm_i915_private *dev_priv = dev->dev_private;
652 unsigned long high_frame; 652 unsigned long high_frame;
653 unsigned long low_frame; 653 unsigned long low_frame;
654 u32 high1, high2, low, pixel, vbl_start; 654 u32 high1, high2, low, pixel, vbl_start;
@@ -704,7 +704,7 @@ static u32 i915_get_vblank_counter(struct drm_device *dev, int pipe)
704 704
705static u32 gm45_get_vblank_counter(struct drm_device *dev, int pipe) 705static u32 gm45_get_vblank_counter(struct drm_device *dev, int pipe)
706{ 706{
707 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 707 struct drm_i915_private *dev_priv = dev->dev_private;
708 int reg = PIPE_FRMCOUNT_GM45(pipe); 708 int reg = PIPE_FRMCOUNT_GM45(pipe);
709 709
710 if (!i915_pipe_enabled(dev, pipe)) { 710 if (!i915_pipe_enabled(dev, pipe)) {
@@ -959,8 +959,8 @@ static bool intel_hpd_irq_event(struct drm_device *dev,
959 959
960static void i915_hotplug_work_func(struct work_struct *work) 960static void i915_hotplug_work_func(struct work_struct *work)
961{ 961{
962 drm_i915_private_t *dev_priv = container_of(work, drm_i915_private_t, 962 struct drm_i915_private *dev_priv =
963 hotplug_work); 963 container_of(work, struct drm_i915_private, hotplug_work);
964 struct drm_device *dev = dev_priv->dev; 964 struct drm_device *dev = dev_priv->dev;
965 struct drm_mode_config *mode_config = &dev->mode_config; 965 struct drm_mode_config *mode_config = &dev->mode_config;
966 struct intel_connector *intel_connector; 966 struct intel_connector *intel_connector;
@@ -1035,7 +1035,7 @@ static void intel_hpd_irq_uninstall(struct drm_i915_private *dev_priv)
1035 1035
1036static void ironlake_rps_change_irq_handler(struct drm_device *dev) 1036static void ironlake_rps_change_irq_handler(struct drm_device *dev)
1037{ 1037{
1038 drm_i915_private_t *dev_priv = dev->dev_private; 1038 struct drm_i915_private *dev_priv = dev->dev_private;
1039 u32 busy_up, busy_down, max_avg, min_avg; 1039 u32 busy_up, busy_down, max_avg, min_avg;
1040 u8 new_delay; 1040 u8 new_delay;
1041 1041
@@ -1086,8 +1086,8 @@ static void notify_ring(struct drm_device *dev,
1086 1086
1087static void gen6_pm_rps_work(struct work_struct *work) 1087static void gen6_pm_rps_work(struct work_struct *work)
1088{ 1088{
1089 drm_i915_private_t *dev_priv = container_of(work, drm_i915_private_t, 1089 struct drm_i915_private *dev_priv =
1090 rps.work); 1090 container_of(work, struct drm_i915_private, rps.work);
1091 u32 pm_iir; 1091 u32 pm_iir;
1092 int new_delay, adj; 1092 int new_delay, adj;
1093 1093
@@ -1165,8 +1165,8 @@ static void gen6_pm_rps_work(struct work_struct *work)
1165 */ 1165 */
1166static void ivybridge_parity_work(struct work_struct *work) 1166static void ivybridge_parity_work(struct work_struct *work)
1167{ 1167{
1168 drm_i915_private_t *dev_priv = container_of(work, drm_i915_private_t, 1168 struct drm_i915_private *dev_priv =
1169 l3_parity.error_work); 1169 container_of(work, struct drm_i915_private, l3_parity.error_work);
1170 u32 error_status, row, bank, subbank; 1170 u32 error_status, row, bank, subbank;
1171 char *parity_event[6]; 1171 char *parity_event[6];
1172 uint32_t misccpctl; 1172 uint32_t misccpctl;
@@ -1238,7 +1238,7 @@ out:
1238 1238
1239static void ivybridge_parity_error_irq_handler(struct drm_device *dev, u32 iir) 1239static void ivybridge_parity_error_irq_handler(struct drm_device *dev, u32 iir)
1240{ 1240{
1241 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 1241 struct drm_i915_private *dev_priv = dev->dev_private;
1242 1242
1243 if (!HAS_L3_DPF(dev)) 1243 if (!HAS_L3_DPF(dev))
1244 return; 1244 return;
@@ -1349,7 +1349,7 @@ static inline void intel_hpd_irq_handler(struct drm_device *dev,
1349 u32 hotplug_trigger, 1349 u32 hotplug_trigger,
1350 const u32 *hpd) 1350 const u32 *hpd)
1351{ 1351{
1352 drm_i915_private_t *dev_priv = dev->dev_private; 1352 struct drm_i915_private *dev_priv = dev->dev_private;
1353 int i; 1353 int i;
1354 bool storm_detected = false; 1354 bool storm_detected = false;
1355 1355
@@ -1405,14 +1405,14 @@ static inline void intel_hpd_irq_handler(struct drm_device *dev,
1405 1405
1406static void gmbus_irq_handler(struct drm_device *dev) 1406static void gmbus_irq_handler(struct drm_device *dev)
1407{ 1407{
1408 struct drm_i915_private *dev_priv = (drm_i915_private_t *) dev->dev_private; 1408 struct drm_i915_private *dev_priv = dev->dev_private;
1409 1409
1410 wake_up_all(&dev_priv->gmbus_wait_queue); 1410 wake_up_all(&dev_priv->gmbus_wait_queue);
1411} 1411}
1412 1412
1413static void dp_aux_irq_handler(struct drm_device *dev) 1413static void dp_aux_irq_handler(struct drm_device *dev)
1414{ 1414{
1415 struct drm_i915_private *dev_priv = (drm_i915_private_t *) dev->dev_private; 1415 struct drm_i915_private *dev_priv = dev->dev_private;
1416 1416
1417 wake_up_all(&dev_priv->gmbus_wait_queue); 1417 wake_up_all(&dev_priv->gmbus_wait_queue);
1418} 1418}
@@ -1612,7 +1612,7 @@ static void valleyview_pipestat_irq_handler(struct drm_device *dev, u32 iir)
1612static irqreturn_t valleyview_irq_handler(int irq, void *arg) 1612static irqreturn_t valleyview_irq_handler(int irq, void *arg)
1613{ 1613{
1614 struct drm_device *dev = (struct drm_device *) arg; 1614 struct drm_device *dev = (struct drm_device *) arg;
1615 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 1615 struct drm_i915_private *dev_priv = dev->dev_private;
1616 u32 iir, gt_iir, pm_iir; 1616 u32 iir, gt_iir, pm_iir;
1617 irqreturn_t ret = IRQ_NONE; 1617 irqreturn_t ret = IRQ_NONE;
1618 1618
@@ -1659,7 +1659,7 @@ out:
1659 1659
1660static void ibx_irq_handler(struct drm_device *dev, u32 pch_iir) 1660static void ibx_irq_handler(struct drm_device *dev, u32 pch_iir)
1661{ 1661{
1662 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 1662 struct drm_i915_private *dev_priv = dev->dev_private;
1663 int pipe; 1663 int pipe;
1664 u32 hotplug_trigger = pch_iir & SDE_HOTPLUG_MASK; 1664 u32 hotplug_trigger = pch_iir & SDE_HOTPLUG_MASK;
1665 1665
@@ -1766,7 +1766,7 @@ static void cpt_serr_int_handler(struct drm_device *dev)
1766 1766
1767static void cpt_irq_handler(struct drm_device *dev, u32 pch_iir) 1767static void cpt_irq_handler(struct drm_device *dev, u32 pch_iir)
1768{ 1768{
1769 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 1769 struct drm_i915_private *dev_priv = dev->dev_private;
1770 int pipe; 1770 int pipe;
1771 u32 hotplug_trigger = pch_iir & SDE_HOTPLUG_MASK_CPT; 1771 u32 hotplug_trigger = pch_iir & SDE_HOTPLUG_MASK_CPT;
1772 1772
@@ -1890,7 +1890,7 @@ static void ivb_display_irq_handler(struct drm_device *dev, u32 de_iir)
1890static irqreturn_t ironlake_irq_handler(int irq, void *arg) 1890static irqreturn_t ironlake_irq_handler(int irq, void *arg)
1891{ 1891{
1892 struct drm_device *dev = (struct drm_device *) arg; 1892 struct drm_device *dev = (struct drm_device *) arg;
1893 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 1893 struct drm_i915_private *dev_priv = dev->dev_private;
1894 u32 de_iir, gt_iir, de_ier, sde_ier = 0; 1894 u32 de_iir, gt_iir, de_ier, sde_ier = 0;
1895 irqreturn_t ret = IRQ_NONE; 1895 irqreturn_t ret = IRQ_NONE;
1896 1896
@@ -2101,8 +2101,8 @@ static void i915_error_work_func(struct work_struct *work)
2101{ 2101{
2102 struct i915_gpu_error *error = container_of(work, struct i915_gpu_error, 2102 struct i915_gpu_error *error = container_of(work, struct i915_gpu_error,
2103 work); 2103 work);
2104 drm_i915_private_t *dev_priv = container_of(error, drm_i915_private_t, 2104 struct drm_i915_private *dev_priv =
2105 gpu_error); 2105 container_of(error, struct drm_i915_private, gpu_error);
2106 struct drm_device *dev = dev_priv->dev; 2106 struct drm_device *dev = dev_priv->dev;
2107 char *error_event[] = { I915_ERROR_UEVENT "=1", NULL }; 2107 char *error_event[] = { I915_ERROR_UEVENT "=1", NULL };
2108 char *reset_event[] = { I915_RESET_UEVENT "=1", NULL }; 2108 char *reset_event[] = { I915_RESET_UEVENT "=1", NULL };
@@ -2311,7 +2311,7 @@ void i915_handle_error(struct drm_device *dev, bool wedged,
2311 2311
2312static void __always_unused i915_pageflip_stall_check(struct drm_device *dev, int pipe) 2312static void __always_unused i915_pageflip_stall_check(struct drm_device *dev, int pipe)
2313{ 2313{
2314 drm_i915_private_t *dev_priv = dev->dev_private; 2314 struct drm_i915_private *dev_priv = dev->dev_private;
2315 struct drm_crtc *crtc = dev_priv->pipe_to_crtc_mapping[pipe]; 2315 struct drm_crtc *crtc = dev_priv->pipe_to_crtc_mapping[pipe];
2316 struct intel_crtc *intel_crtc = to_intel_crtc(crtc); 2316 struct intel_crtc *intel_crtc = to_intel_crtc(crtc);
2317 struct drm_i915_gem_object *obj; 2317 struct drm_i915_gem_object *obj;
@@ -2360,7 +2360,7 @@ static void __always_unused i915_pageflip_stall_check(struct drm_device *dev, in
2360 */ 2360 */
2361static int i915_enable_vblank(struct drm_device *dev, int pipe) 2361static int i915_enable_vblank(struct drm_device *dev, int pipe)
2362{ 2362{
2363 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 2363 struct drm_i915_private *dev_priv = dev->dev_private;
2364 unsigned long irqflags; 2364 unsigned long irqflags;
2365 2365
2366 if (!i915_pipe_enabled(dev, pipe)) 2366 if (!i915_pipe_enabled(dev, pipe))
@@ -2384,7 +2384,7 @@ static int i915_enable_vblank(struct drm_device *dev, int pipe)
2384 2384
2385static int ironlake_enable_vblank(struct drm_device *dev, int pipe) 2385static int ironlake_enable_vblank(struct drm_device *dev, int pipe)
2386{ 2386{
2387 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 2387 struct drm_i915_private *dev_priv = dev->dev_private;
2388 unsigned long irqflags; 2388 unsigned long irqflags;
2389 uint32_t bit = (INTEL_INFO(dev)->gen >= 7) ? DE_PIPE_VBLANK_IVB(pipe) : 2389 uint32_t bit = (INTEL_INFO(dev)->gen >= 7) ? DE_PIPE_VBLANK_IVB(pipe) :
2390 DE_PIPE_VBLANK(pipe); 2390 DE_PIPE_VBLANK(pipe);
@@ -2401,7 +2401,7 @@ static int ironlake_enable_vblank(struct drm_device *dev, int pipe)
2401 2401
2402static int valleyview_enable_vblank(struct drm_device *dev, int pipe) 2402static int valleyview_enable_vblank(struct drm_device *dev, int pipe)
2403{ 2403{
2404 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 2404 struct drm_i915_private *dev_priv = dev->dev_private;
2405 unsigned long irqflags; 2405 unsigned long irqflags;
2406 2406
2407 if (!i915_pipe_enabled(dev, pipe)) 2407 if (!i915_pipe_enabled(dev, pipe))
@@ -2436,7 +2436,7 @@ static int gen8_enable_vblank(struct drm_device *dev, int pipe)
2436 */ 2436 */
2437static void i915_disable_vblank(struct drm_device *dev, int pipe) 2437static void i915_disable_vblank(struct drm_device *dev, int pipe)
2438{ 2438{
2439 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 2439 struct drm_i915_private *dev_priv = dev->dev_private;
2440 unsigned long irqflags; 2440 unsigned long irqflags;
2441 2441
2442 spin_lock_irqsave(&dev_priv->irq_lock, irqflags); 2442 spin_lock_irqsave(&dev_priv->irq_lock, irqflags);
@@ -2451,7 +2451,7 @@ static void i915_disable_vblank(struct drm_device *dev, int pipe)
2451 2451
2452static void ironlake_disable_vblank(struct drm_device *dev, int pipe) 2452static void ironlake_disable_vblank(struct drm_device *dev, int pipe)
2453{ 2453{
2454 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 2454 struct drm_i915_private *dev_priv = dev->dev_private;
2455 unsigned long irqflags; 2455 unsigned long irqflags;
2456 uint32_t bit = (INTEL_INFO(dev)->gen >= 7) ? DE_PIPE_VBLANK_IVB(pipe) : 2456 uint32_t bit = (INTEL_INFO(dev)->gen >= 7) ? DE_PIPE_VBLANK_IVB(pipe) :
2457 DE_PIPE_VBLANK(pipe); 2457 DE_PIPE_VBLANK(pipe);
@@ -2463,7 +2463,7 @@ static void ironlake_disable_vblank(struct drm_device *dev, int pipe)
2463 2463
2464static void valleyview_disable_vblank(struct drm_device *dev, int pipe) 2464static void valleyview_disable_vblank(struct drm_device *dev, int pipe)
2465{ 2465{
2466 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 2466 struct drm_i915_private *dev_priv = dev->dev_private;
2467 unsigned long irqflags; 2467 unsigned long irqflags;
2468 2468
2469 spin_lock_irqsave(&dev_priv->irq_lock, irqflags); 2469 spin_lock_irqsave(&dev_priv->irq_lock, irqflags);
@@ -2630,7 +2630,7 @@ ring_stuck(struct intel_ring_buffer *ring, u64 acthd)
2630static void i915_hangcheck_elapsed(unsigned long data) 2630static void i915_hangcheck_elapsed(unsigned long data)
2631{ 2631{
2632 struct drm_device *dev = (struct drm_device *)data; 2632 struct drm_device *dev = (struct drm_device *)data;
2633 drm_i915_private_t *dev_priv = dev->dev_private; 2633 struct drm_i915_private *dev_priv = dev->dev_private;
2634 struct intel_ring_buffer *ring; 2634 struct intel_ring_buffer *ring;
2635 int i; 2635 int i;
2636 int busy_count = 0, rings_hung = 0; 2636 int busy_count = 0, rings_hung = 0;
@@ -2789,7 +2789,7 @@ static void gen5_gt_irq_preinstall(struct drm_device *dev)
2789*/ 2789*/
2790static void ironlake_irq_preinstall(struct drm_device *dev) 2790static void ironlake_irq_preinstall(struct drm_device *dev)
2791{ 2791{
2792 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 2792 struct drm_i915_private *dev_priv = dev->dev_private;
2793 2793
2794 I915_WRITE(HWSTAM, 0xeffe); 2794 I915_WRITE(HWSTAM, 0xeffe);
2795 2795
@@ -2804,7 +2804,7 @@ static void ironlake_irq_preinstall(struct drm_device *dev)
2804 2804
2805static void valleyview_irq_preinstall(struct drm_device *dev) 2805static void valleyview_irq_preinstall(struct drm_device *dev)
2806{ 2806{
2807 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 2807 struct drm_i915_private *dev_priv = dev->dev_private;
2808 int pipe; 2808 int pipe;
2809 2809
2810 /* VLV magic */ 2810 /* VLV magic */
@@ -2880,7 +2880,7 @@ static void gen8_irq_preinstall(struct drm_device *dev)
2880 2880
2881static void ibx_hpd_irq_setup(struct drm_device *dev) 2881static void ibx_hpd_irq_setup(struct drm_device *dev)
2882{ 2882{
2883 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 2883 struct drm_i915_private *dev_priv = dev->dev_private;
2884 struct drm_mode_config *mode_config = &dev->mode_config; 2884 struct drm_mode_config *mode_config = &dev->mode_config;
2885 struct intel_encoder *intel_encoder; 2885 struct intel_encoder *intel_encoder;
2886 u32 hotplug_irqs, hotplug, enabled_irqs = 0; 2886 u32 hotplug_irqs, hotplug, enabled_irqs = 0;
@@ -2915,7 +2915,7 @@ static void ibx_hpd_irq_setup(struct drm_device *dev)
2915 2915
2916static void ibx_irq_postinstall(struct drm_device *dev) 2916static void ibx_irq_postinstall(struct drm_device *dev)
2917{ 2917{
2918 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 2918 struct drm_i915_private *dev_priv = dev->dev_private;
2919 u32 mask; 2919 u32 mask;
2920 2920
2921 if (HAS_PCH_NOP(dev)) 2921 if (HAS_PCH_NOP(dev))
@@ -2977,7 +2977,7 @@ static void gen5_gt_irq_postinstall(struct drm_device *dev)
2977static int ironlake_irq_postinstall(struct drm_device *dev) 2977static int ironlake_irq_postinstall(struct drm_device *dev)
2978{ 2978{
2979 unsigned long irqflags; 2979 unsigned long irqflags;
2980 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 2980 struct drm_i915_private *dev_priv = dev->dev_private;
2981 u32 display_mask, extra_mask; 2981 u32 display_mask, extra_mask;
2982 2982
2983 if (INTEL_INFO(dev)->gen >= 7) { 2983 if (INTEL_INFO(dev)->gen >= 7) {
@@ -3114,7 +3114,7 @@ void valleyview_disable_display_irqs(struct drm_i915_private *dev_priv)
3114 3114
3115static int valleyview_irq_postinstall(struct drm_device *dev) 3115static int valleyview_irq_postinstall(struct drm_device *dev)
3116{ 3116{
3117 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3117 struct drm_i915_private *dev_priv = dev->dev_private;
3118 unsigned long irqflags; 3118 unsigned long irqflags;
3119 3119
3120 dev_priv->irq_mask = ~0; 3120 dev_priv->irq_mask = ~0;
@@ -3261,7 +3261,7 @@ static void gen8_irq_uninstall(struct drm_device *dev)
3261 3261
3262static void valleyview_irq_uninstall(struct drm_device *dev) 3262static void valleyview_irq_uninstall(struct drm_device *dev)
3263{ 3263{
3264 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3264 struct drm_i915_private *dev_priv = dev->dev_private;
3265 unsigned long irqflags; 3265 unsigned long irqflags;
3266 int pipe; 3266 int pipe;
3267 3267
@@ -3292,7 +3292,7 @@ static void valleyview_irq_uninstall(struct drm_device *dev)
3292 3292
3293static void ironlake_irq_uninstall(struct drm_device *dev) 3293static void ironlake_irq_uninstall(struct drm_device *dev)
3294{ 3294{
3295 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3295 struct drm_i915_private *dev_priv = dev->dev_private;
3296 3296
3297 if (!dev_priv) 3297 if (!dev_priv)
3298 return; 3298 return;
@@ -3323,7 +3323,7 @@ static void ironlake_irq_uninstall(struct drm_device *dev)
3323 3323
3324static void i8xx_irq_preinstall(struct drm_device * dev) 3324static void i8xx_irq_preinstall(struct drm_device * dev)
3325{ 3325{
3326 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3326 struct drm_i915_private *dev_priv = dev->dev_private;
3327 int pipe; 3327 int pipe;
3328 3328
3329 for_each_pipe(pipe) 3329 for_each_pipe(pipe)
@@ -3335,7 +3335,7 @@ static void i8xx_irq_preinstall(struct drm_device * dev)
3335 3335
3336static int i8xx_irq_postinstall(struct drm_device *dev) 3336static int i8xx_irq_postinstall(struct drm_device *dev)
3337{ 3337{
3338 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3338 struct drm_i915_private *dev_priv = dev->dev_private;
3339 unsigned long irqflags; 3339 unsigned long irqflags;
3340 3340
3341 I915_WRITE16(EMR, 3341 I915_WRITE16(EMR,
@@ -3373,7 +3373,7 @@ static int i8xx_irq_postinstall(struct drm_device *dev)
3373static bool i8xx_handle_vblank(struct drm_device *dev, 3373static bool i8xx_handle_vblank(struct drm_device *dev,
3374 int plane, int pipe, u32 iir) 3374 int plane, int pipe, u32 iir)
3375{ 3375{
3376 drm_i915_private_t *dev_priv = dev->dev_private; 3376 struct drm_i915_private *dev_priv = dev->dev_private;
3377 u16 flip_pending = DISPLAY_PLANE_FLIP_PENDING(plane); 3377 u16 flip_pending = DISPLAY_PLANE_FLIP_PENDING(plane);
3378 3378
3379 if (!drm_handle_vblank(dev, pipe)) 3379 if (!drm_handle_vblank(dev, pipe))
@@ -3401,7 +3401,7 @@ static bool i8xx_handle_vblank(struct drm_device *dev,
3401static irqreturn_t i8xx_irq_handler(int irq, void *arg) 3401static irqreturn_t i8xx_irq_handler(int irq, void *arg)
3402{ 3402{
3403 struct drm_device *dev = (struct drm_device *) arg; 3403 struct drm_device *dev = (struct drm_device *) arg;
3404 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3404 struct drm_i915_private *dev_priv = dev->dev_private;
3405 u16 iir, new_iir; 3405 u16 iir, new_iir;
3406 u32 pipe_stats[2]; 3406 u32 pipe_stats[2];
3407 unsigned long irqflags; 3407 unsigned long irqflags;
@@ -3471,7 +3471,7 @@ static irqreturn_t i8xx_irq_handler(int irq, void *arg)
3471 3471
3472static void i8xx_irq_uninstall(struct drm_device * dev) 3472static void i8xx_irq_uninstall(struct drm_device * dev)
3473{ 3473{
3474 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3474 struct drm_i915_private *dev_priv = dev->dev_private;
3475 int pipe; 3475 int pipe;
3476 3476
3477 for_each_pipe(pipe) { 3477 for_each_pipe(pipe) {
@@ -3486,7 +3486,7 @@ static void i8xx_irq_uninstall(struct drm_device * dev)
3486 3486
3487static void i915_irq_preinstall(struct drm_device * dev) 3487static void i915_irq_preinstall(struct drm_device * dev)
3488{ 3488{
3489 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3489 struct drm_i915_private *dev_priv = dev->dev_private;
3490 int pipe; 3490 int pipe;
3491 3491
3492 if (I915_HAS_HOTPLUG(dev)) { 3492 if (I915_HAS_HOTPLUG(dev)) {
@@ -3504,7 +3504,7 @@ static void i915_irq_preinstall(struct drm_device * dev)
3504 3504
3505static int i915_irq_postinstall(struct drm_device *dev) 3505static int i915_irq_postinstall(struct drm_device *dev)
3506{ 3506{
3507 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3507 struct drm_i915_private *dev_priv = dev->dev_private;
3508 u32 enable_mask; 3508 u32 enable_mask;
3509 unsigned long irqflags; 3509 unsigned long irqflags;
3510 3510
@@ -3558,7 +3558,7 @@ static int i915_irq_postinstall(struct drm_device *dev)
3558static bool i915_handle_vblank(struct drm_device *dev, 3558static bool i915_handle_vblank(struct drm_device *dev,
3559 int plane, int pipe, u32 iir) 3559 int plane, int pipe, u32 iir)
3560{ 3560{
3561 drm_i915_private_t *dev_priv = dev->dev_private; 3561 struct drm_i915_private *dev_priv = dev->dev_private;
3562 u32 flip_pending = DISPLAY_PLANE_FLIP_PENDING(plane); 3562 u32 flip_pending = DISPLAY_PLANE_FLIP_PENDING(plane);
3563 3563
3564 if (!drm_handle_vblank(dev, pipe)) 3564 if (!drm_handle_vblank(dev, pipe))
@@ -3586,7 +3586,7 @@ static bool i915_handle_vblank(struct drm_device *dev,
3586static irqreturn_t i915_irq_handler(int irq, void *arg) 3586static irqreturn_t i915_irq_handler(int irq, void *arg)
3587{ 3587{
3588 struct drm_device *dev = (struct drm_device *) arg; 3588 struct drm_device *dev = (struct drm_device *) arg;
3589 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3589 struct drm_i915_private *dev_priv = dev->dev_private;
3590 u32 iir, new_iir, pipe_stats[I915_MAX_PIPES]; 3590 u32 iir, new_iir, pipe_stats[I915_MAX_PIPES];
3591 unsigned long irqflags; 3591 unsigned long irqflags;
3592 u32 flip_mask = 3592 u32 flip_mask =
@@ -3692,7 +3692,7 @@ static irqreturn_t i915_irq_handler(int irq, void *arg)
3692 3692
3693static void i915_irq_uninstall(struct drm_device * dev) 3693static void i915_irq_uninstall(struct drm_device * dev)
3694{ 3694{
3695 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3695 struct drm_i915_private *dev_priv = dev->dev_private;
3696 int pipe; 3696 int pipe;
3697 3697
3698 intel_hpd_irq_uninstall(dev_priv); 3698 intel_hpd_irq_uninstall(dev_priv);
@@ -3716,7 +3716,7 @@ static void i915_irq_uninstall(struct drm_device * dev)
3716 3716
3717static void i965_irq_preinstall(struct drm_device * dev) 3717static void i965_irq_preinstall(struct drm_device * dev)
3718{ 3718{
3719 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3719 struct drm_i915_private *dev_priv = dev->dev_private;
3720 int pipe; 3720 int pipe;
3721 3721
3722 I915_WRITE(PORT_HOTPLUG_EN, 0); 3722 I915_WRITE(PORT_HOTPLUG_EN, 0);
@@ -3732,7 +3732,7 @@ static void i965_irq_preinstall(struct drm_device * dev)
3732 3732
3733static int i965_irq_postinstall(struct drm_device *dev) 3733static int i965_irq_postinstall(struct drm_device *dev)
3734{ 3734{
3735 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3735 struct drm_i915_private *dev_priv = dev->dev_private;
3736 u32 enable_mask; 3736 u32 enable_mask;
3737 u32 error_mask; 3737 u32 error_mask;
3738 unsigned long irqflags; 3738 unsigned long irqflags;
@@ -3791,7 +3791,7 @@ static int i965_irq_postinstall(struct drm_device *dev)
3791 3791
3792static void i915_hpd_irq_setup(struct drm_device *dev) 3792static void i915_hpd_irq_setup(struct drm_device *dev)
3793{ 3793{
3794 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3794 struct drm_i915_private *dev_priv = dev->dev_private;
3795 struct drm_mode_config *mode_config = &dev->mode_config; 3795 struct drm_mode_config *mode_config = &dev->mode_config;
3796 struct intel_encoder *intel_encoder; 3796 struct intel_encoder *intel_encoder;
3797 u32 hotplug_en; 3797 u32 hotplug_en;
@@ -3823,7 +3823,7 @@ static void i915_hpd_irq_setup(struct drm_device *dev)
3823static irqreturn_t i965_irq_handler(int irq, void *arg) 3823static irqreturn_t i965_irq_handler(int irq, void *arg)
3824{ 3824{
3825 struct drm_device *dev = (struct drm_device *) arg; 3825 struct drm_device *dev = (struct drm_device *) arg;
3826 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3826 struct drm_i915_private *dev_priv = dev->dev_private;
3827 u32 iir, new_iir; 3827 u32 iir, new_iir;
3828 u32 pipe_stats[I915_MAX_PIPES]; 3828 u32 pipe_stats[I915_MAX_PIPES];
3829 unsigned long irqflags; 3829 unsigned long irqflags;
@@ -3941,7 +3941,7 @@ static irqreturn_t i965_irq_handler(int irq, void *arg)
3941 3941
3942static void i965_irq_uninstall(struct drm_device * dev) 3942static void i965_irq_uninstall(struct drm_device * dev)
3943{ 3943{
3944 drm_i915_private_t *dev_priv = (drm_i915_private_t *) dev->dev_private; 3944 struct drm_i915_private *dev_priv = dev->dev_private;
3945 int pipe; 3945 int pipe;
3946 3946
3947 if (!dev_priv) 3947 if (!dev_priv)
@@ -3966,7 +3966,7 @@ static void i965_irq_uninstall(struct drm_device * dev)
3966 3966
3967static void intel_hpd_irq_reenable(unsigned long data) 3967static void intel_hpd_irq_reenable(unsigned long data)
3968{ 3968{
3969 drm_i915_private_t *dev_priv = (drm_i915_private_t *)data; 3969 struct drm_i915_private *dev_priv = (struct drm_i915_private *)data;
3970 struct drm_device *dev = dev_priv->dev; 3970 struct drm_device *dev = dev_priv->dev;
3971 struct drm_mode_config *mode_config = &dev->mode_config; 3971 struct drm_mode_config *mode_config = &dev->mode_config;
3972 unsigned long irqflags; 3972 unsigned long irqflags;