[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 27/40] char: move QIOChannel-related in char-io.
From: |
Eric Blake |
Subject: |
Re: [Qemu-devel] [PATCH 27/40] char: move QIOChannel-related in char-io.h |
Date: |
Thu, 12 Jan 2017 17:26:33 -0600 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.6.0 |
On 01/11/2017 11:29 AM, Marc-André Lureau wrote:
Grammar in subject is a bit terse; maybe:
char: move QIOChannel-related stuff to char-io.h
> Signed-off-by: Marc-André Lureau <address@hidden>
> ---
> chardev/char-io.h | 24 +++++++
> chardev/char-io.c | 168 ++++++++++++++++++++++++++++++++++++++++++++++++
> chardev/char.c | 174
> +-------------------------------------------------
> chardev/Makefile.objs | 1 +
> 4 files changed, 194 insertions(+), 173 deletions(-)
> create mode 100644 chardev/char-io.h
> create mode 100644 chardev/char-io.c
>
> diff --git a/chardev/char-io.h b/chardev/char-io.h
> new file mode 100644
> index 0000000000..ea559fd124
> --- /dev/null
> +++ b/chardev/char-io.h
> @@ -0,0 +1,24 @@
> +#ifndef CHAR_IO_H
> +#define CHAR_IO_H
Must... resist... the temptation to repeat myself!
> +
> +#include "qemu/osdep.h"
.h files should NOT include osdep.h; since all .c files included it
before any other .h file, then all things in osdep.h are already in
scope at the point the .h file starts.
> +static gboolean io_watch_poll_prepare(GSource *source,
> + gint *timeout_)
> +{
Why the weird spelling of timeout_ ? Maybe timeout_unused is better?
> +++ b/chardev/char.c
> -static gboolean io_watch_poll_prepare(GSource *source,
> - gint *timeout_)
Then again, it's code motion. Again, up to you if you want to tweak
style things during code motion, or split them into a general cleanup
patch separately.
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
- Re: [Qemu-devel] [PATCH 19/40] char: move to chardev/, (continued)
- [Qemu-devel] [PATCH 24/40] char: move ringbuf/memory to its own file, Marc-André Lureau, 2017/01/11
- [Qemu-devel] [PATCH 23/40] char: move mux to its own file, Marc-André Lureau, 2017/01/11
- [Qemu-devel] [PATCH 26/40] char: remove unused READ_RETRIES, Marc-André Lureau, 2017/01/11
- [Qemu-devel] [PATCH 25/40] char: rename and move to header CHR_READ_BUF_LEN, Marc-André Lureau, 2017/01/11
- [Qemu-devel] [PATCH 27/40] char: move QIOChannel-related in char-io.h, Marc-André Lureau, 2017/01/11
- Re: [Qemu-devel] [PATCH 27/40] char: move QIOChannel-related in char-io.h,
Eric Blake <=
- [Qemu-devel] [PATCH 28/40] char: move fd chardev in its own file, Marc-André Lureau, 2017/01/11
- [Qemu-devel] [PATCH 29/40] char: move win chardev base class in its own file, Marc-André Lureau, 2017/01/11
- [Qemu-devel] [PATCH 30/40] char: move win-stdio into its own file, Marc-André Lureau, 2017/01/11
- [Qemu-devel] [PATCH 34/40] char: move stdio in its own file, Marc-André Lureau, 2017/01/11
- [Qemu-devel] [PATCH 33/40] char: move file chardev in its own file, Marc-André Lureau, 2017/01/11
- [Qemu-devel] [PATCH 32/40] char: move udp chardev in its own file, Marc-André Lureau, 2017/01/11
- [Qemu-devel] [PATCH 35/40] char: move console in its own file, Marc-André Lureau, 2017/01/11
- [Qemu-devel] [PATCH 36/40] char: move pipe chardev in its own file, Marc-André Lureau, 2017/01/11