aboutsummaryrefslogtreecommitdiffstats
path: root/arch/frv/kernel
diff options
context:
space:
mode:
authorDavid Howells <dhowells@redhat.com>2009-06-11 08:05:09 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2009-06-11 12:01:26 -0400
commitaa1913c0214a53568731617c0afbbfa3f59513fb (patch)
tree5ae7c12bd1cf1c47b1742b023be25e7511da4dda /arch/frv/kernel
parentdb5c444eeb781788a0db36a2682b2417cf71f764 (diff)
FRV: Remove in-kernel strace code
Remove in-kernel strace code from the FRV arch as it's not really needed any more. Signed-off-by: David Howells <dhowells@redhat.com> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/frv/kernel')
-rw-r--r--arch/frv/kernel/ptrace.c379
1 files changed, 0 insertions, 379 deletions
diff --git a/arch/frv/kernel/ptrace.c b/arch/frv/kernel/ptrace.c
index 5e7d401d21e7..6b15e5da311a 100644
--- a/arch/frv/kernel/ptrace.c
+++ b/arch/frv/kernel/ptrace.c
@@ -306,387 +306,8 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data)
306 return ret; 306 return ret;
307} 307}
308 308
309int __nongprelbss kstrace;
310
311static const struct {
312 const char *name;
313 unsigned argmask;
314} __syscall_name_table[NR_syscalls] = {
315 [0] = { "restart_syscall" },
316 [1] = { "exit", 0x000001 },
317 [2] = { "fork", 0xffffff },
318 [3] = { "read", 0x000141 },
319 [4] = { "write", 0x000141 },
320 [5] = { "open", 0x000235 },
321 [6] = { "close", 0x000001 },
322 [7] = { "waitpid", 0x000141 },
323 [8] = { "creat", 0x000025 },
324 [9] = { "link", 0x000055 },
325 [10] = { "unlink", 0x000005 },
326 [11] = { "execve", 0x000445 },
327 [12] = { "chdir", 0x000005 },
328 [13] = { "time", 0x000004 },
329 [14] = { "mknod", 0x000325 },
330 [15] = { "chmod", 0x000025 },
331 [16] = { "lchown", 0x000025 },
332 [17] = { "break" },
333 [18] = { "oldstat", 0x000045 },
334 [19] = { "lseek", 0x000131 },
335 [20] = { "getpid", 0xffffff },
336 [21] = { "mount", 0x043555 },
337 [22] = { "umount", 0x000005 },
338 [23] = { "setuid", 0x000001 },
339 [24] = { "getuid", 0xffffff },
340 [25] = { "stime", 0x000004 },
341 [26] = { "ptrace", 0x004413 },
342 [27] = { "alarm", 0x000001 },
343 [28] = { "oldfstat", 0x000041 },
344 [29] = { "pause", 0xffffff },
345 [30] = { "utime", 0x000045 },
346 [31] = { "stty" },
347 [32] = { "gtty" },
348 [33] = { "access", 0x000025 },
349 [34] = { "nice", 0x000001 },
350 [35] = { "ftime" },
351 [36] = { "sync", 0xffffff },
352 [37] = { "kill", 0x000011 },
353 [38] = { "rename", 0x000055 },
354 [39] = { "mkdir", 0x000025 },
355 [40] = { "rmdir", 0x000005 },
356 [41] = { "dup", 0x000001 },
357 [42] = { "pipe", 0x000004 },
358 [43] = { "times", 0x000004 },
359 [44] = { "prof" },
360 [45] = { "brk", 0x000004 },
361 [46] = { "setgid", 0x000001 },
362 [47] = { "getgid", 0xffffff },
363 [48] = { "signal", 0x000041 },
364 [49] = { "geteuid", 0xffffff },
365 [50] = { "getegid", 0xffffff },
366 [51] = { "acct", 0x000005 },
367 [52] = { "umount2", 0x000035 },
368 [53] = { "lock" },
369 [54] = { "ioctl", 0x000331 },
370 [55] = { "fcntl", 0x000331 },
371 [56] = { "mpx" },
372 [57] = { "setpgid", 0x000011 },
373 [58] = { "ulimit" },
374 [60] = { "umask", 0x000002 },
375 [61] = { "chroot", 0x000005 },
376 [62] = { "ustat", 0x000043 },
377 [63] = { "dup2", 0x000011 },
378 [64] = { "getppid", 0xffffff },
379 [65] = { "getpgrp", 0xffffff },
380 [66] = { "setsid", 0xffffff },
381 [67] = { "sigaction" },
382 [68] = { "sgetmask" },
383 [69] = { "ssetmask" },
384 [70] = { "setreuid" },
385 [71] = { "setregid" },
386 [72] = { "sigsuspend" },
387 [73] = { "sigpending" },
388 [74] = { "sethostname" },
389 [75] = { "setrlimit" },
390 [76] = { "getrlimit" },
391 [77] = { "getrusage" },
392 [78] = { "gettimeofday" },
393 [79] = { "settimeofday" },
394 [80] = { "getgroups" },
395 [81] = { "setgroups" },
396 [82] = { "select" },
397 [83] = { "symlink" },
398 [84] = { "oldlstat" },
399 [85] = { "readlink" },
400 [86] = { "uselib" },
401 [87] = { "swapon" },
402 [88] = { "reboot" },
403 [89] = { "readdir" },
404 [91] = { "munmap", 0x000034 },
405 [92] = { "truncate" },
406 [93] = { "ftruncate" },
407 [94] = { "fchmod" },
408 [95] = { "fchown" },
409 [96] = { "getpriority" },
410 [97] = { "setpriority" },
411 [99] = { "statfs" },
412 [100] = { "fstatfs" },
413 [102] = { "socketcall" },
414 [103] = { "syslog" },
415 [104] = { "setitimer" },
416 [105] = { "getitimer" },
417 [106] = { "stat" },
418 [107] = { "lstat" },
419 [108] = { "fstat" },
420 [111] = { "vhangup" },
421 [114] = { "wait4" },
422 [115] = { "swapoff" },
423 [116] = { "sysinfo" },
424 [117] = { "ipc" },
425 [118] = { "fsync" },
426 [119] = { "sigreturn" },
427 [120] = { "clone" },
428 [121] = { "setdomainname" },
429 [122] = { "uname" },
430 [123] = { "modify_ldt" },
431 [123] = { "cacheflush" },
432 [124] = { "adjtimex" },
433 [125] = { "mprotect" },
434 [126] = { "sigprocmask" },
435 [127] = { "create_module" },
436 [128] = { "init_module" },
437 [129] = { "delete_module" },
438 [130] = { "get_kernel_syms" },
439 [131] = { "quotactl" },
440 [132] = { "getpgid" },
441 [133] = { "fchdir" },
442 [134] = { "bdflush" },
443 [135] = { "sysfs" },
444 [136] = { "personality" },
445 [137] = { "afs_syscall" },
446 [138] = { "setfsuid" },
447 [139] = { "setfsgid" },
448 [140] = { "_llseek", 0x014331 },
449 [141] = { "getdents" },
450 [142] = { "_newselect", 0x000141 },
451 [143] = { "flock" },
452 [144] = { "msync" },
453 [145] = { "readv" },
454 [146] = { "writev" },
455 [147] = { "getsid", 0x000001 },
456 [148] = { "fdatasync", 0x000001 },
457 [149] = { "_sysctl", 0x000004 },
458 [150] = { "mlock" },
459 [151] = { "munlock" },
460 [152] = { "mlockall" },
461 [153] = { "munlockall" },
462 [154] = { "sched_setparam" },
463 [155] = { "sched_getparam" },
464 [156] = { "sched_setscheduler" },
465 [157] = { "sched_getscheduler" },
466 [158] = { "sched_yield" },
467 [159] = { "sched_get_priority_max" },
468 [160] = { "sched_get_priority_min" },
469 [161] = { "sched_rr_get_interval" },
470 [162] = { "nanosleep", 0x000044 },
471 [163] = { "mremap" },
472 [164] = { "setresuid" },
473 [165] = { "getresuid" },
474 [166] = { "vm86" },
475 [167] = { "query_module" },
476 [168] = { "poll" },
477 [169] = { "nfsservctl" },
478 [170] = { "setresgid" },
479 [171] = { "getresgid" },
480 [172] = { "prctl", 0x333331 },
481 [173] = { "rt_sigreturn", 0xffffff },
482 [174] = { "rt_sigaction", 0x001441 },
483 [175] = { "rt_sigprocmask", 0x001441 },
484 [176] = { "rt_sigpending", 0x000014 },
485 [177] = { "rt_sigtimedwait", 0x001444 },
486 [178] = { "rt_sigqueueinfo", 0x000411 },
487 [179] = { "rt_sigsuspend", 0x000014 },
488 [180] = { "pread", 0x003341 },
489 [181] = { "pwrite", 0x003341 },
490 [182] = { "chown", 0x000115 },
491 [183] = { "getcwd" },
492 [184] = { "capget" },
493 [185] = { "capset" },
494 [186] = { "sigaltstack" },
495 [187] = { "sendfile" },
496 [188] = { "getpmsg" },
497 [189] = { "putpmsg" },
498 [190] = { "vfork", 0xffffff },
499 [191] = { "ugetrlimit" },
500 [192] = { "mmap2", 0x313314 },
501 [193] = { "truncate64" },
502 [194] = { "ftruncate64" },
503 [195] = { "stat64", 0x000045 },
504 [196] = { "lstat64", 0x000045 },
505 [197] = { "fstat64", 0x000041 },
506 [198] = { "lchown32" },
507 [199] = { "getuid32", 0xffffff },
508 [200] = { "getgid32", 0xffffff },
509 [201] = { "geteuid32", 0xffffff },
510 [202] = { "getegid32", 0xffffff },
511 [203] = { "setreuid32" },
512 [204] = { "setregid32" },
513 [205] = { "getgroups32" },
514 [206] = { "setgroups32" },
515 [207] = { "fchown32" },
516 [208] = { "setresuid32" },
517 [209] = { "getresuid32" },
518 [210] = { "setresgid32" },
519 [211] = { "getresgid32" },
520 [212] = { "chown32" },
521 [213] = { "setuid32" },
522 [214] = { "setgid32" },
523 [215] = { "setfsuid32" },
524 [216] = { "setfsgid32" },
525 [217] = { "pivot_root" },
526 [218] = { "mincore" },
527 [219] = { "madvise" },
528 [220] = { "getdents64" },
529 [221] = { "fcntl64" },
530 [223] = { "security" },
531 [224] = { "gettid" },
532 [225] = { "readahead" },
533 [226] = { "setxattr" },
534 [227] = { "lsetxattr" },
535 [228] = { "fsetxattr" },
536 [229] = { "getxattr" },
537 [230] = { "lgetxattr" },
538 [231] = { "fgetxattr" },
539 [232] = { "listxattr" },
540 [233] = { "llistxattr" },
541 [234] = { "flistxattr" },
542 [235] = { "removexattr" },
543 [236] = { "lremovexattr" },
544 [237] = { "fremovexattr" },
545 [238] = { "tkill" },
546 [239] = { "sendfile64" },
547 [240] = { "futex" },
548 [241] = { "sched_setaffinity" },
549 [242] = { "sched_getaffinity" },
550 [243] = { "set_thread_area" },
551 [244] = { "get_thread_area" },
552 [245] = { "io_setup" },
553 [246] = { "io_destroy" },
554 [247] = { "io_getevents" },
555 [248] = { "io_submit" },
556 [249] = { "io_cancel" },
557 [250] = { "fadvise64" },
558 [252] = { "exit_group", 0x000001 },
559 [253] = { "lookup_dcookie" },
560 [254] = { "epoll_create" },
561 [255] = { "epoll_ctl" },
562 [256] = { "epoll_wait" },
563 [257] = { "remap_file_pages" },
564 [258] = { "set_tid_address" },
565 [259] = { "timer_create" },
566 [260] = { "timer_settime" },
567 [261] = { "timer_gettime" },
568 [262] = { "timer_getoverrun" },
569 [263] = { "timer_delete" },
570 [264] = { "clock_settime" },
571 [265] = { "clock_gettime" },
572 [266] = { "clock_getres" },
573 [267] = { "clock_nanosleep" },
574 [268] = { "statfs64" },
575 [269] = { "fstatfs64" },
576 [270] = { "tgkill" },
577 [271] = { "utimes" },
578 [272] = { "fadvise64_64" },
579 [273] = { "vserver" },
580 [274] = { "mbind" },
581 [275] = { "get_mempolicy" },
582 [276] = { "set_mempolicy" },
583 [277] = { "mq_open" },
584 [278] = { "mq_unlink" },
585 [279] = { "mq_timedsend" },
586 [280] = { "mq_timedreceive" },
587 [281] = { "mq_notify" },
588 [282] = { "mq_getsetattr" },
589 [283] = { "sys_kexec_load" },
590};
591
592asmlinkage void do_syscall_trace(int leaving) 309asmlinkage void do_syscall_trace(int leaving)
593{ 310{
594#if 0
595 unsigned long *argp;
596 const char *name;
597 unsigned argmask;
598 char buffer[16];
599
600 if (!kstrace)
601 return;
602
603 if (!current->mm)
604 return;
605
606 if (__frame->gr7 == __NR_close)
607 return;
608
609#if 0
610 if (__frame->gr7 != __NR_mmap2 &&
611 __frame->gr7 != __NR_vfork &&
612 __frame->gr7 != __NR_execve &&
613 __frame->gr7 != __NR_exit)
614 return;
615#endif
616
617 argmask = 0;
618 name = NULL;
619 if (__frame->gr7 < NR_syscalls) {
620 name = __syscall_name_table[__frame->gr7].name;
621 argmask = __syscall_name_table[__frame->gr7].argmask;
622 }
623 if (!name) {
624 sprintf(buffer, "sys_%lx", __frame->gr7);
625 name = buffer;
626 }
627
628 if (!leaving) {
629 if (!argmask) {
630 printk(KERN_CRIT "[%d] %s(%lx,%lx,%lx,%lx,%lx,%lx)\n",
631 current->pid,
632 name,
633 __frame->gr8,
634 __frame->gr9,
635 __frame->gr10,
636 __frame->gr11,
637 __frame->gr12,
638 __frame->gr13);
639 }
640 else if (argmask == 0xffffff) {
641 printk(KERN_CRIT "[%d] %s()\n",
642 current->pid,
643 name);
644 }
645 else {
646 printk(KERN_CRIT "[%d] %s(",
647 current->pid,
648 name);
649
650 argp = &__frame->gr8;
651
652 do {
653 switch (argmask & 0xf) {
654 case 1:
655 printk("%ld", (long) *argp);
656 break;
657 case 2:
658 printk("%lo", *argp);
659 break;
660 case 3:
661 printk("%lx", *argp);
662 break;
663 case 4:
664 printk("%p", (void *) *argp);
665 break;
666 case 5:
667 printk("\"%s\"", (char *) *argp);
668 break;
669 }
670
671 argp++;
672 argmask >>= 4;
673 if (argmask)
674 printk(",");
675
676 } while (argmask);
677
678 printk(")\n");
679 }
680 }
681 else {
682 if ((int)__frame->gr8 > -4096 && (int)__frame->gr8 < 4096)
683 printk(KERN_CRIT "[%d] %s() = %ld\n", current->pid, name, __frame->gr8);
684 else
685 printk(KERN_CRIT "[%d] %s() = %lx\n", current->pid, name, __frame->gr8);
686 }
687 return;
688#endif
689
690 if (!test_thread_flag(TIF_SYSCALL_TRACE)) 311 if (!test_thread_flag(TIF_SYSCALL_TRACE))
691 return; 312 return;
692 313