Re: [PATCH 0/5] ppc/pnv: fix Homer/Occ mappings on multichip systems

2019-11-22 Thread Balamuruhan S
On Thu, Nov 21, 2019 at 11:00:12AM +0100, Cédric Le Goater wrote: > On 21/11/2019 10:11, Balamuruhan S wrote: > > On Wed, Nov 20, 2019 at 08:46:30AM +0100, Cédric Le Goater wrote: > >> Hello, > >> > >> On 19/11/2019 18:50, Balamuruhan S wrote: > >&g

Re: [PATCH 0/5] ppc/pnv: fix Homer/Occ mappings on multichip systems

2019-11-21 Thread Balamuruhan S
On Wed, Nov 20, 2019 at 08:46:30AM +0100, Cédric Le Goater wrote: > Hello, > > On 19/11/2019 18:50, Balamuruhan S wrote: > > Hi All, > > > > PowerNV fails to boot in multichip systems due to some misinterpretation > > and mapping in Homer/Occ device models, this

Re: [PATCH 5/5] hw/ppc/pnv_xscom: add PBA BARs for Power8 slw image

2019-11-21 Thread Balamuruhan S
On Wed, Nov 20, 2019 at 08:31:50AM +0100, Cédric Le Goater wrote: > On 19/11/2019 18:50, Balamuruhan S wrote: > > slw base and size mask are accessed during boot in homer_init_chip(), > > so include BAR2 and BARMASK2 for Power8. > > > > Signed-off-by: Balamur

Re: [PATCH 4/5] hw/ppc/pnv_xscom: occ common area to be mapped only once

2019-11-21 Thread Balamuruhan S
On Wed, Nov 20, 2019 at 08:30:03AM +0100, Cédric Le Goater wrote: > On 19/11/2019 18:50, Balamuruhan S wrote: > > occ common area should be mapped once > > It's the same address on each chip. > > the question is how the HW knows from which chip the OCC access is &g

Re: [PATCH 3/5] hw/ppc/pnv_xscom: Power8 occ common area is in PBA BAR 3

2019-11-21 Thread Balamuruhan S
On Wed, Nov 20, 2019 at 08:20:35AM +0100, Cédric Le Goater wrote: > On 19/11/2019 18:50, Balamuruhan S wrote: > > Fix incorrect PBA BAR and BARMASK value for Power8 occ common area > > region where skiboot enum declaration have it in BAR 3 and BARMASK > > is calc

Re: [PATCH 2/5] hw/ppc/pnv_xscom: PBA bar mask values are incorrect with homer/occ sizes

2019-11-21 Thread Balamuruhan S
On Wed, Nov 20, 2019 at 08:18:38AM +0100, Cédric Le Goater wrote: > On 19/11/2019 18:50, Balamuruhan S wrote: > > homer/occ sizes are calculated in skiboot with `(mask | 0xf) + 1`, > > and from xscom access should return correct mask values instead of actual > > sizes

Re: [PATCH 2/5] hw/ppc/pnv_xscom: PBA bar mask values are incorrect with homer/occ sizes

2019-11-21 Thread Balamuruhan S
On Wed, Nov 20, 2019 at 08:59:40AM +0100, Greg Kurz wrote: > On Wed, 20 Nov 2019 08:46:51 +0530 > Balamuruhan S wrote: > > > On Wed, Nov 20, 2019 at 08:31:03AM +0530, Balamuruhan S wrote: > > > On Wed, Nov 20, 2019 at 09:02:26AM +1100, David Gibson wrote: > > >

Re: [PATCH 1/5] hw/ppc/pnv: incorrect homer and occ common area size

2019-11-21 Thread Balamuruhan S
On Wed, Nov 20, 2019 at 08:13:50AM +0100, Cédric Le Goater wrote: > On 19/11/2019 18:50, Balamuruhan S wrote: > > Homer size is 4MB and OCC common area size is 8MB, but currently > > it is assigned with bar mask value. Also pass on the occ sram > > size 3 bits right shifted t

Re: [PATCH 2/5] hw/ppc/pnv_xscom: PBA bar mask values are incorrect with homer/occ sizes

2019-11-19 Thread Balamuruhan S
On Wed, Nov 20, 2019 at 08:31:03AM +0530, Balamuruhan S wrote: > On Wed, Nov 20, 2019 at 09:02:26AM +1100, David Gibson wrote: > > On Wed, Nov 20, 2019 at 09:00:32AM +1100, David Gibson wrote: > > > On Wed, Nov 20, 2019 at 08:56:18AM +1100, David Gibson wrote: > > > >

Re: [PATCH 2/5] hw/ppc/pnv_xscom: PBA bar mask values are incorrect with homer/occ sizes

2019-11-19 Thread Balamuruhan S
On Wed, Nov 20, 2019 at 09:02:26AM +1100, David Gibson wrote: > On Wed, Nov 20, 2019 at 09:00:32AM +1100, David Gibson wrote: > > On Wed, Nov 20, 2019 at 08:56:18AM +1100, David Gibson wrote: > > > On Tue, Nov 19, 2019 at 11:20:53PM +0530, Balamuruhan S wrote: >

[PATCH 3/5] hw/ppc/pnv_xscom: Power8 occ common area is in PBA BAR 3

2019-11-19 Thread Balamuruhan S
-off-by: Cédric Le Goater Signed-off-by: Balamuruhan S --- hw/ppc/pnv_xscom.c | 12 ++-- 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/hw/ppc/pnv_xscom.c b/hw/ppc/pnv_xscom.c index cdd5fa356e..cb6d6bbcfc 100644 --- a/hw/ppc/pnv_xscom.c +++ b/hw/ppc/pnv_xscom.c @@ -38,9

[PATCH 1/5] hw/ppc/pnv: incorrect homer and occ common area size

2019-11-19 Thread Balamuruhan S
Homer size is 4MB and OCC common area size is 8MB, but currently it is assigned with bar mask value. Also pass on the occ sram size 3 bits right shifted to initialize the size appropriately. Signed-off-by: Cédric Le Goater Signed-off-by: Balamuruhan S --- hw/ppc/pnv_occ.c | 2 +- include

[PATCH 4/5] hw/ppc/pnv_xscom: occ common area to be mapped only once

2019-11-19 Thread Balamuruhan S
occ common area should be mapped once and disable it for every other chip. Signed-off-by: Cédric Le Goater Signed-off-by: Balamuruhan S --- hw/ppc/pnv_xscom.c | 15 --- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/hw/ppc/pnv_xscom.c b/hw/ppc/pnv_xscom.c index

[PATCH 2/5] hw/ppc/pnv_xscom: PBA bar mask values are incorrect with homer/occ sizes

2019-11-19 Thread Balamuruhan S
homer/occ sizes are calculated in skiboot with `(mask | 0xf) + 1`, and from xscom access should return correct mask values instead of actual sizes. Signed-off-by: Cédric Le Goater Signed-off-by: Balamuruhan S --- hw/ppc/pnv_xscom.c | 10 ++ 1 file changed, 6 insertions(+), 4

[PATCH 5/5] hw/ppc/pnv_xscom: add PBA BARs for Power8 slw image

2019-11-19 Thread Balamuruhan S
slw base and size mask are accessed during boot in homer_init_chip(), so include BAR2 and BARMASK2 for Power8. Signed-off-by: Balamuruhan S --- hw/ppc/pnv_xscom.c | 10 -- include/hw/ppc/pnv.h | 4 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/hw/ppc

[PATCH 0/5] ppc/pnv: fix Homer/Occ mappings on multichip systems

2019-11-19 Thread Balamuruhan S
and help to figure out the issues. Balamuruhan S (5): hw/ppc/pnv: incorrect homer and occ common area size hw/ppc/pnv_xscom: PBA bar mask values are incorrect with homer/occ sizes hw/ppc/pnv_xscom: Power8 occ common area is in PBA BAR 3 hw/ppc/pnv_xscom: occ common area to be mapped

Re: [Qemu-devel] [PATCH 1/3] tests/acceptance/migration: fix post migration check

2019-09-17 Thread Balamuruhan S
On Mon, Sep 16, 2019 at 07:50:44PM +0100, Dr. David Alan Gilbert wrote: > * Balamuruhan S (bal...@linux.ibm.com) wrote: > > assert `query-migrate` in target doesn't give migration > > status and test errors even if migration succeeds. > > > > In target: >

Re: [Qemu-devel] [PATCH 3/3] tests/acceptance/migration: test to migrate will all machine types

2019-09-17 Thread Balamuruhan S
On Mon, Sep 16, 2019 at 03:50:06PM +0100, Dr. David Alan Gilbert wrote: > * Balamuruhan S (bal...@linux.ibm.com) wrote: > > add migration test to query machine types supported by qemu binary > > and migrate vm will all supported type. > > > > Signed-off-by: Ba

[Qemu-devel] [PATCH 1/3] tests/acceptance/migration: fix post migration check

2019-09-16 Thread Balamuruhan S
assert `query-migrate` in target doesn't give migration status and test errors even if migration succeeds. In target: {'execute': 'query-migrate'} {"return": {}} Signed-off-by: Balamuruhan S --- tests/acceptance/migration.py | 7 --- 1 file changed, 4 insertions(+), 3 deletion

[Qemu-devel] [PATCH 3/3] tests/acceptance/migration: test to migrate will all machine types

2019-09-16 Thread Balamuruhan S
add migration test to query machine types supported by qemu binary and migrate vm will all supported type. Signed-off-by: Balamuruhan S --- tests/acceptance/migration.py | 26 ++ 1 file changed, 26 insertions(+) diff --git a/tests/acceptance/migration.py b/tests

[Qemu-devel] [PATCH 2/3] tests/acceptance/avocado_qemu: add method to get supported machine types

2019-09-16 Thread Balamuruhan S
add `get_machine_types()` to return list of supported machine types by the qemu binary. Signed-off-by: Balamuruhan S --- tests/acceptance/avocado_qemu/__init__.py | 6 ++ 1 file changed, 6 insertions(+) diff --git a/tests/acceptance/avocado_qemu/__init__.py b/tests/acceptance/avocado_qemu

[Qemu-devel] [PATCH 0/3] Add acceptance test for migration

2019-09-16 Thread Balamuruhan S
TIME : 5.86 s Currently acceptance test for migration error out as we check `query-migrate` in target after migration which is not appropriate. Balamuruhan S (3): tests/acceptance/migration: fix post migration check tests/acceptance/avocado_qemu: add method to get supported machine

Re: [Qemu-devel] [PATCH v3 0/4] add Homer/OCC common area emulation for PowerNV

2019-09-12 Thread Balamuruhan S
On Thu, Sep 12, 2019 at 11:54:00AM +0200, Cédric Le Goater wrote: > On 12/09/2019 11:30, Balamuruhan S wrote: > > Hi All, > > > > This is follow-up patch that implements HOMER and OCC SRAM device > > models to emulate homer memory and occ common area access for ps

[Qemu-devel] [PATCH v3 3/4] hw/ppc/pnv_homer: add PowerNV homer device model

2019-09-12 Thread Balamuruhan S
add PnvHomer device model to emulate homer memory access for pstate table, occ-sensors, slw, occ static and dynamic values for Power8 and Power9 chips. Signed-off-by: Balamuruhan S --- hw/ppc/Makefile.objs | 1 + hw/ppc/pnv.c | 30 + hw/ppc/pnv_homer.c | 272

[Qemu-devel] [PATCH v3 2/4] hw/ppc/pnv_occ: add sram device model for occ common area

2019-09-12 Thread Balamuruhan S
emulate occ common area region with occ sram device model which occ and skiboot uses it to communicate regarding sensors, slw and HWMON in PowerNV emulated host. Reviewed-by: Cédric Le Goater Signed-off-by: Balamuruhan S --- hw/ppc/pnv.c | 8 + hw/ppc/pnv_occ.c | 78

[Qemu-devel] [PATCH v3 4/4] hw/ppc/pnv: fix checkpatch.pl coding style warnings

2019-09-12 Thread Balamuruhan S
There were few trailing comments after `/*` instead in new line and line more than 80 character, these fixes are trivial and doesn't change any logic in code. Reviewed-by: Cédric Le Goater Signed-off-by: Balamuruhan S --- hw/ppc/pnv.c | 49 - 1

[Qemu-devel] [PATCH v3 0/4] add Homer/OCC common area emulation for PowerNV

2019-09-12 Thread Balamuruhan S
`chip_num`. * define all the memory ops access address as macros. * few coding style warnings given by checkpatch.pl. rfc patchset: https://lists.gnu.org/archive/html/qemu-devel/2019-08/msg00979.html I request for review, comments and suggestions for the changes. Balamuruhan S (4): hw/ppc

[Qemu-devel] [PATCH v3 1/4] hw/ppc/pnv_xscom: retrieve homer/occ base address from PBA BARs

2019-09-12 Thread Balamuruhan S
During PowerNV boot skiboot populates the device tree by retrieving base address of homer/occ common area from PBA BARs and prd ipoll mask by accessing xscom read/write accesses. Reviewed-by: Cédric Le Goater Signed-off-by: Balamuruhan S --- hw/ppc/pnv_xscom.c | 34

Re: [Qemu-devel] [PATCH v2 3/4] hw/ppc/pnv_homer: add PowerNV homer device model

2019-09-11 Thread Balamuruhan S
On Wed, Sep 11, 2019 at 04:53:37PM +0200, Cédric Le Goater wrote: > On 11/09/2019 16:29, Balamuruhan S wrote: > > add PnvHomer device model to emulate homer memory access > > for pstate table, occ-sensors, slw, occ static and dynamic > > values for Power8 and Power9 chips

[Qemu-devel] [PATCH v2 3/4] hw/ppc/pnv_homer: add PowerNV homer device model

2019-09-11 Thread Balamuruhan S
add PnvHomer device model to emulate homer memory access for pstate table, occ-sensors, slw, occ static and dynamic values for Power8 and Power9 chips. Signed-off-by: Cédric Le Goater Signed-off-by: Balamuruhan S --- hw/ppc/Makefile.objs | 1 + hw/ppc/pnv.c | 30

[Qemu-devel] [PATCH v2 2/4] hw/ppc/pnv_occ: add sram device model for occ common area

2019-09-11 Thread Balamuruhan S
emulate occ common area region with occ sram device model which occ and skiboot uses it to communicate regarding sensors, slw and HWMON in PowerNV emulated host. Reviewed-by: Cédric Le Goater Signed-off-by: Balamuruhan S --- hw/ppc/pnv.c | 8 + hw/ppc/pnv_occ.c | 78

[Qemu-devel] [PATCH v2 4/4] hw/ppc/pnv: fix checkpatch.pl coding style warnings

2019-09-11 Thread Balamuruhan S
There were few trailing comments after `/*` instead in new line and line more than 80 character, these fixes are trivial and doesn't change any logic in code. Signed-off-by: Balamuruhan S --- hw/ppc/pnv.c | 49 - 1 file changed, 32 insertions

[Qemu-devel] [PATCH v2 1/4] hw/ppc/pnv_xscom: retrieve homer/occ base address from PBA BARs

2019-09-11 Thread Balamuruhan S
During PowerNV boot skiboot populates the device tree by retrieving base address of homer/occ common area from PBA BARs and prd ipoll mask by accessing xscom read/write accesses. Reviewed-by: Cédric Le Goater Signed-off-by: Balamuruhan S --- hw/ppc/pnv_xscom.c | 34

[Qemu-devel] [PATCH v2 0/4] add Homer/OCC common area emulation for PowerNV

2019-09-11 Thread Balamuruhan S
-devel/2019-08/msg00979.html I request for review, comments and suggestions for the changes. Balamuruhan S (4): hw/ppc/pnv_xscom: retrieve homer/occ base address from PBA BARs hw/ppc/pnv_occ: add sram device model for occ common area hw/ppc/pnv_homer: add PowerNV homer device model hw/ppc

Re: [Qemu-devel] [PATCH v1 3/3] hw/ppc/pnv_homer: add PowerNV homer device model

2019-09-10 Thread Balamuruhan S
On Wed, Sep 11, 2019 at 10:34:05AM +1000, David Gibson wrote: > On Tue, Sep 10, 2019 at 12:40:19PM +0530, Balamuruhan S wrote: > > add PnvHOMER device model to emulate homer memory access > > Please use PnvHomer as the identifier instead. I'm guessing that > messes with the us

Re: [Qemu-devel] [PATCH v1 3/3] hw/ppc/pnv_homer: add PowerNV homer device model

2019-09-10 Thread Balamuruhan S
On Tue, Sep 10, 2019 at 01:00:54PM +0200, Cédric Le Goater wrote: > >>> + > >>> +object_initialize_child(obj, "homer", >homer, > >>> sizeof(chip9->homer), > >>> +TYPE_PNV9_HOMER, _abort, NULL); > >>> +object_property_add_const_link(OBJECT(>homer), "chip", obj,

Re: [Qemu-devel] [PATCH v1 0/3] add Homer/OCC common area emulation for PowerNV

2019-09-10 Thread Balamuruhan S
On Tue, Sep 10, 2019 at 01:45:55PM +0200, Cédric Le Goater wrote: > On 10/09/2019 09:10, Balamuruhan S wrote: > > Hi All, > > > > This is follow-up patch that implements HOMER and OCC SRAM device > > models to emulate homer memory and occ common area access for ps

Re: [Qemu-devel] [PATCH v1 3/3] hw/ppc/pnv_homer: add PowerNV homer device model

2019-09-10 Thread Balamuruhan S
On Tue, Sep 10, 2019 at 09:46:16AM +0200, Cédric Le Goater wrote: > On 10/09/2019 09:10, Balamuruhan S wrote: > > add PnvHOMER device model to emulate homer memory access > > for pstate table, occ-sensors, slw, occ static and dynamic > > values for Power8 and Power9 chips.

Re: [Qemu-devel] [PATCH v1 2/3] hw/ppc/pnv_occ: add sram device model for occ common area

2019-09-10 Thread Balamuruhan S
On Tue, Sep 10, 2019 at 09:19:11AM +0200, Cédric Le Goater wrote: > On 10/09/2019 09:10, Balamuruhan S wrote: > > emulate occ common area region with occ sram device model which > > occ and skiboot uses it to communicate regarding sensors, slw > > and HWMON in

[Qemu-devel] [PATCH v1 3/3] hw/ppc/pnv_homer: add PowerNV homer device model

2019-09-10 Thread Balamuruhan S
add PnvHOMER device model to emulate homer memory access for pstate table, occ-sensors, slw, occ static and dynamic values for Power8 and Power9 chips. Fix few coding style warnings given by checkpatch.pl. Signed-off-by: Balamuruhan S --- hw/ppc/Makefile.objs | 1 + hw/ppc/pnv.c

[Qemu-devel] [PATCH v1 1/3] hw/ppc/pnv_xscom: retrieve homer/occ base address from PBA BARs

2019-09-10 Thread Balamuruhan S
During PowerNV boot skiboot populates the device tree by retrieving base address of homer/occ common area from PBA BARs and prd ipoll mask by accessing xscom read/write accesses. Signed-off-by: Balamuruhan S --- hw/ppc/pnv_xscom.c | 34 ++ include/hw/ppc/pnv.h

[Qemu-devel] [PATCH v1 2/3] hw/ppc/pnv_occ: add sram device model for occ common area

2019-09-10 Thread Balamuruhan S
emulate occ common area region with occ sram device model which occ and skiboot uses it to communicate regarding sensors, slw and HWMON in PowerNV emulated host. Signed-off-by: Balamuruhan S --- hw/ppc/pnv.c | 8 + hw/ppc/pnv_occ.c | 78

[Qemu-devel] [PATCH v1 0/3] add Homer/OCC common area emulation for PowerNV

2019-09-10 Thread Balamuruhan S
by checkpatch.pl. I request for review, comments and suggestions for the changes. Balamuruhan S (3): hw/ppc/pnv_xscom: retrieve homer/occ base address from PBA BARs hw/ppc/pnv_occ: add sram device model for occ common area hw/ppc/pnv_homer: add PowerNV homer device model hw/ppc/Makefile.objs

Re: [Qemu-devel] [RFC PATCH 0/6] Enhancing Qemu MMIO emulation with scripting interface

2019-08-12 Thread Balamuruhan S
On 8/8/19 3:55 PM, Stefan Hajnoczi wrote: > On Wed, Aug 07, 2019 at 12:44:39PM +0530, Balamuruhan S wrote: >> This is a proposal to extend mmio callbacks in Qemu with scripting interface >> that is prototyped with python in this implementation. It gives ability to >> feed

Re: [Qemu-devel] [RFC PATCH 0/6] Enhancing Qemu MMIO emulation with scripting interface

2019-08-11 Thread Balamuruhan S
On 8/9/19 10:19 AM, David Gibson wrote: > On Wed, Aug 07, 2019 at 10:15:48AM +0200, Cédric Le Goater wrote: >> On 07/08/2019 09:14, Balamuruhan S wrote: >>> Hi All, >>> >>> This is a proposal to extend mmio callbacks in Qemu with scripting interfac

Re: [Qemu-devel] [RFC PATCH 1/6] utils/python_api: add scripting interface for Qemu with python lib

2019-08-11 Thread Balamuruhan S
On 8/9/19 2:16 PM, Stefan Hajnoczi wrote: > On Thu, Aug 08, 2019 at 11:53:07AM +0100, Daniel P. Berrangé wrote: >> On Thu, Aug 08, 2019 at 11:10:13AM +0100, Stefan Hajnoczi wrote: >>> On Wed, Aug 07, 2019 at 12:20:47PM +0200, Philippe Mathieu-Daudé wrote: > +void python_args_clean(char

Re: [Qemu-devel] [RFC PATCH 1/6] utils/python_api: add scripting interface for Qemu with python lib

2019-08-11 Thread Balamuruhan S
On 8/8/19 6:15 PM, Philippe Mathieu-Daudé wrote: > On 8/8/19 12:49 PM, Daniel P. Berrangé wrote: >> On Wed, Aug 07, 2019 at 12:44:40PM +0530, Balamuruhan S wrote: >>> Adds scripting interface with python library to call functions in >>> python modules from Qemu tha

Re: [Qemu-devel] [RFC PATCH 1/6] utils/python_api: add scripting interface for Qemu with python lib

2019-08-11 Thread Balamuruhan S
On 8/8/19 3:39 PM, Stefan Hajnoczi wrote: > On Wed, Aug 07, 2019 at 12:44:40PM +0530, Balamuruhan S wrote: >> +void python_args_init_cast_int(char *args[], int arg, int pos) >> +{ >> +args[pos]= malloc(sizeof(int)); >> +sprintf(args[pos], "%d", ar

Re: [Qemu-devel] [RFC PATCH 3/6] hw/ppc/pnv_homer: add homer/occ common area emulation for PowerNV

2019-08-11 Thread Balamuruhan S
On 8/9/19 10:14 AM, David Gibson wrote: > On Wed, Aug 07, 2019 at 09:54:55AM +0200, Cédric Le Goater wrote: >> On 07/08/2019 09:14, Balamuruhan S wrote: >>> Add mmio callback functions to enable homer/occ common area >>> to emulate pstate table, occ-sensors, slw, occ st

Re: [Qemu-devel] [RFC PATCH 6/6] hw/ppc/pnv_homer: add python interface support for homer/occ common area

2019-08-11 Thread Balamuruhan S
On 8/9/19 10:16 AM, David Gibson wrote: > On Wed, Aug 07, 2019 at 12:44:45PM +0530, Balamuruhan S wrote: >> use python interface APIs in homer/occ common area emulation to >> interact with scripts if provided else fallback to normal flow, >> it shows how simple to use the int

Re: [Qemu-devel] [RFC PATCH 6/6] hw/ppc/pnv_homer: add python interface support for homer/occ common area

2019-08-11 Thread Balamuruhan S
On 8/7/19 3:57 PM, Philippe Mathieu-Daudé wrote: > On 8/7/19 9:14 AM, Balamuruhan S wrote: >> use python interface APIs in homer/occ common area emulation to >> interact with scripts if provided else fallback to normal flow, >> it shows how simple to use the interface t

Re: [Qemu-devel] [RFC PATCH 5/6] hw/ppc/pnv_xscom: retrieve homer/occ base address from PBA BARs

2019-08-07 Thread Balamuruhan S
On Wed, Aug 07, 2019 at 10:01:58AM +0200, Cédric Le Goater wrote: > On 07/08/2019 09:14, Balamuruhan S wrote: > > During PowerNV boot skiboot populates the device tree by retrieving > > base address of homer/occ common area from PBA BARs and prd ipoll > > mask by acces

Re: [Qemu-devel] [RFC PATCH 0/6] Enhancing Qemu MMIO emulation with scripting interface

2019-08-07 Thread Balamuruhan S
On Wed, Aug 07, 2019 at 10:15:48AM +0200, Cédric Le Goater wrote: > On 07/08/2019 09:14, Balamuruhan S wrote: > > Hi All, > > > > This is a proposal to extend mmio callbacks in Qemu with scripting interface > > that is prototyped with python in this implementation. I

Re: [Qemu-devel] [RFC PATCH 4/6] hw/ppc/pnv: initialize and realize homer/occ common area

2019-08-07 Thread Balamuruhan S
On Wed, Aug 07, 2019 at 09:59:26AM +0200, Cédric Le Goater wrote: > On 07/08/2019 09:14, Balamuruhan S wrote: > > homer and occ common area region base address are initialized > > to create device tree and realized to map the address with > > mmio callbacks dur

Re: [Qemu-devel] [RFC PATCH 3/6] hw/ppc/pnv_homer: add homer/occ common area emulation for PowerNV

2019-08-07 Thread Balamuruhan S
On Wed, Aug 07, 2019 at 09:54:55AM +0200, Cédric Le Goater wrote: > On 07/08/2019 09:14, Balamuruhan S wrote: > > Add mmio callback functions to enable homer/occ common area > > to emulate pstate table, occ-sensors, slw, occ static and > > dynamic values for Power8 and Power9

[Qemu-devel] [RFC PATCH 5/6] hw/ppc/pnv_xscom: retrieve homer/occ base address from PBA BARs

2019-08-07 Thread Balamuruhan S
During PowerNV boot skiboot populates the device tree by retrieving base address of homer/occ common area from PBA BARs and prd ipoll mask by accessing xscom read/write accesses. Signed-off-by: Balamuruhan S --- hw/ppc/pnv_xscom.c | 27 +++ 1 file changed, 23 insertions

[Qemu-devel] [RFC PATCH 3/6] hw/ppc/pnv_homer: add homer/occ common area emulation for PowerNV

2019-08-07 Thread Balamuruhan S
tree. currently skiboot disables the homer/occ code path with `QUIRK_NO_PBA`, this quirk have to be removed in skiboot for it to use this infrastructure. Signed-off-by: Hariharan T.S Signed-off-by: Balamuruhan S --- hw/ppc/Makefile.objs | 2 +- hw/ppc/pnv_homer.c | 185

[Qemu-devel] [RFC PATCH 6/6] hw/ppc/pnv_homer: add python interface support for homer/occ common area

2019-08-07 Thread Balamuruhan S
. Signed-off-by: Balamuruhan S --- hw/ppc/pnv_homer.c | 20 hw/ppc/pnv_xscom.c | 9 + include/sysemu/sysemu.h | 4 vl.c| 24 4 files changed, 53 insertions(+), 4 deletions(-) diff --git a/hw/ppc/pnv_homer.c b

[Qemu-devel] [RFC PATCH 4/6] hw/ppc/pnv: initialize and realize homer/occ common area

2019-08-07 Thread Balamuruhan S
base address + size contiguously on a PowerNV with multichip boot. Signed-off-by: Balamuruhan S --- hw/ppc/pnv.c | 49 + include/hw/ppc/pnv.h | 1 + 2 files changed, 46 insertions(+), 4 deletions(-) diff --git a/hw/ppc/pnv.c b/hw/ppc/pnv.c

[Qemu-devel] [RFC PATCH 0/6] Enhancing Qemu MMIO emulation with scripting interface

2019-08-07 Thread Balamuruhan S
xscom to adopt this python interface Patch 3 - 6: emulate uncore/core shared memory region with mmio callbacks and add support with this infrastructure. I request for comments, suggestions, ideas on getting a scripting interface like python added in qemu. Balamuruhan S (6): utils/python_api: add

[Qemu-devel] [RFC PATCH 2/6] hw/ppc/pnv_xscom: extend xscom to use python interface

2019-08-07 Thread Balamuruhan S
Existing xscom access emulation for read/write can be extended with the python interface to support feeding data externally. Signed-off-by: Balamuruhan S --- hw/ppc/pnv_xscom.c | 31 --- include/sysemu/sysemu.h | 4 qemu-options.hx | 14

[Qemu-devel] [RFC PATCH 1/6] utils/python_api: add scripting interface for Qemu with python lib

2019-08-07 Thread Balamuruhan S
maintenance. Signed-off-by: Balamuruhan S --- configure | 10 + include/sysemu/python_api.h | 30 + util/Makefile.objs | 1 + util/python_api.c | 100 4 files changed, 141 insertions(+) create mode

[Qemu-devel] [PATCH 2/3] tests/acceptance/avocado_qemu: add method to get supported machine types

2019-08-05 Thread Balamuruhan S
add `get_machine_types()` to return list of supported machine types by the qemu binary. Signed-off-by: Balamuruhan S --- tests/acceptance/avocado_qemu/__init__.py | 6 ++ 1 file changed, 6 insertions(+) diff --git a/tests/acceptance/avocado_qemu/__init__.py b/tests/acceptance/avocado_qemu

[Qemu-devel] [PATCH 1/3] tests/acceptance/migration: fix post migration check

2019-08-05 Thread Balamuruhan S
assert `query-migrate` in target doesn't give migration status and test errors even if migration succeeds. In target: {'execute': 'query-migrate'} {"return": {}} Signed-off-by: Balamuruhan S --- tests/acceptance/migration.py | 1 - 1 file changed, 1 deletion(-) diff --git a/tests/

[Qemu-devel] [PATCH 3/3] tests/acceptance/migration: test to migrate will all machine types

2019-08-05 Thread Balamuruhan S
add migration test to query machine types supported by qemu binary and migrate vm will all supported type. Signed-off-by: Balamuruhan S --- tests/acceptance/migration.py | 26 ++ 1 file changed, 26 insertions(+) diff --git a/tests/acceptance/migration.py b/tests

[Qemu-devel] [PATCH 0/3] Add acceptance test for migration

2019-08-05 Thread Balamuruhan S
TIME : 5.86 s Currently acceptance test for migration error out as we check `query-migrate` in target after migration which is not appropriate. Balamuruhan S (3): tests/acceptance/migration: fix post migration check tests/acceptance/avocado_qemu: add method to get supported machine

Re: [Qemu-devel] [PATCH 1/2] mmap-alloc: unfold qemu_ram_mmap()

2019-02-01 Thread Balamuruhan S
ve ptr and ptr1 meaningful names: > ptr -> guardptr : pointer to the PROT_NONE guard region > ptr1 -> ptr : pointer to the mapped memory returned to caller > > Signed-off-by: Murilo Opsfelder Araujo Reported-by: Balamuruhan S Tested-by: Balamuruhan S

Re: [Qemu-devel] [PATCH 2/2] mmap-alloc: fix hugetlbfs misaligned length in ppc64

2019-02-01 Thread Balamuruhan S
the underlying page size on ppc64. > > After this patch, memory hot-unplug releases huge pages back to the > pool. > > Fixes: 7197fb4058bcb68986bae2bb2c04d6370f3e7218 > Signed-off-by: Murilo Opsfelder Araujo Reported-by: Balamuruhan S Tested-by: Balamuruhan S I tried

Re: [Qemu-devel] [PATCH 1/1] migration: calculate expected_downtime considering redirtied ram

2019-01-30 Thread Balamuruhan S
On Thu, Jan 24, 2019 at 03:18:22PM +0800, Peter Xu wrote: > On Wed, Jan 23, 2019 at 05:35:03PM +0100, Juan Quintela wrote: > > bal...@linux.vnet.ibm.com wrote: > > > From: Balamuruhan S > > > > > > currently we calculate expected_downtime by time taken to tran

Re: [Qemu-devel] [PATCH for-3.0 0/9] migration: postcopy recovery unit test, bug fixes

2018-07-09 Thread Balamuruhan S
and stop patching, run "git am --abort". I have manually reverted it to apply and test your patchset. This Patchset is working without any issues. Tested-by: Balamuruhan S > > Peter Xu (9): > migration: simplify check to use qemu file buffer > migratio

Re: [Qemu-devel] [PATCH for-3.0 0/9] migration: postcopy recovery unit test, bug fixes

2018-07-06 Thread Balamuruhan S
On Fri, Jul 06, 2018 at 11:56:59AM +0100, Dr. David Alan Gilbert wrote: > * Dr. David Alan Gilbert (dgilb...@redhat.com) wrote: > > * Peter Xu (pet...@redhat.com) wrote: > > > Based-on: <20180627132246.5576-1-pet...@redhat.com> > > > > > > Based on the series to unbreak postcopy: > > > Subject:

Re: [Qemu-devel] [PATCH for-3.0 0/9] migration: postcopy recovery unit test, bug fixes

2018-07-06 Thread Balamuruhan S
On Fri, Jul 06, 2018 at 11:56:59AM +0100, Dr. David Alan Gilbert wrote: > * Dr. David Alan Gilbert (dgilb...@redhat.com) wrote: > > * Peter Xu (pet...@redhat.com) wrote: > > > Based-on: <20180627132246.5576-1-pet...@redhat.com> > > > > > > Based on the series to unbreak postcopy: > > > Subject:

Re: [Qemu-devel] [PATCH for-3.0 7/9] tests: introduce wait_for_migration_status()

2018-07-06 Thread Balamuruhan S
On Thu, Jul 05, 2018 at 11:17:53AM +0800, Peter Xu wrote: > It's generalized from wait_for_migration_complete() to allow us to wait > for any migration status besides failure. > > Signed-off-by: Peter Xu > --- Reviewed-by: Balamuruhan S > tests/migration-test.c | 10 ++

Re: [Qemu-devel] [PATCH for-3.0 5/9] tests: allow migrate() to take extra flags

2018-07-06 Thread Balamuruhan S
On Thu, Jul 05, 2018 at 11:17:51AM +0800, Peter Xu wrote: > For example, we can pass in '"resume": true' to resume a migration. > > Signed-off-by: Peter Xu > --- Reviewed-by: Balamuruhan S > tests/migration-test.c | 12 ++-- > 1 file changed, 6 insertions(

Re: [Qemu-devel] [PATCH for-3.0 4/9] tests: introduce migrate_postcopy_* helpers

2018-07-06 Thread Balamuruhan S
On Fri, Jul 06, 2018 at 10:19:51AM +0800, Peter Xu wrote: > On Thu, Jul 05, 2018 at 03:01:44PM +0530, Balamuruhan S wrote: > > On Thu, Jul 05, 2018 at 11:17:50AM +0800, Peter Xu wrote: > > > Separate the old postcopy UNIX socket test into three steps, provide a > >

Re: [Qemu-devel] [PATCH 2/2] tests: add precopy multifd migration with fd protocol

2018-07-05 Thread Balamuruhan S
On Fri, Jul 06, 2018 at 12:37:40PM +0800, Peter Xu wrote: > On Thu, Jul 05, 2018 at 06:22:31PM +0530, Balamuruhan S wrote: > > On Thu, Jul 05, 2018 at 05:26:09PM +0800, Peter Xu wrote: > > > On Thu, Jul 05, 2018 at 01:30:17PM +0530, Balamuruhan S wrote: > > > > Th

Re: [Qemu-devel] [PATCH 2/2] tests: add precopy multifd migration with fd protocol

2018-07-05 Thread Balamuruhan S
On Thu, Jul 05, 2018 at 05:26:09PM +0800, Peter Xu wrote: > On Thu, Jul 05, 2018 at 01:30:17PM +0530, Balamuruhan S wrote: > > This patch adds test for multifd migration feature with fd protocol. > > > > Signed-off-by: Balamuruhan S > > --- >

Re: [Qemu-devel] [PATCH for-3.0 6/9] tests: introduce migrate_query*() helpers

2018-07-05 Thread Balamuruhan S
On Thu, Jul 05, 2018 at 11:17:52AM +0800, Peter Xu wrote: > Introduce helpers to query migration states and use it. > > Signed-off-by: Peter Xu Looks good to me. Reviewed-by: Balamuruhan S > --- > tests/migration-test.c | 64 -- >

Re: [Qemu-devel] [PATCH for-3.0 4/9] tests: introduce migrate_postcopy_* helpers

2018-07-05 Thread Balamuruhan S
On Thu, Jul 05, 2018 at 11:17:50AM +0800, Peter Xu wrote: > Separate the old postcopy UNIX socket test into three steps, provide a > helper for each step. With these helpers, we can do more compliated > tests like postcopy recovery, while keep the codes shared. > > Signed-off-by: Peter Xu > ---

[Qemu-devel] [PATCH 2/2] tests: add precopy multifd migration with fd protocol

2018-07-05 Thread Balamuruhan S
This patch adds test for multifd migration feature with fd protocol. Signed-off-by: Balamuruhan S --- tests/migration-test.c | 57 ++ 1 file changed, 57 insertions(+) diff --git a/tests/migration-test.c b/tests/migration-test.c index e2434e70ea

[Qemu-devel] [PATCH 1/2] tests: add precopy multifd migration test with unix

2018-07-05 Thread Balamuruhan S
multifd migration feature is in with commit: 35374cbdff, this patch adds test for it using unix socket. Signed-off-by: Balamuruhan S --- tests/migration-test.c | 31 +++ 1 file changed, 31 insertions(+) diff --git a/tests/migration-test.c b/tests/migration-test.c

[Qemu-devel] [PATCH 0/2] tests: multifd migration test scenarios

2018-07-05 Thread Balamuruhan S
/multifd/fd: OK PASS: tests/migration-test Please help review, -- Bala Balamuruhan S (2): tests: add precopy multifd migration test tests: add precopy multifd migration with fd protocol tests/migration-test.c | 88 ++ 1 file changed, 88

Re: [Qemu-devel] [PATCH v3 0/4] migation: unbreak postcopy recovery

2018-07-02 Thread Balamuruhan S
On Mon, Jul 02, 2018 at 04:46:18PM +0800, Peter Xu wrote: > On Mon, Jul 02, 2018 at 01:34:45PM +0530, Balamuruhan S wrote: > > On Wed, Jun 27, 2018 at 09:22:42PM +0800, Peter Xu wrote: > > > v3: > > > - keep the recovery logic even for RDMA by dropping the 3rd

Re: [Qemu-devel] [PATCH v3 0/4] migation: unbreak postcopy recovery

2018-07-02 Thread Balamuruhan S
On Wed, Jun 27, 2018 at 09:22:42PM +0800, Peter Xu wrote: > v3: > - keep the recovery logic even for RDMA by dropping the 3rd patch and > touch up the original 4th patch (current 3rd patch) to suite that [Dave] > > v2: > - break the first patch into several > - fix a QEMUFile leak > > Please

Re: [Qemu-devel] [PULL 16/16] migration: fix crash in when incoming client channel setup fails

2018-06-29 Thread Balamuruhan S
On Thu, Jun 28, 2018 at 01:06:25PM +0200, Juan Quintela wrote: > Balamuruhan S wrote: > > On Wed, Jun 27, 2018 at 02:56:04PM +0200, Juan Quintela wrote: > >> From: Daniel P. Berrangé > > > > > Hi Juan, > > > > I tried to perform multifd enable

Re: [Qemu-devel] [PULL 16/16] migration: fix crash in when incoming client channel setup fails

2018-06-28 Thread Balamuruhan S
On Wed, Jun 27, 2018 at 02:56:04PM +0200, Juan Quintela wrote: > From: Daniel P. Berrangé > > The way we determine if we can start the incoming migration was > changed to use migration_has_all_channels() in: > > commit 428d89084c709e568f9cd301c2f6416a54c53d6d > Author: Juan Quintela >

[Qemu-devel] [PATCH v4 1/1] migration: calculate expected_downtime with ram_bytes_remaining()

2018-06-12 Thread Balamuruhan S
the `remaining` field in ram_counters to hold ram_bytes_remaining() for calculating expected_downtime. Reported-by: Michael Roth Signed-off-by: Balamuruhan S Signed-off-by: Laurent Vivier --- migration/migration.c | 3 +-- migration/ram.c | 1 + 2 files changed, 2 insertions(+), 2 deletions(-) diff

[Qemu-devel] [PATCH v4 0/1] migration: calculate expected_downtime with ram_bytes_remaining()

2018-06-12 Thread Balamuruhan S
actual value = 1054 milliseconds since v1: use ram_bytes_remaining() instead of dirty_pages_rate * page_size to calculate expected_downtime to be more accurate. Regards, Bala Balamuruhan S (1): migration: calculate expected_downtime with ram_bytes_remaining() migration/migration.c | 3 +-- migra

Re: [Qemu-devel] [PATCH v3 1/1] migration: calculate expected_downtime with ram_bytes_remaining()

2018-05-22 Thread Balamuruhan S
es: 1333940 kbytes dirty sync count: 6 page size: 4 kbytes > "transferred ram" continues to increase. If we do not set the downtime-limit, the remaining ram and transferred ram gets bumped up and migration continues infinitely. -- Bala > > so think there is a problem somewhere...

Re: [Qemu-devel] [PATCH v3] migration: update docs

2018-05-08 Thread Balamuruhan S
t | 532 +++ > 1 file changed, 376 insertions(+), 156 deletions(-) > Reviewed-by: Balamuruhan S <bal...@linux.vnet.ibm.com> > diff --git a/docs/devel/migration.rst b/docs/devel/migration.rst > index 9342a8af06..40f136f6be 100644 > --- a/docs/devel/m

Re: [Qemu-devel] [PATCH v3 1/1] migration: calculate expected_downtime with ram_bytes_remaining()

2018-05-01 Thread Balamuruhan S
Hi, Dave, David and Juan if you guys are okay with the patch, please help to merge it. Thanks, Bala On Wed, Apr 25, 2018 at 12:40:40PM +0530, Balamuruhan S wrote: > expected_downtime value is not accurate with dirty_pages_rate * page_size, > using ram_bytes_remaining would yeild it c

Re: [Qemu-devel] [PATCH v2] migration: update docs

2018-04-29 Thread Balamuruhan S
On Fri, Apr 27, 2018 at 06:34:16PM +0100, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Update the migration docs: > > Among other changes: > * Added a general list of advice for device authors > * Reordered the section on conditional state

Re: [Qemu-devel] [PATCH] migration: update docs

2018-04-25 Thread Balamuruhan S
On Fri, Apr 20, 2018 at 06:57:21PM +0100, Dr. David Alan Gilbert (git) wrote: > From: "Dr. David Alan Gilbert" > > Update the migration docs: > > Among other changes: > * Added a general list of advice for device authors > * Reordered the section on conditional state

[Qemu-devel] [PATCH v3 1/1] migration: calculate expected_downtime with ram_bytes_remaining()

2018-04-25 Thread Balamuruhan S
this patch bandwidth, expected_downtime and remaining ram are calculated in migration_update_counters(), retrieve the same value during "info migrate". By this approach we get almost close enough value. Reported-by: Michael Roth <mdr...@linux.vnet.ibm.com> Signed-

[Qemu-devel] [PATCH v3 0/1] migration: calculate expected_downtime with ram_bytes_remaining()

2018-04-25 Thread Balamuruhan S
on: calculated value = (14016 * 8 ) / 108.92 = 1029.452809401 milliseconds actual value = 1054 milliseconds since v1: use ram_bytes_remaining() instead of dirty_pages_rate * page_size to calculate expected_downtime to be more accurate. Regards, Bala Balamuruhan S (1): migration: calcula

Re: [Qemu-devel] [PATCH v2 1/1] migration: calculate expected_downtime with ram_bytes_remaining()

2018-04-21 Thread Balamuruhan S
On Fri, Apr 20, 2018 at 11:28:04AM +0100, Dr. David Alan Gilbert wrote: > * David Gibson (da...@gibson.dropbear.id.au) wrote: > > On Thu, Apr 19, 2018 at 12:24:04PM +0100, Dr. David Alan Gilbert wrote: > > > * Balamuruhan S (bal...@linux.vnet.ibm.com) wrote: > > > >

Re: [Qemu-devel] [PATCH v2 1/1] migration: calculate expected_downtime with ram_bytes_remaining()

2018-04-21 Thread Balamuruhan S
On Thu, Apr 19, 2018 at 09:48:17PM +1000, David Gibson wrote: > On Thu, Apr 19, 2018 at 10:14:52AM +0530, Balamuruhan S wrote: > > On Wed, Apr 18, 2018 at 09:36:33AM +0100, Dr. David Alan Gilbert wrote: > > > * Balamuruhan S (bal...@linux.vnet.ibm.com) wrote: > > > >

Re: [Qemu-devel] [PATCH v2 1/1] migration: calculate expected_downtime with ram_bytes_remaining()

2018-04-18 Thread Balamuruhan S
On Wed, Apr 18, 2018 at 09:36:33AM +0100, Dr. David Alan Gilbert wrote: > * Balamuruhan S (bal...@linux.vnet.ibm.com) wrote: > > On Wed, Apr 18, 2018 at 10:57:26AM +1000, David Gibson wrote: > > > On Wed, Apr 18, 2018 at 10:55:50AM +1000, David Gibson wrote: > > > >

Re: [Qemu-devel] [PATCH v2 1/1] migration: calculate expected_downtime with ram_bytes_remaining()

2018-04-18 Thread Balamuruhan S
On Wed, Apr 18, 2018 at 10:55:50AM +1000, David Gibson wrote: > On Tue, Apr 17, 2018 at 06:53:17PM +0530, Balamuruhan S wrote: > > expected_downtime value is not accurate with dirty_pages_rate * page_size, > > using ram_bytes_remaining would yeild it correct. > > This commi

Re: [Qemu-devel] [PATCH v2 1/1] migration: calculate expected_downtime with ram_bytes_remaining()

2018-04-18 Thread Balamuruhan S
On Wed, Apr 18, 2018 at 10:57:26AM +1000, David Gibson wrote: > On Wed, Apr 18, 2018 at 10:55:50AM +1000, David Gibson wrote: > > On Tue, Apr 17, 2018 at 06:53:17PM +0530, Balamuruhan S wrote: > > > expected_downtime value is not accurate with dirty_pages_rate * page

  1   2   >