diff options
Diffstat (limited to 'drivers/gpu/drm/gma500/framebuffer.c')
-rw-r--r-- | drivers/gpu/drm/gma500/framebuffer.c | 25 |
1 files changed, 12 insertions, 13 deletions
diff --git a/drivers/gpu/drm/gma500/framebuffer.c b/drivers/gpu/drm/gma500/framebuffer.c index 362dd2ad286f..01dd7d225762 100644 --- a/drivers/gpu/drm/gma500/framebuffer.c +++ b/drivers/gpu/drm/gma500/framebuffer.c | |||
@@ -520,21 +520,21 @@ static struct drm_framebuffer *psb_user_framebuffer_create | |||
520 | static void psbfb_gamma_set(struct drm_crtc *crtc, u16 red, u16 green, | 520 | static void psbfb_gamma_set(struct drm_crtc *crtc, u16 red, u16 green, |
521 | u16 blue, int regno) | 521 | u16 blue, int regno) |
522 | { | 522 | { |
523 | struct psb_intel_crtc *intel_crtc = to_psb_intel_crtc(crtc); | 523 | struct gma_crtc *gma_crtc = to_gma_crtc(crtc); |
524 | 524 | ||
525 | intel_crtc->lut_r[regno] = red >> 8; | 525 | gma_crtc->lut_r[regno] = red >> 8; |
526 | intel_crtc->lut_g[regno] = green >> 8; | 526 | gma_crtc->lut_g[regno] = green >> 8; |
527 | intel_crtc->lut_b[regno] = blue >> 8; | 527 | gma_crtc->lut_b[regno] = blue >> 8; |
528 | } | 528 | } |
529 | 529 | ||
530 | static void psbfb_gamma_get(struct drm_crtc *crtc, u16 *red, | 530 | static void psbfb_gamma_get(struct drm_crtc *crtc, u16 *red, |
531 | u16 *green, u16 *blue, int regno) | 531 | u16 *green, u16 *blue, int regno) |
532 | { | 532 | { |
533 | struct psb_intel_crtc *intel_crtc = to_psb_intel_crtc(crtc); | 533 | struct gma_crtc *gma_crtc = to_gma_crtc(crtc); |
534 | 534 | ||
535 | *red = intel_crtc->lut_r[regno] << 8; | 535 | *red = gma_crtc->lut_r[regno] << 8; |
536 | *green = intel_crtc->lut_g[regno] << 8; | 536 | *green = gma_crtc->lut_g[regno] << 8; |
537 | *blue = intel_crtc->lut_b[regno] << 8; | 537 | *blue = gma_crtc->lut_b[regno] << 8; |
538 | } | 538 | } |
539 | 539 | ||
540 | static int psbfb_probe(struct drm_fb_helper *helper, | 540 | static int psbfb_probe(struct drm_fb_helper *helper, |
@@ -703,13 +703,12 @@ static void psb_setup_outputs(struct drm_device *dev) | |||
703 | 703 | ||
704 | list_for_each_entry(connector, &dev->mode_config.connector_list, | 704 | list_for_each_entry(connector, &dev->mode_config.connector_list, |
705 | head) { | 705 | head) { |
706 | struct psb_intel_encoder *psb_intel_encoder = | 706 | struct gma_encoder *gma_encoder = gma_attached_encoder(connector); |
707 | psb_intel_attached_encoder(connector); | 707 | struct drm_encoder *encoder = &gma_encoder->base; |
708 | struct drm_encoder *encoder = &psb_intel_encoder->base; | ||
709 | int crtc_mask = 0, clone_mask = 0; | 708 | int crtc_mask = 0, clone_mask = 0; |
710 | 709 | ||
711 | /* valid crtcs */ | 710 | /* valid crtcs */ |
712 | switch (psb_intel_encoder->type) { | 711 | switch (gma_encoder->type) { |
713 | case INTEL_OUTPUT_ANALOG: | 712 | case INTEL_OUTPUT_ANALOG: |
714 | crtc_mask = (1 << 0); | 713 | crtc_mask = (1 << 0); |
715 | clone_mask = (1 << INTEL_OUTPUT_ANALOG); | 714 | clone_mask = (1 << INTEL_OUTPUT_ANALOG); |
@@ -744,7 +743,7 @@ static void psb_setup_outputs(struct drm_device *dev) | |||
744 | } | 743 | } |
745 | encoder->possible_crtcs = crtc_mask; | 744 | encoder->possible_crtcs = crtc_mask; |
746 | encoder->possible_clones = | 745 | encoder->possible_clones = |
747 | psb_intel_connector_clones(dev, clone_mask); | 746 | gma_connector_clones(dev, clone_mask); |
748 | } | 747 | } |
749 | } | 748 | } |
750 | 749 | ||