Re: [Qemu-devel] [PATCH v1 05/11] spapr: move memory hotplug size check into plug code

2018-06-14 Thread David Hildenbrand
On 13.06.2018 15:57, Igor Mammedov wrote: > On Wed, 13 Jun 2018 13:05:53 +0200 > David Hildenbrand wrote: > >> On 13.06.2018 13:01, Igor Mammedov wrote: >>> On Mon, 11 Jun 2018 14:16:49 +0200 >>> David Hildenbrand wrote: >>> This might look like a step backwards, but it is not. get_memor

Re: [Qemu-devel] [PATCH v1 05/11] spapr: move memory hotplug size check into plug code

2018-06-13 Thread Igor Mammedov
On Wed, 13 Jun 2018 13:05:53 +0200 David Hildenbrand wrote: > On 13.06.2018 13:01, Igor Mammedov wrote: > > On Mon, 11 Jun 2018 14:16:49 +0200 > > David Hildenbrand wrote: > > > >> This might look like a step backwards, but it is not. get_memory_region() > >> should not be called on uninitita

Re: [Qemu-devel] [PATCH v1 05/11] spapr: move memory hotplug size check into plug code

2018-06-13 Thread David Hildenbrand
On 13.06.2018 13:01, Igor Mammedov wrote: > On Mon, 11 Jun 2018 14:16:49 +0200 > David Hildenbrand wrote: > >> This might look like a step backwards, but it is not. get_memory_region() >> should not be called on uninititalized devices. In general, only >> properties should be access, but no "deri

Re: [Qemu-devel] [PATCH v1 05/11] spapr: move memory hotplug size check into plug code

2018-06-13 Thread Igor Mammedov
On Mon, 11 Jun 2018 14:16:49 +0200 David Hildenbrand wrote: > This might look like a step backwards, but it is not. get_memory_region() > should not be called on uninititalized devices. In general, only > properties should be access, but no "derived" satte like the memory > region. > > 1. We need

Re: [Qemu-devel] [PATCH v1 05/11] spapr: move memory hotplug size check into plug code

2018-06-11 Thread David Gibson
On Mon, Jun 11, 2018 at 02:16:49PM +0200, David Hildenbrand wrote: > This might look like a step backwards, but it is not. get_memory_region() > should not be called on uninititalized devices. In general, only > properties should be access, but no "derived" satte like the memory > region. > > 1. W

[Qemu-devel] [PATCH v1 05/11] spapr: move memory hotplug size check into plug code

2018-06-11 Thread David Hildenbrand
This might look like a step backwards, but it is not. get_memory_region() should not be called on uninititalized devices. In general, only properties should be access, but no "derived" satte like the memory region. 1. We need duplicate error checks if memdev is actually already set. realize() p