All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>
To: Shyam Sundar S K <Shyam-sundar.S-k@amd.com>
Cc: Hans de Goede <hdegoede@redhat.com>,
	Sanket.Goswami@amd.com,  platform-driver-x86@vger.kernel.org
Subject: Re: [PATCH v3 04/13] platform/x86/amd/pmc: Invoke amd_pmc_s2d_init() Post Debugfs Registration
Date: Wed, 6 Nov 2024 12:35:03 +0200 (EET)	[thread overview]
Message-ID: <dc6f7140-2b0f-99f6-2514-6e3dc2eabe59@linux.intel.com> (raw)
In-Reply-To: <20241105173637.733589-5-Shyam-sundar.S-k@amd.com>

On Tue, 5 Nov 2024, Shyam Sundar S K wrote:

> Relocate the call to amd_pmc_s2d_init() to occur after the creation of the
> "amd_pmc" debugfs directory. This ensures that the driver's root debugfs
> directory is established beforehand.
> 
> Co-developed-by: Sanket Goswami <Sanket.Goswami@amd.com>
> Signed-off-by: Sanket Goswami <Sanket.Goswami@amd.com>
> Signed-off-by: Shyam Sundar S K <Shyam-sundar.S-k@amd.com>
> ---
>  drivers/platform/x86/amd/pmc/pmc.c | 8 ++++----
>  1 file changed, 4 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/platform/x86/amd/pmc/pmc.c b/drivers/platform/x86/amd/pmc/pmc.c
> index 58fdf044fd36..6ebb9123ba00 100644
> --- a/drivers/platform/x86/amd/pmc/pmc.c
> +++ b/drivers/platform/x86/amd/pmc/pmc.c
> @@ -822,10 +822,6 @@ static int amd_pmc_probe(struct platform_device *pdev)
>  	/* Get num of IP blocks within the SoC */
>  	amd_pmc_get_ip_info(dev);
>  
> -	err = amd_pmc_s2d_init(dev);
> -	if (err)
> -		goto err_pci_dev_put;
> -
>  	platform_set_drvdata(pdev, dev);
>  	if (IS_ENABLED(CONFIG_SUSPEND)) {
>  		err = acpi_register_lps0_dev(&amd_pmc_s2idle_dev_ops);
> @@ -836,6 +832,10 @@ static int amd_pmc_probe(struct platform_device *pdev)
>  	}
>  
>  	amd_pmc_dbgfs_register(dev);
> +	err = amd_pmc_s2d_init(dev);
> +	if (err)
> +		goto err_pci_dev_put;
> +
>  	if (IS_ENABLED(CONFIG_AMD_MP2_STB))
>  		amd_mp2_stb_init(dev);
>  	pm_report_max_hw_sleep(U64_MAX);
> 

My expectation was that this would be the first patch of the series and 
it would include the move of the if (enable_stb) block 
from amd_pmc_dbgfs_register() to amd_pmc_s2d_init().

(Patch 3 too can be incorporated into that same refactoring patch as long 
as you explain the reason for adding the return in the commit message).

Is that order not viable for some reason?

-- 
 i.


  reply	other threads:[~2024-11-06 10:35 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-11-05 17:36 [PATCH v3 00/13] platform/x86/amd/pmc: Updates to AMD PMC driver Shyam Sundar S K
2024-11-05 17:36 ` [PATCH v3 01/13] platform/x86/amd/pmc: Move STB functionality to a new file for better code organization Shyam Sundar S K
2024-11-05 17:36 ` [PATCH v3 02/13] platform/x86/amd/pmc: Relocate STB Debugfs to a New File Shyam Sundar S K
2024-11-05 17:36 ` [PATCH v3 03/13] platform/x86/amd/pmc: Skip Completing amd_pmc_s2d_init() on Older Platforms Shyam Sundar S K
2024-11-05 17:36 ` [PATCH v3 04/13] platform/x86/amd/pmc: Invoke amd_pmc_s2d_init() Post Debugfs Registration Shyam Sundar S K
2024-11-06 10:35   ` Ilpo Järvinen [this message]
2024-11-05 17:36 ` [PATCH v3 05/13] platform/x86/amd/pmc: Update function names to align with new STB file Shyam Sundar S K
2024-11-05 17:36 ` [PATCH v3 06/13] platform/x86/amd/pmc: Define enum for S2D/PMC msg_port Shyam Sundar S K
2024-11-06 10:08   ` Ilpo Järvinen
2024-11-05 17:36 ` [PATCH v3 07/13] platform/x86/amd/pmc: Isolate STB code changes to a new file Shyam Sundar S K
2024-11-05 17:36 ` [PATCH v3 08/13] platform/x86/amd/pmc: Introduce helper function to set proper string Shyam Sundar S K
2024-11-05 17:36 ` [PATCH v3 09/13] platform/x86/amd/pmc: Update IP information structure for newer SoCs Shyam Sundar S K
2024-11-05 19:00   ` Mario Limonciello
2024-11-06 10:14   ` Ilpo Järvinen
2024-11-07  5:28     ` Shyam Sundar S K
2024-11-05 17:36 ` [PATCH v3 10/13] platform/x86/amd/pmc: Use ARRAY_SIZE() to fill num_ips information Shyam Sundar S K
2024-11-05 18:58   ` Mario Limonciello
2024-11-05 17:36 ` [PATCH v3 11/13] platform/x86/amd/pmc: Update S2D message id for 1Ah Family 70h model Shyam Sundar S K
2024-11-05 17:36 ` [PATCH v3 12/13] platform/x86/amd/pmc: Add STB support for AMD Desktop variants Shyam Sundar S K
2024-11-05 17:36 ` [PATCH v3 13/13] MAINTAINERS: Change AMD PMC driver status to "Supported" Shyam Sundar S K

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=dc6f7140-2b0f-99f6-2514-6e3dc2eabe59@linux.intel.com \
    --to=ilpo.jarvinen@linux.intel.com \
    --cc=Sanket.Goswami@amd.com \
    --cc=Shyam-sundar.S-k@amd.com \
    --cc=hdegoede@redhat.com \
    --cc=platform-driver-x86@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.