This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

PROCESSOR-SDK-AM335X: Clock and Timer not found

Part Number: PROCESSOR-SDK-AM335X

Tool/software:

Hello, 

I create a board with AM335x and I used SDK tools to modify u-Boot and Kernel with my hardware. U-boot starts me up correctly and try to initialize the Kernel.

The problem is when Kernel try to start, I have a lot of errors with Clock and Timer and system stop starting. 

[    0.000000] rcu: srcu_init: Setting srcu_struct sizes based on contention.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@0/clock@38 not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@0/clock@1c not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@0/clock@24 not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@0/clock@120 not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@0/clock@e8 not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@0/clock@0 not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@0/clock@18 not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@0/clock@14c not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@400/clock@0 not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@400/clock@14 not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@400/clock@b0 not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@600/clock@0 not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@800/clock@0 not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@900/clock@0 not found from clkctrl data.
[    0.000000] /ocp/l4_wkup@44c00000/segment@200000/target-module@0/prcm@0/clock@a00/clock@0 not found from clkctrl data.
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-sys-clkin-22!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-dpll-core-m4!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-dpll-core-m5!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-dpll-core-m6!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-dpll-mpu-m2!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-dpll-ddr-m2!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-dpll-disp-m2!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-dpll-per-m2!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-pruss-ocp-gclk!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-mmu-fck-1!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-timer1-fck!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-timer2-fck!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-timer3-fck!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-timer4-fck!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-timer5-fck!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-timer6-fck!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-timer7-fck!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-usbotg-fck-8!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-ieee5000-fck-1!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-wdt1-fck!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-cpsw-cpts-rft!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-gpio0-dbclk-mux!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clock-lcd-gclk!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for gfx_fclk_clksel_ck!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for gfx_fck_div_ck!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for sysclkout_pre_ck!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clkout2_div_ck!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for clkout2_ck!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for ehrpwm0_tbclk!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for ehrpwm1_tbclk!
[    0.000000] ti_clk_get_reg_addr: clk-provider not found for ehrpwm2_tbclk!
[    0.000000] dmtimer_systimer_init: unable to detect system timers, update dtb?
[    0.000000] Failed to initialize '/ocp/l4_wkup@44c00000/segment@200000/target-module@31000/timer@0': -22
[    0.000000] dmtimer_systimer_init: unable to detect system timers, update dtb?
[    0.000000] Failed to initialize '/ocp/interconnect@48000000/segment@0/target-module@40000/timer@0': -22
[    0.000000] dmtimer_systimer_init: unable to detect system timers, update dtb?
[    0.000000] Failed to initialize '/ocp/interconnect@48000000/segment@0/target-module@42000/timer@0': -22
[    0.000000] dmtimer_systimer_init: unable to detect system timers, update dtb?
[    0.000000] Failed to initialize '/ocp/interconnect@48000000/segment@0/target-module@44000/timer@0': -22
[    0.000000] dmtimer_systimer_init: unable to detect system timers, update dtb?
[    0.000000] Failed to initialize '/ocp/interconnect@48000000/segment@0/target-module@46000/timer@0': -22
[    0.000000] dmtimer_systimer_init: unable to detect system timers, update dtb?
[    0.000000] Failed to initialize '/ocp/interconnect@48000000/segment@0/target-module@48000/timer@0': -22
[    0.000000] dmtimer_systimer_init: unable to detect system timers, update dtb?
[    0.000000] Failed to initialize '/ocp/interconnect@48000000/segment@0/target-module@4a000/timer@0': -22
[    0.000000] timer_probe: no matching timers found

For hardware, I used the same elements and connections as a AM335x-EVM and I connect SYSBOOT[15:14 ] = 01b = 24MHz.



I reviewed all files about EVM say to copy for creating my board (https://software-dl.ti.com/processor-sdk-linux/esd/AM335X/09_03_05_02/exports/docs/linux/How_to_Guides/Board_Port/U-Boot.html#integrating-support-for-a-new-board-into-the-u-boot-tree)  and I only found the following items regarding the clock and timer.

&rtc {
	clocks = <&clk_32768_ck>, <&clk_24mhz_clkctrl AM3_CLK_24MHZ_CLKDIV32K_CLKCTRL 0>;
	clock-names = "ext-clk", "int-clk";
};

/* Clock Defines */
#define V_OSCK				24000000  /* Clock output from T2 */
#define V_SCLK				(V_OSCK)

What could be happening to me because I can't find the elements to charge the clock and timer?

Thanks, 

  • Hi,

    Today I continued testing and finally I found that the problem is because the DTB is not compatible with my hardware. That is, I modified the following lines for my hardware.

    model = "TI AM335x EVM";
    compatible = "ti,am335x-evm", "ti,am33xx";

    I have verified that the DTB file I created for my hardware loads correctly but when I modify the compatible text, it stops loading the operating system.
    When the operating system starts, how does it know which hardware it is running on? How do I modify it so that it knows that it is my hardware and not the AM335x EVM?

    Thanks, 

    Xavier

  • Hi Xavier,
    some of the Kernel platform drivers like the clock driver or CPU frequency driver look for the compatible string on the board level and only then function properly...

    a0797059@jiji:~/git/linux (ti-linux-6.1.y)
    $ git grep '"ti,am33xx"' drivers/
    drivers/clk/ti/clkctrl.c:       if (of_machine_is_compatible("ti,am33xx"))
    drivers/clocksource/timer-ti-dm-systimer.c:     if (of_machine_is_compatible("ti,am33xx") ||
    drivers/cpufreq/cpufreq-dt-platdev.c:   { .compatible = "ti,am33xx", },
    drivers/cpufreq/ti-cpufreq.c:   { .compatible = "ti,am33xx", .data = &am3x_soc_data, },
    drivers/net/ethernet/ti/cpsw-common.c:  if (of_machine_is_compatible("ti,am33xx"))
    drivers/soc/ti/pm33xx.c:        if (!of_machine_is_compatible("ti,am33xx") &&

    So the right way for you to define your board-level compatible node would be to keep the platform-level compatible string in the `compatible` list, just like any of the other AM335x-based boards do, so that the drivers can get matched to your board.

    Something like this:

    compatible = "xavier-corporation,am335x-custom-board", "ti,am33xx";

    Regards, Andreas