Merge branch 'net-ipa-constrain-gsi-interrupts'
authorJakub Kicinski <kuba@kernel.org>
Sat, 7 Nov 2020 23:39:20 +0000 (15:39 -0800)
committerJakub Kicinski <kuba@kernel.org>
Sat, 7 Nov 2020 23:39:21 +0000 (15:39 -0800)
commit2d152760a9e024c5a639529e85fc05a3d198e2ce
tree817b3a9ae2d7f7485a2e57342022cd49722a8140
parentf8ae7bbec726f4d09ca19ecea45ea147b8801e10
parent8194be79fbbc36dae391b7d747ba58459687792a
Merge branch 'net-ipa-constrain-gsi-interrupts'

Alex Elder says:

====================
net: ipa: constrain GSI interrupts

The goal of this series is to more tightly control when GSI
interrupts are enabled.  This is a long-ish series, so I'll
describe it in parts.

The first patch is actually unrelated...  I forgot to include
it in my previous series (which exposed the GSI layer to the
IPA version).  It is a trivial comments-only update patch.

The second patch defers registering the GSI interrupt handler
until *after* all of the resources that handler touches have
been initialized.  In practice, we don't see this interrupt
that early, but this precludes an obvious problem.

The next two patches are simple changes.  The first just
trivially renames a field.  The second switches from using
constant mask values to using an enumerated type of bit
positions to represent each GSI interrupt type.

The rest implement the "real work."  First, all interrupts
are disabled at initialization time.  Next, we keep track of
a bitmask of enabled GSI interrupt types, updating it each
time we enable or disable one of them.  From there we have
a set of patches that one-by-one enable each interrupt type
only during the period it is required.  This includes allowing
a channel to generate IEOB interrupts only when it has been
enabled.  And finally, the last patch simplifies some code
now that all GSI interrupt types are handled uniformly.
====================

Link: https://lore.kernel.org/r/20201105181407.8006-1-elder@linaro.org
Signed-off-by: Jakub Kicinski <kuba@kernel.org>