Re: [PATCH 11/14] acpi: disable battery and adapter for x86 apple machines

From: Andy Shevchenko

Date: Fri Dec 04 2026 - 12:15:10 EST


On Fri, Dec 04, 2026 at 08:26:48PM +0530, Aditya Garg wrote:
> On 04-Dec-26 07:38 PM, Andy Shevchenko wrote:
> > On Fri, Dec 04, 2026 at 08:12:51AM -0500, Atharva Tiwari wrote:

...

> >> + if (IS_ENABLED(CONFIG_MACSMC_ACPI) &&
> >> + IS_ENABLED(CONFIG_MACSMC_POWER) && x86_apple_machine)
> >> + return -ENODEV;
> >
> > This is a hack. And it's even indented wrongly.
>
> Do you have a better idea to avoid using duplicate devices?

The commit message is poorly written to advice anything.
It's unclear why we have duplicate drivers for the same ACPI HID to begin with.
Can MAC case be enumerated differently? When the SMS driver is not compiled
this one is still in use, why is it not a problem? So, there are many unaswered
questions...

--
With Best Regards,
Andy Shevchenko