summaryrefslogtreecommitdiff
path: root/include/video/atmel_lcdc.h
AgeCommit message (Collapse)Author
2013-09-27video: atmel_lcdfb: pass the pdata as paramsJean-Christophe PLAGNIOL-VILLARD
so we can use have list gpio as example (probe via DT) Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2013-09-27video: atmel_lcdfb: fix platform data structJean-Christophe PLAGNIOL-VILLARD
Today we mix pdata and drivers data in the struct atmel_lcdfb_info Fix it and introduce a new struct atmel_lcdfb_pdata for platform data only Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Signed-off-by: Tomi Valkeinen <tomi.valkeinen@ti.com>
2013-03-13ARM: at91/avr32/atmel_lcdfb: add platform device-id tableJohan Hovold
Add platform device-id table in order to identify the controller and determine its configuration. The currently used configuration parameters are: have_alt_pixclock - SOC uses an alternate pixel-clock calculation formula (at91sam9g45 non-ES) have_hozval - SOC has a HOZVAL field in LCDFRMCFG which is used to determine the linesize for STN displays (at91sam9261, at921sam9g10 and at32ap) have_intensity_bit - SOC uses IBGR:555 rather than BGR:565 16-bit pixel layout (at91sam9261, at91sam9263 and at91sam9rl) This allows us to remove all the remaining uses of cpu_is macros from the driver. Tested on at91sam9263 and at91sam9g45, compile-tested for other AT91-SOCs, and untested for AVR32. Signed-off-by: Johan Hovold <jhovold@gmail.com> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
2013-03-13ARM: at91: fix LCD-wiring modeJohan Hovold
Fix regression introduced by commit 787f9fd23283 ("atmel_lcdfb: support 16bit BGR:565 mode, remove unsupported 15bit modes") which broke 16-bpp modes for older SOCs which use IBGR:555 (msb is intensity) rather than BGR:565. The above commit removes the RGB:555-wiring hack by removing the no longer used ATMEL_LCDC_WIRING_RGB555 define. Acked-by: Peter Korsgaard <jacmet@sunsite.dk> Signed-off-by: Johan Hovold <jhovold@gmail.com> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
2013-03-13atmel_lcdfb: fix 16-bpp modes on older SOCsJohan Hovold
Fix regression introduced by commit 787f9fd23283 ("atmel_lcdfb: support 16bit BGR:565 mode, remove unsupported 15bit modes") which broke 16-bpp modes for older SOCs which use IBGR:555 (msb is intensity) rather than BGR:565. Use SOC-type to determine the pixel layout. Tested on at91sam9263 and at91sam9g45. Cc: <stable@vger.kernel.org> Acked-by: Peter Korsgaard <jacmet@sunsite.dk> Signed-off-by: Johan Hovold <jhovold@gmail.com> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com>
2011-03-22atmel_lcdfb: implement inverted contrast pwmAndreas Bießmann
This patch introduces lcdc->lcdcon_pol_negative which set CONTRAST_CTR register to inverted polarity. Signed-off-by: Andreas Bießmann <biessmann@corscience.de> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
2008-11-12atmel_lcdfb: change irq_base definition to allow error reportingNicolas Ferre
Changed because old the definition of unsigned long cannot be negative. Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Reported-by: Roel Kluin <roel.kluin@gmail.com> Cc: Haavard Skinnemoen <hskinnemoen@atmel.com> Cc: Andrew Victor <linux@maxim.org.za> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-09-18[ARM] 5228/1: Add the RGB555 wiring for the atmel LCDGuillaume GARDET
Add the RGB555 wiring for the atmel LCD. Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com> Acked-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com> Signed-off-by: Guillaume GARDET <guillaume.gardet@free.fr> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2008-08-12atmel_lcdfb: add board parameter specify framebuffer memory sizeHaavard Skinnemoen
Specify how much physically continuous, DMA capable memory will be allocated at driver initialization time. This allow to create framebuffer device with larger virtual resolution. Combine with y-panning this can be used to implement double buffering acceleration method. Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl> Acked-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com> Acked-by: Krzysztof Helt <krzysztof.h1@wp.pl> Cc: Nicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-26include/video/atmel_lcdc.h must #include <linux/workqueue.h>Adrian Bunk
This patch fixes the following compile error caused by commit d22579b837358cbef12ccca5adaf7e93ae09ab7a ("atmel_lcdfb: FIFO underflow management"): In file included from arch/avr32/boards/atstk1000/atstk1004.c:21: include/video/atmel_lcdc.h:40: error: field 'task' has incomplete type Signed-off-by: Adrian Bunk <bunk@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-07-24atmel_lcdfb: FIFO underflow managementNicolas Ferre
Manage atmel_lcdfb FIFO underflow Resetting the LCD and DMA allows to fix screen shifting after a FIFO underflow. It follows reset sequence from errata "LCD Screen Shifting After a Reset". Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Cc: Haavard Skinnemoen <hskinnemoen@atmel.com> Cc: Andrew Victor <linux@maxim.org.za> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-04-28atmel_lcdfb: wiring BGR to RGB color modeNicolas Ferre
Adds different wiring mode for the LCD screen. The legacy atmel LCDC IP uses a non standard color mode, "BGR-555.1" instead "RGB-565". The major part of graphic stacks for embedded systems uses only "RGB-565". It is possible to swap LCD IOs instead of doing this bit swapping by software (See application note AT91SAM9 LCD Controller http://www.atmel.com/dyn/resources/prod_documents/doc6300.pdf) This wire swapping is done on the at91sam9rl-ek board (board code using this patch will come later). Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Cc: David Brownell <dbrownell@users.sourceforge.net> Cc: Hans-Christian Egtvedt <hcegtvedt@atmel.com> Cc: Haavard Skinnemoen <hskinnemoen@atmel.com> Cc: Andrew Victor <avictor.za@gmail.com> Cc: "Antonino A. Daplas" <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-04-28atmel_lcdfb: suspend/resume supportDavid Brownell
Teach atmel_lcdfb driver how to suspend/resume. Note that the backlight control should probably do more of the same stuff: turning off display power (more than just the backlight) and stopping the clocks (and dma to drive the no-longer-seen display). No point in wasting power to generate images that can't be observed, after all... Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Cc: Hans-Christian Egtvedt <hcegtvedt@atmel.com> Cc: Haavard Skinnemoen <hskinnemoen@atmel.com> Cc: Andrew Victor <avictor.za@gmail.com> Cc: "Antonino A. Daplas" <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-06atmel_lcdfb: backlight controlDavid Brownell
On the sam9 EK boards, the LCD backlight is hooked up to a PWM output from the LCD controller. It's controlled by "contrast" registers though. This patch lets boards declare that they have that kind of backlight control. The driver can then export this control, letting screenblank and other operations actually take effect ... reducing the typically substantial power drain from the backlight. Note that it's not fully cooked - doesn't force backlight off during system suspend - the "power" and "blank" events may not be done right This should be easily added in the future. [nicolas.ferre@atmel.com: remove unneeded inline and rename functions] Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Nicolas Ferre <nicolas.ferre@atmel.com> Cc: Andrew Victor <linux@maxim.org.za> Cc: Russell King <rmk@arm.linux.org.uk> Cc: "Antonino A. Daplas" <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2008-02-06atmel_lcdfb: validate display timingsHaavard Skinnemoen
Setting a display timing parameter too high or too low may cause it to wrap around and thus become completely wrong. Validate the timings in atmel_lcdfb_check_var() and saturate to the highest or lowest possible value if necessary. Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com> Cc: "Antonino A. Daplas" <adaplas@pol.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-05-11atmel_lcdfb: AT91/AT32 LCD Controller framebuffer driverNicolas Ferre
Adds a framebuffer driver to ATMEL AT91SAM9x and AT32 aka AVR32 platforms. Those chips share quite the same IP and this code is suitable for both architectures. Signed-off-by: Nicolas Ferre <nicolas.ferre@rfo.atmel.com> Signed-off-by: Antonino Daplas <adaplas@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>