ANDROID: KVM: arm64: Cleanup fail path
When the driver fails to probe do the following:
- Some SMMUs might have been already probed, so unregister them.
- return 0, as the otherwise the kernel will re-use the module pages
which is not supported at the moment.
- Add missing goto, if the module loading failed
- Free the atomic_mc which can be a lot of memory.
At the moment the smmu array is not freed nor some of the resources
from the SMMU driver (stream tables) as there in remove operation
at EL2.
Bug: 277989609
Bug: 278749606
Change-Id: I8cf53ff957b4d39605fe78bbe6f929b3e8b0a28e
Signed-off-by:
Mostafa Saleh <smostafa@google.com>
Loading
Please sign in to comment