diff options
| author | Patrik Jakobsson <patrik.r.jakobsson@gmail.com> | 2013-07-21 19:31:23 -0400 |
|---|---|---|
| committer | Patrik Jakobsson <patrik.r.jakobsson@gmail.com> | 2013-07-23 19:47:33 -0400 |
| commit | 6306865daf0283d1b13adea8be8d1ad4dd0ea1c3 (patch) | |
| tree | 891ac48786f85357a052ede877b92b8156e6ee97 | |
| parent | c5c81f4e1bc9c8ee1c3637de51ee180efbbf629c (diff) | |
drm/gma500: Rename psb_intel_crtc to gma_crtc
The psb_intel_crtc is generic and should be named appropriately
Signed-off-by: Patrik Jakobsson <patrik.r.jakobsson@gmail.com>
| -rw-r--r-- | drivers/gpu/drm/gma500/cdv_intel_crt.c | 7 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/cdv_intel_display.c | 28 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/cdv_intel_dp.c | 10 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/cdv_intel_hdmi.c | 6 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/cdv_intel_lvds.c | 8 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/framebuffer.c | 16 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/gma_display.c | 105 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/mdfld_dsi_output.c | 15 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/mdfld_intel_display.c | 16 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/oaktrail_crtc.c | 16 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/psb_drv.c | 6 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/psb_intel_display.c | 98 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/psb_intel_drv.h | 6 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/psb_intel_lvds.c | 10 | ||||
| -rw-r--r-- | drivers/gpu/drm/gma500/psb_intel_sdvo.c | 4 |
15 files changed, 170 insertions, 181 deletions
diff --git a/drivers/gpu/drm/gma500/cdv_intel_crt.c b/drivers/gpu/drm/gma500/cdv_intel_crt.c index 0cfcb26fb2a1..79ad19696f71 100644 --- a/drivers/gpu/drm/gma500/cdv_intel_crt.c +++ b/drivers/gpu/drm/gma500/cdv_intel_crt.c | |||
| @@ -95,13 +95,12 @@ static void cdv_intel_crt_mode_set(struct drm_encoder *encoder, | |||
| 95 | 95 | ||
| 96 | struct drm_device *dev = encoder->dev; | 96 | struct drm_device *dev = encoder->dev; |
| 97 | struct drm_crtc *crtc = encoder->crtc; | 97 | struct drm_crtc *crtc = encoder->crtc; |
| 98 | struct psb_intel_crtc *psb_intel_crtc = | 98 | struct gma_crtc *gma_crtc = to_gma_crtc(crtc); |
| 99 | to_psb_intel_crtc(crtc); | ||
| 100 | int dpll_md_reg; | 99 | int dpll_md_reg; |
| 101 | u32 adpa, dpll_md; | 100 | u32 adpa, dpll_md; |
| 102 | u32 adpa_reg; | 101 | u32 adpa_reg; |
| 103 | 102 | ||
| 104 | if (psb_intel_crtc->pipe == 0) | 103 | if (gma_crtc->pipe == 0) |
| 105 | dpll_md_reg = DPLL_A_MD; | 104 | dpll_md_reg = DPLL_A_MD; |
| 106 | else | 105 | else |
| 107 | dpll_md_reg = DPLL_B_MD; | 106 | dpll_md_reg = DPLL_B_MD; |
| @@ -124,7 +123,7 @@ static void cdv_intel_crt_mode_set(struct drm_encoder *encoder, | |||
| 124 | if (adjusted_mode->flags & DRM_MODE_FLAG_PVSYNC) | 123 | if (adjusted_mode->flags & DRM_MODE_FLAG_PVSYNC) |
| 125 | adpa |= ADPA_VSYNC_ACTIVE_HIGH; | 124 | adpa |= ADPA_VSYNC_ACTIVE_HIGH; |
| 126 | 125 | ||
| 127 | if (psb_intel_crtc->pipe == 0) | 126 | if (gma_crtc->pipe == 0) |
| 128 | adpa |= ADPA_PIPE_A_SELECT; | 127 | adpa |= ADPA_PIPE_A_SELECT; |
| 129 | else | 128 | else |
| 130 | adpa |= ADPA_PIPE_B_SELECT; | 129 | adpa |= ADPA_PIPE_B_SELECT; |
diff --git a/drivers/gpu/drm/gma500/cdv_intel_display.c b/drivers/gpu/drm/gma500/cdv_intel_display.c index 6bca1fe470ab..e18c3b9fd07f 100644 --- a/drivers/gpu/drm/gma500/cdv_intel_display.c +++ b/drivers/gpu/drm/gma500/cdv_intel_display.c | |||
| @@ -222,8 +222,8 @@ static int | |||
| 222 | cdv_dpll_set_clock_cdv(struct drm_device *dev, struct drm_crtc *crtc, | 222 | cdv_dpll_set_clock_cdv(struct drm_device *dev, struct drm_crtc *crtc, |
| 223 | struct gma_clock_t *clock, bool is_lvds, u32 ddi_select) | 223 | struct gma_clock_t *clock, bool is_lvds, u32 ddi_select) |
| 224 | { | 224 | { |
| 225 | struct psb_intel_crtc *psb_crtc = to_psb_intel_crtc(crtc); | 225 | struct gma_crtc *gma_crtc = to_gma_crtc(crtc); |
| 226 | int pipe = psb_crtc->pipe; | 226 | int pipe = gma_crtc->pipe; |
| 227 | u32 m, n_vco, p; | 227 | u32 m, n_vco, p; |
| 228 | int ret = 0; | 228 | int ret = 0; |
| 229 | int dpll_reg = (pipe == 0) ? DPLL_A : DPLL_B; | 229 | int dpll_reg = (pipe == 0) ? DPLL_A : DPLL_B; |
| @@ -458,12 +458,12 @@ static bool cdv_intel_pipe_enabled(struct drm_device *dev, int pipe) | |||
| 458 | { | 458 | { |
| 459 | struct drm_crtc *crtc; | 459 | struct drm_crtc *crtc; |
| 460 | struct drm_psb_private *dev_priv = dev->dev_private; | 460 | struct drm_psb_private *dev_priv = dev->dev_private; |
| 461 | struct psb_intel_crtc *psb_intel_crtc = NULL; | 461 | struct gma_crtc *gma_crtc = NULL; |
| 462 | 462 | ||
| 463 | crtc = dev_priv->pipe_to_crtc_mapping[pipe]; | 463 | crtc = dev_priv->pipe_to_crtc_mapping[pipe]; |
| 464 | psb_intel_crtc = to_psb_intel_crtc(crtc); | 464 | gma_crtc = to_gma_crtc(crtc); |
| 465 | 465 | ||
| 466 | if (crtc->fb == NULL || !psb_intel_crtc->active) | 466 | if (crtc->fb == NULL || !gma_crtc->active) |
| 467 | return false; | 467 | return false; |
| 468 | return true; | 468 | return true; |
| 469 | } | 469 | } |
| @@ -489,11 +489,11 @@ static bool cdv_intel_single_pipe_active (struct drm_device *dev) | |||
| 489 | 489 | ||
| 490 | static bool is_pipeb_lvds(struct drm_device *dev, struct drm_crtc *crtc) | 490 | static bool is_pipeb_lvds(struct drm_device *dev, struct drm_crtc *crtc) |
| 491 | { | 491 | { |
| 492 | struct psb_intel_crtc *psb_intel_crtc = to_psb_intel_crtc(crtc); | 492 | struct gma_crtc *gma_crtc = to_gma_crtc(crtc); |
| 493 | struct drm_mode_config *mode_config = &dev->mode_config; | 493 | struct drm_mode_config *mode_config = &dev->mode_config; |
| 494 | struct drm_connector *connector; | 494 | struct drm_connector *connector; |
| 495 | 495 | ||
| 496 | if (psb_intel_crtc->pipe != 1) | 496 | if (gma_crtc->pipe != 1) |
| 497 | return false; | 497 | return false; |
| 498 | 498 | ||
| 499 | list_for_each_entry(connector, &mode_config->connector_list, head) { | 499 | list_for_each_entry(connector, &mode_config->connector_list, head) { |
| @@ -616,8 +616,8 @@ static int cdv_intel_crtc_mode_set(struct drm_crtc *crtc, | |||
| 616 | { | 616 | { |
| 617 | struct drm_device *dev = crtc->dev; | 617 | struct drm_device *dev = crtc->dev; |
| 618 | struct drm_psb_private *dev_priv = dev->dev_private; | 618 | struct drm_psb_private *dev_priv = dev->dev_private; |
| 619 | struct psb_intel_crtc *psb_intel_crtc = to_psb_intel_crtc(crtc); | 619 | struct gma_crtc *gma_crtc = to_gma_crtc(crtc); |
| 620 | int pipe = psb_intel_crtc->pipe; | 620 | int pipe = gma_crtc->pipe; |
| 621 | const struct psb_offset *map = &dev_priv->regmap[pipe]; | 621 | const struct psb_offset *map = &dev_priv->regmap[pipe]; |
| 622 | int refclk; | 622 | int refclk; |
| 623 | struct gma_clock_t clock; | 623 | struct gma_clock_t clock; |
| @@ -693,7 +693,7 @@ static int cdv_intel_crtc_mode_set(struct drm_crtc *crtc, | |||
| 693 | 693 | ||
| 694 | drm_mode_debug_printmodeline(adjusted_mode); | 694 | drm_mode_debug_printmodeline(adjusted_mode); |
| 695 | 695 | ||
| 696 | limit = psb_intel_crtc->clock_funcs->limit(crtc, refclk); | 696 | limit = gma_crtc->clock_funcs->limit(crtc, refclk); |
| 697 | 697 | ||
| 698 | ok = limit->find_pll(limit, crtc, adjusted_mode->clock, refclk, | 698 | ok = limit->find_pll(limit, crtc, adjusted_mode->clock, refclk, |
| 699 | &clock); | 699 | &clock); |
| @@ -883,8 +883,8 @@ static int cdv_intel_crtc_clock_get(struct drm_device *dev, | |||
| 883 | struct drm_crtc *crtc) | 883 | struct drm_crtc *crtc) |
| 884 | { | 884 | { |
| 885 | struct drm_psb_private *dev_priv = dev->dev_private; | 885 | struct drm_psb_private *dev_priv = dev->dev_private; |
| 886 | struct psb_intel_crtc *psb_intel_crtc = to_psb_intel_crtc(crtc); | 886 | struct gma_crtc *gma_crtc = to_gma_crtc(crtc); |
| 887 | int pipe = psb_intel_crtc->pipe; | 887 | int pipe = gma_crtc->pipe; |
| 888 | const struct psb_offset *map = &dev_priv->regmap[pipe]; | 888 | const struct psb_offset *map = &dev_priv->regmap[pipe]; |
| 889 | u32 dpll; | 889 | u32 dpll; |
| 890 | u32 fp; | 890 | u32 fp; |
| @@ -961,8 +961,8 @@ static int cdv_intel_crtc_clock_get(struct drm_device *dev, | |||
| 961 | struct drm_display_mode *cdv_intel_crtc_mode_get(struct drm_device *dev, | 961 | struct drm_display_mode *cdv_intel_crtc_mode_get(struct drm_device *dev, |
| 962 | struct drm_crtc *crtc) | 962 | struct drm_crtc *crtc) |
| 963 | { | 963 | { |
| 964 | struct psb_intel_crtc *psb_intel_crtc = to_psb_intel_crtc(crtc); | 964 | struct gma_crtc *gma_crtc = to_gma_crtc(crtc); |
| 965 | int pipe = psb_intel_crtc->pipe; | 965 | int pipe = gma_crtc->pipe; |
| 966 | struct drm_psb_private *dev_priv = dev->dev_private; | 966 | struct drm_psb_private *dev_priv = dev->dev_private; |
| 967 | struct psb_pipe *p = &dev_priv->regs.pipe[pipe]; | 967 | struct psb_pipe *p = &dev_priv->regs.pipe[pipe]; |
| 968 | const struct psb_offset *map = &dev_priv->regmap[pipe]; | 968 | const struct psb_offset *map = &dev_priv->regmap[pipe]; |
diff --git a/drivers/gpu/drm/gma500/cdv_intel_dp.c b/drivers/gpu/drm/gma500/cdv_intel_dp.c index e3907becf8c9..a90adf629925 100644 --- a/drivers/gpu/drm/gma500/cdv_intel_dp.c +++ b/drivers/gpu/drm/gma500/cdv_intel_dp.c | |||
| @@ -793,10 +793,10 @@ cdv_intel_dp_set_m_n(struct drm_crtc *crtc, struct drm_display_mode *mode, | |||
| 793 | struct drm_psb_private *dev_priv = dev->dev_private; | 793 | struct drm_psb_private *dev_priv = dev->dev_private; |
| 794 | struct drm_mode_config *mode_config = &dev->mode_config; | 794 | struct drm_mode_config *mode_config = &dev->mode_config; |
| 795 | struct drm_encoder *encoder; | 795 | struct drm_encoder *encoder; |
| 796 | struct psb_intel_crtc *intel_crtc = to_psb_intel_crtc(crtc); | 796 | struct gma_crtc *gma_crtc = to_gma_crtc(crtc); |
| 797 | int lane_count = 4, bpp = 24; | 797 | int lane_count = 4, bpp = 24; |
| 798 | struct cdv_intel_dp_m_n m_n; | 798 | struct cdv_intel_dp_m_n m_n; |
| 799 | int pipe = intel_crtc->pipe; | 799 | int pipe = gma_crtc->pipe; |
| 800 | |||
