Skip to contentSkip to conversation

linux-user, trivial: display "0x%x" instead of "0x%d"

PATCH Applied Laurent Vivier 4 participants 5 messages Jun 20, 2016 – Jul 26, 2016

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 linux-user, trivial: display "0x%x" instead of "0x%d"

Display an exception number, generally defined as an hexadecimal number (for instance, EXCP_HLT is 0x10001).

---
Resent to fix qemu-trivial email address.

 linux-user/main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
linux-user/main.c +1 -1
index b9a4e0e..c79f5cb 100644
@@ -2036,7 +2036,7 @@ void cpu_loop(CPUPPCState *env)
             /* just indicate that signals should be handled asap */
             break;
         default:
-            cpu_abort(cs, "Unknown exception 0x%d. Aborting\n", trapnr);
+            cpu_abort(cs, "Unknown exception 0x%x. Aborting\n", trapnr);
             break;
         }
         process_pending_signals(env);
Signature · 1 line
2.5.5
Reviewed-by on v1 1/1
#1 lore raw
Quoted 10 lines · Laurent Vivier

Display an exception number, generally defined as an hexadecimal number (for instance, EXCP_HLT is 0x10001).

---
Resent to fix qemu-trivial email address.

 linux-user/main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Can you also fix the occurrence of 0x%d in trace-events, for mhp_pc_dimm_assigned_slot()? (Or whatever file it lands in after the trace-events split pull request)

Quoted 14 lines
linux-user/main.c +1 -1
index b9a4e0e..c79f5cb 100644
@@ -2036,7 +2036,7 @@ void cpu_loop(CPUPPCState *env)
             /* just indicate that signals should be handled asap */
             break;
         default:
-            cpu_abort(cs, "Unknown exception 0x%d. Aborting\n", trapnr);
+            cpu_abort(cs, "Unknown exception 0x%x. Aborting\n", trapnr);
             break;
         }
         process_pending_signals(env);
Signature · 2 lines
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org
#2 lore raw
Quoted 12 lines · Eric Blake
Quoted 10 lines · Laurent Vivier

Display an exception number, generally defined as an hexadecimal number (for instance, EXCP_HLT is 0x10001).

---
Resent to fix qemu-trivial email address.

 linux-user/main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
Quoted 5 lines

Can you also fix the occurrence of 0x%d in trace-events, for mhp_pc_dimm_assigned_slot()? (Or whatever file it lands in after the trace-events split pull request)

Yes, after the after split pull request.

Thanks,
Laurent

Quoted 16 lines
Quoted 15 lines
linux-user/main.c +1 -1
index b9a4e0e..c79f5cb 100644
@@ -2036,7 +2036,7 @@ void cpu_loop(CPUPPCState *env)
             /* just indicate that signals should be handled asap */
             break;
         default:
-            cpu_abort(cs, "Unknown exception 0x%d. Aborting\n", trapnr);
+            cpu_abort(cs, "Unknown exception 0x%x. Aborting\n", trapnr);
             break;
         }
         process_pending_signals(env);
Acked-by on v1 1/1
#3 lore raw
In reply to Laurent Vivier
Quoted 2 lines · Laurent Vivier

Display an exception number, generally defined as an hexadecimal number (for instance, EXCP_HLT is 0x10001).

Quoted 23 lines

---
Resent to fix qemu-trivial email address.

 linux-user/main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
linux-user/main.c +1 -1
index b9a4e0e..c79f5cb 100644
@@ -2036,7 +2036,7 @@ void cpu_loop(CPUPPCState *env)
             /* just indicate that signals should be handled asap */
             break;
         default:
-            cpu_abort(cs, "Unknown exception 0x%d. Aborting\n", trapnr);
+            cpu_abort(cs, "Unknown exception 0x%x. Aborting\n", trapnr);
             break;
         }
         process_pending_signals(env);
Signature · 1 line
2.5.5
#4 lore raw
In reply to Laurent Vivier
Quoted 2 lines · Laurent Vivier

Display an exception number, generally defined as an hexadecimal number (for instance, EXCP_HLT is 0x10001).

Applied to -trivial, thanks!

/mjt