assert(!irq_is_enabled());
/* Should never have ktask still set. If we do, future syscalls could try
* to block later and lose track of our address space. */
- assert(!pcpui->cur_kthread->is_ktask);
+ assert(!is_ktask(pcpui->cur_kthread));
__set_proc_current(p);
/* Clear the current_ctx, since it is no longer used */
current_ctx = 0; /* TODO: might not need this... */