Skip to contentSkip to conversation

m68k: Return semihosting errno values correctly

PATCH Applied Meador Inge 4 participants 7 messages Feb 24, 2012 – Oct 29, 2012

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 m68k: Return semihosting errno values correctly

Fixing a simple typo, s/errno/err/, that caused
the error status from GDB semihosted system calls
to be returned incorrectly.

---
 m68k-semi.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
m68k-semi.c +1 -1
index bab01ee..6d60ced 100644
@@ -150,7 +150,7 @@ static void m68k_semi_cb(CPUState *env, target_ulong ret, target_ulong err)
     }
     /* FIXME - handle put_user() failure */
     put_user_u32(ret, args);
-    put_user_u32(errno, args + 4);
+    put_user_u32(err, args + 4);
 }
 
 #define ARG(n)					\
Signature · 1 line
1.7.7.6
Reviewed-by on v1 1/1
#1 lore raw

Am 24.02.2012 23:18, schrieb Meador Inge:

Quoted 5 lines

Fixing a simple typo, s/errno/err/, that caused
the error status from GDB semihosted system calls
to be returned incorrectly.

Nice catch!

Andreas

Quoted 17 lines
---
 m68k-semi.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
m68k-semi.c +1 -1
index bab01ee..6d60ced 100644
@@ -150,7 +150,7 @@ static void m68k_semi_cb(CPUState *env, target_ulong ret, target_ulong err)
     }
     /* FIXME - handle put_user() failure */
     put_user_u32(ret, args);
-    put_user_u32(errno, args + 4);
+    put_user_u32(err, args + 4);
 }
 
 #define ARG(n)					\
Signature · 2 lines
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg
#2 lore raw

Ping.

Quoted 31 lines · Andreas Färber

Am 24.02.2012 23:18, schrieb Meador Inge:

Quoted 5 lines

Fixing a simple typo, s/errno/err/, that caused
the error status from GDB semihosted system calls
to be returned incorrectly.

Nice catch!

Andreas

Quoted 17 lines
---
 m68k-semi.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
m68k-semi.c +1 -1
index bab01ee..6d60ced 100644
@@ -150,7 +150,7 @@ static void m68k_semi_cb(CPUState *env, target_ulong ret, target_ulong err)
     }
     /* FIXME - handle put_user() failure */
     put_user_u32(ret, args);
-    put_user_u32(errno, args + 4);
+    put_user_u32(err, args + 4);
 }
 
 #define ARG(n)					\
Signature · 3 lines
Meador Inge
CodeSourcery / Mentor Embedded
http://www.mentor.com/embedded-software
#3 lore raw

This patch is simple enough (and m68k unmaintained enough) that it could reasonably go through qemu-trivial I think.

-- PMM

Quoted 41 lines · Meador Inge

Ping.

Quoted 29 lines · Andreas Färber

Am 24.02.2012 23:18, schrieb Meador Inge:

Quoted 5 lines

Fixing a simple typo, s/errno/err/, that caused
the error status from GDB semihosted system calls
to be returned incorrectly.

Nice catch!

Andreas

Quoted 16 lines

---
 m68k-semi.c |    2 +-

 1 files changed, 1 insertions(+), 1 deletions(-)
m68k-semi.c +1 -1
index bab01ee..6d60ced 100644
@@ -150,7 +150,7 @@ static void m68k_semi_cb(CPUState *env, target_ulong ret, target_ulong err)
      }
      /* FIXME - handle put_user() failure */
      put_user_u32(ret, args);
-    put_user_u32(errno, args + 4);
+    put_user_u32(err, args + 4);
  }
 
Quoted 2 lines

m68k-semi.c static void m68k_semi_cb(CPUState *env, target_ulong ret, target_ulong err) · line 156

Quoted 1 line
m68k-semi.c +0 -0
  #define ARG(n)                                      \

--
Meador Inge
CodeSourcery / Mentor Embedded
http://www.mentor.com/embedded-software

#4 lore raw

Am 27.03.2012 17:43, schrieb Peter Maydell:

Quoted 2 lines

This patch is simple enough (and m68k unmaintained enough) that it could reasonably go through qemu-trivial I think.

This one's a Mentor-internal issue though - Paul, are you planning to handle (your colleague's) m68k patches? Or should we downgrade m68k to
S: Orphan and handle them through some other to be defined way?

I'm asking because I have m68k QOM'ification in the queue and Anthony has set out not to apply patches for which a submaintainer is defined.

Andreas

Signature · 2 lines
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg
#5 lore raw
In reply to Peter Maydell

I just noticed this patch never got applied by anybody (and alas it now needs a refresh because the file was renamed in the interim.)

-- PMM

Quoted 47 lines · Peter Maydell

This patch is simple enough (and m68k unmaintained enough) that it could reasonably go through qemu-trivial I think.

-- PMM

Quoted 41 lines · Meador Inge

Ping.

Quoted 29 lines · Andreas Färber

Am 24.02.2012 23:18, schrieb Meador Inge:

Quoted 5 lines

Fixing a simple typo, s/errno/err/, that caused
the error status from GDB semihosted system calls
to be returned incorrectly.

Nice catch!

Andreas

Quoted 16 lines
---
 m68k-semi.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
m68k-semi.c +1 -1
index bab01ee..6d60ced 100644
@@ -150,7 +150,7 @@ static void m68k_semi_cb(CPUState *env, target_ulong ret, target_ulong err)
     }
     /* FIXME - handle put_user() failure */
     put_user_u32(ret, args);
-    put_user_u32(errno, args + 4);
+    put_user_u32(err, args + 4);
 }
 
Quoted 2 lines

m68k-semi.c static void m68k_semi_cb(CPUState *env, target_ulong ret, target_ulong err) · line 156

Quoted 1 line
m68k-semi.c +0 -0
 #define ARG(n)                                      \

--
Meador Inge
CodeSourcery / Mentor Embedded
http://www.mentor.com/embedded-software