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.

Linux/DRA71: How to modify QSPI clock in Uboot and kernel

Part Number: DRA71

Tool/software: Linux

Our original QSPI Clock is 96MHz, TI recommends us set the QSPI clock to 76.8MHz.

Then I modify the clock  in device tree file in arch/arm/dts/, both uboot source and kernel source.

But after that, QSPI clock is still 96MHz at the start of system, and turn into 48Mhz after kernel boot up.

Can you advise how to modify QSPI correctly.

Thanks.

  • Hi,

    In u-boot please modify the 'spi-max-frequency' in arch/arm/dts/dra72-evm-common.dtsi to the frequency desired.
    Also in u-boot modify the macro CONFIG_SF_DEFAULT_SPEED present in include/configs/dra7xx_evm.h to the frequency desired.

    In kernel, update the spi-max-frequency attribute in the file arch/arm/boot/dts/dra72-evm-common.dtsi to the desired frequency.

    Regards
    Shravan
  • Hi Shravan,

    I have already modified the related code, but I seems doesn't work, I will double check code and measure the QSPI clock again.

    Is there any restriction on QSPI clock settings? as I set the QSPI clock 76.8Mhz, but measured result is 48Mhz, half of 96Mhz.

    Thanks.

    Best Regards

    Jeremy Zhang

  • Hi Jeremy,

    There isn't any restriction on QSPI clock setting. You can check decompile the kernel dtb to a dts file by running the below command and make sure the spi-max-frequency isn't overwritten.

    dtc -I dtb -O dts -o <output_path> <path to kernel dtb>

    Regards
    Shravan