From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 36742C433F5 for ; Wed, 3 Nov 2021 08:21:43 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 17D07611C6 for ; Wed, 3 Nov 2021 08:21:43 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231332AbhKCIYR (ORCPT ); Wed, 3 Nov 2021 04:24:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58758 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230025AbhKCIYQ (ORCPT ); Wed, 3 Nov 2021 04:24:16 -0400 Received: from casper.infradead.org (casper.infradead.org [IPv6:2001:8b0:10b:1236::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 933CFC061714 for ; Wed, 3 Nov 2021 01:21:40 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=8huLmD98SSL+mzJ3Jm1lG9FgiQpVwJXnN0kffx8m9Zc=; b=ejv5Lm027thQy32eIITKEnby8p UqZZ85rHOSGSW9ivQzOncgNh33mvw3J9khqB5XoVctP6MvF0qfI96C1yHartbZtMXYhc6CXUj84GC ymIcRDHREX3UKQDpUbhBVyFuusHtN4VyabX06n0ufOVfV4Dz0e/+RvF+Vtpwa1Szu7m5FQRScHRfr MyzgrC8GYwAx+nEBD8cvqq7i5Z8lbU86vJWLs1la/s8KpUs1paC2VbCSmAt/Yw7a+Vv3b9mTbuVYi 3AKoUM4GG6ZB+uql8XT02HEkL3h3tKu9g3dTCE0qpTeAqZml6MrvS697yHnwKhuGgBvVB5ZB9Kcgr cIPyzgFw==; Received: from j217100.upc-j.chello.nl ([24.132.217.100] helo=worktop.programming.kicks-ass.net) by casper.infradead.org with esmtpsa (Exim 4.94.2 #2 (Red Hat Linux)) id 1miBUe-0054WQ-4b; Wed, 03 Nov 2021 08:19:54 +0000 Received: by worktop.programming.kicks-ass.net (Postfix, from userid 1000) id 61F2D986378; Wed, 3 Nov 2021 09:19:35 +0100 (CET) Date: Wed, 3 Nov 2021 09:19:35 +0100 From: Peter Zijlstra To: Alexander Popov Cc: Linus Torvalds , Thomas Gleixner , Josh Poimboeuf , Linux Kernel Mailing List , the arch/x86 maintainers Subject: Re: Stackleak vs noinstr (Was: [GIT pull] objtool/core for v5.16-rc1) Message-ID: <20211103081935.GA174703@worktop.programming.kicks-ass.net> References: <163572864256.3357115.931779940195622047.tglx@xen13> <163572864563.3357115.8793939214537874196.tglx@xen13> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Nov 03, 2021 at 10:18:22AM +0300, Alexander Popov wrote: > Yes, this is a correct approach. > > But I'm not sure about removing NOKPROBE_SYMBOL and notrace for > stackleak_erase. Does the code in noinstr.text disable all those? Yes, noinstr implies all those and more. Both kprobe and tracing are a form of instrumentation, and hence noinstr must disallow it.