mirror of
https://github.com/xen-project/xen.git
synced 2026-10-28 02:01:24 +01:00
xen/arm: Propagate clock-frequency to DOMU if present in the DT timer node
When the property "clock-frequency" is present in the DT timer node, it means that the bootloader/firmware didn't correctly configure the CNTFRQ/CNTFRQ_EL0 on each processor. The best solution would be to fix the offending firmware/bootloader, although it may not always be possible to modify and re-flash it. As it's not possible to trap the register CNTFRQ/CNTFRQ_EL0, we have to extend xen_arch_domainconfig to provide the timer frequency to the toolstack when the property "clock-frequency" is present to the host DT timer node. Then, a property "clock-frequency" will be created in the guest DT timer node if the value is not 0. We could have set the property in the guest DT no matter if the property is present in the host DT. Although, we still want to let the guest using CNTFRQ in normal case. After all, the property "clock-frequency" is just a workaround for buggy firmware. Also add a stub for fdt_property_u32 which is not present in libfdt < 1.4.0 used by distribution such as Debian Wheezy. Signed-off-by: Julien Grall <julien.grall@citrix.com> Tested-by: Chris Brand <chris.brand@broadcom.com> Acked-by: Ian Campbell <ian.campbell@citrix.com> [ ijc -- ran autogen.sh ]
This commit is contained in:
1 parent
c164853948
commit
59ccb33c40
11 files changed
+70
-5
No files matched your search
@@ -14,6 +14,10 @@
|
||||
you don't. */
|
||||
#undef HAVE_DECL_FDT_NEXT_SUBNODE
|
||||
|
||||
/* Define to 1 if you have the declaration of `fdt_property_u32', and to 0 if
|
||||
you don't. */
|
||||
#undef HAVE_DECL_FDT_PROPERTY_U32
|
||||
|
||||
/* Define to 1 if you have the `fdt_first_subnode' function. */
|
||||
#undef HAVE_FDT_FIRST_SUBNODE
|
||||
|
||||
|
||||