From mboxrd@z Thu Jan 1 00:00:00 1970 Date: Mon, 4 Feb 2019 15:28:29 +0100 From: Borislav Petkov Subject: Re: [PATCH v2 03/20] x86/mm: temporary mm struct Message-ID: <20190204142829.GD29639@zn.tnic> References: <20190129003422.9328-1-rick.p.edgecombe@intel.com> <20190129003422.9328-4-rick.p.edgecombe@intel.com> <20190131112948.GE6749@zn.tnic> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: To: Nadav Amit Cc: Rick Edgecombe , Andy Lutomirski , Ingo Molnar , LKML , X86 ML , "H. Peter Anvin" , Thomas Gleixner , Dave Hansen , Peter Zijlstra , Damian Tometzki , linux-integrity , LSM List , Andrew Morton , Kernel Hardening , Linux-MM , Will Deacon , Ard Biesheuvel , Kristen Carlson Accardi , "Dock, Deneen T" , Kees Cook , Dave Hansen List-ID: On Thu, Jan 31, 2019 at 10:19:54PM +0000, Nadav Amit wrote: > Having a different struct can prevent the misuse of using mm_structs in > unuse_temporary_mm() that were not “used” using use_temporary_mm. The > typedef, I presume, can deter users from starting to play with the internal > “private” fields. Ok, makes sense. > > That prev.prev below looks unnecessary, instead of just using prev. > > > >> + struct mm_struct *prev; > > > > Why "prev”? > > This is obviously the previous active mm. Feel free to suggest an > alternative name. Well, when I look at the typedef I'm wondering why is it called "prev" but I guess this is to mean that it will be saving the previously used mm, so ack. Thx. -- Regards/Gruss, Boris. Good mailing practices for 400: avoid top-posting and trim the reply.