inst_trap_return() was checking for rfir by masking with 0xfc001fc0
which made it impossible to match rfir (0xca0)
rfi: return from interruption
00 rv rv rv 60 0
6 5 5 3 8 5
rfir: return from interruption and restore
00 rv rv rv 65 0
6 5 5 3 8 5
from "PA-RISC 1.1 Architecture and Instruction Set Reference Manual"
where rv indicates reserved bits
change the mask to only mask out reserved bits and check for rfi
in addition to rfir
ok miod@
-/* $OpenBSD: db_machdep.h,v 1.22 2021/08/30 08:11:12 jasper Exp $ */
+/* $OpenBSD: db_machdep.h,v 1.23 2022/02/15 00:27:11 jsg Exp $ */
/*
* Copyright (c) 1998-2005 Michael Shalayeff
(ins & 0xfc000000) == 0xe0000000;
}
static __inline int inst_trap_return(u_int ins) {
- return (ins & 0xfc001fc0) == 0x00000ca0;
+ return (ins & 0xfc001fff) == 0x00000c00 || /* rfi */
+ (ins & 0xfc001fff) == 0x00000ca0; /* rfir */
}
#if 0