summaryrefslogtreecommitdiff
path: root/drivers/video
AgeCommit message (Collapse)Author
2014-03-19OMAPDSS: Add DT support to VENCTomi Valkeinen
Add DT support to VENC. In contrast to non-DT version, the DT version gets the invert-polarity and connector type via venc's endpoint, not from the connector. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Archit Taneja <archit@ti.com>
2014-03-19OMAPDSS: Add DT support to HDMITomi Valkeinen
Add DT support to HDMI driver. The only thing needed for DT support here is the of_match_table. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Archit Taneja <archit@ti.com>
2014-03-19OMAPDSS: Add DT support to DISPCTomi Valkeinen
Add DT support to DISPC. Only thing needed here is the of_match_table. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Archit Taneja <archit@ti.com>
2014-03-19OMAPDSS: Add DT support to DSSTomi Valkeinen
Add DT support for DSS. Contrary to the non-DT version, the DSS in DT mode contains DPI and SDI outputs, which better reflects the hardware. The non-DT code will be removed after all boards have been converted to DT, so there's no need to change the non-DT code to act the same way. The code for DPI and SDI needs to be refined later to make it possible to add multiple DPI ports. For now, handling just a single DPI port is enough for all the boards. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Archit Taneja <archit@ti.com>
2014-03-19OMAPDSS: Improve regulator names for DTTomi Valkeinen
The regulator names used for DSS components are somewhat ugly for DT use. As we're just adding DT support, it's simple to change the regulator names. This patch makes the DSS driver get the regulators with somewhat cleaner names when bootin with DT. For example, this allows us to define HDMI's VDDA regulator in the DT data as: vdda-supply = <...>; instead of vdda_hdmi_dac-supply = <...>; Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Archit Taneja <archit@ti.com>
2014-03-19OMAPDSS: add of helpersTomi Valkeinen
Add helpers to get ports and endpoints from DT data. These helpers parse v4l2 style ports and endpoints, but compared to the v4l2 helpers, these allow iterating ports and endpoints separately. This is a temporary solution until we get generic code to parse the ports and endpoints. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Archit Taneja <archit@ti.com>
2014-03-19OMAPFB: search for default display with DT aliasTomi Valkeinen
Improve the search for the default display in two ways: * compare the given display name to the display's alias * if no display name is given, look for "display0" DT alias Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Archit Taneja <archit@ti.com>
2014-03-19OMAPFB: clean up default display searchTomi Valkeinen
Separate the code for finding the default display into a function for clarity and to make it easier to extend it in the future. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Archit Taneja <archit@ti.com>
2014-03-19OMAPDSS: get dssdev->alias from DT aliasTomi Valkeinen
We currently create a "displayX" style alias name for all displays, using a number that is incremented for each registered display. With the new DSS device model there is no clear order in which the displays are registered, and thus the numbering is somewhat random. This patch improves the behavior for DT case so that if the displays have been assigned DT aliases, those aliases will be used as DSS aliases. This means that "display0" is always the one specified in the DT alias, and thus display0 can be used as default display in case the user didn't specify a default display. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Archit Taneja <archit@ti.com>
2014-03-19OMAPDSS: add 'label' support for DTTomi Valkeinen
Add support to get the label (i.e. a "nickname") for a display from the DT data. If there is no label defined, use the display's alias (e.g. 'display0') as a name. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Archit Taneja <archit@ti.com>
2014-03-17video: imxfb: Add DT default contrast control register property.Denis Carikli
Signed-off-by: Denis Carikli <denis@eukrea.com> Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Acked-by: Grant Likely <grant.likely@linaro.org> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-03-12video: atmel_lcdfb: ensure the hardware is initialized with the correct modeAntoine Ténart
If no driver takeover the atmel_lcdfb, the lcd won't be in a working state since atmel_lcdfb_set_par() will never be called. Enabling a driver which does, like fbcon, will call the function and put atmel_lcdfb in a working state. Fixes: b985172b328a (video: atmel_lcdfb: add device tree suport) Signed-off-by: Antoine Ténart <antoine.tenart@free-electrons.com> Reported-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Acked-by: Alexandre Belloni <alexandre.belloni@free-electrons.com> Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-03-07fbdev: vesafb: add dev->remove() callbackDavid Herrmann
If x86-sysfb platform-devices are removed from a system, we should properly unload vesafb. Otherwise, we end up releasing the parent while our vesa framebuffer is still running. This currently works just fine, but will cause problems on handover to real hw. So add the ->remove() callback and unregister vesafb. Signed-off-by: David Herrmann <dh.herrmann@gmail.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-03-07fbdev: efifb: add dev->remove() callbackDavid Herrmann
If x86-sysfb platform-devices are removed from a system, we should properly unload efifb. Otherwise, we end up releasing the parent while our efi framebuffer is still running. This currently works just fine, but will cause problems on handover to real hw. So add the ->remove() callback and unregister efifb. Signed-off-by: David Herrmann <dh.herrmann@gmail.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-03-07video: pxa3xx-gcu: switch to devres functionsDaniel Mack
Switch to devres allocators to clean up the error unwinding paths. Signed-off-by: Daniel Mack <zonque@gmail.com> Acked-by: Haojian Zhuang <haojian.zhuang@gmail.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-03-07video: pxa3xx-gcu: provide an empty .open callDaniel Mack
This is necessary in order to make the core set file->private_data to miscdev in use. We need that information later to dereference the container of the device, so we can get access to our private struct from other callbacks. Signed-off-by: Daniel Mack <zonque@gmail.com> Acked-by: Haojian Zhuang <haojian.zhuang@gmail.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-03-07video: pxa3xx-gcu: pass around struct device *Daniel Mack
Instead of passing around struct platform_device, use struct device. That saves one level of dereference. Also, call platform devices pdev, and provide a shortcut for &pdev->dev. Signed-off-by: Daniel Mack <zonque@gmail.com> Acked-by: Haojian Zhuang <haojian.zhuang@gmail.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-03-07video: pxa3xx-gcu: rename some symbolsDaniel Mack
Prefix some functions with more specific names. While at it, kill some stray newlines and other coding style related minor things. Signed-off-by: Daniel Mack <zonque@gmail.com> Acked-by: Haojian Zhuang <haojian.zhuang@gmail.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-03-07sisfb: fix 1280x720 resolution supportDan Carpenter
It uses the wrong mode index because there is no break statement. Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-03-06video: fbdev: uvesafb: Remove impossible code path in uvesafb_init_infoWang YanQing
Because uvesafb_vbe_init will fail when get zero avaiable modes, and we have checked the return value of uvesafb_vbe_init_mode, so it is impossible to pass NULL as mode into uvesafb_init_info. [ This patch fix warning report by fengguang.wu@intel.com "drivers/video/fbdev/uvesafb.c:1509 uvesafb_init_info() error: we previously assumed 'mode' could be null" ] Signed-off-by: Wang YanQing <udknight@gmail.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-03-06video: fbdev: uvesafb: Remove redundant NULL check in uvesafb_removeWang YanQing
Because uvesafb_par is allocated as part of fb_info in uvesafb_probe, so we don't need to do NULL check for both fb_info and uvesafb_par in uvesafb_remove. [ This patch also fix a warning report by fengguang.wu@intel.com "drivers/video/fbdev/uvesafb.c:1815 uvesafb_remove() warn: variable dereferenced before check 'par'" ] Signed-off-by: Wang YanQing <udknight@gmail.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-03-05fbdev: FB_OPENCORES should depend on HAS_DMAGeert Uytterhoeven
If NO_DMA=y: drivers/built-in.o: In function `ocfb_remove': ocfb.c:(.text+0x27fee): undefined reference to `dma_free_coherent' drivers/built-in.o: In function `ocfb_probe': ocfb.c:(.text+0x28418): undefined reference to `dma_alloc_coherent' ocfb.c:(.text+0x284d2): undefined reference to `dma_free_coherent' Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org> Acked-by: Stefan Kristiansson <stefan.kristiansson@saunalahti.fi> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-03-05OMAPDSS: convert pixel clock to common videomode styleTomi Valkeinen
omapdss has its own video-timings struct, but we want to move the common videomode. The first step is to change the omapdss's pixelclock unit from kHz to Hz. Also, omapdss uses "pixel_clock" field name, whereas the common videomode uses "pixelclock" field name. This patch changes the field name also, as that makes it easy to spot any non-converted pixel_clock uses. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-28hyperv-fb: kick off efifb earlyGerd Hoffmann
Remove firmware framebuffer before initializing hyperv-fb. Needed on gen2 virtual machines. Letting register_framebuffer handle the switchover results in efifb still being active while hyperv graphics are initialized, which in turn can make the linux kernel hang. Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com> Acked-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-02-28hyperv-fb: add support for generation 2 virtual machines.Gerd Hoffmann
UEFI-based generation 2 virtual machines support vmbus devices only. There is no pci bus. Thus they use a different mechanism for the graphics framebuffer: Instead of using the vga pci bar a chunk of memory muct be allocated from the hyperv mmio region declared using APCI. This patch implements support for it. Based on a patch by Haiyang Zhang <haiyangz@microsoft.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com> Acked-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-02-28OMAPDSS: Remove unused get_context_loss_count supportTomi Valkeinen
The omapdss driver no longer uses get_context_loss_count call, so we can remove it. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Archit Taneja <archit@ti.com>
2014-02-28OMAPDSS: use DISPC register to detect context lossTomi Valkeinen
Instead of relying on the OMAP specific omap_pm_get_dev_context_loss_count() to detect register context loss, we can achieve the same in a much simpler way by just observing the DISPC registers. We always set DISPC's load mode to LOAD_FRAME_ONLY, which is not the reset value. Thus we can just observe the load mode to see if we have lost register context. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com> Reviewed-by: Archit Taneja <archit@ti.com>
2014-02-28video: da8xx-fb: Use "SIMPLE_DEV_PM_OPS" macroManish Badarkhe
Update driver to use SIMPLE_DEV_PM_OPS macro for power management suspend and resume operations. Signed-off-by: Manish Badarkhe <badarkhe.manish@gmail.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-28video: imxfb: Convert to SIMPLE_DEV_PM_OPSAlexander Shiyan
Instead of assigning the pm_ops fields individually we can simply use SIMPLE_DEV_PM_OPS. Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-28video: imxfb: Resolve mismatch between backlight/contrastAlexander Shiyan
Currently, driver uses backlight class to control contrast value. This is not correct. This patch resolves this issue by removing backlight class from the driver and replace handling of LCDC PWM Contrast Control Register by contrast control through LCD class. Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-28video: imxfb: Use module_platform_driver()Alexander Shiyan
We have no reason to call fb_get_options() when registering module, so move this call in the probe() and convert the driver to use module_platform_driver() macro. Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-28video: imxfb: Remove unused fields from platform data structureAlexander Shiyan
Some fields in platform data structure is never used by boards. This patch removes these fields and as a result optimizes private driver structure a bit. Additionally patch removes backligh_power() callback, so if it will be needed in the future, this feature should be added as pwm{gpio,etc.}-regulator to the board code or in the DTS. Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-27x86, platforms: Remove SGI Visual WorkstationH. Peter Anvin
The SGI Visual Workstation seems to be dead; remove support so we don't have to continue maintaining it. Cc: Andrey Panin <pazke@donpac.ru> Cc: Michael Reed <mdr@sgi.com> Link: http://lkml.kernel.org/r/530CFD6C.7040705@zytor.com Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
2014-02-18Merge 3.14-rc3 into char-misc-nextGreg Kroah-Hartman
We need the fixes here for future mei and other patches. Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-02-14video: s6e8ax0: Use devm_* APIsSachin Kamat
devm_* APIs make the cleanup paths simpler. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-14video: exynos: Remove OF dependency for Exynos DPSachin Kamat
OF dependency can be removed as the driver does not actually depend on it at all. Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Acked-by: Jingoo Han <jg1.han@samsung.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-14video: Kconfig: Allow more broad selection of the imxfb framebuffer driver.Denis Carikli
Without that patch, a user can't select the imxfb driver when the i.MX25 and/or the i.MX27 device tree board are selected and that no boards that selects IMX_HAVE_PLATFORM_IMX_FB are compiled in. Cc: Eric Bénard <eric@eukrea.com> Cc: Jean-Christophe Plagniol-Villard <plagnioj@jcrosoft.com> Cc: Sascha Hauer <kernel@pengutronix.de> Cc: Tomi Valkeinen <tomi.valkeinen@ti.com> Cc: linux-arm-kernel@lists.infradead.org Cc: linux-fbdev@vger.kernel.org Signed-off-by: Denis Carikli <denis@eukrea.com> Acked-by: Shawn Guo <shawn.guo@linaro.org> Acked-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Acked-by: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-14video: exynos: Fix S6E8AX0 LCD driver build errorSachin Kamat
Enable S6E8AX0 LCD driver only if LCD_CLASS_DEVICE is a built-in driver. Else we get the following errors due to missing symbols: drivers/built-in.o: In function `s6e8ax0_probe': :(.text+0x51aec): undefined reference to `lcd_device_register' :(.text+0x51c44): undefined reference to `lcd_device_unregister' Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-11OMAPDSS: fix fck field typesTomi Valkeinen
'fck' field in dpi and sdi clock calculation struct is 'unsigned long long', even though it should be 'unsigned long'. This hasn't caused any issues so far. Fix the field's type. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-11OMAPDSS: DISPC: decimation rounding fixTomi Valkeinen
The driver uses DIV_ROUND_UP when calculating decimated width & height. For example, when decimating with 3, the width is calculated as: width = DIV_ROUND_UP(width, decim_x); This yields bad results for some values. For example, 800/3=266.666..., which is rounded to 267. When the input width is set to 267, and pixel increment is set to 3, this causes the dispc to read a line of 801 pixels, i.e. it reads a wrong pixel at the end of the line. Even more pressing, the above rounding causes a BUG() in pixinc(), as the value of 801 is used to calculate row increment, leading to a bad value being passed to pixinc(). This patch fixes the decimation by removing the DIV_ROUND_UP()s when calculating width and height for decimation. Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-11video: xilinxfb: Move xilinxfb_platform_data directly to the driverMichal Simek
No reason to have separate file in header in include/linux folder if this is purely driver specific structure. Signed-off-by: Michal Simek <michal.simek@xilinx.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-11video: imxfb: Use regulator API with LCD class for poweringAlexander Shiyan
This patch replaces custom lcd_power() callback with regulator API over LCD class. Signed-off-by: Alexander Shiyan <shc_work@mail.ru> Acked-by: Shawn Guo <shawn.guo@linaro.org> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-11tgafb: avoid restriction on modes with line length not a multiple of 64Mikulas Patocka
In tgafb there is a restriction that prevents the user from setting a videomode with line length not a multiple of 64 bytes (for example, 800x600 is not allowed). The reason for this restriction it that functions copyarea_line_8bpp and copyarea_line_32bpp can not handle a line length that is not a multiple of 64 bytes. This patch removes this restriction on mode setting and makes sure that the functions copyarea_line_8bpp and copyarea_line_32bpp are called only if line length is a multiple of 64 bytes. If we set a mode 800x600, the functions copyarea_line_8bpp and copyarea_line_32bpp are not used, generic functions for copying are used instead and it works just fine. Signed-off-by: Mikulas Patocka <mpatocka@redhat.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-11tgafb: fix data copyingMikulas Patocka
The functions for data copying copyarea_foreward_8bpp and copyarea_backward_8bpp are buggy, they produce screen corruption. This patch fixes the functions and moves the logic to one function "copyarea_8bpp". For simplicity, the function only handles copying that is aligned on 8 pixes. If we copy an unaligned area, generic function cfb_copyarea is used. Signed-off-by: Mikulas Patocka <mpatocka@redhat.com> Cc: stable@vger.kernel.org Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-11tgafb: fix mode setting with fbsetMikulas Patocka
Mode setting in the TGA driver is broken for these reasons: - info->fix.line_length is set just once in tgafb_init_fix function. If we change videomode, info->fix.line_length is not recalculated - so the video mode is changed but the screen is corrupted because of wrong info->fix.line_length. - info->fix.smem_len is set in tgafb_init_fix to the size of the default video mode (640x480). If we set a higher resolution, info->fix.smem_len is smaller than the current screen size, preventing the userspace program from mapping the framebuffer. This patch fixes it: - info->fix.line_length initialization is moved to tgafb_set_par so that it is recalculated with each mode change. - info->fix.smem_len is set to a fixed value representing the real amount of video ram (the values are taken from xfree86 driver). - add a check to tgafb_check_var to prevent us from setting a videomode that doesn't fit into videoram. - in tgafb_register, tgafb_init_fix is moved upwards, to be called before fb_find_mode (because fb_find_mode already needs the videoram size set in tgafb_init_fix). Signed-off-by: Mikulas Patocka <mpatocka@redhat.com> Cc: stable@vga.kernel.org Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-11mach64: fix cursor when character width is not a multiple of 8 pixelsMikulas Patocka
This patch fixes the hardware cursor on mach64 when font width is not a multiple of 8 pixels. If you load such a font, the cursor is expanded to the next 8-byte boundary and a part of the next character after the cursor is not visible. For example, when you load a font with 12-pixel width, the cursor width is 16 pixels and when the cursor is displayed, 4 pixels of the next character are not visible. The reason is this: atyfb_cursor is called with proper parameters to load an image that is 12-pixel wide. However, the number is aligned on the next 8-pixel boundary on the line "unsigned int width = (cursor->image.width + 7) >> 3;" and the whole function acts as it is was loading a 16-pixel image. This patch fixes it so that the value written to the framebuffer is padded with 0xaaaa (the transparent pattern) when the image size it not a multiple of 8 pixels. The transparent pattern causes that the cursor will not interfere with the next character. Signed-off-by: Mikulas Patocka <mpatocka@redhat.com> Cc: stable@vger.kernel.org Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-11atyfb: set FBINFO_READS_FASTMikulas Patocka
Set FBINFO_READS_FAST so that the console code uses scrolling instead of rewriting. This improves scrolling speed. A time to do ls -la /usr/bin: original patched 32bpp 4.9 3.6 24bpp 4.9 2.9 16bpp 4.9 2.1 8bpp 4.9 1.7 Signed-off-by: Mikulas Patocka <mpatocka@redhat.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-11mach64: use unaligned accessMikulas Patocka
This patch fixes mach64 to use unaligned access to the font bitmap. This fixes unaligned access warning on sparc64 when 14x8 font is loaded. On x86(64), unaligned access is handled in hardware, so both functions le32_to_cpup and get_unaligned_le32 perform the same operation. On RISC machines, unaligned access is not handled in hardware, so we better use get_unaligned_le32 to avoid the unaligned trap and warning. Signed-off-by: Mikulas Patocka <mpatocka@redhat.com> Cc: stable@vger.kernel.org Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-11atyfb: remove resolution limit 1600Mikulas Patocka
The card works fine in 1980x1080 resolution. Therefore, there is no need to limit the resolution to 1600 pixels. Signed-off-by: Mikulas Patocka <mpatocka@redhat.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2014-02-11framebuffer: fix cfb_copyareaMikulas Patocka
The function cfb_copyarea is buggy when the copy operation is not aligned on long boundary (4 bytes on 32-bit machines, 8 bytes on 64-bit machines). How to reproduce: - use x86-64 machine - use a framebuffer driver without acceleration (for example uvesafb) - set the framebuffer to 8-bit depth (for example fbset -a 1024x768-60 -depth 8) - load a font with character width that is not a multiple of 8 pixels note: the console-tools package cannot load a font that has width different from 8 pixels. You need to install the packages "kbd" and "console-terminus" and use the program "setfont" to set font width (for example: setfont Uni2-Terminus20x10) - move some text left and right on the bash command line and you get a screen corruption To expose more bugs, put this line to the end of uvesafb_init_info: info->flags |= FBINFO_HWACCEL_COPYAREA | FBINFO_READS_FAST; - Now framebuffer console will use cfb_copyarea for console scrolling. You get a screen corruption when console is scrolled. This patch is a rewrite of cfb_copyarea. It fixes the bugs, with this patch, console scrolling in 8-bit depth with a font width that is not a multiple of 8 pixels works fine. The cfb_copyarea code was very buggy and it looks like it was written and never tried with non-8-pixel font. Signed-off-by: Mikulas Patocka <mpatocka@redhat.com> Cc: stable@vger.kernel.org Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>