Hi everyone,
My final post for today, I hope :-P
One of my binaries needed an unimplemented ioctl command code (TCSETAW).
This patch adds it.
However, I have a question about these codes and their names. At least
in the kernel I'm looking at (2.6.15), there isn't a TIOCGETA or a
TIOCGETS which are used in sim/syscall_emul.hh . However, there is a
TCGETA and TCGETS which I believe is what is meant. Are these names
wrong and should I change them? (Presumably this would require changing
all ISAs?)
Cheers
Tim
--
The University of Edinburgh is a charitable body, registered in
Scotland, with registration number SC005336.
diff --git a/src/arch/powerpc/linux/linux.hh b/src/arch/powerpc/linux/linux.hh
--- a/src/arch/powerpc/linux/linux.hh
+++ b/src/arch/powerpc/linux/linux.hh
@@ -157,6 +157,8 @@
//@{
/// ioctl() command codes.
+ /// These are for the 2.6.15 kernel. Some have changed for
+ /// later versions.
static const unsigned TIOCGETP_ = 0x40067408;
static const unsigned TIOCSETP_ = 0x80067409;
static const unsigned TIOCSETN_ = 0x8006740a;
@@ -166,6 +168,7 @@
static const unsigned TIOCISATTY_ = 0x2000745e;
static const unsigned TIOCGETS_ = 0x402c7413;
static const unsigned TIOCGETA_ = 0x40147417;
+ static const unsigned TCSETAW_ = 0x80147419;
//@}
/// For table().
diff --git a/src/sim/syscall_emul.hh b/src/sim/syscall_emul.hh
--- a/src/sim/syscall_emul.hh
+++ b/src/sim/syscall_emul.hh
@@ -498,6 +498,7 @@
case OS::TIOCGETC_:
case OS::TIOCGETS_:
case OS::TIOCGETA_:
+ case OS::TCSETAW_:
return -ENOTTY;
default:
_______________________________________________
m5-dev mailing list
[email protected]
http://m5sim.org/mailman/listinfo/m5-dev