DDI warnings from ixgbe
We've seen warnings from DDI on some systems using ixgbe:
WARNING: ixgbe1: failed callback (action=0, ret=-1)
This is coming from DDI in response to the ixgbe interrupt resource management callback returning failure.
It seems the interrupt resource management callback can expected to be called at any time after being registered. In this case it returned failure because ixgbe wasn't started yet, which it doesn't handle. Also, the callback returns failure if it would be offered more interrupt resources to add than it can handle.
There is three things that need fixing here. First, if ixgbe receives more interrupts than it wants from the system, that is not an error. The manpage explicitly states that it doesn't have to use all interrupt resources it is offered. So don't return failure.
Second, move the registration of the callback to the end of attach(), after we set the bit indicating that we're fully initialized. Since the callback really is optional, don't fail the attach if registration fails.
And third, the callback itself should fail when ixgbe isn't initialized (which cannot happen now). Whether it's started or not can be handled easily.