Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp3906618ybv; Mon, 10 Feb 2020 08:34:36 -0800 (PST) X-Google-Smtp-Source: APXvYqytEcoo0zw4Fj4zV1OwqhwUSH/3tz7+9aSssd2y06WQ8a6epcvrfpXr5OM51D210Eh4IPKS X-Received: by 2002:a05:6808:8d0:: with SMTP id k16mr1346801oij.68.1581352476152; Mon, 10 Feb 2020 08:34:36 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1581352476; cv=none; d=google.com; s=arc-20160816; b=NWppe9bj+z4KUJa+s0MsHi4w93mZ3Dfps/K5Qx/ZLMtaoXeqmb9UC5adg2rTs8/yiU ePSNfyBe/IZ4x+gQYVIoP4yEixPy22akJBO4bPRJqjiNW5wbLzW4dRAmG3IcHaMb60XO luwDn9o7FZ7cQnGUzYUjCAeASqJy653KKPqUwkyIFVJX9+NJt84fMsNzw/62+e5ghxcO 4d3XpzueRU0OlZ21H85hHlKdDwjECEE0tUVp89IUqXFcm9ijsAjOVqcHLvsWQeEm3mb7 BrbRBbWZb6kNGqAEadEWLzqHZFvcdTH71YYB4eKhD/lWKVLGS5Ysk2dZ9/QdwmzIV3f/ Hkdg== 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=TYukr5dq99Wb6Jz0o3Qw0MLepm8kfq6DhcjLCXJwOIU=; b=fiqLy58+0uJO0f8VLPtvxW0uagOu3D4jO3q+nXjcF0Mg1HSkllyLkNVl9Lbf2d+MHI GQmg1Smi7jBpvokojWqR/S0fXPbpqqxEjWPEMitsrKM/5LUzIfGF2JUUu5gOw7GV9Xh9 kuIl0EXCplQU0NR9AvKzzPfLp8pFgRNaZXq12Q+/2oVqZxxRwZKeGEfNyssku2MwpEzC 3+wTdk2ODn+5EuHhApwXkJW+0wQEtIdjwf3u3nPWRHvNnI2ffUBeDLvaxEL69kEUu3Sk 6yZABdF768vI6SKBCuWe7zbXcfjEl7NwOUCKpIIjxJyfbB6EZswqXOpnGcV65hN2j8x/ pffQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=USLhZXtz; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o20si414161otl.60.2020.02.10.08.34.24; Mon, 10 Feb 2020 08:34:36 -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=@kernel.org header.s=default header.b=USLhZXtz; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727928AbgBJQeH (ORCPT + 99 others); Mon, 10 Feb 2020 11:34:07 -0500 Received: from mail.kernel.org ([198.145.29.99]:36948 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727640AbgBJQeG (ORCPT ); Mon, 10 Feb 2020 11:34:06 -0500 Received: from willie-the-truck (236.31.169.217.in-addr.arpa [217.169.31.236]) (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 83BE42085B; Mon, 10 Feb 2020 16:34:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1581352446; bh=M1hd3p9CfdbpxNt92LvggRQSIKAyGUl2mET37GiGwb4=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=USLhZXtzCssL6tE52ftuZWqw+kDdKDOY2DEkJ8Nq9CoKd2ivfCUakOsUtt6txO8ue z/snzuxStwbUXtXTNXQDA22n1aWldWd/aTI5bEfQWKXQZn6+wPpH5IjbU+zTfTDFbV TFmEGG5XJQHUIHMGzNL9LnpS2p2JjDueUGbgds+o= Date: Mon, 10 Feb 2020 16:34:01 +0000 From: Will Deacon To: Wu Hao Cc: mdf@kernel.org, mark.rutland@arm.com, gregkh@linuxfoundation.org, linux-fpga@vger.kernel.org, linux-kernel@vger.kernel.org, linux-api@vger.kernel.org, atull@kernel.org, yilun.xu@intel.com, Luwei Kang Subject: Re: [PATCH v7 2/2] fpga: dfl: fme: add performance reporting support Message-ID: <20200210163400.GA21900@willie-the-truck> References: <1581306469-22629-1-git-send-email-hao.wu@intel.com> <1581306469-22629-3-git-send-email-hao.wu@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1581306469-22629-3-git-send-email-hao.wu@intel.com> 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 Hi, On Mon, Feb 10, 2020 at 11:47:49AM +0800, Wu Hao wrote: > This patch adds support for performance reporting private feature > for FPGA Management Engine (FME). Now it supports several different > performance counters, including 'basic', 'cache', 'fabric', 'vtd' > and 'vtd_sip'. It allows user to use standard linux tools to access > these performance counters. I had a quick look at this, and it mostly looks alright to me. Just a few high-level comments/questions: - I would still prefer for the PMU drivers to live under drivers/perf/ - You should probably give the PMU a better name than "fme%d", for example "intel_fpga_dfl_fme%d". - CPU0 can be hotplugged off on non-x86 systems. How do you cope with that? - readq() will emit 2x32-bit reads on some architectures. What happens in this case? Will