Received: by 2002:ab2:69cc:0:b0:1f4:be93:e15a with SMTP id n12csp28184lqp; Fri, 12 Apr 2024 09:35:04 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWNRCmDQkwq+KFnpTT75E1gOZEFfC0uf3srkeDrz8ak03+srlObuSDcRSvqBPSs8RWpM+q+if6OMyCjt1rujZoLLiQRhwszeC0tiwzo+Q== X-Google-Smtp-Source: AGHT+IF79OSCIkgcn9gLazgw7cXfhqB6jmrS4ciu+YgduUaajEFpO5954e3qLVgVin9FgSgDf2Nm X-Received: by 2002:a17:90a:d3d1:b0:2a5:2be6:3ff5 with SMTP id d17-20020a17090ad3d100b002a52be63ff5mr3057449pjw.21.1712939704000; Fri, 12 Apr 2024 09:35:04 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712939703; cv=pass; d=google.com; s=arc-20160816; b=wgnFtjFM+9PeYoExD4BIQa2Vr5g7ryBeXuwI7NQVT3b7nDKY2M8AGiyPQ8PnMPoZry AkfmXptv3c0a8sJeGl7Ye40g/+9g/xHa9RAEXfcfSG4H6kEVzhpI/wSyNj5f69R7rX1b H9xKiJUNKrcWNoubTOxzWZj97QWtVfs/Cl4etCmPnTGk/xkVvkqQ4xb+AXHqO62hTRzg wkgvohFuA97YI0WXcO0lGqnOrqnJh+l+xthXEYLh7DGtIyN9VoNYxIqe//IhCnCX9h2J qEl/SH4w2Reuur3XVqqSEVlvYnbHTVPYqyjnZCL5A/I24uGSMYBMwk0EHICCk71Q1QuS vksg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from; bh=XwGX1ml0w/s5gOcuUEv7/p3aWfR4VK2pBXsN3D0A3WM=; fh=22aR/NFsCqnOGZIQzPDG1h79gcfY6gTV1vkpxQGj2A0=; b=ijsiMNxbMCTAbLKcj+Qe5KkPOImGig1R6xBUlkUxcewU8dqZ4GO2JAQiHtlbinmiZZ q/OOo8DONLQ3xZUqSQZQcJjJYQjFJiI7vQVLE9HiIGBJ9GwfeT7d6Aw8sTF1FCUZjRUV gVlkKUgG5OrUXlU4s02nlrXEdZfh5xwl2xuCCr8FGtJkpkwPJqjTdHDaa5/6QA2xNJm7 tIA6nig3b89vaPZJDC5M5WfBlr5fOnZt6hTgw9QsuaU1VXMmOwFb7jkqFNnH5qLiGxtX s5BhlT5jKQKFSPAcbkhIjaQJB9zz+Xkmp/I7FZL2qeT5wXlZ3Q7c9zBdzM8ujgV5DRWD QFXw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-143048-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-143048-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [2604:1380:40f1:3f00::1]) by mx.google.com with ESMTPS id h24-20020a17090ac39800b0029dd8953b07si3676559pjt.144.2024.04.12.09.35.03 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 12 Apr 2024 09:35:03 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-143048-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) client-ip=2604:1380:40f1:3f00::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=huawei.com dmarc=pass fromdomain=huawei.com); spf=pass (google.com: domain of linux-kernel+bounces-143048-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:40f1:3f00::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-143048-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id C8EFEB23B1B for ; Fri, 12 Apr 2024 16:19:45 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 0650A14A0AE; Fri, 12 Apr 2024 16:18:10 +0000 (UTC) Received: from frasgout.his.huawei.com (frasgout.his.huawei.com [185.176.79.56]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 3F7D114A0B8; Fri, 12 Apr 2024 16:18:08 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.176.79.56 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712938689; cv=none; b=PQPxgsKxXQRDlbIAQvDNlM+/0+ZCc8mRW55l8zG0bpUmCazF2Q7ZfcmeqHLNu1Ivep3q2CCoh+Q2XBdazj4d1shZsr88CioWtbr27CQQxgXOngqU+H2Vk+Y2mcX4eDseq0x+R1CzXRpcdkKJc5JhSdw7WD5uDT9i4EJ662/G+44= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712938689; c=relaxed/simple; bh=r5vwBGGey4k5VfNBQTEwSrb8Yw3rErC2yx1VhM/Ih80=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=IIdVoXSb0G3/F5FLNAdz8/oktEG2lzUZQVa2ReCGGKoZo7ok8sOyhqjw2P0VuMtVUq09QpoV+pRCmNDggXR5jeHsmw3i8FhqUll4mn78owjdo0HyeWOZKMu724H93RhQ78W8Evq1gXcQFYybuMnJIDvfCIvgIAvkkZLGosjMSw4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com; spf=pass smtp.mailfrom=huawei.com; arc=none smtp.client-ip=185.176.79.56 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huawei.com Received: from mail.maildlp.com (unknown [172.18.186.231]) by frasgout.his.huawei.com (SkyGuard) with ESMTP id 4VGM6z4bQ5z6K6hC; Sat, 13 Apr 2024 00:13:15 +0800 (CST) Received: from lhrpeml500005.china.huawei.com (unknown [7.191.163.240]) by mail.maildlp.com (Postfix) with ESMTPS id 15A87140B3C; Sat, 13 Apr 2024 00:18:06 +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_256_GCM_SHA384) id 15.1.2507.35; Fri, 12 Apr 2024 17:18:05 +0100 From: Jonathan Cameron To: Mark Rutland , Peter Zijlstra , Ingo Molnar , Arnaldo Carvalho de Melo , Will Deacon , , , CC: , Shaokun Zhang , Yicong Yang , Jiucheng Xu , Khuong Dinh , 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 v2 14/30] perf/qcom: Assign parents for event_source devices Date: Fri, 12 Apr 2024 17:10:41 +0100 Message-ID: <20240412161057.14099-15-Jonathan.Cameron@huawei.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240412161057.14099-1-Jonathan.Cameron@huawei.com> References: <20240412161057.14099-1-Jonathan.Cameron@huawei.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain X-ClientProxiedBy: lhrpeml100003.china.huawei.com (7.191.160.210) To lhrpeml500005.china.huawei.com (7.191.163.240) 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 148df5ae8ef8..9d6a8ae1c47a 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 f16783d03db7..37786e88514e 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.39.2