dt-bindings: net: nfc: s3fwrn5: Change I2C interrupt trigger type
authorBongsu Jeon <bongsu.jeon@samsung.com>
Tue, 8 Dec 2020 14:10:11 +0000 (23:10 +0900)
committerDavid S. Miller <davem@davemloft.net>
Thu, 10 Dec 2020 00:49:46 +0000 (16:49 -0800)
commitb783ff46ef4c80c666ed2186f471b7173db63976
treef0b7f75eb9b2cd114930e1281ec8f308da74462a
parente65f3df5ff38d0f77eabdffaf0c5b480a3a9422a
dt-bindings: net: nfc: s3fwrn5: Change I2C interrupt trigger type

Change interrupt trigger from IRQ_TYPE_LEVEL_HIGH to IRQ_TYPE_EDGE_RISING
 for stable NFC I2C interrupt handling.
Samsung's NFC Firmware sends an i2c frame as below.
1. NFC Firmware sets the GPIO(interrupt pin) high when there is an i2c
 frame to send.
2. If the CPU's I2C master has received the i2c frame, NFC F/W sets the
GPIO low.
NFC driver's i2c interrupt handler would be called in the abnormal case
as the NFC FW task of number 2 is delayed because of other high priority
tasks.
In that case, NFC driver will try to receive the i2c frame but there isn't
 any i2c frame to send in NFC.
It would cause an I2C communication problem. This case would hardly happen.
But, I changed the interrupt as a defense code.
If Driver uses the TRIGGER_RISING instead of the LEVEL trigger,
there would be no problem even if the NFC FW task is delayed.

Signed-off-by: Bongsu Jeon <bongsu.jeon@samsung.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Documentation/devicetree/bindings/net/nfc/samsung,s3fwrn5.yaml