Lines Matching +full:im +full:-
1 // SPDX-License-Identifier: GPL-2.0-only
45 uint32_t im, mod, pol; in tb10x_irq_set_type() local
47 im = data->mask; in tb10x_irq_set_type()
51 mod = ab_irqctl_readreg(gc, AB_IRQCTL_SRC_MODE) | im; in tb10x_irq_set_type()
52 pol = ab_irqctl_readreg(gc, AB_IRQCTL_SRC_POLARITY) | im; in tb10x_irq_set_type()
56 pol ^= im; in tb10x_irq_set_type()
59 mod ^= im; in tb10x_irq_set_type()
64 mod ^= im; in tb10x_irq_set_type()
65 pol ^= im; in tb10x_irq_set_type()
72 __func__, data->irq); in tb10x_irq_set_type()
73 return -EBADR; in tb10x_irq_set_type()
81 ab_irqctl_writereg(gc, AB_IRQCTL_INT_STATUS, im); in tb10x_irq_set_type()
108 return -EINVAL; in of_tb10x_init_irq()
112 ictl->full_name)) { in of_tb10x_init_irq()
114 return -EBUSY; in of_tb10x_init_irq()
119 ret = -EBUSY; in of_tb10x_init_irq()
127 ret = -ENOMEM; in of_tb10x_init_irq()
134 2, ictl->name, handle_level_irq, in of_tb10x_init_irq()
143 gc = domain->gc->gc[0]; in of_tb10x_init_irq()
144 gc->reg_base = reg_base; in of_tb10x_init_irq()
146 gc->chip_types[0].type = IRQ_TYPE_LEVEL_MASK; in of_tb10x_init_irq()
147 gc->chip_types[0].chip.irq_mask = irq_gc_mask_clr_bit; in of_tb10x_init_irq()
148 gc->chip_types[0].chip.irq_unmask = irq_gc_mask_set_bit; in of_tb10x_init_irq()
149 gc->chip_types[0].chip.irq_set_type = tb10x_irq_set_type; in of_tb10x_init_irq()
150 gc->chip_types[0].regs.mask = AB_IRQCTL_INT_ENABLE; in of_tb10x_init_irq()
152 gc->chip_types[1].type = IRQ_TYPE_EDGE_BOTH; in of_tb10x_init_irq()
153 gc->chip_types[1].chip.name = gc->chip_types[0].chip.name; in of_tb10x_init_irq()
154 gc->chip_types[1].chip.irq_ack = irq_gc_ack_set_bit; in of_tb10x_init_irq()
155 gc->chip_types[1].chip.irq_mask = irq_gc_mask_clr_bit; in of_tb10x_init_irq()
156 gc->chip_types[1].chip.irq_unmask = irq_gc_mask_set_bit; in of_tb10x_init_irq()
157 gc->chip_types[1].chip.irq_set_type = tb10x_irq_set_type; in of_tb10x_init_irq()
158 gc->chip_types[1].regs.ack = AB_IRQCTL_INT_STATUS; in of_tb10x_init_irq()
159 gc->chip_types[1].regs.mask = AB_IRQCTL_INT_ENABLE; in of_tb10x_init_irq()
160 gc->chip_types[1].handler = handle_edge_irq; in of_tb10x_init_irq()
184 IRQCHIP_DECLARE(tb10x_intc, "abilis,tb10x-ictl", of_tb10x_init_irq);