drm/udl: fix stride issues scanning out stride != width*bpp
authorDave Airlie <airlied@redhat.com>
Thu, 1 Nov 2012 03:47:09 +0000 (13:47 +1000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 17 Nov 2012 21:16:03 +0000 (13:16 -0800)
commit4b51c17efde8501badb4bf7355172eb262407ad8
treee9b7ed3ad873f092399c98e863c07e810518306a
parentf93a53b38d63be316156ad8a332ed982ad33a59d
drm/udl: fix stride issues scanning out stride != width*bpp

commit 3916e1d71b62b120888aa50bcc8d9a6200fc19a7 upstream.

When buffer sharing with the i915 and using a 1680x1050 monitor,
the i915 gives is a 6912 buffer for the 6720 width, the code doesn't
render this properly as it uses one value to set the base address for
reading from the vmap and for where to start on the device.

This fixes it by calculating the values correctly for the device and
for the pixmap. No idea how I haven't seen this before now.

Signed-off-by: Dave Airlie <airlied@redhat.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpu/drm/udl/udl_drv.h
drivers/gpu/drm/udl/udl_fb.c
drivers/gpu/drm/udl/udl_transfer.c