Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp3745147imu; Mon, 14 Jan 2019 08:18:57 -0800 (PST) X-Google-Smtp-Source: ALg8bN7RV2hHeje/ENa9FaFRaG/1GswnW7v92KifHryKPjQvrElxJ4SYe6Md11yYypROmJ1qGBa0 X-Received: by 2002:aa7:868f:: with SMTP id d15mr25838425pfo.225.1547482737524; Mon, 14 Jan 2019 08:18:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1547482737; cv=none; d=google.com; s=arc-20160816; b=SsoGR4xkr9UyuqTg12XNUDgO5444TyOSG6otRp5OspClVVwgvQWGIKZdGMjkOoqSlZ x1OVnB27tcTWAtVeJH0OOrX2ciNchx9kEIr4Dp9Isw9BLw8gelYZdWA7FbPR2RJXd7tE vv/nm6X8yz/pKZFi3+NrCOdo2tvo+wOTXUtvT7e9DFa5P0OkSpl6vjq/82J4x1LxfZgS 2uIhrvMKtiHrx6DwQWklJqIoYajY8UPi8xCEi7CBNrSwaqL5Faro+SLQ3PnPf3K5nD1P 6bz8WZW9Lj8Pr9BWMuEvMG9V07BriS2zA3YD53oWw20gvNX7wPb2uzlOMk2YslxuC5dV Qjyw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date; bh=3G4jr0MCH3FimIs2MR0fF+M5zwSCI2EwhfIWcXxf6QE=; b=dDNTxt4YvVSCvfPMnuRlox7S9ocjwWuqvQd9ZgqneDpwuFFfwLbiE5T4CYr/7BgN5E VD+Pt/D17GO08K1XpLiAgdKCDZMj8x2GupX9P2mv4p+6oqN2wPudlg15+SW8j80Hyfdz OednRzBHXFJPzoNmdSA4BzYOwkc8MbuI8+L6MVqbABQPjjYaoIFK6FWNPlQ/k9mbcTMm vO6W+HwQw30P29if2SyX9zucjzolgTZdVjaFT+y7lMqYYRCGIEp20vm5RyhQ412Fprvj tFi/VXEgft2/l1Arj/1fnMrTTzhR//MOzNDF4FzXKNc0UywQYI3gXSfz4b4+sXN4IWep tIHw== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id g63si636661pfc.60.2019.01.14.08.18.41; Mon, 14 Jan 2019 08:18:57 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726819AbfANQRA (ORCPT + 99 others); Mon, 14 Jan 2019 11:17:00 -0500 Received: from mail.kernel.org ([198.145.29.99]:48618 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726640AbfANQRA (ORCPT ); Mon, 14 Jan 2019 11:17:00 -0500 Received: from gandalf.local.home (cpe-66-24-58-225.stny.res.rr.com [66.24.58.225]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 5CA5420873; Mon, 14 Jan 2019 16:16:59 +0000 (UTC) Date: Mon, 14 Jan 2019 11:16:57 -0500 From: Steven Rostedt To: Masami Hiramatsu Cc: Ingo Molnar , peterz@infradead.org, Mathieu Desnoyers , linux-kernel , Andrea Righi Subject: Re: [PATCH v2 5/9] kprobes: Search non-suffixed symbol in blacklist Message-ID: <20190114111657.639a3bf8@gandalf.local.home> In-Reply-To: <154726008226.18060.9082091974811290044.stgit@devbox> References: <154725993986.18060.2759150647140353514.stgit@devbox> <154726008226.18060.9082091974811290044.stgit@devbox> X-Mailer: Claws Mail 3.16.0 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sat, 12 Jan 2019 11:28:02 +0900 Masami Hiramatsu wrote: > Newer gcc can generate some different instances of a function > with suffixed symbols if the function is optimized and only > has a part of that. (e.g. .constprop, .part etc.) > > In this case, it is not enough to check the entry of kprobe > blacklist because it only records non-suffixed symbol address. > > To fix this issue, search non-suffixed symbol in blacklist if > given address is within a symbol which has a suffix. > > Note that this can cause false positive cases if a kprobe-safe > function is optimized to suffixed instance and has same name > symbol which is blacklisted. > But I would like to chose a fail-safe design for this issue. > > Signed-off-by: Masami Hiramatsu Reviewed-by: Steven Rostedt (VMware) -- Steve