summaryrefslogtreecommitdiffstats
path: root/kernel
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2000-06-16 23:00:36 +0000
committerRalf Baechle <ralf@linux-mips.org>2000-06-16 23:00:36 +0000
commit14dd2ec093cfabda3ae7efeeaf0e23c66ebaccc0 (patch)
tree9a9ce5cff6ef92faa6e07a82785b9a6d6838f7e4 /kernel
parent847290510f811c572cc2aa80c1f02a04721410b1 (diff)
Merge with 2.4.0-test1.
Diffstat (limited to 'kernel')
-rw-r--r--kernel/acct.c5
-rw-r--r--kernel/ksyms.c8
-rw-r--r--kernel/signal.c22
3 files changed, 18 insertions, 17 deletions
diff --git a/kernel/acct.c b/kernel/acct.c
index 86d776c5b..cef9aca85 100644
--- a/kernel/acct.c
+++ b/kernel/acct.c
@@ -71,7 +71,7 @@ void acct_timeout(unsigned long);
static volatile int acct_active;
static volatile int acct_needcheck;
static struct file *acct_file;
-static struct timer_list acct_timer = { NULL, NULL, 0, 0, acct_timeout };
+static struct timer_list acct_timer;
static int do_acct_process(long, struct file *);
/*
@@ -180,6 +180,9 @@ asmlinkage long sys_acct(const char *name)
acct_file = file;
acct_needcheck = 0;
acct_active = 1;
+ /* Its been deleted if it was used before so this is safe */
+ init_timer(&acct_timer);
+ acct_timer.function = acct_timeout;
acct_timer.expires = jiffies + ACCT_TIMEOUT*HZ;
add_timer(&acct_timer);
}
diff --git a/kernel/ksyms.c b/kernel/ksyms.c
index 4f60cf8dc..62426b761 100644
--- a/kernel/ksyms.c
+++ b/kernel/ksyms.c
@@ -52,11 +52,6 @@
#include <linux/kmod.h>
#endif
-#ifdef CONFIG_BLK_DEV_LVM_MODULE
-extern void (*lvm_hd_name_ptr) ( char*, int);
-EXPORT_SYMBOL(lvm_hd_name_ptr);
-#endif
-
extern int console_loglevel;
extern void set_device_ro(kdev_t dev,int flag);
#if !defined(CONFIG_NFSD) && defined(CONFIG_NFSD_MODULE)
@@ -116,7 +111,6 @@ EXPORT_SYMBOL(kmem_cache_free);
EXPORT_SYMBOL(kmalloc);
EXPORT_SYMBOL(kfree);
EXPORT_SYMBOL(kfree_s);
-EXPORT_SYMBOL(vmalloc);
EXPORT_SYMBOL(vfree);
EXPORT_SYMBOL(__vmalloc);
EXPORT_SYMBOL(mem_map);
@@ -249,7 +243,6 @@ EXPORT_SYMBOL(vfs_follow_link);
EXPORT_SYMBOL(page_readlink);
EXPORT_SYMBOL(page_follow_link);
EXPORT_SYMBOL(page_symlink_inode_operations);
-EXPORT_SYMBOL(block_fsync);
EXPORT_SYMBOL(block_symlink);
EXPORT_SYMBOL(vfs_readdir);
EXPORT_SYMBOL(dcache_readdir);
@@ -289,7 +282,6 @@ EXPORT_SYMBOL(bmap);
EXPORT_SYMBOL(sync_dev);
EXPORT_SYMBOL(devfs_register_partitions);
EXPORT_SYMBOL(blkdev_open);
-EXPORT_SYMBOL(blkdev_close);
EXPORT_SYMBOL(blkdev_get);
EXPORT_SYMBOL(blkdev_put);
EXPORT_SYMBOL(ioctl_by_bdev);
diff --git a/kernel/signal.c b/kernel/signal.c
index e37b7f399..3708a1b89 100644
--- a/kernel/signal.c
+++ b/kernel/signal.c
@@ -146,7 +146,7 @@ printk("SIG dequeue (%s:%d): %d ", current->comm, current->pid,
if (q) {
if ((*pp = q->next) == NULL)
current->sigqueue_tail = pp;
- *info = q->info;
+ copy_siginfo(info, &q->info);
kmem_cache_free(signal_queue_cachep,q);
atomic_dec(&nr_queued_signals);
@@ -372,7 +372,7 @@ printk("SIG queue (%s:%d): %d ", t->comm, t->pid, sig);
q->info.si_uid = 0;
break;
default:
- q->info = *info;
+ copy_siginfo(&q->info, info);
break;
}
} else if (sig >= SIGRTMIN && info && (unsigned long)info != 1
@@ -600,16 +600,18 @@ void
notify_parent(struct task_struct *tsk, int sig)
{
struct siginfo info;
- int why;
+ int why, status;
info.si_signo = sig;
info.si_errno = 0;
info.si_pid = tsk->pid;
+ info.si_uid = tsk->uid;
/* FIXME: find out whether or not this is supposed to be c*time. */
info.si_utime = HZ_TO_STD(tsk->times.tms_utime);
info.si_stime = HZ_TO_STD(tsk->times.tms_stime);
+ status = tsk->exit_code & 0x7f;
why = SI_KERNEL; /* shouldn't happen */
switch (tsk->state) {
case TASK_ZOMBIE:
@@ -617,12 +619,17 @@ notify_parent(struct task_struct *tsk, int sig)
why = CLD_DUMPED;
else if (tsk->exit_code & 0x7f)
why = CLD_KILLED;
- else
+ else {
why = CLD_EXITED;
+ status = tsk->exit_code >> 8;
+ }
break;
case TASK_STOPPED:
/* FIXME -- can we deduce CLD_TRAPPED or CLD_CONTINUED? */
- why = CLD_STOPPED;
+ if (tsk->flags & PF_PTRACED)
+ why = CLD_TRAPPED;
+ else
+ why = CLD_STOPPED;
break;
default:
@@ -631,6 +638,7 @@ notify_parent(struct task_struct *tsk, int sig)
break;
}
info.si_code = why;
+ info.si_status = status;
send_sig_info(sig, &info, tsk->p_pptr);
wake_up_interruptible(&tsk->p_pptr->wait_chldexit);
@@ -799,7 +807,7 @@ sys_rt_sigtimedwait(const sigset_t *uthese, siginfo_t *uinfo,
if (sig) {
ret = sig;
if (uinfo) {
- if (copy_to_user(uinfo, &info, sizeof(siginfo_t)))
+ if (copy_siginfo_to_user(uinfo, &info))
ret = -EFAULT;
}
} else {
@@ -816,8 +824,6 @@ sys_kill(int pid, int sig)
{
struct siginfo info;
- memset(&info, 0, sizeof(info));
-
info.si_signo = sig;
info.si_errno = 0;
info.si_code = SI_USER;