Re: [PATCH v3 1/5] msmouse: Handle mouse reset

2022-09-29 Thread Arwed Meyer
Hi, thanks for the reminder and ack. I opened this issue: https://gitlab.com/qemu-project/qemu/-/issues/1234 (wow, it's really 1234) Best regards, Arwed Am 27.09.22 um 11:21 schrieb Marc-André Lureau: Hi On Sun, Sep 11, 2022 at 10:39 PM Arwed Meyer mailto:arwed.me...@gmx.de>>

Re: [PATCH v2 0/5] Make serial msmouse work

2022-09-24 Thread Arwed Meyer
Am 11.09.22 um 20:18 schrieb Arwed Meyer: This series of patches makes `-serial msmouse` work in practice. Tested with FreeDOS/CTMouse driver `ctmouse /V` which identifies a Logitech compatible 3 button mouse. It will probably run as well with any other compatible serial mouse driver on Windows 9x

Re: [PATCH v2 1/5] msmouse: Handle mouse reset

2022-09-12 Thread Arwed Meyer
Am 12.09.22 um 19:45 schrieb Arwed Meyer: Am 11.09.22 um 20:27 schrieb Peter Maydell: On Sun, 11 Sept 2022 at 18:14, Arwed Meyer wrote: Am 08.09.22 um 23:11 schrieb Peter Maydell: On Thu, 8 Sept 2022 at 18:43, Arwed Meyer wrote: Detect mouse reset via RTS or DTR line: Don't send

Re: [PATCH v2 1/5] msmouse: Handle mouse reset

2022-09-12 Thread Arwed Meyer
Am 11.09.22 um 20:27 schrieb Peter Maydell: On Sun, 11 Sept 2022 at 18:14, Arwed Meyer wrote: Am 08.09.22 um 23:11 schrieb Peter Maydell: On Thu, 8 Sept 2022 at 18:43, Arwed Meyer wrote: Detect mouse reset via RTS or DTR line: Don't send or process anything while in reset. When coming out

[PATCH v3 5/5] serial: Allow unaligned i/o access

2022-09-11 Thread Arwed Meyer
Unaligned i/o access on serial UART works on real PCs. This is used for example by FreeDOS CTMouse driver. Without this it can't reset and detect serial mice. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/77 Signed-off-by: Arwed Meyer --- hw/char/serial.c | 3 +++ 1 file changed, 3

[PATCH v3 2/5] chardev: src buffer const for write functions

2022-09-11 Thread Arwed Meyer
Make source buffers const for char be write functions. This allows using buffers returned by fifo as buf parameter and source buffer should not be changed by write functions anyway. Signed-off-by: Arwed Meyer Reviewed-by: Marc-André Lureau --- chardev/char.c | 4 ++-- include/chardev

[PATCH v3 1/5] msmouse: Handle mouse reset

2022-09-11 Thread Arwed Meyer
Detect mouse reset via RTS or DTR line: Don't send or process anything while in reset. When coming out of reset, send ID sequence first thing. This allows msmouse to be detected by common mouse drivers. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/77 Signed-off-by: Arwed Meyer

[PATCH v3 3/5] msmouse: Use fifo8 instead of array

2022-09-11 Thread Arwed Meyer
Make use of fifo8 functions instead of implementing own fifo code. This makes the code more readable and reduces risk of bugs. Signed-off-by: Arwed Meyer Reviewed-by: Marc-André Lureau --- chardev/msmouse.c | 47 +-- 1 file changed, 25 insertions

[PATCH v3 4/5] msmouse: Add pnp data

2022-09-11 Thread Arwed Meyer
Make msmouse send serial pnp data. Enables you to see nice qemu device name in Win9x. Signed-off-by: Arwed Meyer Reviewed-by: Marc-André Lureau --- chardev/msmouse.c | 58 ++- 1 file changed, 47 insertions(+), 11 deletions(-) diff --git a/chardev

[PATCH v2 0/5] Make serial msmouse work

2022-09-11 Thread Arwed Meyer
This series of patches makes `-serial msmouse` work in practice. Tested with FreeDOS/CTMouse driver `ctmouse /V` which identifies a Logitech compatible 3 button mouse. It will probably run as well with any other compatible serial mouse driver on Windows 9x etc. Arwed Meyer (5): msmouse: Handle

Re: [PATCH v2 3/5] msmouse: Use fifo8 instead of array

2022-09-11 Thread Arwed Meyer
Am 11.09.22 um 08:12 schrieb Volker Rümelin: Am 08.09.22 um 19:31 schrieb Arwed Meyer: @@ -54,21 +60,15 @@ DECLARE_INSTANCE_CHECKER(MouseChardev, MOUSE_CHARDEV,   static void msmouse_chr_accept_input(Chardev *chr)   {   MouseChardev *mouse = MOUSE_CHARDEV(chr); -    int len; +    uint32_t

Re: [PATCH v2 3/5] msmouse: Use fifo8 instead of array

2022-09-11 Thread Arwed Meyer
Hi, Am 09.09.22 um 15:18 schrieb Marc-André Lureau: Hi On Thu, Sep 8, 2022 at 9:38 PM Arwed Meyer mailto:arwed.me...@gmx.de>> wrote: Make use of fifo8 functions instead of implementing own fifo code. This makes the code more readable and reduces risk of bugs. Signed-off-by:

Re: [PATCH v2 1/5] msmouse: Handle mouse reset

2022-09-11 Thread Arwed Meyer
Am 08.09.22 um 23:11 schrieb Peter Maydell: On Thu, 8 Sept 2022 at 18:43, Arwed Meyer wrote: Detect mouse reset via RTS or DTR line: Don't send or process anything while in reset. When coming out of reset, send ID sequence first thing. This allows msmouse to be detected by common mouse

[PATCH v2 2/5] chardev: src buffer const for write functions

2022-09-08 Thread Arwed Meyer
Make source buffers const for char be write functions. This allows using buffers returned by fifo as buf parameter and source buffer should not be changed by write functions anyway. Signed-off-by: Arwed Meyer --- chardev/char.c | 4 ++-- include/chardev/char.h | 4 ++-- include/sysemu

[PATCH v2 1/5] msmouse: Handle mouse reset

2022-09-08 Thread Arwed Meyer
Detect mouse reset via RTS or DTR line: Don't send or process anything while in reset. When coming out of reset, send ID sequence first thing. This allows msmouse to be detected by common mouse drivers. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/77 Signed-off-by: Arwed Meyer

[PATCH v2 3/5] msmouse: Use fifo8 instead of array

2022-09-08 Thread Arwed Meyer
Make use of fifo8 functions instead of implementing own fifo code. This makes the code more readable and reduces risk of bugs. Signed-off-by: Arwed Meyer --- chardev/msmouse.c | 43 +-- 1 file changed, 21 insertions(+), 22 deletions(-) diff --git

[PATCH v2 0/5] Make serial msmouse work

2022-09-08 Thread Arwed Meyer
This series of patches makes `-serial msmouse` work in practice. Tested with FreeDOS/CTMouse driver `ctmouse /V` which identifies a Logitech compatible 3 button mouse. It will probably run as well with any other compatible serial mouse driver on Windows 9x etc. Arwed Meyer (5): msmouse: Handle

[PATCH v2 4/5] msmouse: Add pnp data

2022-09-08 Thread Arwed Meyer
Make msmouse send serial pnp data. Enables you to see nice qemu device name in Win9x. Signed-off-by: Arwed Meyer --- chardev/msmouse.c | 58 ++- 1 file changed, 47 insertions(+), 11 deletions(-) diff --git a/chardev/msmouse.c b/chardev/msmouse.c

[PATCH v2 5/5] serial: Allow unaligned i/o access

2022-09-08 Thread Arwed Meyer
Unaligned i/o access on serial UART works on real PCs. This is used for example by FreeDOS CTMouse driver. Without this it can't reset and detect serial mice. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/77 Signed-off-by: Arwed Meyer --- hw/char/serial.c | 3 +++ 1 file changed, 3

Re: [PATCH 1/4] msmouse: Handle mouse reset

2022-09-08 Thread Arwed Meyer
Am 08.09.22 um 11:45 schrieb Marc-André Lureau: Hi On Wed, Sep 7, 2022 at 2:03 AM Arwed Meyer mailto:arwed.me...@gmx.de>> wrote: Detect mouse reset via RTS or DTR line: Don't send or process anything while in reset. When coming out of reset, send ID sequence first

Re: [PATCH 4/4] serial: Allow unaligned i/o access

2022-09-08 Thread Arwed Meyer
Am 08.09.22 um 13:15 schrieb Michael S. Tsirkin: On Thu, Sep 08, 2022 at 02:11:28PM +0400, Marc-André Lureau wrote: Hi On Wed, Sep 7, 2022 at 2:03 AM Arwed Meyer wrote: Unaligned i/o access on serial UART works on real PCs. This is used for example by FreeDOS CTMouse driver

[PATCH 2/4] chardev: src buffer const for write functions

2022-09-06 Thread Arwed Meyer
Make source buffers const for char be write functions. This allows using buffers returned by fifo as buf parameter and source buffer should not be changed by write functions anyway. Signed-off-by: Arwed Meyer --- chardev/char.c | 4 ++-- include/chardev/char.h | 4 ++-- include/sysemu

[PATCH 3/4] msmouse: Add pnp data

2022-09-06 Thread Arwed Meyer
Make msmouse send serial pnp data. Enables you to see nice qemu device name in Win9x. Signed-off-by: Arwed Meyer --- chardev/msmouse.c | 101 +++--- 1 file changed, 68 insertions(+), 33 deletions(-) diff --git a/chardev/msmouse.c b/chardev/msmouse.c

[PATCH 1/4] msmouse: Handle mouse reset

2022-09-06 Thread Arwed Meyer
Detect mouse reset via RTS or DTR line: Don't send or process anything while in reset. When coming out of reset, send ID sequence first thing. This allows msmouse to be detected by common mouse drivers. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/77 Signed-off-by: Arwed Meyer

[PATCH 4/4] serial: Allow unaligned i/o access

2022-09-06 Thread Arwed Meyer
Unaligned i/o access on serial UART works on real PCs. This is used for example by FreeDOS CTMouse driver. Without this it can't reset and detect serial mice. Resolves: https://gitlab.com/qemu-project/qemu/-/issues/77 Signed-off-by: Arwed Meyer --- hw/char/serial.c | 3 +++ 1 file changed, 3

[PATCH 0/4] Make serial msmouse work

2022-09-06 Thread Arwed Meyer
This series of patches makes `-serial msmouse` work in practice. I tested with FreeDOS/CTMouse driver `ctmouse /V` which identifies a Logitech compatible 3 button mouse. It will probably run as well with any other compatible serial mouse driver on Windows 9x etc. Arwed Meyer (4): msmouse