From: Katy Feng Date: Thu, 5 Oct 2023 17:35:26 +0000 (-0700) Subject: Change to common header file not applicable to open-vm-tools. X-Git-Tag: stable-12.4.0~95 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=60ede3ec06d81bf7033ca2ac68431148506baf1b;p=thirdparty%2Fopen-vm-tools.git Change to common header file not applicable to open-vm-tools. --- diff --git a/open-vm-tools/lib/include/vm_basic_asm_arm64.h b/open-vm-tools/lib/include/vm_basic_asm_arm64.h index 2cd7c5dce..88a709c17 100644 --- a/open-vm-tools/lib/include/vm_basic_asm_arm64.h +++ b/open-vm-tools/lib/include/vm_basic_asm_arm64.h @@ -336,16 +336,15 @@ GET_CURRENT_PC(void) /* * GET_CURRENT_LOCATION -- * - * Updates the arguments with the values of the pc, x29, sp and x30 - * registers at the current code location where the macro is invoked. + * Updates the arguments with the values of the pc, fp, sp and the + * return address at the current code location where the macro is invoked. */ -#define GET_CURRENT_LOCATION(pc, fp, sp, lr) do { \ +#define GET_CURRENT_LOCATION(pc, fp, sp, retAddr) do { \ _GET_CURRENT_PC(pc); \ - asm volatile("mov %0, x29" "\n\t" \ - "mov %1, sp" "\n\t" \ - "mov %2, x30" \ - : "=r" (fp), "=r" (sp), "=r" (lr)); \ + asm volatile("mov %0, sp" : "=r" (sp)); \ + fp = (uint64)GetFrameAddr(); \ + retAddr = (uint64)GetReturnAddress(); \ } while (0)