[SSI] openssi/kernel/cluster/arch/i386/vproc rproc_arch.c, 1.10, 1.11
Roger Tsang <[email protected]>
| Newsgroups | gmane.linux.cluster.ssic.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/ssic-linux/openssi/kernel/cluster/arch/i386/vproc
In directory fdv4jf1.ch3.sourceforge.com:/tmp/cvs-serv29491/cluster/arch/i386/vproc
Modified Files:
Tag: OPENSSI-FC
rproc_arch.c
Log Message:
Bug fixes and enhancements (see ChangeLog)
Index: rproc_arch.c
===================================================================
RCS file: /cvsroot/ssic-linux/openssi/kernel/cluster/arch/i386/vproc/rproc_arch.c,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -d -r1.10 -r1.11
--- rproc_arch.c 7 Aug 2007 03:06:07 -0000 1.10
+++ rproc_arch.c 24 Mar 2009 04:26:27 -0000 1.11
@@ -67,7 +67,7 @@
{
struct task_struct *t = current;
rvp_arch_data *ap = &fp->full_arch_data;
- int error;
+ int cpu, error;
(void)optype;
*regs = fp->full_regs;
@@ -78,7 +78,14 @@
}
load_LDT(&t->mm->context);
array_cpy(t->thread.tls_array, ap->arch_thread.tls_array);
- load_TLS(&t->thread, smp_processor_id());
+
+ /*
+ * We must not get preempted while modifying the TLS.
+ */
+ cpu = get_cpu();
+ load_TLS(&t->thread, cpu);
+ put_cpu();
+
if (ap->arch_thread.fs)
loadsegment(fs, ap->arch_thread.fs);
if (ap->arch_thread.gs)
------------------------------------------------------------------------------
Apps built with the Adobe(R) Flex(R) framework and Flex Builder(TM) are
powering Web 2.0 with engaging, cross-platform capabilities. Quickly and
easily build your RIAs with Flex Builder, the Eclipse(TM)based development
software that enables intelligent coding and step-through debugging.
Download the free 60 day trial. http://p.sf.net/sfu/www-adobe-com