From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stefano Babic Date: Tue, 28 Aug 2012 10:28:14 +0200 Subject: [U-Boot] [PATCH v1 8/8] OMAP3: mt_ventoux: added video support In-Reply-To: <503C7D38.1070205@denx.de> References: <1346140007-9563-1-git-send-email-sbabic@denx.de> <1346140007-9563-8-git-send-email-sbabic@denx.de> <503C7D38.1070205@denx.de> Message-ID: <503C811E.8090503@denx.de> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de On 28/08/2012 10:11, Heiko Schocher wrote: > Hello Stefano, > Hi Heiko, >> +static struct panel_config lcd_cfg[] = { >> + { >> + .timing_h = ((4 /* hpb */ - 1)<< 20) | >> + ((8 /*hfp */- 1)<< 8) | >> + (41 /* hsw */ - 1), /* Horizontal timing */ > > Could we use here a define, something like this: > > #define PANEL_TIMING_H(bp, fp, sw) (((bp - 1) << 20) | ((fp - 1) << 8) | > (sw - 1)) Agree - and put it in a common header (arch/dss.h), making it accessible to all boards. And we need only one macro PANEL_TIMING, the register has the same layout. I'll do in V2. > > .panel_config = { > .timing_h = PANEL_TIMING_H(4, 8, 41), > >> + .timing_v = (2 /*vbp */<< 24) | > ^^ > Is this correct? In the manual I > see for the timing H and V > settings > the same bitpositions! > This is not correct, thanks. It has no influence on my hardware because it simply increments vbp, but I will fix it. Stefano -- ===================================================================== DENX Software Engineering GmbH, MD: Wolfgang Denk & Detlev Zundel HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: +49-8142-66989-53 Fax: +49-8142-66989-80 Email: sbabic at denx.de =====================================================================