From mboxrd@z Thu Jan 1 00:00:00 1970 Return-path: Date: Tue, 18 May 2021 07:40:29 +0100 From: Christoph Hellwig Subject: Re: [PATCH v3 1/4] kexec: simplify compat_sys_kexec_load Message-ID: References: <20210517203343.3941777-1-arnd@kernel.org> <20210517203343.3941777-2-arnd@kernel.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "kexec" Errors-To: kexec-bounces+dwmw2=infradead.org@lists.infradead.org To: "Eric W. Biederman" Cc: Arnd Bergmann , linux-arch@vger.kernel.org, Arnd Bergmann , Christoph Hellwig , Alexander Viro , Andrew Morton , Borislav Petkov , Brian Gerst , Ingo Molnar , "H. Peter Anvin" , Thomas Gleixner , Linux ARM , linux-kernel@vger.kernel.org, Linux-MM , kexec@lists.infradead.org On Mon, May 17, 2021 at 10:57:24PM -0500, Eric W. Biederman wrote: > We open ourselves up to bugs whenever we lie to the type system. > > Skimming through the code it looks like it should be possible > to not need the in_compat_syscall and the casts to the wrong > type by changing the order of the code a little bit. What kind of bug do you expect? We must only copy from user addresses once anyway. I've never seen bugs due the use of in_compat_syscall, but plenty due to cruft code trying to avoid it. _______________________________________________ kexec mailing list kexec@lists.infradead.org http://lists.infradead.org/mailman/listinfo/kexec