update scripts
[lttv.git] / scripts / lttng-split-script.sh
CommitLineData
ba899d3d 1#!/bin/sh
2# LTTng patch creation
3# Creates a -all patch, and split it.
4# Mathieu Desnoyers, october 2005
5#$1 is the version
6
7function wr () {
8
9 cat $1 >> $2
10
11}
12
13
d58172db 14NAME=patch-2.6.17-lttng-$1
ba899d3d 15ALL_NAME=$NAME-all.diff
16
17rm -fr tmppatch
18mkdir tmppatch
ba899d3d 19
20cd tmppatch
21
22cp ../$ALL_NAME .
23
24splitdiff -a -d $ALL_NAME
25
26
1a6c4b55 27rm $ALL_NAME
28
29for a in *; do
30 cp $a $a.tmp;
31 grep -v -e "^diff --git " -e "^new file mode " -e "^index " $a.tmp > $a
32 rm $a.tmp;
33done
34
35
11df8cd5 36
37FILE=../$NAME-debugfs.diff
38
39IN="?_fs_debugfs_inode.c"
40
41for a in $IN; do wr $a $FILE; done
42
43
44
ba899d3d 45FILE=../$NAME-instrumentation.diff
46
f7ebc2da 47IN="?_include_linux_kernel.h
48?_fs_buffer.c
33bd182c 49?_fs_compat.c
ba899d3d 50?_fs_exec.c
51?_fs_ioctl.c
52?_fs_open.c
53?_fs_read_write.c
54?_fs_select.c
ba899d3d 55?_ipc_msg.c
56?_ipc_sem.c
57?_ipc_shm.c
ba899d3d 58?_kernel_irq_handle.c
59?_kernel_itimer.c
60?_kernel_sched.c
61?_kernel_signal.c
62?_kernel_softirq.c
63?_kernel_timer.c
64?_kernel_module.c
75163c9d 65?_kernel_printk.c
ba899d3d 66?_mm_filemap.c
67?_mm_memory.c
68?_mm_page_alloc.c
69?_mm_page_io.c
70?_net_core_dev.c
71?_net_ipv4_devinet.c
72?_net_socket.c"
73
74for a in $IN; do wr $a $FILE; done
75
76
77FILE=../$NAME-instrumentation-arm.diff
78
79IN="?_arch_arm_kernel_entry-common.S
80?_arch_arm_kernel_calls.S
81?_arch_arm_kernel_irq.c
82?_arch_arm_kernel_process.c
83?_arch_arm_kernel_sys_arm.c
84?_arch_arm_kernel_time.c
85?_arch_arm_kernel_traps.c"
86
87for a in $IN; do wr $a $FILE; done
88
89
90FILE=../$NAME-instrumentation-i386.diff
91
92IN="?_arch_i386_kernel_entry.S
93?_arch_i386_kernel_Makefile
94?_arch_i386_kernel_ltt.c
95?_arch_i386_kernel_syscall_table.S
96?_arch_i386_kernel_process.c
97?_arch_i386_kernel_sys_i386.c
98?_arch_i386_kernel_traps.c
99?_arch_i386_kernel_time.c
100?_arch_i386_mm_fault.c
101?_include_asm-i386_unistd.h
102?_include_asm-i386_system.h"
103
104for a in $IN; do wr $a $FILE; done
105
106
107FILE=../$NAME-instrumentation-mips.diff
108
109IN="?_arch_mips_kernel_irq.c
f61b0dc2 110?_arch_mips_kernel_process.c
ba899d3d 111?_arch_mips_kernel_traps.c
112?_arch_mips_kernel_unaligned.c
f61b0dc2 113?_arch_mips_kernel_syscall.c
114?_arch_mips_kernel_scall32-o32.S
115?_arch_mips_kernel_scall64-64.S
116?_arch_mips_kernel_scall64-n32.S
117?_arch_mips_kernel_scall64-o32.S
ba899d3d 118?_arch_mips_mm_fault.c"
119for a in $IN; do wr $a $FILE; done
120
121
122FILE=../$NAME-instrumentation-ppc.diff
123IN="?_arch_ppc_kernel_entry.S
124?_arch_ppc_kernel_misc.S
ba899d3d 125?_arch_ppc_kernel_time.c
126?_arch_ppc_kernel_traps.c
127?_arch_ppc_mm_fault.c"
128for a in $IN; do wr $a $FILE; done
129
130
131FILE=../$NAME-instrumentation-powerpc.diff
446a6afb 132IN="?_arch_powerpc_kernel_entry_32.S
8084c788 133?_arch_powerpc_kernel_entry_64.S
134?_arch_powerpc_kernel_misc_32.S
135?_arch_powerpc_kernel_misc_64.S
136?_arch_powerpc_kernel_process.c
137?_arch_powerpc_kernel_systbl.S
138?_arch_powerpc_kernel_time.c
139?_arch_powerpc_kernel_traps.c
140?_arch_powerpc_mm_fault.c
3aa70304 141?_arch_powerpc_kernel_irq.c
142?_arch_powerpc_kernel_ppc_ksyms.c
8084c788 143?_arch_powerpc_kernel_syscalls.c
144?_include_asm-powerpc_unistd.h"
ba899d3d 145
146for a in $IN; do wr $a $FILE; done
147
b221a631 148FILE=../$NAME-instrumentation-x86_64.diff
149
150IN="?_arch_x86_64_ia32_ia32entry.S
151?_arch_x86_64_ia32_ipc32.c
b221a631 152?_arch_x86_64_kernel_entry.S
153?_arch_x86_64_kernel_ltt.c
154?_arch_x86_64_kernel_Makefile
155?_arch_x86_64_kernel_time.c
156?_arch_x86_64_kernel_traps.c
157?_arch_x86_64_mm_fault.c
158?_include_asm-x86_64_ia32_unistd.h
159?_include_asm-x86_64_unistd.h
160?_include_asm-x86_64_system.h"
161
162for a in $IN; do wr $a $FILE; done
163
164
ba899d3d 165
166FILE=../$NAME-instrumentation-s390.diff
167IN="?_arch_s390_kernel_entry.S
168?_arch_s390_kernel_sys_s390.c
169?_arch_s390_kernel_traps.c
170?_arch_s390_mm_fault.c"
171for a in $IN; do wr $a $FILE; done
172
173
174FILE=../$NAME-instrumentation-sh.diff
175IN="?_arch_sh_kernel_irq.c
176?_arch_sh_kernel_process.c
177?_arch_sh_kernel_sys_sh.c
178?_arch_sh_kernel_traps.c
179?_arch_sh_mm_fault.c"
180for a in $IN; do wr $a $FILE; done
181
182
183
184FILE=../$NAME-facilities-headers.diff
185
186IN="?_include_linux_ltt_ltt-facility-core.h
187?_include_linux_ltt_ltt-facility-fs.h
c2bf1ace 188?_include_linux_ltt_ltt-facility-fs_data.h
189?_include_linux_ltt_ltt-facility-custom-fs_data.h
0bdf8e98 190?_include_linux_ltt_ltt-facility-custom-stack.h
ba899d3d 191?_include_linux_ltt_ltt-facility-id-core.h
192?_include_linux_ltt_ltt-facility-id-fs.h
c2bf1ace 193?_include_linux_ltt_ltt-facility-id-fs_data.h
ba899d3d 194?_include_linux_ltt_ltt-facility-id-ipc.h
195?_include_linux_ltt_ltt-facility-id-kernel.h
196?_include_linux_ltt_ltt-facility-id-locking.h
197?_include_linux_ltt_ltt-facility-id-memory.h
198?_include_linux_ltt_ltt-facility-id-network.h
199?_include_linux_ltt_ltt-facility-id-network_ip_interface.h
200?_include_linux_ltt_ltt-facility-id-process.h
201?_include_linux_ltt_ltt-facility-id-socket.h
0bdf8e98 202?_include_linux_ltt_ltt-facility-id-stack.h
ba899d3d 203?_include_linux_ltt_ltt-facility-id-statedump.h
204?_include_linux_ltt_ltt-facility-id-timer.h
205?_include_linux_ltt_ltt-facility-ipc.h
206?_include_linux_ltt_ltt-facility-kernel.h
207?_include_linux_ltt_ltt-facility-locking.h
208?_include_linux_ltt_ltt-facility-memory.h
209?_include_linux_ltt_ltt-facility-network.h
210?_include_linux_ltt_ltt-facility-network_ip_interface.h
211?_include_linux_ltt_ltt-facility-process.h
212?_include_linux_ltt_ltt-facility-socket.h
0bdf8e98 213?_include_linux_ltt_ltt-facility-stack.h
ba899d3d 214?_include_linux_ltt_ltt-facility-statedump.h
215?_include_linux_ltt_ltt-facility-timer.h
216?_include_asm-i386_ltt_ltt-facility-id-kernel_arch_i386.h
217?_include_asm-i386_ltt_ltt-facility-kernel_arch_i386.h
0bdf8e98 218?_include_asm-i386_ltt_ltt-facility-custom-stack.h
ba899d3d 219?_include_asm-i386_ltt_ltt-facility-custom-locking.h
220?_include_asm-arm_ltt_ltt-facility-id-kernel_arch_arm.h
221?_include_asm-arm_ltt_ltt-facility-kernel_arch_arm.h
222?_include_asm-mips_ltt_ltt-facility-id-kernel_arch_mips.h
8084c788 223?_include_asm-mips_ltt_ltt-facility-kernel_arch_mips.h
224?_include_asm-powerpc_ltt_ltt-facility-id-kernel_arch_powerpc.h
f748c06f 225?_include_asm-powerpc_ltt_ltt-facility-kernel_arch_powerpc.h
226?_include_asm-ppc_ltt_ltt-facility-id-kernel_arch_ppc.h
b221a631 227?_include_asm-ppc_ltt_ltt-facility-kernel_arch_ppc.h
228?_include_asm-x86_64_ltt_ltt-facility-id-kernel_arch_x86_64.h
229?_include_asm-x86_64_ltt_ltt-facility-kernel_arch_x86_64.h
0bdf8e98 230?_include_asm-x86_64_ltt_ltt-facility-custom-stack.h
b221a631 231?_include_asm-x86_64_ltt_ltt-facility-custom-locking.h"
ba899d3d 232
233for a in $IN; do wr $a $FILE; done
234
235
236FILE=../$NAME-facilities-loader.diff
237
238IN="?_ltt_Makefile
239?_ltt_ltt-facility-loader-core.c
240?_ltt_ltt-facility-loader-core.h
241?_ltt_ltt-facility-loader-fs.c
242?_ltt_ltt-facility-loader-fs.h
c2bf1ace 243?_ltt_ltt-facility-loader-fs_data.c
244?_ltt_ltt-facility-loader-fs_data.h
ba899d3d 245?_ltt_ltt-facility-loader-ipc.c
246?_ltt_ltt-facility-loader-ipc.h
247?_ltt_ltt-facility-loader-kernel.c
248?_ltt_ltt-facility-loader-kernel.h
249?_ltt_ltt-facility-loader-locking.c
250?_ltt_ltt-facility-loader-locking.h
251?_ltt_ltt-facility-loader-memory.c
252?_ltt_ltt-facility-loader-memory.h
253?_ltt_ltt-facility-loader-network.c
254?_ltt_ltt-facility-loader-network.h
255?_ltt_ltt-facility-loader-network_ip_interface.c
256?_ltt_ltt-facility-loader-network_ip_interface.h
257?_ltt_ltt-facility-loader-process.c
258?_ltt_ltt-facility-loader-process.h
259?_ltt_ltt-facility-loader-socket.c
260?_ltt_ltt-facility-loader-socket.h
0bdf8e98 261?_ltt_ltt-facility-loader-stack.c
262?_ltt_ltt-facility-loader-stack.h
ba899d3d 263?_ltt_ltt-facility-loader-statedump.c
264?_ltt_ltt-facility-loader-statedump.h
265?_ltt_ltt-facility-loader-timer.c
266?_ltt_ltt-facility-loader-timer.h
267?_ltt_ltt-facility-loader-kernel_arch_i386.c
268?_ltt_ltt-facility-loader-kernel_arch_i386.h
ba899d3d 269?_ltt_ltt-facility-loader-kernel_arch_arm.c
270?_ltt_ltt-facility-loader-kernel_arch_arm.h
271?_ltt_ltt-facility-loader-kernel_arch_mips.c
8084c788 272?_ltt_ltt-facility-loader-kernel_arch_mips.h
273?_ltt_ltt-facility-loader-kernel_arch_powerpc.c
f748c06f 274?_ltt_ltt-facility-loader-kernel_arch_powerpc.h
275?_ltt_ltt-facility-loader-kernel_arch_ppc.c
b221a631 276?_ltt_ltt-facility-loader-kernel_arch_ppc.h
277?_ltt_ltt-facility-loader-kernel_arch_x86_64.c
278?_ltt_ltt-facility-loader-kernel_arch_x86_64.h"
ba899d3d 279
280
281for a in $IN; do wr $a $FILE; done
282
283FILE=../$NAME-facilities.diff
284
285IN="?_include_linux_ltt-facilities.h
286?_kernel_ltt-facilities.c"
287
288for a in $IN; do wr $a $FILE; done
289
ba899d3d 290
291FILE=../$NAME-build.diff
292
293IN="?_Makefile"
294
295for a in $IN; do wr $a $FILE; done
296
297FILE=../$NAME-core.diff
298
299IN="?_MAINTAINERS
ba899d3d 300?_include_asm-alpha_ltt.h
301?_include_asm-arm26_ltt.h
302?_include_asm-arm_ltt.h
303?_include_asm-cris_ltt.h
304?_include_asm-frv_ltt.h
305?_include_asm-generic_ltt.h
306?_include_asm-h8300_ltt.h
307?_include_asm-i386_ltt.h
308?_include_asm-ia64_ltt.h
309?_include_asm-m32r_ltt.h
310?_include_asm-m68k_ltt.h
311?_include_asm-m68knommu_ltt.h
312?_include_asm-mips_ltt.h
313?_include_asm-mips_mipsregs.h
314?_include_asm-mips_timex.h
315?_arch_mips_kernel_time.c
316?_include_asm-parisc_ltt.h
669f30eb 317?_include_asm-powerpc_ltt.h
ba899d3d 318?_include_asm-ppc_ltt.h
319?_include_asm-s390_ltt.h
320?_include_asm-sh64_ltt.h
321?_include_asm-sh_ltt.h
322?_include_asm-sparc64_ltt.h
323?_include_asm-sparc_ltt.h
324?_include_asm-um_ltt.h
325?_include_asm-v850_ltt.h
326?_include_asm-x86_64_ltt.h
327?_include_linux_ltt-core.h
328?_include_linux_netlink.h
329?_include_linux_sched.h
330?_ltt_Kconfig
f61b0dc2 331?_ltt_ltt-core.c
11df8cd5 332?_Documentation_ioctl-number.txt
446a6afb 333?_ltt_ltt-relay.c
ba899d3d 334?_arch_i386_Kconfig
335?_arch_ppc_Kconfig
446a6afb 336?_arch_powerpc_Kconfig
ba899d3d 337?_arch_arm_Kconfig
338?_arch_mips_Kconfig
b221a631 339?_arch_x86_64_Kconfig
ba899d3d 340?_init_main.c
341?_kernel_Makefile
342?_kernel_ltt-base.c
ba899d3d 343?_kernel_ltt-heartbeat.c
344?_kernel_ltt-syscall.c
345?_kernel_sys_ni.c
346?_kernel_exit.c
347?_kernel_fork.c"
348
30ba2cb7 349for a in $IN; do wr $a $FILE; done
350
0f3b7d0d 351FILE=../$NAME-modules.diff
352
353IN="?_ltt_ltt-control.c
354?_ltt_ltt-control.h
355?_ltt_ltt-statedump.c"
356
ba899d3d 357for a in $IN; do wr $a $FILE; done
358
359cd ..
360
361rm $ALL_NAME
362tar cvfj $NAME.tar.bz2 $NAME-*
363
This page took 0.052117 seconds and 4 git commands to generate.