[Qemu-devel] [PATCH for-2.11 v3 16/25] tricore: replace cpu_tricore_init() with cpu_generic_init()

2017-08-24 Thread Igor Mammedov
it's just a wrapper, drop it and use cpu_generic_init() directly Signed-off-by: Igor Mammedov Reviewed-by: Eduardo Habkost --- target/tricore/cpu.h | 4 +--- hw/tricore/tricore_testboard.c | 2 +- target/tricore/helper.c| 5 - 3 files changed, 2 insertions(+), 9 dele

[Qemu-devel] [PATCH for-2.11 v3 22/25] moxie: replace cpu_moxie_init() with cpu_generic_init()

2017-08-24 Thread Igor Mammedov
it's just a wrapper, drop it and use cpu_generic_init() directly Signed-off-by: Igor Mammedov Reviewed-by: Eduardo Habkost --- target/moxie/cpu.h | 3 +-- hw/moxie/moxiesim.c | 2 +- target/moxie/cpu.c | 5 - 3 files changed, 2 insertions(+), 8 deletions(-) diff --git a/target/

[Qemu-devel] [PATCH for-2.11 v3 19/25] cris: replace cpu_cris_init() with cpu_generic_init()

2017-08-24 Thread Igor Mammedov
it's just a wrapper, drop it and use cpu_generic_init() directly Signed-off-by: Igor Mammedov Reviewed-by: Eduardo Habkost --- target/cris/cpu.h| 3 +-- hw/cris/axis_dev88.c | 2 +- target/cris/cpu.c| 5 - 3 files changed, 2 insertions(+), 8 deletions(-) diff --git a/target

[Qemu-devel] [PATCH for-2.11 v3 20/25] x86: replace cpu_x86_init() with cpu_generic_init()

2017-08-24 Thread Igor Mammedov
it's just a wrapper, drop it and use cpu_generic_init() directly Signed-off-by: Igor Mammedov Reviewed-by: Eduardo Habkost --- target/i386/cpu.h | 3 +-- target/i386/cpu.c | 5 - 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/target/i386/cpu.h b/target/i386/cpu.h

[Qemu-devel] [PATCH for-2.11 v3 21/25] lm32: replace cpu_lm32_init() with cpu_generic_init()

2017-08-24 Thread Igor Mammedov
it's just a wrapper, drop it and use cpu_generic_init() directly Signed-off-by: Igor Mammedov Acked-by: Michael Walle Reviewed-by: Eduardo Habkost --- target/lm32/cpu.h | 3 +-- hw/lm32/lm32_boards.c | 4 ++-- hw/lm32/milkymist.c | 2 +- target/lm32/helper.c | 5 - 4 files ch

[Qemu-devel] [PATCH for-2.11 v3 23/25] openrisc: replace cpu_openrisc_init() with cpu_generic_init()

2017-08-24 Thread Igor Mammedov
it's just a wrapper, drop it and use cpu_generic_init() directly Signed-off-by: Igor Mammedov Acked-by: Stafford Horne Reviewed-by: Eduardo Habkost --- target/openrisc/cpu.h | 4 +--- hw/openrisc/openrisc_sim.c | 2 +- target/openrisc/cpu.c | 5 - 3 files changed, 2 inser

[Qemu-devel] [PATCH for-2.11 v3 24/25] unicore32: replace uc32_cpu_init() with cpu_generic_init()

2017-08-24 Thread Igor Mammedov
it's just a wrapper, drop it and use cpu_generic_init() directly Signed-off-by: Igor Mammedov Reviewed-by: Eduardo Habkost --- target/unicore32/cpu.h| 4 +--- hw/unicore32/puv3.c | 2 +- target/unicore32/helper.c | 5 - 3 files changed, 2 insertions(+), 9 deletions(-) diff

[Qemu-devel] [PATCH for-2.11 v3 25/25] ppc: replace cpu_ppc_init() with cpu_generic_init()

2017-08-24 Thread Igor Mammedov
it's just a wrapper, drop it and use cpu_generic_init() directly Signed-off-by: Igor Mammedov Acked-by: David Gibson Reviewed-by: Hervé Poussineau Reviewed-by: Eduardo Habkost --- target/ppc/cpu.h| 3 +-- hw/ppc/e500.c | 3 ++- hw/ppc/mac_newworld.c

Re: [Qemu-devel] [PATCH for-2.11 2/6] ppc: make cpu_model translation to type consistent

2017-08-25 Thread Igor Mammedov
On Fri, 25 Aug 2017 11:38:19 +1000 David Gibson wrote: > On Thu, Aug 24, 2017 at 10:21:47AM +0200, Igor Mammedov wrote: > > PPC handles -cpu FOO rather incosistently, > > i.e. it does case-insensitive matching of FOO to > > a CPU type (see: ppc_cpu_compare_class_name) but &g

Re: [Qemu-devel] [PATCH for-2.11 1/6] ppc: use macros to make cpu type name from string literal

2017-08-25 Thread Igor Mammedov
On Fri, 25 Aug 2017 11:30:47 +1000 David Gibson wrote: > On Thu, Aug 24, 2017 at 10:21:46AM +0200, Igor Mammedov wrote: > > Replace > > "-" TYPE_POWERPC_CPU > > when composing cpu type name from cpu model string literal > > and th

Re: [Qemu-devel] [PATCH for-2.11 4/6] ppc: replace inter-function cyclic dependency/recurssion with 2 simple lookups

2017-08-25 Thread Igor Mammedov
On Fri, 25 Aug 2017 14:12:08 +1000 David Gibson wrote: > On Thu, Aug 24, 2017 at 10:21:49AM +0200, Igor Mammedov wrote: > > previous patches cleaned up cpu model/alias naming which > > allows to simplify cpu model/alias to cpu type lookup a bit > > byt removing recurss

Re: [Qemu-devel] [PATCH for-2.11 5/6] ppc: simplify cpu model lookup by PVR

2017-08-25 Thread Igor Mammedov
On Fri, 25 Aug 2017 14:16:44 +1000 David Gibson wrote: > On Thu, Aug 24, 2017 at 10:21:50AM +0200, Igor Mammedov wrote: > > Signed-off-by: Igor Mammedov > > --- > > target/ppc/translate_init.c | 27 +++ > > 1 file changed, 11 insertions(+), 16

Re: [Qemu-devel] [PATCH for-2.11 6/6] ppc: drop caching ObjectClass from PowerPCCPUAlias

2017-08-25 Thread Igor Mammedov
On Fri, 25 Aug 2017 14:22:03 +1000 David Gibson wrote: > On Thu, Aug 24, 2017 at 10:21:51AM +0200, Igor Mammedov wrote: > > Caching there practically doesn't give any benefits > > and that at slow path druring querying supported CPU list. > > But it introduces non conve

Re: [Qemu-devel] [PATCH for-2.11 v3 01/25] qom: cpu: fix parsed feature string length

2017-08-25 Thread Igor Mammedov
On Thu, 24 Aug 2017 14:00:21 -0300 Philippe Mathieu-Daudé wrote: > Hi Igor, > > On 08/24/2017 01:31 PM, Igor Mammedov wrote: > > since commit ( 9262685b cpu: Factor out cpu_generic_init() ) > > features parsed by it were truncated only to the 1st feature > > afte

Re: [Qemu-devel] [PATCH for-2.11 2/6] ppc: make cpu_model translation to type consistent

2017-08-25 Thread Igor Mammedov
On Fri, 25 Aug 2017 19:45:38 +1000 David Gibson wrote: > On Fri, Aug 25, 2017 at 09:27:40AM +0200, Igor Mammedov wrote: > > On Fri, 25 Aug 2017 11:38:19 +1000 > > David Gibson wrote: > > > > > On Thu, Aug 24, 2017 at 10:21:47AM +0200, Igor Mammedov wrote:

Re: [Qemu-devel] [PATCH for-2.11 5/6] ppc: simplify cpu model lookup by PVR

2017-08-25 Thread Igor Mammedov
On Fri, 25 Aug 2017 19:32:29 +1000 David Gibson wrote: > On Fri, Aug 25, 2017 at 09:40:37AM +0200, Igor Mammedov wrote: > > On Fri, 25 Aug 2017 14:16:44 +1000 > > David Gibson wrote: > > > > > On Thu, Aug 24, 2017 at 10:21:50AM +0200, Igor Mammedov wrote:

Re: [Qemu-devel] [PATCH for-2.11 2/6] ppc: make cpu_model translation to type consistent

2017-08-25 Thread Igor Mammedov
On Fri, 25 Aug 2017 23:28:00 +1000 David Gibson wrote: > On Fri, Aug 25, 2017 at 01:40:07PM +0200, Igor Mammedov wrote: > > On Fri, 25 Aug 2017 19:45:38 +1000 > > David Gibson wrote: > > > > > On Fri, Aug 25, 2017 at 09:27:40AM +0200, Igor Mammedov wrote: >

[Qemu-devel] [PATCH for-2.11 v4 06/25] sparc: make cpu feature parsing property based

2017-08-25 Thread Igor Mammedov
sparc_cpu_parse_features() providing generic CPUClass::parse_features callback, the cpu_sparc_init() will do the same job as cpu_generic_init() so replace content of cpu_sparc_init() with it. Signed-off-by: Igor Mammedov Acked-by: Philippe Mathieu-Daudé Tested-by: Philippe Mathieu-Daudé --- CC: Riku

Re: [Qemu-devel] Qemu 2.10 rc4 build issue on BE (luigi burdo)

2017-08-28 Thread Igor Mammedov
On Mon, 28 Aug 2017 06:13:03 + luigi burdo wrote: > Hi, > > this is the log that was attached in my email. > > i will test only i386 softmmu when will return at home > > thanks > > Luigi > > > ./configure > --target-list=ppc64-softmmu,ppc-softmmu,x86_64-softmmu,arm-softmmu,i386-softmmu

Re: [Qemu-devel] Qemu 2.10 rc4 build issue on BE (luigi burdo)

2017-08-28 Thread Igor Mammedov
On Mon, 28 Aug 2017 09:14:48 + luigi burdo wrote: > Hi Igor, > > > below errors look like corrupted source files > > > > > > i ust dowloaded the compressed file from qemu website,unzipped with tar from > console (like i usually did) and run configure and make. > > can be the file of

[Qemu-devel] [PATCH for-2.11] ide: ahci: unparent children buses before freeing their memory

2017-08-28 Thread Igor Mammedov
added by ide_bus_new() and tries to unparent them, which causes access to freed memory where they where located. Reported-by: Thomas Huth Signed-off-by: Igor Mammedov --- hw/ide/ahci.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/ide/ahci.c b/hw/ide/ahci.c index 406a1b5..ccbe091

Re: [Qemu-devel] [PATCH v11 2/6] ACPI: Add APEI GHES Table Generation support

2017-08-29 Thread Igor Mammedov
On Fri, 18 Aug 2017 22:23:43 +0800 Dongjiu Geng wrote: > This implements APEI GHES Table by passing the error CPER info > to the guest via a fw_cfg_blob. After a CPER info is recorded, an > SEA(Synchronous External Abort)/SEI(SError Interrupt) exception > will be injected into the guest OS. it's

Re: [Qemu-devel] [PATCH for-2.11 4/6] ppc: replace inter-function cyclic dependency/recurssion with 2 simple lookups

2017-08-29 Thread Igor Mammedov
On Wed, 30 Aug 2017 13:05:01 +1000 David Gibson wrote: > On Fri, Aug 25, 2017 at 09:34:32AM +0200, Igor Mammedov wrote: > > On Fri, 25 Aug 2017 14:12:08 +1000 > > David Gibson wrote: > > > > > On Thu, Aug 24, 2017 at 10:21:49AM +0200, Igor Mammedov wrote: &g

Re: [Qemu-devel] [PATCH] qom: Remove unused errp parameter from can_be_deleted()

2017-08-29 Thread Igor Mammedov
e the unused parameter. > > Signed-off-by: Eduardo Habkost Reviewed-by: Igor Mammedov > --- > include/qom/object_interfaces.h | 5 ++--- > backends/cryptodev.c| 2 +- > backends/hostmem.c | 2 +- > qom/object_interfaces.c | 6 +++--- >

Re: [Qemu-devel] [PATCH for-2.11 5/6] ppc: simplify cpu model lookup by PVR

2017-08-30 Thread Igor Mammedov
On Fri, 25 Aug 2017 19:32:29 +1000 David Gibson wrote: > On Fri, Aug 25, 2017 at 09:40:37AM +0200, Igor Mammedov wrote: > > On Fri, 25 Aug 2017 14:16:44 +1000 > > David Gibson wrote: > > > > > On Thu, Aug 24, 2017 at 10:21:50AM +0200, Igor Mammedov wrote:

[Qemu-devel] [PATCH v2 2/8] ppc: use macros to make cpu type name from string literal

2017-08-30 Thread Igor Mammedov
u type per machine type and as bonus it will be consistent and easy grep-able pattern across all other targets that I'm plannig to treat the same way. Signed-off-by: Igor Mammedov Reviewed-by: David Gibson --- target/ppc/cpu.h| 3 +++ target/ppc/kvm_ppc.h| 2 +- target/p

[Qemu-devel] [PATCH v2 1/8] ppc: replace cpu_ppc_init() with cpu_generic_init()

2017-08-30 Thread Igor Mammedov
it's just a wrapper, drop it and use cpu_generic_init() directly Signed-off-by: Igor Mammedov Acked-by: David Gibson Reviewed-by: Hervé Poussineau Reviewed-by: Eduardo Habkost --- target/ppc/cpu.h| 3 +-- hw/ppc/e500.c | 3 ++- hw/ppc/mac_newworld.c

[Qemu-devel] [PATCH v2 0/8] ppc: cpu_model handling cleanups

2017-08-30 Thread Igor Mammedov
cpu model to cpu type, so pls consider merging it early once 2.11 merge window is open if patches make any sense. repo for testing: https://github.com/imammedo/qemu.git ppc_cpu_model_cleanups_V2 CC: David Gibson CC: Alexander Graf CC: qemu-...@nongnu.org Igor Mammedov (8): pp

[Qemu-devel] [PATCH v2 3/8] ppc: make cpu_model translation to type consistent

2017-08-30 Thread Igor Mammedov
all alias/type/core_type lookups. As side effect it allows to remove duplicate core types which are the same except of using different cased letters in name. Signed-off-by: Igor Mammedov --- v2: * make all typenames lower-cased instead on upper-cased (David) PS: consistent naming will be used by fol

[Qemu-devel] [PATCH v2 4/8] ppc: make cpu alias point only to real cpu models

2017-08-30 Thread Igor Mammedov
ppc_cpu_aliases[] content use PowerPCCPUAlias fields properly (i.e. alias goes into .alias and model goes into .model) While at it add TODO defines around aliases that point to cpu models excluded by the same TODO defines. Signed-off-by: Igor Mammedov Acked-by: David Gibson --- v2: * rebase on top of lower

[Qemu-devel] [PATCH v2 5/8] ppc: replace inter-function cyclic dependency/recurssion with 2 simple lookups

2017-08-30 Thread Igor Mammedov
previous patches cleaned up cpu model/alias naming which allows to simplify cpu model/alias to cpu type lookup a bit byt removing recurssion and dependency of ppc_cpu_class_by_name() / ppc_cpu_class_by_alias() on each other. Besides of simplifying code it reduces it by ~15LOC. Signed-off-by: Igor

[Qemu-devel] [PATCH v2 8/8] ppc: remove non implemented cpu models

2017-08-30 Thread Igor Mammedov
Remove cpu models that aren't implemented and are not compiled/tested since they are under TODO ifdef which isn't defined in sources. If someone really needs a removed model he/she should add as regular one with corresponding implementation. Signed-off-by: Igor Mammedov --- targ

[Qemu-devel] [PATCH v2 6/8] ppc: simplify cpu model lookup by PVR

2017-08-30 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- v2: - if going PVR lookup routem check that cpu_model string consumed completely, as PVR number shouldn't have any stray symbol in it. --- target/ppc/translate_init.c | 27 +++ 1 file changed, 11 insertions(+), 16 deletions(-)

[Qemu-devel] [PATCH v2 7/8] ppc: drop caching ObjectClass from PowerPCCPUAlias

2017-08-30 Thread Igor Mammedov
nd trouble wondering why ppc_cpu_class_by_alias() is necessary. Signed-off-by: Igor Mammedov --- target/ppc/cpu-models.h | 1 - target/ppc/kvm.c| 1 - target/ppc/translate_init.c | 26 ++ 3 files changed, 2 insertions(+), 26 deletions(-) diff --git a/

Re: [Qemu-devel] [PATCH 0/8] QOMify MIPS cpu

2017-08-30 Thread Igor Mammedov
On Fri, 18 Aug 2017 17:08:29 -0300 Philippe Mathieu-Daudé wrote: > On 08/17/2017 12:22 PM, Igor Mammedov wrote: > > On Thu, 17 Aug 2017 01:30:54 -0300 > > Philippe Mathieu-Daudé wrote: > [...] > >> Also I couldn't test it with KVM. > > Tested in TCG

Re: [Qemu-devel] [PATCH for-2.11] tests/bios-tables: Silence some messages with V=1, print them with V=2 only

2017-08-30 Thread Igor Mammedov
On Mon, 28 Aug 2017 19:39:45 +0200 Thomas Huth wrote: > When running "make check-qtest-x86_64 V=1", the output is currently flooded > with "Looking for expected file ..." and "Using expected file ..." messages. > None of the other tests is doing that with V=1, so this is a little bit > annoying.

Re: [Qemu-devel] [Qemu-ppc] [PATCH v2 8/8] ppc: remove non implemented cpu models

2017-08-30 Thread Igor Mammedov
On Wed, 30 Aug 2017 15:46:30 +0200 Thomas Huth wrote: > On 30.08.2017 15:24, Igor Mammedov wrote: > > Remove cpu models that aren't implemented and are not > > compiled/tested since they are under TODO ifdef > > which isn't defined in sources. > > > >

[Qemu-devel] [PATCH v2 9/8] fixup! ppc: remove non implemented cpu models

2017-08-30 Thread Igor Mammedov
only TODO escaped defines were meant to be removed, but not TODO_USER_ONLY which are compiled in case of *-user targets. So retirn back "440" model removed by mistake Spotted-by: Thomas Huth Signed-off-by: Igor Mammedov --- target/ppc/cpu-models.c | 4 1 file changed, 4

Re: [Qemu-devel] [Qemu-ppc] [PATCH v2 8/8] ppc: remove non implemented cpu models

2017-08-31 Thread Igor Mammedov
On Thu, 31 Aug 2017 09:58:45 +0200 Thomas Huth wrote: > On 30.08.2017 15:24, Igor Mammedov wrote: > > Remove cpu models that aren't implemented and are not > > compiled/tested since they are under TODO ifdef > > which isn't defined in sources. > > > >

[Qemu-devel] [PATCH for-2.11 v4 08/25] s390x: replace cpu_s390x_init() with cpu_generic_init()

2017-08-31 Thread Igor Mammedov
eation utility for btoh machine and user emulation. Signed-off-by: Igor Mammedov Acked-by: Cornelia Huck --- v2: - fix merge conflict in target/s390x/cpu.h caused by moving cpu_init/cpu_s390x_init with the file in commit (c862bddbc target/s390x: cleanup cpu.h) CC: Cornelia Huck CC: da...

Re: [Qemu-devel] [PATCH for-2.11 v4 08/25] s390x: replace cpu_s390x_init() with cpu_generic_init()

2017-08-31 Thread Igor Mammedov
On Thu, 31 Aug 2017 15:44:38 +0200 David Hildenbrand wrote: > On 31.08.2017 15:19, Igor Mammedov wrote: > > cpu_s390x_init() is used only *-user targets indirectly > > via cpu_init() macro and has a hack to assign ids to created > > cpus (I'm not sure if 'id'

Re: [Qemu-devel] [PATCH v1 06/11] target/s390x: cleanup cpu number/address handling

2017-08-31 Thread Igor Mammedov
On Thu, 31 Aug 2017 16:35:13 +0200 Cornelia Huck wrote: > On Wed, 30 Aug 2017 19:05:56 +0200 > David Hildenbrand wrote: > > > Some time ago we discussed that using "id" as property name is not the > > right thing to do, as it is a reserved property for other devices. > > > > Switch to the term

Re: [Qemu-devel] [PATCH v11 2/6] ACPI: Add APEI GHES Table Generation support

2017-09-01 Thread Igor Mammedov
On Fri, 1 Sep 2017 17:58:55 +0800 gengdongjiu wrote: > Hi Igor, > > On 2017/8/29 18:20, Igor Mammedov wrote: > > On Fri, 18 Aug 2017 22:23:43 +0800 > > Dongjiu Geng wrote: [...] > > > >> +void ghes_build_acpi(GArray

Re: [Qemu-devel] [PATCH] x86/acpi: build SRAT when memory hotplug is enabled

2017-09-04 Thread Igor Mammedov
On Fri, 1 Sep 2017 13:11:18 -0300 Eduardo Habkost wrote: > On Fri, Sep 01, 2017 at 12:45:42PM -0300, Thadeu Lima de Souza Cascardo wrote: > > Linux uses SRAT to determine the maximum memory in a system, which is > > used to determine whether to use the swiotlb for IOMMU or not for a > > device th

Re: [Qemu-devel] [PATCH v2 2/6] xlnx-zynqmp-pmu: Add the CPU and memory

2017-09-04 Thread Igor Mammedov
On Fri, 1 Sep 2017 14:00:37 -0700 Alistair Francis wrote: > Connect the MicroBlaze CPU and the ROM and RAM memory regions. > > Signed-off-by: Alistair Francis > --- > > hw/microblaze/xlnx-zynqmp-pmu.c | 65 > +++-- > 1 file changed, 63 insertions(+), 2 del

Re: [Qemu-devel] [PATCH v5 1/3] hw/acpi-build: Fix SRAT memory building in case of node 0 without RAM

2017-09-04 Thread Igor Mammedov
On Thu, 31 Aug 2017 20:04:26 +0800 Dou Liyang wrote: > From: Eduardo Habkost > > Currently, Using the fisrt node without memory on the machine makes > QEMU unhappy. With this example command line: > ... \ > -m 1024M,slots=4,maxmem=32G \ > -numa node,nodeid=0 \ > -numa node,mem=1024M,nod

Re: [Qemu-devel] [PATCH v5 1/3] hw/acpi-build: Fix SRAT memory building in case of node 0 without RAM

2017-09-04 Thread Igor Mammedov
On Mon, 4 Sep 2017 18:16:31 +0800 Dou Liyang wrote: > At 09/04/2017 05:39 PM, Igor Mammedov wrote: > > On Thu, 31 Aug 2017 20:04:26 +0800 > > Dou Liyang wrote: > > > >> From: Eduardo Habkost > >> > >> Currently, Using the fisrt node without mem

Re: [Qemu-devel] [PATCH v2 9/8] fixup! ppc: remove non implemented cpu models

2017-09-04 Thread Igor Mammedov
On Mon, 4 Sep 2017 21:10:54 +1000 David Gibson wrote: > On Wed, Aug 30, 2017 at 04:26:10PM +0200, Igor Mammedov wrote: > > only TODO escaped defines were meant to be removed, > > but not TODO_USER_ONLY which are compiled in case of > > *-user targets. > > > > S

[Qemu-devel] [PATCH 1/6] qom: cpus: split cpu_generic_init() on feature parsing and cpu creation parts

2017-09-04 Thread Igor Mammedov
it would allow to reuse feature parsing part in various machines that have CPU features instead of re-implementing the same feature parsing each time. Signed-off-by: Igor Mammedov --- include/qom/cpu.h | 21 + qom/cpu.c | 46

[Qemu-devel] [PATCH 2/6] cpu: make cpu_generic_init() abort QEMU on error

2017-09-04 Thread Igor Mammedov
so instead of checking for failure and reporting it various ways, make cpu_generic_init() report errors in consistent way and terminate QEMU on failure. Signed-off-by: Igor Mammedov --- Even though it's tree wide change, it's trivial so all affected call sites are included within one

[Qemu-devel] [PATCH 4/6] vl.c: convert cpu_model to cpu type and set of global properties before machine_init()

2017-09-04 Thread Igor Mammedov
efine default CPU type per machine class at class_init() time and if that is set generic code will parse cpu_model into a MachineState::cpu_type which will be used to create CPUs for that machine instance and allows gradual per board conversion. Signed-off-by: Igor Mammedov --- Target specific chang

[Qemu-devel] [PATCH 5/6] pc: use generic cpu_model parsing

2017-09-04 Thread Igor Mammedov
to pick default cpu type Signed-off-by: Igor Mammedov --- target/i386/cpu.h | 9 + hw/i386/pc.c | 41 + hw/i386/pc_piix.c | 4 +--- target/i386/cpu.c | 3 --- 4 files changed, 15 insertions(+), 42 deletions(-) diff --git a/target/i386

[Qemu-devel] [PATCH 0/6] generalize parsing of cpu_model (x86/arm)

2017-09-04 Thread Igor Mammedov
basis (then I'll respin it as separate series on top of generic patches) github tree for testing: https://github.com/imammedo/qemu.git default_machine_cpu_type_PC_ARM CC: Eduardo Habkost CC: Andrew Jones CC: Richard Henderson Igor Mammedov (6): qom: cpus: split cpu_generic_init() on fea

[Qemu-devel] [PATCH 3/6] cpu: rename cpu_parse_features() to cpu_parse_cpu_model()

2017-09-04 Thread Igor Mammedov
function not just parses features but also converts CPU model name to CPU type, rename it to reflect what it actualy does. Signed-off-by: Igor Mammedov --- include/qom/cpu.h | 4 ++-- qom/cpu.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/include/qom/cpu.h b

[Qemu-devel] [PATCH 6/6] arm: drop intermadiate cpu_model -> cpu type parsing and use cpu type directly

2017-09-04 Thread Igor Mammedov
ead of adhoc places in boadr's machine_init code. Signed-off-by: Igor Mammedov --- CC: Peter Maydell CC: Igor Mitsyanko CC: Rob Herring CC: Andrzej Zaborowski CC: Jan Kiszka CC: Alistair Francis CC: "Edgar E. Iglesias" CC: qemu-...@nongnu.org --- include/hw/arm/armv7m.

Re: [Qemu-devel] [PATCH 3/6] cpu: rename cpu_parse_features() to cpu_parse_cpu_model()

2017-09-04 Thread Igor Mammedov
On Mon, 4 Sep 2017 12:03:09 -0300 Philippe Mathieu-Daudé wrote: > Hi Igor, > > On 09/04/2017 11:00 AM, Igor Mammedov wrote: > > function not just parses features but also converts CPU model > > name to CPU type, rename it to reflect what it actualy does. > > Why no

Re: [Qemu-devel] qdev_get_machine() can return something non-NULL but not TYPE_MACHINE

2017-09-04 Thread Igor Mammedov
On Mon, 4 Sep 2017 17:36:59 +0100 Peter Maydell wrote: > I just got bitten by qdev_get_machine()'s behaviour on the user-only > emulators, where it can return something that isn't NULL and isn't > an instance of TYPE_MACHINE either. user-only shouldn't get to qdev_get_machine() at all, issue prob

Re: [Qemu-devel] [PATCH v2 0/5] generalize parsing of cpu_model (x86/arm)

2017-09-15 Thread Igor Mammedov
On Wed, 13 Sep 2017 18:04:52 +0200 Igor Mammedov wrote: > Changelog since v1: > * fix merge conflicts with ignore_memory_transaction_failures > * fix couple merge conflicts where SoC type string where replaced by type > macro > * keep plain prefix string in: strncmp(cpu_t

Re: [Qemu-devel] [RFC PATCH] NUMA: Enable adding NUMA node implicitly

2017-09-18 Thread Igor Mammedov
>> Add numa_implicit_add_node0 in struct MachineClass, Invoke it before > >>> QEMU > >>> parse NUMA options to enable adding NUMA node implicitly. > >>> > >>> Reported-by: Thadeu Lima de Souza Cascardo > >>> Suggested-by: Igor Ma

Re: [Qemu-devel] [RFC PATCH] NUMA: Enable adding NUMA node implicitly

2017-09-18 Thread Igor Mammedov
h would provide SRAT table to guests without explicit -numa options on CLI and would allow: * windows: to enable memory hotplug * linux: switch to SWIOTLB DMA ops, to bounce DMA transfers to 32bit allocated buffers that legacy drivers/hw can handle. > Reported-by: Thadeu Lima de Souza Casc

Re: [Qemu-devel] [PATCH] qom/cpu: move cpu_model null check to cpu_class_by_name()

2017-09-18 Thread Igor Mammedov
On Sun, 17 Sep 2017 20:28:42 -0300 Philippe Mathieu-Daudé wrote: > and clean every implementation. > > Suggested-by: Eduardo Habkost > Signed-off-by: Philippe Mathieu-Daudé Reviewed-by: Igor Mammedov > --- > Based-on: 20170917232010.14183-7-f4...@amsat.org > > qo

Re: [Qemu-devel] [PATCH v2 0/5] generalize parsing of cpu_model (x86/arm)

2017-09-18 Thread Igor Mammedov
On Fri, 15 Sep 2017 17:03:26 +0200 Igor Mammedov wrote: [...] > > > Hi Eduardo, > > Could you merge it via machine tree? Forgot to actually CC Eduardo, Just noticed a patch (1) on list adding a new soc that would break, due to armv7 dropping cpu-model property in 5/5. It wou

Re: [Qemu-devel] [PATCH v2 0/5] generalize parsing of cpu_model (x86/arm)

2017-09-19 Thread Igor Mammedov
On Tue, 19 Sep 2017 09:11:25 -0300 Eduardo Habkost wrote: > On Mon, Sep 18, 2017 at 06:42:13PM +0200, Igor Mammedov wrote: > > On Fri, 15 Sep 2017 17:03:26 +0200 > > Igor Mammedov wrote: > > > > [...] > > > > > > > Hi Eduardo, > > >

Re: [Qemu-devel] [PATCH v3 6/6] mips: replace cpu_mips_init() with cpu_generic_init()

2017-09-20 Thread Igor Mammedov
erday. Could you rebase this patch on top of pull req (it's only this one patch, the rest applies fine) > From: Igor Mammedov > > now cpu_mips_init() reimplements subset of cpu_generic_init() > tasks, so just drop it and use cpu_generic_init() directly. > > Signed-off-by:

Re: [Qemu-devel] [PATCH] ppc/pnv: fix cores per chip for multiple cpus

2017-09-21 Thread Igor Mammedov
On Thu, 21 Sep 2017 08:04:55 +0200 Cédric Le Goater wrote: > On 09/21/2017 05:54 AM, Nikunj A Dadhania wrote: > > David Gibson writes: > > > >> On Wed, Sep 20, 2017 at 12:48:55PM +0530, Nikunj A Dadhania wrote: > >>> David Gibson writes: > >>> > On Wed, Sep 20, 2017 at 12:10:48PM +0

Re: [Qemu-devel] [RFC PATCH] NUMA: Enable adding NUMA node implicitly

2017-09-21 Thread Igor Mammedov
On Thu, 21 Sep 2017 12:19:17 +0800 Dou Liyang wrote: > Hi Igor, > > I am sorry I missed some comments you gave to me. > > my reply is below. > At 09/18/2017 05:24 PM, Dou Liyang wrote: > [...] > >>> ranges where > >>> *the guest will attempt to probe for a device that QEMU doesn't > >>>

Re: [Qemu-devel] [RFC PATCH] qdev: Mark devices as non-hotpluggable by default

2017-09-21 Thread Igor Mammedov
On Wed, 20 Sep 2017 18:10:48 +0200 Thomas Huth wrote: > On 20.09.2017 13:17, Thomas Huth wrote: > > On 20.09.2017 12:57, Marcel Apfelbaum wrote: > >> On 20/09/2017 13:07, Peter Maydell wrote: > [...] > >>> Is it possible to hack together some kind of test code that > >>> can give us a list of

Re: [Qemu-devel] [PATCH] trivial: Add missing "-m" parameter in docs/memory-hotplug.txt

2017-09-21 Thread Igor Mammedov
On Tue, 19 Sep 2017 11:02:26 +0200 Thomas Huth wrote: > The example obviously lacks the "-m" parameter. > > Signed-off-by: Thomas Huth Reviewed-by: Igor Mammedov > --- > docs/memory-hotplug.txt | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > di

[Qemu-devel] [PATCH] s390x: use generic cpu_model parsing

2017-09-21 Thread Igor Mammedov
define default CPU type in generic way in machine class_init and let common machine code to handle cpu_model parsing. Signed-off-by: Igor Mammedov --- tested under TCG booting debian kernel, and compile tested on s390 host CC: Cornelia Huck CC: Christian Borntraeger CC: Alexander Graf CC

[Qemu-devel] [PATCH v2] s390x: use generic cpu_model parsing

2017-09-21 Thread Igor Mammedov
define default CPU type in generic way in machine class_init and let common machine code to handle cpu_model parsing. Signed-off-by: Igor Mammedov Reviewed-by: David Hildenbrand --- CC: Cornelia Huck --- target/s390x/cpu.h | 6 -- hw/s390x/s390-virtio-ccw.c | 28

Re: [Qemu-devel] [PATCH] s390x: use generic cpu_model parsing

2017-09-21 Thread Igor Mammedov
On Thu, 21 Sep 2017 14:34:40 +0200 David Hildenbrand wrote: > On 21.09.2017 12:53, Igor Mammedov wrote: > > define default CPU type in generic way in machine class_init > > and let common machine code to handle cpu_model parsing. > > > > Signed-off-by: Igor Mammedo

Re: [Qemu-devel] [PATCH v1 03/27] target/s390x: get rid of next_core_id

2017-09-21 Thread Igor Mammedov
; While at it, shield core_id and cpuid completely from linux-user. cpuid > can also only be queried from kernel space. > > Suggested-by: Igor Mammedov > Signed-off-by: David Hildenbrand Reviewed-by: Igor Mammedov [...]

Re: [Qemu-devel] [PATCH] spapr: move registration of "host" CPU core type to machine code

2017-09-25 Thread Igor Mammedov
On Mon, 25 Sep 2017 11:47:33 +0200 Greg Kurz wrote: > The CPU core abstraction belongs to the machine code. This also gets > rid of some code duplication. > > Signed-off-by: Greg Kurz > --- > > hw/ppc/spapr_cpu_core.h is also included elsewhere in target/ppc/kvm.c > but this is already handled

Re: [Qemu-devel] [PATCH v2] qdev: Mark devices as non-hotpluggable by default

2017-09-25 Thread Igor Mammedov
On Mon, 25 Sep 2017 10:31:53 -0300 Eduardo Habkost wrote: > On Mon, Sep 25, 2017 at 01:53:16PM +0200, Cornelia Huck wrote: > > On Fri, 22 Sep 2017 11:16:34 +0200 > > Thomas Huth wrote: > > > > > Historically we've marked all devices as hotpluggable by default. However, > > > most devices are

Re: [Qemu-devel] [PATCH] spapr: move registration of "host" CPU core type to machine code

2017-09-26 Thread Igor Mammedov
On Tue, 26 Sep 2017 09:19:28 +0200 Greg Kurz wrote: > On Tue, 26 Sep 2017 12:57:39 +1000 > David Gibson wrote: > > > On Mon, Sep 25, 2017 at 11:47:33AM +0200, Greg Kurz wrote: > > > The CPU core abstraction belongs to the machine code. This also gets > > > rid of some code duplication. > > >

Re: [Qemu-devel] [PATCH v1 03/27] target/s390x: get rid of next_core_id

2017-09-26 Thread Igor Mammedov
On Mon, 25 Sep 2017 16:14:16 -0700 Richard Henderson wrote: > On 09/18/2017 08:59 AM, David Hildenbrand wrote: > > /* sync cs->cpu_index and env->core_id. The latter is needed for TCG. > > */ > > -cs->cpu_index = env->core_id; > > +cs->cpu_index = cpu->env.core_id; > > +#endif >

Re: [Qemu-devel] [PATCH v2] s390x: use generic cpu_model parsing

2017-09-26 Thread Igor Mammedov
On Tue, 26 Sep 2017 11:24:25 +0200 Cornelia Huck wrote: > On Thu, 21 Sep 2017 14:59:08 +0200 > Igor Mammedov wrote: > > > define default CPU type in generic way in machine class_init > > s/define/Define/ > > > and let common machine code to handle cpu_mod

Re: [Qemu-devel] [RFC PATCH 1/4] pc-dimm: add 'reserved-size' to reserve address range after the ending address

2017-04-20 Thread Igor Mammedov
On Tue, 11 Apr 2017 16:57:00 +0800 Haozhong Zhang wrote: > On 04/07/17 14:46 +0100, Stefan Hajnoczi wrote: > > On Thu, Apr 06, 2017 at 06:46:49PM +0800, Haozhong Zhang wrote: > > > On 04/06/17 11:24 +0100, Stefan Hajnoczi wrote: > > > > On Fri, Mar 31, 2017 at 04:41:44PM +0800, Haozhong Zhang

Re: [Qemu-devel] [RFC PATCH 4/4] nvdimm acpi: build flush hint address structure if required

2017-04-20 Thread Igor Mammedov
On Fri, 31 Mar 2017 16:41:47 +0800 Haozhong Zhang wrote: > Add an boolean option 'flush-hint' to device 'nvdimm'. If it's on, a > flush hint address structure will be constructed for each nvdimm > device. > > Signed-off-by: Haozhong Zhang > --- > hw/acpi/nvdimm.c| 106 > ++

Re: [Qemu-devel] [PATCH v6] Allow setting NUMA distance for different NUMA nodes

2017-04-20 Thread Igor Mammedov
On Thu, 20 Apr 2017 17:25:45 +0800 He Chen wrote: > On Wed, Apr 19, 2017 at 04:14:40PM +0200, Igor Mammedov wrote: > > On Tue, 11 Apr 2017 16:49:26 +0800 > > He Chen wrote: ... > > > +error_setg(errp, "Source/Destination NUMA node is missing. " >

Re: [Qemu-devel] [RFC PATCH 2/4] nvdimm: add functions to initialize and perform flush on back store

2017-04-20 Thread Igor Mammedov
On Fri, 31 Mar 2017 16:41:45 +0800 Haozhong Zhang wrote: > fsync() is used to persist modifications to the back store. If the s/back/backing/ > host NVDIMM is used as the back store, fsync() on Linux will trigger > the write to the host flush hint address. > > Signed-off-by: Haozhong Zhang > -

Re: [Qemu-devel] [PATCH for-2.10 05/23] numa: move source of default CPUs to NUMA node mapping into boards

2017-04-20 Thread Igor Mammedov
On Tue, 28 Mar 2017 15:19:20 +1100 David Gibson wrote: > On Wed, Mar 22, 2017 at 02:32:30PM +0100, Igor Mammedov wrote: [...] answering to questions that I forgot to answer before > > @@ -1554,6 +1554,16 @@ static void virt_set_gic_version(Object *obj, const > > char *valu

Re: [Qemu-devel] [PATCH v7] Allow setting NUMA distance for different NUMA nodes

2017-04-21 Thread Igor Mammedov
On Fri, 21 Apr 2017 15:32:15 +0800 He Chen wrote: > This patch is going to add SLIT table support in QEMU, and provides > additional option `dist` for command `-numa` to allow user set vNUMA > distance by QEMU command. > > With this patch, when a user wants to create a guest that contains > seve

Re: [Qemu-devel] [PATCH v7] Allow setting NUMA distance for different NUMA nodes

2017-04-24 Thread Igor Mammedov
On Mon, 24 Apr 2017 16:52:48 +0800 He Chen wrote: > On Fri, Apr 21, 2017 at 11:53:01AM +0200, Igor Mammedov wrote: > > On Fri, 21 Apr 2017 15:32:15 +0800 > > He Chen wrote: > > > ... > > > +static void validate_numa_distance(void) > > > +

[Qemu-devel] [PATCH] pc/fwcfg: unbreak migration from qemu-2.5 and qemu-2.6 during firmware boot

2017-04-24 Thread Igor Mammedov
option rom is managed by new Signed-off-by: Igor Mammedov --- hw/i386/pc.c | 2 +- hw/i386/pc_piix.c| 1 + hw/i386/pc_q35.c | 1 + include/hw/i386/pc.h | 6 ++ 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/hw/i386/pc.c b/hw/i386/pc.c index f3b372a18f

Re: [Qemu-devel] [PATCH] pc/fwcfg: unbreak migration from qemu-2.5 and qemu-2.6 during firmware boot

2017-04-24 Thread Igor Mammedov
On Mon, 24 Apr 2017 16:13:17 -0300 Eduardo Habkost wrote: > On Mon, Apr 24, 2017 at 08:58:17PM +0200, Igor Mammedov wrote: > [...] > > diff --git a/hw/i386/pc.c b/hw/i386/pc.c > > index f3b372a18f..3f2d96da64 100644 > > --- a/hw/i386/pc.c > > +++ b/hw/i386/pc.c &g

Re: [Qemu-devel] [PATCH] pc/fwcfg: unbreak migration from qemu-2.5 and qemu-2.6 during firmware boot

2017-04-24 Thread Igor Mammedov
On Mon, 24 Apr 2017 16:37:31 -0300 Eduardo Habkost wrote: > On Mon, Apr 24, 2017 at 09:32:33PM +0200, Igor Mammedov wrote: > > On Mon, 24 Apr 2017 16:13:17 -0300 > > Eduardo Habkost wrote: > > > > > On Mon, Apr 24, 2017 at 08:58:17PM +0200, Igor Mammedov wrote: &g

[Qemu-devel] [PATCH v2] pc/fwcfg: unbreak migration from qemu-2.5 and qemu-2.6 during firmware boot

2017-04-24 Thread Igor Mammedov
option rom is managed by new Signed-off-by: Igor Mammedov --- v2: (Eduardo Habkost ) * s/linuxboot_dma_disabled/linuxboot_dma_enabled/ * add comment to linuxboot_dma_enabled field --- hw/i386/pc.c | 9 - hw/i386/pc_piix.c| 1 + hw/i386/pc_q35.c | 1 + include/hw

Re: [Qemu-devel] [PATCH v8] Allow setting NUMA distance for different NUMA nodes

2017-04-25 Thread Igor Mammedov
1,val=21 \ > -numa dist,src=0,dst=2,val=31 \ > -numa dist,src=0,dst=3,val=41 \ > -numa dist,src=1,dst=2,val=21 \ > -numa dist,src=1,dst=3,val=31 \ > -numa dist,src=2,dst=3,val=21 \ > ``` > > Signed-off-by: He Chen Reviewed-by: Igor Mammedov > > --- > Changes si

Re: [Qemu-devel] [PATCH for-2.10 02/23] hw/arm/virt: extract mp-affinity calculation in separate function

2017-04-25 Thread Igor Mammedov
On Tue, 25 Apr 2017 16:09:26 +0200 Andrew Jones wrote: > On Wed, Mar 22, 2017 at 02:32:27PM +0100, Igor Mammedov wrote: > > Signed-off-by: Igor Mammedov > > --- > > hw/arm/virt.c | 59 > > ++- > > 1 f

Re: [Qemu-devel] [PATCH for-2.10 03/23] hw/arm/virt: use machine->possible_cpus for storing possible topology info

2017-04-25 Thread Igor Mammedov
On Tue, 25 Apr 2017 16:28:27 +0200 Andrew Jones wrote: > On Wed, Mar 22, 2017 at 02:32:28PM +0100, Igor Mammedov wrote: > > for now precalculate and store mp_afinity in possible_cpus > > as ARM cpus don't have socket/core/thread-id properties yet. > > In follow patches

Re: [Qemu-devel] [PATCH for-2.10 05/23] numa: move source of default CPUs to NUMA node mapping into boards

2017-04-25 Thread Igor Mammedov
On Tue, 25 Apr 2017 16:48:30 +0200 Andrew Jones wrote: > On Wed, Mar 22, 2017 at 02:32:30PM +0100, Igor Mammedov wrote: > > diff --git a/hw/arm/virt.c b/hw/arm/virt.c > > index 0cbcbc1..8748d25 100644 > > --- a/hw/arm/virt.c > > +++ b/hw/arm/virt.c > > @

Re: [Qemu-devel] [PATCH v2] pc/fwcfg: unbreak migration from qemu-2.5 and qemu-2.6 during firmware boot

2017-04-25 Thread Igor Mammedov
On Tue, 25 Apr 2017 17:01:21 +0200 Laszlo Ersek wrote: > On 04/24/17 22:45, Igor Mammedov wrote: > > Since 2.7 commit (b2a575a Add optionrom compatible with fw_cfg DMA version) > > regressed migration during firmware exection time by > > abusing fwcfg.dma_enabled prope

[Qemu-devel] [PATCH v3] pc/fwcfg: unbreak migration from qemu-2.5 and qemu-2.6 during firmware boot

2017-04-25 Thread Igor Mammedov
,oprom=ioport) to: a bc from a OK FAIL OK b OK OKOK c OK FAIL OK where forward migration from qemu-2.6 to qemu-2.10 should work again leaving only qemu-2.[789]:pc-2.6 broken. Reported-by: Eduardo Habkost Analyzed-by: Laszlo Ersek Signed-off-by: Igor Mammedov

Re: [Qemu-devel] [PATCH for-2.10 08/23] virt-arm: add node-id property to CPU

2017-04-26 Thread Igor Mammedov
On Tue, 25 Apr 2017 19:16:13 +0200 Andrew Jones wrote: > On Wed, Mar 22, 2017 at 02:32:33PM +0100, Igor Mammedov wrote: > > it will allow switching from cpu_index to property based > > numa mapping in follow up patches. > > > > Signed-off-by: Igor Mammedov > &g

Re: [Qemu-devel] [PATCH for-2.10 14/23] virt-arm: get numa node mapping from possible_cpus instead of numa_get_node_for_cpu()

2017-04-26 Thread Igor Mammedov
On Tue, 25 Apr 2017 19:06:34 +0200 Andrew Jones wrote: > On Wed, Mar 22, 2017 at 02:32:39PM +0100, Igor Mammedov wrote: > > Signed-off-by: Igor Mammedov > > --- > > hw/arm/virt-acpi-build.c | 19 +++ > > hw/arm/virt.c| 13 +++

Re: [Qemu-devel] [PATCH v3] pc/fwcfg: unbreak migration from qemu-2.5 and qemu-2.6 during firmware boot

2017-04-26 Thread Igor Mammedov
On Wed, 26 Apr 2017 11:34:04 -0300 Eduardo Habkost wrote: > On Tue, Apr 25, 2017 at 05:37:50PM +0200, Igor Mammedov wrote: > > Since 2.7 commit (b2a575a Add optionrom compatible with fw_cfg DMA version) > > regressed migration during firmware exection time by > > abus

Re: [Qemu-devel] [PATCH] ACPI: call acpi_set_pci_info when only acpi enabled

2017-04-27 Thread Igor Mammedov
On Wed, 26 Apr 2017 13:07:02 -0600 Bruce Rogers wrote: > Commit f0c9d64a exposed an issue with the code order in acpi_setup. > As of that commit, a xenfv machine type guest will no longer start > if using pci passthrough. Re-order the code in that function to > allow acpi_set_pci_info to be calle

Re: [Qemu-devel] [PATCH v9] Allow setting NUMA distance for different NUMA nodes

2017-04-27 Thread Igor Mammedov
nce}_parse --> parse_numa_{node, distance} > * Comments refinement. looks good to me Reviewed-by: Igor Mammedov > > Changes since v7: > * Remove unnecessary node present check. > * Minor improvement on prompt message. > > Changes since v6: > * Split validate_numa_

Re: [Qemu-devel] [PATCH for-2.10 07/23] pc: add node-id property to CPU

2017-04-27 Thread Igor Mammedov
On Wed, 26 Apr 2017 09:21:38 -0300 Eduardo Habkost wrote: adding Peter to CC list [...] > On Wed, Apr 19, 2017 at 01:14:58PM +0200, Igor Mammedov wrote: > > On Wed, 12 Apr 2017 18:02:39 -0300 > > Eduardo Habkost wrote: > > > > > On Wed, Mar 22, 2017 at 02:32:3

<    6   7   8   9   10   11   12   13   14   15   >