xref: /freebsd/sys/libkern/arm/aeabi_unwind.c (revision fdafd315ad0d0f28a11b9fb4476a9ab059c62b92)
18a36da99SPedro F. Giffuni /*-
2*4d846d26SWarner Losh  * SPDX-License-Identifier: BSD-2-Clause
38a36da99SPedro F. Giffuni  *
45cc8d54cSAndrew Turner  * Copyright (C) 2013 Andrew Turner
55cc8d54cSAndrew Turner  * All rights reserved.
65cc8d54cSAndrew Turner  *
75cc8d54cSAndrew Turner  * Redistribution and use in source and binary forms, with or without
85cc8d54cSAndrew Turner  * modification, are permitted provided that the following conditions
95cc8d54cSAndrew Turner  * are met:
105cc8d54cSAndrew Turner  * 1. Redistributions of source code must retain the above copyright
115cc8d54cSAndrew Turner  *    notice, this list of conditions and the following disclaimer.
125cc8d54cSAndrew Turner  * 2. Redistributions in binary form must reproduce the above copyright
135cc8d54cSAndrew Turner  *    notice, this list of conditions and the following disclaimer in the
145cc8d54cSAndrew Turner  *    documentation and/or other materials provided with the distribution.
155cc8d54cSAndrew Turner  *
165cc8d54cSAndrew Turner  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
175cc8d54cSAndrew Turner  * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
185cc8d54cSAndrew Turner  * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
195cc8d54cSAndrew Turner  * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
205cc8d54cSAndrew Turner  * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
215cc8d54cSAndrew Turner  * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
225cc8d54cSAndrew Turner  * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
235cc8d54cSAndrew Turner  * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
245cc8d54cSAndrew Turner  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
255cc8d54cSAndrew Turner  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
265cc8d54cSAndrew Turner  * SUCH DAMAGE.
275cc8d54cSAndrew Turner  *
285cc8d54cSAndrew Turner  */
295cc8d54cSAndrew Turner 
305cc8d54cSAndrew Turner #include <sys/types.h>
31ca496244SAndrew Turner #ifdef _KERNEL
325cc8d54cSAndrew Turner #include <sys/systm.h>
33ca496244SAndrew Turner #else
34ca496244SAndrew Turner #define	panic(x) (void)0
35ca496244SAndrew Turner #endif
365cc8d54cSAndrew Turner 
375cc8d54cSAndrew Turner /* We need to provide these functions never call them */
385cc8d54cSAndrew Turner void __aeabi_unwind_cpp_pr0(void);
395cc8d54cSAndrew Turner void __aeabi_unwind_cpp_pr1(void);
405cc8d54cSAndrew Turner void __aeabi_unwind_cpp_pr2(void);
415cc8d54cSAndrew Turner 
425cc8d54cSAndrew Turner void
__aeabi_unwind_cpp_pr0(void)435cc8d54cSAndrew Turner __aeabi_unwind_cpp_pr0(void)
445cc8d54cSAndrew Turner {
455cc8d54cSAndrew Turner 	panic("__aeabi_unwind_cpp_pr0");
465cc8d54cSAndrew Turner }
475cc8d54cSAndrew Turner 
485cc8d54cSAndrew Turner void
__aeabi_unwind_cpp_pr1(void)495cc8d54cSAndrew Turner __aeabi_unwind_cpp_pr1(void)
505cc8d54cSAndrew Turner {
515cc8d54cSAndrew Turner 	panic("__aeabi_unwind_cpp_pr1");
525cc8d54cSAndrew Turner }
535cc8d54cSAndrew Turner 
545cc8d54cSAndrew Turner void
__aeabi_unwind_cpp_pr2(void)555cc8d54cSAndrew Turner __aeabi_unwind_cpp_pr2(void)
565cc8d54cSAndrew Turner {
575cc8d54cSAndrew Turner 	panic("__aeabi_unwind_cpp_pr2");
585cc8d54cSAndrew Turner }
59