[haiku-commits] r40196 - in haiku/trunk: . build/jam headers/libs/freetype2 headers/libs/png headers/libs/tiff ...

Author: bonefish
Date: 2011-01-10 22:54:38 +0100 (Mon, 10 Jan 2011)
New Revision: 40196
Changeset: http://dev.haiku-os.org/changeset/40196

Added:
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/firewire.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/firewire_module.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/fwdma.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/fwmem.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/fwohci.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/fwohci_pci.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/timer.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/ps2/ps2_service.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/bus_raw.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/busses.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/ccb.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/device_scan.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/devices.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/dpc.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/queuing.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/scatter_gather.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/scsi.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/scsi_io.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/sim_interface.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/virtual_memory.cpp
Removed:
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/firewire.c
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/firewire_module.c
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/fwdma.c
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/fwmem.c
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/fwohci.c
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/fwohci_pci.c
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/timer.c
   haiku/trunk/src/add-ons/kernel/bus_managers/ps2/ps2_service.c
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/bus_raw.c
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/busses.c
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/ccb.c
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/device_scan.c
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/devices.c
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/dpc.c
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/queuing.c
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/scatter_gather.c
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/scsi.c
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/scsi_io.c
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/sim_interface.c
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/virtual_memory.c
Modified:
   haiku/trunk/
   haiku/trunk/build/jam/HaikuImage
   haiku/trunk/headers/libs/freetype2/
   haiku/trunk/headers/libs/png/png.h
   haiku/trunk/headers/libs/png/pngconf.h
   haiku/trunk/headers/libs/tiff/tiff.h
   haiku/trunk/headers/libs/tiff/tiffio.h
   haiku/trunk/headers/libs/tiff/tiffvers.h
   haiku/trunk/headers/private/firewire/iec13213.h
   haiku/trunk/headers/private/kernel/arch/arm/arch_thread.h
   haiku/trunk/headers/private/kernel/arch/debug.h
   haiku/trunk/headers/private/kernel/arch/m68k/arch_cpu.h
   haiku/trunk/headers/private/kernel/arch/m68k/arch_thread.h
   haiku/trunk/headers/private/kernel/arch/mipsel/arch_thread.h
   haiku/trunk/headers/private/kernel/arch/ppc/arch_cpu.h
   haiku/trunk/headers/private/kernel/arch/ppc/arch_thread.h
   haiku/trunk/headers/private/kernel/arch/thread.h
   haiku/trunk/headers/private/kernel/arch/user_debugger.h
   haiku/trunk/headers/private/kernel/arch/x86/arch_thread.h
   haiku/trunk/headers/private/kernel/arch/x86/arch_user_debugger.h
   haiku/trunk/headers/private/kernel/condition_variable.h
   haiku/trunk/headers/private/kernel/cpu.h
   haiku/trunk/headers/private/kernel/debug.h
   haiku/trunk/headers/private/kernel/elf.h
   haiku/trunk/headers/private/kernel/kimage.h
   haiku/trunk/headers/private/kernel/kscheduler.h
   haiku/trunk/headers/private/kernel/ksignal.h
   haiku/trunk/headers/private/kernel/listeners.h
   haiku/trunk/headers/private/kernel/port.h
   haiku/trunk/headers/private/kernel/posix/xsi_semaphore.h
   haiku/trunk/headers/private/kernel/sem.h
   haiku/trunk/headers/private/kernel/syscall_restart.h
   haiku/trunk/headers/private/kernel/team.h
   haiku/trunk/headers/private/kernel/thread.h
   haiku/trunk/headers/private/kernel/thread_types.h
   haiku/trunk/headers/private/kernel/tracing.h
   haiku/trunk/headers/private/kernel/user_debugger.h
   haiku/trunk/headers/private/kernel/usergroup.h
   haiku/trunk/headers/private/kernel/util/AutoLock.h
   haiku/trunk/headers/private/kernel/util/OpenHashTable.h
   haiku/trunk/headers/private/kernel/vm/vm.h
   haiku/trunk/src/add-ons/kernel/bus_managers/acpi/
   haiku/trunk/src/add-ons/kernel/bus_managers/acpi/include/platform/achaiku.h
   haiku/trunk/src/add-ons/kernel/bus_managers/ata/ATAChannel.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/Jamfile
   haiku/trunk/src/add-ons/kernel/bus_managers/firewire/util.h
   haiku/trunk/src/add-ons/kernel/bus_managers/ide/pio.cpp
   haiku/trunk/src/add-ons/kernel/bus_managers/ps2/Jamfile
   haiku/trunk/src/add-ons/kernel/bus_managers/scsi/Jamfile
   haiku/trunk/src/add-ons/kernel/debugger/demangle/demangle.cpp
   haiku/trunk/src/add-ons/kernel/debugger/demangle/gcc2.cpp
   haiku/trunk/src/add-ons/kernel/debugger/demangle/gcc3+.cpp
   haiku/trunk/src/add-ons/kernel/drivers/network/wlan/atheroswifi/dev/ath/
   haiku/trunk/src/add-ons/kernel/drivers/network/wlan/iprowifi4965/dev/iwn/
   haiku/trunk/src/add-ons/kernel/file_cache/launch_speedup.cpp
   haiku/trunk/src/add-ons/kernel/file_cache/log.cpp
   
haiku/trunk/src/add-ons/kernel/file_systems/userlandfs/kernel_add_on/FileSystem.cpp
   
haiku/trunk/src/add-ons/kernel/file_systems/userlandfs/kernel_add_on/Volume.cpp
   haiku/trunk/src/add-ons/kernel/network/stack/utility.cpp
   haiku/trunk/src/add-ons/media/plugins/ffmpeg/
   haiku/trunk/src/apps/debugger/demangler/Jamfile
   haiku/trunk/src/bin/fwcontrol/fwcrom.c
   haiku/trunk/src/build/libbe/storage/mime/
   haiku/trunk/src/libs/freetype2/
   haiku/trunk/src/libs/png/
   haiku/trunk/src/libs/tiff/
   haiku/trunk/src/system/kernel/arch/arm/arch_debug.cpp
   haiku/trunk/src/system/kernel/arch/arm/arch_thread.cpp
   haiku/trunk/src/system/kernel/arch/arm/arch_user_debugger.cpp
   
haiku/trunk/src/system/kernel/arch/arm/paging/32bit/ARMVMTranslationMap32Bit.cpp
   haiku/trunk/src/system/kernel/arch/arm/paging/ARMVMTranslationMap.cpp
   
haiku/trunk/src/system/kernel/arch/arm/paging/arm_physical_page_mapper_large_memory.cpp
   haiku/trunk/src/system/kernel/arch/m68k/arch_debug.cpp
   haiku/trunk/src/system/kernel/arch/m68k/arch_int.cpp
   haiku/trunk/src/system/kernel/arch/m68k/arch_thread.cpp
   haiku/trunk/src/system/kernel/arch/m68k/arch_user_debugger.cpp
   haiku/trunk/src/system/kernel/arch/m68k/asm_offsets.cpp
   haiku/trunk/src/system/kernel/arch/mips/arch_thread.cpp
   haiku/trunk/src/system/kernel/arch/mipsel/arch_debug.cpp
   haiku/trunk/src/system/kernel/arch/mipsel/arch_thread.cpp
   haiku/trunk/src/system/kernel/arch/mipsel/arch_user_debugger.cpp
   haiku/trunk/src/system/kernel/arch/ppc/arch_debug.cpp
   haiku/trunk/src/system/kernel/arch/ppc/arch_int.cpp
   haiku/trunk/src/system/kernel/arch/ppc/arch_thread.cpp
   haiku/trunk/src/system/kernel/arch/x86/arch_debug.cpp
   haiku/trunk/src/system/kernel/arch/x86/arch_int.cpp
   haiku/trunk/src/system/kernel/arch/x86/arch_interrupts.S
   haiku/trunk/src/system/kernel/arch/x86/arch_thread.cpp
   haiku/trunk/src/system/kernel/arch/x86/arch_user_debugger.cpp
   haiku/trunk/src/system/kernel/arch/x86/asm_offsets.cpp
   
haiku/trunk/src/system/kernel/arch/x86/paging/32bit/X86VMTranslationMap32Bit.cpp
   haiku/trunk/src/system/kernel/arch/x86/paging/X86VMTranslationMap.cpp
   haiku/trunk/src/system/kernel/arch/x86/paging/pae/X86VMTranslationMapPAE.cpp
   
haiku/trunk/src/system/kernel/arch/x86/paging/x86_physical_page_mapper_large_memory.cpp
   haiku/trunk/src/system/kernel/arch/x86/vm86.cpp
   haiku/trunk/src/system/kernel/debug/debug.cpp
   haiku/trunk/src/system/kernel/debug/system_profiler.cpp
   haiku/trunk/src/system/kernel/debug/tracing.cpp
   haiku/trunk/src/system/kernel/debug/user_debugger.cpp
   haiku/trunk/src/system/kernel/device_manager/IOCache.cpp
   [... truncated: 34 changed files follow ...]
Log:
Merged the signals branch into trunk, with these changes:
* The team and thread kernel structures have been renamed to Team and Thread
  respectively and moved into the new BKernel namespace.
* Several (kernel add-on) sources have been converted from C to C++ since
  private kernel headers are included that are no longer C compatible.

Changes after merging:
* Fixed gcc 2 build (warnings mainly in the scary firewire bus manager).



Property changes on: haiku/trunk
___________________________________________________________________
Modified: svn:mergeinfo
   - /haiku/branches/developer/bonefish/weak-symbols:39365-39568
   + /haiku/branches/developer/bonefish/signals:40148-40195
/haiku/branches/developer/bonefish/weak-symbols:39365-39568

Modified: haiku/trunk/build/jam/HaikuImage
===================================================================
--- haiku/trunk/build/jam/HaikuImage    2011-01-10 21:14:06 UTC (rev 40195)
+++ haiku/trunk/build/jam/HaikuImage    2011-01-10 21:54:38 UTC (rev 40196)
@@ -227,7 +227,7 @@
        : <usb>uhci <usb>ohci <usb>ehci ;
 AddFilesToHaikuImage system add-ons kernel console : vga_text ;
 AddFilesToHaikuImage system add-ons kernel debugger
-       : <kdebug>demangle $(X86_ONLY)<kdebug>disasm <kdebug>hangman
+       : <kdebug>demangle $(X86_ONLY)<kdebug>disasm
          <kdebug>invalidate_on_exit <kdebug>usb_keyboard <kdebug>run_on_exit ;
 AddFilesToHaikuImage system add-ons kernel file_systems
        : $(SYSTEM_ADD_ONS_FILE_SYSTEMS) ;


Property changes on: haiku/trunk/headers/libs/freetype2
___________________________________________________________________
Modified: svn:mergeinfo
   - /haiku/vendor/freetype2/2.4.3/include:39521-39523
/haiku/vendor/freetype2/current/include:37946-39520
   + 
/haiku/branches/developer/bonefish/signals/headers/libs/freetype2:40148-40195
/haiku/vendor/freetype2/2.4.3/include:39521-39523
/haiku/vendor/freetype2/current/include:37946-39520


Property changes on: haiku/trunk/headers/libs/png/png.h
___________________________________________________________________
Modified: svn:mergeinfo
   - 
/haiku/branches/developer/bonefish/weak-symbols/headers/libs/png/png.h:39365-39568
/haiku/vendor/libpng/1.4.4/png.h:39522
/haiku/vendor/libpng/current/png.h:35840-39521
   + 
/haiku/branches/developer/bonefish/signals/headers/libs/png/png.h:40148-40195
/haiku/branches/developer/bonefish/weak-symbols/headers/libs/png/png.h:39365-39568
/haiku/vendor/libpng/1.4.4/png.h:39522
/haiku/vendor/libpng/current/png.h:35840-39521


Property changes on: haiku/trunk/headers/libs/png/pngconf.h
___________________________________________________________________
Modified: svn:mergeinfo
   - 
/haiku/branches/developer/bonefish/weak-symbols/headers/libs/png/pngconf.h:39365-39568
/haiku/vendor/libpng/1.4.4/pngconf.h:39522
/haiku/vendor/libpng/current/pngconf.h:35840-39521
   + 
/haiku/branches/developer/bonefish/signals/headers/libs/png/pngconf.h:40148-40195
/haiku/branches/developer/bonefish/weak-symbols/headers/libs/png/pngconf.h:39365-39568
/haiku/vendor/libpng/1.4.4/pngconf.h:39522
/haiku/vendor/libpng/current/pngconf.h:35840-39521


Property changes on: haiku/trunk/headers/libs/tiff/tiff.h
___________________________________________________________________
Modified: svn:mergeinfo
   - 
/haiku/branches/developer/bonefish/weak-symbols/headers/libs/tiff/tiff.h:39365-39568
/haiku/vendor/libtiff/3.9.4/libtiff/tiff.h:38702
/haiku/vendor/libtiff/current/libtiff/tiff.h:38700-38701
   + 
/haiku/branches/developer/bonefish/signals/headers/libs/tiff/tiff.h:40148-40195
/haiku/branches/developer/bonefish/weak-symbols/headers/libs/tiff/tiff.h:39365-39568
/haiku/vendor/libtiff/3.9.4/libtiff/tiff.h:38702
/haiku/vendor/libtiff/current/libtiff/tiff.h:38700-38701


Property changes on: haiku/trunk/headers/libs/tiff/tiffio.h
___________________________________________________________________
Modified: svn:mergeinfo
   - 
/haiku/branches/developer/bonefish/weak-symbols/headers/libs/tiff/tiffio.h:39365-39568
/haiku/vendor/libtiff/3.9.4/libtiff/tiffio.h:38702
/haiku/vendor/libtiff/current/libtiff/tiffio.h:38700-38701
   + 
/haiku/branches/developer/bonefish/signals/headers/libs/tiff/tiffio.h:40148-40195
/haiku/branches/developer/bonefish/weak-symbols/headers/libs/tiff/tiffio.h:39365-39568
/haiku/vendor/libtiff/3.9.4/libtiff/tiffio.h:38702
/haiku/vendor/libtiff/current/libtiff/tiffio.h:38700-38701


Property changes on: haiku/trunk/headers/libs/tiff/tiffvers.h
___________________________________________________________________
Modified: svn:mergeinfo
   - 
/haiku/branches/developer/bonefish/weak-symbols/headers/libs/tiff/tiffvers.h:39365-39568
/haiku/vendor/libtiff/3.9.4/libtiff/tiffvers.h:38702
/haiku/vendor/libtiff/current/libtiff/tiffvers.h:38700-38701
   + 
/haiku/branches/developer/bonefish/signals/headers/libs/tiff/tiffvers.h:40148-40195
/haiku/branches/developer/bonefish/weak-symbols/headers/libs/tiff/tiffvers.h:39365-39568
/haiku/vendor/libtiff/3.9.4/libtiff/tiffvers.h:38702
/haiku/vendor/libtiff/current/libtiff/tiffvers.h:38700-38701

Modified: haiku/trunk/headers/private/firewire/iec13213.h
===================================================================
--- haiku/trunk/headers/private/firewire/iec13213.h     2011-01-10 21:14:06 UTC 
(rev 40195)
+++ haiku/trunk/headers/private/firewire/iec13213.h     2011-01-10 21:54:38 UTC 
(rev 40196)
@@ -30,11 +30,15 @@
  * STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
  * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  * POSSIBILITY OF SUCH DAMAGE.
- * 
+ *
  * $FreeBSD: src/sys/dev/firewire/iec13213.h,v 1.14 2005/01/06 01:42:41 imp 
Exp $
  *
  */
 
+
+#include <sys/cdefs.h>
+
+
 #define        STATE_CLEAR     0x0000
 #define        STATE_SET       0x0004
 #define        NODE_IDS        0x0008
@@ -161,7 +165,7 @@
 
 struct bus_info {
 #define        CSR_BUS_NAME_IEEE1394   0x31333934
-       uint32_t bus_name;      
+       uint32_t bus_name;
 #if BYTE_ORDER == BIG_ENDIAN
        uint32_t irmc:1,                /* iso. resource manager capable */
                 cmc:1,                 /* cycle master capable */
@@ -209,6 +213,8 @@
        struct crom_ptr stack[CROM_MAX_DEPTH];
 };
 
+__BEGIN_DECLS
+
 void crom_init_context(struct crom_context *, uint32_t *);
 struct csrreg *crom_get(struct crom_context *);
 void crom_next(struct crom_context *);
@@ -232,12 +238,12 @@
 
 struct crom_chunk {
        STAILQ_ENTRY(crom_chunk) link;
-       struct crom_chunk *ref_chunk; 
-       int ref_index; 
+       struct crom_chunk *ref_chunk;
+       int ref_index;
        int offset;
        struct {
                BIT16x2(crc_len, crc);
-               uint32_t buf[CROM_MAX_CHUNK_LEN]; 
+               uint32_t buf[CROM_MAX_CHUNK_LEN];
        } data;
 };
 
@@ -246,6 +252,9 @@
 extern int crom_add_chunk(struct crom_src *src, struct crom_chunk *,
                                        struct crom_chunk *, int);
 extern int crom_add_simple_text(struct crom_src *src, struct crom_chunk *,
-                                       struct crom_chunk *, char *);
+                                       struct crom_chunk *, const char *);
 extern int crom_load(struct crom_src *, uint32_t *, int);
+
 #endif
+
+__END_DECLS

Modified: haiku/trunk/headers/private/kernel/arch/arm/arch_thread.h
===================================================================
--- haiku/trunk/headers/private/kernel/arch/arm/arch_thread.h   2011-01-10 
21:14:06 UTC (rev 40195)
+++ haiku/trunk/headers/private/kernel/arch/arm/arch_thread.h   2011-01-10 
21:54:38 UTC (rev 40196)
@@ -22,9 +22,9 @@
 
 /* as we won't support SMP on arm (yet?) we can use a global here */
 /*TODO SMP-ARMS are comming..*/
-extern struct thread *gCurrentThread;
+extern Thread *gCurrentThread;
 
-extern inline struct thread *
+extern inline Thread *
 arch_thread_get_current_thread(void)
 {
        return gCurrentThread;
@@ -32,7 +32,7 @@
 
 
 extern inline void
-arch_thread_set_current_thread(struct thread *t)
+arch_thread_set_current_thread(Thread *t)
 {
        gCurrentThread = t;
 }

Modified: haiku/trunk/headers/private/kernel/arch/debug.h
===================================================================
--- haiku/trunk/headers/private/kernel/arch/debug.h     2011-01-10 21:14:06 UTC 
(rev 40195)
+++ haiku/trunk/headers/private/kernel/arch/debug.h     2011-01-10 21:54:38 UTC 
(rev 40196)
@@ -16,9 +16,14 @@
 
 
 struct kernel_args;
-struct thread;
 
+namespace BKernel {
+       struct Thread;
+}
 
+using BKernel::Thread;
+
+
 // arch_debug_get_stack_trace() flags
 #define STACK_TRACE_KERNEL     0x01
 #define STACK_TRACE_USER       0x02
@@ -34,7 +39,7 @@
 int32 arch_debug_get_stack_trace(addr_t* returnAddresses, int32 maxCount,
                int32 skipIframes, int32 skipFrames, uint32 flags);
 void* arch_debug_get_interrupt_pc(bool* _isSyscall);
-bool arch_debug_contains_call(struct thread *thread, const char *symbol,
+bool arch_debug_contains_call(Thread *thread, const char *symbol,
                addr_t start, addr_t end);
 void arch_debug_save_registers(struct arch_debug_registers* registers);
 void arch_debug_unset_current_thread(void);

Modified: haiku/trunk/headers/private/kernel/arch/m68k/arch_cpu.h
===================================================================
--- haiku/trunk/headers/private/kernel/arch/m68k/arch_cpu.h     2011-01-10 
21:14:06 UTC (rev 40195)
+++ haiku/trunk/headers/private/kernel/arch/m68k/arch_cpu.h     2011-01-10 
21:54:38 UTC (rev 40196)
@@ -22,7 +22,7 @@
 
 #ifndef _ASSEMBLER
 
-/* 68k has many different possible stack frames, differentiated by a 4 bit 
number, 
+/* 68k has many different possible stack frames, differentiated by a 4 bit 
number,
  * but they also depend on the cpu type.
  * cf. mint/sys/arch/check_exc.h
  */
@@ -283,7 +283,7 @@
        struct mc680x0_fp_control_regs fpc;
        /* fpu state */
        struct mc680x0_fpu_state fpu;
-       
+
        /* data and address registers */
        uint32 d[8];
        uint32 a[7];
@@ -517,7 +517,7 @@
        Use of (some) special purpose registers.
        XXX: those regs aren't implemented/accessed the same way on different 
cpus...
 
-       SRP[63-32]: current struct thread*
+       SRP[63-32]: current Thread*
        SRP[31-0] :
        CAAR      : can we use it ??
        MSP       :
@@ -526,7 +526,7 @@
        SPRG0: per CPU physical address pointer to an ppc_cpu_exception_context
               structure
        SPRG1: scratch
-       SPRG2: current struct thread*
+       SPRG2: current Thread*
        SPRG3: TLS base pointer (only for userland threads)
 */
 

Modified: haiku/trunk/headers/private/kernel/arch/m68k/arch_thread.h
===================================================================
--- haiku/trunk/headers/private/kernel/arch/m68k/arch_thread.h  2011-01-10 
21:14:06 UTC (rev 40195)
+++ haiku/trunk/headers/private/kernel/arch/m68k/arch_thread.h  2011-01-10 
21:54:38 UTC (rev 40196)
@@ -1,5 +1,5 @@
 /*
- * Copyright 2003-2006, Haiku Inc. All rights reserved.
+ * Copyright 2003-2011, Haiku Inc. All rights reserved.
  * Distributed under the terms of the MIT License.
  *
  * Authors:
@@ -20,9 +20,9 @@
 struct iframe *m68k_get_user_iframe(void);
 
 /* as we won't support SMP on m68k (yet?) we can use a global here */
-extern struct thread *gCurrentThread;
+extern Thread *gCurrentThread;
 
-extern inline struct thread *
+extern inline Thread *
 arch_thread_get_current_thread(void)
 {
        return gCurrentThread;
@@ -30,7 +30,7 @@
 
 
 extern inline void
-arch_thread_set_current_thread(struct thread *t)
+arch_thread_set_current_thread(Thread *t)
 {
        gCurrentThread = t;
 }
@@ -38,17 +38,17 @@
 #if 0
 /* this would only work on 030... */
 
-extern inline struct thread *
+extern inline Thread *
 arch_thread_get_current_thread(void)
 {
        uint64 v = 0;
        asm volatile("pmove %%srp,(%0)" : : "a"(&v));
-       return (struct thread *)(uint32)(v & 0xffffffff);
+       return (Thread *)(uint32)(v & 0xffffffff);
 }
 
 
 extern inline void
-arch_thread_set_current_thread(struct thread *t)
+arch_thread_set_current_thread(Thread *t)
 {
        uint64 v;
        asm volatile("pmove %%srp,(%0)\n" \

Modified: haiku/trunk/headers/private/kernel/arch/mipsel/arch_thread.h
===================================================================
--- haiku/trunk/headers/private/kernel/arch/mipsel/arch_thread.h        
2011-01-10 21:14:06 UTC (rev 40195)
+++ haiku/trunk/headers/private/kernel/arch/mipsel/arch_thread.h        
2011-01-10 21:54:38 UTC (rev 40196)
@@ -1,5 +1,5 @@
 /*
- * Copyright 2003-2009, Haiku Inc. All rights reserved.
+ * Copyright 2003-2011, Haiku Inc. All rights reserved.
  * Distributed under the terms of the MIT License.
  *
  * Authors:
@@ -22,17 +22,17 @@
 struct iframe* mipsel_get_user_iframe(void);
 
 
-static inline struct thread* 
+static inline Thread*
 arch_thread_get_current_thread(void)
 {
 #warning IMPLEMENT arch_thread_get_current_thread
-    struct thread* t;
+    Thread* t;
     return t;
 }
 
 
 static inline void
-arch_thread_set_current_thread(struct thread* t)
+arch_thread_set_current_thread(Thread* t)
 {
 #warning IMPLEMENT arch_thread_set_current_thread
 }

Modified: haiku/trunk/headers/private/kernel/arch/ppc/arch_cpu.h
===================================================================
--- haiku/trunk/headers/private/kernel/arch/ppc/arch_cpu.h      2011-01-10 
21:14:06 UTC (rev 40195)
+++ haiku/trunk/headers/private/kernel/arch/ppc/arch_cpu.h      2011-01-10 
21:54:38 UTC (rev 40196)
@@ -206,7 +206,7 @@
        SPRG0: per CPU physical address pointer to an ppc_cpu_exception_context
               structure
        SPRG1: scratch
-       SPRG2: current struct thread*
+       SPRG2: current Thread*
        SPRG3: TLS base pointer (only for userland threads)
 */
 

Modified: haiku/trunk/headers/private/kernel/arch/ppc/arch_thread.h
===================================================================
--- haiku/trunk/headers/private/kernel/arch/ppc/arch_thread.h   2011-01-10 
21:14:06 UTC (rev 40195)
+++ haiku/trunk/headers/private/kernel/arch/ppc/arch_thread.h   2011-01-10 
21:54:38 UTC (rev 40196)
@@ -1,5 +1,5 @@
 /*
- * Copyright 2003-2006, Haiku Inc. All rights reserved.
+ * Copyright 2003-2011, Haiku Inc. All rights reserved.
  * Distributed under the terms of the MIT License.
  *
  * Authors:
@@ -20,17 +20,17 @@
 struct iframe *ppc_get_user_iframe(void);
 
 
-static inline struct thread *
+static inline Thread *
 arch_thread_get_current_thread(void)
 {
-    struct thread *t;
+    Thread *t;
     asm volatile("mfsprg2 %0" : "=r"(t));
     return t;
 }
 
 
 static inline void
-arch_thread_set_current_thread(struct thread *t)
+arch_thread_set_current_thread(Thread *t)
 {
     asm volatile("mtsprg2 %0" : : "r"(t));
 }

Modified: haiku/trunk/headers/private/kernel/arch/thread.h
===================================================================
--- haiku/trunk/headers/private/kernel/arch/thread.h    2011-01-10 21:14:06 UTC 
(rev 40195)
+++ haiku/trunk/headers/private/kernel/arch/thread.h    2011-01-10 21:54:38 UTC 
(rev 40196)
@@ -17,18 +17,18 @@
 #endif
 
 status_t arch_thread_init(struct kernel_args *args);
-status_t arch_team_init_team_struct(struct team *t, bool kernel);
-status_t arch_thread_init_thread_struct(struct thread *t);
-status_t arch_thread_init_tls(struct thread *thread);
-void arch_thread_context_switch(struct thread *t_from, struct thread *t_to);
-status_t arch_thread_init_kthread_stack(struct thread *t,
+status_t arch_team_init_team_struct(Team *t, bool kernel);
+status_t arch_thread_init_thread_struct(Thread *t);
+status_t arch_thread_init_tls(Thread *thread);
+void arch_thread_context_switch(Thread *t_from, Thread *t_to);
+status_t arch_thread_init_kthread_stack(Thread *t,
        int (*start_func)(void), void (*entry_func)(void), void 
(*exit_func)(void));
 void arch_thread_dump_info(void *info);
-status_t arch_thread_enter_userspace(struct thread *t, addr_t entry,
+status_t arch_thread_enter_userspace(Thread *t, addr_t entry,
        void *args1, void *args2);
 
-bool arch_on_signal_stack(struct thread *thread);
-status_t arch_setup_signal_frame(struct thread *t, struct sigaction *sa,
+bool arch_on_signal_stack(Thread *thread);
+status_t arch_setup_signal_frame(Thread *t, struct sigaction *sa,
        int signal, int signalMask);
 int64 arch_restore_signal_frame(void);
 

Modified: haiku/trunk/headers/private/kernel/arch/user_debugger.h
===================================================================
--- haiku/trunk/headers/private/kernel/arch/user_debugger.h     2011-01-10 
21:14:06 UTC (rev 40195)
+++ haiku/trunk/headers/private/kernel/arch/user_debugger.h     2011-01-10 
21:54:38 UTC (rev 40196)
@@ -1,10 +1,11 @@
 /*
- * Copyright 2005, Ingo Weinhold, bonefish@xxxxxxxxxxxxx
+ * Copyright 2005-2011, Ingo Weinhold, ingo_weinhold@xxxxxxx
  * Distributed under the terms of the MIT License.
  */
 #ifndef KERNEL_ARCH_USER_DEBUGGER_H
 #define KERNEL_ARCH_USER_DEBUGGER_H
 
+
 #include "kernel_debug_config.h"
 
 #ifndef _ASSEMBLER
@@ -17,8 +18,8 @@
 
 struct arch_team_debug_info;
 struct arch_thread_debug_info;
-struct thread;
 
+
 void arch_clear_team_debug_info(struct arch_team_debug_info *info);
 void arch_destroy_team_debug_info(struct arch_team_debug_info *info);
 void arch_clear_thread_debug_info(struct arch_thread_debug_info *info);

Modified: haiku/trunk/headers/private/kernel/arch/x86/arch_thread.h
===================================================================
--- haiku/trunk/headers/private/kernel/arch/x86/arch_thread.h   2011-01-10 
21:14:06 UTC (rev 40195)
+++ haiku/trunk/headers/private/kernel/arch/x86/arch_thread.h   2011-01-10 
21:54:38 UTC (rev 40196)
@@ -1,5 +1,5 @@
 /*
- * Copyright 2002-2009, The Haiku Team. All rights reserved.
+ * Copyright 2002-2011, The Haiku Team. All rights reserved.
  * Distributed under the terms of the MIT License.
  *
  * Copyright 2002, Travis Geiselbrecht. All rights reserved.
@@ -18,9 +18,9 @@
 
 struct iframe *i386_get_user_iframe(void);
 struct iframe *i386_get_current_iframe(void);
-struct iframe *i386_get_thread_user_iframe(struct thread *thread);
+struct iframe *i386_get_thread_user_iframe(Thread *thread);
 
-uint32 x86_next_page_directory(struct thread *from, struct thread *to);
+uint32 x86_next_page_directory(Thread *from, Thread *to);
 
 void x86_restart_syscall(struct iframe* frame);
 
@@ -33,16 +33,16 @@
 
 
 static
-inline struct thread *
+inline Thread *
 arch_thread_get_current_thread(void)
 {
-       struct thread *t;
+       Thread *t;
        read_dr3(t);
        return t;
 }
 
 static inline void
-arch_thread_set_current_thread(struct thread *t)
+arch_thread_set_current_thread(Thread *t)
 {
        write_dr3(t);
 }

Modified: haiku/trunk/headers/private/kernel/arch/x86/arch_user_debugger.h
===================================================================
--- haiku/trunk/headers/private/kernel/arch/x86/arch_user_debugger.h    
2011-01-10 21:14:06 UTC (rev 40195)
+++ haiku/trunk/headers/private/kernel/arch/x86/arch_user_debugger.h    
2011-01-10 21:54:38 UTC (rev 40196)
@@ -1,14 +1,15 @@
 /*
- * Copyright 2005-2009, Ingo Weinhold, bonefish@xxxxxxxxxxxxx
+ * Copyright 2005-2011, Ingo Weinhold, ingo_weinhold@xxxxxxx
  * Distributed under the terms of the MIT License.
  */
 #ifndef _KERNEL_ARCH_X86_USER_DEBUGGER_H
 #define _KERNEL_ARCH_X86_USER_DEBUGGER_H
 
+
 #define ARCH_INIT_USER_DEBUG x86_init_user_debug
 
 // number of breakpoints the CPU supports
-// Actually it supports 4, but DR3 is used to hold the struct thread*.
+// Actually it supports 4, but DR3 is used to hold the Thread*.
 #define X86_BREAKPOINT_COUNT   3
 
 // debug status register DR6
@@ -116,7 +117,6 @@
 #endif
 
 struct iframe;
-struct thread;
 
 extern void x86_init_user_debug_at_kernel_exit(struct iframe *frame);
 extern void x86_exit_user_debug_at_kernel_entry();
@@ -137,4 +137,5 @@
 #define DEBUG_SOFTWARE_BREAKPOINT_SIZE         1
 #define DEBUG_SHARED_BREAK_AND_WATCHPOINTS     1
 
+
 #endif // _KERNEL_ARCH_X86_USER_DEBUGGER_H

Modified: haiku/trunk/headers/private/kernel/condition_variable.h
===================================================================
--- haiku/trunk/headers/private/kernel/condition_variable.h     2011-01-10 
21:14:06 UTC (rev 40195)
+++ haiku/trunk/headers/private/kernel/condition_variable.h     2011-01-10 
21:54:38 UTC (rev 40196)
@@ -1,5 +1,5 @@
 /*
- * Copyright 2007-2008, Ingo Weinhold, bonefish@xxxxxxxxxxxxxxxx
+ * Copyright 2007-2011, Ingo Weinhold, ingo_weinhold@xxxxxxx
  * Distributed under the terms of the MIT License.
  */
 #ifndef _KERNEL_CONDITION_VARIABLE_H
@@ -41,7 +41,7 @@
 
 private:
                        ConditionVariable*      fVariable;
-                       struct thread*          fThread;
+                       Thread*                         fThread;
                        status_t                        fWaitStatus;
 
                        friend struct ConditionVariable;

Modified: haiku/trunk/headers/private/kernel/cpu.h
===================================================================
--- haiku/trunk/headers/private/kernel/cpu.h    2011-01-10 21:14:06 UTC (rev 
40195)
+++ haiku/trunk/headers/private/kernel/cpu.h    2011-01-10 21:54:38 UTC (rev 
40196)
@@ -23,9 +23,14 @@
 
 
 struct kernel_args;
-struct thread;
 
+namespace BKernel {
+       struct Thread;
+}
 
+using BKernel::Thread;
+
+
 /* CPU local data structure */
 
 typedef struct cpu_ent {
@@ -45,7 +50,7 @@
        addr_t                  fault_handler_stack_pointer;
        jmp_buf                 fault_jump_buffer;
 
-       struct thread*  running_thread;
+       Thread*                 running_thread;
        bool                    invoke_scheduler;
        bool                    invoke_scheduler_if_idle;
        bool                    disabled;

Modified: haiku/trunk/headers/private/kernel/debug.h
===================================================================
--- haiku/trunk/headers/private/kernel/debug.h  2011-01-10 21:14:06 UTC (rev 
40195)
+++ haiku/trunk/headers/private/kernel/debug.h  2011-01-10 21:54:38 UTC (rev 
40196)
@@ -17,6 +17,22 @@
 #include "kernel_debug_config.h"
 
 
+// We need the BKernel::Thread type below (opaquely) in the exported C
+// functions below. Since this header is currently still included by plain C
+// code, we define a dummy type BKernel_Thread in C mode and a equally named
+// macro in C++ mode.
+#ifdef __cplusplus
+       namespace BKernel {
+               struct Thread;
+       }
+
+       using BKernel::Thread;
+#      define BKernel_Thread   Thread
+#else
+       typedef struct BKernel_Thread BKernel_Thread;
+#endif
+
+
 /*     KDEBUG
        The kernel debug level.
        Level 1 is usual asserts, > 1 should be used for very expensive runtime
@@ -180,8 +196,8 @@
                                        const char* symbol, char* name, size_t 
nameSize,
                                        int32* _type, size_t* _argumentLength);
 
-extern struct thread* debug_set_debugged_thread(struct thread* thread);
-extern struct thread* debug_get_debugged_thread();
+extern BKernel_Thread* debug_set_debugged_thread(BKernel_Thread* thread);
+extern BKernel_Thread* debug_get_debugged_thread();
 extern bool debug_is_debugged_team(team_id teamID);
 
 extern struct arch_debug_registers* debug_get_debug_registers(int32 cpu);
@@ -197,7 +213,7 @@
 #ifdef __cplusplus
 
 struct DebuggedThreadSetter {
-       DebuggedThreadSetter(struct thread* thread)
+       DebuggedThreadSetter(Thread* thread)
                :
                fPreviousThread(debug_set_debugged_thread(thread))
        {
@@ -209,7 +225,7 @@
        }
 
 private:
-       struct thread*  fPreviousThread;
+       Thread* fPreviousThread;
 };
 
 

Modified: haiku/trunk/headers/private/kernel/elf.h
===================================================================
--- haiku/trunk/headers/private/kernel/elf.h    2011-01-10 21:14:06 UTC (rev 
40195)
+++ haiku/trunk/headers/private/kernel/elf.h    2011-01-10 21:54:38 UTC (rev 
40196)
@@ -20,7 +20,8 @@
 extern "C" {
 #endif
 
-status_t elf_load_user_image(const char *path, struct team *team, int flags, 
addr_t *_entry);
+status_t elf_load_user_image(const char *path, Team *team, int flags,
+       addr_t *_entry);
 
 // these two might get public one day:
 image_id load_kernel_add_on(const char *path);
@@ -29,7 +30,7 @@
 status_t elf_debug_lookup_symbol_address(addr_t address, addr_t *_baseAddress,
                        const char **_symbolName, const char **_imageName,
                        bool *_exactMatch);
-status_t elf_debug_lookup_user_symbol_address(struct team* team, addr_t 
address,
+status_t elf_debug_lookup_user_symbol_address(Team* team, addr_t address,
                        addr_t *_baseAddress, const char **_symbolName,
                        const char **_imageName, bool *_exactMatch);
 addr_t elf_debug_lookup_symbol(const char* searchName);

Modified: haiku/trunk/headers/private/kernel/kimage.h
===================================================================
--- haiku/trunk/headers/private/kernel/kimage.h 2011-01-10 21:14:06 UTC (rev 
40195)
+++ haiku/trunk/headers/private/kernel/kimage.h 2011-01-10 21:54:38 UTC (rev 
40196)
@@ -9,8 +9,14 @@
 
 
 struct image;
-struct team;
 
+namespace BKernel {
+       struct Team;
+}
+
+using BKernel::Team;
+
+
 #ifdef __cplusplus
 
 #include <util/OpenHashTable.h>
@@ -35,16 +41,16 @@
 extern "C" {
 #endif
 
-extern image_id register_image(struct team *team, image_info *info, size_t 
size);
-extern status_t unregister_image(struct team *team, image_id id);
-extern int32 count_images(struct team *team);
-extern status_t remove_images(struct team *team);
+extern image_id register_image(Team *team, image_info *info, size_t size);
+extern status_t unregister_image(Team *team, image_id id);
+extern int32 count_images(Team *team);
+extern status_t remove_images(Team *team);
 
 typedef bool (*image_iterator_callback)(struct image* image, void* cookie);
 struct image* image_iterate_through_images(image_iterator_callback callback,
                                        void* cookie);
 
-extern status_t image_debug_lookup_user_symbol_address(struct team *team,
+extern status_t image_debug_lookup_user_symbol_address(Team *team,
                                        addr_t address, addr_t *_baseAddress, 
const char **_symbolName,
                                        const char **_imageName, bool 
*_exactMatch);
 extern status_t image_init(void);

Modified: haiku/trunk/headers/private/kernel/kscheduler.h
===================================================================
--- haiku/trunk/headers/private/kernel/kscheduler.h     2011-01-10 21:14:06 UTC 
(rev 40195)
+++ haiku/trunk/headers/private/kernel/kscheduler.h     2011-01-10 21:54:38 UTC 
(rev 40196)
@@ -1,5 +1,5 @@
 /*
- * Copyright 2008-2010, Ingo Weinhold, ingo_weinhold@xxxxxxx
+ * Copyright 2008-2011, Ingo Weinhold, ingo_weinhold@xxxxxxx
  * Copyright 2005-2010, Axel Dörfler, axeld@xxxxxxxxxxxxxxxxx
  * Distributed under the terms of the MIT License.
  */
@@ -14,25 +14,24 @@
 
 
 struct scheduling_analysis;
-struct thread;
 struct SchedulerListener;
 
 
 struct scheduler_ops {
-       void (*enqueue_in_run_queue)(struct thread* thread);
+       void (*enqueue_in_run_queue)(Thread* thread);
        void (*reschedule)(void);
-       void (*set_thread_priority)(struct thread* thread, int32 priority);
-       bigtime_t (*estimate_max_scheduling_latency)(struct thread* thread);
+       void (*set_thread_priority)(Thread* thread, int32 priority);
+       bigtime_t (*estimate_max_scheduling_latency)(Thread* thread);
 
-       void (*on_thread_create)(struct thread* thread);
+       void (*on_thread_create)(Thread* thread);
                // called when the thread structure is first created -
                // initialization of per-thread housekeeping data structures 
should
                // be done here
-       void (*on_thread_init)(struct thread* thread);
+       void (*on_thread_init)(Thread* thread);
                // called when a thread structure is initialized and made ready 
for
                // use - should be used to reset the housekeeping data 
structures
                // if needed
-       void (*on_thread_destroy)(struct thread* thread);
+       void (*on_thread_destroy)(Thread* thread);
                // called when a thread structure is freed - freeing up any 
allocated
                // mem on the scheduler's part should be done here
 

Modified: haiku/trunk/headers/private/kernel/ksignal.h
===================================================================
--- haiku/trunk/headers/private/kernel/ksignal.h        2011-01-10 21:14:06 UTC 
(rev 40195)
+++ haiku/trunk/headers/private/kernel/ksignal.h        2011-01-10 21:54:38 UTC 
(rev 40196)
@@ -10,6 +10,13 @@
 #include <signal.h>
 
 
+namespace BKernel {
+       struct Thread;
+}
+
+using BKernel::Thread;
+
+
 #define KILL_SIGNALS   ((1L << (SIGKILL - 1)) | (1L << (SIGKILLTHR - 1)))
 
 #define SIGNAL_TO_MASK(signal) (1LL << (signal - 1))
@@ -24,7 +31,7 @@
 extern "C" {
 #endif
 
-extern bool handle_signals(struct thread *thread);
+extern bool handle_signals(Thread *thread);
 extern bool is_kill_signal_pending(void);
 extern int has_signals_pending(void *_thread);
 extern bool is_signal_blocked(int signal);

Modified: haiku/trunk/headers/private/kernel/listeners.h
===================================================================
--- haiku/trunk/headers/private/kernel/listeners.h      2011-01-10 21:14:06 UTC 
(rev 40195)
+++ haiku/trunk/headers/private/kernel/listeners.h      2011-01-10 21:54:38 UTC 
(rev 40196)
@@ -1,10 +1,11 @@
 /*
- * Copyright 2009, Ingo Weinhold, ingo_weinhold@xxxxxxx
+ * Copyright 2009-2011, Ingo Weinhold, ingo_weinhold@xxxxxxx
  * Distributed under the terms of the MIT License.
  */
 #ifndef KERNEL_LISTENERS_H
 #define KERNEL_LISTENERS_H
 
+
 #include <KernelExport.h>
 
 #include <util/AutoLock.h>
@@ -14,7 +15,6 @@
 struct ConditionVariable;
 struct mutex;
 struct rw_lock;
-struct thread;
 
 
 // scheduler listeners
@@ -24,11 +24,11 @@
        virtual                                         ~SchedulerListener();
 
        virtual void                            ThreadEnqueuedInRunQueue(
-                                                                       struct 
thread* thread) = 0;
+                                                                       Thread* 
thread) = 0;
        virtual void                            ThreadRemovedFromRunQueue(
-                                                                       struct 
thread* thread) = 0;
-       virtual void                            ThreadScheduled(struct thread* 
oldThread,
-                                                                       struct 
thread* newThread) = 0;
+                                                                       Thread* 
thread) = 0;
+       virtual void                            ThreadScheduled(Thread* 
oldThread,
+                                                                       Thread* 
newThread) = 0;
 };
 
 

Modified: haiku/trunk/headers/private/kernel/port.h
===================================================================
--- haiku/trunk/headers/private/kernel/port.h   2011-01-10 21:14:06 UTC (rev 
40195)
+++ haiku/trunk/headers/private/kernel/port.h   2011-01-10 21:54:38 UTC (rev 
40196)
@@ -32,7 +32,7 @@
 #endif
 
 status_t port_init(struct kernel_args *args);
-void delete_owned_ports(struct team* team);
+void delete_owned_ports(Team* team);
 int32 port_max_ports(void);
 int32 port_used_ports(void);
 

Modified: haiku/trunk/headers/private/kernel/posix/xsi_semaphore.h
===================================================================
--- haiku/trunk/headers/private/kernel/posix/xsi_semaphore.h    2011-01-10 
21:14:06 UTC (rev 40195)
+++ haiku/trunk/headers/private/kernel/posix/xsi_semaphore.h    2011-01-10 
21:54:38 UTC (rev 40196)
@@ -14,10 +14,17 @@
 #include <posix/xsi_semaphore_defs.h>
 
 
+namespace BKernel {
+       struct Team;
+}
+
+using BKernel::Team;
+
+
 __BEGIN_DECLS
 
 extern void xsi_sem_init();
-extern void xsi_sem_undo(struct team *team);
+extern void xsi_sem_undo(Team *team);
 
 /* user calls */
 int _user_xsi_semget(key_t key, int numberOfSemaphores, int flags);

Modified: haiku/trunk/headers/private/kernel/sem.h
===================================================================
--- haiku/trunk/headers/private/kernel/sem.h    2011-01-10 21:14:06 UTC (rev 
40195)
+++ haiku/trunk/headers/private/kernel/sem.h    2011-01-10 21:54:38 UTC (rev 
40196)
@@ -22,7 +22,7 @@
 #endif
 
 extern status_t haiku_sem_init(struct kernel_args *args);
-extern void sem_delete_owned_sems(struct team* team);
+extern void sem_delete_owned_sems(Team* team);
 extern int32 sem_used_sems(void);
 extern int32 sem_max_sems(void);
 

Modified: haiku/trunk/headers/private/kernel/syscall_restart.h
===================================================================
--- haiku/trunk/headers/private/kernel/syscall_restart.h        2011-01-10 
21:14:06 UTC (rev 40195)
+++ haiku/trunk/headers/private/kernel/syscall_restart.h        2011-01-10 
21:54:38 UTC (rev 40196)
@@ -1,10 +1,11 @@
 /*
- * Copyright 2008, Haiku Inc. All rights reserved.
+ * Copyright 2008-2011, Haiku Inc. All rights reserved.
  * Distributed under the terms of the MIT License.
  */
 #ifndef _KERNEL_SYSCALL_RESTART_H
 #define _KERNEL_SYSCALL_RESTART_H
 
+
 #include <OS.h>
 
 #include <thread.h>
@@ -20,7 +21,7 @@
 {
        // If restarted, get the timeout from the restart parameters. Otherwise
        // convert relative timeout to an absolute one.
-       struct thread* thread = thread_get_current_thread();
+       Thread* thread = thread_get_current_thread();
        if ((thread->flags & THREAD_FLAGS_SYSCALL_RESTARTED) != 0)
                timeout = *(bigtime_t*)thread->syscall_restart.parameters;
        else if (timeout >= 0) {
@@ -44,7 +45,7 @@
        // convert relative timeout to an absolute one. Note that we preserve
        // relative 0 us timeouts, so that the syscall can still decide whether 
to
        // return B_WOULD_BLOCK instead of B_TIMED_OUT.
-       struct thread* thread = thread_get_current_thread();
+       Thread* thread = thread_get_current_thread();
        if ((thread->flags & THREAD_FLAGS_SYSCALL_RESTARTED) != 0) {
                timeout = *(bigtime_t*)thread->syscall_restart.parameters;
                if (timeout > 0 && (flags & B_RELATIVE_TIMEOUT) != 0)
@@ -67,7 +68,7 @@
 {
        if (error == B_INTERRUPTED) {
                // interrupted -- store timeout and set flag for syscall restart
-               struct thread* thread = thread_get_current_thread();
+               Thread* thread = thread_get_current_thread();
                *(bigtime_t*)thread->syscall_restart.parameters = timeout;
                atomic_or(&thread->flags, THREAD_FLAGS_RESTART_SYSCALL);
        }
@@ -81,7 +82,7 @@
 {
        if (error == B_INTERRUPTED) {
                // interrupted -- set flag for syscall restart
-               struct thread* thread = thread_get_current_thread();
+               Thread* thread = thread_get_current_thread();
                atomic_or(&thread->flags, THREAD_FLAGS_RESTART_SYSCALL);
        }
 
@@ -92,7 +93,7 @@
 static inline bool
 syscall_restart_is_restarted()
 {
-       struct thread* thread = thread_get_current_thread();
+       Thread* thread = thread_get_current_thread();
 
        return (thread->flags & THREAD_FLAGS_SYSCALL) != 0
                && (thread->flags & THREAD_FLAGS_SYSCALL_RESTARTED) != 0;
@@ -114,8 +115,8 @@
        }
 
 private:
-       struct thread*  fThread;
-       bool                    fWasSyscall;
+       Thread* fThread;
+       bool    fWasSyscall;
 };
 
 
@@ -147,8 +148,8 @@
        operator Type() const   { return fResult; }
 
 private:
-       Type                    fResult;
-       struct thread*  fThread;
+       Type    fResult;
+       Thread* fThread;
 };
 
 

Modified: haiku/trunk/headers/private/kernel/team.h
===================================================================
--- haiku/trunk/headers/private/kernel/team.h   2011-01-10 21:14:06 UTC (rev 
40195)
+++ haiku/trunk/headers/private/kernel/team.h   2011-01-10 21:54:38 UTC (rev 
40196)
@@ -1,5 +1,5 @@
 /*
- * Copyright 2004-2009, Haiku Inc. All Rights Reserved.
+ * Copyright 2004-2011, Haiku Inc. All Rights Reserved.
  * Distributed under the terms of the MIT License.
  */
 #ifndef _TEAM_H
@@ -22,34 +22,34 @@
 
 status_t team_init(struct kernel_args *args);
 status_t wait_for_team(team_id id, status_t *returnCode);
-void team_remove_team(struct team *team);
-port_id team_shutdown_team(struct team *team, cpu_status& state);
-void team_delete_team(struct team *team, port_id debuggerPort);
+void team_remove_team(Team *team);
+port_id team_shutdown_team(Team *team, cpu_status& state);
+void team_delete_team(Team *team, port_id debuggerPort);
 struct process_group *team_get_process_group_locked(
                        struct process_session *session, pid_t id);
 void team_delete_process_group(struct process_group *group);
-struct team *team_get_kernel_team(void);
+Team *team_get_kernel_team(void);
 team_id team_get_kernel_team_id(void);
 team_id team_get_current_team_id(void);
 status_t team_get_address_space(team_id id,
                        struct VMAddressSpace **_addressSpace);
 char **user_team_get_arguments(void);
 int user_team_get_arg_count(void);
-struct job_control_entry* team_get_death_entry(struct team *team,
+struct job_control_entry* team_get_death_entry(Team *team,
                        thread_id child, bool* _deleteEntry);
 bool team_is_valid(team_id id);
-struct team *team_get_team_struct_locked(team_id id);
+Team *team_get_team_struct_locked(team_id id);
 int32 team_max_teams(void);
 int32 team_used_teams(void);
 
-typedef bool (*team_iterator_callback)(struct team* team, void* cookie);
-struct team* team_iterate_through_teams(team_iterator_callback callback,

[... truncated: 17202 lines follow ...]

Other related posts:

  • » [haiku-commits] r40196 - in haiku/trunk: . build/jam headers/libs/freetype2 headers/libs/png headers/libs/tiff ... - ingo_weinhold