From: Laurent Vivier <laurent@vivier.eu>
To: "Philippe Mathieu-Daudé" <f4bug@amsat.org>
Cc: "qemu-devel@nongnu.org Developers" <qemu-devel@nongnu.org>,
"Hervé Poussineau" <hpoussin@reactos.org>,
"Mark Cave-Ayland" <mark.cave-ayland@ilande.co.uk>,
"Gerd Hoffmann" <kraxel@redhat.com>
Subject: Re: [Qemu-devel] [PATCH v2] Split adb.c into adb.c, adb-mouse.c and adb-kbd.c
Date: Wed, 20 Dec 2017 14:53:47 +0100 [thread overview]
Message-ID: <e4d9b437-159c-556d-f529-1429f6f14f33@vivier.eu> (raw)
In-Reply-To: <CAAdtpL5QmaXbGN_q5nMiUuoJRtNf4QF2yz1xWUK0-b6ZRo+dng@mail.gmail.com>
Le 20/12/2017 à 14:16, Philippe Mathieu-Daudé a écrit :
> On Wed, Dec 20, 2017 at 9:14 AM, Laurent Vivier <laurent@vivier.eu> wrote:
>> It makes the code clearer to separate the bus implementation
>> from the devices one.
>>
>> Replace ADB_DPRINTF() with trace events (and adding new ones in adb-kbd.c).
>> Some minor changes to make checkpatch.pl happy.
>>
>> Signed-off-by: Laurent Vivier <laurent@vivier.eu>
>> ---
>> v2: move internal declarations to adb-internal.h
>> replace ADB_DPRINTF() with trace event.
>>
>> hw/input/Makefile.objs | 2 +-
>> hw/input/adb-internal.h | 49 ++++
>> hw/input/adb-kbd.c | 400 +++++++++++++++++++++++++++++++
>> hw/input/adb-mouse.c | 254 ++++++++++++++++++++
>> hw/input/adb.c | 622 +-----------------------------------------------
>> hw/input/trace-events | 8 +
>> 6 files changed, 714 insertions(+), 621 deletions(-)
>> create mode 100644 hw/input/adb-internal.h
>> create mode 100644 hw/input/adb-kbd.c
>> create mode 100644 hw/input/adb-mouse.c
>>
...
>> diff --git a/hw/input/trace-events b/hw/input/trace-events
>> index 88150ef7a6..a8d46cb766 100644
>> --- a/hw/input/trace-events
>> +++ b/hw/input/trace-events
>> @@ -1,5 +1,13 @@
>> # See docs/devel/tracing.txt for syntax documentation.
>>
>> +# hw/input/adb-kbd.c
>> +adb_kbd_no_key(void) "Ignoring NO_KEY"
>> +adb_kbd_writereg(int reg, uint8_t val) "reg %d val 0x%2.2x"
>> +adb_kbd_readreg(int reg, uint8_t val0, uint8_t val1) "reg %d obuf[0] 0x%2.2x obuf[1] 0x%2.2x"
>
> Minor aesthetical change:
> adb_kbd_readreg(int reg, uint8_t val0, uint8_t val1) "reg %d obuf
> [0x%2.2x, 0x%2.2x]"
>
> Anyway, regardless this:
> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
>
>> +# hw/input/adb-mouse.c
>> +adb_mouse_writereg(int reg, uint8_t val) "reg %d val 0x%2.2x"
>> +adb_mouse_readreg(int reg, uint8_t val0, uint8_t val1) "reg %d obuf[0] 0x%2.2x obuf[1] 0x%2.2x"
>
> Ditto:
> adb_mouse_readreg(int reg, uint8_t val0, uint8_t val1) "reg %d obuf
> [0x%2.2x, 0x%2.2x]"
>
I will in case of a v3: I don't think it is worth another round only for
that.
Thanks,
Laurent
next prev parent reply other threads:[~2017-12-20 13:54 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-12-20 12:14 [Qemu-devel] [PATCH v2] Split adb.c into adb.c, adb-mouse.c and adb-kbd.c Laurent Vivier
2017-12-20 13:16 ` Philippe Mathieu-Daudé
2017-12-20 13:53 ` Laurent Vivier [this message]
2017-12-21 8:26 ` Mark Cave-Ayland
2017-12-21 8:32 ` Laurent Vivier
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=e4d9b437-159c-556d-f529-1429f6f14f33@vivier.eu \
--to=laurent@vivier.eu \
--cc=f4bug@amsat.org \
--cc=hpoussin@reactos.org \
--cc=kraxel@redhat.com \
--cc=mark.cave-ayland@ilande.co.uk \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).