Received: by 2002:a05:6a10:22f:0:0:0:0 with SMTP id 15csp457061pxk; Thu, 24 Sep 2020 09:35:57 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzjFh/xk3ArmYp4YhIsPgGOD+fdk2g9h/4MkiDxemtBc+2FW6nHb9c/Xr6JdRNAQ7QBY6RL X-Received: by 2002:aa7:c154:: with SMTP id r20mr756364edp.337.1600965357308; Thu, 24 Sep 2020 09:35:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1600965357; cv=none; d=google.com; s=arc-20160816; b=Abd2ZqinTHG+gkT2h9Ow15SVAVIdBsDXqnJWbE36ECay9sDxoMfMvNRX//LYx6sShM pGt0RS06UeA7+Bz5fCICWmqZWy2l7p79ilsXGIdgclxcfCx+pWZsLEQcN+ezhpxNXT8G 0BxD82zFUE1XW0qMJ9ToD1CMjdRK0pf4Zl+CUzaANJQRfKAlH9uSkBr0JDiSrTk3AwyT P6gFdgufkqAQ/IbtQe5bbbepPjWtL0Ny0Myi0CO70ztmwTiJLu0aM7Aagm0eFJyVk7YQ kt1C1R1fX4ahAxCWThJA44xzNetW4Pqbt7yexmBgQfi2ZAOkXWb/Fg9wZdUHjTMojyto B+Nw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=Wyic6RS8dnxuPl9A3GuZuq4BV1OsZd9ESbttja8eKEE=; b=mYUZtJUoiHRP+qJkZ8mv/Hz0T3kf7RoNkvL6iYiPNz52ublD6jc5NA7pisBdvMjwGV +PZiFtBuzvAeM5KUjeeGB2klveZi3Tb/FZV0Wot8bu4B5x4TvM8Q4ySFW7OOb+B+HxFM vJQyOS6iZdyEjxbsUjyXAEPz1ayaGsMZoH2PKZhMpendEBiihevrj1cpH0S5lg0EgxAy qI805qlFlLm3X0Wboav4kmhi4kAIPxoOh2pLJtMk6qThjE/4jm3lYymAKXk0SyiDtf1d KLMqjlGEtQl5/5iHcEeDq+N0MkVJxOHrfOW4QctfTmw0s4CYtpQqVbxCaQJPuSrHIA2J 4DJw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=l737tOpB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id a8si23442ejs.101.2020.09.24.09.35.32; Thu, 24 Sep 2020 09:35:57 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b=l737tOpB; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726919AbgIXQbg (ORCPT + 99 others); Thu, 24 Sep 2020 12:31:36 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48604 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726458AbgIXQbf (ORCPT ); Thu, 24 Sep 2020 12:31:35 -0400 Received: from mail.skyhub.de (mail.skyhub.de [IPv6:2a01:4f8:190:11c2::b:1457]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A35D2C0613CE; Thu, 24 Sep 2020 09:31:35 -0700 (PDT) Received: from zn.tnic (p200300ec2f0c950018c19313925c730a.dip0.t-ipconnect.de [IPv6:2003:ec:2f0c:9500:18c1:9313:925c:730a]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id 26BA81EC0469; Thu, 24 Sep 2020 18:31:34 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1600965094; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=Wyic6RS8dnxuPl9A3GuZuq4BV1OsZd9ESbttja8eKEE=; b=l737tOpBpD/V+sYHc+UbPMpWBhNrCvZuUTwN9dgzCEFfYTpJca29PDR0IkjMj//nBl0l18 /EOgjw8oCmnPEU53HI1xAZWQhyRDGubc6JavDu/5qGDV1lZdHO6cYkF+ri0eQIV/PYEajV 97+Gd89uv9ly2gsHERD+TFzz4ShQW0A= Date: Thu, 24 Sep 2020 18:31:28 +0200 From: Borislav Petkov To: Jarkko Sakkinen Cc: x86@kernel.org, linux-sgx@vger.kernel.org, linux-kernel@vger.kernel.org, Sean Christopherson , Andy Lutomirski , Jethro Beekman , akpm@linux-foundation.org, andriy.shevchenko@linux.intel.com, asapek@google.com, cedric.xing@intel.com, chenalexchen@google.com, conradparker@google.com, cyhanish@google.com, dave.hansen@intel.com, haitao.huang@intel.com, josh@joshtriplett.org, kai.huang@intel.com, kai.svahn@intel.com, kmoy@google.com, ludloff@google.com, luto@kernel.org, nhorman@redhat.com, npmccallum@redhat.com, puiterwijk@redhat.com, rientjes@google.com, tglx@linutronix.de, yaozhangx@google.com Subject: Re: [PATCH v38 20/24] x86/traps: Attempt to fixup exceptions in vDSO before signaling Message-ID: <20200924163128.GM5030@zn.tnic> References: <20200915112842.897265-1-jarkko.sakkinen@linux.intel.com> <20200915112842.897265-21-jarkko.sakkinen@linux.intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <20200915112842.897265-21-jarkko.sakkinen@linux.intel.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Sep 15, 2020 at 02:28:38PM +0300, Jarkko Sakkinen wrote: > diff --git a/arch/x86/mm/fault.c b/arch/x86/mm/fault.c > index 9e5ec861aba0..ebe290a68c36 100644 > --- a/arch/x86/mm/fault.c > +++ b/arch/x86/mm/fault.c > @@ -30,6 +30,7 @@ > #include /* exception stack */ > #include /* VMALLOC_START, ... */ > #include /* kvm_handle_async_pf */ > +#include /* fixup_vdso_exception() */ > > #define CREATE_TRACE_POINTS > #include > @@ -775,6 +776,10 @@ __bad_area_nosemaphore(struct pt_regs *regs, unsigned long error_code, > > sanitize_error_code(address, &error_code); > > + if (fixup_vdso_exception(regs, X86_TRAP_PF, error_code, > + address)) No need to break that line. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette