diff -NurpP --minimal linux-2.4.24-vs1.23/Makefile linux-2.4.24-vs1.23-rev01/Makefile --- linux-2.4.24-vs1.23/Makefile Mon Jan 12 05:03:14 2004 +++ linux-2.4.24-vs1.23-rev01/Makefile Thu Jan 15 22:19:51 2004 @@ -1,7 +1,7 @@ VERSION = 2 PATCHLEVEL = 4 SUBLEVEL = 24 -EXTRAVERSION = -vs1.23 +EXTRAVERSION = -vs1.23-fix1 KERNELRELEASE=$(VERSION).$(PATCHLEVEL).$(SUBLEVEL)$(EXTRAVERSION) diff -NurpP --minimal linux-2.4.24-vs1.23/fs/proc/array.c linux-2.4.24-vs1.23-rev01/fs/proc/array.c --- linux-2.4.24-vs1.23/fs/proc/array.c Mon Jan 12 05:03:14 2004 +++ linux-2.4.24-vs1.23-rev01/fs/proc/array.c Thu Jan 15 22:19:51 2004 @@ -281,7 +281,6 @@ static inline char *task_cap(struct task cap_t(p->cap_bset)); } -extern rwlock_t ctx_ref_lock; int proc_pid_status(struct task_struct *task, char * buffer) { @@ -301,7 +300,6 @@ int proc_pid_status(struct task_struct * } buffer = task_sig(task, buffer); buffer = task_cap(task, buffer); - read_lock(&ctx_ref_lock); if (task->s_info) { int i; @@ -347,7 +345,6 @@ int proc_pid_status(struct task_struct * buffer += sprintf (buffer,"ipv4root: 0\n"); buffer += sprintf (buffer,"ipv4root_bcast: 0\n"); } - read_unlock(&ctx_ref_lock); #if defined(CONFIG_ARCH_S390) buffer = task_show_regs(task, buffer); #endif diff -NurpP --minimal linux-2.4.24-vs1.23/kernel/exit.c linux-2.4.24-vs1.23-rev01/kernel/exit.c --- linux-2.4.24-vs1.23/kernel/exit.c Mon Jan 12 05:03:14 2004 +++ linux-2.4.24-vs1.23-rev01/kernel/exit.c Thu Jan 15 22:19:51 2004 @@ -24,7 +24,6 @@ extern void sem_exit (void); extern struct task_struct *child_reaper; -extern rwlock_t ctx_ref_lock; int getrusage(struct task_struct *, int, struct rusage *); @@ -166,7 +165,6 @@ static inline void forget_original_paren struct task_struct *vchild_reaper = child_reaper; read_lock(&tasklist_lock); - read_lock(&ctx_ref_lock); if (father->s_info) { pid_t initpid = father->s_info->initpid; if ((initpid != 0) && (father->pid != initpid)) { @@ -176,7 +174,6 @@ static inline void forget_original_paren vchild_reaper = r; } } - read_unlock(&ctx_ref_lock); for_each_task(p) { if (p->p_opptr == father) { diff -NurpP --minimal linux-2.4.24-vs1.23/kernel/sched.c linux-2.4.24-vs1.23-rev01/kernel/sched.c --- linux-2.4.24-vs1.23/kernel/sched.c Mon Jan 12 05:03:14 2004 +++ linux-2.4.24-vs1.23-rev01/kernel/sched.c Thu Jan 15 22:19:51 2004 @@ -112,7 +112,6 @@ static union { struct kernel_stat kstat; extern struct task_struct *child_reaper; -extern rwlock_t ctx_ref_lock; #ifdef CONFIG_SMP @@ -167,14 +166,12 @@ static inline int goodness(struct task_s * Don't do any other calculations if the time slice is * over.. */ - read_lock(&ctx_ref_lock); if (p->s_info && (p->s_info->flags & VX_INFO_SCHED)) { weight = atomic_read(&p->s_info->ticks) / atomic_read(&p->s_info->refcount); weight = (weight+p->counter) >> 1; } else weight = p->counter; - read_unlock(&ctx_ref_lock); if (!weight) goto out; @@ -631,7 +628,6 @@ repeat_schedule: Reset the s_info->ticks to the sum off all member processes p->counter */ - read_lock(&ctx_ref_lock); for_each_task(p) { if (p->s_info && (p->s_info->flags & VX_INFO_SCHED)) atomic_set(&p->s_info->ticks, 0); @@ -641,7 +637,6 @@ repeat_schedule: if (p->s_info && (p->s_info->flags & VX_INFO_SCHED)) atomic_add(p->counter, &p->s_info->ticks); } - read_unlock(&ctx_ref_lock); read_unlock(&tasklist_lock); spin_lock_irq(&runqueue_lock); goto repeat_schedule; diff -NurpP --minimal linux-2.4.24-vs1.23/kernel/vcontext.c linux-2.4.24-vs1.23-rev01/kernel/vcontext.c --- linux-2.4.24-vs1.23/kernel/vcontext.c Mon Jan 12 05:03:14 2004 +++ linux-2.4.24-vs1.23-rev01/kernel/vcontext.c Thu Jan 15 22:19:51 2004 @@ -152,17 +152,17 @@ static void vx_alloc_info(void) } } -rwlock_t ctx_ref_lock = RW_LOCK_UNLOCKED; +static spinlock_t ctx_ref_lock = SPIN_LOCK_UNLOCKED; /* * Increase the reference count on the context_info member of a task */ void vx_assign_info (struct task_struct *p) { - read_lock(&ctx_ref_lock); + spin_lock (&ctx_ref_lock); if (p->s_info) atomic_inc(&p->s_info->refcount); - read_unlock(&ctx_ref_lock); + spin_unlock (&ctx_ref_lock); } /* @@ -171,17 +171,14 @@ void vx_assign_info (struct task_struct */ void vx_release_info (struct task_struct *p) { - write_lock(&ctx_ref_lock); + spin_lock (&ctx_ref_lock); if (p->s_info) { if (atomic_dec_and_test(&p->s_info->refcount)) { - struct context_info *s_info; - - s_info = p->s_info; + kfree(p->s_info); p->s_info = NULL; - kfree(s_info); } } - write_unlock(&ctx_ref_lock); + spin_unlock (&ctx_ref_lock); } /*