]> git.baikalelectronics.ru Git - uboot.git/commit
riscv: Try to get cpu frequency from a "clocks" node if it exists
authorSean Anderson <seanga2@gmail.com>
Wed, 24 Jun 2020 10:41:21 +0000 (06:41 -0400)
committerAndes <uboot@andestech.com>
Wed, 1 Jul 2020 07:01:22 +0000 (15:01 +0800)
commit09f2b207030bc316838c03b6b46d18d4e6beaa45
tree184985446d435f4d6a54275dc635b87d25d55106
parenta56bfe64481c3388e46512c55d22fad2c9d7db00
riscv: Try to get cpu frequency from a "clocks" node if it exists

Instead of always using the "clock-frequency" property to determine cpu
frequency, try using a clock in "clocks" if it exists. This patch also
fixes a bug where there could be spurious higher frequencies if sizeof(u32)
!= sizeof(ulong).

Signed-off-by: Sean Anderson <seanga2@gmail.com>
Reviewed-by: Bin Meng <bmeng.cn@gmail.com>
drivers/cpu/riscv_cpu.c