
A dynamic SMMU mapping created as part of an RPC call can potentially be removed by a parallel munmap ioctl call before the RPC call is complete, leading to SMMU faults. Maintain a ref-count that indicates that the mapping is being used by a pending RPC call and allow the mapping to be removed only if this count is 0. Change-Id: Ieb4ff6b298ff9c48953bc5b3539fdfe19a14b442 Acked-by: Santosh Sakore <ssakore@qti.qualcomm.com> Signed-off-by: Santosh Sakore <quic_ssakore@quicinc.com>