2 * File: arch/blackfin/kernel/entry.S
10 * Copyright 2004-2006 Analog Devices Inc.
12 * Bugs: Enter bugs at http://blackfin.uclinux.org/
14 * This program is free software; you can redistribute it and/or modify
15 * it under the terms of the GNU General Public License as published by
16 * the Free Software Foundation; either version 2 of the License, or
17 * (at your option) any later version.
19 * This program is distributed in the hope that it will be useful,
20 * but WITHOUT ANY WARRANTY; without even the implied warranty of
21 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
22 * GNU General Public License for more details.
24 * You should have received a copy of the GNU General Public License
25 * along with this program; if not, see the file COPYING, or write
26 * to the Free Software Foundation, Inc.,
27 * 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
30 #include <linux/linkage.h>
31 #include <asm/thread_info.h>
32 #include <asm/errno.h>
33 #include <asm/blackfin.h>
34 #include <asm/asm-offsets.h>
36 #include <asm/context.S>
38 #ifdef CONFIG_EXCPT_IRQ_SYSC_L1
47 * Hw IRQs are off on entry, and we don't want the scheduling tail
48 * code to starve high priority domains from interrupts while it
49 * runs. Therefore we first stall the root stage to have the
50 * virtual interrupt state reflect IMASK.
52 p0.l = ___ipipe_root_status;
53 p0.h = ___ipipe_root_status;
58 * Then we may enable hw IRQs, allowing preemption from high
59 * priority domains. schedule_tail() will do local_irq_enable()
60 * since Blackfin does not define __ARCH_WANT_UNLOCKED_CTXSW, so
61 * there is no need to unstall the root domain by ourselves
64 p0.l = _bfin_irq_flags;
65 p0.h = _bfin_irq_flags;
68 #endif /* CONFIG_IPIPE */
74 if cc jump .Lin_kernel;
80 /* do a 'fake' RTI by jumping to [RETI]
81 * to avoid clearing supervisor mode in child
88 ENDPROC(_ret_from_fork)
92 #if (ANOMALY_05000371)
122 ENTRY(_sys_rt_sigreturn)
127 call _do_rt_sigreturn;
131 ENDPROC(_sys_rt_sigreturn)