From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rodolfo Giometti Date: Thu, 19 Jul 2007 16:18:29 +0200 Subject: [U-Boot-Users] [RFC] Splash image In-Reply-To: <20070719095239.GU25573@enneenne.com> References: <20070718083012.GE4836@enneenne.com> <469E280A.9090903@grandegger.com> <20070718153723.GK25573@enneenne.com> <469E39EA.40306@grandegger.com> <20070718160146.GM25573@enneenne.com> <469E3D08.3060208@grandegger.com> <20070719083652.GQ25573@enneenne.com> <469F334F.6040003@grandegger.com> <20070719095239.GU25573@enneenne.com> Message-ID: <20070719141829.GA8458@enneenne.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On Thu, Jul 19, 2007 at 11:52:40AM +0200, Rodolfo Giometti wrote: > On Thu, Jul 19, 2007 at 11:47:59AM +0200, Wolfgang Grandegger wrote: > > Rodolfo Giometti wrote: > >> On Wed, Jul 18, 2007 at 06:17:12PM +0200, Wolfgang Grandegger wrote: > >>> Rodolfo Giometti wrote: > >>>> On Wed, Jul 18, 2007 at 06:03:54PM +0200, Wolfgang Grandegger wrote: > >>>>> What color format do you want to support? > >>>> 16 bpp > >>> Then use "drivers/cfb_console.c" as it already supports that format. > >>> Adapting the interface to pxafb should not be a big deal. > >> In order to adapt pxafb support to "drivers/cfb_console.c" I think I > >> should move cpu/pxa/pxafb.c to drivers/pxafb.c adapting the internal > >> functions to use video_hw_init() and video_set_lut(). Is that right? > > > > I think so and drivers is also the correct place for pxafb.c. > > Ok, I'll propose a patch ASAP. However, simply moving the file from > cpu/pxa/ to drivers/ shouldn't break any code but modifying it in > order to support cfb_console.c will do. > > What do you suggest in order to do the right steps? Maybe should I > remove lcd.c support before doing my modifications? Just to gain some time and doing some tests I did the modifications in order to support splash screen into cfb_console for PXAFB. I noticed that I have to disable some code regarding LCD otherwise there are doubled code execution and several incongruences, see here: static int bmp_display(ulong addr, int x, int y) { #if defined(CONFIG_LCD) extern int lcd_display_bitmap (ulong, int, int); return (lcd_display_bitmap (addr, x, y)); #elif defined(CONFIG_VIDEO) extern int video_display_bitmap (ulong, int, int); return (video_display_bitmap (addr, x, y)); #else # error bmp_display() requires CONFIG_LCD or CONFIG_VIDEO #endif } This code seems OK but if you doesn't define CONFIG_LCD you cannot get framebuffer memory here (lib_arm/board.c): #ifdef CONFIG_LCD # ifndef PAGE_SIZE # define PAGE_SIZE 4096 # endif /* * reserve memory for LCD display (always full pages) */ /* bss_end is defined in the board-specific linker script */ addr = (_bss_end + (PAGE_SIZE - 1)) & ~(PAGE_SIZE - 1); size = lcd_setmem (addr); gd->fb_base = addr; #endif /* CONFIG_LCD */ Ok, I can add a defined() but this is not the right solution IMHO. I wish to remove LCD support at all... are you agree? Any suggestions in order to which steps I should do for better result? Thanks in advance, Rodolfo -- GNU/Linux Solutions e-mail: giometti at enneenne.com Linux Device Driver giometti at gnudd.com Embedded Systems giometti at linux.it UNIX programming phone: +39 349 2432127