[PATCH] npcm7xx_adc-test: Fix memleak in adc_qom_set

2021-01-17 Thread Gan Qixin
onvert_external ../tests/qtest/npcm7xx_adc-test.c:246 Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Hao Wu Cc: Havard Skinnemoen Cc: Tyrone Ting Cc: Thomas Huth Cc: Laurent Vivier --- tests/qtest/npcm7xx_adc-test.c | 1 + 1 file changed, 1 insertion(+) diff --git a/tests/qtest/npc

[PATCH] util/cacheflush: Fix error generated by clang

2021-01-14 Thread Gan Qixin
t64_t to fix it. Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Richard Henderson Cc: Paolo Bonzini --- util/cacheflush.c | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/util/cacheflush.c b/util/cacheflush.c index 6a20723902..933355b0c9 100644 --- a/

[PATCH] qtest/npcm7xx_pwm-test: Fix memleak in pwm_qom_get

2021-01-14 Thread Gan Qixin
toggle ../tests/qtest/npcm7xx_pwm-test.c:447 Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Havard Skinnemoen Cc: Tyrone Ting Cc: Thomas Huth Cc: Laurent Vivier --- tests/qtest/npcm7xx_pwm-test.c | 5 - 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/tests/qtest/npcm7

[PATCH v3 0/2] Fix some memleaks caused by timer_new_ns

2021-01-12 Thread Gan Qixin
ed, so delete it. Gan Qixin (2): pl031: Use timer_free() in the finalize function to avoid memleaks misc/mos6522: Use timer_free() in the finalize function to avoid memleak hw/misc/mos6522.c | 9 + hw/rtc/pl031.c| 8 2 files changed, 17 insertions(+) -- 2.27.0

[PATCH v3 2/2] misc/mos6522: Use timer_free() in the finalize function to avoid memleak

2021-01-12 Thread Gan Qixin
Robot Signed-off-by: Gan Qixin --- Cc: David Gibson --- hw/misc/mos6522.c | 9 + 1 file changed, 9 insertions(+) diff --git a/hw/misc/mos6522.c b/hw/misc/mos6522.c index ac4cd1d58e..1c57332b40 100644 --- a/hw/misc/mos6522.c +++ b/hw/misc/mos6522.c @@ -490,6 +490,14 @@ static void

[PATCH v3 1/2] pl031: Use timer_free() in the finalize function to avoid memleaks

2021-01-12 Thread Gan Qixin
-by: Gan Qixin --- Cc: Peter Maydell --- hw/rtc/pl031.c | 8 1 file changed, 8 insertions(+) diff --git a/hw/rtc/pl031.c b/hw/rtc/pl031.c index ae47f09635..2bbb2062ac 100644 --- a/hw/rtc/pl031.c +++ b/hw/rtc/pl031.c @@ -194,6 +194,13 @@ static void pl031_init(Object *obj) s->ti

[PATCH v2 0/2] Fix some memleaks caused by timer_new_ns

2021-01-12 Thread Gan Qixin
v1->v2: patch1: Delete the modification of unrelated whitespace. patch2: Add David Gibson acked tag. patch3: Has been applied, so delete it. Gan Qixin (2): pl031: Use timer_free() in the finalize function to avoid memleaks misc/mos6522: Use timer_free() in the finalize function

[PATCH v2 2/2] misc/mos6522: Use timer_free() in the finalize function to avoid memleak

2021-01-12 Thread Gan Qixin
Robot Signed-off-by: Gan Qixin Acked-by: David Gibson --- Cc: David Gibson --- hw/misc/mos6522.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/hw/misc/mos6522.c b/hw/misc/mos6522.c index ac4cd1d58e..0236eeece1 100644 --- a/hw/misc/mos6522.c +++ b/hw/misc/mos6522.c @@ -490,6

[PATCH v2 1/2] pl031: Use timer_free() in the finalize function to avoid memleaks

2021-01-12 Thread Gan Qixin
-by: Gan Qixin --- Cc: Peter Maydell --- hw/rtc/pl031.c | 9 + 1 file changed, 9 insertions(+) diff --git a/hw/rtc/pl031.c b/hw/rtc/pl031.c index ae47f09635..f0981e6c21 100644 --- a/hw/rtc/pl031.c +++ b/hw/rtc/pl031.c @@ -194,6 +194,14 @@ static void pl031_init(Object *obj) s->ti

[PATCH v2] qtest/libqtest: fix heap-buffer-overflow in qtest_cb_for_every_machine()

2021-01-05 Thread Gan Qixin
in (/lib64/libc.so.6+0x26d42) #4 0x5632c20b72cd in _start (build/tests/qtest/test-hmp+0x542cd) Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Thomas Huth Cc: Laurent Vivier v2: Changes suggested by Thomas Huth: Replace memcmp(..., 5) with strncmp(..., 5). --- tests/qtest/libq

[PATCH] qtest/libqtest.c: fix heap-buffer-overflow in qtest_cb_for_every_machine()

2021-01-04 Thread Gan Qixin
in (/lib64/libc.so.6+0x26d42) #4 0x5632c20b72cd in _start (build/tests/qtest/test-hmp+0x542cd) Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Thomas Huth Cc: Laurent Vivier --- tests/qtest/libqtest.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/qtest/li

[PATCH v2 3/7] exynos4210_mct: Use ptimer_free() in the finalize function to avoid memleaks

2020-12-17 Thread Gan Qixin
-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Igor Mitsyanko Cc: Peter Maydell --- hw/timer/exynos4210_mct.c | 14 ++ 1 file changed, 14 insertions(+) diff --git a/hw/timer/exynos4210_mct.c b/hw/timer/exynos4210_mct.c index 439053acd2..d0e5343996 100644 --- a/hw/timer

[PATCH v2 7/7] musicpal: Use ptimer_free() in the finalize function to avoid memleaks

2020-12-17 Thread Gan Qixin
: Euler Robot Signed-off-by: Gan Qixin --- Cc: Jan Kiszka Cc: Peter Maydell --- hw/arm/musicpal.c | 12 1 file changed, 12 insertions(+) diff --git a/hw/arm/musicpal.c b/hw/arm/musicpal.c index 458b1cbeb7..6aec84aeed 100644 --- a/hw/arm/musicpal.c +++ b/hw/arm/musicpal.c @@ -959,6

[PATCH v2 6/7] mss-timer: Use ptimer_free() in the finalize function to avoid memleaks

2020-12-17 Thread Gan Qixin
do_qmp_dispatch_bh /qemu/qapi/qmp-dispatch.c:110 Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Subbaraya Sundeep Cc: Peter Maydell --- hw/timer/mss-timer.c | 13 + 1 file changed, 13 insertions(+) diff --git a/hw/timer/mss-timer.c b/hw/timer/mss-timer.c index 29943fd744

[PATCH v2 4/7] exynos4210_pwm: Use ptimer_free() in the finalize function to avoid memleaks

2020-12-17 Thread Gan Qixin
:136 Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Igor Mitsyanko Cc: Peter Maydell --- hw/timer/exynos4210_pwm.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/hw/timer/exynos4210_pwm.c b/hw/timer/exynos4210_pwm.c index de181428b4..220088120e 100644 --- a/hw

[PATCH v2 5/7] exynos4210_rtc: Use ptimer_free() in the finalize function to avoid memleaks

2020-12-17 Thread Gan Qixin
: Euler Robot Signed-off-by: Gan Qixin --- Cc: Igor Mitsyanko Cc: Peter Maydell --- hw/rtc/exynos4210_rtc.c | 9 + 1 file changed, 9 insertions(+) diff --git a/hw/rtc/exynos4210_rtc.c b/hw/rtc/exynos4210_rtc.c index 4c97624478..45c0a951c4 100644 --- a/hw/rtc/exynos4210_rtc.c +++ b/hw/rtc

[PATCH v2 1/7] allwinner-a10-pit: Use ptimer_free() in the finalize function to avoid memleaks

2020-12-17 Thread Gan Qixin
Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Beniamino Galvani Cc: Peter Maydell --- hw/timer/allwinner-a10-pit.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/hw/timer/allwinner-a10-pit.c b/hw/timer/allwinner-a10-pit.c index f84fc0ea25..c3fc2a4daa 100644 --- a/hw

[PATCH v2 0/7] Fix some memleaks caused by ptimer_init

2020-12-17 Thread Gan Qixin
v1->v2: Changes suggested by Peter Maydell: Delete the modification of unrelated whitespace. Gan Qixin (7): allwinner-a10-pit: Use ptimer_free() in the finalize function to avoid memleaks digic-timer: Use ptimer_free() in the finalize function to avoid memleaks exynos4210_

[PATCH v2 2/7] digic-timer: Use ptimer_free() in the finalize function to avoid memleaks

2020-12-17 Thread Gan Qixin
do_qmp_dispatch_bh /qemu/qapi/qmp-dispatch.c:110 Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Antony Pavlov Cc: Peter Maydell --- hw/timer/digic-timer.c | 8 1 file changed, 8 insertions(+) diff --git a/hw/timer/digic-timer.c b/hw/timer/digic-timer.c index 32612228da..e3aae4a45a

[PATCH 3/3] s390x/cpu: Use timer_free() in the finalize function to avoid memleaks

2020-12-04 Thread Gan Qixin
: Euler Robot Signed-off-by: Gan Qixin --- Cc: Thomas Huth --- target/s390x/cpu.c | 5 + 1 file changed, 5 insertions(+) diff --git a/target/s390x/cpu.c b/target/s390x/cpu.c index 7b66718c44..8a734c2f8c 100644 --- a/target/s390x/cpu.c +++ b/target/s390x/cpu.c @@ -313,6 +313,11 @@ static void

[PATCH 1/3] pl031: Use timer_free() in the finalize function to avoid memleaks

2020-12-04 Thread Gan Qixin
-by: Gan Qixin --- Cc: Peter Maydell --- hw/rtc/pl031.c | 19 ++- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/hw/rtc/pl031.c b/hw/rtc/pl031.c index ae47f09635..2ea3dc1281 100644 --- a/hw/rtc/pl031.c +++ b/hw/rtc/pl031.c @@ -194,6 +194,14 @@ static void

[PATCH 2/3] misc/mos6522: Use timer_free() in the finalize function to avoid memleak

2020-12-04 Thread Gan Qixin
Robot Signed-off-by: Gan Qixin --- Cc: David Gibson --- hw/misc/mos6522.c | 11 +++ 1 file changed, 11 insertions(+) diff --git a/hw/misc/mos6522.c b/hw/misc/mos6522.c index ac4cd1d58e..0236eeece1 100644 --- a/hw/misc/mos6522.c +++ b/hw/misc/mos6522.c @@ -490,6 +490,16 @@ static void

[PATCH 0/3] Fix some memleaks caused by timer_new_ns

2020-12-04 Thread Gan Qixin
Hi all, When running device-introspect-test, I found some memory leaks caused by timer_new_ns in the init function, so I free it in the finalize function. Gan Qixin (3): pl031: Use timer_free() in the finalize function to avoid memleaks misc/mos6522: Use timer_free() in the finalize function

[PATCH] ppc/e500: Free irqs array to avoid memleak

2020-12-04 Thread Gan Qixin
Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: David Gibson --- hw/ppc/e500.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/ppc/e500.c b/hw/ppc/e500.c index ae39b9358e..74f33af88e 100644 --- a/hw/ppc/e500.c +++ b/hw/ppc/e500.c @@ -925,6 +925,7 @@ void ppce500_init(MachineState

[PATCH v2 4/4] block/iscsi: Use lock guard macros

2020-12-02 Thread Gan Qixin
Replace manual lock()/unlock() calls with lock guard macros (QEMU_LOCK_GUARD/WITH_QEMU_LOCK_GUARD) in block/iscsi. Signed-off-by: Gan Qixin --- Cc: Kevin Wolf Cc: Paolo Bonzini Cc: Markus Armbruster --- block/iscsi.c | 50 -- 1 file changed, 24

[PATCH v2 1/4] block/accounting: Use lock guard macros

2020-12-02 Thread Gan Qixin
Replace manual lock()/unlock() calls with lock guard macros (QEMU_LOCK_GUARD/WITH_QEMU_LOCK_GUARD) in block/accounting. Signed-off-by: Gan Qixin Reviewed-by: Paolo Bonzini --- Cc: Kevin Wolf Cc: Markus Armbruster --- block/accounting.c | 32 +++- 1 file changed

[PATCH v2 3/4] block/throttle-groups: Use lock guard macros

2020-12-02 Thread Gan Qixin
Replace manual lock()/unlock() calls with lock guard macros (QEMU_LOCK_GUARD/WITH_QEMU_LOCK_GUARD) in block/throttle-groups. Signed-off-by: Gan Qixin --- Cc: Kevin Wolf Cc: Paolo Bonzini Cc: Markus Armbruster --- block/throttle-groups.c | 48 - 1 file

[PATCH v2 0/4] Use lock guard macros in block

2020-12-02 Thread Gan Qixin
ong indentation format. -Patch4: Delete the .c suffix in the commit. Changes suggested by Kevin Wolf: Replace QEMU_LOCK_GUARD with WITH_QEMU_LOCK_GUARD, and delete the redundant qemu_mutex_unlock(). Gan Qixin (4): block/accounting: Use lock guard macros block/curl: Use lock guard mac

[PATCH v2 2/4] block/curl: Use lock guard macros

2020-12-02 Thread Gan Qixin
Replace manual lock()/unlock() calls with lock guard macros (QEMU_LOCK_GUARD/WITH_QEMU_LOCK_GUARD) in block/curl. Signed-off-by: Gan Qixin Reviewed-by: Paolo Bonzini --- Cc: Kevin Wolf Cc: Markus Armbruster --- block/curl.c | 28 ++-- 1 file changed, 14 insertions

[PATCH v2 10/12] tosa-ssp: put it into the 'misc' category

2020-11-30 Thread Gan Qixin
The category of the tosa-ssp device is not set, put it into the 'misc' category. Signed-off-by: Gan Qixin --- Cc: Peter Maydell --- hw/arm/tosa.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/arm/tosa.c b/hw/arm/tosa.c index fe88ed89fe..0e3461c8ed 100644 --- a/hw/arm/tosa.

[PATCH v2 09/12] u2f-passthru: put it into the 'misc' category

2020-11-30 Thread Gan Qixin
The category of the u2f-passthru device is not set, put it into the 'misc' category. Signed-off-by: Gan Qixin --- Cc: Gerd Hoffmann Cc: Philippe Mathieu-Daudé --- hw/usb/u2f-passthru.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/usb/u2f-passthru.c b/hw/usb/u2f-passth

[PATCH v2 11/12] spitz: put some Spitz-family devices into the correct category

2020-11-30 Thread Gan Qixin
Some Spitz-family devices have no category, put them into the correct category. Signed-off-by: Gan Qixin --- Cc: Peter Maydell --- hw/arm/spitz.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/arm/spitz.c b/hw/arm/spitz.c index 32bdeacfd3..0e5e8a4634 100644 --- a/hw/arm/spitz.c +++ b

[PATCH v2 06/12] ipmi: put some ipmi devices into the correct category

2020-11-30 Thread Gan Qixin
Some ipmi devices have no category, put them into the correct category. Signed-off-by: Gan Qixin --- Cc: Corey Minyard --- hw/ipmi/ipmi_bmc_extern.c | 1 + hw/ipmi/ipmi_bmc_sim.c| 1 + hw/ipmi/isa_ipmi_bt.c | 1 + hw/ipmi/isa_ipmi_kcs.c| 1 + hw/ipmi/pci_ipmi_bt.c | 1 + hw

[PATCH v2 07/12] tpm: put some tpm devices into the correct category

2020-11-30 Thread Gan Qixin
Some tpm devices have no category, put them into the correct category. Signed-off-by: Gan Qixin --- Cc: Stefan Berger --- hw/tpm/tpm_tis_isa.c| 1 + hw/tpm/tpm_tis_sysbus.c | 1 + 2 files changed, 2 insertions(+) diff --git a/hw/tpm/tpm_tis_isa.c b/hw/tpm/tpm_tis_isa.c index 6fd876eebf

[PATCH v2 04/12] nvdimm: put it into the 'storage' category

2020-11-30 Thread Gan Qixin
The category of the nvdimm device is not set, put it into the 'storage' category. Signed-off-by: Gan Qixin --- Cc: Xiao Guangrong --- hw/mem/nvdimm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/mem/nvdimm.c b/hw/mem/nvdimm.c index e1574bc07c..e30695b2ce 100644 --- a/hw/me

[PATCH v2 05/12] mc146818rtc: put it into the 'misc' category

2020-11-30 Thread Gan Qixin
The category of the mc146818rtc device is not set, put it into the 'misc' category. Signed-off-by: Gan Qixin --- Cc: Michael S. Tsirkin --- hw/rtc/mc146818rtc.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/rtc/mc146818rtc.c b/hw/rtc/mc146818rtc.c index 7a38540cb9..39edca0

[PATCH v2 02/12] virtio-pmem: put it into the 'storage' category

2020-11-30 Thread Gan Qixin
The category of the virtio-pmem device is not set, put it into the 'storage' category. Signed-off-by: Gan Qixin Reviewed-by: Pankaj Gupta --- Cc: Michael S. Tsirkin --- hw/virtio/virtio-pmem.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/virtio/virtio-pmem.c b/hw/vir

[PATCH v2 03/12] vmmouse: put it into the 'input' category

2020-11-30 Thread Gan Qixin
The category of the vmmouse device is not set, put it into the 'input' category. Signed-off-by: Gan Qixin Reviewed-by: Philippe Mathieu-Daudé --- Cc: Michael S. Tsirkin --- hw/i386/vmmouse.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/i386/vmmouse.c b/hw/i386/vmmou

[PATCH v2 08/12] AMDVI-PCI: put it into the 'misc' category

2020-11-30 Thread Gan Qixin
The category of the AMDVI-PCI device is not set, put it into the 'misc' category. Signed-off-by: Gan Qixin --- Cc: Paolo Bonzini --- hw/i386/amd_iommu.c | 8 1 file changed, 8 insertions(+) diff --git a/hw/i386/amd_iommu.c b/hw/i386/amd_iommu.c index 74a93a5d93..1d4e488

[PATCH v2 12/12] SPI flash devices: put them into the 'storage' category

2020-11-30 Thread Gan Qixin
SPI flash devices have no category, put them into the 'storage' category. Signed-off-by: Gan Qixin Reviewed-by: Alistair Francis Reviewed-by: Philippe Mathieu-Daudé --- hw/block/m25p80.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/block/m25p80.c b/hw/block/m25p80.c index

[PATCH v2 00/12] Categorize some uncategorized devices

2020-11-30 Thread Gan Qixin
cm2835_cprman is not an usable device, so delete the patch that categorize it. Gan Qixin (12): pc-dimm: put it into the 'storage' category virtio-pmem: put it into the 'storage' category vmmouse: put it into the 'input' category nvdimm: put it into the '

[PATCH v2 01/12] pc-dimm: put it into the 'storage' category

2020-11-30 Thread Gan Qixin
The category of the pc-dimm device is not set, put it into the 'storage' category. Signed-off-by: Gan Qixin --- Cc: Michael S. Tsirkin --- hw/mem/pc-dimm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/mem/pc-dimm.c b/hw/mem/pc-dimm.c index 2ffc986734..017146e3d1 100644 --

[PATCH 7/7] musicpal: Use ptimer_free() in the finalize function to avoid memleaks

2020-11-26 Thread Gan Qixin
-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Jan Kiszka --- hw/arm/musicpal.c | 22 +- 1 file changed, 17 insertions(+), 5 deletions(-) diff --git a/hw/arm/musicpal.c b/hw/arm/musicpal.c index 458b1cbeb7..0e77082e52 100644 --- a/hw/arm/musicpal.c +++ b/hw/arm/musicpal.c

[PATCH 5/7] exynos4210_rtc: Use ptimer_free() in the finalize function to avoid memleaks

2020-11-26 Thread Gan Qixin
: Euler Robot Signed-off-by: Gan Qixin --- Cc: Igor Mitsyanko --- hw/rtc/exynos4210_rtc.c | 19 ++- 1 file changed, 14 insertions(+), 5 deletions(-) diff --git a/hw/rtc/exynos4210_rtc.c b/hw/rtc/exynos4210_rtc.c index 4c97624478..2f667fb010 100644 --- a/hw/rtc/exynos4210_rtc.c

[PATCH 4/7] exynos4210_pwm: Use ptimer_free() in the finalize function to avoid memleaks

2020-11-26 Thread Gan Qixin
/async.c:136 Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Igor Mitsyanko --- hw/timer/exynos4210_pwm.c | 21 - 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/hw/timer/exynos4210_pwm.c b/hw/timer/exynos4210_pwm.c index de181428b4..4764164d5e 100644 --- a

[PATCH 6/7] mss-timer: Use ptimer_free() in the finalize function to avoid memleaks

2020-11-26 Thread Gan Qixin
do_qmp_dispatch_bh /qemu/qapi/qmp-dispatch.c:110 Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Subbaraya Sundeep --- hw/timer/mss-timer.c | 23 ++- 1 file changed, 18 insertions(+), 5 deletions(-) diff --git a/hw/timer/mss-timer.c b/hw/timer/mss-timer.c index 29943fd744

[PATCH 2/7] digic-timer: Use ptimer_free() in the finalize function to avoid memleaks

2020-11-26 Thread Gan Qixin
do_qmp_dispatch_bh /qemu/qapi/qmp-dispatch.c:110 Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Antony Pavlov --- hw/timer/digic-timer.c | 18 +- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/hw/timer/digic-timer.c b/hw/timer/digic-timer.c index 32612228da

[PATCH 3/7] exynos4210_mct: Use ptimer_free() in the finalize function to avoid memleaks

2020-11-26 Thread Gan Qixin
-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Igor Mitsyanko --- hw/timer/exynos4210_mct.c | 24 +++- 1 file changed, 19 insertions(+), 5 deletions(-) diff --git a/hw/timer/exynos4210_mct.c b/hw/timer/exynos4210_mct.c index 439053acd2..7172ec425d 100644 --- a/hw/timer

[PATCH 1/7] allwinner-a10-pit: Use ptimer_free() in the finalize function to avoid memleaks

2020-11-26 Thread Gan Qixin
Reported-by: Euler Robot Signed-off-by: Gan Qixin --- Cc: Beniamino Galvani --- hw/timer/allwinner-a10-pit.c | 21 - 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/hw/timer/allwinner-a10-pit.c b/hw/timer/allwinner-a10-pit.c index f84fc0ea25..be211983b0 100644

[PATCH 0/7] Fix some memleaks caused by ptimer_init

2020-11-26 Thread Gan Qixin
Hi all, When running device-introspect-test, I found some memory leaks caused by ptimer_init in the init function, so I released it in the finalize function. Gan Qixin (7): allwinner-a10-pit: Use ptimer_free() in the finalize function to avoid memleaks digic-timer: Use ptimer_free() in

[PATCH 10/13] tosa-ssp: put it into the 'misc' category

2020-11-16 Thread Gan Qixin
The category of the tosa-ssp device is not set, put it into the 'misc' category. Signed-off-by: Gan Qixin --- Cc: Peter Maydell --- hw/arm/tosa.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/arm/tosa.c b/hw/arm/tosa.c index fe88ed89fe..0e3461c8ed 100644 --- a/hw/arm/tosa.

[PATCH 06/13] ipmi: put some ipmi devices into the correct category

2020-11-16 Thread Gan Qixin
Some ipmi devices have no category, put them into the correct category. Signed-off-by: Gan Qixin --- Cc: Corey Minyard --- hw/ipmi/ipmi_bmc_extern.c | 1 + hw/ipmi/ipmi_bmc_sim.c| 1 + hw/ipmi/isa_ipmi_bt.c | 1 + hw/ipmi/isa_ipmi_kcs.c| 1 + hw/ipmi/pci_ipmi_bt.c | 1 + hw

[PATCH 13/13] bcm2835_cprman: put some peripherals of bcm2835 cprman into the 'misc' category

2020-11-16 Thread Gan Qixin
Some peripherals of bcm2835 cprman have no category, put them into the 'misc' category. Signed-off-by: Gan Qixin --- Cc: Philippe Mathieu-Daud?? --- hw/misc/bcm2835_cprman.c | 4 1 file changed, 4 insertions(+) diff --git a/hw/misc/bcm2835_cprman.c b/hw/misc/bcm2835_cprm

[PATCH 07/13] tpm: put some tpm devices into the correct category

2020-11-16 Thread Gan Qixin
Some tpm devices have no category, put them into the correct category. Signed-off-by: Gan Qixin --- Cc: Stefan Berger --- hw/tpm/tpm_tis_isa.c| 1 + hw/tpm/tpm_tis_sysbus.c | 1 + 2 files changed, 2 insertions(+) diff --git a/hw/tpm/tpm_tis_isa.c b/hw/tpm/tpm_tis_isa.c index 6fd876eebf

[PATCH 12/13] SPI flash devices: put them into the 'storage' category

2020-11-16 Thread Gan Qixin
SPI flash devices have no category, put them into the 'storage' category. Signed-off-by: Gan Qixin --- Cc: Alistair Francis --- hw/block/m25p80.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/block/m25p80.c b/hw/block/m25p80.c index 483925f57a..8dd3ef8559 100644 --- a/hw/bl

[PATCH 08/13] AMDVI-PCI: put it into the 'misc' category

2020-11-16 Thread Gan Qixin
The category of the AMDVI-PCI device is not set, put it into the 'misc' category. Signed-off-by: Gan Qixin --- Cc: Paolo Bonzini --- hw/i386/amd_iommu.c | 8 1 file changed, 8 insertions(+) diff --git a/hw/i386/amd_iommu.c b/hw/i386/amd_iommu.c index 74a93a5d93..1d4e488

[PATCH 04/13] nvdimm: put it into the 'storage' category

2020-11-16 Thread Gan Qixin
The category of the nvdimm device is not set, put it into the 'storage' category. Signed-off-by: Gan Qixin --- Cc: Xiao Guangrong --- hw/mem/nvdimm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/mem/nvdimm.c b/hw/mem/nvdimm.c index e1574bc07c..e30695b2ce 100644 --- a/hw/me

[PATCH 11/13] spitz: put some Spitz-family devices into the correct category

2020-11-16 Thread Gan Qixin
Some Spitz-family devices have no category, put them into the correct category. Signed-off-by: Gan Qixin --- Cc: Peter Maydell --- hw/arm/spitz.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/arm/spitz.c b/hw/arm/spitz.c index 32bdeacfd3..0e5e8a4634 100644 --- a/hw/arm/spitz.c +++ b

[PATCH 02/13] virtio-pmem: put it into the 'storage' category

2020-11-16 Thread Gan Qixin
The category of the virtio-pmem device is not set, put it into the 'storage' category. Signed-off-by: Gan Qixin --- Cc: Michael S. Tsirkin --- hw/virtio/virtio-pmem.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/virtio/virtio-pmem.c b/hw/virtio/virtio-pmem.c index

[PATCH 03/13] vmmouse: put it into the 'input' category

2020-11-16 Thread Gan Qixin
The category of the vmmouse device is not set, put it into the 'input' category. Signed-off-by: Gan Qixin --- Cc: Michael S. Tsirkin --- hw/i386/vmmouse.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/i386/vmmouse.c b/hw/i386/vmmouse.c index a3556438f0..df4798f502 100644 ---

[PATCH 05/13] mc146818rtc: put it into the 'misc' category

2020-11-16 Thread Gan Qixin
The category of the mc146818rtc device is not set, put it into the 'misc' category. Signed-off-by: Gan Qixin --- Cc: Michael S. Tsirkin --- hw/rtc/mc146818rtc.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/rtc/mc146818rtc.c b/hw/rtc/mc146818rtc.c index 7a38540cb9..39edca0

[PATCH 09/13] u2f-passthru: put it into the 'usb' category

2020-11-16 Thread Gan Qixin
The category of the u2f-passthru device is not set, put it into the 'usb' category. Signed-off-by: Gan Qixin --- Cc: Gerd Hoffmann --- hw/usb/u2f-passthru.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/usb/u2f-passthru.c b/hw/usb/u2f-passthru.c index ae00e93f35..000822f

[PATCH 00/13] Categorize some uncategorized devices

2020-11-16 Thread Gan Qixin
Hi all, By running "qemu-system-x86_64 -device help" and "qemu-system-arm -M none -device help", I found many uncategorized devices. Therefore, I categorized them. Thanks, Gan Qixin Gan Qixin (13): pc-dimm: put it into the 'storage' category virtio-pmem: put

[PATCH 01/13] pc-dimm: put it into the 'storage' category

2020-11-16 Thread Gan Qixin
The category of the pc-dimm device is not set, put it into the 'storage' category. Signed-off-by: Gan Qixin --- Cc: Michael S. Tsirkin --- hw/mem/pc-dimm.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/mem/pc-dimm.c b/hw/mem/pc-dimm.c index 2ffc986734..017146e3d1 100644 --

[PATCH] ads7846: moves from the hw/display folder to the hw/input folder.

2020-11-15 Thread Gan Qixin
ads7846 is a touch-screen controller that is an input device rather than a display device, so move it to the hw/input folder. Signed-off-by: Gan Qixin --- hw/arm/Kconfig | 2 +- hw/display/Kconfig | 3 --- hw/display/meson.build | 1 - hw/input/Kconfig

[PATCH v3 1/4] ssd0323: put it into the 'display' category

2020-11-12 Thread Gan Qixin
The category of the ssd0323 device is not set, put it into the 'display' category. Signed-off-by: Gan Qixin Reviewed-by: Thomas Huth --- hw/display/ssd0323.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/display/ssd0323.c b/hw/display/ssd0323.c index 17d4b32ae3..cbfd21d

[PATCH v3 4/4] max111x: put it into the 'misc' category

2020-11-12 Thread Gan Qixin
The category of the max111x device is not set, put it into the 'misc' category. Signed-off-by: Gan Qixin --- hw/misc/max111x.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/misc/max111x.c b/hw/misc/max111x.c index 7e6723f343..eae0f9b598 100644 --- a/hw/misc/max111x.c +++

[PATCH v3 3/4] nand: put it into the 'storage' category

2020-11-12 Thread Gan Qixin
The category of the nand device is not set, put it into the 'storage' category. Signed-off-by: Gan Qixin Reviewed-by: Thomas Huth --- hw/block/nand.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/block/nand.c b/hw/block/nand.c index bcceb64ebb..1d7a48a2ec 100644 --- a/hw/bl

[PATCH v3 2/4] ads7846: put it into the 'input' category

2020-11-12 Thread Gan Qixin
The category of the ads7846 device is not set, put it into the 'input' category. Signed-off-by: Gan Qixin --- Cc: Peter Maydell --- hw/display/ads7846.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/display/ads7846.c b/hw/display/ads7846.c index 023165b2a3..cb3a431cfd 10

[PATCH v3 0/4] Categorize some uncategorized devices

2020-11-12 Thread Gan Qixin
v1->v2: Correct some spelling errors and limit commit message line length to around 70. v2->v3: Changes suggested by Peter Maydell: ads7846 is a touch-screen controller, so put it into the 'input' category instead of 'display' category. Gan Qixin (4):

[PATCH v2 3/4] nand: put it into the 'storage' category

2020-11-11 Thread Gan Qixin
The category of the nand device is not set, put it into the 'storage' category. Signed-off-by: Gan Qixin --- hw/block/nand.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/block/nand.c b/hw/block/nand.c index bcceb64ebb..1d7a48a2ec 100644 --- a/hw/block/nand.c +++ b/hw/bl

[PATCH v2 2/4] ads7846: put it into the 'display' category

2020-11-11 Thread Gan Qixin
The category of the ads7846 device is not set, put it into the 'display' category. Signed-off-by: Gan Qixin --- hw/display/ads7846.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/display/ads7846.c b/hw/display/ads7846.c index 023165b2a3..b455cb5acd 100644 --- a/hw/display

[PATCH v2 4/4] max111x: put it into the 'misc' category

2020-11-11 Thread Gan Qixin
The category of the max111x device is not set, put it into the 'misc' category. Signed-off-by: Gan Qixin --- hw/misc/max111x.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/misc/max111x.c b/hw/misc/max111x.c index 7e6723f343..eae0f9b598 100644 --- a/hw/misc/max111x.c +++

[PATCH v2 0/4] Categorize some uncategorized devices

2020-11-11 Thread Gan Qixin
Hi all, I found some uncategorized devices and categorize them in these patches. Thanks, Gan Qixin v1->v2: Correct some spelling errors and limit commit message line length to around 70. Gan Qixin (4): ssd0323: put it into the 'display' category ads7846: put it into the '

[PATCH v2 1/4] ssd0323: put it into the 'display' category

2020-11-11 Thread Gan Qixin
The category of the ssd0323 device is not set, put it into the 'display' category. Signed-off-by: Gan Qixin --- hw/display/ssd0323.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/display/ssd0323.c b/hw/display/ssd0323.c index 17d4b32ae3..cbfd21dfd5 100644 --- a/hw/display

[PATCH 0/4] Categorize some uncategorized devices

2020-11-11 Thread Gan Qixin
Hi all, I categorize some uncategorized devices,could someone help me check it? Thanks, Gan Qixin Gan Qixin (4): ssd0323: put it into the 'dispaly' category ads7846: put it into the 'dispaly' category nand: put it into the 'storage' category max111x: put it

[PATCH 2/4] ads7846: put it into the 'dispaly' category

2020-11-11 Thread Gan Qixin
The category of the ads7846 device is not set, put it into the 'dispaly' category. Signed-off-by: Gan Qixin --- hw/display/ads7846.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/display/ads7846.c b/hw/display/ads7846.c index 023165b2a3..b455cb5acd 100644 --- a/hw/display

[PATCH 3/4] nand: put it into the 'storage' category

2020-11-11 Thread Gan Qixin
The category of the nand device is not set, put it into the 'storage' category. Signed-off-by: Gan Qixin --- hw/block/nand.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/block/nand.c b/hw/block/nand.c index bcceb64ebb..1d7a48a2ec 100644 --- a/hw/block/nand.c +++ b/hw/bl

[PATCH 1/4] ssd0323: put it into the 'dispaly' category

2020-11-11 Thread Gan Qixin
The category of the ssd0323 device is not set, put it into the 'dispaly' category. Signed-off-by: Gan Qixin --- hw/display/ssd0323.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/display/ssd0323.c b/hw/display/ssd0323.c index 17d4b32ae3..cbfd21dfd5 100644 --- a/hw/display

[PATCH 4/4] max111x: put it into the 'misc' category

2020-11-11 Thread Gan Qixin
The category of the max111x device is not set, put it into the 'misc' category. Signed-off-by: Gan Qixin --- hw/misc/max111x.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/misc/max111x.c b/hw/misc/max111x.c index 7e6723f343..eae0f9b598 100644 --- a/hw/misc/max111x.c +++

[PATCH 0/3] Fix LGPL information in the file headers

2020-11-11 Thread Gan Qixin
Hi all, I saw some tasks to replace "LGPL version 2" with "LGPL version 2.1" in BiteSizedTasks. So I modified the file in the test folder that contains "LGPL version 2". Thanks, Gan Qixin Gan Qixin (3): tests/migration: Fix LGPL information in the file header

[PATCH 2/3] tests/acceptance: Fix LGPL information in the file headers

2020-11-11 Thread Gan Qixin
There never was a "Lesser GPL version 2.0", It is either "GPL version 2.0" or "Lesser GPL version 2.1". This patch replaces all "Lesser GPL version 2.0" with "Lesser GPL version 2.1" in the tests/acceptance folder. Signed-off-by: Gan Qixin -

[PATCH 3/3] test: Fix LGPL information in the file headers

2020-11-11 Thread Gan Qixin
There never was a "Lesser GPL version 2.0", It is either "GPL version 2.0" or "Lesser GPL version 2.1". This patch replaces all "Lesser GPL version 2.0" with "Lesser GPL version 2.1" in the test folder. Signed-off-by: Gan Qixin --- tests/io-ch

[PATCH 1/3] tests/migration: Fix LGPL information in the file headers

2020-11-11 Thread Gan Qixin
There never was a "Lesser GPL version 2.0", It is either "GPL version 2.0" or "Lesser GPL version 2.1". This patch replaces all "Lesser GPL version 2.0" with "Lesser GPL version 2.1" in the tests/migration folder. Signed-off-by: Gan Qixin

[PATCH 3/4] block/throttle-groups.c: Use lock guard macros

2020-11-09 Thread Gan Qixin
Replace manual lock()/unlock() calls with lock guard macros (QEMU_LOCK_GUARD/WITH_QEMU_LOCK_GUARD) in block/throttle-groups.c. Signed-off-by: Gan Qixin --- block/throttle-groups.c | 48 - 1 file changed, 23 insertions(+), 25 deletions(-) diff --git a

[PATCH 2/4] block/curl.c: Use lock guard macros

2020-11-09 Thread Gan Qixin
Replace manual lock()/unlock() calls with lock guard macros (QEMU_LOCK_GUARD/WITH_QEMU_LOCK_GUARD) in block/curl.c. Signed-off-by: Gan Qixin --- block/curl.c | 28 ++-- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/block/curl.c b/block/curl.c index

[PATCH 1/4] block/accounting.c: Use lock guard macros

2020-11-09 Thread Gan Qixin
Replace manual lock()/unlock() calls with lock guard macros (QEMU_LOCK_GUARD/WITH_QEMU_LOCK_GUARD) in block/accounting.c. Signed-off-by: Gan Qixin --- block/accounting.c | 32 +++- 1 file changed, 15 insertions(+), 17 deletions(-) diff --git a/block/accounting.c b

[PATCH 4/4] block/iscsi.c: Use lock guard macros

2020-11-09 Thread Gan Qixin
Replace manual lock()/unlock() calls with lock guard macros (QEMU_LOCK_GUARD/WITH_QEMU_LOCK_GUARD) in block/iscsi.c. Signed-off-by: Gan Qixin --- block/iscsi.c | 28 +--- 1 file changed, 13 insertions(+), 15 deletions(-) diff --git a/block/iscsi.c b/block/iscsi.c index

[PATCH 0/4] Use lock guard macros in block

2020-11-09 Thread Gan Qixin
Hi all, I saw some tasks to replace manual lock()/unlock() calls with lock guard macros in BiteSizedTasks. I am very interested in this and modified some of the files under block. Could someone help me check the code? Thanks, Gan Qixin Gan Qixin (4): block/accounting.c: Use lock guard

[PATCH] scripts/checkpatch.pl: Modify the line length limit of the code

2020-11-05 Thread Gan Qixin
not go on next line whether the line length exceeds max_line_length or not Signed-off-by: Gan Qixin --- scripts/checkpatch.pl | 18 +- 1 file changed, 5 insertions(+), 13 deletions(-) diff --git a/scripts/checkpatch.pl b/scripts/checkpatch.pl index 88c858f67c..84a72d47ad 100755

[PATCH 08/10] hw/char/:split some lines containing more than 80 characters

2020-10-20 Thread Gan Qixin
By using scripts/checkpatch.pl, it is found that many files in hw/char/ contain lines with more than 80 characters. Signed-off-by: Gan Qixin --- hw/char/ibex_uart.c | 12 +--- hw/char/omap_uart.c | 3 +- hw/char/parallel.c | 12 +--- hw/char/serial.c

[PATCH 07/10] hw/pci-host/:split some lines containing more than 80 characters

2020-10-20 Thread Gan Qixin
By using scripts/checkpatch.pl, it is found that many files in hw/pci-host/ contain lines with more than 80 characters. Signed-off-by: Gan Qixin --- hw/pci-host/gpex-acpi.c | 18 -- hw/pci-host/pam.c | 4 ++-- hw/pci-host/ppce500.c | 8 +--- hw/pci-host/q35.c

[PATCH 10/10] hw/riscv/:split some lines containing more than 80 characters

2020-10-20 Thread Gan Qixin
By using scripts/checkpatch.pl, it is found that many files in hw/riscv/ contain lines with more than 80 characters. Signed-off-by: Gan Qixin --- hw/riscv/opentitan.c | 6 -- hw/riscv/sifive_e.c | 6 -- hw/riscv/sifive_u.c | 12 3 files changed, 16 insertions(+), 8

[PATCH 02/10] hw/core/:split some lines containing more than 80 characters

2020-10-20 Thread Gan Qixin
By using scripts/checkpatch.pl, it is found that many files in hw/core/ contain lines with more than 80 characters. Signed-off-by: Gan Qixin --- hw/core/bus.c| 3 ++- hw/core/loader.c | 17 +++-- hw/core/machine-hmp-cmds.c | 6 -- hw

[PATCH 09/10] hw/input/:split some lines containing more than 80 characters

2020-10-20 Thread Gan Qixin
By using scripts/checkpatch.pl, it is found that many files in hw/input/ contain lines with more than 80 characters. Signed-off-by: Gan Qixin --- hw/input/hid.c | 3 ++- hw/input/milkymist-softusb.c | 16 ++-- hw/input/pxa2xx_keypad.c | 3 ++- hw/input/virtio

[PATCH 05/10] hw/misc/:split some lines containing more than 80 characters

2020-10-20 Thread Gan Qixin
By using scripts/checkpatch.pl, it is found that many files in hw/misc/ contain lines with more than 80 characters. Signed-off-by: Gan Qixin --- hw/misc/aspeed_sdmc.c | 10 ++ hw/misc/bcm2835_mphi.c | 3 ++- hw/misc/edu.c | 3 ++- hw/misc/omap_gpmc.c| 3 ++- hw/misc

[PATCH 04/10] hw/intc/:split some lines containing more than 80 characters

2020-10-20 Thread Gan Qixin
By using scripts/checkpatch.pl, it is found that many files in hw/intc/ contain lines with more than 80 characters. Signed-off-by: Gan Qixin --- hw/intc/apic.c | 3 ++- hw/intc/arm_gic.c| 5 +++-- hw/intc/arm_gic_common.c | 3 ++- hw/intc/ioapic.c | 3 ++- hw/intc

[PATCH 00/10] Fix line over 80 characters warning

2020-10-20 Thread Gan Qixin
Hi all, I used scripts/checkpatch.pl to find that many files in the hw directory contain lines with more than 80 characters. Therefore, I splited some lines to fix this warning. Thanks, Gan Qixin Gan Qixin (10): hw/virtio/:split some lines containing more than 80 characters hw/core

[PATCH 01/10] hw/virtio/:split some lines containing more than 80 characters

2020-10-20 Thread Gan Qixin
By using scripts/checkpatch.pl, it is found that many files in hw/virtio/ contain lines with more than 80 characters. Signed-off-by: Gan Qixin --- hw/virtio/vhost-backend.c | 3 ++- hw/virtio/vhost-user-fs.c | 6 -- hw/virtio/vhost-user.c | 10 +- hw/virtio/virtio-balloon.c

[PATCH 03/10] hw/ide/:split some lines containing more than 80 characters

2020-10-20 Thread Gan Qixin
By using scripts/checkpatch.pl, it is found that many files in hw/ide/ contain lines with more than 80 characters. Signed-off-by: Gan Qixin --- hw/ide/ahci.c | 10 ++ hw/ide/atapi.c | 9 + hw/ide/cmd646.c | 3 ++- hw/ide/core.c | 21 ++--- hw/ide/piix.c

  1   2   >