public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* Re: [bug] set_pgdir can skip mm's
@ 2000-11-24 13:07 V Ganesh
  0 siblings, 0 replies; 2+ messages in thread
From: V Ganesh @ 2000-11-24 13:07 UTC (permalink / raw)
  To: linux-kernel

> From ganesh Fri Nov 24 18:08:15 2000

[ set_pgdir() blah blah blah ]

damn. I was looking at test9 and as usual after shooting my mouth off on l-k
I go look at test11 and find it's fixed there, at least in i386, thanks to
the vmalloc_fault: stuff in do_page_fault. but a lot of other architectures
still use the old method.

ganesh
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

^ permalink raw reply	[flat|nested] 2+ messages in thread
* [bug] set_pgdir can skip mm's
@ 2000-11-24 12:38 V Ganesh
  0 siblings, 0 replies; 2+ messages in thread
From: V Ganesh @ 2000-11-24 12:38 UTC (permalink / raw)
  To: linux-kernel

set_pgdir() needs to modify all active mm's to include the new entry.
what it really does is 
        for_each_task(p) {
                if (!p->mm)
                        continue;
                *pgd_offset(p->mm,address) = entry;
        }

however, there could be a lazy-tlb thread on another cpu whose active_mm
belongs to a process which is dead and gone, and hence won't be covered by the
above code. if this thread then accesses an address covered by this entry, it
would fault.
ideally, we ought to loop through a list of all mm's rather than processes.
but since we don't have such a list, an easier solution is to use p->active_mm
rather than p->mm. this can cause multiple updates of the same pgd, but
the number of such unnecessary extra updates is bound by the number of CPUs.

ganesh
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
Please read the FAQ at http://www.tux.org/lkml/

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2000-11-24 14:19 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2000-11-24 13:07 [bug] set_pgdir can skip mm's V Ganesh
  -- strict thread matches above, loose matches on Subject: below --
2000-11-24 12:38 V Ganesh

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox