Back to home page

OSCL-LXR

 
 

    


0001 /* SPDX-License-Identifier: GPL-2.0 */
0002 /*
0003  * ARM Generic Interrupt Controller (GIC) private defines that's only
0004  * shared among the GIC library code.
0005  */
0006 
0007 #ifndef SELFTEST_KVM_GIC_PRIVATE_H
0008 #define SELFTEST_KVM_GIC_PRIVATE_H
0009 
0010 struct gic_common_ops {
0011     void (*gic_init)(unsigned int nr_cpus, void *dist_base);
0012     void (*gic_cpu_init)(unsigned int cpu, void *redist_base);
0013     void (*gic_irq_enable)(unsigned int intid);
0014     void (*gic_irq_disable)(unsigned int intid);
0015     uint64_t (*gic_read_iar)(void);
0016     void (*gic_write_eoir)(uint32_t irq);
0017     void (*gic_write_dir)(uint32_t irq);
0018     void (*gic_set_eoi_split)(bool split);
0019     void (*gic_set_priority_mask)(uint64_t mask);
0020     void (*gic_set_priority)(uint32_t intid, uint32_t prio);
0021     void (*gic_irq_set_active)(uint32_t intid);
0022     void (*gic_irq_clear_active)(uint32_t intid);
0023     bool (*gic_irq_get_active)(uint32_t intid);
0024     void (*gic_irq_set_pending)(uint32_t intid);
0025     void (*gic_irq_clear_pending)(uint32_t intid);
0026     bool (*gic_irq_get_pending)(uint32_t intid);
0027     void (*gic_irq_set_config)(uint32_t intid, bool is_edge);
0028 };
0029 
0030 extern const struct gic_common_ops gicv3_ops;
0031 
0032 #endif /* SELFTEST_KVM_GIC_PRIVATE_H */