sortof works
[com32] / src / asmops.h
index 6a25f15..09adb13 100644 (file)
@@ -26,7 +26,7 @@ along with this program.  If not, see <https://www.gnu.org/licenses/>.
 
 #define CALLER_EIP(eip) \
        asm volatile( \
-               "mov (%%esp), %0\n\t" \
+               "mov 4(%%ebp), %0\n\t" \
                : "=a" ((uint32_t)eip))
 
 static inline uint8_t inp(uint16_t port)