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 8AB98C433EF for ; Wed, 2 Feb 2022 16:46:46 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1345992AbiBBQqp (ORCPT ); Wed, 2 Feb 2022 11:46:45 -0500 Received: from foss.arm.com ([217.140.110.172]:42290 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232448AbiBBQqi (ORCPT ); Wed, 2 Feb 2022 11:46:38 -0500 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 39701113E; Wed, 2 Feb 2022 08:46:38 -0800 (PST) Received: from [10.57.89.81] (unknown [10.57.89.81]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id EBA8C3F40C; Wed, 2 Feb 2022 08:46:36 -0800 (PST) Message-ID: Date: Wed, 2 Feb 2022 16:46:35 +0000 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.5.1 Subject: Re: [PATCH] hwtracing: coresight: Replace acpi_bus_get_device() To: "Rafael J. Wysocki" Cc: "Rafael J. Wysocki" , Alexander Shishkin , Mathieu Poirier , Mike Leach , Leo Yan , LKML , Linux ACPI References: <5790600.lOV4Wx5bFT@kreacher> From: Suzuki K Poulose In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 02/02/2022 13:44, Rafael J. Wysocki wrote: > On Wed, Feb 2, 2022 at 12:43 PM Suzuki K Poulose wrote: >> >> Hi Rafael >> >> On 01/02/2022 17:58, Rafael J. Wysocki wrote: >>> From: Rafael J. Wysocki >>> >>> Replace acpi_bus_get_device() that is going to be dropped with >>> acpi_fetch_acpi_dev(). >>> >>> No intentional functional impact. >>> >>> Signed-off-by: Rafael J. Wysocki >> >> >>> --- >>> drivers/hwtracing/coresight/coresight-platform.c | 8 ++++---- >>> 1 file changed, 4 insertions(+), 4 deletions(-) >>> >>> Index: linux-pm/drivers/hwtracing/coresight/coresight-platform.c >>> =================================================================== >>> --- linux-pm.orig/drivers/hwtracing/coresight/coresight-platform.c >>> +++ linux-pm/drivers/hwtracing/coresight/coresight-platform.c >>> @@ -626,7 +626,7 @@ static int acpi_coresight_parse_link(str >>> const union acpi_object *link, >>> struct coresight_connection *conn) >>> { >>> - int rc, dir; >>> + int dir; >>> const union acpi_object *fields; >>> struct acpi_device *r_adev; >>> struct device *rdev; >>> @@ -643,9 +643,9 @@ static int acpi_coresight_parse_link(str >>> fields[3].type != ACPI_TYPE_INTEGER) >>> return -EINVAL; >>> >>> - rc = acpi_bus_get_device(fields[2].reference.handle, &r_adev); >>> - if (rc) >>> - return rc; >>> + r_adev = acpi_fetch_acpi_dev(fields[2].reference.handle); >>> + if (!r_adev) >>> + return -ENODEV; >>> >> >> Is this patch part of a series ? > > No, it isn't. > >> I don't see acpi_fetch_acpi_dev() in v5.17-rc1, which our tree is based on at the moment. > > acpi_fetch_acpi_dev() is there in v5.17-rc1. Please see > > https://elixir.bootlin.com/linux/v5.17-rc1/A/ident/acpi_fetch_acpi_dev > >> Please could you point us to the changes ? >> >> Also do you expect to pull this via your tree ? > > I can route it via the ACPI tree, but it may as well be routed along > with other coresight-platform.c changes, if any. Apologies, obviously, I was looking at the wrong tree. I will queue this Thanks Suzuki