Any non-stub implementation is going to have to do something here.
The related hook irq_end_none() is more complicated and has arch-specific
interactions with irq_ack_none(), so make it optional.
For PPC, introduce a stub irq_ack_none().
For ARM and x86, export the existing {ack,end}_none() helpers, gaining an irq_
prefix for consisntency with everything else in no_irq_type.
No functional change.
Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Julien Grall <jgrall@amazon.com>
Release-Acked-by: Oleksii Kurochko <oleksii.kurochko@gmail.com>
*/
bool irq_type_set_by_domain(const struct domain *d);
+void irq_end_none(struct irq_desc *irq);
+#define irq_end_none irq_end_none
+
#endif /* _ASM_HW_IRQ_H */
/*
* Local variables:
unsigned int virq;
};
-static void ack_none(struct irq_desc *irq)
+void irq_ack_none(struct irq_desc *irq)
{
printk("unexpected IRQ trap at irq %02x\n", irq->irq);
}
-static void end_none(struct irq_desc *irq)
+void irq_end_none(struct irq_desc *irq)
{
/*
* Still allow a CPU to end an interrupt if we receive a spurious
.shutdown = irq_shutdown_none,
.enable = irq_enable_none,
.disable = irq_disable_none,
- .ack = ack_none,
- .end = end_none
+ .ack = irq_ack_none,
+ .end = irq_end_none
};
static irq_desc_t irq_desc[NR_IRQS];
BUG_ON("unimplemented");
}
+void irq_ack_none(struct irq_desc *desc)
+{
+ BUG_ON("unimplemented");
+}
+
hw_irq_controller no_irq_type = {
.typename = "none",
.startup = irq_startup_none,
.shutdown = irq_shutdown_none,
.enable = irq_enable_none,
.disable = irq_disable_none,
+ .ack = irq_ack_none,
};
int arch_init_one_irq_desc(struct irq_desc *desc)
return 0;
}
-static void cf_check ack_none(struct irq_desc *desc)
+void cf_check irq_ack_none(struct irq_desc *desc)
{
ack_bad_irq(desc->irq);
}
irq_shutdown_none,
irq_enable_none,
irq_disable_none,
- ack_none,
+ irq_ack_none,
};
static vmask_t *irq_get_used_vector_mask(int irq)
#define irq_disable_none irq_actor_none
#define irq_enable_none irq_actor_none
+/*
+ * irq_ack_none() must be provided by the architecture.
+ * irq_end_none() is optional, and opted into using a define.
+ */
+void cf_check irq_ack_none(struct irq_desc *irq);
+
/*
* Per-cpu interrupted context register state - the inner-most interrupt frame
* on the stack.