Re: [PATCH 0/2] gpio: pca953x: Add interrupt mask support for pca953x chips

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

 



On Monday, October 17, 2022 7:31 PM, Andy Shevchenko wrote:
> At first glance I think this needs two prerequisite patches:
>
> 1) convert _TYPE from bits to plain numbers, so we will have room
>    for up to 16 types;
>
> 2) Introducing PCAL953X_TYPE.
>
> After this is done, the current series will be neater.

Thanks for the suggestions!

I have started implementing this change:

    * Convert _TYPE from bits to 4 bit integer

    * Define 4 chip types: PCA953X_TYPE, PCAL953X_TYPE,
                           PCAL653X_TYPE, PCA957X_TYPE

The PCA_PCAL bit is redundant, we know which chip is PCAL from their
chip type. Remove the PCA_PCAL bit and the PCA_LATCH_INT mask.

The now modified bits were also used in the acpi_device_id
initialization:

    static const struct acpi_device_id pca953x_acpi_ids[] = {
        { "INT3491", 16 | PCA953X_TYPE | PCA_LATCH_INT, },
        { }
    };
    MODULE_DEVICE_TABLE(acpi, pca953x_acpi_ids);

I do not understand what is happening in this snippet. 
What should be the id?

---
Best regards,
Levente



[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux