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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id D6DCDC7618D for ; Thu, 6 Apr 2023 03:59:42 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235110AbjDFD6E (ORCPT ); Wed, 5 Apr 2023 23:58:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57732 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235045AbjDFD6D (ORCPT ); Wed, 5 Apr 2023 23:58:03 -0400 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 565339760; Wed, 5 Apr 2023 20:58:02 -0700 (PDT) Received: from canpemm500009.china.huawei.com (unknown [172.30.72.57]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4PsSKw0VcRzSqkp; Thu, 6 Apr 2023 11:54:12 +0800 (CST) Received: from [10.67.102.169] (10.67.102.169) by canpemm500009.china.huawei.com (7.192.105.203) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23; Thu, 6 Apr 2023 11:57:30 +0800 CC: , , Dan Williams , Shaokun Zhang , Jiucheng Xu , Khuong Dinh , Robert Richter , Atish Patra , Anup Patel , Andy Gross , Bjorn Andersson , Frank Li , Shuai Xue , Vineet Gupta , Shawn Guo , Fenghua Yu , Dave Jiang , Wu Hao , Tom Rix , , Suzuki K Poulose , Liang Kan Subject: Re: [PATCH 04/32] perf/hisi-uncore: Assign parents for event_source devices To: Jonathan Cameron , Mark Rutland , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Will Deacon , , , References: <20230404134225.13408-1-Jonathan.Cameron@huawei.com> <20230404134225.13408-5-Jonathan.Cameron@huawei.com> From: Yicong Yang Message-ID: <233516c4-be85-ec0b-e586-bb1c5f78a9b5@huawei.com> Date: Thu, 6 Apr 2023 11:57:30 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:78.0) Gecko/20100101 Thunderbird/78.5.1 MIME-Version: 1.0 In-Reply-To: <20230404134225.13408-5-Jonathan.Cameron@huawei.com> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit X-Originating-IP: [10.67.102.169] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To canpemm500009.china.huawei.com (7.192.105.203) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-fpga@vger.kernel.org On 2023/4/4 21:41, Jonathan Cameron wrote: > Currently the PMU device appears directly under /sys/devices/ > Only root busses should appear there, so instead assign the pmu->dev > parent to be the platform device. > > Link: https://lore.kernel.org/linux-cxl/ZCLI9A40PJsyqAmq@kroah.com/ > Signed-off-by: Jonathan Cameron Reviewed-by: Yicong Yang > --- > drivers/perf/hisilicon/hisi_uncore_pmu.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/drivers/perf/hisilicon/hisi_uncore_pmu.c b/drivers/perf/hisilicon/hisi_uncore_pmu.c > index f1b0f5e1a28f..b4350e5dc3fc 100644 > --- a/drivers/perf/hisilicon/hisi_uncore_pmu.c > +++ b/drivers/perf/hisilicon/hisi_uncore_pmu.c > @@ -538,6 +538,7 @@ void hisi_pmu_init(struct hisi_pmu *hisi_pmu, const char *name, > > pmu->name = name; > pmu->module = module; > + pmu->parent = hisi_pmu->dev; > pmu->task_ctx_nr = perf_invalid_context; > pmu->event_init = hisi_uncore_pmu_event_init; > pmu->pmu_enable = hisi_uncore_pmu_enable; >