mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] struct thread_struct, asm-i386/processor.h: wrong datatype?
@ 2005-06-04 15:43 Herbert Rosmanith
  2005-06-04 16:01 ` Herbert Rosmanith
  0 siblings, 1 reply; 4+ messages in thread
From: Herbert Rosmanith @ 2005-06-04 15:43 UTC (permalink / raw)
  To: linux-kernel; +Cc: torvalds, Herbert Rosmanith


good day,

concerning this file:

/usr/src/linux/include/asm-i386/processor.h

we find a "struct thread_struct":

struct thread_struct {
        unsigned long   esp0;
        unsigned long   eip;
        unsigned long   esp;
        unsigned long   fs;
        ^^^^^^^^^^^^^^^^^^^
        unsigned long   gs;
        ^^^^^^^^^^^^^^^^^^^

as segment-registers, aren't fs and gs only 16 bit? why are they not
unsigned short (or possibly u_int16_t)?

kind regards,
herbert rosmanith

# diff -uN processor.h.orig processor.h
--- processor.h.orig    Wed Feb 18 14:36:32 2004
+++ processor.h Sat Jun  4 17:41:58 2005
@@ -2,6 +2,9 @@
  * include/asm-i386/processor.h
  *
  * Copyright (C) 1994 Linus Torvalds
+ *
+ * Sat Jun  4 17:41:23 MET DST 2005 herp - Herbert Rosmanith
+ *  fix wrong datatypes in struct thread_struct
  */

 #ifndef __ASM_I386_PROCESSOR_H
@@ -361,8 +364,8 @@
        unsigned long   esp0;
        unsigned long   eip;
        unsigned long   esp;
-       unsigned long   fs;
-       unsigned long   gs;
+       unsigned short  fs;
+       unsigned short  gs;
 /* Hardware debugging registers */
        unsigned long   debugreg[8];  /* %%db0-7 debug registers */
 /* fault info */


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2005-06-08 21:08 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-06-04 15:43 [PATCH] struct thread_struct, asm-i386/processor.h: wrong datatype? Herbert Rosmanith
2005-06-04 16:01 ` Herbert Rosmanith
2005-06-06  8:16   ` Ingo Molnar
2005-06-08 21:08     ` Herbert Rosmanith

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®