projects
/
linux.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
83dbeae
)
MLK-16013-12: staging: typec: tcpci: clear pending events before request irq
author
Li Jun
<jun.li@nxp.com>
Wed, 26 Jul 2017 16:19:55 +0000
(
00:19
+0800)
committer
Nitin Garg
<nitin.garg@nxp.com>
Mon, 19 Mar 2018 20:36:18 +0000
(15:36 -0500)
Clear all possible pending events before request irq.
Reviewed-by: Peter Chen <peter.chen@nxp.com>
Signed-off-by: Li Jun <jun.li@nxp.com>
drivers/staging/typec/tcpci.c
patch
|
blob
|
history
diff --git
a/drivers/staging/typec/tcpci.c
b/drivers/staging/typec/tcpci.c
index
2c847c6
..
2fddcad
100644
(file)
--- a/
drivers/staging/typec/tcpci.c
+++ b/
drivers/staging/typec/tcpci.c
@@
-498,7
+498,8
@@
static int tcpci_probe(struct i2c_client *client,
if (err < 0)
return err;
- /* Disable chip interrupts */
+ /* Clear and disable chip interrupts */
+ tcpci_write16(tcpci, TCPC_ALERT, 0xffff);
tcpci_write16(tcpci, TCPC_ALERT_MASK, 0);
err = devm_request_threaded_irq(tcpci->dev, client->irq, NULL,