[Openchrome-devel] drm-openchrome: 3 commits - drivers/gpu/drm
Kevin Brace
kevinbrace at kemper.freedesktop.org
Thu Dec 29 23:12:24 UTC 2016
drivers/gpu/drm/via/via_crtc.c | 56 ++++++++++++++---------------------------
drivers/gpu/drm/via/via_drv.h | 4 +-
drivers/gpu/drm/via/via_fp.c | 8 +++++
3 files changed, 30 insertions(+), 38 deletions(-)
New commits:
commit 96830308ef5acbc2a74d799e4090ee8e444f778c
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Thu Dec 29 10:55:07 2016 -0800
Version bumped to 3.0.8
This version contains a temporary fix to FP (Flat Panel) not turning
off. Since it is a temporary fix, it may not work on all models.
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/drivers/gpu/drm/via/via_drv.h b/drivers/gpu/drm/via/via_drv.h
index dda8572..bc2ec5b 100644
--- a/drivers/gpu/drm/via/via_drv.h
+++ b/drivers/gpu/drm/via/via_drv.h
@@ -27,11 +27,11 @@
#define DRIVER_AUTHOR "The OpenChrome Project"
#define DRIVER_NAME "via"
#define DRIVER_DESC "OpenChrome DRM for VIA Technologies Chrome IGP"
-#define DRIVER_DATE "20161227"
+#define DRIVER_DATE "20161229"
#define DRIVER_MAJOR 3
#define DRIVER_MINOR 0
-#define DRIVER_PATCHLEVEL 7
+#define DRIVER_PATCHLEVEL 8
#include <linux/module.h>
commit eef95ac9abc2c715913a9acf421f615eaea29fb2
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Thu Dec 29 10:50:44 2016 -0800
Temporary fix to FP not turning off
While this fix is not 100% satisfactory, this commit will fix the
issue of FP (Flat Panel) not turning off. While there will have to
be a more permanent fix to this issue, for now, it solves the issue
for certain models.
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/drivers/gpu/drm/via/via_fp.c b/drivers/gpu/drm/via/via_fp.c
index c85c708..39158d6 100644
--- a/drivers/gpu/drm/via/via_fp.c
+++ b/drivers/gpu/drm/via/via_fp.c
@@ -125,6 +125,10 @@ via_enable_internal_lvds(struct drm_encoder *encoder)
/* Back-Light ON */
svga_wcrt_mask(VGABASE, 0xD3, BIT(1), BIT(1));
} else {
+ /* Turn on panel path. */
+ svga_wcrt_mask(VGABASE, 0x91, 0x00, BIT(5));
+ /* Turn on back light. */
+ svga_wcrt_mask(VGABASE, 0x91, 0x00, BIT(6));
/* Use hardware control power sequence. */
svga_wcrt_mask(VGABASE, 0xD3, 0x00, BIT(0));
/* Turn on back light and panel path. */
@@ -203,6 +207,10 @@ via_disable_internal_lvds(struct drm_encoder *encoder)
svga_wcrt_mask(VGABASE, 0xD4, 0x00, BIT(1));
/* Turn off back light and panel path. */
svga_wcrt_mask(VGABASE, 0xD3, 0xC0, BIT(7) | BIT(6));
+ /* Turn off back light. */
+ svga_wcrt_mask(VGABASE, 0x91, BIT(6), BIT(6));
+ /* Turn off panel path. */
+ svga_wcrt_mask(VGABASE, 0x91, BIT(5), BIT(5));
}
}
commit 42f4cea6d6539b589696958dbedc8110553a444e
Author: Kevin Brace <kevinbrace at gmx.com>
Date: Thu Dec 29 10:46:48 2016 -0800
Removal of dead code from via_iga*_crtc_dpms
Removed IGA1 code from via_iga2_crtc_dpms callback function and
IGA2 code from via_iga1_crtc_dpms callback function.
Signed-off-by: Kevin Brace <kevinbrace at gmx.com>
diff --git a/drivers/gpu/drm/via/via_crtc.c b/drivers/gpu/drm/via/via_crtc.c
index a4e16a6..344f30a 100644
--- a/drivers/gpu/drm/via/via_crtc.c
+++ b/drivers/gpu/drm/via/via_crtc.c
@@ -1055,29 +1055,21 @@ via_iga1_crtc_dpms(struct drm_crtc *crtc, int mode)
case DRM_MODE_DPMS_OFF:
if (crtc->dev->num_crtcs)
drm_vblank_pre_modeset(crtc->dev, iga->index);
- if (iga->index) {
- /* turn off CRT screen (IGA2) */
- svga_wcrt_mask(VGABASE, 0x6B, BIT(2), BIT(2));
- /* clear for TV clock */
- svga_wcrt_mask(VGABASE, 0x6C, 0x00, 0x0F);
- } else {
- /* turn off CRT screen (IGA1) */
- svga_wseq_mask(VGABASE, 0x01, BIT(5), BIT(5));
- /* clear for TV clock */
- svga_wcrt_mask(VGABASE, 0x6C, 0x00, 0xF0);
- }
+
+ /* turn off CRT screen (IGA1) */
+ svga_wseq_mask(VGABASE, 0x01, BIT(5), BIT(5));
+
+ /* clear for TV clock */
+ svga_wcrt_mask(VGABASE, 0x6C, 0x00, 0xF0);
break;
case DRM_MODE_DPMS_ON:
if (crtc->dev->num_crtcs)
drm_vblank_post_modeset(crtc->dev, iga->index);
- if (iga->index) {
- /* turn on CRT screen (IGA2) */
- svga_wcrt_mask(VGABASE, 0x6B, 0x00, BIT(2));
- } else {
- /* turn on CRT screen (IGA1) */
- svga_wseq_mask(VGABASE, 0x01, 0x00, BIT(5));
- }
+
+ /* turn on CRT screen (IGA1) */
+ svga_wseq_mask(VGABASE, 0x01, 0x00, BIT(5));
+
/* disable simultaneous */
svga_wcrt_mask(VGABASE, 0x6B, 0x00, BIT(3));
drm_mode_crtc_load_lut(crtc);
@@ -1347,29 +1339,21 @@ via_iga2_crtc_dpms(struct drm_crtc *crtc, int mode)
case DRM_MODE_DPMS_OFF:
if (crtc->dev->num_crtcs)
drm_vblank_pre_modeset(crtc->dev, iga->index);
- if (iga->index) {
- /* turn off CRT screen (IGA2) */
- svga_wcrt_mask(VGABASE, 0x6B, BIT(2), BIT(2));
- /* clear for TV clock */
- svga_wcrt_mask(VGABASE, 0x6C, 0x00, 0x0F);
- } else {
- /* turn off CRT screen (IGA1) */
- svga_wseq_mask(VGABASE, 0x01, BIT(5), BIT(5));
- /* clear for TV clock */
- svga_wcrt_mask(VGABASE, 0x6C, 0x00, 0xF0);
- }
+
+ /* turn off CRT screen (IGA2) */
+ svga_wcrt_mask(VGABASE, 0x6B, BIT(2), BIT(2));
+
+ /* clear for TV clock */
+ svga_wcrt_mask(VGABASE, 0x6C, 0x00, 0x0F);
break;
case DRM_MODE_DPMS_ON:
if (crtc->dev->num_crtcs)
drm_vblank_post_modeset(crtc->dev, iga->index);
- if (iga->index) {
- /* turn on CRT screen (IGA2) */
- svga_wcrt_mask(VGABASE, 0x6B, 0x00, BIT(2));
- } else {
- /* turn on CRT screen (IGA1) */
- svga_wseq_mask(VGABASE, 0x01, 0x00, BIT(5));
- }
+
+ /* turn on CRT screen (IGA2) */
+ svga_wcrt_mask(VGABASE, 0x6B, 0x00, BIT(2));
+
/* disable simultaneous */
svga_wcrt_mask(VGABASE, 0x6B, 0x00, BIT(3));
drm_mode_crtc_load_lut(crtc);
More information about the Openchrome-devel
mailing list