1
0
Fork 0

MLK-17077 staging: typec: clear vbus change event in irq handler

For vbus change event, we need read the vbus status to clear
the alert. Current code do this in queue work, this has problem
on single core running, the queue work of vbus change may have
no chance to be scheduled as we continue receive the vbus change
event in threaded irq.

Acked-by: Peter Chen <peter.chen@nxp.com>
Signed-off-by: Li Jun <jun.li@nxp.com>
pull/10/head
Li Jun 2017-12-06 22:05:31 +08:00 committed by Jason Liu
parent ef4148dc62
commit c5500a2ee4
1 changed files with 3 additions and 0 deletions

View File

@ -547,6 +547,9 @@ static irqreturn_t tcpci_irq(int irq, void *dev_id)
tcpm_cc_change(tcpci->port);
if (status & TCPC_ALERT_POWER_STATUS) {
/* Read power status to clear the event */
regmap_read(tcpci->regmap, TCPC_POWER_STATUS, &reg);
regmap_read(tcpci->regmap, TCPC_POWER_STATUS_MASK, &reg);
/*