Re: [Qemu-devel] [PATCH 2/3] cpu: refactor cpu_address_space_init()

2017-11-23 Thread Peter Xu
On Thu, Nov 23, 2017 at 05:06:31PM +0100, Paolo Bonzini wrote: > On 23/11/2017 10:23, Peter Xu wrote: > > +const char *prefix, MemoryRegion *mr) > > { > > CPUAddressSpace *newas; > > +AddressSpace *as = g_new0(AddressSpace, 1); > > + > > +assert(mr); > > +

Re: [Qemu-devel] [PATCH 2/3] cpu: refactor cpu_address_space_init()

2017-11-23 Thread Paolo Bonzini
On 23/11/2017 10:23, Peter Xu wrote: > +const char *prefix, MemoryRegion *mr) > { > CPUAddressSpace *newas; > +AddressSpace *as = g_new0(AddressSpace, 1); > + > +assert(mr); > +address_space_init(as, mr, prefix); > Now that address_space_init_shareab

[Qemu-devel] [PATCH 2/3] cpu: refactor cpu_address_space_init()

2017-11-23 Thread Peter Xu
Normally we create an address space for that CPU and pass that address space into the function. Let's just do it inside to unify address space creations. It'll simplify my next patch to rename those address spaces. Signed-off-by: Peter Xu --- cpus.c | 5 + exec.c