unwind.h revision 115084
185685Sdfr/*-
285685Sdfr * Copyright (c) 2001 Doug Rabson
385685Sdfr * All rights reserved.
485685Sdfr *
585685Sdfr * Redistribution and use in source and binary forms, with or without
685685Sdfr * modification, are permitted provided that the following conditions
785685Sdfr * are met:
885685Sdfr * 1. Redistributions of source code must retain the above copyright
985685Sdfr *    notice, this list of conditions and the following disclaimer.
1085685Sdfr * 2. Redistributions in binary form must reproduce the above copyright
1185685Sdfr *    notice, this list of conditions and the following disclaimer in the
1285685Sdfr *    documentation and/or other materials provided with the distribution.
1385685Sdfr *
1485685Sdfr * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
1585685Sdfr * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
1685685Sdfr * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
1785685Sdfr * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
1885685Sdfr * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
1985685Sdfr * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
2085685Sdfr * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
2185685Sdfr * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
2285685Sdfr * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
2385685Sdfr * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
2485685Sdfr * SUCH DAMAGE.
2585685Sdfr *
2685685Sdfr * $FreeBSD: head/sys/ia64/include/unwind.h 115084 2003-05-16 21:26:42Z marcel $
2785685Sdfr */
2885685Sdfr
29115084Smarcel#ifndef _MACHINE_UNWIND_H_
30115084Smarcel#define	_MACHINE_UNWIND_H_
3185685Sdfr
32115084Smarcelstruct uwx_env;
33115084Smarcel
34115084Smarcelstruct unw_regstate {
35115084Smarcel	struct trapframe *frame;
36115084Smarcel	struct uwx_env	*env;
37115084Smarcel	uint64_t	keyval[8];
38115084Smarcel};
39115084Smarcel
40115084Smarcelint unw_create(struct unw_regstate *s, struct trapframe *tf);
41115084Smarcelint unw_step(struct unw_regstate *s);
42115084Smarcel
43115084Smarcelint unw_get_bsp(struct unw_regstate *s, uint64_t *r);
44115084Smarcelint unw_get_cfm(struct unw_regstate *s, uint64_t *r);
45115084Smarcelint unw_get_ip(struct unw_regstate *s, uint64_t *r);
46115084Smarcel
47115084Smarcelint unw_table_add(uint64_t, uint64_t, uint64_t);
48115084Smarcelvoid unw_table_remove(uint64_t);
49115084Smarcel
50115084Smarcel#endif /* _MACHINE_UNWIND_H_ */
51