2002-02-16 00:22:05 +01:00
|
|
|
/* libunwind - a platform-independent unwind library
|
|
|
|
Copyright (C) 2001-2002 Hewlett-Packard Co
|
|
|
|
Contributed by David Mosberger-Tang <davidm@hpl.hp.com>
|
|
|
|
|
|
|
|
This file is part of libunwind.
|
|
|
|
|
|
|
|
libunwind is free software; you can redistribute it and/or modify
|
|
|
|
it under the terms of the GNU General Public License as published by
|
|
|
|
the Free Software Foundation; either version 2, or (at your option)
|
|
|
|
any later version.
|
|
|
|
|
|
|
|
libunwind is distributed in the hope that it will be useful,
|
|
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
GNU General Public License for more details.
|
|
|
|
|
|
|
|
As a special exception, if you link this library with other files to
|
|
|
|
produce an executable, this library does not by itself cause the
|
|
|
|
resulting executable to be covered by the GNU General Public License.
|
|
|
|
This exception does not however invalidate any other reasons why the
|
|
|
|
executable file might be covered by the GNU General Public
|
|
|
|
License. */
|
|
|
|
|
2002-02-28 17:24:48 +01:00
|
|
|
#include "init.h"
|
2002-02-16 00:22:05 +01:00
|
|
|
#include "rse.h"
|
|
|
|
#include "unwind_i.h"
|
|
|
|
|
|
|
|
int
|
2002-02-22 22:58:53 +01:00
|
|
|
unw_init_remote (unw_cursor_t *cursor, unw_accessors_t *a)
|
2002-02-16 00:22:05 +01:00
|
|
|
{
|
2002-02-28 17:24:48 +01:00
|
|
|
#ifdef UNW_LOCAL_ONLY
|
|
|
|
return -UNW_EINVAL;
|
|
|
|
#else /* !UNW_LOCAL_ONLY */
|
2002-02-16 00:22:05 +01:00
|
|
|
struct ia64_cursor *c = (struct ia64_cursor *) cursor;
|
|
|
|
|
|
|
|
if (unw.first_time)
|
|
|
|
{
|
|
|
|
unw.first_time = 0;
|
|
|
|
ia64_init ();
|
|
|
|
}
|
|
|
|
|
|
|
|
c->acc = *a;
|
2002-02-28 17:24:48 +01:00
|
|
|
return common_init (c);
|
|
|
|
#endif /* !UNW_LOCAL_ONLY */
|
2002-02-16 00:22:05 +01:00
|
|
|
}
|