aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEric Andersen <andersen@codepoet.org>2000-07-06 17:05:33 +0000
committerEric Andersen <andersen@codepoet.org>2000-07-06 17:05:33 +0000
commit3cfa9ec09cbd6742abee95526912269fd2e62a4c (patch)
tree03381b63f0a5b3664130945107394543da14b189
parent6f5e281479193fb2cf76a18017f3df9d9f1b8941 (diff)
downloadbusybox-w32-3cfa9ec09cbd6742abee95526912269fd2e62a4c.tar.gz
busybox-w32-3cfa9ec09cbd6742abee95526912269fd2e62a4c.tar.bz2
busybox-w32-3cfa9ec09cbd6742abee95526912269fd2e62a4c.zip
Reorganized signal names for better architecture support -- patch
thanks to simon wood <simon@mungewell.uklinux.net> -Erik
-rw-r--r--kill.c76
-rw-r--r--procps/kill.c76
2 files changed, 60 insertions, 92 deletions
diff --git a/kill.c b/kill.c
index 75277d962..a0b93be2b 100644
--- a/kill.c
+++ b/kill.c
@@ -58,76 +58,60 @@ struct signal_name {
58}; 58};
59 59
60const struct signal_name signames[] = { 60const struct signal_name signames[] = {
61 /* Everything, order not important */
61 {"HUP", SIGHUP}, 62 {"HUP", SIGHUP},
62 {"INT", SIGINT}, 63 {"INT", SIGINT},
63 {"QUIT", SIGQUIT}, 64 {"QUIT", SIGQUIT},
64 {"ILL", SIGILL}, 65 {"ILL", SIGILL},
65 {"TRAP", SIGTRAP}, 66 {"TRAP", SIGTRAP},
66 {"ABRT", SIGABRT}, 67 {"ABRT", SIGABRT},
67#ifndef __alpha__
68 {"IOT", SIGIOT},
69#endif
70#if defined(__sparc__) || defined(__alpha__)
71 {"EMT", SIGEMT},
72#else
73 {"BUS", SIGBUS},
74#endif
75 {"FPE", SIGFPE}, 68 {"FPE", SIGFPE},
76 {"KILL", SIGKILL}, 69 {"KILL", SIGKILL},
77#if defined(__sparc__) || defined(__alpha__)
78 {"BUS", SIGBUS},
79#else
80 {"USR1", SIGUSR1},
81#endif
82 {"SEGV", SIGSEGV}, 70 {"SEGV", SIGSEGV},
83#if defined(__sparc__) || defined(__alpha__)
84 {"SYS", SIGSYS},
85#else
86 {"USR2", SIGUSR2},
87#endif
88 {"PIPE", SIGPIPE}, 71 {"PIPE", SIGPIPE},
89 {"ALRM", SIGALRM}, 72 {"ALRM", SIGALRM},
90 {"TERM", SIGTERM}, 73 {"TERM", SIGTERM},
91#if defined(__sparc__) || defined(__alpha__) 74 {"BUS", SIGBUS},
92 {"URG", SIGURG}, 75 {"USR1", SIGUSR1},
76 {"USR2", SIGUSR2},
93 {"STOP", SIGSTOP}, 77 {"STOP", SIGSTOP},
94 {"TSTP", SIGTSTP},
95 {"CONT", SIGCONT}, 78 {"CONT", SIGCONT},
96 {"CHLD", SIGCHLD},
97 {"TTIN", SIGTTIN}, 79 {"TTIN", SIGTTIN},
98 {"TTOU", SIGTTOU}, 80 {"TTOU", SIGTTOU},
99 {"IO", SIGIO}, 81 {"IO", SIGIO},
100# ifndef __alpha__ 82 {"TSTP", SIGTSTP},
101 {"POLL", SIGIO}, 83 {"CHLD", SIGCHLD},
102# endif
103 {"XCPU", SIGXCPU}, 84 {"XCPU", SIGXCPU},
104 {"XFSZ", SIGXFSZ}, 85 {"XFSZ", SIGXFSZ},
105 {"VTALRM", SIGVTALRM},
106 {"PROF", SIGPROF}, 86 {"PROF", SIGPROF},
107 {"WINCH", SIGWINCH}, 87 {"WINCH", SIGWINCH},
108# ifdef __alpha__
109 {"INFO", SIGINFO},
110# else
111 {"LOST", SIGLOST},
112# endif
113 {"USR1", SIGUSR1},
114 {"USR2", SIGUSR2},
115#else
116 {"STKFLT", SIGSTKFLT},
117 {"CHLD", SIGCHLD},
118 {"CONT", SIGCONT},
119 {"STOP", SIGSTOP},
120 {"TSTP", SIGTSTP},
121 {"TTIN", SIGTTIN},
122 {"TTOU", SIGTTOU},
123 {"URG", SIGURG}, 88 {"URG", SIGURG},
124 {"XCPU", SIGXCPU},
125 {"XFSZ", SIGXFSZ},
126 {"VTALRM", SIGVTALRM}, 89 {"VTALRM", SIGVTALRM},
127 {"PROF", SIGPROF}, 90#ifndef __alpha__
128 {"WINCH", SIGWINCH}, 91 /* everything except alpha */
129 {"IO", SIGIO}, 92 {"IOT", SIGIOT},
130 {"POLL", SIGPOLL}, 93 {"POLL", SIGPOLL},
94#endif
95#if defined(__sparc__) || defined(__alpha__) || defined(__mips__)
96 /* everthing except intel */
97 {"EMT", SIGEMT},
98 {"SYS", SIGSYS},
99# ifdef __alpha__
100 /* alpha only */
101 {"LOST", SIGLOST},
102#endif
103#ifdef __sparc__
104 /* space only */
105 {"INFO", SIGINFO},
106#endif
107#ifdef __mips__
108 /* mips only */
109 {"CLD", SIGCLD},
110 {"PWR", SIGPWR},
111#endif
112#else
113 /* intel only */
114 {"STKFLT", SIGSTKFLT},
131 {"PWR", SIGPWR}, 115 {"PWR", SIGPWR},
132 {"UNUSED", SIGUNUSED}, 116 {"UNUSED", SIGUNUSED},
133#endif 117#endif
diff --git a/procps/kill.c b/procps/kill.c
index 75277d962..a0b93be2b 100644
--- a/procps/kill.c
+++ b/procps/kill.c
@@ -58,76 +58,60 @@ struct signal_name {
58}; 58};
59 59
60const struct signal_name signames[] = { 60const struct signal_name signames[] = {
61 /* Everything, order not important */
61 {"HUP", SIGHUP}, 62 {"HUP", SIGHUP},
62 {"INT", SIGINT}, 63 {"INT", SIGINT},
63 {"QUIT", SIGQUIT}, 64 {"QUIT", SIGQUIT},
64 {"ILL", SIGILL}, 65 {"ILL", SIGILL},
65 {"TRAP", SIGTRAP}, 66 {"TRAP", SIGTRAP},
66 {"ABRT", SIGABRT}, 67 {"ABRT", SIGABRT},
67#ifndef __alpha__
68 {"IOT", SIGIOT},
69#endif
70#if defined(__sparc__) || defined(__alpha__)
71 {"EMT", SIGEMT},
72#else
73 {"BUS", SIGBUS},
74#endif
75 {"FPE", SIGFPE}, 68 {"FPE", SIGFPE},
76 {"KILL", SIGKILL}, 69 {"KILL", SIGKILL},
77#if defined(__sparc__) || defined(__alpha__)
78 {"BUS", SIGBUS},
79#else
80 {"USR1", SIGUSR1},
81#endif
82 {"SEGV", SIGSEGV}, 70 {"SEGV", SIGSEGV},
83#if defined(__sparc__) || defined(__alpha__)
84 {"SYS", SIGSYS},
85#else
86 {"USR2", SIGUSR2},
87#endif
88 {"PIPE", SIGPIPE}, 71 {"PIPE", SIGPIPE},
89 {"ALRM", SIGALRM}, 72 {"ALRM", SIGALRM},
90 {"TERM", SIGTERM}, 73 {"TERM", SIGTERM},
91#if defined(__sparc__) || defined(__alpha__) 74 {"BUS", SIGBUS},
92 {"URG", SIGURG}, 75 {"USR1", SIGUSR1},
76 {"USR2", SIGUSR2},
93 {"STOP", SIGSTOP}, 77 {"STOP", SIGSTOP},
94 {"TSTP", SIGTSTP},
95 {"CONT", SIGCONT}, 78 {"CONT", SIGCONT},
96 {"CHLD", SIGCHLD},
97 {"TTIN", SIGTTIN}, 79 {"TTIN", SIGTTIN},
98 {"TTOU", SIGTTOU}, 80 {"TTOU", SIGTTOU},
99 {"IO", SIGIO}, 81 {"IO", SIGIO},
100# ifndef __alpha__ 82 {"TSTP", SIGTSTP},
101 {"POLL", SIGIO}, 83 {"CHLD", SIGCHLD},
102# endif
103 {"XCPU", SIGXCPU}, 84 {"XCPU", SIGXCPU},
104 {"XFSZ", SIGXFSZ}, 85 {"XFSZ", SIGXFSZ},
105 {"VTALRM", SIGVTALRM},
106 {"PROF", SIGPROF}, 86 {"PROF", SIGPROF},
107 {"WINCH", SIGWINCH}, 87 {"WINCH", SIGWINCH},
108# ifdef __alpha__
109 {"INFO", SIGINFO},
110# else
111 {"LOST", SIGLOST},
112# endif
113 {"USR1", SIGUSR1},
114 {"USR2", SIGUSR2},
115#else
116 {"STKFLT", SIGSTKFLT},
117 {"CHLD", SIGCHLD},
118 {"CONT", SIGCONT},
119 {"STOP", SIGSTOP},
120 {"TSTP", SIGTSTP},
121 {"TTIN", SIGTTIN},
122 {"TTOU", SIGTTOU},
123 {"URG", SIGURG}, 88 {"URG", SIGURG},
124 {"XCPU", SIGXCPU},
125 {"XFSZ", SIGXFSZ},
126 {"VTALRM", SIGVTALRM}, 89 {"VTALRM", SIGVTALRM},
127 {"PROF", SIGPROF}, 90#ifndef __alpha__
128 {"WINCH", SIGWINCH}, 91 /* everything except alpha */
129 {"IO", SIGIO}, 92 {"IOT", SIGIOT},
130 {"POLL", SIGPOLL}, 93 {"POLL", SIGPOLL},
94#endif
95#if defined(__sparc__) || defined(__alpha__) || defined(__mips__)
96 /* everthing except intel */
97 {"EMT", SIGEMT},
98 {"SYS", SIGSYS},
99# ifdef __alpha__
100 /* alpha only */
101 {"LOST", SIGLOST},
102#endif
103#ifdef __sparc__
104 /* space only */
105 {"INFO", SIGINFO},
106#endif
107#ifdef __mips__
108 /* mips only */
109 {"CLD", SIGCLD},
110 {"PWR", SIGPWR},
111#endif
112#else
113 /* intel only */
114 {"STKFLT", SIGSTKFLT},
131 {"PWR", SIGPWR}, 115 {"PWR", SIGPWR},
132 {"UNUSED", SIGUNUSED}, 116 {"UNUSED", SIGUNUSED},
133#endif 117#endif