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.

AM4378 internal clock output setup



Team,

We are trying to use the internal clock output (clkout1) to drive a camera sensor. (The required clock signal of the camera is 12 MHz.)

The pinmux of that signal has already been set to MODE 3 in the dts file. However, we are not sure how to configure the control register to specify clkout1.
In the datasheet, we know the corresponding register is PRCM_CM_DIV_M4_DPLL_CORE. (As the figure shown below)
We want to set field HSDIVIDER_CLKOUT1_P to 1, field ST_HSDIVIDER_CLKOU to 1, field HSDIVIDER_CLKOUT1_ DIVCHACK to 1 and field HSDIVIDER_CLKOUT1_ DIV to 16.

If you can shed light on which file we should modify (either in U-Boot or in kernel), that will be a great help!

Thanks,

Evan

  • Hi Evan,
    You can define the clock settings am43xx-clocks.dtsi. For information on how to set the clkout1 dtsi node check txt files in Documentation/devicetree/bindings/clock/ti. 

    After that in dts file you need to add this clock in the camera dts node. The actual register settings should be done within the sensor driver (initialization part). You could also check the clock, dpll, cm files in arch/arm/mach-omap2/ to see if any generic settings for am43xx dplls are done there.

    Hope this helps.

    Best Regards,
    Yordan