xen: Deprecation of <xs.h>.
cover xen: Deprecation of <xs.h>.
Considering that <xs.h> will be deprecated in the next release of Xen, this two patches clean a bit the inclusion of xs.h and changes it in a single place.
Anthony PERARD (2):
xen: Reorganize includes of Xen headers.
xenstore: Use <xenstore.h>
configure | 2 +- hw/xen_backend.c | 6 ++---- hw/xen_common.h | 6 +++++- hw/xen_console.c | 5 ++--- hw/xen_disk.c | 6 +----- hw/xen_nic.c | 7 ++----- hw/xenfb.c | 13 +++++-------- 7 files changed, 18 insertions(+), 27 deletions(-)
Signature · 1 line
Anthony PERARD
PATCH 1/2 xen: Reorganize includes of Xen headers.
Because xs.h will be remove in future release of Xen, this patch removes the extra includes of this headers.
Also, it removes the extra includes of xenctrl.h and xen/io/xenbus.h as there already are in xen_common.h.
--- hw/xen_backend.c | 6 ++---- hw/xen_console.c | 5 ++--- hw/xen_disk.c | 6 +----- hw/xen_nic.c | 7 ++----- hw/xenfb.c | 13 +++++-------- 5 files changed, 12 insertions(+), 25 deletions(-)
hw/xen_backend.c +2 -4
@@ -34,15 +34,13 @@#include <sys/mman.h> #include <sys/signal.h> -#include <xs.h> -#include <xenctrl.h> -#include <xen/grant_table.h> -#include "hw.h" #include "qemu-char.h" #include "qemu-log.h" #include "xen_backend.h" +#include <xen/grant_table.h> +/* ------------------------------------------------------------- */ /* public */
hw/xen_console.c +2 -3
@@ -28,14 +28,13 @@#include <termios.h> #include <stdarg.h> #include <sys/mman.h> -#include <xs.h> -#include <xen/io/console.h> -#include <xenctrl.h> #include "hw.h" #include "qemu-char.h" #include "xen_backend.h" +#include <xen/io/console.h> +struct buffer {uint8_t *data;size_t consumed;
hw/xen_disk.c +1 -5
@@ -35,15 +35,11 @@#include <sys/mman.h> #include <sys/uio.h> -#include <xs.h> -#include <xenctrl.h> -#include <xen/io/xenbus.h> -#include "hw.h" #include "block_int.h" #include "qemu-char.h" -#include "xen_blkif.h" #include "xen_backend.h" +#include "xen_blkif.h" #include "blockdev.h" /* ------------------------------------------------------------- */
hw/xen_nic.c +2 -5
@@ -35,11 +35,6 @@#include <sys/mman.h> #include <sys/wait.h> -#include <xs.h> -#include <xenctrl.h> -#include <xen/io/xenbus.h> -#include <xen/io/netif.h> -#include "hw.h" #include "net.h" #include "net/checksum.h"
@@ -47,6 +42,8 @@#include "qemu-char.h" #include "xen_backend.h" +#include <xen/io/netif.h> +/* ------------------------------------------------------------- */ struct XenNetDev {
hw/xenfb.c +5 -8
@@ -35,19 +35,16 @@#include <string.h> #include <time.h> -#include <xs.h> -#include <xenctrl.h> -#include <xen/event_channel.h> -#include <xen/io/xenbus.h> -#include <xen/io/fbif.h> -#include <xen/io/kbdif.h> -#include <xen/io/protocols.h> -#include "hw.h" #include "console.h" #include "qemu-char.h" #include "xen_backend.h" +#include <xen/event_channel.h> +#include <xen/io/fbif.h> +#include <xen/io/kbdif.h> +#include <xen/io/protocols.h> +#ifndef BTN_LEFT #define BTN_LEFT 0x110/* from <linux/input.h> */ #endif
Signature · 1 line
Anthony PERARD
PATCH 1/2 xen: Reorganize includes of Xen headers.
In reply to Anthony PERARDBecause xs.h will be remove in future release of Xen, this patch removes the extra includes of this headers.
Also, it removes the extra includes of xenctrl.h and xen/io/xenbus.h as there already are in xen_common.h.
--- hw/xen_backend.c | 6 ++---- hw/xen_console.c | 5 ++--- hw/xen_disk.c | 6 +----- hw/xen_nic.c | 7 ++----- hw/xenfb.c | 13 +++++-------- 5 files changed, 12 insertions(+), 25 deletions(-)
hw/xen_backend.c +2 -4
@@ -34,15 +34,13 @@#include <sys/mman.h> #include <sys/signal.h> -#include <xs.h> -#include <xenctrl.h> -#include <xen/grant_table.h> -#include "hw.h" #include "qemu-char.h" #include "qemu-log.h" #include "xen_backend.h" +#include <xen/grant_table.h> +/* ------------------------------------------------------------- */ /* public */
hw/xen_console.c +2 -3
@@ -28,14 +28,13 @@#include <termios.h> #include <stdarg.h> #include <sys/mman.h> -#include <xs.h> -#include <xen/io/console.h> -#include <xenctrl.h> #include "hw.h" #include "qemu-char.h" #include "xen_backend.h" +#include <xen/io/console.h> +struct buffer {uint8_t *data;size_t consumed;
hw/xen_disk.c +1 -5
@@ -35,15 +35,11 @@#include <sys/mman.h> #include <sys/uio.h> -#include <xs.h> -#include <xenctrl.h> -#include <xen/io/xenbus.h> -#include "hw.h" #include "block_int.h" #include "qemu-char.h" -#include "xen_blkif.h" #include "xen_backend.h" +#include "xen_blkif.h" #include "blockdev.h" /* ------------------------------------------------------------- */
hw/xen_nic.c +2 -5
@@ -35,11 +35,6 @@#include <sys/mman.h> #include <sys/wait.h> -#include <xs.h> -#include <xenctrl.h> -#include <xen/io/xenbus.h> -#include <xen/io/netif.h> -#include "hw.h" #include "net.h" #include "net/checksum.h"
@@ -47,6 +42,8 @@#include "qemu-char.h" #include "xen_backend.h" +#include <xen/io/netif.h> +/* ------------------------------------------------------------- */ struct XenNetDev {
hw/xenfb.c +5 -8
@@ -35,19 +35,16 @@#include <string.h> #include <time.h> -#include <xs.h> -#include <xenctrl.h> -#include <xen/event_channel.h> -#include <xen/io/xenbus.h> -#include <xen/io/fbif.h> -#include <xen/io/kbdif.h> -#include <xen/io/protocols.h> -#include "hw.h" #include "console.h" #include "qemu-char.h" #include "xen_backend.h" +#include <xen/event_channel.h> +#include <xen/io/fbif.h> +#include <xen/io/kbdif.h> +#include <xen/io/protocols.h> +#ifndef BTN_LEFT #define BTN_LEFT 0x110/* from <linux/input.h> */ #endif
Signature · 1 line
Anthony PERARD
PATCH 2/2 xenstore: Use <xenstore.h>
In reply to Anthony PERARDIn the next release of Xen (4.2), xs.h became deprecated.
--- configure | 2 +- hw/xen_common.h | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-)
configure +1 -1
@@ -1382,7 +1382,7 @@ EOF elif ( cat > $TMPC <<EOF #include <xenctrl.h> -#include <xs.h> +#include <xenstore.h> #include <stdint.h> #include <xen/hvm/hvm_info_table.h> #if !defined(HVM_MAX_VCPUS)
hw/xen_common.h +5 -1
@@ -7,7 +7,11 @@#include <inttypes.h> #include <xenctrl.h> -#include <xs.h> +#if CONFIG_XEN_CTRL_INTERFACE_VERSION <420 +# include <xs.h> +#else +# include <xenstore.h> +#endif #include <xen/io/xenbus.h> #include "hw.h"
Signature · 1 line
Anthony PERARD
PATCH 2/2 xenstore: Use <xenstore.h>
In reply to Anthony PERARDIn the next release of Xen (4.2), xs.h became deprecated.
--- configure | 2 +- hw/xen_common.h | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-)
configure +1 -1
@@ -1382,7 +1382,7 @@ EOF elif ( cat > $TMPC <<EOF #include <xenctrl.h> -#include <xs.h> +#include <xenstore.h> #include <stdint.h> #include <xen/hvm/hvm_info_table.h> #if !defined(HVM_MAX_VCPUS)
hw/xen_common.h +5 -1
@@ -7,7 +7,11 @@#include <inttypes.h> #include <xenctrl.h> -#include <xs.h> +#if CONFIG_XEN_CTRL_INTERFACE_VERSION <420 +# include <xs.h> +#else +# include <xenstore.h> +#endif #include <xen/io/xenbus.h> #include "hw.h"
Signature · 1 line
Anthony PERARD
Re: [PATCH 2/2] xenstore: Use <xenstore.h>
Quoted 28 lines · Anthony PERARD
In the next release of Xen (4.2),
xs.hbecame deprecated.Signed-off-by Anthony PERARD <[email protected]>--- configure | 2 +- hw/xen_common.h | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-)configure +1
-1@@ -1382,7 +1382,7 @@ EOF elif ( cat > $TMPC <<EOF #include <xenctrl.h> -#include <xs.h> +#include <xenstore.h> #include <stdint.h> #include <xen/hvm/hvm_info_table.h> #if !defined(HVM_MAX_VCPUS)hw/xen_common.h +0
-0@@ -7,7 +7,11 @@#include <inttypes.h>
hw/xen_common.h line 17
Quoted 10 lines
hw/xen_common.h +5
-1#include <xenctrl.h> -#include <xs.h> +#if CONFIG_XEN_CTRL_INTERFACE_VERSION <420 +# include <xs.h> +#else +# include <xenstore.h> +#endif #include <xen/io/xenbus.h> #include "hw.h"
Shouldn't we need the ifdef also in configure? On my system xenstore.h still don't exist.
(master *)$ rpm -qa xen-devel xen-devel-4.1.2-17.fc17.x86_64
(master *)$ ls /usr/include/xs.h/usr/include/xs.h
(master *)$ ls /usr/include/xenstore.h
ls: cannot access /usr/include/xenstore.h: No such file or directory (master *)$
Later, Juan.
Re: [Qemu-devel] [PATCH 2/2] xenstore: Use <xenstore.h>
In reply to Anthony PERARDQuoted 28 lines · Anthony PERARD
In the next release of Xen (4.2),
xs.hbecame deprecated.Signed-off-by Anthony PERARD <[email protected]>--- configure | 2 +- hw/xen_common.h | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-)configure +1
-1@@ -1382,7 +1382,7 @@ EOF elif ( cat > $TMPC <<EOF #include <xenctrl.h> -#include <xs.h> +#include <xenstore.h> #include <stdint.h> #include <xen/hvm/hvm_info_table.h> #if !defined(HVM_MAX_VCPUS)hw/xen_common.h +0
-0@@ -7,7 +7,11 @@#include <inttypes.h>
hw/xen_common.h line 17
Quoted 10 lines
hw/xen_common.h +5
-1#include <xenctrl.h> -#include <xs.h> +#if CONFIG_XEN_CTRL_INTERFACE_VERSION <420 +# include <xs.h> +#else +# include <xenstore.h> +#endif #include <xen/io/xenbus.h> #include "hw.h"
Shouldn't we need the ifdef also in configure? On my system xenstore.h still don't exist.
(master *)$ rpm -qa xen-devel xen-devel-4.1.2-17.fc17.x86_64
(master *)$ ls /usr/include/xs.h/usr/include/xs.h
(master *)$ ls /usr/include/xenstore.h
ls: cannot access /usr/include/xenstore.h: No such file or directory (master *)$
Later, Juan.
Re: [Qemu-devel] [PATCH 2/2] xenstore: Use <xenstore.h>
Quoted 43 lines · Juan Quintela
Quoted 28 lines · Anthony PERARD
In the next release of Xen (4.2),
xs.hbecame deprecated.Signed-off-by Anthony PERARD <[email protected]>--- configure | 2 +- hw/xen_common.h | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-)configure +1
-1@@ -1382,7 +1382,7 @@ EOF elif ( cat > $TMPC <<EOF #include <xenctrl.h> -#include <xs.h> +#include <xenstore.h> #include <stdint.h> #include <xen/hvm/hvm_info_table.h> #if !defined(HVM_MAX_VCPUS)hw/xen_common.h +0
-0@@ -7,7 +7,11 @@#include <inttypes.h> hw/xen_common.h line 17
Quoted 10 lines
hw/xen_common.h +5
-1#include <xenctrl.h> -#include <xs.h> +#if CONFIG_XEN_CTRL_INTERFACE_VERSION <420 +# include <xs.h> +#else +# include <xenstore.h> +#endif #include <xen/io/xenbus.h> #include "hw.h" Shouldn't we need the ifdef also in configure? On my system
xenstore.hstill don't exist.
Quoted 7 lines
(master *)$ rpm -qa xen-devel xen-devel-4.1.2-17.fc17.x86_64
(master *)$ ls/usr/include/xs.h/usr/include/xs.h
(master *)$ ls/usr/include/xenstore.h
ls: cannot access/usr/include/xenstore.h: No such file or directory (master *)$
configure is already testing for a number of specific xen versions, this patch is only changing the xen-unstable test, but all the other tests for older xen versions still use xs.h.
Re: [PATCH 2/2] xenstore: Use <xenstore.h>
In reply to Juan QuintelaQuoted 38 lines · Juan Quintela
Quoted 37 lines · Anthony PERARD
In the next release of Xen (4.2),
xs.hbecame deprecated.Signed-off-by Anthony PERARD<[email protected]>--- configure | 2 +- hw/xen_common.h | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-)configure +1
-1@@ -1382,7 +1382,7 @@ EOF elif ( cat> $TMPC<<EOF #include<xenctrl.h> -#include<xs.h> +#include<xenstore.h> #include<stdint.h> #include<xen/hvm/hvm_info_table.h> #if !defined(HVM_MAX_VCPUS)hw/xen_common.h +5
-1@@ -7,7 +7,11 @@#include <inttypes.h> #include <xenctrl.h> -#include <xs.h> +#if CONFIG_XEN_CTRL_INTERFACE_VERSION <420 +# include <xs.h> +#else +# include <xenstore.h> +#endif #include <xen/io/xenbus.h>
Quoted 4 lines
hw/xen_common.h line 17
Quoted 1 line
hw/xen_common.h +0
-0#include "hw.h" Shouldn't we need the ifdef also in configure? On my system
xenstore.hstill don't exist.
No, configure does not need it. In the configure, I just change the header in the test for the next version of Xen. Also the define is defined by configure.
Regards,
Signature · 1 line
Anthony PERARD
Re: [Qemu-devel] [PATCH 2/2] xenstore: Use <xenstore.h>
In reply to Juan QuintelaQuoted 38 lines · Juan Quintela
Quoted 37 lines · Anthony PERARD
In the next release of Xen (4.2),
xs.hbecame deprecated.Signed-off-by Anthony PERARD<[email protected]>--- configure | 2 +- hw/xen_common.h | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-)configure +1
-1@@ -1382,7 +1382,7 @@ EOF elif ( cat> $TMPC<<EOF #include<xenctrl.h> -#include<xs.h> +#include<xenstore.h> #include<stdint.h> #include<xen/hvm/hvm_info_table.h> #if !defined(HVM_MAX_VCPUS)hw/xen_common.h +5
-1@@ -7,7 +7,11 @@#include <inttypes.h> #include <xenctrl.h> -#include <xs.h> +#if CONFIG_XEN_CTRL_INTERFACE_VERSION <420 +# include <xs.h> +#else +# include <xenstore.h> +#endif #include <xen/io/xenbus.h>
Quoted 4 lines
hw/xen_common.h line 17
Quoted 1 line
hw/xen_common.h +0
-0#include "hw.h" Shouldn't we need the ifdef also in configure? On my system
xenstore.hstill don't exist.
No, configure does not need it. In the configure, I just change the header in the test for the next version of Xen. Also the define is defined by configure.
Regards,
Signature · 1 line
Anthony PERARD
Re: [Qemu-devel] [PATCH 2/2] xenstore: Use <xenstore.h>
In reply to Juan QuintelaQuoted 43 lines · Juan Quintela
Quoted 28 lines · Anthony PERARD
In the next release of Xen (4.2),
xs.hbecame deprecated.Signed-off-by Anthony PERARD <[email protected]>--- configure | 2 +- hw/xen_common.h | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-)configure +1
-1@@ -1382,7 +1382,7 @@ EOF elif ( cat > $TMPC <<EOF #include <xenctrl.h> -#include <xs.h> +#include <xenstore.h> #include <stdint.h> #include <xen/hvm/hvm_info_table.h> #if !defined(HVM_MAX_VCPUS)hw/xen_common.h +0
-0@@ -7,7 +7,11 @@#include <inttypes.h> hw/xen_common.h line 17
Quoted 10 lines
hw/xen_common.h +5
-1#include <xenctrl.h> -#include <xs.h> +#if CONFIG_XEN_CTRL_INTERFACE_VERSION <420 +# include <xs.h> +#else +# include <xenstore.h> +#endif #include <xen/io/xenbus.h> #include "hw.h" Shouldn't we need the ifdef also in configure? On my system
xenstore.hstill don't exist.
Quoted 7 lines
(master *)$ rpm -qa xen-devel xen-devel-4.1.2-17.fc17.x86_64
(master *)$ ls/usr/include/xs.h/usr/include/xs.h
(master *)$ ls/usr/include/xenstore.h
ls: cannot access/usr/include/xenstore.h: No such file or directory (master *)$
configure is already testing for a number of specific xen versions, this patch is only changing the xen-unstable test, but all the other tests for older xen versions still use xs.h.
Quoted 7 lines · Anthony PERARD
Considering that <
xs.h> will be deprecated in the next release of Xen, this two patches clean a bit the inclusion ofxs.hand changes it in a single place.Anthony PERARD (2):
xen: Reorganize includes of Xen headers.
xenstore: Use <xenstore.h>
Quoted 8 lines
configure | 2 +- hw/xen_backend.c | 6 ++---- hw/xen_common.h | 6 +++++- hw/xen_console.c | 5 ++--- hw/xen_disk.c | 6 +----- hw/xen_nic.c | 7 ++----- hw/xenfb.c | 13 +++++-------- 7 files changed, 18 insertions(+), 27 deletions(-)
both patches are fine.
Quoted 7 lines · Anthony PERARD
Considering that <
xs.h> will be deprecated in the next release of Xen, this two patches clean a bit the inclusion ofxs.hand changes it in a single place.Anthony PERARD (2):
xen: Reorganize includes of Xen headers.
xenstore: Use <xenstore.h>
Quoted 8 lines
configure | 2 +- hw/xen_backend.c | 6 ++---- hw/xen_common.h | 6 +++++- hw/xen_console.c | 5 ++--- hw/xen_disk.c | 6 +----- hw/xen_nic.c | 7 ++----- hw/xenfb.c | 13 +++++-------- 7 files changed, 18 insertions(+), 27 deletions(-)
both patches are fine.