Re: [Qemu-devel] [PATCH 1/2] Allow QEMUMachine to override reset sequencing

2012-08-02 Thread David Gibson
On Wed, Aug 01, 2012 at 09:37:39PM -0500, Anthony Liguori wrote: > David Gibson writes: > > > At present the qemu_system_reset() function always performs the same basic > > actions on all machines. This includes running all the reset handler > > hooks, however the order in which they run is not

Re: [Qemu-devel] [PATCH 1/2] Allow QEMUMachine to override reset sequencing

2012-08-02 Thread David Gibson
On Thu, Aug 02, 2012 at 05:17:27PM +0200, Paolo Bonzini wrote: > Il 02/08/2012 05:50, Benjamin Herrenschmidt ha scritto: > > > >> > This sort of stuff is either > >> > (1) hard coded in a firmware/flashrom or (2) built dynamically in > >> > firmware. Let's not pretend like we're doing this becau

Re: [Qemu-devel] [PATCH 1/2] Allow QEMUMachine to override reset sequencing

2012-08-02 Thread David Gibson
On Thu, Aug 02, 2012 at 06:00:06PM +0300, Lluís Vilanova wrote: > David Gibson writes: > [...] > > diff --git a/vl.c b/vl.c > > index 9fea320..ac47a7c 100644 > > --- a/vl.c > > +++ b/vl.c > > @@ -1410,6 +1410,14 @@ void qemu_system_reset(bool report) > > cpu_synchronize_all_post_reset(); > >

Re: [Qemu-devel] [PATCH 1/2] Allow QEMUMachine to override reset sequencing

2012-08-02 Thread Anthony Liguori
Benjamin Herrenschmidt writes: > On Thu, 2012-08-02 at 17:17 +0200, Paolo Bonzini wrote: >> >> On x86 we do not pre-load the kernel. Neither the kernel/initramfs >> and >> the option ROM that loads the kernel are written in memory, they are >> passed to the guest via fw_cfg. Then the option RO

Re: [Qemu-devel] [PATCH 1/2] Allow QEMUMachine to override reset sequencing

2012-08-02 Thread Benjamin Herrenschmidt
On Thu, 2012-08-02 at 17:17 +0200, Paolo Bonzini wrote: > > On x86 we do not pre-load the kernel. Neither the kernel/initramfs > and > the option ROM that loads the kernel are written in memory, they are > passed to the guest via fw_cfg. Then the option ROM is loaded by the > BIOS, and loads the

Re: [Qemu-devel] [PATCH 1/2] Allow QEMUMachine to override reset sequencing

2012-08-02 Thread Paolo Bonzini
Il 02/08/2012 05:50, Benjamin Herrenschmidt ha scritto: > >> > This sort of stuff is either >> > (1) hard coded in a firmware/flashrom or (2) built dynamically in >> > firmware. Let's not pretend like we're doing this because it's needed >> > for real hardware. > Doesn't matter, we do things lik

Re: [Qemu-devel] [PATCH 1/2] Allow QEMUMachine to override reset sequencing

2012-08-02 Thread Lluís Vilanova
David Gibson writes: [...] > diff --git a/vl.c b/vl.c > index 9fea320..ac47a7c 100644 > --- a/vl.c > +++ b/vl.c > @@ -1410,6 +1410,14 @@ void qemu_system_reset(bool report) > cpu_synchronize_all_post_reset(); > } > +void qemu_system_reset(bool report) > +{ > +if (current_machine->reset)

Re: [Qemu-devel] [PATCH 1/2] Allow QEMUMachine to override reset sequencing

2012-08-01 Thread Benjamin Herrenschmidt
On Wed, 2012-08-01 at 21:37 -0500, Anthony Liguori wrote: > > But all of the DT initialization stuff that is leading to this > discussion in the first place is a gross hack to make a PV > architecture > work that took far too many short cuts. > > Building a DT in memory representing hardware inst

Re: [Qemu-devel] [PATCH 1/2] Allow QEMUMachine to override reset sequencing

2012-08-01 Thread Anthony Liguori
David Gibson writes: > At present the qemu_system_reset() function always performs the same basic > actions on all machines. This includes running all the reset handler > hooks, however the order in which they run is not controlled by the board > logic. Let's be careful here in referring to "bo

[Qemu-devel] [PATCH 1/2] Allow QEMUMachine to override reset sequencing

2012-08-01 Thread David Gibson
At present the qemu_system_reset() function always performs the same basic actions on all machines. This includes running all the reset handler hooks, however the order in which they run is not controlled by the board logic. This is incorrect: any modern real hardware will generally have some sor