arm: virt: Support the ranchu machine name as a virt board
authorChristoffer Dall <christoffer.dall@linaro.org>
Wed, 29 Oct 2014 14:55:19 +0000 (15:55 +0100)
committerChristoffer Dall <christoffer.dall@linaro.org>
Sat, 13 Dec 2014 15:13:46 +0000 (16:13 +0100)
The QEMU ranchu board is a variant of the virt board, it is completely
device-tree driven, but should be matched by the virt board.  It
contains a pl011 serial port for console output, but the virt board
doesn't currently initialize the of clock framework, which is required
for this device to be probed, so add this logic to the virt board as
well.

Note that for newer kernels, this has all been reworked to not have a
board file for mach-virt, so it should not be neccessary in that context
and this patch should not be carried foward into newer kernels, but it
is useful for Linux v3.10-based Android kernels.

Signed-off-by: Christoffer Dall <christoffer.dall@linaro.org>
arch/arm/mach-virt/Kconfig
arch/arm/mach-virt/virt.c

index 8958f0d896bc983cda9fcf9ffff12a4318ab4001..eafb6bed380bd292bff2fa25b23533448cb7116e 100644 (file)
@@ -8,3 +8,4 @@ config ARCH_VIRT
        select CPU_V7
        select SPARSE_IRQ
        select USE_OF
+       select GENERIC_CLOCKEVENTS
index 061f283f579e891b59f8a0c17c0dcafa7bdc4288..4f5b2598386029fd334e35bc97d6d9c73d36863f 100644 (file)
 #include <linux/of_irq.h>
 #include <linux/of_platform.h>
 #include <linux/smp.h>
+#include <linux/clk-provider.h>
 
 #include <asm/mach/arch.h>
 
 static void __init virt_init(void)
 {
+       of_clk_init(NULL);
        of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
 }
 
 static const char *virt_dt_match[] = {
        "linux,dummy-virt",
+       "ranchu",
        "xen,xenvm",
        NULL
 };