Message ID | 1382028526-1826-1-git-send-email-peter.maydell@linaro.org |
---|---|
State | Superseded |
Headers | show |
On Thu, Oct 17, 2013 at 05:48:43PM +0100, Peter Maydell wrote: > This patch series adds a 'virt' platform which uses the > kernel's mach-virt (fully device-tree driven) support > to create a simple minimalist platform intended for > use for KVM VM guests. > > v6->v7 change is just flipping the order we put > the virtio nodes into the device tree, to match > vexpress and ppc precedent. that's v7->v8 changes right? -Christoffer
On 17 October 2013 18:05, Christoffer Dall <christoffer.dall@linaro.org> wrote: > On Thu, Oct 17, 2013 at 05:48:43PM +0100, Peter Maydell wrote: >> This patch series adds a 'virt' platform which uses the >> kernel's mach-virt (fully device-tree driven) support >> to create a simple minimalist platform intended for >> use for KVM VM guests. >> >> v6->v7 change is just flipping the order we put >> the virtio nodes into the device tree, to match >> vexpress and ppc precedent. > > that's v7->v8 changes right? doh, yes. -- PMM
On 17 October 2013 17:48, Peter Maydell <peter.maydell@linaro.org> wrote: > This patch series adds a 'virt' platform which uses the > kernel's mach-virt (fully device-tree driven) support > to create a simple minimalist platform intended for > use for KVM VM guests. > Changes v7->v8: > * iterate through virtio-mmio nodes the opposite way round so > that they appear in the device tree lowest-address-first; > this matches PPC behaviour and the vexpress code ...it turns out this isn't quite right. We need to create the actual devices in forwards order (so that devices created on the qemu command line populate the transports lowest address first) and then create the dtb nodes in reverse order (so that the transports appear in the final dtb lowest address first). Ugh. Given this plus the fact that you still need a kernel patch to get the thing to boot at all [would anybody on the kernel side like to pick up that particular ball?], I'm leaning toward not putting this in 1.7 now. -- PMM
On 18.10.2013, at 13:12, Peter Maydell <peter.maydell@linaro.org> wrote: > On 17 October 2013 17:48, Peter Maydell <peter.maydell@linaro.org> wrote: >> This patch series adds a 'virt' platform which uses the >> kernel's mach-virt (fully device-tree driven) support >> to create a simple minimalist platform intended for >> use for KVM VM guests. > >> Changes v7->v8: >> * iterate through virtio-mmio nodes the opposite way round so >> that they appear in the device tree lowest-address-first; >> this matches PPC behaviour and the vexpress code > > ...it turns out this isn't quite right. We need to create > the actual devices in forwards order (so that devices created > on the qemu command line populate the transports lowest address > first) and then create the dtb nodes in reverse order (so that > the transports appear in the final dtb lowest address first). Ugh. > > Given this plus the fact that you still need a kernel patch to > get the thing to boot at all [would anybody on the kernel side > like to pick up that particular ball?], I'm leaning toward not > putting this in 1.7 now. We could add a fdt_append_subnode_namelen() function that instead of putting it after the parent's properties puts the new node after all subnodes. While we're waiting for it to trickle into libfdt we could keep a copy in device_tree.c. Then we just switch everything to "natural" non-reverse order append_subnode(). Alex
diff --git a/arch/arm/mach-virt/virt.c b/arch/arm/mach-virt/virt.c index b184e57..2b6aceb 100644 --- a/arch/arm/mach-virt/virt.c +++ b/arch/arm/mach-virt/virt.c @@ -21,11 +21,13 @@ #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); }