Skip to contentSkip to conversation

x86/hvm: Fix non-debug build folling c/s 0745f665a5

PATCH In review Andrew Cooper 3 participants 3 messages Nov 21, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 x86/hvm: Fix non-debug build folling c/s 0745f665a5

The variable is named inst_len, not insn_len.

---
CC: Jan Beulich <[email protected]>
CC: Wei Liu <[email protected]>
CC: Boris Ostrovsky <[email protected]>
CC: Suravee Suthikulpanit <[email protected]>

I definitely fixed this once duing development, but it clearly slipped back in. My appologies.

---
 xen/arch/x86/hvm/svm/emulate.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
xen/arch/x86/hvm/svm/emulate.c +2 -2
index ca670bf..2b47db9 100644
@@ -98,8 +98,8 @@ int __get_instruction_length_from_list(struct vcpu *v,
      */
 #ifdef NDEBUG
     if ( (inst_len = svm_nextrip_insn_length(v)) > MAX_INST_LEN )
-        gprintk(XENLOG_WARNING, "NRip reported insn_len %lu\n", insn_len);
-    else if ( insn_len != 0 )
+        gprintk(XENLOG_WARNING, "NRip reported insn_len %lu\n", inst_len);
+    else if ( inst_len != 0 )
         return inst_len;
 
     if ( vmcb->exitcode == VMEXIT_IOIO )
Signature · 7 lines
2.1.4


_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel
Reviewed-by on v1 1/1
#1 lore raw
Quoted 20 lines · Andrew Cooper

The variable is named inst_len, not insn_len.

---
CC: Jan Beulich <[email protected]>
CC: Wei Liu <[email protected]>
CC: Boris Ostrovsky <[email protected]>
CC: Suravee Suthikulpanit <[email protected]>

I definitely fixed this once duing development, but it clearly slipped back in. My appologies.

---
 xen/arch/x86/hvm/svm/emulate.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
xen/arch/x86/hvm/svm/emulate.c +0 -0
index ca670bf..2b47db9 100644

xen/arch/x86/hvm/svm/emulate.c int __get_instruction_length_from_list(struct vcpu *v, · line 101

Quoted 6 lines
xen/arch/x86/hvm/svm/emulate.c +1 -2
@@ -98,8 +98,8 @@ int __get_instruction_length_from_list(struct vcpu *v,
      */
 #ifdef NDEBUG
     if ( (inst_len = svm_nextrip_insn_length(v)) > MAX_INST_LEN )
-        gprintk(XENLOG_WARNING, "NRip reported insn_len %lu\n", insn_len);
-    else if ( insn_len != 0 )
+        gprintk(XENLOG_WARNING, "NRip reported insn_len %lu\n", inst_len);

Since you are fixing this up anyway, insn_let in format string should also be updated.

With that,

xen/arch/x86/hvm/svm/emulate.c int __get_instruction_length_from_list(struct vcpu *v, · line 105

Quoted 4 lines
xen/arch/x86/hvm/svm/emulate.c +1 -0
+    else if ( inst_len != 0 )
         return inst_len;
 
     if ( vmcb->exitcode == VMEXIT_IOIO )

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel

#2 lore raw
Quoted 31 lines · Boris Ostrovsky
Quoted 20 lines · Andrew Cooper

The variable is named inst_len, not insn_len.

---
CC: Jan Beulich <[email protected]>
CC: Wei Liu <[email protected]>
CC: Boris Ostrovsky <[email protected]>
CC: Suravee Suthikulpanit <[email protected]>

I definitely fixed this once duing development, but it clearly slipped back in. My appologies.

---
 xen/arch/x86/hvm/svm/emulate.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
xen/arch/x86/hvm/svm/emulate.c +0 -0
index ca670bf..2b47db9 100644

xen/arch/x86/hvm/svm/emulate.c int __get_instruction_length_from_list(struct vcpu *v, · line 101

Quoted 6 lines
xen/arch/x86/hvm/svm/emulate.c +1 -2
@@ -98,8 +98,8 @@ int __get_instruction_length_from_list(struct vcpu *v,
      */
 #ifdef NDEBUG
     if ( (inst_len = svm_nextrip_insn_length(v)) > MAX_INST_LEN )
-        gprintk(XENLOG_WARNING, "NRip reported insn_len %lu\n", insn_len);
-    else if ( insn_len != 0 )
+        gprintk(XENLOG_WARNING, "NRip reported insn_len %lu\n", inst_len);

Since you are fixing this up anyway, insn_let in format string should also be updated.

Quoted 3 lines

With that,

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xen.org/xen-devel