OSDN Git Service

ASoC: rt5645: Add ACPI-defined GPIO for ECS EF20 series
authorChris Chiu <chiu@endlessos.org>
Mon, 11 Jan 2021 05:41:39 +0000 (13:41 +0800)
committerMark Brown <broonie@kernel.org>
Mon, 11 Jan 2021 14:03:08 +0000 (14:03 +0000)
commita4dae468cfdd90cdb08d96161482c23739dd636a
treec50c57b0d8f8e953e8a84e8012527ec9c8baf7c3
parent21f603482a6bdc4e7481f5a8e0e4b654d8d6e3a3
ASoC: rt5645: Add ACPI-defined GPIO for ECS EF20 series

Add the hp-detect gpio for ECS EF20 series laptops based on the
_CRS defined in DSDT table.

Method (_CRS, 0, NotSerialized)
{
  Name (SBUF, ResourceTemplate ()
  {
    I2cSerialBusV2 (0x001A, ControllerInitiated, 0x00061A80,
        AddressingMode7Bit, "\\_SB.PCI0.I2C2",
        0x00, ResourceConsumer, , Exclusive,
        )
    GpioInt (Edge, ActiveBoth, SharedAndWake, PullNone, 0x0000,
        "\\_SB.GPO3", 0x00, ResourceConsumer, ,
        )
        {   // Pin list
            0x004F
        }
    GpioIo (Shared, PullDefault, 0x0000, 0x0000, IoRestrictionInputOnly,
        "\\_SB.GPO3", 0x00, ResourceConsumer, ,
        )
        {   // Pin list
            0x004F
        }
  })
  Return (SBUF) /* \_SB_.PCI0.I2C2.RTK2._CRS.SBUF */
}

Signed-off-by: Chris Chiu <chiu@endlessos.org>
Link: https://lore.kernel.org/r/20210111054141.4668-3-chiu@endlessos.org
Signed-off-by: Mark Brown <broonie@kernel.org>
sound/soc/codecs/rt5645.c