• Alex Elder's avatar
    net: ipa: add driver shutdown callback · ae1d72f9
    Alex Elder authored
    A system shutdown can happen at essentially any time, and it's
    possible that the IPA driver is busy when a shutdown is underway.
    IPA hardware accesses IMEM and SMEM memory regions using an IOMMU,
    and at some point during shutdown, needed I/O mappings could become
    invalid.  This could be disastrous for any "in flight" IPA activity.
    
    Avoid this by defining a new driver shutdown callback that stops all
    IPA activity and cleanly shuts down the driver.  It merely calls the
    driver's existing remove callback, reporting the error if it returns
    one.
    Signed-off-by: default avatarAlex Elder <elder@linaro.org>
    Signed-off-by: default avatarJakub Kicinski <kuba@kernel.org>
    ae1d72f9
ipa_main.c 25.9 KB