Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 500
b: refs/heads/master
c: e8d1cb2
h: refs/heads/master
v: v3
  • Loading branch information
Keith Owens authored and Tony Luck committed Apr 25, 2005
1 parent aabd4ad commit cd7de25
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 11 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 8297511530b0d2a281c796e738683951a59a020c
refs/heads/master: e8d1cb2f280aa53e1c75c8b5fcbf80b3481d0caa
27 changes: 17 additions & 10 deletions trunk/arch/ia64/kernel/unwind.c
Original file line number Diff line number Diff line change
Expand Up @@ -1943,23 +1943,30 @@ EXPORT_SYMBOL(unw_unwind);
int
unw_unwind_to_user (struct unw_frame_info *info)
{
unsigned long ip, sp;
unsigned long ip, sp, pr = 0;

while (unw_unwind(info) >= 0) {
if (unw_get_rp(info, &ip) < 0) {
unw_get_ip(info, &ip);
UNW_DPRINT(0, "unwind.%s: failed to read return pointer (ip=0x%lx)\n",
__FUNCTION__, ip);
return -1;
}
unw_get_sp(info, &sp);
if (sp >= (unsigned long)info->task + IA64_STK_OFFSET)
if ((long)((unsigned long)info->task + IA64_STK_OFFSET - sp)
< IA64_PT_REGS_SIZE) {
UNW_DPRINT(0, "unwind.%s: ran off the top of the kernel stack\n",
__FUNCTION__);
break;
if (ip < FIXADDR_USER_END)
}
if (unw_is_intr_frame(info) &&
(pr & (1UL << PRED_USER_STACK)))
return 0;
if (unw_get_pr (info, &pr) < 0) {
unw_get_rp(info, &ip);
UNW_DPRINT(0, "unwind.%s: failed to read "
"predicate register (ip=0x%lx)\n",
__FUNCTION__, ip);
return -1;
}
}
unw_get_ip(info, &ip);
UNW_DPRINT(0, "unwind.%s: failed to unwind to user-level (ip=0x%lx)\n", __FUNCTION__, ip);
UNW_DPRINT(0, "unwind.%s: failed to unwind to user-level (ip=0x%lx)\n",
__FUNCTION__, ip);
return -1;
}
EXPORT_SYMBOL(unw_unwind_to_user);
Expand Down

0 comments on commit cd7de25

Please sign in to comment.