[U-Boot] [PATCH v5] arm: rmobile: Add support Renesas SH73A0

Nobuhiro Iwamatsu iwamatsu at nigauri.org
Tue Aug 21 08:05:11 CEST 2012


Hi,

Thanks for your review.

On Mon, Aug 20, 2012 at 12:00 PM, Mike Frysinger <vapier at gentoo.org> wrote:
> On Sunday 19 August 2012 10:40:05 Nobuhiro Iwamatsu wrote:
>> --- /dev/null
>> +++ b/arch/arm/cpu/armv7/rmobile/board.c
>>
>> +#ifdef CONFIG_DISPLAY_BOARDINFO
>> +int checkboard(void)
>> +{
>> +     printf("Board: %s\n", sysinfo.board_string);
>> +     return 0;
>> +}
>> +#endif /* CONFIG_DISPLAY_BOARDINFO */
>
> seems like you could have the makefile do:
> COBJS-$(CONFIG_DISPLAY_BOARDINFO) += board.o
>
> then you wouldn't need these ifdefs in this file
>
>> --- /dev/null
>> +++ b/arch/arm/cpu/armv7/rmobile/cpu_info-sh73a0.c
>>
>> +#ifdef CONFIG_DISPLAY_CPUINFO
>> +u32 rmobile_get_cpu_type(void)
>> +{
>> +     u32 id;
>> +     u32 type;
>> +     struct sh73a0_hpb *hpb = (struct sh73a0_hpb *)HPB_BASE;
>> +
>> +     id = readl(hpb->cccr);
>> +     type = (id >> 8) & 0xFF;
>> +
>> +     return type;
>> +}
>> +
>> +u32 get_cpu_rev(void)
>> +{
>> +     u32 id;
>> +     u32 rev;
>> +     struct sh73a0_hpb *hpb = (struct sh73a0_hpb *)HPB_BASE;
>> +
>> +     id = readl(hpb->cccr);
>> +     rev = (id >> 4) & 0xF;
>> +
>> +     return rev;
>> +}
>> +#endif /* CONFIG_DISPLAY_CPUINFO */
>
> seems like you could have the makefile do:
> COBJS-$(CONFIG_DISPLAY_CPUINFO) += board.o
>
> then you wouldn't need these ifdefs in this file
> -mike

Thanks, I will fix these.

Nobuhiro
-- 
Nobuhiro Iwamatsu
   iwamatsu at {nigauri.org / debian.org}
   GPG ID: 40AD1FA6


More information about the U-Boot mailing list