[Openchrome-devel] [PATCH 2/2] via: Add missing magic value to IGA1 fetch count
Ondrej Zary
linux
Thu Aug 16 03:27:24 PDT 2012
Fetch count for IGA1 is missing magic "+4" that is called
IGA1_FETCH_COUNT_PATCH_VALUE in viafb. This causes screen to be distorted
at least on K8M890CE.
Signed-off-by: Ondrej Zary <linux at rainbow-software.org>
--- a/drivers/gpu/drm/via/via_display.c
+++ b/drivers/gpu/drm/via/via_display.c
@@ -784,7 +784,8 @@ via_iga1_mode_set_base_atomic(struct drm_crtc *crtc,
struct drm_framebuffer *fb,
/* Load Fetch registers */
pitch = ALIGN((crtc->mode.hdisplay * fb->bits_per_pixel >> 3), 16) >> 4;
- load_value_to_registers(VGABASE, &iga->fetch, pitch);
+ /* magic "+4" is from viafb IGA1_FETCH_COUNT_PATCH_VALUE */
+ load_value_to_registers(VGABASE, &iga->fetch, pitch + 4);
if ((state == ENTER_ATOMIC_MODE_SET) ||
crtc->fb->pitches[0] != fb->pitches[0]) {
--
Ondrej Zary
More information about the Openchrome-devel
mailing list