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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id CA7B6C48BC4 for ; Mon, 19 Feb 2024 02:53:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:From:References:Cc:To: Subject:MIME-Version:Date:Message-ID:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=5eB9Gm6MX4UVG7ERKm4DDE0YHIqaNQfgeyCyl2aHh6Y=; b=uAxdGWzShv9z4f 4vcexBOummACgNG3D7EKMCW7x1zxhSfth2/41+ZDjSGaPY2QGgENIFqAR3Mb0ug8+YouWvMUmyjhs fw3Cf8GefffDCeg/e7xQVe3GCGlR+gSe0dZD0+VPhoPRWgwizH3A4JVp7EP+5ZLjcbtcMvSJ3yGq1 Sp0DhNwVtHoH6FP6QZ8/3gKMOJYTwmZoNlFw/3hcM/SqazbUNXxSGRzSUaW3IYHQD35lo0dO0JuHZ OY6qOsayCS8oV4WiyDx7GSEoBNLXqZod5g6T1EftnRQu48Xn6nSdb3vqVKbg8Cxzi0Ssb7zlLWJs9 OhVpjSA00exEVUtQE0Eg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rbtly-00000008uOr-3zUj; Mon, 19 Feb 2024 02:52:50 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rbtlu-00000008uOK-2QiB for linux-arm-kernel@lists.infradead.org; Mon, 19 Feb 2024 02:52:48 +0000 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 81CE4FEC; Sun, 18 Feb 2024 18:53:20 -0800 (PST) Received: from [10.162.43.127] (a077893.blr.arm.com [10.162.43.127]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id B10943F766; Sun, 18 Feb 2024 18:52:36 -0800 (PST) Message-ID: Date: Mon, 19 Feb 2024 08:22:33 +0530 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH V4 05/11] coresight: replicator: Move ACPI support from AMBA driver to platform driver Content-Language: en-US To: Suzuki K Poulose , linux-arm-kernel@lists.infradead.org Cc: Lorenzo Pieralisi , Sudeep Holla , Mike Leach , James Clark , Maxime Coquelin , Alexandre Torgue , linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org, coresight@lists.linaro.org, linux-stm32@st-md-mailman.stormreply.com References: <20240123054608.1790189-1-anshuman.khandual@arm.com> <20240123054608.1790189-6-anshuman.khandual@arm.com> From: Anshuman Khandual In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240218_185246_744612_14252CA6 X-CRM114-Status: GOOD ( 19.12 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org On 2/15/24 16:55, Suzuki K Poulose wrote: > On 15/02/2024 11:23, Suzuki K Poulose wrote: >> Hi Anshuman >> >> On 23/01/2024 05:46, Anshuman Khandual wrote: >>> Add support for the dynamic replicator device in the platform driver, which >>> can then be used on ACPI based platforms. This change would now allow >>> runtime power management for repliacator devices on ACPI based systems. >>> >>> The driver would try to enable the APB clock if available. Also, rename the >>> code to reflect the fact that it now handles both static and dynamic >>> replicators. >>> >>> Cc: Lorenzo Pieralisi >>> Cc: Sudeep Holla >>> Cc: Suzuki K Poulose >>> Cc: Mike Leach >>> Cc: James Clark >>> Cc: linux-acpi@vger.kernel.org >>> Cc: linux-arm-kernel@lists.infradead.org >>> Cc: linux-kernel@vger.kernel.org >>> Cc: coresight@lists.linaro.org >>> Tested-by: Sudeep Holla # Boot and driver probe only >>> Acked-by: Sudeep Holla # For ACPI related changes >>> Signed-off-by: Anshuman Khandual >> >> I think the patch is doing three different things: >> >> 1) Use new helper to register/remove AMBA/Platform drivers >> 2) Refactor replicator_probe() to make sure it can be reused for platform/amba driver, by moving the pm_runtime_put() to the callers. >> 3) Actually moving the ACPI driver to Platform driver >> >> While (1) and (3) are obvious, (2) gave me hard time to review this >> patch, without proper description. If you don't mind, are you able to >> split the patch and add proper description of the 3 changes mentioned >> above. >> > > You could even move (1) for all the existing drivers into a single patch > or even fold it with the patch that introduces the helpers. That way it There are only two existing coresight devices with both AMBA and platform drivers available i.e replicator and funnel. Such devices could use these new helpers right from the beginning. As you mentioned earlier such changes might be folded back into the patch adding the helpers. But coresight devices such as catu, tpiu, tmc, stm and debug don't have platform drivers to begin with. Hence the helpers could only be used in their respective patches adding platform drivers. > is cleaner and easier to review. And (2) & (3) could be in the same patch for each driver, but please add something in the description for (2). Please find the updated commit message here, does this look okay ? coresight: replicator: Move ACPI support from AMBA driver to platform driver Add support for the dynamic replicator device in the platform driver, which can then be used on ACPI based platforms. This change would now allow runtime power management for replicator devices on ACPI based systems. The driver would try to enable the APB clock if available. Also, rename the code to reflect the fact that it now handles both static and dynamic replicators. But first this refactors replicator_probe() making sure it can be used both for platform and AMBA drivers, by moving the pm_runtime_put() to the callers. _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel