From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kees Cook Subject: Re: [patch V3 07/13] x86/ptrace: Provide pt_regs helpers for entry/exit Date: Thu, 16 Jul 2020 13:57:54 -0700 Message-ID: <202007161357.70EF223F@keescook> References: <20200716182208.180916541@linutronix.de> <20200716185424.658427667@linutronix.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Content-Disposition: inline In-Reply-To: <20200716185424.658427667@linutronix.de> Sender: kvm-owner@vger.kernel.org To: Thomas Gleixner Cc: LKML , x86@kernel.org, linux-arch@vger.kernel.org, Will Deacon , Arnd Bergmann , Mark Rutland , Keno Fischer , Paolo Bonzini , kvm@vger.kernel.org List-Id: linux-arch.vger.kernel.org On Thu, Jul 16, 2020 at 08:22:15PM +0200, Thomas Gleixner wrote: > As a preparatory step for moving the syscall and interrupt entry/exit > handling into generic code, provide pt_regs helpers which allow to: > > - Retrieve the syscall number from pt_regs > - Retrieve the syscall return value from pt_regs > - Retrieve the interrupt state from pt_regs to check whether interrupts > are reenabled by return from interrupt/exception. > > Signed-off-by: Thomas Gleixner Reviewed-by: Kees Cook -- Kees Cook From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51344 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726231AbgGPU55 (ORCPT ); Thu, 16 Jul 2020 16:57:57 -0400 Received: from mail-pf1-x435.google.com (mail-pf1-x435.google.com [IPv6:2607:f8b0:4864:20::435]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 040ABC08C5CE for ; Thu, 16 Jul 2020 13:57:57 -0700 (PDT) Received: by mail-pf1-x435.google.com with SMTP id x72so4255342pfc.6 for ; Thu, 16 Jul 2020 13:57:56 -0700 (PDT) Date: Thu, 16 Jul 2020 13:57:54 -0700 From: Kees Cook Subject: Re: [patch V3 07/13] x86/ptrace: Provide pt_regs helpers for entry/exit Message-ID: <202007161357.70EF223F@keescook> References: <20200716182208.180916541@linutronix.de> <20200716185424.658427667@linutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200716185424.658427667@linutronix.de> Sender: linux-arch-owner@vger.kernel.org List-ID: To: Thomas Gleixner Cc: LKML , x86@kernel.org, linux-arch@vger.kernel.org, Will Deacon , Arnd Bergmann , Mark Rutland , Keno Fischer , Paolo Bonzini , kvm@vger.kernel.org Message-ID: <20200716205754.zJuPZUVlJ4ie-DLSP4ZBo-AkjXk-Qv5yUY37ewgZOKw@z> On Thu, Jul 16, 2020 at 08:22:15PM +0200, Thomas Gleixner wrote: > As a preparatory step for moving the syscall and interrupt entry/exit > handling into generic code, provide pt_regs helpers which allow to: > > - Retrieve the syscall number from pt_regs > - Retrieve the syscall return value from pt_regs > - Retrieve the interrupt state from pt_regs to check whether interrupts > are reenabled by return from interrupt/exception. > > Signed-off-by: Thomas Gleixner Reviewed-by: Kees Cook -- Kees Cook