[PATCH v3 0/1] platform/x86: serial-multi-instantiate: ACPI example code

Baojun Xu posted 1 patch 5 days, 14 hours ago
There is a newer version of this series
drivers/platform/x86/serial-multi-instantiate.c | 13 +++++++++----
1 file changed, 9 insertions(+), 4 deletions(-)
[PATCH v3 0/1] platform/x86: serial-multi-instantiate: ACPI example code
Posted by Baojun Xu 5 days, 14 hours ago
The tas2781-hda supports multi-projects, In some projects,
GpioInt was dropped due to no IRQ connection.
See the example code below:

But in smi_i2c_probe(), smi_spi_probe() (serial-multi-instantiate.c),
if looking for IRQ by smi_get_irq() fails, it will return an error,
will not add new device, and cause smi_probe to fail.
So need to add an exception case for these situations.
BTW, this patch will take effect on both I2C and SPI devices.

Device (SPKR)
{
    Name (_ADR, One)
    Name (_HID, "TXNW2781")
    Method (_CRS, 0, NotSerialized)
    {
        Name (RBUF, ResourceTemplate ()
        {
            I2cSerialBusV2 (0x0038, ...)
            I2cSerialBusV2 (0x0039, ...)
            // GpioInt (Edge, ...) { 0x0000 }
            //"GpioInt (...) {}" was commented out due to no IRQ connection.
        })
        Return (RBUF)
    }
}

Signed-off-by: Baojun Xu <baojun.xu@ti.com>

Baojun Xu (1):
  platform/x86: serial-multi-instantiate: Add IRQ_RESOURCE_OPT for IRQ
    missing projects

 drivers/platform/x86/serial-multi-instantiate.c | 13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)

-- 
2.25.1
Re: [PATCH v3 0/1] platform/x86: serial-multi-instantiate: ACPI example code
Posted by Andy Shevchenko 5 days, 11 hours ago
On Wed, Nov 26, 2025 at 04:17:40PM +0800, Baojun Xu wrote:
> The tas2781-hda supports multi-projects, In some projects,
> GpioInt was dropped due to no IRQ connection.

GpioInt()

> See the example code below:
> 
> But in smi_i2c_probe(), smi_spi_probe() (serial-multi-instantiate.c),
> if looking for IRQ by smi_get_irq() fails, it will return an error,
> will not add new device, and cause smi_probe to fail.

smi_probe()

> So need to add an exception case for these situations.
> BTW, this patch will take effect on both I2C and SPI devices.
> 
> Device (SPKR)
> {
>     Name (_ADR, One)
>     Name (_HID, "TXNW2781")
>     Method (_CRS, 0, NotSerialized)
>     {
>         Name (RBUF, ResourceTemplate ()
>         {
>             I2cSerialBusV2 (0x0038, ...)
>             I2cSerialBusV2 (0x0039, ...)
>             // GpioInt (Edge, ...) { 0x0000 }
>             //"GpioInt (...) {}" was commented out due to no IRQ connection.
>         })
>         Return (RBUF)
>     }
> }

And as Hans said, please fold this into the patch as part of the commit message.

-- 
With Best Regards,
Andy Shevchenko
Re: [PATCH v3 0/1] platform/x86: serial-multi-instantiate: ACPI example code
Posted by Hans de Goede 5 days, 14 hours ago
Hi Baojun Xu,

On 26-Nov-25 9:17 AM, Baojun Xu wrote:
> The tas2781-hda supports multi-projects, In some projects,
> GpioInt was dropped due to no IRQ connection.
> See the example code below:
> 
> But in smi_i2c_probe(), smi_spi_probe() (serial-multi-instantiate.c),
> if looking for IRQ by smi_get_irq() fails, it will return an error,
> will not add new device, and cause smi_probe to fail.
> So need to add an exception case for these situations.
> BTW, this patch will take effect on both I2C and SPI devices.
> 
> Device (SPKR)
> {
>     Name (_ADR, One)
>     Name (_HID, "TXNW2781")
>     Method (_CRS, 0, NotSerialized)
>     {
>         Name (RBUF, ResourceTemplate ()
>         {
>             I2cSerialBusV2 (0x0038, ...)
>             I2cSerialBusV2 (0x0039, ...)
>             // GpioInt (Edge, ...) { 0x0000 }
>             //"GpioInt (...) {}" was commented out due to no IRQ connection.
>         })
>         Return (RBUF)
>     }
> }
> 
> Signed-off-by: Baojun Xu <baojun.xu@ti.com>

Thank you, the patch itself looks good, but the above information
from the cover-letter really should be in the commit message of
the patch itself.

Can you please send a v4 with this info added to the commit
message ?

Regards,

Hans




> 
> Baojun Xu (1):
>   platform/x86: serial-multi-instantiate: Add IRQ_RESOURCE_OPT for IRQ
>     missing projects
> 
>  drivers/platform/x86/serial-multi-instantiate.c | 13 +++++++++----
>  1 file changed, 9 insertions(+), 4 deletions(-)
>