unsigned long *bottom = (unsigned long *)(thread->stack + STACK_SIZE);
unsigned long *pointer = (unsigned long *)thread->thr_sp;
int count;
- if(thread == current)
+ if(thread == get_current())
{
#ifdef __i386__
asm("movl %%esp,%0"
void dump_regs(struct pt_regs *regs)
{
- minios_printk("Thread: %s\n", current->name);
+ minios_printk("Thread: %s\n", get_current()->name);
#ifdef __i386__
minios_printk("EIP: %x, EFLAGS %x.\n", regs->eip, regs->eflags);
minios_printk("EBX: %08x ECX: %08x EDX: %08x\n",
struct thread *minios_init_mainlwp(void *cookie);
void minios_schedule(void);
-#define current get_current()
-
void minios_wake(struct thread *thread);
void minios_block(struct thread *thread);
int minios_msleep(uint64_t millisecs);
struct thread *prev, *next, *thread, *tmp;
unsigned long flags;
- prev = current;
+ prev = get_current();
local_irq_save(flags);
if (_minios_in_hypervisor_callback) {
void minios_exit_thread(void)
{
unsigned long flags;
- struct thread *thread = current;
+ struct thread *thread = get_current();
struct join_waiter *jw_iter;
/* if joinable, gate until we are allowed to exit */
{
threads_started = 1;
while (1) {
- minios_block(current);
+ minios_block(get_current());
minios_schedule();
}
}
struct thread *minios_init_mainlwp(void *cookie)
{
+ struct thread *current = get_current();
current->cookie = cookie;
allocothertls(current);