Parcourir la source

msm: adsprpc: add warning log for non-ion buffer

Print non-ion buffer details as warning to help in size issues debugging.

Change-Id: Ib96af6d202620e06cd9ed15f2698f6eac5c3a444
Signed-off-by: Ramesh Nallagopu <[email protected]>
Ramesh Nallagopu il y a 1 an
Parent
commit
b92e5483d4
1 fichiers modifiés avec 4 ajouts et 0 suppressions
  1. 4 0
      dsp/adsprpc.c

+ 4 - 0
dsp/adsprpc.c

@@ -2560,6 +2560,10 @@ static int get_args(uint32_t kernel, struct smq_invoke_ctx *ctx)
 			err = -EFAULT;
 			goto bail;
 		}
+		if (templen > DEBUG_PRINT_SIZE_LIMIT)
+			ADSPRPC_WARN(
+				"user passed non ion buffer size %zu, mend 0x%llx mstart 0x%llx, sc 0x%x  handle 0x%x\n",
+				templen, mend, mstart, sc, ctx->handle);
 		copylen += templen;
 	}
 	totallen = ALIGN(totallen, BALIGN) + copylen;