RE: [PATCH] iio: adc: ti-adc081c: Partial revert of removal of ACPI IDs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Andy,

This patch would affect the ADC function on AAEON x86 products: https://www.aaeon.com/en/p/developer-board-intel-11th-up-xtreme-i11, we need the ACPI ID to enable ADC device ADC081C

Thanks,

Kunyang

-----Original Message-----
From: Andy Shevchenko <andy.shevchenko@xxxxxxxxx>
Sent: Monday, October 4, 2021 12:28 AM
To: Jonathan Cameron <jic23@xxxxxxxxxx>
Cc: linux-iio <linux-iio@xxxxxxxxxxxxxxx>; Jonathan Cameron <Jonathan.Cameron@xxxxxxxxxx>; Kunyang Fan <Kunyang_Fan@xxxxxxxxxxxx>
Subject: Re: [PATCH] iio: adc: ti-adc081c: Partial revert of removal of ACPI IDs

On Sun, Oct 3, 2021 at 7:20 PM Jonathan Cameron <jic23@xxxxxxxxxx> wrote:
>
> From: Jonathan Cameron <Jonathan.Cameron@xxxxxxxxxx>
>
> Unfortuanately a non standards compliant ACPI ID is known to be

Unfortunately

> in the wild on some AAEON boards.
>
> Partly revert the removal of these IDs so that ADC081C will again work
> + add a comment to that affect for future reference.

affect?! Okay, you are native speaker.

...

> +#include <linux/acpi.h>

> +       if (ACPI_COMPANION(&client->dev)) {
> +               const struct acpi_device_id *ad_id;
> +
> +               ad_id = acpi_match_device(client->dev.driver->acpi_match_table,
> +                                         &client->dev);
> +               if (!ad_id)
> +                       return -ENODEV;
> +               model = &adcxx1c_models[ad_id->driver_data];
> +       } else {
> +               model = &adcxx1c_models[id->driver_data];
> +       }

Can we please use device_get_match_data() instead (with corresponding property.h inclusion instead of acpi.h)?
This may require adding driver_data to OF IDs.

--
With Best Regards,
Andy Shevchenko
<p></p>
===================================================================================================================================
This email and any attachments to it contain confidential information and are intended solely for the use of the individual to whom it is addressed.If you are not the intended recipient or receive it accidentally, please immediately notify the sender by e-mail and delete the message and any attachments from your computer system, and destroy all hard copies. If any, please be advised that any unauthorized disclosure, copying, distribution or any action taken or omitted in reliance on this, is illegal and prohibited. Furthermore, any views or opinions expressed are solely those of the author and do not represent those of ASUSTeK. Thank you for your cooperation.
===================================================================================================================================




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux