qemu with hax to log dma reads & writes jcs.org/2018/11/12/vfio

char: fix alias devices regression

Fix regression from commit 4d43a603c71, where the serial and parallel
headers got removed from char.c, which broke the alias table.

Move the HAVE_CHARDEV_SERIAL/HAVE_CHARDEV_PARPORT to osdep.h instead
of being in separate headers.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>

+13 -13
-5
include/chardev/char-parallel.h
··· 26 26 27 27 #include "chardev/char.h" 28 28 29 - #if defined(__linux__) || defined(__FreeBSD__) || \ 30 - defined(__FreeBSD_kernel__) || defined(__DragonFly__) 31 - #define HAVE_CHARDEV_PARPORT 1 32 - #endif 33 - 34 29 #define CHR_IOCTL_PP_READ_DATA 3 35 30 #define CHR_IOCTL_PP_WRITE_DATA 4 36 31 #define CHR_IOCTL_PP_READ_CONTROL 5
-8
include/chardev/char-serial.h
··· 26 26 27 27 #include "chardev/char.h" 28 28 29 - #ifdef _WIN32 30 - #define HAVE_CHARDEV_SERIAL 1 31 - #elif defined(__linux__) || defined(__sun__) || defined(__FreeBSD__) \ 32 - || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__) \ 33 - || defined(__GLIBC__) 34 - #define HAVE_CHARDEV_SERIAL 1 35 - #endif 36 - 37 29 #define CHR_IOCTL_SERIAL_SET_PARAMS 1 38 30 typedef struct { 39 31 int speed;
+13
include/qemu/osdep.h
··· 284 284 285 285 #endif 286 286 287 + #ifdef _WIN32 288 + #define HAVE_CHARDEV_SERIAL 1 289 + #elif defined(__linux__) || defined(__sun__) || defined(__FreeBSD__) \ 290 + || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__) \ 291 + || defined(__GLIBC__) 292 + #define HAVE_CHARDEV_SERIAL 1 293 + #endif 294 + 295 + #if defined(__linux__) || defined(__FreeBSD__) || \ 296 + defined(__FreeBSD_kernel__) || defined(__DragonFly__) 297 + #define HAVE_CHARDEV_PARPORT 1 298 + #endif 299 + 287 300 #if defined(CONFIG_LINUX) 288 301 #ifndef BUS_MCEERR_AR 289 302 #define BUS_MCEERR_AR 4