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] tools: build fix for blktap2

To: Christoph Egger <Christoph.Egger@xxxxxxx>
Subject: Re: [Xen-devel] [PATCH] tools: build fix for blktap2
From: Daniel Stodden <daniel.stodden@xxxxxxxxxx>
Date: Thu, 4 Feb 2010 04:39:44 -0800
Cc: "xen-devel@xxxxxxxxxxxxxxxxxxx" <xen-devel@xxxxxxxxxxxxxxxxxxx>
Delivery-date: Thu, 04 Feb 2010 04:40:05 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <201002041238.03896.Christoph.Egger@xxxxxxx>
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: <201002041238.03896.Christoph.Egger@xxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
On Thu, 2010-02-04 at 06:38 -0500, Christoph Egger wrote:
> 
> Hi!

Hi!

> Attached patch makes blktap2 build again.
> 
> Signed-off-by: Christoph Egger <Christoph.Egger@xxxxxxx>

>  #define LIO_FLAG_EVENTFD        (1<<0)
>  
> +#if defined(__linux__)
> +/* XXX abstraction violation: move this into a linux specific file */
>  static int
>  tapdisk_lio_check_resfd(void)
>  {
>         return tapdisk_linux_version() >= KERNEL_VERSION(2, 6, 22);
>  }
> +#endif

Ah right, I forgot to mask out KERNEL_VERSION itself.

tapdisk_linux_version is defined however, turning into an ENOSYS.

How about just running and failing that check?

>  static void
>  tapdisk_lio_destroy_aio(struct tqueue *queue)
> @@ -372,8 +375,11 @@ tapdisk_lio_setup_aio(struct tqueue *que
>          * if not, fall back to the poll fd patch.
>          */
>  
> +#if defined(__linux__)
> +/* XXX abstraction violation: move this into a linux specific file */
>         err = !tapdisk_lio_check_resfd();
>         if (!err)
> +#endif
>                 err = __lio_setup_aio_eventfd(queue, qlen);

I don't think you wanted this, unless you're sure what you keep calling.

>         if (err)
>                 err = __lio_setup_aio_poll(queue, qlen);

Just to understand the FreeBSD situation a little better -- it actually
does come with a mechanism equivalent to the poll patch?

Cheers,
Daniel



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

<Prev in Thread] Current Thread [Next in Thread>