Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp1163327ybl; Fri, 10 Jan 2020 13:16:17 -0800 (PST) X-Google-Smtp-Source: APXvYqz7saZDx7CPrpIkJ+SDxLvX4prI9zKwDNspfFVvUaRlx1BrwcaxxO3qXi6nSJacD73yprbO X-Received: by 2002:a05:6830:22c6:: with SMTP id q6mr4409325otc.244.1578690977723; Fri, 10 Jan 2020 13:16:17 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1578690977; cv=none; d=google.com; s=arc-20160816; b=l7JXBdUVS16tntvI5iJHLcav/KverHkRP4clA2EQCysv31DzYcghxvDWhWev6MW/7u xrE+abpl9mM1nQXn7mPEWaX90pcbC8cb1u2+DTLMquTY4hUcjFgezzeV32Sejm8W+6Nr rDH+5LPQSTzGN/g2v9HuhjrN9jKs+HIoZcEqglhGPwMo9l9FXk/vtWgOXeX9lUYOXqQo nCc9ueZxiQIq01ea7CdEj36qHxZ03FuJJRArpaIwRlBG0BfQbbpiriXKveY9sssygrly g1v+ugUScWGAjX8xntJhwK74msWDScrUgC7E1FGfrY2pWK9IADJfl37nv9RNkuuMHhYE o5bQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=t8bMlx3yVEv9zU0xDUT4JoQBf57pH4Aos3r9DWeX5bE=; b=o8WCo4T4vswjKY4PFJC7szv4/Mm1hwVEgiLbqxrCpsjQm/JyYA9wLyM4Oji4+T7Ne/ sqcRRAXgUhGQ+v8vHflFO9tKQlXsae4Qefz/3kLTNXLGgRi1z79okXAg7WQ9B+mvPmdu tGeTYPgh+DkRd/bI2PH+WaIXBjXN30ZRi190e0tVfGnJgi0Ine3jopswdSileNs7v3WX pl5FLyePPSmSRwsPFsE1lFtNiw34gUkYQpke5QNrPrkHmC7x/XyZXG0cldZ8qMUUmfAp kKoboBCNYTtf9JqrHCnphcqWBzOiBe93My22PYWv3UtQFDaFkNhYs1xVqQZEIxOpKQqv 6o8g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@joelfernandes.org header.s=google header.b=YuCDXCY3; 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 25si1654968oix.178.2020.01.10.13.16.05; Fri, 10 Jan 2020 13:16:17 -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; dkim=pass header.i=@joelfernandes.org header.s=google header.b=YuCDXCY3; 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 S1726912AbgAJVOl (ORCPT + 99 others); Fri, 10 Jan 2020 16:14:41 -0500 Received: from mail-pl1-f194.google.com ([209.85.214.194]:42062 "EHLO mail-pl1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726762AbgAJVOk (ORCPT ); Fri, 10 Jan 2020 16:14:40 -0500 Received: by mail-pl1-f194.google.com with SMTP id p9so1301295plk.9 for ; Fri, 10 Jan 2020 13:14:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=joelfernandes.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=t8bMlx3yVEv9zU0xDUT4JoQBf57pH4Aos3r9DWeX5bE=; b=YuCDXCY3hwa94AhsKBLyqdk6tp3fytvqMdvAlpRsi6RJMkk9dNCg58HHy+dJ6+1gj6 4unrTP+4SPLWeLQJ6GdkHa/gKUHvXn/P4Exn0feaUcF/g9+e+6f02O2eKAdX00yj769x Y1kL5H08/Pk3mIqz+u3XLv5z4jIaIOFTqJKEM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=t8bMlx3yVEv9zU0xDUT4JoQBf57pH4Aos3r9DWeX5bE=; b=VaJbplVCmMHFk6kyKZSPCFlS7XrVbH/lz5HrY575wNodSCLPrEX/GaH/dBVet0C7ni bLtDHUGYVZRsygdJpfvVr9xtRk9yFgnnqIfETgSjMn0cI2l2Pa02PWC74pI+1mKPofFU Ixggv/N7sD/UcF7QWssRfjtTw6d23gsIybZh2MtAXBWZWihccNMxW/w61sdg1R8VZSVT +/tzgjLAXnoZ/h4yOfLIDkcOFGbscmF30E2vV6otQAlNcPGjrxwzJr9CT52OHu6twG3R g/FgR326Brj+ifRIAgAYIwTlDiFLs+LVeeUAXsnxxD893hi9rpNw5T6o2ZFZXsYw9KoO 0SVA== X-Gm-Message-State: APjAAAV+yFEW3s9zXB762x4rSSiyYlzQ2d1QCZDZKXOvkha2HuXMpjs4 ESd1y6P5Rn5rlLwv5vpeknZMng== X-Received: by 2002:a17:902:8484:: with SMTP id c4mr529932plo.339.1578690879634; Fri, 10 Jan 2020 13:14:39 -0800 (PST) Received: from localhost ([2620:15c:6:12:9c46:e0da:efbf:69cc]) by smtp.gmail.com with ESMTPSA id r7sm4278287pfg.34.2020.01.10.13.14.38 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 10 Jan 2020 13:14:39 -0800 (PST) Date: Fri, 10 Jan 2020 16:14:38 -0500 From: Joel Fernandes To: Masami Hiramatsu Cc: Ingo Molnar , Anders Roxell , paulmck@kernel.org, "Naveen N . Rao" , Anil S Keshavamurthy , David Miller , Linux Kernel Mailing List Subject: Re: [PATCH -tip V2 0/2] kprobes: Fix RCU warning and cleanup Message-ID: <20200110211438.GE128013@google.com> References: <157535316659.16485.11817291759382261088.stgit@devnote2> <20191221035541.69fc05613351b8dabd6e1a44@kernel.org> <20200107211535.233e7ff396f867ee1348178b@kernel.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200107211535.233e7ff396f867ee1348178b@kernel.org> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, Jan 07, 2020 at 09:15:35PM +0900, Masami Hiramatsu wrote: > Hello, > > Anyone have any comment on this series? > Without this series, I still see the suspicious RCU warning for kprobe on -tip tree. +Paul since RCU. Hi Masami, I believe I had commented before that I don't agree with this patch: https://lore.kernel.org/lkml/157535318870.16485.6366477974356032624.stgit@devnote2/ The rationale you used is to replace RCU-api with non-RCU api just to avoid warnings. I think a better approach is to use RCU api and pass the optional expression to silence the false-positive warnings by informing the RCU API about the fact that locks are held (similar to what we do for rcu_dereference_protected()). The RCU API will do additional checking (such as making sure preemption is disabled for safe RCU usage etc) as well. Could you repost the latest versions? thanks, - Joel > > Thank you, > > On Sat, 21 Dec 2019 03:55:41 +0900 > Masami Hiramatsu wrote: > > > Hi Ingo, > > > > Could you pick this series to fix the false-positive RCU-list warnings? > > > > Thank you, > > > > On Tue, 3 Dec 2019 15:06:06 +0900 > > Masami Hiramatsu wrote: > > > > > Hi, > > > > > > Here is a couple of patches which fix suspicious RCU > > > usage warnings in kprobes. > > > > > > Anders reported the first warning in kprobe smoke test > > > with CONFIG_PROVE_RCU_LIST=y. While fixing this issue, > > > I found similar issues and cleanups in kprobes. > > > > > > Thank you, > > > > > > --- > > > > > > Masami Hiramatsu (2): > > > kprobes: Suppress the suspicious RCU warning on kprobes > > > kprobes: Use non RCU traversal APIs on kprobe_tables if possible > > > > > > > > > kernel/kprobes.c | 32 ++++++++++++++++++++++---------- > > > 1 file changed, 22 insertions(+), 10 deletions(-) > > > > > > -- > > > Masami Hiramatsu (Linaro) > > > > > > -- > > Masami Hiramatsu > > > -- > Masami Hiramatsu