aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/nouveau/nouveau_hw.c2
-rw-r--r--drivers/gpu/drm/nouveau/nv04_crtc.c8
-rw-r--r--drivers/gpu/drm/nouveau/nvreg.h2
3 files changed, 11 insertions, 1 deletions
diff --git a/drivers/gpu/drm/nouveau/nouveau_hw.c b/drivers/gpu/drm/nouveau/nouveau_hw.c
index 053edf9d2f67..ba896e54b799 100644
--- a/drivers/gpu/drm/nouveau/nouveau_hw.c
+++ b/drivers/gpu/drm/nouveau/nouveau_hw.c
@@ -900,6 +900,7 @@ nv_save_state_ext(struct drm_device *dev, int head,
900 } 900 }
901 /* NV11 and NV20 don't have this, they stop at 0x52. */ 901 /* NV11 and NV20 don't have this, they stop at 0x52. */
902 if (nv_gf4_disp_arch(dev)) { 902 if (nv_gf4_disp_arch(dev)) {
903 rd_cio_state(dev, head, regp, NV_CIO_CRE_42);
903 rd_cio_state(dev, head, regp, NV_CIO_CRE_53); 904 rd_cio_state(dev, head, regp, NV_CIO_CRE_53);
904 rd_cio_state(dev, head, regp, NV_CIO_CRE_54); 905 rd_cio_state(dev, head, regp, NV_CIO_CRE_54);
905 906
@@ -1003,6 +1004,7 @@ nv_load_state_ext(struct drm_device *dev, int head,
1003 nouveau_wait_eq(dev, 650000000, NV_PRMCIO_INP0__COLOR, 0x8, 0x0); 1004 nouveau_wait_eq(dev, 650000000, NV_PRMCIO_INP0__COLOR, 0x8, 0x0);
1004 } 1005 }
1005 1006
1007 wr_cio_state(dev, head, regp, NV_CIO_CRE_42);
1006 wr_cio_state(dev, head, regp, NV_CIO_CRE_53); 1008 wr_cio_state(dev, head, regp, NV_CIO_CRE_53);
1007 wr_cio_state(dev, head, regp, NV_CIO_CRE_54); 1009 wr_cio_state(dev, head, regp, NV_CIO_CRE_54);
1008 1010
diff --git a/drivers/gpu/drm/nouveau/nv04_crtc.c b/drivers/gpu/drm/nouveau/nv04_crtc.c
index 3c78bc81357e..f1a3ae491995 100644
--- a/drivers/gpu/drm/nouveau/nv04_crtc.c
+++ b/drivers/gpu/drm/nouveau/nv04_crtc.c
@@ -376,7 +376,10 @@ nv_crtc_mode_set_vga(struct drm_crtc *crtc, struct drm_display_mode *mode)
376 */ 376 */
377 377
378 /* framebuffer can be larger than crtc scanout area. */ 378 /* framebuffer can be larger than crtc scanout area. */
379 regp->CRTC[NV_CIO_CRE_RPC0_INDEX] = XLATE(fb->pitch / 8, 8, NV_CIO_CRE_RPC0_OFFSET_10_8); 379 regp->CRTC[NV_CIO_CRE_RPC0_INDEX] =
380 XLATE(fb->pitch / 8, 8, NV_CIO_CRE_RPC0_OFFSET_10_8);
381 regp->CRTC[NV_CIO_CRE_42] =
382 XLATE(fb->pitch / 8, 11, NV_CIO_CRE_42_OFFSET_11);
380 regp->CRTC[NV_CIO_CRE_RPC1_INDEX] = mode->crtc_hdisplay < 1280 ? 383 regp->CRTC[NV_CIO_CRE_RPC1_INDEX] = mode->crtc_hdisplay < 1280 ?
381 MASK(NV_CIO_CRE_RPC1_LARGE) : 0x00; 384 MASK(NV_CIO_CRE_RPC1_LARGE) : 0x00;
382 regp->CRTC[NV_CIO_CRE_LSR_INDEX] = XLATE(horizBlankEnd, 6, NV_CIO_CRE_LSR_HBE_6) | 385 regp->CRTC[NV_CIO_CRE_LSR_INDEX] = XLATE(horizBlankEnd, 6, NV_CIO_CRE_LSR_HBE_6) |
@@ -824,8 +827,11 @@ nv04_crtc_do_mode_set_base(struct drm_crtc *crtc,
824 regp->CRTC[NV_CIO_CR_OFFSET_INDEX] = drm_fb->pitch >> 3; 827 regp->CRTC[NV_CIO_CR_OFFSET_INDEX] = drm_fb->pitch >> 3;
825 regp->CRTC[NV_CIO_CRE_RPC0_INDEX] = 828 regp->CRTC[NV_CIO_CRE_RPC0_INDEX] =
826 XLATE(drm_fb->pitch >> 3, 8, NV_CIO_CRE_RPC0_OFFSET_10_8); 829 XLATE(drm_fb->pitch >> 3, 8, NV_CIO_CRE_RPC0_OFFSET_10_8);
830 regp->CRTC[NV_CIO_CRE_42] =
831 XLATE(drm_fb->pitch / 8, 11, NV_CIO_CRE_42_OFFSET_11);
827 crtc_wr_cio_state(crtc, regp, NV_CIO_CRE_RPC0_INDEX); 832 crtc_wr_cio_state(crtc, regp, NV_CIO_CRE_RPC0_INDEX);
828 crtc_wr_cio_state(crtc, regp, NV_CIO_CR_OFFSET_INDEX); 833 crtc_wr_cio_state(crtc, regp, NV_CIO_CR_OFFSET_INDEX);
834 crtc_wr_cio_state(crtc, regp, NV_CIO_CRE_42);
829 835
830 /* Update the framebuffer location. */ 836 /* Update the framebuffer location. */
831 regp->fb_start = nv_crtc->fb.offset & ~3; 837 regp->fb_start = nv_crtc->fb.offset & ~3;
diff --git a/drivers/gpu/drm/nouveau/nvreg.h b/drivers/gpu/drm/nouveau/nvreg.h
index fe0f253089ac..bbfb1a68fb11 100644
--- a/drivers/gpu/drm/nouveau/nvreg.h
+++ b/drivers/gpu/drm/nouveau/nvreg.h
@@ -277,6 +277,8 @@
277# define NV_CIO_CRE_EBR_VDE_11 2:2 277# define NV_CIO_CRE_EBR_VDE_11 2:2
278# define NV_CIO_CRE_EBR_VRS_11 4:4 278# define NV_CIO_CRE_EBR_VRS_11 4:4
279# define NV_CIO_CRE_EBR_VBS_11 6:6 279# define NV_CIO_CRE_EBR_VBS_11 6:6
280# define NV_CIO_CRE_42 0x42
281# define NV_CIO_CRE_42_OFFSET_11 6:6
280# define NV_CIO_CRE_43 0x43 282# define NV_CIO_CRE_43 0x43
281# define NV_CIO_CRE_44 0x44 /* head control */ 283# define NV_CIO_CRE_44 0x44 /* head control */
282# define NV_CIO_CRE_CSB 0x45 /* colour saturation boost */ 284# define NV_CIO_CRE_CSB 0x45 /* colour saturation boost */