[Qemu-block] [C v2 01/10] hw/m68k: add via support

2018-06-27 Thread Laurent Vivier
Co-developed-by: Mark Cave-Ayland Signed-off-by: Mark Cave-Ayland Signed-off-by: Laurent Vivier --- hw/misc/Makefile.objs | 1 + hw/misc/mac_via.c | 675 ++ include/hw/misc/mac_via.h | 106 3 files changed, 782 insertions

[Qemu-block] [C v2 03/10] escc: introduce a selector for the register bit

2018-06-27 Thread Laurent Vivier
bits usage must be swapped between registers and channels. For the moment all the machines use the bit 0, but this change will be needed to emulate Quadra 800. Signed-off-by: Laurent Vivier --- hw/char/escc.c | 30 -- include/hw/char/escc.h | 1 + 2 files

[Qemu-block] [C v2 02/10] ADB: VIA probes ADB bus when it is idle

2018-06-27 Thread Laurent Vivier
Co-developed-by: Mark Cave-Ayland Signed-off-by: Mark Cave-Ayland Signed-off-by: Laurent Vivier --- hw/input/adb-kbd.c| 4 ++ hw/input/adb-mouse.c | 4 ++ hw/input/adb.c| 115 ++ hw/misc/mac_via.c | 56

[Qemu-block] [C v2 00/10] hw/m68k: add Apple Machintosh Quadra 800 machine

2018-06-27 Thread Laurent Vivier
Update "dp8393x: manage big endian bus" with idea from Thomas Mark has reworked most of the patches: - use mos6522 - some code move, renamings and cleanup Laurent Vivier (10): hw/m68k: add via support ADB: VIA probes ADB bus when it is idle escc: introduce a selector

Re: [Qemu-block] [Qemu-devel] [RFC 01/13] hw/m68k: add via support

2018-06-10 Thread Laurent Vivier
Le 09/06/2018 à 17:48, Mark Cave-Ayland a écrit : > On 09/06/18 11:01, Mark Cave-Ayland wrote: > >> Yeah, we can certainly remove a huge chunk of this by converting over >> to the mos6522 device. My last set of updates to CUDA a couple of days >> ago are probably the best reference, but I can prob

Re: [Qemu-block] [Qemu-devel] [RFC 00/13] hw/m68k: add Apple Machintosh Quadra 800 machine

2018-06-09 Thread Laurent Vivier
Le 09/06/2018 à 05:26, Philippe Mathieu-Daudé a écrit : > On 06/08/2018 05:05 PM, Laurent Vivier wrote: >> I'm rebasing some of these patches for seven years now, >> too many years... >> >> It's an RFC because things have changed in QEMU in seven yea

[Qemu-block] [RFC 09/13] hw/m68k: define Macintosh Quadra 800

2018-06-08 Thread Laurent Vivier
From: Laurent Vivier Signed-off-by: Laurent Vivier --- default-configs/m68k-softmmu.mak | 12 ++ hw/display/macfb.c | 31 ++-- hw/m68k/Makefile.objs| 6 +- hw/m68k/bootinfo.h | 99 ++ hw/m68k/mac.c| 384

[Qemu-block] [RFC 07/13] hw/m68k: add Nubus support

2018-06-08 Thread Laurent Vivier
Signed-off-by: Laurent Vivier --- hw/Makefile.objs | 1 + hw/display/macfb.c | 67 +++- hw/nubus/Makefile.objs | 4 + hw/nubus/mac.c | 112 +++ hw/nubus/nubus-bridge.c | 34 ++ hw/nubus/nubus-bus.c | 60 +++ hw/nubus/nubus

[Qemu-block] [RFC 11/13] dp8393x: manage big endian bus

2018-06-08 Thread Laurent Vivier
This is needed by Quadra 800, this card can run on little-endian or big-endian bus. Signed-off-by: Laurent Vivier --- hw/net/dp8393x.c | 101 ++- 1 file changed, 70 insertions(+), 31 deletions(-) diff --git a/hw/net/dp8393x.c b/hw/net

[Qemu-block] [RFC 12/13] dp8393x: put DMA temp buffer in the state, not in the stack

2018-06-08 Thread Laurent Vivier
It's only 32 bytes, and this simplifies the dp8393x_get()/ dp8393x_put() interface. Signed-off-by: Laurent Vivier --- hw/net/dp8393x.c | 107 ++- 1 file changed, 51 insertions(+), 56 deletions(-) diff --git a/hw/net/dp8393x.c b/h

[Qemu-block] [RFC 05/13] hw/m68k: Apple Sound Chip (ASC) emulation

2018-06-08 Thread Laurent Vivier
From: Laurent Vivier This is broken as the linux driver seems broken too... Signed-off-by: Laurent Vivier --- hw/audio/Makefile.objs | 1 + hw/audio/asc.c | 492 + include/hw/audio/asc.h | 21 +++ 3 files changed, 514 insertions

[Qemu-block] [RFC 13/13] dp8393x: fix receiving buffer exhaustion

2018-06-08 Thread Laurent Vivier
buffers, but the card cannot receive new ones. This patch fixes the problem by not incrementing RRP when the driver clears the ISR RBE bit. Signed-off-by: Laurent Vivier --- hw/net/dp8393x.c | 31 --- 1 file changed, 16 insertions(+), 15 deletions(-) diff --git a/hw/net

[Qemu-block] [RFC 08/13] hw/m68k: add a dummy SWIM floppy controller

2018-06-08 Thread Laurent Vivier
Signed-off-by: Laurent Vivier --- hw/block/Makefile.objs | 1 + hw/block/swim.c| 325 + 2 files changed, 326 insertions(+) create mode 100644 hw/block/swim.c diff --git a/hw/block/Makefile.objs b/hw/block/Makefile.objs index 53ce5751ae

[Qemu-block] [RFC 00/13] hw/m68k: add Apple Machintosh Quadra 800 machine

2018-06-08 Thread Laurent Vivier
-out /boot/vmlinux-4.15.0-2-m68k . copy-out /boot/initrd.img-4.15.0-2-m68k . _EOF_ and boot with: ... -append "root=/dev/sda2 rw console=ttyS0 console=tty \ -kernel vmlinux-4.15.0-2-m68k \ -initrd initrd.img-4.15.0-2-m68k Laurent Vivier (13): hw/m68k: add via support ADB: VIA

[Qemu-block] [RFC 10/13] dp8393x: fix dp8393x_receive

2018-06-08 Thread Laurent Vivier
address_space_rw() access size must be multiplied by width. dp8393x_receive() must return the number of bytes read, not the length of the last memory access. Signed-off-by: Laurent Vivier --- hw/net/dp8393x.c | 8 +--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/hw/net

[Qemu-block] [RFC 03/13] escc: introduce a selector for the register bit

2018-06-08 Thread Laurent Vivier
From: Laurent Vivier On Sparc and PowerMac, the bit 0 of the address selects the register type (control or data) and bit 1 selects the channel (B or A). On m68k Macintosh, the bit 0 selects the channel and bit 1 the register type. This patch introduces a new parameter (bit_swap) to the device

[Qemu-block] [RFC 01/13] hw/m68k: add via support

2018-06-08 Thread Laurent Vivier
Signed-off-by: Laurent Vivier --- hw/input/adb.c| 99 - hw/misc/Makefile.objs | 1 + hw/misc/mac_via.c | 940 ++ include/hw/input/adb.h| 8 + include/hw/misc/mac_via.h | 45 +++ 5 files changed, 1092 insertions

[Qemu-block] [RFC 02/13] ADB: VIA probes ADB bus when it is idle

2018-06-08 Thread Laurent Vivier
Signed-off-by: Laurent Vivier --- hw/input/adb-kbd.c | 4 hw/input/adb-mouse.c | 4 hw/input/adb.c | 33 + hw/misc/mac_via.c | 27 ++- include/hw/input/adb.h | 1 + 5 files changed, 60 insertions(+), 9

[Qemu-block] [RFC 04/13] hw/m68k: add video card

2018-06-08 Thread Laurent Vivier
From: Laurent Vivier Signed-off-by: Laurent Vivier --- arch_init.c | 4 + hw/display/Makefile.objs| 1 + hw/display/macfb-template.h | 158 + hw/display/macfb.c | 283 qemu-options.hx

[Qemu-block] [RFC 06/13] ESP: add pseudo-DMA as used by Macintosh

2018-06-08 Thread Laurent Vivier
From: Laurent Vivier Signed-off-by: Laurent Vivier --- hw/mips/mips_jazz.c | 2 +- hw/scsi/esp.c | 330 +- include/hw/scsi/esp.h | 15 ++- 3 files changed, 313 insertions(+), 34 deletions(-) diff --git a/hw/mips/mips_jazz.c b/hw

Re: [Qemu-block] [PATCH 2/4] error: Remove NULL checks on error_propagate() calls

2018-03-26 Thread Laurent Vivier
On 23/03/2018 21:50, Eric Blake wrote: > On 03/22/2018 11:12 AM, Laurent Vivier wrote: >> Re-run Coccinelle patch >> scripts/coccinelle/error_propagate_null.cocci >> >> Signed-off-by: Laurent Vivier >> --- >>   io/channel-websock.c | 4 +--- >>

Re: [Qemu-block] [PATCH v2 0/5] coccinelle: re-run scripts from scripts/coccinelle

2018-03-23 Thread Laurent Vivier
On 23/03/2018 18:47, Eric Blake wrote: > On 03/23/2018 09:31 AM, Laurent Vivier wrote: >> I've re-run some scripts from the coccinelle directory, >> and they have found some problems. >> >> This series fixes them. >> >> v2: only change PATCH 4/4 &

[Qemu-block] [PATCH v2 5/5] Remove unnecessary variables for function return value

2018-03-23 Thread Laurent Vivier
Re-run Coccinelle script scripts/coccinelle/return_directly.cocci Signed-off-by: Laurent Vivier --- accel/tcg/translate-all.c | 5 +- block/quorum.c | 6 +-- hw/arm/exynos4210.c| 6 +-- hw/block

[Qemu-block] [PATCH v2 4/5] qdict: remove useless cast

2018-03-23 Thread Laurent Vivier
Re-run Coccinelle script scripts/coccinelle/qobject.cocci Signed-off-by: Laurent Vivier --- block/nvme.c | 11 +-- monitor.c| 2 +- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/block/nvme.c b/block/nvme.c index 8bca57aae6..c4f3a7bc94 100644 --- a/block/nvme.c

[Qemu-block] [PATCH v2 3/5] error: Remove NULL checks on error_propagate() calls

2018-03-23 Thread Laurent Vivier
Re-run Coccinelle patch scripts/coccinelle/error_propagate_null.cocci Signed-off-by: Laurent Vivier --- io/channel-websock.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/io/channel-websock.c b/io/channel-websock.c index ec48a305f0..e6608b969d 100644 --- a/io/channel

[Qemu-block] [PATCH v2 1/5] make: improve check for stale generated files in source dir

2018-03-23 Thread Laurent Vivier
From: Daniel P. Berrangé When doing a build with builddir != srcdir, if any generated files are accidentally present in srcdir from a previous build, these can cause unexpected failures. Currently there is a rule that checks for existance of config-host.mak, but there have been cases where confi

[Qemu-block] [PATCH v2 2/5] error: Strip trailing '\n' from error string arguments (again again)

2018-03-23 Thread Laurent Vivier
Re-run Coccinelle script scripts/coccinelle/err-bad-newline.cocci, and found new error_report() occurences with '\n'. Signed-off-by: Laurent Vivier --- target/i386/hvf/hvf.c | 24 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/target/i386/h

[Qemu-block] [PATCH v2 0/5] coccinelle: re-run scripts from scripts/coccinelle

2018-03-23 Thread Laurent Vivier
errangé (1): make: improve check for stale generated files in source dir Laurent Vivier (4): error: Strip trailing '\n' from error string arguments (again again) error: Remove NULL checks on error_propagate() calls qdict: remove useless cast Remove unnecessary variables for f

Re: [Qemu-block] [PATCH 0/4] coccinelle: re-run scripts from scripts/coccinelle

2018-03-23 Thread Laurent Vivier
On 23/03/2018 13:37, Michael Tokarev wrote: > 22.03.2018 19:12, Laurent Vivier wrote: >> I've re-run some scripts from the coccinelle directory, >> and they have found some problems. >> >> This series fixes them. >> >> Laurent Vivier (4): >> erro

Re: [Qemu-block] [PATCH 4/4] Remove unnecessary variables for function return value

2018-03-22 Thread Laurent Vivier
On 22/03/2018 17:51, Max Filippov wrote: > On Thu, Mar 22, 2018 at 9:12 AM, Laurent Vivier wrote: >> Re-run Coccinelle script scripts/coccinelle/return_directly.cocci >> >> Signed-off-by: Laurent Vivier >> --- >> target/xtensa/core-dc2

[Qemu-block] [PATCH 3/4] qdict: remove useless cast

2018-03-22 Thread Laurent Vivier
Re-run Coccinelle script scripts/coccinelle/qobject.cocci Signed-off-by: Laurent Vivier --- block/nvme.c | 11 +-- monitor.c| 2 +- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/block/nvme.c b/block/nvme.c index 8bca57aae6..c4f3a7bc94 100644 --- a/block/nvme.c

[Qemu-block] [PATCH 4/4] Remove unnecessary variables for function return value

2018-03-22 Thread Laurent Vivier
Re-run Coccinelle script scripts/coccinelle/return_directly.cocci Signed-off-by: Laurent Vivier --- accel/tcg/translate-all.c | 5 +- block/quorum.c | 6 +-- hw/arm/exynos4210.c| 7 +-- hw/block

[Qemu-block] [PATCH 2/4] error: Remove NULL checks on error_propagate() calls

2018-03-22 Thread Laurent Vivier
Re-run Coccinelle patch scripts/coccinelle/error_propagate_null.cocci Signed-off-by: Laurent Vivier --- io/channel-websock.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/io/channel-websock.c b/io/channel-websock.c index ec48a305f0..e6608b969d 100644 --- a/io/channel

[Qemu-block] [PATCH 1/4] error: Strip trailing '\n' from error string arguments (again again)

2018-03-22 Thread Laurent Vivier
Re-run Coccinelle script scripts/coccinelle/err-bad-newline.cocci, and found new error_report() occurences with '\n'. Signed-off-by: Laurent Vivier --- target/i386/hvf/hvf.c | 24 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/target/i386/h

[Qemu-block] [PATCH 0/4] coccinelle: re-run scripts from scripts/coccinelle

2018-03-22 Thread Laurent Vivier
I've re-run some scripts from the coccinelle directory, and they have found some problems. This series fixes them. Laurent Vivier (4): error: Strip trailing '\n' from error string arguments (again again) error: Remove NULL checks on error_propagate() calls qdict: remo

Re: [Qemu-block] [PATCH] scsi: turn "is this a SCSI device?" into a conditional hint

2018-03-21 Thread Laurent Vivier
nt. > > Reported-by: Ala Hino > Reviewed-by: Eric Blake > Signed-off-by: Paolo Bonzini > --- > hw/scsi/scsi-disk.c| 7 --- > hw/scsi/scsi-generic.c | 7 --- > 2 files changed, 8 insertions(+), 6 deletions(-) Reviewed-by: Laurent Vivier

Re: [Qemu-block] [Qemu-devel] [PATCH] scsi: turn "is this a SCSI device?" into a conditional hint

2018-03-21 Thread Laurent Vivier
On 21/03/2018 11:58, Paolo Bonzini wrote: > If the user does not have permissions to send ioctls to the device (due to > SELinux or cgroups, for example), the output can look like > > qemu-kvm: -device scsi-block,drive=disk: cannot get SG_IO version number: > Operation not permitted. Is this a

Re: [Qemu-block] [PATCH] qemu: include generated files with <> and not ""

2018-03-20 Thread Laurent Vivier
Le 20/03/2018 à 02:54, Michael S. Tsirkin a écrit : > QEMU coding style at the moment asks for all non-system > include files to be used with #include "foo.h". > However this rule actually does not make sense and > creates issues for when the included file is generated. If you change that, we can

Re: [Qemu-block] [Qemu-trivial] [PATCH] hw/block/onenand: Remove dead code block

2017-10-03 Thread Laurent Vivier
if (s->blockwp[b] == ONEN_LOCK_LOCKTIGHTEN) > break; > > Looks like a bad cut'n'paste from case 0x23. Reviewed-by: Laurent Vivier

Re: [Qemu-block] [Qemu-trivial] [PATCH] MAINTAINERS: Update paths for AioContext implementation

2017-05-03 Thread Laurent Vivier
AINERS > @@ -1177,8 +1177,8 @@ M: Stefan Hajnoczi > M: Fam Zheng > L: qemu-block@nongnu.org > S: Supported > -F: async.c > -F: aio-*.c > +F: util/async.c > +F: util/aio-*.c > F: block/io.c > F: migration/block* > F: include/block/aio.h > Reviewed-by: Laurent Vivier

Re: [Qemu-block] [Qemu-trivial] [PATCH] MAINTAINERS: Update paths for AioContext implementation

2017-05-03 Thread Laurent Vivier
On 03/05/2017 12:30, Paolo Bonzini wrote: > Signed-off-by: Paolo Bonzini > --- > MAINTAINERS | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/MAINTAINERS b/MAINTAINERS > index 46cf4870f9..62d62a6675 100644 > --- a/MAINTAINERS > +++ b/MAINTAINERS > @@ -1177,8 +1177,8 @

Re: [Qemu-block] [Qemu-trivial] [PATCH] iotests: Fix typo in 026

2017-04-27 Thread Laurent Vivier
On 27/04/2017 00:10, Eric Blake wrote: > s/refcout/refcount/ > > CC: qemu-triv...@nongnu.org > Signed-off-by: Eric Blake Reviewed-by: Laurent Vivier > --- > tests/qemu-iotests/026 | 2 +- > tests/qemu-iotests/026.out | 2 +- > tests/qemu-iot

Re: [Qemu-block] [PATCH for-2.9?] block/io: Comment out permission assertions

2017-04-12 Thread Laurent Vivier
On 12/04/2017 15:18, Kevin Wolf wrote: > Am 11.04.2017 um 17:07 hat Laurent Vivier geschrieben: >> On 11/04/2017 16:58, Kevin Wolf wrote: >>> Am 11.04.2017 um 16:50 hat Max Reitz geschrieben: >>>> In case of block migration, there may be writes to BlockBackends t

Re: [Qemu-block] [PATCH for-2.9?] block/io: Comment out permission assertions

2017-04-11 Thread Laurent Vivier
n Wolf > Tested-by: Kevin Wolf > With postcopy migration Tested-by: Laurent Vivier

Re: [Qemu-block] [PATCH v2 3/8] hw: Default -drive to if=none instead of ide when ide cannot work

2017-01-26 Thread Laurent Vivier
alone code to > honor if=ide. > > Cc: Peter Maydell > Cc: qemu-...@nongnu.org > Cc: Edgar E. Iglesias > Cc: Stefano Stabellini > Cc: Anthony Perard > Cc: xen-de...@lists.xensource.com > Cc: Michael Walle > Cc: Laurent Vivier > Cc: Anthony Green > Cc: Jia Liu > Cc: Alexande

[Qemu-block] [PATCH 7/7] sheepdog: remove useless casts

2016-06-15 Thread Laurent Vivier
This patch is the result of coccinelle script scripts/coccinelle/typecast.cocci CC: Hitoshi Mitake CC: qemu-block@nongnu.org Signed-off-by: Laurent Vivier --- block/sheepdog.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/block/sheepdog.c b/block/sheepdog.c index

[Qemu-block] [PATCH 04/16] qed: Use DIV_ROUND_UP

2016-05-31 Thread Laurent Vivier
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: qemu-block@nongnu.org Signed-off-by: Laurent Vivier --- block/qed-check.c | 3 +-- block/qed.c | 3 +-- 2 files changed, 2 insertions(+), 4 deletions

[Qemu-block] [PATCH 03/16] qcow/qcow2: Use DIV_ROUND_UP

2016-05-31 Thread Laurent Vivier
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: qemu-block@nongnu.org Signed-off-by: Laurent Vivier --- block/qcow.c | 4 ++-- block/qcow2-cluster.c | 4 ++-- block/qcow2-refcount.c | 6 ++ 3

[Qemu-block] [PATCH 02/16] parallels: Use DIV_ROUND_UP

2016-05-31 Thread Laurent Vivier
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: qemu-block@nongnu.org Signed-off-by: Laurent Vivier --- block/parallels.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/block/parallels.c

[Qemu-block] [PATCH 05/16] block: Use DIV_ROUND_UP

2016-05-31 Thread Laurent Vivier
Replace (((n) + (d) - 1) /(d)) by DIV_ROUND_UP(n,d). This patch is the result of coccinelle script scripts/coccinelle/round.cocci CC: qemu-block@nongnu.org Signed-off-by: Laurent Vivier --- block/vvfat.c | 3 +-- hw/block/tc58128.c | 2 +- 2 files changed, 2 insertions(+), 3 deletions

Re: [Qemu-block] [PATCH v2] block: Fix bdrv_drain in coroutine

2016-04-01 Thread Laurent Vivier
_coroutine_yield() >> qcow2:qemu_co_mutex_lock.return >> ... >tracked request end > ... > (resumed from BH callback) > bdrv_drain.return > ... > > Reported-by: Laurent Vivier > Suggested-by: Paolo Bonzini > Signed-off-by: Fam Zheng Tested-by: Laurent Vivier

Re: [Qemu-block] [PATCH] block: Fix bdrv_drain in coroutine

2016-04-01 Thread Laurent Vivier
() > > bdrv_drain > while (has tracked request) > aio_poll() > > In the scsi-disk coroutine, the qemu_co_mutex_lock() will never return > because the mirror coroutine is blocked in the aio_poll(blocking=true). > > Reported-by: Laurent Vivier I've che

Re: [Qemu-block] [Qemu-ppc] [PATCH] Replacing (and removing) get_ticks_per_sec() function with NANOSECONDS_PER_SECOND Signed-off-by: Rutuja Shah

2016-03-15 Thread Laurent Vivier
On 10/03/2016 20:30, rutu.shah...@gmail.com wrote: > From: Rutuja Shah > > --- > audio/audio.c | 2 +- > audio/noaudio.c | 4 ++-- > audio/spiceaudio.c| 2 +- > audio/wavaudio.c | 2 +- > backends/baum.c | 2 +- > block/qed.c

Re: [Qemu-block] [Qemu-devel] [PULL 08/17] block: Assert no write requests under BDRV_O_INCOMING

2016-02-19 Thread Laurent Vivier
On 19/02/2016 10:17, Kevin Wolf wrote: > Am 18.02.2016 um 17:03 hat Laurent Vivier geschrieben: >> Hi, >> >> this commit breaks incoming migration case: >> >> qemu-system-ppc64 XXX -incoming tcp:0: >> qemu-system-ppc64: .../qemu/block/io.c:1304:

Re: [Qemu-block] [Qemu-devel] [PULL 08/17] block: Assert no write requests under BDRV_O_INCOMING

2016-02-18 Thread Laurent Vivier
Hi, this commit breaks incoming migration case: qemu-system-ppc64 XXX -incoming tcp:0: qemu-system-ppc64: .../qemu/block/io.c:1304: bdrv_co_do_pwritev: Assertion `!(bs->open_flags & 0x0800)' failed. Without "-incoming", the same command line boots fine. Are you aware of the problem? Lauren

Re: [Qemu-block] [PATCH v3] virtio-blk: Fix double completion for werror=stop

2015-11-17 Thread Laurent Vivier
or it will be >> restarted and parsed from scratch out of the vq later. >> >> Signed-off-by: Fam Zheng >> >> --- >> >> v3: Fix as Stefan suggested. >> --- >> hw/block/virtio-blk.c | 4 >> 1 file changed, 4 insertions(+) >

Re: [Qemu-block] [PATCH v2] virtio-blk: Fix double completion for werror=stop

2015-11-16 Thread Laurent Vivier
Fix this by marking request R as "merged" and skipping it in > virtio_blk_handle_rw_error. > > Cc: qemu-sta...@nongnu.org > Signed-off-by: Fam Zheng > > --- > > v2: Don't lose the request in migration. [Paolo] Tested-by: Laurent Vivier > --- > hw

Re: [Qemu-block] [PATCH] virtio-blk: Fix double completion for werror=stop

2015-11-13 Thread Laurent Vivier
io/virtio-blk.h > +++ b/include/hw/virtio/virtio-blk.h > @@ -70,6 +70,7 @@ typedef struct VirtIOBlockReq { > size_t in_len; > struct VirtIOBlockReq *next; > struct VirtIOBlockReq *mr_next; > +bool merged; > BlockAcctCookie acct; > } VirtIOBlockReq; > > Tested-by: Laurent Vivier In my case, this patch fixes a memory corruption when the VM is stopped on io-error (no space) and restarted.

[Qemu-block] [PATCH 02/10][TRIVIAL] cmd646: add to storage category

2015-09-26 Thread Laurent Vivier
cmd646 is an IDE controller, so add it to the storage category. Signed-off-by: Laurent Vivier --- hw/ide/cmd646.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/ide/cmd646.c b/hw/ide/cmd646.c index 66fb9d9..27f3da2 100644 --- a/hw/ide/cmd646.c +++ b/hw/ide/cmd646.c @@ -417,6 +417,7

[Qemu-block] [PATCH 04/10][TRIVIAL] grackle: add to bridge category

2015-09-26 Thread Laurent Vivier
Grackle is the PCI host controller of oldworld powermac, so add it to the bridge category. Signed-off-by: Laurent Vivier --- hw/pci-host/grackle.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/pci-host/grackle.c b/hw/pci-host/grackle.c index bfe707a..ea31b72 100644 --- a/hw/pci-host

[Qemu-block] [PATCH 05/10][TRIVIAL] cuda: add to bridge category

2015-09-26 Thread Laurent Vivier
Cuda is a bridge between PowerMac system bus and the ADB controller, real-time clock, pram and the power management unit. So add it to the bridge category. Signed-off-by: Laurent Vivier --- hw/misc/macio/cuda.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/misc/macio/cuda.c b/hw/misc

[Qemu-block] [PATCH 03/10][TRIVIAL] escc: add to input category

2015-09-26 Thread Laurent Vivier
ESCC is a serial port controller, so add it to the input category. Signed-off-by: Laurent Vivier --- hw/char/escc.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/char/escc.c b/hw/char/escc.c index ba653ef..9816154 100644 --- a/hw/char/escc.c +++ b/hw/char/escc.c @@ -1035,6 +1035,7

[Qemu-block] [PATCH 07/10][TRIVIAL] uninorth: add to bridge category

2015-09-26 Thread Laurent Vivier
Uninorth is the mac99 PCI host controller, so add it to the bridge category. Signed-off-by: Laurent Vivier --- hw/pci-host/uninorth.c | 8 1 file changed, 8 insertions(+) diff --git a/hw/pci-host/uninorth.c b/hw/pci-host/uninorth.c index f0144eb..215b64f 100644 --- a/hw/pci-host

[Qemu-block] [PATCH 00/10][TRIVIAL] Define categories for some PPC devices

2015-09-26 Thread Laurent Vivier
Some PPC devices appear uncategorized in the output of "-device ?". This series tries to categorize some of them. Laurent Vivier (10): adb: add to input category cmd646: add to storage category escc: add to input category grackle: add to bridge category cuda: add to bridg

[Qemu-block] [PATCH 06/10][TRIVIAL] macio-ide: add to storage category

2015-09-26 Thread Laurent Vivier
macio-ide is an IDE controller, so add it to the storage category. Signed-off-by: Laurent Vivier --- hw/ide/macio.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/ide/macio.c b/hw/ide/macio.c index 66ac2ba..893c9b9 100644 --- a/hw/ide/macio.c +++ b/hw/ide/macio.c @@ -590,6 +590,7

[Qemu-block] [PATCH 10/10][TRIVIAL] openpic: add to misc category

2015-09-26 Thread Laurent Vivier
openpic is a programmable interrupt controller, so add it to the misc category. Signed-off-by: Laurent Vivier --- hw/intc/openpic.c | 1 + hw/intc/openpic_kvm.c | 1 + 2 files changed, 2 insertions(+) diff --git a/hw/intc/openpic.c b/hw/intc/openpic.c index 14ab0e3..bfcf155 100644 --- a/hw

[Qemu-block] [PATCH 08/10][TRIVIAL] macio: add to bridge category

2015-09-26 Thread Laurent Vivier
macio is a bridge between the PCI bus and the Mac nvram, IDE controller and PIC, so add it to the bridge category. Signed-off-by: Laurent Vivier --- hw/misc/macio/macio.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/misc/macio/macio.c b/hw/misc/macio/macio.c index e3c0242..c0989a0

[Qemu-block] [PATCH 01/10][TRIVIAL] adb: add to input category

2015-09-26 Thread Laurent Vivier
The Apple Desktop Bus is used to connect a keyboard and a mouse, so add it to the input category. Signed-off-by: Laurent Vivier --- hw/input/adb.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/hw/input/adb.c b/hw/input/adb.c index a18eea2..09eead9 100644 --- a/hw/input/adb.c +++ b/hw

[Qemu-block] [PATCH 09/10][TRIVIAL] macio-nvram: add to misc category

2015-09-26 Thread Laurent Vivier
The macio nvram is a non volatile RAM, so add it the misc category. Signed-off-by: Laurent Vivier --- hw/nvram/mac_nvram.c | 1 + 1 file changed, 1 insertion(+) diff --git a/hw/nvram/mac_nvram.c b/hw/nvram/mac_nvram.c index d35f8a3..9f16566 100644 --- a/hw/nvram/mac_nvram.c +++ b/hw/nvram

Re: [Qemu-block] [PATCH v2] raw-posix.c: Make physical devices usable in QEMU under Mac OS X host

2015-07-20 Thread Laurent Vivier
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 20/07/2015 12:48, Stefan Hajnoczi wrote: > On Fri, Jul 17, 2015 at 03:24:34PM -0400, Programmingkid wrote: >> >> On Jul 17, 2015, at 9:41 AM, Stefan Hajnoczi wrote: >> >>> On Thu, Jul 16, 2015 at 04:46:07PM -0400, Programmingkid >>> wrote:

Re: [Qemu-block] [Qemu-devel] [PATCH] raw-posix.c: Make physical devices usable in QEMU

2015-07-09 Thread Laurent Vivier
On 07/07/2015 19:33, Programmingkid wrote: > Make physical devices like a USB flash drive or a CDROM drive work in > QEMU. With > this patch I can use a USB flash drive like a hard drive. Before this > patch, > QEMU would just quit with a message like "resource busy". Now it handles > issues > l

Re: [Qemu-block] [PATCH] raw-posix.c: remove raw device access for cdrom

2015-07-08 Thread Laurent Vivier
On 08/07/2015 13:01, Kevin Wolf wrote: > Am 08.07.2015 um 12:47 hat Laurent Vivier geschrieben: >> >> >> On 08/07/2015 12:31, Kevin Wolf wrote: >>> Am 02.07.2015 um 16:18 hat Laurent Vivier geschrieben: >>>> >>>> >>>> On 02/07/2

Re: [Qemu-block] [PATCH] raw-posix.c: remove raw device access for cdrom

2015-07-08 Thread Laurent Vivier
On 08/07/2015 12:31, Kevin Wolf wrote: > Am 02.07.2015 um 16:18 hat Laurent Vivier geschrieben: >> >> >> On 02/07/2015 16:03, Paolo Bonzini wrote: >>> >>> >>> On 02/07/2015 15:58, Laurent Vivier wrote: >>>> Since any /dev entry can b

Re: [Qemu-block] [PATCH] raw-posix.c: remove raw device access for cdrom

2015-07-02 Thread Laurent Vivier
On 02/07/2015 16:03, Paolo Bonzini wrote: > > > On 02/07/2015 15:58, Laurent Vivier wrote: >> Since any /dev entry can be treated as a raw disk image, it is worth >> noting which devices can be accessed when and how. /dev/rdisk nodes are >> character-special device

Re: [Qemu-block] [PATCH] raw-posix.c: remove raw device access for cdrom

2015-07-02 Thread Laurent Vivier
On 02/07/2015 16:20, Paolo Bonzini wrote: > > > On 02/07/2015 16:18, Laurent Vivier wrote: >>>> I'm okay with doing the simple thing, but it needs a comment for >>>> non-BSDers. >> So, what we have to do, in our case, for MacOS X cd

Re: [Qemu-block] [PATCH] raw-posix.c: remove raw device access for cdrom

2015-07-02 Thread Laurent Vivier
On 02/07/2015 15:47, Paolo Bonzini wrote: > > > On 02/07/2015 14:24, Laurent Vivier wrote: >> >> #ifdef __FreeBSD__ >> if (S_ISCHR(st.st_mode)) { >> /* >> * The file is a char device (disk), which on FreeBSD isn't behind >&g

Re: [Qemu-block] [PATCH] raw-posix.c: remove raw device access for cdrom

2015-07-02 Thread Laurent Vivier
On 02/07/2015 13:14, Stefan Hajnoczi wrote: > On Wed, Jul 1, 2015 at 11:13 PM, Programmingkid > wrote: >> Fix real cdrom access in Mac OS X so it can be used in QEMU. >> It simply removes the r from a device file's name. This >> allows for a real cdrom to be accessible to the guest. >> It has be

Re: [Qemu-block] [PATCH] raw-posix.c: remove raw device access for cdrom

2015-07-02 Thread Laurent Vivier
On 02/07/2015 09:18, Paolo Bonzini wrote: > > > On 02/07/2015 00:13, Programmingkid wrote: >> Fix real cdrom access in Mac OS X so it can be used in QEMU. >> It simply removes the r from a device file's name. This >> allows for a real cdrom to be accessible to the guest. >> It has been successf

Re: [Qemu-block] [Qemu-devel] [PATCH] raw-posix.c: cd_is_inserted() implementation for Mac OS X

2015-06-29 Thread Laurent Vivier
On 29/06/2015 20:37, Programmingkid wrote: > > On Jun 29, 2015, at 2:16 PM, Peter Maydell wrote: > >> On 29 June 2015 at 19:04, Programmingkid > > wrote: >>> >>> On Jun 29, 2015, at 1:11 PM, Peter Maydell wrote: >>> On 29 June 2015 at 17:54, Programmingkid

Re: [Qemu-block] [Qemu-devel] [PATCH] block.c: fix real cdrom detection

2015-06-29 Thread Laurent Vivier
On 29/06/2015 05:01, Programmingkid wrote: > > On Jun 28, 2015, at 8:29 PM, Laurent Vivier wrote: > >> Hi, >> >> On 29/06/2015 01:43, Programmingkid wrote: >>> >>> On Jun 25, 2015, at 2:01 PM, Peter Maydell wrote: >>> >>>>

Re: [Qemu-block] [Qemu-devel] [PATCH] block.c: fix real cdrom detection

2015-06-28 Thread Laurent Vivier
Hi, On 29/06/2015 01:43, Programmingkid wrote: > > On Jun 25, 2015, at 2:01 PM, Peter Maydell wrote: > >> On 25 June 2015 at 18:56, Programmingkid >> wrote: >>> Nice to hear from you again Laurent. The only way a solution in >>> hdev_open() would work is if it could prevent >>> find_image_form

Re: [Qemu-block] [Qemu-devel] [PATCH] block.c: fix real cdrom detection

2015-06-26 Thread Laurent Vivier
On 25/06/2015 19:19, Laurent Vivier wrote: > > > On 25/06/2015 18:16, Paolo Bonzini wrote: >> >> >> On 25/06/2015 18:12, Laurent Vivier wrote: >>> >>> >>> On 25/06/2015 17:48, Paolo Bonzini wrote: >>>> >>>> On 25/06/

Re: [Qemu-block] [Qemu-devel] [PATCH] block.c: fix real cdrom detection

2015-06-25 Thread Laurent Vivier
On 25/06/2015 18:16, Paolo Bonzini wrote: > > > On 25/06/2015 18:12, Laurent Vivier wrote: >> >> >> On 25/06/2015 17:48, Paolo Bonzini wrote: >>> >>> On 25/06/2015 17:32, Programmingkid wrote: >>>>> I think we are going to have to

Re: [Qemu-block] [Qemu-devel] [PATCH] block.c: fix real cdrom detection

2015-06-25 Thread Laurent Vivier
On 25/06/2015 17:48, Paolo Bonzini wrote: > > On 25/06/2015 17:32, Programmingkid wrote: >>> I think we are going to have to agree to disagree. I have never >>> used the /dev/sr(0 | 1) devices and don't see how they would be >>> effected by this patch. Are you trying to say the /dev/sr(0 | 1) >>

<    1   2   3   4   5   6