Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp3275012pxu; Tue, 15 Dec 2020 03:05:08 -0800 (PST) X-Google-Smtp-Source: ABdhPJxY8bFf3tOlNuzZQN8zgnMst5K+VpnnQeOQIx0Mim/fnOSaljGHZB1+BPeiMmAFusUmhN+R X-Received: by 2002:a17:907:271c:: with SMTP id w28mr26711523ejk.140.1608030308526; Tue, 15 Dec 2020 03:05:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1608030308; cv=none; d=google.com; s=arc-20160816; b=ii2CZ/bjt9urscLUkKa6wcSN1x+YCEQUj5FNO/Zqx3BbSb47Z32jtSGL5IrmzoW3TH vaLY/fRSmX0nWHpEm+oT760jIAw6vQWnb/wg2hJ97oaPUVHp82R+yBtzGwJlb4MGivQM hIJvl6AebG/aNopDnm4W4QIU+MTNu/sgjBPPwH0hkIQY8b0YfGiVEnPvgf4eOiudSRYH mx/uo+pU91j6CvJXZYM5pdMyHs2wMS4sTMg/tA27zqNSnHd+DOcslli+qMv1toWvBSHF KhnzxQQtUeKg8ypY+646zr2LAn0QU0BRs9RGj5MbvcbMgEAwGgRVrt99qQrqssh9BKzl LmPQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:date:message-id:subject:references:in-reply-to :cc:to:from; bh=1dddv1Wjn68IP5ecygg1AInM8D3DWR6YC6ieqmGyfnk=; b=MSZGcgf6HZ2y8vTlkyjLIY8mqz5+JHhEFvKwlF9xovvbnL9I6OypbO3RcDRcdEcuYW Erz8jfcVeHa9G1AUSWOg064OyLwdr4ddQDB0rMBbls6PXDDDoYwcQ5QTUKf0X4u+cKjI kz9MLmHbSp225ErVgcqYOLyRqn+55mSKSns+o9iModwl8+EDrcb6dGLiKxEmNwgAekC3 Xquq77LVDVCgSYHag4Ki8ECd6m+9LTd0kbJgGKl0mkJLFSD0TT1mDWPTOvctjpflL0k4 xsbg4eBVfVLrPay4lrIVs74BC1YNqmmvSJAlsxfVMGZ01qRxPQ00rhP7Z6VH72Z18ctx q7Xg== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id e6si757770edv.445.2020.12.15.03.04.44; Tue, 15 Dec 2020 03:05:08 -0800 (PST) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727063AbgLOK7e (ORCPT + 99 others); Tue, 15 Dec 2020 05:59:34 -0500 Received: from bilbo.ozlabs.org ([203.11.71.1]:54695 "EHLO ozlabs.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727029AbgLOK6r (ORCPT ); Tue, 15 Dec 2020 05:58:47 -0500 Received: by ozlabs.org (Postfix, from userid 1034) id 4CwFbd6xzDz9sRR; Tue, 15 Dec 2020 21:58:05 +1100 (AEDT) From: Michael Ellerman To: Paul Mackerras , Christophe Leroy , Michael Ellerman , npiggin@gmail.com, aneesh.kumar@linux.ibm.com, Benjamin Herrenschmidt Cc: linux-kernel@vger.kernel.org, linuxppc-dev@lists.ozlabs.org In-Reply-To: <0d37490a067840f53fc5b118869917c0aec9ab87.1607491747.git.christophe.leroy@csgroup.eu> References: <0d37490a067840f53fc5b118869917c0aec9ab87.1607491747.git.christophe.leroy@csgroup.eu> Subject: Re: [PATCH v4 1/6] powerpc/book3s64/kuap: Improve error reporting with KUAP Message-Id: <160802974007.512611.9989753415773028301.b4-ty@ellerman.id.au> Date: Tue, 15 Dec 2020 21:58:05 +1100 (AEDT) Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 9 Dec 2020 05:29:20 +0000 (UTC), Christophe Leroy wrote: > This partially reverts commit eb232b162446 ("powerpc/book3s64/kuap: Improve > error reporting with KUAP") and update the fault handler to print > > [ 55.022514] Kernel attempted to access user page (7e6725b70000) - exploit attempt? (uid: 0) > [ 55.022528] BUG: Unable to handle kernel data access on read at 0x7e6725b70000 > [ 55.022533] Faulting instruction address: 0xc000000000e8b9bc > [ 55.022540] Oops: Kernel access of bad area, sig: 11 [#1] > .... > > [...] Patches 2-6 applied to powerpc/next. [2/6] powerpc/mm: sanity_check_fault() should work for all, not only BOOK3S https://git.kernel.org/powerpc/c/7ceb40027e19567a0a066e3b380cc034cdd9a124 [3/6] powerpc/fault: Unnest definition of page_fault_is_write() and page_fault_is_bad() https://git.kernel.org/powerpc/c/5250d026d241febfaf226d26cabe528fc478e225 [4/6] powerpc/mm: Move the WARN() out of bad_kuap_fault() https://git.kernel.org/powerpc/c/3dc12dfe74300febc568c3b530c0f9bee01f2821 [5/6] powerpc/fault: Avoid heavy search_exception_tables() verification https://git.kernel.org/powerpc/c/cbd7e6ca0210db05c315a27bb5db5a482f2772ce [6/6] powerpc/fault: Perform exception fixup in do_page_fault() https://git.kernel.org/powerpc/c/5f1888a077069988218805534f56b983b6d5710c cheers