[U-Boot] [PATCH 17/22] omap4: calculate EMIF register values

Aneesh V aneesh at ti.com
Wed Mar 9 10:26:20 CET 2011


On Wednesday 09 March 2011 10:16 AM, John Rigby wrote:
> On Mon, Feb 28, 2011 at 4:46 AM, Aneesh V<aneesh at ti.com>  wrote:
>> Calculate EMIF register values based on AC timing parameters
>> from the SDRAM datasheet and the DDR frequency rather than
>> using the hard-coded values.
>>
>> For a new board the user doen't have to go through the tedious
>> process of calculating the register values. Instead, just
>> provide the AC timings from the device data sheet as input
>> and the driver will automatically calculate the register values.
>>
>> Signed-off-by: Aneesh V<aneesh at ti.com>
>> ---
>
>
> I get some warnings from arch/arm/cpu/armv7/omap4/emif.c:

I installed Linaro GCC 4.5.2 and I see these warnings now.

> emif.c: In function ‘sdram_init’:
> emif.c:1164:43: warning: ‘section_map’ may be used uninitialized in

Technically, I think this is a false alarm. Although section_map is
initialized conditionally the use is also conditional. So, if the
compiler had done proper data flow analysis it could see that this
won't happen (I don't know if compilers do that kind of analysis)
Nevertheless, we could avoid it. I will fix it in v2.

> this function
> emif.c:1166:27: warning: ‘lis_map_regs_calculated$dmm_lisa_map_3’ may
> be used uninitialized in this function
> emif.c: In function ‘sdram_init’:
> emif.c:1166:27: warning: ‘lis_map_regs_calculated$dmm_lisa_map_3’ may
> be used uninitialized in this function

This is genuine. In one path it may be used uninitialized(this
path is not expected in real scenarios). I will fix this.

Thanks,
Aneesh


More information about the U-Boot mailing list