Lines Matching full:intc
49 struct s3c_irq_intc *intc; member
57 * @reg_intpnd special register intpnd in main intc
83 struct s3c_irq_intc *intc = irq_data->intc; in s3c_irq_mask() local
84 struct s3c_irq_intc *parent_intc = intc->parent; in s3c_irq_mask()
89 mask = readl_relaxed(intc->reg_mask); in s3c_irq_mask()
91 writel_relaxed(mask, intc->reg_mask); in s3c_irq_mask()
111 struct s3c_irq_intc *intc = irq_data->intc; in s3c_irq_unmask() local
112 struct s3c_irq_intc *parent_intc = intc->parent; in s3c_irq_unmask()
116 mask = readl_relaxed(intc->reg_mask); in s3c_irq_unmask()
118 writel_relaxed(mask, intc->reg_mask); in s3c_irq_unmask()
130 struct s3c_irq_intc *intc = irq_data->intc; in s3c_irq_ack() local
133 writel_relaxed(bitval, intc->reg_pending); in s3c_irq_ack()
134 if (intc->reg_intpnd) in s3c_irq_ack()
135 writel_relaxed(bitval, intc->reg_intpnd); in s3c_irq_ack()
299 struct s3c_irq_intc *intc = irq_data->intc; in s3c_irq_demux() local
308 offset = irq_domain_get_of_node(intc->domain) ? 32 : 0; in s3c_irq_demux()
327 static inline int s3c24xx_handle_intc(struct s3c_irq_intc *intc, in s3c24xx_handle_intc() argument
333 pnd = readl_relaxed(intc->reg_intpnd); in s3c24xx_handle_intc()
338 if (!irq_domain_get_of_node(intc->domain)) in s3c24xx_handle_intc()
348 offset = readl_relaxed(intc->reg_intpnd + 4); in s3c24xx_handle_intc()
357 generic_handle_domain_irq(intc->domain, intc_offset + offset); in s3c24xx_handle_intc()
432 struct s3c_irq_intc *intc = h->host_data; in s3c24xx_irq_map() local
433 struct s3c_irq_data *irq_data = &intc->irqs[hw]; in s3c24xx_irq_map()
439 irq_data->intc = intc; in s3c24xx_irq_map()
442 parent_intc = intc->parent; in s3c24xx_irq_map()
460 if (parent_intc || intc->reg_pending == S3C2416_SRCPND2) in s3c24xx_irq_map()
490 parent_irq_data->sub_intc = intc; in s3c24xx_irq_map()
512 static void s3c24xx_clear_intc(struct s3c_irq_intc *intc) in s3c24xx_clear_intc() argument
520 reg_source = intc->reg_intpnd ? intc->reg_intpnd : intc->reg_pending; in s3c24xx_clear_intc()
529 writel_relaxed(pend, intc->reg_pending); in s3c24xx_clear_intc()
530 if (intc->reg_intpnd) in s3c24xx_clear_intc()
531 writel_relaxed(pend, intc->reg_intpnd); in s3c24xx_clear_intc()
543 struct s3c_irq_intc *intc; in s3c24xx_init_intc() local
549 intc = kzalloc(sizeof(struct s3c_irq_intc), GFP_KERNEL); in s3c24xx_init_intc()
550 if (!intc) in s3c24xx_init_intc()
553 intc->irqs = irq_data; in s3c24xx_init_intc()
556 intc->parent = parent; in s3c24xx_init_intc()
564 pr_debug("irq: found main intc\n"); in s3c24xx_init_intc()
565 intc->reg_pending = base; in s3c24xx_init_intc()
566 intc->reg_mask = base + 0x08; in s3c24xx_init_intc()
567 intc->reg_intpnd = base + 0x10; in s3c24xx_init_intc()
573 intc->reg_pending = base + 0x18; in s3c24xx_init_intc()
574 intc->reg_mask = base + 0x1c; in s3c24xx_init_intc()
580 intc->reg_pending = base + 0x40; in s3c24xx_init_intc()
581 intc->reg_mask = base + 0x48; in s3c24xx_init_intc()
582 intc->reg_intpnd = base + 0x50; in s3c24xx_init_intc()
590 intc->reg_mask = base + 0xa4; in s3c24xx_init_intc()
591 intc->reg_pending = base + 0xa8; in s3c24xx_init_intc()
602 s3c24xx_clear_intc(intc); in s3c24xx_init_intc()
603 intc->domain = irq_domain_add_legacy(np, irq_num, irq_start, in s3c24xx_init_intc()
605 intc); in s3c24xx_init_intc()
606 if (!intc->domain) { in s3c24xx_init_intc()
614 return intc; in s3c24xx_init_intc()
617 kfree(intc); in s3c24xx_init_intc()
1166 struct s3c_irq_intc *intc = s3c_intc[ctrl_num]; in s3c24xx_irq_map_of() local
1167 struct s3c_irq_intc *parent_intc = intc->parent; in s3c24xx_irq_map_of()
1168 struct s3c_irq_data *irq_data = &intc->irqs[intc_hw]; in s3c24xx_irq_map_of()
1171 irq_data->intc = intc; in s3c24xx_irq_map_of()
1192 struct s3c_irq_intc *intc; in s3c24xx_irq_xlate_of() local
1205 intc = s3c_intc[intspec[0]]; in s3c24xx_irq_xlate_of()
1210 parent_intc = intc->parent; in s3c24xx_irq_xlate_of()
1212 irq_data = &intc->irqs[intspec[2]]; in s3c24xx_irq_xlate_of()
1215 parent_irq_data->sub_intc = intc; in s3c24xx_irq_xlate_of()
1248 struct s3c_irq_intc *intc; in s3c_init_intc_of() local
1272 intc = kzalloc(sizeof(struct s3c_irq_intc), GFP_KERNEL); in s3c_init_intc_of()
1273 if (!intc) in s3c_init_intc_of()
1276 intc->domain = domain; in s3c_init_intc_of()
1277 intc->irqs = kcalloc(32, sizeof(struct s3c_irq_data), in s3c_init_intc_of()
1279 if (!intc->irqs) { in s3c_init_intc_of()
1280 kfree(intc); in s3c_init_intc_of()
1285 intc->reg_pending = reg_base + ctrl->offset; in s3c_init_intc_of()
1286 intc->reg_mask = reg_base + ctrl->offset + 0x4; in s3c_init_intc_of()
1289 intc->parent = *(ctrl->parent); in s3c_init_intc_of()
1293 kfree(intc->irqs); in s3c_init_intc_of()
1294 kfree(intc); in s3c_init_intc_of()
1298 intc->reg_pending = reg_base + ctrl->offset; in s3c_init_intc_of()
1299 intc->reg_mask = reg_base + ctrl->offset + 0x08; in s3c_init_intc_of()
1300 intc->reg_intpnd = reg_base + ctrl->offset + 0x10; in s3c_init_intc_of()
1303 s3c24xx_clear_intc(intc); in s3c_init_intc_of()
1304 s3c_intc[i] = intc; in s3c_init_intc_of()
1314 .name = "intc",
1333 .name = "intc",