summaryrefslogtreecommitdiff
path: root/common/lcd.c
Commit message (Collapse)AuthorAgeLines
* lcd: refactor lcd console stuff into its own fileNikita Kiryanov2015-01-10-229/+0
| | | | | | | | | | | | | common/lcd.c is a mix of code portions that do different but related things. To improve modularity, the various code portions should be split into their own modules. Separate lcd console code into its own file. Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il> Cc: Anatolij Gustschin <agust@denx.de> Cc: Simon Glass <sjg@chromium.org> Cc: Stephen Warren <swarren@wwwdotorg.org> Acked-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>
* lcd: make lcd_drawchars() independant of lcd_baseNikita Kiryanov2015-01-10-5/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | lcd_logo() has the following return value: #if defined(CONFIG_LCD_LOGO) && !defined(CONFIG_LCD_INFO_BELOW_LOGO) return (void *)((ulong)lcd_base + BMP_LOGO_HEIGHT * lcd_line_length); #else return (void *)lcd_base; #endif This return value gets assigned to lcd_console_address. lcd_console_address is not assigned or modified anywhere else. Thus: #if defined(CONFIG_LCD_LOGO) && !defined(CONFIG_LCD_INFO_BELOW_LOGO): y' = BMP_LOGO_HEIGHT + y; lcd_base + y' * lcd_line_length == lcd_base + (BMP_LOGO_HEIGHT + y) * lcd_line_length == lcd_base + BMP_LOGO_HEIGHT * lcd_line_length + y * lcd_line_length == lcd_console_address + y * lcd_line_length #else lcd_base + y * lcd_line_length == lcd_console_address + y * lcd_line_length #endif This is a preparatory step for extracting lcd console code into its own file. Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il> Cc: Anatolij Gustschin <agust@denx.de> Cc: Simon Glass <sjg@chromium.org>
* lcd: introduce getters for bg/fg colorNikita Kiryanov2015-01-10-9/+22
| | | | | | | | | | | | | Introduce lcd_getbgcolor() and lcd_getfgcolor(), and use them where applicable. This is a preparatory step for extracting lcd console code into its own file. Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il> Cc: Anatolij Gustschin <agust@denx.de> Cc: Simon Glass <sjg@chromium.org> Acked-by: Simon Glass <sjg@chromium.org>
* lcd: get rid of COLOR_MASKNikita Kiryanov2015-01-10-8/+6
| | | | | | | | | | | | | | COLOR_MASK macro doesn't do anything; Remove it to reduce visual complexity. This is a preparatory step for extracting lcd console code into its own file. Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il> Cc: Anatolij Gustschin <agust@denx.de> Cc: Simon Glass <sjg@chromium.org> Acked-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>
* lcd: expand console apiNikita Kiryanov2015-01-10-9/+26
| | | | | | | | | | | | | | Introduce set_console_row(), set_console_col(), and lcd_init_console(). Use these functions in lcd functions: lcd_init(), lcd_clear(), lcd_logo(). This is a preparatory step for extracting lcd console code into its own file. Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il> Cc: Anatolij Gustschin <agust@denx.de> Cc: Simon Glass <sjg@chromium.org> Acked-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>
* lcd: replace CONSOLE_(ROWS|COLS) with variablesNikita Kiryanov2015-01-10-17/+18
| | | | | | | | | | | | | | Replace CONSOLE_(ROWS|COLS) macros with variables, and assign the original macro values. This is a preparatory step for extracting lcd console code into its own file. Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il> Cc: Anatolij Gustschin <agust@denx.de> Cc: Simon Glass <sjg@chromium.org> Acked-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>
* lcd: rename console_(row|col)Nikita Kiryanov2015-01-10-27/+27
| | | | | | | | | | | | | Rename console_(row|col) to console_curr_(row|col) to better distinguish it from console_(rows|cols). This is a preparatory step for extracting lcd console code into its own file. Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il> Cc: Simon Glass <sjg@chromium.org> Cc: Anatolij Gustschin <agust@denx.de> Acked-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>
* lcd: remove LCD_MONOCHROMENikita Kiryanov2015-01-10-28/+2
| | | | | | | | | No one is using LCD_MONOCHROME; remove related code. Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il> Cc: Wolfgang Denk <wd@denx.de> Cc: Anatolij Gustschin <agust@denx.de> Acked-by: Simon Glass <sjg@chromium.org>
* lcd: cleanup lcd_drawcharsNikita Kiryanov2015-01-10-13/+1
| | | | | | | | | Remove code duplication from lcd_drawchars(). Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il> Cc: Anatolij Gustschin <agust@denx.de> Cc: Simon Glass <sjg@chromium.org> Acked-by: Simon Glass <sjg@chromium.org>
* lcd: remove CONFIG_SYS_INVERT_COLORSNikita Kiryanov2015-01-10-8/+0
| | | | | | | | | No one is using CONFIG_SYS_INVERT_COLORS; remove related code. Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il> Cc: Simon Glass <sjg@chromium.org> Cc: Anatolij Gustschin <agust@denx.de> Acked-by: Simon Glass <sjg@chromium.org>
* ARM: rpi: rename rpi_b to rpiStephen Warren2014-12-08-1/+1
| | | | | | | | | The U-Boot port runs on a variety of RPi models, not just the B. So, rename the port to something slightly more generic. Signed-off-by: Stephen Warren <swarren@wwwdotorg.org> Reviewed-by: Simon Glass <sjg@chromium.org> Tested-by: Simon Glass <sjg@chromium.org>
* common/lcd: Make lcd_dt_simplefb_configure_node use fdt_setup_simplefb_nodeHans de Goede2014-11-25-42/+5
| | | | | | | | | Change lcd_dt_simplefb_configure_node into a wrapper around the new generic fdt_setup_simplefb_node helper function. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Tested-by: Stephen Warren <swarren@wwwdotorg.org> Acked-by: Simon Glass <sjg@chromium.org>
* linux/kernel.h: sync min, max, min3, max3 macros with LinuxMasahiro Yamada2014-11-23-3/+3
| | | | | | | | | | | | | | | | | | | | U-Boot has never cared about the type when we get max/min of two values, but Linux Kernel does. This commit gets min, max, min3, max3 macros synced with the kernel introducing type checks. Many of references of those macros must be fixed to suppress warnings. We have two options: - Use min, max, min3, max3 only when the arguments have the same type (or add casts to the arguments) - Use min_t/max_t instead with the appropriate type for the first argument Signed-off-by: Masahiro Yamada <yamada.m@jp.panasonic.com> Acked-by: Pavel Machek <pavel@denx.de> Acked-by: Lukasz Majewski <l.majewski@samsung.com> Tested-by: Lukasz Majewski <l.majewski@samsung.com> [trini: Fixup arch/blackfin/lib/string.c] Signed-off-by: Tom Rini <trini@ti.com>
* powerpc: remove orphaned boards mcc200 and prs200Nikita Kiryanov2014-11-12-23/+1
| | | | | | | | | | | | | mcc200 and prs200 are old and have no maintainer. Remove the boards. This also removes the mcc200 specific 1bpp BMP support from common/lcd.c Cc: Wolfgang Denk <wd@denx.de> Cc: Anatolij Gustschin <agust@denx.de> Cc: Masahiro Yamada <yamada.m@jp.panasonic.com> Cc: York Sun <yorksun@freescale.com> Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il>
* kconfig: arm: introduce symbol for ARM CPUsGeorges Savoundararadj2014-10-29-1/+0
| | | | | | | | | | | | | | | | | This commit introduces a Kconfig symbol for each ARM CPU: CPU_ARM720T, CPU_ARM920T, CPU_ARM926EJS, CPU_ARM946ES, CPU_ARM1136, CPU_ARM1176, CPU_V7, CPU_PXA, CPU_SA1100. Also, it adds the CPU feature Kconfig symbol HAS_VBAR which is selected for CPU_ARM1176 and CPU_V7. For each target, the corresponding CPU is selected and the definition of SYS_CPU in the corresponding Kconfig file is removed. Also, it removes redundant "string" type in some Kconfig files. Signed-off-by: Georges Savoundararadj <savoundg@gmail.com> Acked-by: Albert ARIBAUD <albert.u.boot@aribaud.net> Cc: Masahiro Yamada <yamada.m@jp.panasonic.com>
* lcd: Fix build error with CONFIG_LCD_BMP_RLE8Simon Glass2014-10-16-2/+2
| | | | | | | | Add a block to avoid a build error with the variable declaration. Enable the option on sandbox to prevent an error being introduced in future. Signed-off-by: Simon Glass <sjg@chromium.org>
* lcd: support displaying 24bpp BMPs on >= 24bpp LCDsHannes Petermaier2014-08-11-3/+20
| | | | | | | | | | most todays LCDs support 32bpp e.g. the framebuffer memory is 32bpp organized. To support 24bpp BMPs we need to take only 3 byte from the bpp and set one byte from the FB to 0. Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at>
* lcd: remove unused lcd_puts_xyJeroen Hofstee2014-08-11-10/+0
| | | | | | | | prevents a clang warning that the function is never used. cc: agust@denx.de Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl>
* lcd: cleanup unused functionsHannes Petermaier2014-08-10-16/+1
| | | | | | | | | | | | | This patch removes following two functions: - lcd_getbgcolor(...) not used somewhere outside lcd.c, internally we use now the global variable lcd_color_bg (was return value of function before) - lcd_getfgcolor(...) not used in any place of u-boot Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at> [agust: rebased] Signed-off-by: Anatolij Gustschin <agust@denx.de>
* Add support for 32-bit organized framebuffersHannes Petermaier2014-08-10-3/+32
| | | | | | | - Adds support for 32-bit organized framebuffers to the LCD-framework. Signed-off-by: Hannes Petermaier <oe5hpm@oevsv.at> Cc: agust@denx.de
* stdio: Pass device pointer to stdio methodsSimon Glass2014-07-23-2/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | At present stdio device functions do not get any clue as to which stdio device is being acted on. Some implementations go to great lengths to work around this, such as defining a whole separate set of functions for each possible device. For driver model we need to associate a stdio_dev with a device. It doesn't seem possible to continue with this work-around approach. Instead, add a stdio_dev pointer to each of the stdio member functions. Note: The serial drivers have the same problem, but it is not strictly necessary to fix that to get driver model running. Also, if we convert serial over to driver model the problem will go away. Code size increases by 244 bytes for Thumb2 and 428 for PowerPC. 22: stdio: Pass device pointer to stdio methods arm: (for 2/2 boards) all +244.0 bss -4.0 text +248.0 powerpc: (for 1/1 boards) all +428.0 text +428.0 Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Marek Vasut <marex@denx.de> Reviewed-by: Marek Vasut <marex@denx.de>
* sandbox: Add LCD driverSimon Glass2014-03-17-4/+17
| | | | | | | | | | | | | Add a simple LCD driver which uses SDL to display the image. We update the image regularly, while still providing for reasonable performance. Adjust the common lcd code to support sandbox. For command-line runs we do not want the LCD to be displayed, so add a --show_lcd option to enable it. Tested-by: Che-Liang Chiou <clchiou@chromium.org> Signed-off-by: Simon Glass <sjg@chromium.org>
* common: lcd.c: fix data abort exception when try to access bmp headerPrzemyslaw Marczak2014-02-03-14/+13
| | | | | | | | | | | | | Changes: - le16_to_cpu() to get_unaligned_le16() - le32_to_cpu() to get_unaligned_le32() when access fields in struct bmp header. This changes avoids data abort exception caused by unaligned data access. Signed-off-by: Przemyslaw Marczak <p.marczak@samsung.com> Acked-by: Anatolij Gustschin <agust@denx.de> Signed-off-by: Minkyu Kang <mk7.kang@samsung.com>
* lcd: allow overriding lcd_get_size()Anatolij Gustschin2013-11-12-3/+7
| | | | | | | | | | | | | | Remove the redundant lcd_line_length initialisation which sneaked in when an earlier version of the patch of commit 6d330719 has been rebased. Some lcd drivers need to setup lcd_line_length not from the panel_info parameters but by different means. Make the lcd_get_size() weak to allow setting lcd_line_length in a driver specific way. Signed-off-by: Anatolij Gustschin <agust@denx.de> Cc: Stephen Warren <swarren@wwwdotorg.org>
* Coding Style cleanup: remove trailing white spaceWolfgang Denk2013-10-14-1/+1
| | | | Signed-off-by: Wolfgang Denk <wd@denx.de>
* video: Encapsulate font in video_font_data.hMarek Vasut2013-08-12-1/+0
| | | | | | | | | | | | This patch moves all the font configuration values into video_font_data.h so they are all in the right place with the font. The video_font.h now only includes video_font_data.h and will allow us to select and include different font once more fonts are added. Signed-off-by: Marek Vasut <marex@denx.de> Cc: Anatolij Gustschin <agust@denx.de> [agust: fixed build warning for mcc200] Signed-off-by: Anatolij Gustschin <agust@denx.de>
* Add GPL-2.0+ SPDX-License-Identifier to source filesWolfgang Denk2013-07-24-17/+1
| | | | | | Signed-off-by: Wolfgang Denk <wd@denx.de> [trini: Fixup common/cmd_io.c] Signed-off-by: Tom Rini <trini@ti.com>
* video: consolidate splash screen alignment codeAnatolij Gustschin2013-07-08-17/+2
| | | | | | | | | | Code for checking "splashpos" environment variable is duplicated in drivers, move it to the common function. Call this function also in the bmp display command to consider "splashpos" settings. Signed-off-by: Anatolij Gustschin <agust@denx.de> Acked-by: Otavio Salvador <otavio@ossystems.com.br>
* video: lcd: Add CONFIG_SPLASH_SCREEN_PREPARE support to CONFIG_VIDEORobert Winkler2013-07-01-13/+3
| | | | | | | | Create splash.c/h to put the function and any future common splash screen code in. Signed-off-by: Robert Winkler <robert.winkler@boundarydevices.com> Acked-by: Igor Grinberg <grinberg@compulab.co.il>
* lcd: remove unaligned access in lcd_dt_simplefb_configure_node()Stephen Warren2013-07-01-3/+3
| | | | | | | | | | | | | Some ARM compilers may emit code that makes unaligned accesses when faced with constructs such as: const char format[] = "r5g6b5"; Make this data static since it doesn't chagne; the compiler will simply place it into the .rodata section directly, and avoid any unaligned run- time initialization. Signed-off-by: Stephen Warren <swarren@nvidia.com>
* lcd: add functions to set up simplefb device treeStephen Warren2013-06-05-0/+87
| | | | | | | | | | | | | | | | simple-framebuffer is a new device tree binding that describes a pre- configured frame-buffer memory region and its format. The Linux kernel contains a driver that supports this binding. Implement functions to create a DT node (or fill in an existing node) with parameters that describe the framebuffer format that U-Boot is using. This will be immediately used by the Raspberry Pi board in U-Boot, and likely will be used by the Samsung ARM ChromeBook support soon too. It could well be used by many other boards (e.g. Tegra boards with built-in LCD panels, which aren't yet supported by the Linux kernel). Signed-off-by: Stephen Warren <swarren@wwwdotorg.org> Acked-by: Simon Glass <sjg@chromium.org>
* video: bcm2835: fix build issuesAnatolij Gustschin2013-03-29-0/+12
| | | | | | | | | After merging LCD patches for v2013.04 the bcm2835 video driver building is broken due to removal of many global variables. Fix the driver. Signed-off-by: Anatolij Gustschin <agust@denx.de> Cc: Stephen Warren <swarren@wwwdotorg.org>
* Merge branch 'for-v2013.04'Anatolij Gustschin2013-03-29-57/+74
|\ | | | | | | | | | | | | Conflicts: drivers/video/Makefile Signed-off-by: Anatolij Gustschin <agust@denx.de>
| * Fix bitmap offsets for non 8-bit LCDsAndre Renaud2013-03-21-3/+4
| | | | | | | | | | | | | | Currently bitmap logos don't interpret the X coordinate correctly if the bpp is anything other than 8. Signed-off-by: Andre Renaud <andre@bluewatersys.com>
| * common/lcd.c: move the macro's to the c fileJeroen Hofstee2013-03-21-0/+28
| | | | | | | | | | | | | | | | Hide the console macros since some reference global data which is no longer present. cc: Anatolij Gustschin <agust@denx.de> Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl>
| * common/lcd: cosmetic: clean up a bitJeroen Hofstee2013-03-21-52/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Make the brackets of the function calls more consistent - Remove really unnecessary brackets - Removes the extern from the function definitions - Remove curly brackets from single line statements - Remove lcd_setmem proto since it is already in common.h - Cleanup comments, remove useless comments - Remove NOT_USED_SO_FAR ifdef - Cleanup coding style cc: Anatolij Gustschin <agust@denx.de> Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl> [agust: rebased the original patch] Signed-off-by: Anatolij Gustschin <agust@denx.de>
| * common/lcd.c: remove global lcd_baseJeroen Hofstee2013-03-21-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | lcd_base is available as gd->fb_base as well, there is no need to keep a seperate copy. For completeness the ack of Bo Shen is for the atmel part. Cc: Alessandro Rubini <rubini@unipv.it> Cc: Anatolij Gustschin <agust@denx.de> Cc: Bo Shen <voice.shen@atmel.com> Cc: Haavard Skinnemoen <haavard.skinnemoen@atmel.com> Cc: Kyungmin Park <kyungmin.park@samsung.com> Cc: Marek Vasut <marek.vasut@gmail.com> Cc: Minkyu Kang <mk7.kang@samsung.com> Cc: Nikita Kiryanov <nikita@compulab.co.il> Cc: Simon Glass <sjg@chromium.org> Cc: Stelian Pop <stelian@popies.net> Cc: Tom Warren <twarren@nvidia.com> Acked-by: Bo Shen <voice.shen@atmel.com> Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl> [agust: also fix cm_t35 board while rebasing] Signed-off-by: Anatolij Gustschin <agust@denx.de>
| * common/lcd.c: cleanup use of global variablesJeroen Hofstee2013-03-21-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | console_col, console_row, lcd_line_length, lcd_console_address had to be declared in board / driver specific code, but were not actually used there on many boards. Get rid of the global variables. for completeness, the ack of Bo Shen is for the atmel part Cc: Alessandro Rubini <rubini@unipv.it> Cc: Anatolij Gustschin <agust@denx.de> Cc: Bo Shen <voice.shen@atmel.com> Cc: Kyungmin Park <kyungmin.park@samsung.com> Cc: Marek Vasut <marek.vasut@gmail.com> Cc: Minkyu Kang <mk7.kang@samsung.com> Cc: Nikita Kiryanov <nikita@compulab.co.il> Cc: Simon Glass <sjg@chromium.org> Cc: Stelian Pop <stelian@popies.net> Cc: Tom Warren <twarren@nvidia.com> Acked-by: Bo Shen <voice.shen@atmel.com> Signed-off-by: Jeroen Hofstee <jeroen@myspectrum.nl> [agust: rebased and fixed cm_t35 board] Signed-off-by: Anatolij Gustschin <agust@denx.de>
| * common/lcd.c: cleanup use of global variablesWolfgang Denk2013-03-21-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | lcd_color_fg and lcd_color_bg had to be declared in board specific code, but were not actually used there; in addition, we have getter / setter functions for these, which were not used either. Get rid of the global variables, and use the getter function where needed (so far no setter calls are needed). Signed-off-by: Wolfgang Denk <wd@denx.de> Cc: Alessandro Rubini <rubini@unipv.it> Cc: Anatolij Gustschin <agust@denx.de> Cc: Bo Shen <voice.shen@atmel.com> Cc: Haavard Skinnemoen <haavard.skinnemoen@atmel.com> Cc: Kyungmin Park <kyungmin.park@samsung.com> Cc: Marek Vasut <marek.vasut@gmail.com> Cc: Minkyu Kang <mk7.kang@samsung.com> Cc: Nikita Kiryanov <nikita@compulab.co.il> Cc: Simon Glass <sjg@chromium.org> Cc: Stelian Pop <stelian@popies.net> Cc: Tom Warren <twarren@nvidia.com> Acked-by: Simon Glass <sjg@chromium.org> Acked-by: Jeroen Hofstee <jeroen@myspectrum.nl> [agust: also fixed cm_t35 board while rebasing] Signed-off-by: Anatolij Gustschin <agust@denx.de>
* | lcd: calculate line_length after lcd_ctrl_init()Stephen Warren2013-03-20-2/+2
|/ | | | | | | | | | | | | | | | | | When an LCD driver is actually driving a regular external display, e.g. an HDMI monitor, the display resolution might not be known until the display controller has initialized, i.e. during lcd_ctrl_init(). However, lcd.c calculates lcd_line_length before calling this function, thus relying on a hard-coded resolution in struct panel_info. Instead, defer this calculation until after lcd_ctrl_init() has had the chance to dynamically determine the resolution. This needs to happen before lcd_clear(), since the value is used there. grep indicates that no code outside lcd.c uses this lcd_line_length; in particular, no lcd_ctrl_init() implementations read it. Signed-off-by: Stephen Warren <swarren@wwwdotorg.org> Acked-by: Anatolij Gustschin <agust@denx.de>
* lcd: implement a callback for splashimageNikita Kiryanov2013-03-11-0/+26
| | | | | | | | | | | | | On some architectures certain values of splashimage will lead to a data abort exception. Document the problem, and implement a callback for splashimage to reject such values. Cc: Anatolij Gustschin <agust@denx.de> Cc: Wolfgang Denk <wd@denx.de> Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il> Acked-by: Igor Grinberg <grinberg@compulab.co.il>
* lcd: add option for board specific splash screen preparationNikita Kiryanov2013-03-08-0/+15
| | | | | | | | | | | | | | | | | | | | | Currently there is no logical place to put the code that prepares the splash image data. The splash image data should be ready in memory before bmp_display() is called, and after the environment is ready (since lcd.c looks for the splash image in an address specified by the environment variable "splashimage"). Our window of opportunity in board_init_r() is therefore: between env_relocate() and bmp_display(), and from the available options only the lcd related functions in drv_lcd_init() seem appropriate for such lcd oriented code. Add the option to prepare the splash image data in lcd_logo() right before it is sent to be displayed. Cc: Anatolij Gustschin <agust@denx.de> Cc: Jeroen Hofstee <jeroen@myspectrum.nl> Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il> Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
* lcd: restore ability to display 8 bpp BMPs on 16 bpp LCDsNikita Kiryanov2013-01-14-1/+1
| | | | | | | | | | | | | | Commit fb6a9aab7ae78c (LCD: display 32bpp decompressed bitmap image) broke the check that allowed U-Boot to display 8 bpp BMPs on a 16 bpp LCD screen, effectively turning this feature off. Restore this feature by changing the check back to the same meaning it originally had. To avoid future confusion, the check has also been rephrased to make its meaning clear. Signed-off-by: Nikita Kiryanov <nikita@compulab.co.il> Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
* Merge branch 'master' of git://git.denx.de/u-boot into resolveMinkyu Kang2012-12-10-4/+174
|\ | | | | | | | | | | | | | | | | | | | | Conflicts: README board/samsung/universal_c210/universal.c drivers/misc/Makefile drivers/power/power_fsl.c include/configs/mx35pdk.h include/configs/mx53loco.h include/configs/seaboard.h
| * lcd: Implement RLE8 bitmap decodingTom Wai-Hong Tam2012-11-07-0/+144
| | | | | | | | | | | | | | | | | | | | | | | | | | Add support for drawing compressed RLE8 bitmaps. Reference: http://www.digicamsoft.com/bmp/bmp.html Signed-off-by: Che-Liang Chiou <clchiou@chromium.org> Signed-off-by: Tom Wai-Hong Tam <waihong@chromium.org> Signed-off-by: Simon Glass <sjg@chromium.org> Acked-by: Che-Liang Chiou <clchiou@chromium.org> [agust: fix some minor style issues and build warnings] Signed-off-by: Anatolij Gustschin <agust@denx.de>
| * lcd: Fix BMP decode bug that skips the wrong padded rowTom Wai-Hong Tam2012-11-07-4/+4
| | | | | | | | | | | | | | | | | | | | | | This change fixed 2 things: - Rename padded_line to padded_width since it is (width + padded_row) not line. - When finished a line, should skip the padded_row that is (padded_width - width) instead of (width - padded_width). Reference: http://en.wikipedia.org/wiki/BMP_file_format Signed-off-by: Tom Wai-Hong Tam <waihong@chromium.org> Signed-off-by: Simon Glass <sjg@chromium.org>
| * lcd: Provide an API to access LCD parametersVadim Bendebury2012-11-07-0/+26
| | | | | | | | | | | | | | | | | | | | | | Create a basic API to provide access to lcd parameters such as screen size, and to position the cursor on the screen. This matches up with the video API for the same purpose. Unfortunately they are not yet combined. Signed-off-by: Vadim Bendebury <vbendeb@chromium.org> Signed-off-by: Simon Glass <sjg@chromium.org>
* | lcd: Add CONFIG_CONSOLE_SCROLL_LINES option to speed consoleSimon Glass2012-11-19-5/+17
| | | | | | | | | | | | | | | | | | | | | | | | When the cursor position gets to the end of the LCD console we normally scroll by one line. This adds an option to increase that value. Console scrolling is often slow, and if a large amount of output is being sent, increasing this option to 10 or so will speed things up considerably. Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Tom Warren <twarren@nvidia.com>
* | lcd: Add support for flushing LCD fb from dcache after updateSimon Glass2012-11-19-7/+39
| | | | | | | | | | | | | | | | This provides an option for the LCD to flush the dcache after each update (puts, scroll or clear). Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Tom Warren <twarren@nvidia.com>
* | lcd: Add CONFIG_LCD_ALIGNMENT to select frame buffer alignmentSimon Glass2012-11-19-5/+16
|/ | | | | | | | | | | | The normal alignment is PAGE_SIZE, but if this is defined, we can support other alignments. The motivation for this change is to make the display section-aligned on ARM so that we can easily turn off data caching for the frame buffer region without resorting to level 2 page tables. Signed-off-by: Simon Glass <sjg@chromium.org> Signed-off-by: Tom Warren <twarren@nvidia.com>