X86 platform drivers
 help / color / mirror / Atom feed
From: "Ilpo Järvinen" <ilpo.jarvinen@linux.intel.com>
To: Suma Hegde <suma.hegde@amd.com>
Cc: platform-driver-x86@vger.kernel.org,
	Hans de Goede <hdegoede@redhat.com>,
	 Naveen Krishna Chatradhi <naveenkrishna.chatradhi@amd.com>
Subject: Re: [PATCH 2/2] platform/x86/amd/hsmp: Split ACPI and non-ACPI code
Date: Mon, 10 Jun 2024 19:10:09 +0300 (EEST)	[thread overview]
Message-ID: <bfc3bc47-4ca9-9616-2248-5b02ef8fc044@linux.intel.com> (raw)
In-Reply-To: <20240607133405.1211929-3-suma.hegde@amd.com>

On Fri, 7 Jun 2024, Suma Hegde wrote:

> Separate the probes for ACPI and non-ACPI supported platforms.
> Provide a Kconfig option to select either the
> ACPI or the non-ACPI (platform device based driver).
> 
> This change is done to
>  - Keep the probes clean of the if else ladder
>  - Use dev_groups in platform driver structure, instead of using
>    devm_device_add_group()
>    + use is_visible() to enable the sysfs entries
> 
> Signed-off-by: Suma Hegde <suma.hegde@amd.com>
> Reviewed-by: Naveen Krishna Chatradhi <naveenkrishna.chatradhi@amd.com>

This will be quite tedious to review in the current form because it 
combines mass-moving of code with non-move changes. I'd expect it to be 
significantly easier to review if the existing functions would be copied 
1:1 to the respective files first and then another change does the actual 
separation.

You might need to add a few extra function prototypes into the header in 
the intermediate state but I believe it's still going to be huge win even 
if you'll need to remove some of those prototypes when the actual split 
commences in the second change.

A few general comments:

- EXPORTs should be namespaced.

- Directly include <> headers in the individual files .c, don't mass 
include them through "hsmp.h" as clearly they'll be different for 
ACPI/non-ACPI to some extent.

-- 
 i.


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

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-06-07 13:34 [PATCH 0/2] platform/x86/amd/hsmp: split ACPI, Non-ACPI code Suma Hegde
2024-06-07 13:34 ` [PATCH 1/2] platform/x86/amd/hsmp: Create hsmp/ directory Suma Hegde
2024-06-07 13:34 ` [PATCH 2/2] platform/x86/amd/hsmp: Split ACPI and non-ACPI code Suma Hegde
2024-06-10 16:10   ` Ilpo Järvinen [this message]

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=bfc3bc47-4ca9-9616-2248-5b02ef8fc044@linux.intel.com \
    --to=ilpo.jarvinen@linux.intel.com \
    --cc=hdegoede@redhat.com \
    --cc=naveenkrishna.chatradhi@amd.com \
    --cc=platform-driver-x86@vger.kernel.org \
    --cc=suma.hegde@amd.com \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox