Received: by 2002:ac0:a594:0:0:0:0:0 with SMTP id m20-v6csp653801imm; Mon, 21 May 2018 11:58:38 -0700 (PDT) X-Google-Smtp-Source: AB8JxZrjwfSasr3g+bTHZ+WlWy7LTdMbg1TG1lTW5JkviG4OKpwMi0geEFE/4tvi5rwSyeGCEYif X-Received: by 2002:a17:902:4483:: with SMTP id l3-v6mr21770951pld.282.1526929118090; Mon, 21 May 2018 11:58:38 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1526929118; cv=none; d=google.com; s=arc-20160816; b=ajAnzVDL4vJiV7HSN3wCo5uVLvMI2uGrQHtLixAj8vSUbn4SthaLfL+19bEullWokt 3tdjuI3tHJskNYTOVpD3AsLSYQRvYsFfjWQmaho2mvuw3yxbStX7I9KllNvzSy+xmMIo lO9ZPhdyO8WqFuruWEvAB9CFJY8keOj2mTkxVz0XpXxpU+Lo+vsTZgjvArszhwDl3kmz fy/k2DkM6r7zwqbVMZJN7z8ZIN714nBjbJC/TNYJm4dFxbWlz6wOwcvsP8fLWkXBPyPD dgPxgBJeq540BCub79Zm7WnQQl+onQtwprIWVTNIU6xK0N+PuwXUi6mwzSZp9BMjGqlv pggA== 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 :organization:references:in-reply-to:message-id:subject:cc:to:from :date:arc-authentication-results; bh=FAcvjttfq96rPpgoEBHr+jTHAtMuppFZ6wzZWA5hCBw=; b=C87Nwt77DTQpe6aMkV6sYx6NUFE4jEfn+5REEXgoy0l8Elt4dX7+YE4IMxn6JpdjpW 0cr4jrsZKrH6igownmcXszt4ZBX2OziBlapG9jJ9ysy9zt+fyv7dHuF9dsZO1v9z5mrs OWl8TuWVk9J2T3CrW9JO50CF5vb8jMVCGIE2ugk0N+OIGgMsUizsWD/9cx19uinuzyGp vZ3gs0bd2aa818ob3ZWwO6WIL71/98O85aamI6nnxF0q3W/FDYS3KY8IQXmRnx4Rugvy pZuCngY6pMgNLOS/h4t7F3IN/C/rpQ2cRYwRQhNj2uMtH24vqEuZweKwLymY8iXdNfVG qoBg== 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 b93-v6si14770514plb.536.2018.05.21.11.58.21; Mon, 21 May 2018 11:58:38 -0700 (PDT) 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 S1751105AbeEUS6K (ORCPT + 99 others); Mon, 21 May 2018 14:58:10 -0400 Received: from foss.arm.com ([217.140.101.70]:55120 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750960AbeEUS6I (ORCPT ); Mon, 21 May 2018 14:58:08 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.72.51.249]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 54E911435; Mon, 21 May 2018 11:58:08 -0700 (PDT) Received: from dupont (dupont.austin.arm.com [10.118.16.87]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id F3BFB3F25D; Mon, 21 May 2018 11:58:07 -0700 (PDT) Date: Mon, 21 May 2018 13:58:07 -0500 From: Kim Phillips To: Mark Rutland Cc: linux-arm-kernel@lists.infradead.org, will.deacon@arm.com, Pawel Moll , linux-kernel@vger.kernel.org, perf group Subject: Re: [PATCHv2] drivers/perf: arm-ccn: don't log to dmesg in event_init Message-Id: <20180521135807.3b39d00979b7c416d4f65be2@arm.com> In-Reply-To: <20180521171949.31412-1-mark.rutland@arm.com> References: <20180521171949.31412-1-mark.rutland@arm.com> Organization: Arm X-Mailer: Sylpheed 3.7.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 [adding LKML, linux-perf-users. Please do so from now on] On Mon, 21 May 2018 18:19:49 +0100 Mark Rutland wrote: > The ARM CCN PMU driver uses dev_warn() to complain about parameters in > the user-provided perf_event_attr. This means that under normal > operation (e.g. a single invocation of the perf tool), a number of > messages warnings may be logged to dmesg. > > Tools may issue multiple syscalls to probe for feature support, and > multiple applications (from multiple users) can attempt to open events > simultaneously, so this is not very helpful, even if a user happens to > have access to dmesg. Worse, this can push important information out of > the dmesg ring buffer, and can significantly slow down syscall fuzzers, > vastly increasing the time it takes to find critical bugs. > > Demote the dev_warn() instances to dev_dbg(), as is the case for all > other PMU drivers under drivers/perf/. Users who wish to debug PMU event > initialisation can enable dynamic debug to receive these messages. > > Signed-off-by: Mark Rutland > Cc: Pawel Moll > Cc: Will Deacon > --- Care to address my comments to the rationale?: https://marc.info/?l=linux-arm-kernel&m=152582291919277&w=2 Thanks, Kim