DragonFly BSD
DragonFly kernel List (threaded) for 2005-05
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: The time has come for a kernel interfacing library layer


From: davidxu <davidxu@xxxxxxxxxxx>
Date: Mon, 09 May 2005 21:52:32 +0800

Matthew Dillon wrote:
    Joerg, does this look ok as an extension to tls_tcb ?  I also added
    some pad to reduce compat headaches in the future.

    We then need to add the code to assign tcb_errno_p during initial
    and new TCB creation.

    I've got the syscall generation infrastructure almost done.  I just
    need to copy the exceptional cases (e.g. fork(), rfork()) from libc.

-Matt

Index: tls.h
===================================================================
RCS file: /cvs/src/sys/i386/include/tls.h,v
retrieving revision 1.3
diff -u -r1.3 tls.h
--- tls.h 3 May 2005 18:25:13 -0000 1.3
+++ tls.h 8 May 2005 03:34:57 -0000
@@ -41,6 +41,8 @@
struct tls_tcb *tcb_self; /* pointer to self*/
void *tcb_dtv; /* Dynamic Thread Vector */
void *tcb_pthread; /* thread library's data*/
+ int *tcb_errno_p; /* pointer to errno or NULL */
+ void *tcb_unused[4];
};
struct tls_dtv {

Do you mean kernel will directly write errno into userland memory?







[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]