summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristophe Ricard <christophe.ricard@gmail.com>2016-04-30 09:12:37 +0200
committerSamuel Ortiz <sameo@linux.intel.com>2016-05-04 01:28:47 +0200
commit2a196975058f94e184464b13b52d86752bccbbd4 (patch)
tree02eded1aaec8995a62fa06250d7624a9df293fce
parentde72dbc52c4141a6e3f31796499908d00816ad2e (diff)
downloadop-kernel-dev-2a196975058f94e184464b13b52d86752bccbbd4.zip
op-kernel-dev-2a196975058f94e184464b13b52d86752bccbbd4.tar.gz
nfc: st21nfca: i2c: Change ST21NFCA_GPIO_NAME_RESET to match DT
Since commit 10cf4899f8af ("gpiolib: tighten up ACPI legacy gpio lookups") If _DSD properties are available in an ACPI node, we are not allowed to fallback to _CRS data to retrieve gpio properties. This was causing us to fail if uicc-present and/or ese-present are defined. To be consistent with devicetree change ST_NCI_GPIO_NAME_RESET content to reset so that acpi_find_gpio in drivers/gpio/gpiolib.c will look for reset-gpios. In the mean time the ACPI table needs to be fixed as follow: Device (NFC1) { Name (_ADR, Zero) // _ADR: Address Name (_HID, "SMO2100") // _HID: Hardware ID Name (_CID, "SMO2100") // _CID: Compatible ID Name (_DDN, "SMO NFC") // _DDN: DOS Device Name Name (_UID, One) // _UID: Unique ID Method (_CRS, 0, NotSerialized) // _CRS: Current Resource Settings { Name (SBUF, ResourceTemplate () { I2cSerialBus (0x0008, ControllerInitiated, 400000, AddressingMode7Bit, "\\_SB.I2C7", 0x00, ResourceConsumer, ,) GpioInt (Edge, ActiveHigh, ExclusiveAndWake, PullNone, 0x0000, "\\_SB.GPO2", 0x00, ResourceConsumer, ,) { // Pin list 0x0001 } GpioIo (Exclusive, PullDefault, 0x0000, 0x0000, IoRestrictionOutputOnly, "\\_SB.GPO2", 0x00, ResourceConsumer, ,) { // Pin list 0x0002, } }) Name (_DSD, Package (0x02) { ToUUID ("daffd814-6eba-4d8c-8a91-bc9bbf4aa301") /* Device Properties for _DSD */, Package (0x03) { Package (0x02) { "uicc-present", 1 }, Package (0x02) { "ese-present", 1 }, Package (0x02) { "enable-gpios", Package(0x04) { ^NFC1, 1, 0, 0} }, } }) Return (SBUF) /* \_SB_.I2C7.NFC1._CRS.SBUF */ } Method (_STA, 0, NotSerialized) // _STA: Status { Return (0x0F) } } Signed-off-by: Christophe Ricard <christophe-h.ricard@st.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
-rw-r--r--drivers/nfc/st21nfca/i2c.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/nfc/st21nfca/i2c.c b/drivers/nfc/st21nfca/i2c.c
index 36645dc..179c0b8 100644
--- a/drivers/nfc/st21nfca/i2c.c
+++ b/drivers/nfc/st21nfca/i2c.c
@@ -62,7 +62,7 @@
#define ST21NFCA_HCI_I2C_DRIVER_NAME "st21nfca_hci_i2c"
-#define ST21NFCA_GPIO_NAME_EN "clf_enable"
+#define ST21NFCA_GPIO_NAME_EN "enable"
struct st21nfca_i2c_phy {
struct i2c_client *i2c_dev;
OpenPOWER on IntegriCloud