Well, not sure about that. During init on a platform which does not have+int irq_update_affinity_desc(unsigned int irq,Just a note on the return value, in the only current callsite -
+ struct irq_affinity_desc *affinity)
platform_get_irqs_affinity() - we don't check the return value and
propagate the error. This is because we don't want to fail the interrupt
init just because of problems updating the affinity mask. So I could
print a message to inform the user of error (at the callsite).
the issues with reservation mode there failure cases are:
1) Interrupt does not exist. Definitely a full fail
2) Interrupt is already started up. Not a good idea on init() and
a clear fail.
3) Interrupt has already been switched to managed. Double init is not
really a good sign either.
Duh yes.+ /* Requires the interrupt to be shut down */We're missing the unlock here, right?
+ if (irqd_is_started(&desc->irq_data))
More duh:)+ return -EBUSY;And here, and I figure that this should be irqd_affinity_is_managed()
+
+ /* Interrupts which are already managed cannot be modified */
+ if (irqd_is_managed(&desc->irq_data))
I assume you send a fixed variant of this.