WARNING - OLD ARCHIVES

This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
   
 
 
Xen 
 
Home Products Support Community News
 
   
 

xen-devel

Re: [Xen-devel] [PATCH] blktap[12]: include <sys/mount.h> instead of <li

To: Ian Campbell <ian.campbell@xxxxxxxxxx>
Subject: Re: [Xen-devel] [PATCH] blktap[12]: include <sys/mount.h> instead of <linux/fs.h>
From: Daniel Stodden <daniel.stodden@xxxxxxxxxx>
Date: Wed, 12 Jan 2011 14:06:08 -0800
Cc: Ian, Campbell <Ian.Campbell@xxxxxxxxxxxxx>, "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Wed, 12 Jan 2011 14:08:55 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <a5a02c0baa75b66c71f2.1294825785@xxxxxxxxxxxxxxxxxxxxx>
List-help: <mailto:xen-devel-request@lists.xensource.com?subject=help>
List-id: Xen developer discussion <xen-devel.lists.xensource.com>
List-post: <mailto:xen-devel@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <a5a02c0baa75b66c71f2.1294825785@xxxxxxxxxxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
On Wed, 2011-01-12 at 04:49 -0500, Ian Campbell wrote:
> # HG changeset patch
> # User Ian Campbell <ian.campbell@xxxxxxxxxx>
> # Date 1294825752 0
> # Node ID a5a02c0baa75b66c71f2828d22971f9dfb1e8a6b
> # Parent  610c0b9e9e3d70275a37aba9857e1b9d3a361bd0
> blktap[12]: include <sys/mount.h> instead of <linux/fs.h>
> 
> The former is a userspace sanitised header which contains the
> definitions we need. In some distros linux/fs.h defines WRITE which
> conflicts with blktaps own use of that name.

Ack.

[But fwiw we have BLKIF_OP_WRITE and TD_OP_WRITE and all proper code
should carry a TD_, so I'm slightly surprised.]

Daniel

> Also there is no reason to use <linux/errno.h> over the more normal
> <errno.h>.
> 
> Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx>
> 
> diff -r 610c0b9e9e3d -r a5a02c0baa75 tools/blktap/drivers/blk_linux.c
> --- a/tools/blktap/drivers/blk_linux.c        Wed Jan 12 09:49:00 2011 +0000
> +++ b/tools/blktap/drivers/blk_linux.c        Wed Jan 12 09:49:12 2011 +0000
> @@ -1,6 +1,6 @@
>  #include <inttypes.h>
>  #include <sys/ioctl.h>
> -#include <linux/fs.h>
> +#include <sys/mount.h>
>  #include "tapdisk.h"
>  #include "blk.h"
>  
> diff -r 610c0b9e9e3d -r a5a02c0baa75 tools/blktap2/drivers/blk_linux.c
> --- a/tools/blktap2/drivers/blk_linux.c       Wed Jan 12 09:49:00 2011 +0000
> +++ b/tools/blktap2/drivers/blk_linux.c       Wed Jan 12 09:49:12 2011 +0000
> @@ -1,7 +1,7 @@
>  #include <inttypes.h>
> +#include <errno.h>
>  #include <sys/ioctl.h>
> -#include <linux/fs.h>
> -#include <linux/errno.h>
> +#include <sys/mount.h>
>  #include "tapdisk.h"
>  #include "blk.h"




_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel