1 /* 2 * This file is subject to the terms and conditions of the GNU General Public 3 * License. See the file "COPYING" in the main directory of this archive 4 * for more details. 5 * 6 * Copyright (C) 2001 - 2005 Tensilica Inc. 7 */ 8 9 #ifndef _XTENSA_SWITCH_TO_H 10 #define _XTENSA_SWITCH_TO_H 11 12 /* * switch_to(n) should switch tasks to task nr n, first 13 * checking that n isn't the current task, in which case it does nothing. 14 */ 15 extern void *_switch_to(void *last, void *next); 16 17 #define switch_to(prev,next,last) \ 18 do { \ 19 (last) = _switch_to(prev, next); \ 20 } while(0) 21 22 #endif /* _XTENSA_SWITCH_TO_H */