Received: by 2002:a05:6358:11c7:b0:104:8066:f915 with SMTP id i7csp6017012rwl; Tue, 4 Apr 2023 06:52:45 -0700 (PDT) X-Google-Smtp-Source: AKy350bFTUPZyJpLTCUqOg/TatSpxbklk576F7GuUmVJhFzWxNPVVooxZal+9iDRR5GTRM0v/pkK X-Received: by 2002:a17:906:2dca:b0:93f:9b68:a0f4 with SMTP id h10-20020a1709062dca00b0093f9b68a0f4mr2699184eji.26.1680616364921; Tue, 04 Apr 2023 06:52:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1680616364; cv=none; d=google.com; s=arc-20160816; b=oi1TrXN7BYYaxbFM8PoLTSQzoBSMpRP+IFMp+jRSqJg1LPIDJrw7+DLrxagJnNwjqs jMKywy5i23H+5wYUMrLv7BouiIps6WxpkP8bJ8vNjxzzHK4ecKs8r17zdUjCP00HFZR8 baBKrHVnHKCmVZauEhPG8MrSndg0BSWPRCkD7DCSyMIZGIIafYG11jtQUebPRW+6zzM2 R0HI1gRR91SycfDu5iiBgfOGjIGcYLK9ViLrr4bPJAbar08KCRXjI1YbI2PpoGhRkZGM EqfwMU9jFURb2kZhd7DRkZJIxStEROebKndmjcijCxtAeEimRmHknj6VRt56HP7IHgXR JbQg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=A4i92Wn2kLUH22rwabToAo+4xPXK9MzRYuXvF6zJkFU=; b=vE5aNVvL8e7qki3dU4X6KUe/nS8gaXmE9KgJdtg9N/Q5D8ybxzmYKPV/5lVWkQCOaQ WTOjfnlbzsw22lywjqqMJ30XdkiYIMNIaBKcfEZFg0lXfDjz2Mt25cKVxl8CRSIJDmqy Pjs9NR65eJMCRWBEQ+PdJoZVovOjZoJPm2eDZ7rdMSRbog6BI7JlI1EKev4ex1IyqOYp uMIDkUOmXStN5EAljJpTL8pSJWlsCZJSNq6j4ZfmQqDZLkRoxH4VGzvAkEohnFaNw5zS G3xBqNaiVA8j8UJ0oJCpcjyvzdbNtM8f4Uf7gsdxtf7h6bIwBQtwqabRF8F2MHTU+PpP tCUg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x12-20020a1709064a8c00b0093bd1b12b6esi6374973eju.385.2023.04.04.06.52.19; Tue, 04 Apr 2023 06:52:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235024AbjDDNuR (ORCPT + 99 others); Tue, 4 Apr 2023 09:50:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:46988 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235327AbjDDNuI (ORCPT ); Tue, 4 Apr 2023 09:50:08 -0400 Received: from frasgout.his.huawei.com (frasgout.his.huawei.com [185.176.79.56]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 075D94212; Tue, 4 Apr 2023 06:50:02 -0700 (PDT) Received: from lhrpeml500005.china.huawei.com (unknown [172.18.147.206]) by frasgout.his.huawei.com (SkyGuard) with ESMTP id 4PrTYj0nTqz67dbJ; Tue, 4 Apr 2023 21:46:01 +0800 (CST) Received: from SecurePC-101-06.china.huawei.com (10.122.247.231) by lhrpeml500005.china.huawei.com (7.191.163.240) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23; Tue, 4 Apr 2023 14:49:59 +0100 From: Jonathan Cameron To: Mark Rutland , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Will Deacon , , , CC: , Dan Williams , Shaokun Zhang , Yicong Yang , 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: [PATCH 15/32] perf/qcom: Assign parents for event_source devices Date: Tue, 4 Apr 2023 14:42:08 +0100 Message-ID: <20230404134225.13408-16-Jonathan.Cameron@huawei.com> X-Mailer: git-send-email 2.37.2 In-Reply-To: <20230404134225.13408-1-Jonathan.Cameron@huawei.com> References: <20230404134225.13408-1-Jonathan.Cameron@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.122.247.231] X-ClientProxiedBy: lhrpeml500003.china.huawei.com (7.191.162.67) To lhrpeml500005.china.huawei.com (7.191.163.240) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-2.3 required=5.0 tests=RCVD_IN_DNSWL_MED, RCVD_IN_MSPIKE_H2,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Currently all these devices appear directly under /sys/devices/ Only root busses should appear there, so instead assign the pmu->dev parents to be the platform devices. Link: https://lore.kernel.org/linux-cxl/ZCLI9A40PJsyqAmq@kroah.com/ Cc: Andy Gross Cc: Bjorn Andersson Signed-off-by: Jonathan Cameron --- drivers/perf/qcom_l2_pmu.c | 1 + drivers/perf/qcom_l3_pmu.c | 1 + 2 files changed, 2 insertions(+) diff --git a/drivers/perf/qcom_l2_pmu.c b/drivers/perf/qcom_l2_pmu.c index aaca6db7d8f6..b047282cdda8 100644 --- a/drivers/perf/qcom_l2_pmu.c +++ b/drivers/perf/qcom_l2_pmu.c @@ -904,6 +904,7 @@ static int l2_cache_pmu_probe(struct platform_device *pdev) l2cache_pmu->pmu = (struct pmu) { /* suffix is instance id for future use with multiple sockets */ .name = "l2cache_0", + .parent = &pdev->dev, .task_ctx_nr = perf_invalid_context, .pmu_enable = l2_cache_pmu_enable, .pmu_disable = l2_cache_pmu_disable, diff --git a/drivers/perf/qcom_l3_pmu.c b/drivers/perf/qcom_l3_pmu.c index 346311a05460..f693a6d9e7e1 100644 --- a/drivers/perf/qcom_l3_pmu.c +++ b/drivers/perf/qcom_l3_pmu.c @@ -748,6 +748,7 @@ static int qcom_l3_cache_pmu_probe(struct platform_device *pdev) return -ENOMEM; l3pmu->pmu = (struct pmu) { + .parent = &pdev->dev, .task_ctx_nr = perf_invalid_context, .pmu_enable = qcom_l3_cache__pmu_enable, -- 2.37.2