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

[Xen-devel] Re: [PATCH 02/18] xen: hook io_apic read/write operations

To: Jeremy Fitzhardinge <jeremy@xxxxxxxx>
Subject: [Xen-devel] Re: [PATCH 02/18] xen: hook io_apic read/write operations
From: Ingo Molnar <mingo@xxxxxxx>
Date: Sat, 9 May 2009 10:42:01 +0200
Cc: Xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxx>, the arch/x86 maintainers <x86@xxxxxxxxxx>, Linux Kernel Mailing List <linux-kernel@xxxxxxxxxxxxxxx>, Jeremy Fitzhardinge <jeremy.fitzhardinge@xxxxxxxxxx>
Delivery-date: Sat, 09 May 2009 01:43:05 -0700
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <1241730883-4917-3-git-send-email-jeremy@xxxxxxxx>
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: <1241730883-4917-1-git-send-email-jeremy@xxxxxxxx> <1241730883-4917-3-git-send-email-jeremy@xxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Mutt/1.5.18 (2008-05-17)
* Jeremy Fitzhardinge <jeremy@xxxxxxxx> wrote:

> --- a/arch/x86/kernel/apic/io_apic.c
> +++ b/arch/x86/kernel/apic/io_apic.c
> @@ -62,8 +62,10 @@
>  #include <asm/uv/uv_hub.h>
>  #include <asm/uv/uv_irq.h>
>  
> +#include <asm/xen/hypervisor.h>
>  #include <asm/apic.h>
>  
> +
>  #define __apicdebuginit(type) static type __init
>  
>  /*
> @@ -407,14 +409,26 @@ static inline void io_apic_eoi(unsigned int apic, 
> unsigned int vector)
>  
>  static inline unsigned int io_apic_read(unsigned int apic, unsigned int reg)
>  {
> -     struct io_apic __iomem *io_apic = io_apic_base(apic);
> +     struct io_apic __iomem *io_apic;
> +
> +     if (xen_initial_domain())
> +             return xen_io_apic_read(apic, reg);

hm, any reason why we dont want to create a 'struct io_apic' driver 
abstraction instead of spreading xen_initial_domain() checks all 
around the code?

        Ingo

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

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