((sh)->evtchn_pending[idx] & \
~(sh)->evtchn_mask[idx])
-int in_callback;
-
#ifndef CONFIG_PARAVIRT
extern shared_info_t shared_info;
BUG_ON(!irqs_disabled());
- in_callback = 1;
-
vcpu_info->evtchn_upcall_pending = 0;
/* NB x86. No need for a barrier here -- XCHG is a barrier on x86. */
#if !defined(__i386__) && !defined(__x86_64__)
do_event(port, regs);
}
}
-
- in_callback = 0;
}
void force_evtchn_callback(void)
prev = current;
local_irq_save(flags);
- if (in_callback) {
- printk("Must not call schedule() from a callback\n");
- BUG();
- }
-
do {
/* Examine all threads.
Find a runnable thread, but also wake up expired ones and find the
EXPORT_SYMBOL(create_thread);
#ifdef HAVE_LIBC
-static struct _reent callback_reent;
struct _reent *__getreent(void)
{
struct _reent *_reent;
if (!threads_started)
_reent = _impure_ptr;
- else if (in_callback)
- _reent = &callback_reent;
else
_reent = &get_current()->reent;
{
printk("Initialising scheduler\n");
-#ifdef HAVE_LIBC
- _REENT_INIT_PTR((&callback_reent))
-#endif
idle_thread = create_thread("Idle", idle_thread_fn, NULL);
}