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] Setting up hypervisor_callback and testing

To: Ivan Kelly <ivan@xxxxxxxxxxxxx>, xen-devel@xxxxxxxxxxxxxxxxxxx
Subject: Re: [Xen-devel] Setting up hypervisor_callback and testing
From: Simon Kagstrom <simon.kagstrom@xxxxxx>
Date: Wed, 15 Feb 2006 13:33:45 +0100
Delivery-date: Wed, 15 Feb 2006 12:46:04 +0000
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
In-reply-to: <20060215114903.GA3745@xxxxxxxxxxxxx>
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/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe>
References: <20060215114903.GA3745@xxxxxxxxxxxxx>
Sender: xen-devel-bounces@xxxxxxxxxxxxxxxxxxx
User-agent: Wanderlust/2.15.2 (Almost Unreal) SEMI/1.14.6 (Maruoka) FLIM/1.14.6 (Marutamachi) APEL/10.6 Emacs/21.4 (i386-pc-linux-gnu) MULE/5.0 (SAKAKI)
At Wed, 15 Feb 2006 11:49:05 +0000,
Ivan Kelly wrote:
> 
> im setting up my hypervisor callback with:
> hypervisor_set_callbacks(CS_SELECTOR, (unsigned long)hypervisor_callback,
>                        CS_SELECTOR, (unsigned long)failsafe_callback);
> hypervisor_callback and failsafe_callback are as yet very simple assembly
> funcations that just shutdown the domain.
> <SNIP>
> _hypervisor_callback:
> [...]
> </SNIP>
> 
> The callback doesn't seem to be getting called at all. At the moment im only
> trying to get very basic callback stuff working, so i've left out the save and
> iret stuff. Could anyone point out where im going wrong?

Have you enabled event delivery? Look in the Mini-OS source kernel.c
and os.h, where "__sti" is defined:

#define __sti()                                                         \
do {                                                                    \
        vcpu_info_t *_vcpu;                                             \
        barrier();                                                      \
        _vcpu = &HYPERVISOR_shared_info->vcpu_info[smp_processor_id()]; \
        _vcpu->evtchn_upcall_mask = 0;                                  \
        barrier(); /* unmask then check (avoid races) */                \
        if ( unlikely(_vcpu->evtchn_upcall_pending) )                   \
                force_evtchn_callback();                                \
} while (0)

the events should be masked on startup I think, so maybe that's your
problem.

// Simon

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

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