How to display IFC frequency when booting T1020 board?

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How to display IFC frequency when booting T1020 board?

Jump to solution
861 Views
cappulee7
Contributor I

Hello.

I am confused how to display the IFC frequency on the T1020 board.(Blue letter below)

CPU0: T1020, Version: 1.1, (0x85210011)
Core: e5500, Version: 2.1, (0x80241021)
Single Source Clock Configuration
Clock Configuration:
CPU0:1200 MHz, CPU1:1200 MHz,
CCB:600 MHz,
DDR:800 MHz (1600 MT/s data rate) (Asynchronous), IFC:300 MHz

........

SDK1.7 and SDK2.0 display methods are different. Which one is more correct?

1) SDK 1.7 uboot
#if defined(CONFIG_FSL_IFC)
    ccr = in_be32(&ifc_regs->ifc_ccr);
    ccr = ((ccr & IFC_CCR_CLK_DIV_MASK) >> IFC_CCR_CLK_DIV_SHIFT) + 1;

    sys_info->freq_localbus = sys_info->freq_systembus / ccr;
#endif

2) SDK 2.0 uboot
    sys_info->freq_localbus = sys_info->freq_systembus / CONFIG_SYS_FSL_IFC_CLK_DIV;

 

Best regard.

0 Kudos
Reply
1 Solution
852 Views
yipingwang
NXP TechSupport
NXP TechSupport

#if defined(CONFIG_FSL_IFC)

ccr = ifc_in32(&ifc_regs.gregs->ifc_ccr);

ccr = ((ccr & IFC_CCR_CLK_DIV_MASK) >> IFC_CCR_CLK_DIV_SHIFT) + 1;

sys_info->freq_localbus = sys_info->freq_systembus / ccr;

#endif

According to the code above, IFC clock freq in uboot means the external clock freq of IFC, not the IFC IP module clock freq. In fact IFC external clock isn’t used on any existing board, so the right way is to calculate IFC IP module clock freq in uboot log as below:

sys_info->freq_localbus = sys_info->freq_systembus / 2.

 

SDK 2.0 is correct.

View solution in original post

1 Reply
853 Views
yipingwang
NXP TechSupport
NXP TechSupport

#if defined(CONFIG_FSL_IFC)

ccr = ifc_in32(&ifc_regs.gregs->ifc_ccr);

ccr = ((ccr & IFC_CCR_CLK_DIV_MASK) >> IFC_CCR_CLK_DIV_SHIFT) + 1;

sys_info->freq_localbus = sys_info->freq_systembus / ccr;

#endif

According to the code above, IFC clock freq in uboot means the external clock freq of IFC, not the IFC IP module clock freq. In fact IFC external clock isn’t used on any existing board, so the right way is to calculate IFC IP module clock freq in uboot log as below:

sys_info->freq_localbus = sys_info->freq_systembus / 2.

 

SDK 2.0 is correct.