Commit 47c9b85
committed
i3c_controller: non-sticky interrupt pending
Set interrupt pending on source signal rising edge, to allow clearing
it and then resolving, e.g.:
static irqreturn_t adi_i3c_controller_irq(int irq, void *data)
{
struct adi_i3c_controller *controller = data;
u32 pending;
pending = readl_relaxed(controller->regs + REG_IRQ_PENDING);
writel_relaxed(pending, controller->regs + REG_IRQ_PENDING);
if (pending & IRQ_PENDING_CMDR_PENDING) {
spin_lock(&controller->xferqueue.lock);
adi_i3c_controller_end_xfer_locked(controller, pending);
spin_unlock(&controller->xferqueue.lock);
}
if (pending & IRQ_PENDING_IBI_PENDING)
adi_i3c_controller_demux_ibis(controller);
if (pending & IRQ_PENDING_DAA_PENDING)
adi_i3c_controller_handle_da_req(controller);
return IRQ_HANDLED;
}
Signed-off-by: Jorge Marques <[email protected]>1 parent 28f6322 commit 47c9b85
File tree
1 file changed
+10
-14
lines changed- library/i3c_controller/i3c_controller_host_interface
1 file changed
+10
-14
lines changedLines changed: 10 additions & 14 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
126 | 126 | | |
127 | 127 | | |
128 | 128 | | |
129 | | - | |
130 | | - | |
131 | | - | |
132 | | - | |
133 | | - | |
| 129 | + | |
| 130 | + | |
| 131 | + | |
134 | 132 | | |
135 | 133 | | |
| 134 | + | |
136 | 135 | | |
137 | 136 | | |
138 | 137 | | |
| |||
522 | 521 | | |
523 | 522 | | |
524 | 523 | | |
525 | | - | |
526 | 524 | | |
527 | 525 | | |
528 | 526 | | |
529 | 527 | | |
530 | | - | |
| 528 | + | |
531 | 529 | | |
532 | 530 | | |
533 | 531 | | |
534 | 532 | | |
535 | 533 | | |
536 | 534 | | |
537 | | - | |
| 535 | + | |
538 | 536 | | |
539 | 537 | | |
540 | 538 | | |
541 | 539 | | |
542 | 540 | | |
543 | 541 | | |
544 | | - | |
| 542 | + | |
545 | 543 | | |
546 | 544 | | |
547 | 545 | | |
548 | 546 | | |
549 | 547 | | |
550 | 548 | | |
551 | | - | |
552 | | - | |
553 | | - | |
554 | | - | |
555 | | - | |
| 549 | + | |
| 550 | + | |
| 551 | + | |
556 | 552 | | |
557 | 553 | | |
558 | 554 | | |
| |||
0 commit comments