Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753589AbdC2RAA (ORCPT ); Wed, 29 Mar 2017 13:00:00 -0400 Received: from mail-vk0-f54.google.com ([209.85.213.54]:36383 "EHLO mail-vk0-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752782AbdC2Q77 (ORCPT ); Wed, 29 Mar 2017 12:59:59 -0400 MIME-Version: 1.0 In-Reply-To: <20170329150535.GA22925@redhat.com> References: <20170328145413.GA3164@redhat.com> <20170328145432.GA3163@redhat.com> <20170328162736.GA3983@redhat.com> <20170329150535.GA22925@redhat.com> From: Andy Lutomirski Date: Wed, 29 Mar 2017 09:59:36 -0700 Message-ID: Subject: Re: [PATCH 1/1] get_nr_restart_syscall() should return __NR_ia32_restart_syscall if __USER32_CS To: Oleg Nesterov Cc: Andy Lutomirski , Andrew Morton , Linus Torvalds , Denys Vlasenko , "H. Peter Anvin" , Ingo Molnar , Jan Kratochvil , Pedro Alves , Thomas Gleixner , X86 ML , "linux-kernel@vger.kernel.org" Content-Type: text/plain; charset=UTF-8 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 756 Lines: 23 On Wed, Mar 29, 2017 at 8:05 AM, Oleg Nesterov wrote: > On 03/28, Oleg Nesterov wrote: >> >> On 03/28, Andy Lutomirski wrote: >> > >> > How about we store the syscall arch to be restored in task_struct >> > along with restart_block? >> >> Yes, perhaps we will have to finally do this. Not really nice too. > > OK, how about the hack below? > > I do not want to a new member into task_struct/restart_block, so the > patch below adds a sticky TS_COMPAT bit which logically is a member > of "struct restart_block". Okay, but I'd much rather we just added a helper that's called in the few places that actually write to restart_block. Or we just add the new syscall nr and see what breaks. The answer could well be nothing at all. --Andy