[U-Boot] [PATCH V2] arm: timer and interrupt init rework

Dirk Behme dirk.behme at googlemail.com
Sat May 2 08:00:54 CEST 2009


Dear Jean-Christophe,

Jean-Christophe PLAGNIOL-VILLARD wrote:
> On 01:00 Sat 02 May     , Dirk Behme wrote:
>> Dear Jean-Christophe,
>>
>> Jean-Christophe PLAGNIOL-VILLARD wrote:
>>> actually the timer init use the interrupt_init as init callback
>>> which make the interrupt and timer implementation difficult to follow
>>>
>>> so now rename it as int timer_init(void) and use interrupt_init for interrupt
>>>
>>> btw also remane the corresponding file to the functionnality implemented
>>>
>>> as ixp arch implement two timer - one based on interrupt - so all the timer
>>> related code is moved to timer.c
>>>
>>> as some timer need interrupt and we need delay in the board init
>>>
>>> the new init sequence is now
>>> interrupt_init (if used)
>>> timer_init
>>> board_init
>>>
>>> Signed-off-by: Jean-Christophe PLAGNIOL-VILLARD <plagnioj at jcrosoft.com>
>> ...
>>> diff --git a/cpu/arm_cortexa8/omap3/Makefile b/cpu/arm_cortexa8/omap3/Makefile
>>> index b96b3dd..edf5cb2 100644
>>> --- a/cpu/arm_cortexa8/omap3/Makefile
>>> +++ b/cpu/arm_cortexa8/omap3/Makefile
>>> @@ -26,7 +26,13 @@ include $(TOPDIR)/config.mk
>>>  LIB	=  $(obj)lib$(SOC).a
>>>   SOBJS	:= lowlevel_init.o
>>> -COBJS	:= sys_info.o board.o clock.o interrupts.o mem.o syslib.o
>>> +
>>> +COBJS	+= board.o
>>> +COBJS	+= clock.o
>>> +COBJS	+= mem.o
>>> +COBJS	+= syslib.o
>>> +COBJS	+= sys_info.o
>>> +COBJS	+= timer.o
>> What do we win with this?
> simple to allow vertical patch to be applied instead of have merge problem
> 
> so yes it's needed

Please elaborate more:

What is "vertical patch"?

Why to "to be applied"? I can't find any note in this patch that 
mentions a dependency to any other patch.

Which "merge problem" do you expect?

So for what "it's needed"?

>>> diff --git a/lib_arm/board.c b/lib_arm/board.c
>>> index 5d05d9b..b678a63 100644
>>> --- a/lib_arm/board.c
>>> +++ b/lib_arm/board.c
>>> @@ -265,8 +265,11 @@ init_fnc_t *init_sequence[] = {
>>>  #if defined(CONFIG_ARCH_CPU_INIT)
>>>  	arch_cpu_init,		/* basic arch cpu dependent setup */
>>>  #endif
>>> -	board_init,		/* basic board dependent setup */
>>> +#if defined(CONFIG_USE_IRQ)
>>>  	interrupt_init,		/* set up exceptions */
>>> +#endif
>>> +	timer_init,		/* initialize timer */
>>> +	board_init,		/* basic board dependent setup */
>>>  	env_init,		/* initialize environment */
>>>  	init_baudrate,		/* initialze baudrate settings */
>>>  	serial_init,		/* serial communications setup */
>> ... if you tested this on an OMAP3 board: I'm not sure, but it seems to 
>> me that the initialization order might change by this?
> maybe read the commit message will answer your question

I understand this as confirmation that the initialization order 
changes by this patch.

Please answer the additional questions in

http://lists.denx.de/pipermail/u-boot/2009-May/051925.html

http://lists.denx.de/pipermail/u-boot/2009-May/051928.html

then.

Dirk



More information about the U-Boot mailing list