Index: linux-2.6.15/arch/arm/kernel/time.c
===================================================================
--- linux-2.6.15.orig/arch/arm/kernel/time.c	2006-02-08 17:46:40.000000000 +0000
+++ linux-2.6.15/arch/arm/kernel/time.c	2006-02-08 17:46:48.000000000 +0000
@@ -289,10 +289,6 @@
 	set_normalized_timespec(&xtime, sec, nsec);
 	set_normalized_timespec(&wall_to_monotonic, wtm_sec, wtm_nsec);
 
-#ifdef CONFIG_LTT
-	ltt_reset_timestamp();
-#endif //CONFIG_LTT
-
 	ntp_clear();
 	write_sequnlock_irq(&xtime_lock);
 	clock_was_set();
@@ -343,6 +339,9 @@
 	do_leds();
 	do_set_rtc();
 	do_timer(regs);
+#ifdef CONFIG_LTT
+	ltt_reset_timestamp();
+#endif
 #ifndef CONFIG_SMP
 	update_process_times(user_mode(regs));
 #endif
Index: linux-2.6.15/include/asm-arm/ltt/ltt-facility-kernel_arch_arm.h
===================================================================
--- linux-2.6.15.orig/include/asm-arm/ltt/ltt-facility-kernel_arch_arm.h	2006-02-08 17:46:40.000000000 +0000
+++ linux-2.6.15/include/asm-arm/ltt/ltt-facility-kernel_arch_arm.h	2006-02-08 21:10:03.000000000 +0000
@@ -301,6 +301,12 @@
 	LTTNG_mbind = 319,
 	LTTNG_get_mempolicy = 320,
 	LTTNG_set_mempolicy = 321,
+	LTTNG_arm_syscall_offset = 1024,
+	LTTNG_breakpoint = 1025,
+	LTTNG_cacheflush = 1026,
+	LTTNG_usr26 = 1027,
+	LTTNG_usr32 = 1028,
+	LTTNG_set_tls = 1029,
 };
 
 /* Event syscall_entry structures */
@@ -365,7 +371,7 @@
 	reserve_size = *to_base + *to + *len;
 	preempt_disable();
 	ltt_nesting[smp_processor_id()]++;
-	index = ltt_get_index_from_facility(ltt_facility_kernel_arch_62B14C1E,
+	index = ltt_get_index_from_facility(ltt_facility_kernel_arch_8E8193AC,
 						event_kernel_arch_syscall_entry);
 
 	list_for_each_entry_rcu(trace, &ltt_traces.head, list) {
@@ -383,7 +389,7 @@
 		*to_base = *to = *len = 0;
 
 		ltt_write_event_header(trace, channel, buffer,
-			ltt_facility_kernel_arch_62B14C1E, event_kernel_arch_syscall_entry,
+			ltt_facility_kernel_arch_8E8193AC, event_kernel_arch_syscall_entry,
 			reserve_size, before_hdr_pad, tsc);
 		*to_base += before_hdr_pad + after_hdr_pad + header_size;
 
@@ -469,7 +475,7 @@
 	reserve_size = *to_base + *to + *len;
 	preempt_disable();
 	ltt_nesting[smp_processor_id()]++;
-	index = ltt_get_index_from_facility(ltt_facility_kernel_arch_62B14C1E,
+	index = ltt_get_index_from_facility(ltt_facility_kernel_arch_8E8193AC,
 						event_kernel_arch_syscall_exit);
 
 	list_for_each_entry_rcu(trace, &ltt_traces.head, list) {
@@ -487,7 +493,7 @@
 		*to_base = *to = *len = 0;
 
 		ltt_write_event_header(trace, channel, buffer,
-			ltt_facility_kernel_arch_62B14C1E, event_kernel_arch_syscall_exit,
+			ltt_facility_kernel_arch_8E8193AC, event_kernel_arch_syscall_exit,
 			reserve_size, before_hdr_pad, tsc);
 		*to_base += before_hdr_pad + after_hdr_pad + header_size;
 
Index: linux-2.6.15/arch/arm/kernel/entry-common.S
===================================================================
--- linux-2.6.15.orig/arch/arm/kernel/entry-common.S	2006-02-08 17:46:40.000000000 +0000
+++ linux-2.6.15/arch/arm/kernel/entry-common.S	2006-02-08 19:03:49.000000000 +0000
@@ -150,11 +150,14 @@
 #endif
 	enable_irq
 #if (CONFIG_LTT)
-	/* zzz note that validity of scno is not yet checked.
-	 * zzz The visualizer checks it.
-	 */
-	add	r1, sp, #S_R0			@ pointer to regs
+
 	mov	r0, scno  		        @ syscall number
+	tst	r0, #0x000f0000			@ Is this an ARM specific syscall
+	orrne	r0, r0, #0x400			@ if so offset the number by 1024
+	bic     r0, r0, #0xff000000             @ mask off SWI op-code and other syscall offsets
+	bic     r0, r0, #0x00ff0000
+
+	add	r1, sp, #S_R0			@ pointer to regs
 	bl	trace_real_syscall_entry
 	add	r1, sp, #S_R0			@ pointer to regs
 	ldmia	r1, {r0 - r3}			@ have to reload r0 - r3
Index: linux-2.6.15/include/asm-arm/ltt.h
===================================================================
--- linux-2.6.15.orig/include/asm-arm/ltt.h	2006-02-08 17:46:40.000000000 +0000
+++ linux-2.6.15/include/asm-arm/ltt.h	2006-02-08 18:07:58.000000000 +0000
@@ -31,7 +31,7 @@
 	do {
 		seq = read_seqbegin(&xtime_lock);
 		ret = (jiffies_64 << LTTNG_LOGICAL_SHIFT) 
-							& (atomic_add_return(1, &lttng_logical_clock));
+							| (atomic_add_return(1, &lttng_logical_clock));
 	} while(read_seqretry(&xtime_lock, seq) && (--try) > 0);
 
 	if(try == 0)
Index: linux-2.6.15/include/asm-i386/ltt.h
===================================================================
--- linux-2.6.15.orig/include/asm-i386/ltt.h	2006-02-08 17:46:40.000000000 +0000
+++ linux-2.6.15/include/asm-i386/ltt.h	2006-02-08 18:10:46.000000000 +0000
@@ -42,7 +42,7 @@
 	do {
 		seq = read_seqbegin(&xtime_lock);
 		ret = (jiffies_64 << LTTNG_LOGICAL_SHIFT) 
-							& (atomic_add_return(1, &lttng_logical_clock));
+							| (atomic_add_return(1, &lttng_logical_clock));
 	} while(read_seqretry(&xtime_lock, seq) && (--try) > 0);
 
 	if(try == 0)
Index: linux-2.6.15/include/asm-ppc/ltt.h
===================================================================
--- linux-2.6.15.orig/include/asm-ppc/ltt.h	2006-02-08 17:46:40.000000000 +0000
+++ linux-2.6.15/include/asm-ppc/ltt.h	2006-02-08 18:10:41.000000000 +0000
@@ -47,7 +47,7 @@
 	do {
 		seq = read_seqbegin(&xtime_lock);
 		ret = (jiffies_64 << LTTNG_LOGICAL_SHIFT) 
-							& (atomic_add_return(1, &lttng_logical_clock));
+							| (atomic_add_return(1, &lttng_logical_clock));
 	} while(read_seqretry(&xtime_lock, seq) && (--try) > 0);
 
 	if(try == 0)
Index: linux-2.6.15/include/asm-arm/ltt/ltt-facility-id-kernel_arch_arm.h
===================================================================
--- linux-2.6.15.orig/include/asm-arm/ltt/ltt-facility-id-kernel_arch_arm.h	2006-02-08 17:46:40.000000000 +0000
+++ linux-2.6.15/include/asm-arm/ltt/ltt-facility-id-kernel_arch_arm.h	2006-02-08 21:10:03.000000000 +0000
@@ -6,7 +6,7 @@
 
 /****  facility handle  ****/
 
-extern ltt_facility_t ltt_facility_kernel_arch_62B14C1E;
+extern ltt_facility_t ltt_facility_kernel_arch_8E8193AC;
 extern ltt_facility_t ltt_facility_kernel_arch;
 
 
Index: linux-2.6.15/ltt/ltt-facility-loader-kernel_arch_arm.h
===================================================================
--- linux-2.6.15.orig/ltt/ltt-facility-loader-kernel_arch_arm.h	2006-02-08 21:10:03.000000000 +0000
+++ linux-2.6.15/ltt/ltt-facility-loader-kernel_arch_arm.h	2006-02-08 22:10:13.000000000 +0000
@@ -7,11 +7,11 @@
 #include <asm/ltt/ltt-facility-id-kernel_arch_arm.h>
 
 ltt_facility_t	ltt_facility_kernel_arch;
-ltt_facility_t	ltt_facility_kernel_arch_8E8193AC;
+ltt_facility_t	ltt_facility_kernel_arch_62B14C1E;
 
 #define LTT_FACILITY_SYMBOL							ltt_facility_kernel_arch
-#define LTT_FACILITY_CHECKSUM_SYMBOL		ltt_facility_kernel_arch_8E8193AC
-#define LTT_FACILITY_CHECKSUM						0x8E8193AC
+#define LTT_FACILITY_CHECKSUM_SYMBOL		ltt_facility_kernel_arch_62B14C1E
+#define LTT_FACILITY_CHECKSUM						0x62B14C1E
 #define LTT_FACILITY_NAME								"kernel_arch"
 #define LTT_FACILITY_NUM_EVENTS					facility_kernel_arch_num_events
 

