lkml.org 
[lkml]   [1998]   [Jul]   [19]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: current pointer question/suggestion
On Sat, Jul 18, 1998 at 08:45:05PM -0400, Benjamin C.R. LaHaise wrote:
> On Sat, 18 Jul 1998, Alexander Kjeldaas wrote:
> >
> > #define __current_virt_addr 0x01234567
> > #define current ((struct *task_struct)%esp & ~8191)
> > #define __current ((struct *task_struct)__current_virt_addr)
>
> And this just plain ain't gonna work on SMP (think of clone'd processes
> that shared the same memory mapping). As for whether or not the effoer
> worth it on UP is questionable.
>

I see. I guess the page would have to be per-cpu instead of
per-process. And then it gets a bit hairy - I'm starting to have
doubts myself. Oh well.. :-)

astor

--
Alexander Kjeldaas, Guardian Networks AS, Trondheim, Norway
http://www.guardian.no/

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.altern.org/andrebalsa/doc/lkml-faq.html

\
 
 \ /
  Last update: 2005-03-22 13:43    [W:0.340 / U:0.108 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site