Skip to contentSkip to conversation

PPC termios structure ordering

PATCH In review Stuart Anderson 2 participants 3 messages Apr 17, 2007 – Apr 18, 2007

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 PPC termios structure ordering

Just found a small problem w/ the termios structure as defined for PPC linux user. It doesn't match the one in include/asm-powerpc/termbits.h.

ppc/termbits.h (working copy) renamed from ppc/termbits.h (revision 44) +1 -0
Index: linux-user/ppc/termbits.h
===================================================================
@@ -7,8 +7,8 @@
     unsigned int c_oflag;               /* output mode flags */
     unsigned int c_cflag;               /* control mode flags */
     unsigned int c_lflag;               /* local mode flags */
+    unsigned char c_cc[TARGET_NCCS];                /* control

characters */
unsigned char c_line; /* line discipline */
- unsigned char c_cc[TARGET_NCCS]; /* control
characters */
unsigned int c_ispeed; /* input speed */
unsigned int c_ospeed; /* output speed */
};

With this change, both host and target 'stty -a' give the same output.

Stuart

Stuart R. Anderson                               [email protected]
Network & Software Engineering                   http://www.netsweng.com/
1024D/37A79149:                                  0791 D3B8 9A4C 2CDC A31F
                                                 BD03 0A62 E534 37A7 9149
#1 lore raw
Quoted 21 lines · Stuart Anderson

Just found a small problem w/ the termios structure as defined for PPC linux user. It doesn't match the one in include/asm-powerpc/termbits.h.

Index: linux-user/ppc/termbits.h
===================================================================

ppc/termbits.h (working copy) renamed from ppc/termbits.h (revision 44) +1 -0
@@ -7,8 +7,8 @@
      unsigned int c_oflag;               /* output mode flags */
      unsigned int c_cflag;               /* control mode flags */
      unsigned int c_lflag;               /* local mode flags */
+    unsigned char c_cc[TARGET_NCCS];                /* control

characters */
unsigned char c_line; /* line discipline */
- unsigned char c_cc[TARGET_NCCS]; /* control
characters */
unsigned int c_ispeed; /* input speed */
unsigned int c_ospeed; /* output speed */
};

Quoted 1 line

With this change, both host and target 'stty -a' give the same output.

Thanks. I'll take a better look to this patch then apply. There maybe the same issue in the ppc64 strucutre ?

Signature · 2 lines
J. Mayer <[email protected]>
Never organized
#2 lore raw
Quoted 4 lines · J. Mayer
Quoted 1 line

With this change, both host and target 'stty -a' give the same output.

Thanks. I'll take a better look to this patch then apply. There maybe the same issue in the ppc64 strucutre ?

Yes, it looks like the same changes it needed in linux-user/ppc64/termbits.h as well.

Stuart

Stuart R. Anderson                               [email protected]
Network & Software Engineering                   http://www.netsweng.com/
1024D/37A79149:                                  0791 D3B8 9A4C 2CDC A31F
                                                 BD03 0A62 E534 37A7 9149