at91 framebuffer support
Subsystems (5)
v2 cover at91 framebuffer support
Hi,
v2:
- mode header in include/video
- allocation info in driver
The following patch serie add the support of the Framebuffer on at91 sam9261/sam9263 and sam9g45. The sam9x5 series is not yet supported as they use an other IP.
And enable it on sam0m10g45ek (9263ek and 9261ek will be availlable later).
This is based on the next branch
The following changes since commit 6392955f283389fa4fecb0e2d5d1837bcb83f480:
Merge branch 'for-next/testing-menu' into next (2012-09-20 23:11:42 +0200)
are available in the git repository at:
git://git.jcrosoft.org/barebox.git delivery/atmel_fb
for you to fetch changes up to a60a81609fdc332ca8b84d2b8633dc59f8aacbc8:
at91sam9m10g45ek: add lcdc support (2012-09-21 20:49:25 +0800)
----------------------------------------------------------------
Jean-Christophe PLAGNIOL-VILLARD (5):
video: add atmel lcdc frambuffer support
at91sam9263: add atmel lcdc frambuffer support
at91sam9261: add atmel lcdc frambuffer support
at91sam9g45: add atmel lcdc frambuffer support
at91sam9m10g45ek: add lcdc support
arch/arm/boards/at91sam9m10g45ek/env/bin/boot_board | 7 +++ arch/arm/boards/at91sam9m10g45ek/env/splash.png | Bin 0 -> 22747 bytes arch/arm/boards/at91sam9m10g45ek/init.c | 35 +++++++++++++ arch/arm/configs/at91sam9m10g45ek_defconfig | 11 ++-- arch/arm/mach-at91/at91sam9261.c | 1 + arch/arm/mach-at91/at91sam9261_devices.c | 51 ++++++++++++++++++ arch/arm/mach-at91/at91sam9263.c | 1 + arch/arm/mach-at91/at91sam9263_devices.c | 40 +++++++++++++++ arch/arm/mach-at91/at91sam9g45.c | 1 + arch/arm/mach-at91/at91sam9g45_devices.c | 49 ++++++++++++++++++ arch/arm/mach-at91/include/mach/atmel_lcdc.h | 209 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ arch/arm/mach-at91/include/mach/board.h | 4 ++ drivers/video/Kconfig | 4 ++ drivers/video/Makefile | 1 + drivers/video/atmel_lcdfb.c | 477 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 15 files changed, 888 insertions(+), 3 deletions(-) create mode 100644 arch/arm/boards/at91sam9m10g45ek/env/splash.png create mode 100644 arch/arm/mach-at91/include/mach/atmel_lcdc.h create mode 100644 drivers/video/atmel_lcdfb.c
Best Regards,
J.
_______________________________________________
barebox mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/barebox
_______________________________________________
barebox mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/barebox
PATCH v2 1/5 video: add atmel lcdc frambuffer support
This IP is present on the at91sam9 until the sam9g45, on the sam9x5 we use a new IP.
This driver is based on the linux one.
--- arch/arm/mach-at91/include/mach/board.h | 4 + drivers/video/Kconfig | 4 + drivers/video/Makefile | 1 + drivers/video/atmel_lcdfb.c | 480 +++++++++++++++++++++++++++++++ include/video/atmel_lcdc.h | 211 ++++++++++++++ 5 files changed, 700 insertions(+) create mode 100644 drivers/video/atmel_lcdfb.c create mode 100644 include/video/atmel_lcdc.h
arch/arm/mach-at91/include/mach/board.h +4 -0
@@ -23,6 +23,8 @@#include <net.h> #include <spi/spi.h> #include <linux/mtd/mtd.h> +#include <fb.h> +#include <video/atmel_lcdc.h> /* USB Host */ struct at91_usbh_data {
@@ -154,4 +156,6 @@ struct at91_spi_platform_data { };void at91_add_device_spi (int spi_id,struct at91_spi_platform_data *pdata); + +void __init at91_add_device_lcdc (struct atmel_lcdfb_info *data);#endif
drivers/video/Kconfig +4 -0
@@ -5,6 +5,10 @@ menuconfig VIDEO if VIDEO +config DRIVER_VIDEO_ATMEL + bool "Atmel LCDC framebuffer driver" + depends on ARCH_AT91 + config DRIVER_VIDEO_IMX bool "i.MX framebuffer driver" depends on ARCH_IMX1 || ARCH_IMX21 || ARCH_IMX25 || ARCH_IMX27
drivers/video/Makefile +1 -0
@@ -5,3 +5,4 @@ obj-$(CONFIG_DRIVER_VIDEO_IMX) += imx.o obj-$(CONFIG_DRIVER_VIDEO_IMX_IPU) += imx-ipu-fb.o obj-$(CONFIG_DRIVER_VIDEO_S3C24XX) += s3c24xx.o obj-$(CONFIG_DRIVER_VIDEO_PXA) += pxa.o +obj-$(CONFIG_DRIVER_VIDEO_ATMEL) += atmel_lcdfb.o
drivers/video/atmel_lcdfb.c new file +480 -0
480 lines not on this page · raw message
include/video/atmel_lcdc.h new file +211 -0
211 lines not on this page · raw message
Signature · 7 lines
1.7.10.4 _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
PATCH v2 2/5 at91sam9263: add atmel lcdc frambuffer support
--- arch/arm/mach-at91/at91sam9263.c | 1 + arch/arm/mach-at91/at91sam9263_devices.c | 40 ++++++++++++++++++++++++++++++ 2 files changed, 41 insertions(+)
arch/arm/mach-at91/at91sam9263.c +1 -0
@@ -168,6 +168,7 @@ static struct clk_lookup periph_clocks_lookups[] = {CLKDEV_CON_DEV_ID ("mci_clk" ,"atmel_mci1" , &mmc1_clk),CLKDEV_CON_DEV_ID ("spi_clk" ,"atmel_spi0" , &spi0_clk),CLKDEV_CON_DEV_ID ("spi_clk" ,"atmel_spi1" , &spi1_clk), + CLKDEV_CON_DEV_ID("hck1", "atmel_lcdfb0", &lcdc_clk), }; static struct clk_lookup usart_clocks_lookups[] = {
arch/arm/mach-at91/at91sam9263_devices.c +40 -0
@@ -218,6 +218,46 @@ void at91_add_device_spi(int spi_id, struct at91_spi_platform_data *pdata)void __init at91_add_device_spi (int spi_id,struct at91_spi_platform_data *pdata) {}#endif + +/* -------------------------------------------------------------------- +* LCD Controller +* -------------------------------------------------------------------- */ + +#if defined(CONFIG_DRIVER_VIDEO_ATMEL ) +void __init at91_add_device_lcdc (struct atmel_lcdfb_info *data) +{ +BUG_ON (!data); + +at91_set_A_periph (AT91_PIN_PC1 ,0 );/* LCDHSYNC */ +at91_set_A_periph (AT91_PIN_PC2 ,0 );/* LCDDOTCK */ +at91_set_A_periph (AT91_PIN_PC3 ,0 );/* LCDDEN */ +at91_set_B_periph (AT91_PIN_PB9 ,0 );/* LCDCC */ +at91_set_A_periph (AT91_PIN_PC6 ,0 );/* LCDD2 */ +at91_set_A_periph (AT91_PIN_PC7 ,0 );/* LCDD3 */ +at91_set_A_periph (AT91_PIN_PC8 ,0 );/* LCDD4 */ +at91_set_A_periph (AT91_PIN_PC9 ,0 );/* LCDD5 */ +at91_set_A_periph (AT91_PIN_PC10 ,0 );/* LCDD6 */ +at91_set_A_periph (AT91_PIN_PC11 ,0 );/* LCDD7 */ +at91_set_A_periph (AT91_PIN_PC14 ,0 );/* LCDD10 */ +at91_set_A_periph (AT91_PIN_PC15 ,0 );/* LCDD11 */ +at91_set_A_periph (AT91_PIN_PC16 ,0 );/* LCDD12 */ +at91_set_B_periph (AT91_PIN_PC12 ,0 );/* LCDD13 */ +at91_set_A_periph (AT91_PIN_PC18 ,0 );/* LCDD14 */ +at91_set_A_periph (AT91_PIN_PC19 ,0 );/* LCDD15 */ +at91_set_A_periph (AT91_PIN_PC22 ,0 );/* LCDD18 */ +at91_set_A_periph (AT91_PIN_PC23 ,0 );/* LCDD19 */ +at91_set_A_periph (AT91_PIN_PC24 ,0 );/* LCDD20 */ +at91_set_B_periph (AT91_PIN_PC17 ,0 );/* LCDD21 */ +at91_set_A_periph (AT91_PIN_PC26 ,0 );/* LCDD22 */ +at91_set_A_periph (AT91_PIN_PC27 ,0 );/* LCDD23 */ + +add_generic_device ("atmel_lcdfb" ,0 ,NULL ,AT91SAM9263_LCDC_BASE ,SZ_4K , +IORESOURCE_MEM , data); +} +#else +void __init at91_add_device_lcdc (struct atmel_lcdfb_info *data) {} +#endif +resource_size_t __init at91_configure_dbgu (void ) {at91_set_A_periph (AT91_PIN_PC30 ,0 );/* DRXD */
Signature · 7 lines
1.7.10.4 _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
PATCH v2 3/5 at91sam9261: add atmel lcdc frambuffer support
In reply to Jean-Christophe PLAGNIOL-VILLARD--- arch/arm/mach-at91/at91sam9261.c | 1 + arch/arm/mach-at91/at91sam9261_devices.c | 51 ++++++++++++++++++++++++++++++ 2 files changed, 52 insertions(+)
arch/arm/mach-at91/at91sam9261.c +1 -0
@@ -136,6 +136,7 @@ static struct clk *periph_clocks[] = {static struct clk_lookup periph_clocks_lookups[] = {CLKDEV_CON_DEV_ID ("spi_clk" ,"atmel_spi0" , &spi0_clk),CLKDEV_CON_DEV_ID ("spi_clk" ,"atmel_spi1" , &spi1_clk), +CLKDEV_CON_DEV_ID ("hck1" ,"atmel_lcdfb0" , &lcdc_clk), };static struct clk_lookup usart_clocks_lookups[] = {
arch/arm/mach-at91/at91sam9261_devices.c +51 -0
57 lines not on this page · raw message
Signature · 7 lines
1.7.10.4 _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
PATCH v2 4/5 at91sam9g45: add atmel lcdc frambuffer support
In reply to Jean-Christophe PLAGNIOL-VILLARDNicolas Ferre <[email protected]>
--- arch/arm/mach-at91/at91sam9g45.c | 1 + arch/arm/mach-at91/at91sam9g45_devices.c | 49 ++++++++++++++++++++++++++++++ 2 files changed, 50 insertions(+)
arch/arm/mach-at91/at91sam9g45.c +1 -0
@@ -190,6 +190,7 @@ static struct clk_lookup periph_clocks_lookups[] = {CLKDEV_CON_DEV_ID ("mci_clk" ,"atmel_mci1" , &mmc1_clk),CLKDEV_CON_DEV_ID ("spi_clk" ,"atmel_spi0" , &spi0_clk),CLKDEV_CON_DEV_ID ("spi_clk" ,"atmel_spi1" , &spi1_clk), + CLKDEV_CON_DEV_ID("hck1", "atmel_lcdfb0", &lcdc_clk), }; static struct clk_lookup usart_clocks_lookups[] = {
arch/arm/mach-at91/at91sam9g45_devices.c +49 -0
52 lines not on this page · raw message
Signature · 7 lines
1.7.10.4 _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
PATCH v2 5/5 at91sam9m10g45ek: add lcdc support
In reply to Jean-Christophe PLAGNIOL-VILLARD--- .../arm/boards/at91sam9m10g45ek/env/bin/boot_board | 7 +++++ arch/arm/boards/at91sam9m10g45ek/env/splash.png | Bin 0 -> 22747 bytes arch/arm/boards/at91sam9m10g45ek/init.c | 33 ++++++++++++++++++++ arch/arm/configs/at91sam9m10g45ek_defconfig | 11 +++++-- 4 files changed, 48 insertions(+), 3 deletions(-) create mode 100644 arch/arm/boards/at91sam9m10g45ek/env/splash.png
arch/arm/boards/at91sam9m10g45ek/env/bin/boot_board +7 -0
@@ -5,6 +5,13 @@ export PATH . /env/config +splash=/env/splash.png + +if [ -f ${splash} ]; then + splash ${splash} + fb0.enable=1 +fi + menu -r -m boot menu -a -m boot -d "\e[1;36mWelcome on Barebox Boot Sequence\e[0m" menu -e -a -m boot -c 'menu_boot' -d "boot (default) "
arch/arm/boards/at91sam9m10g45ek/env/splash.png new file binary +0 -0
arch/arm/boards/at91sam9m10g45ek/init.c +33 -0
@@ -218,6 +218,38 @@ static int at91sam9m10g45ek_mem_init(void) }mem_initcall (at91sam9m10g45ek_mem_init); +static struct fb_videomode at91_tft_vga_modes[] = { + { + .name ="LG" , + .refresh =60 , + .xres =480 , .yres =272 , + .pixclock =KHZ2PICOS (9000 ), + + .left_margin =1 , .right_margin =1 , + .upper_margin =40 , .lower_margin =1 , + .hsync_len =45 , .vsync_len =1 , + + .sync =0 , + .vmode =FB_VMODE_NONINTERLACED , + }, +}; + +#define AT91SAM9G45_DEFAULT_LCDCON2 (ATMEL_LCDC_MEMOR_LITTLE \ + | ATMEL_LCDC_DISTYPE_TFT \ + | ATMEL_LCDC_CLKMOD_ALWAYSACTIVE) + +/* Driver datas */ +static struct atmel_lcdfb_info __initdata ek_lcdc_data = { + .lcdcon_is_backlight = true, + .default_bpp =32 , + .default_dmacon =ATMEL_LCDC_DMAEN , + .default_lcdcon2 =AT91SAM9G45_DEFAULT_LCDCON2 , + .guard_time =9 , + .lcd_wiring_mode =ATMEL_LCDC_WIRING_RGB , + .mode_list = at91_tft_vga_modes, + .num_modes =ARRAY_SIZE (at91_tft_vga_modes), +}; +static int at91sam9m10g45ek_devices_init (void ) {ek_add_device_nand ();
@@ -225,6 +257,7 @@ static int at91sam9m10g45ek_devices_init(void)ek_add_device_mci ();ek_device_add_leds ();ek_device_add_keyboard (); +at91_add_device_lcdc (&ek_lcdc_data);devfs_add_partition ("nand0" ,0x00000 ,SZ_128K ,DEVFS_PARTITION_FIXED ,"at91bootstrap_raw" );dev_add_bb_dev ("at91bootstrap_raw" ,"at91bootstrap" );
arch/arm/configs/at91sam9m10g45ek_defconfig +8 -3
@@ -5,6 +5,7 @@ CONFIG_ARM_OPTIMZED_STRING_FUNCTIONS=y CONFIG_PBL_IMAGE=y CONFIG_MMU=y CONFIG_BAREBOX_MAX_IMAGE_SIZE=0x40000 +CONFIG_MALLOC_SIZE=0x800000 CONFIG_MALLOC_TLSF=y CONFIG_PROMPT="9M10G45-EK:" CONFIG_LONGHELP=y
@@ -29,8 +30,6 @@ CONFIG_CMD_PASSWD=y CONFIG_CMD_ECHO_E=y CONFIG_CMD_LOADB=y CONFIG_CMD_MEMINFO=y -CONFIG_CMD_MTEST=y -CONFIG_CMD_MTEST_ALTERNATIVE=y CONFIG_CMD_FLASH=y CONFIG_CMD_BOOTM_SHOW_TYPE=y CONFIG_CMD_BOOTM_VERBOSE=y
@@ -38,13 +37,17 @@ CONFIG_CMD_BOOTM_INITRD=y CONFIG_CMD_BOOTM_OFTREE=y CONFIG_CMD_BOOTM_OFTREE_UIMAGE=y CONFIG_CMD_UIMAGE=y +# CONFIG_CMD_BOOTU is not set CONFIG_CMD_RESET=y CONFIG_CMD_GO=y CONFIG_CMD_OFTREE=y +CONFIG_CMD_MTEST=y +CONFIG_CMD_MTEST_ALTERNATIVE=y CONFIG_CMD_TIMEOUT=y CONFIG_CMD_PARTITION=y CONFIG_CMD_MAGICVAR=y CONFIG_CMD_MAGICVAR_HELP=y +CONFIG_CMD_SPLASH=y CONFIG_CMD_GPIO=y CONFIG_CMD_UNCOMPRESS=y CONFIG_CMD_LED=y
@@ -66,6 +69,8 @@ CONFIG_NAND=y # CONFIG_NAND_ECC_HW_NONE is not set CONFIG_NAND_ATMEL=y CONFIG_UBI=y +CONFIG_VIDEO=y +CONFIG_DRIVER_VIDEO_ATMEL=y CONFIG_MCI=y CONFIG_MCI_STARTUP=y CONFIG_MCI_ATMEL=y
@@ -75,4 +80,4 @@ CONFIG_LED_TRIGGERS=y CONFIG_FS_FAT=y CONFIG_FS_FAT_WRITE=y CONFIG_FS_FAT_LFN=y -CONFIG_LZO_DECOMPRESS=y +CONFIG_PNG=y
Signature · 7 lines
1.7.10.4 _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
Re: [PATCH 5/5] at91sam9m10g45ek: add lcdc support
arch/arm/boards/at91sam9m10g45ek/env/splash.png
Quoted 29 lines · Jean-Christophe PLAGNIOL-VILLARD
Signed-off-by Jean-Christophe PLAGNIOL-VILLARD <[email protected]>Acked-by Nicolas Ferre <[email protected]>--- .../arm/boards/at91sam9m10g45ek/env/bin/boot_board | 7 +++++ arch/arm/boards/at91sam9m10g45ek/env/splash.png | Bin 0 -> 22747 bytes arch/arm/boards/at91sam9m10g45ek/init.c | 33 ++++++++++++++++++++ arch/arm/configs/at91sam9m10g45ek_defconfig | 11 +++++-- 4 files changed, 48 insertions(+), 3 deletions(-) create mode 100644 arch/arm/boards/at91sam9m10g45ek/env/splash.pngarch/arm/boards/at91sam9m10g45ek/env/bin/boot_board +7
-0@@ -5,6 +5,13 @@ export PATH . /env/config +splash=/env/splash.png + +if [ -f ${splash} ]; then + splash ${splash} + fb0.enable=1 +fi + menu -r -m boot menu -a -m boot -d "\e[1;36mWelcome on Barebox Boot Sequence\e[0m" menu -e -a -m boot -c 'menu_boot' -d "boot (default) "arch/arm/boards/at91sam9m10g45ek/env/splash.png +0
-0
I understand your desire to show a logo on the screen, but we really need a storage outside the main repository for this. I'm perfectly fine with showing full HD 3d pictures on the screen if your hardware can do so, but we should not put this into the repository.
We should solve this right now, then we are free to add huge logos, add different logo for each board, update logos for christmas, summer, Helloween...
How about adding some wget mechanism which:
- Only downloads the logos if allowed in the config
- Does not download logos if a logo directory already exists
I'm sure we could create some storage here.
Sascha
Signature · 9 lines
Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
Re: [PATCH 5/5] at91sam9m10g45ek: add lcdc support
Quoted 40 lines · Sascha Hauer
arch/arm/boards/at91sam9m10g45ek/env/splash.png
Quoted 29 lines · Jean-Christophe PLAGNIOL-VILLARD
Signed-off-by Jean-Christophe PLAGNIOL-VILLARD <[email protected]>Acked-by Nicolas Ferre <[email protected]>--- .../arm/boards/at91sam9m10g45ek/env/bin/boot_board | 7 +++++ arch/arm/boards/at91sam9m10g45ek/env/splash.png | Bin 0 -> 22747 bytes arch/arm/boards/at91sam9m10g45ek/init.c | 33 ++++++++++++++++++++ arch/arm/configs/at91sam9m10g45ek_defconfig | 11 +++++-- 4 files changed, 48 insertions(+), 3 deletions(-) create mode 100644 arch/arm/boards/at91sam9m10g45ek/env/splash.pngarch/arm/boards/at91sam9m10g45ek/env/bin/boot_board +7
-0@@ -5,6 +5,13 @@ export PATH . /env/config +splash=/env/splash.png + +if [ -f ${splash} ]; then + splash ${splash} + fb0.enable=1 +fi + menu -r -m boot menu -a -m boot -d "\e[1;36mWelcome on Barebox Boot Sequence\e[0m" menu -e -a -m boot -c 'menu_boot' -d "boot (default) "arch/arm/boards/at91sam9m10g45ek/env/splash.png +0
-0I understand your desire to show a logo on the screen, but we really need a storage outside the main repository for this. I'm perfectly fine with showing full HD 3d pictures on the screen if your hardware can do so, but we should not put this into the repository.
We should solve this right now, then we are free to add huge logos, add different logo for each board, update logos for christmas, summer, Helloween...
Quoted 6 lines
How about adding some wget mechanism which:
- Only downloads the logos if allowed in the config
- Does not download logos if a logo directory already existsI'm sure we could create some storage here.
I nack the wget not the idea
how about a git submodule
as I must have the offline build support
Best Regards,
J.
_______________________________________________
barebox mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/barebox
Re: [PATCH 5/5] at91sam9m10g45ek: add lcdc support
Quoted 17 lines · Jean-Christophe PLAGNIOL-VILLARD
Quoted 16 lines · Sascha Hauer
arch/arm/boards/at91sam9m10g45ek/env/splash.png
Quoted 1 line
arch/arm/boards/at91sam9m10g45ek/env/splash.png +0
-0I understand your desire to show a logo on the screen, but we really need a storage outside the main repository for this. I'm perfectly fine with showing full HD 3d pictures on the screen if your hardware can do so, but we should not put this into the repository.
We should solve this right now, then we are free to add huge logos, add different logo for each board, update logos for christmas, summer, Helloween...
How about adding some wget mechanism which:
- Only downloads the logos if allowed in the config
- Does not download logos if a logo directory already exists
Quoted 6 lines
Quoted 1 line
I'm sure we could create some storage here.
I nack the wget not the idea
how about a git submodule
as I must have the offline build support
That was the "Does not download logos if a logo directory already exists" part above.
Anyway, a submoule is fine with me. I don't care, as long as it's not in the main repository.
Sascha
Signature · 9 lines
Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
Re: [PATCH 1/5] video: add atmel lcdc frambuffer support
In reply to Jean-Christophe PLAGNIOL-VILLARDQuoted 29 lines · Jean-Christophe PLAGNIOL-VILLARD
This IP is present on the at91sam9 until the sam9g45, on the sam9x5 we use a new IP.
This driver is based on the linux one.
include/video/atmel_lcdc.h new file +24
-0+ +/* Way LCD wires are connected to the chip: +* Some Atmel chips use BGR color mode (instead of standard RGB) +* A swapped wiring onboard can bring to RGB mode. +*/ +#define ATMEL_LCDC_WIRING_BGR 0 +#define ATMEL_LCDC_WIRING_RGB 1 +#define ATMEL_LCDC_WIRING_RGB555 2 + + +/* LCD Controller info data structure, stored in device platform_data */ +struct atmel_lcdfb_info { +struct fb_info *info; +void __iomem *mmio; +struct device_d *device; + +unsigned int guard_time; +unsigned int smem_len; +struct clk *bus_clk; +struct clk *lcdc_clk; + +bool lcdcon_is_backlight; +bool lcdcon_pol_negative; +u8 saved_lcdcon;
include/video/atmel_lcdc.h line 57
Quoted 10 lines
include/video/atmel_lcdc.h new file +10
-0+ +u8 default_bpp; +u8 lcd_wiring_mode; +unsigned int default_lcdcon2; +unsigned int default_dmacon; +void (*atmel_lcdfb_power_control)(int on); +struct fb_videomode *mode_list; +unsigned num_modes; +u32 pseudo_palette[16 ]; +};
Honestly, Passing in the driver internal data as platform_data is completely rubbish. If you want to have it the-same-like-in-Linux, then fix it in Linux first.
Sascha
Signature · 9 lines
Pengutronix e.K. | | Industrial Linux Solutions | http://www.pengutronix.de/ | Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ barebox mailing list [email protected] http://lists.infradead.org/mailman/listinfo/barebox
Re: [PATCH 1/5] video: add atmel lcdc frambuffer support
Quoted 36 lines · Sascha Hauer
Quoted 35 lines · Jean-Christophe PLAGNIOL-VILLARD
This IP is present on the at91sam9 until the sam9g45, on the sam9x5 we use a new IP.
This driver is based on the linux one.
include/video/atmel_lcdc.h new file +30
-0+ +/* Way LCD wires are connected to the chip: +* Some Atmel chips use BGR color mode (instead of standard RGB) +* A swapped wiring onboard can bring to RGB mode. +*/ +#define ATMEL_LCDC_WIRING_BGR 0 +#define ATMEL_LCDC_WIRING_RGB 1 +#define ATMEL_LCDC_WIRING_RGB555 2 + + +/* LCD Controller info data structure, stored in device platform_data */ +struct atmel_lcdfb_info { +struct fb_info *info; +void __iomem *mmio; +struct device_d *device; + +unsigned int guard_time; +unsigned int smem_len; +struct clk *bus_clk; +struct clk *lcdc_clk; + +bool lcdcon_is_backlight; +bool lcdcon_pol_negative; +u8 saved_lcdcon; + +u8 default_bpp; +u8 lcd_wiring_mode; +unsigned int default_lcdcon2; +unsigned int default_dmacon; +void (*atmel_lcdfb_power_control)(int on);
Quoted 8 lines
include/video/atmel_lcdc.h line 57
Quoted 4 lines
include/video/atmel_lcdc.h new file +4
-0+struct fb_videomode *mode_list; +unsigned num_modes; +u32 pseudo_palette[16 ]; +};Honestly, Passing in the driver internal data as
platform_datais completely rubbish. If you want to have it the-same-like-in-Linux, then fix it in Linux first.
we will first linux but later with switch with DT that will be done after the discussion about panel description. Once it's done I'll update barebox with it as I alwasy do on at91
As we discuss before on IMX where you do not want to update barebox before finish cleanup linux
So can you agree here on at91 too
Best Regards,
J.
_______________________________________________
barebox mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/barebox