lists.openwall.net | lists / announce owl-users owl-dev john-users john-dev passwdqc-users yescrypt popa3d-users / oss-security kernel-hardening musl sabotage tlsify passwords / crypt-dev xvendor / Bugtraq Full-Disclosure linux-kernel linux-netdev linux-ext4 linux-hardening linux-cve-announce PHC | |
Open Source and information security mailing list archives
| ||
|
Date: Wed, 06 Dec 2006 17:36:02 -0800 From: Jeremy Fitzhardinge <jeremy@...p.org> To: Jeremy Fitzhardinge <jeremy@...p.org> CC: Zach Brown <zach.brown@...cle.com>, Badari Pulavarty <pbadari@...ibm.com>, Nick Piggin <nickpiggin@...oo.com.au>, Andrew Morton <akpm@...l.org>, Linux Kernel Mailing List <linux-kernel@...r.kernel.org>, Zachary Amsden <zach@...are.com>, Chris Wright <chrisw@...s-sol.org>, Rusty Russell <rusty@...tcorp.com.au>, Jeff Dike <jdike@...toit.com> Subject: Re: [PATCH RFC] use of activate_mm in fs/aio.c:use_mm()? Jeremy Fitzhardinge wrote: > I'm wondering if activate_mm() is the right thing to be using in > use_mm(); shouldn't this be switch_mm()? > > On normal x86, they're synonymous, but for the Xen patches I'm adding a > hook which assumes that activate_mm is only used the first time a new mm > is used after creation (I have another hook for dealing with dup_mm). I > think this use of activate_mm() is the only place where it could be used > a second time on an mm. > > From a quick look at the other architectures I think this is OK (most > simply implement one in terms of the other), but some are doing some > subtly different stuff between the two. > > Thanks, > J > > > Er, lets try that again: diff -r 455b71ed4525 fs/aio.c --- a/fs/aio.c Wed Dec 06 13:16:42 2006 -0800 +++ b/fs/aio.c Wed Dec 06 17:17:43 2006 -0800 @@ -588,7 +588,7 @@ static void use_mm(struct mm_struct *mm) * Note that on UML this *requires* PF_BORROWED_MM to be set, otherwise * it won't work. Update it accordingly if you change it here */ - activate_mm(active_mm, mm); + switch_mm(active_mm, mm, tsk); task_unlock(tsk); mmdrop(active_mm); - To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@...r.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists