Subversion Repositories HelenOS-historic

Rev

Rev 1112 | Rev 1121 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 1112 Rev 1119
Line 109... Line 109...
109
    }
109
    }
110
}
110
}
111
 
111
 
112
/** Set Thread-local-storeage pointer
112
/** Set Thread-local-storeage pointer
113
 *
113
 *
114
 * TLS pointer is set in FS register. Unfortunately the 64-bit
114
 * TLS pointer is set in GS register. That means, the GS contains
115
 * part can be set only in CPL0 mode.
-
 
116
 *
-
 
117
 * The specs says, that on %fs:0 there is stored contents of %fs register,
115
 * selector, and the descriptor->base is the correct address.
118
 * we need not to go to CPL0 to read it.
-
 
119
 */
116
 */
120
__native sys_tls_set(__native addr)
117
__native sys_tls_set(__native addr)
121
{
118
{
122
    THREAD->tls = addr;
119
    THREAD->tls = addr;
123
    set_tls_desc(addr);
120
    set_tls_desc(addr);