From: Kathiravan Thirumoorthy Date: Fri, 31 Oct 2025 05:51:01 +0000 (+0530) Subject: soc: qcom: smem: drop the WARN_ON() on SMEM item validation X-Git-Tag: v6.19-rc1~98^2~4^2~6 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d403276969b2aae147f671506a6c69089587ddd7;p=thirdparty%2Flinux.git soc: qcom: smem: drop the WARN_ON() on SMEM item validation When a SMEM item is allocated or retrieved, sanity check on the SMEM item is performed and backtrace is printed if it is invalid. But there is no benefit in dumping that information in the logs. Lets drop it. Signed-off-by: Kathiravan Thirumoorthy Link: https://lore.kernel.org/r/20251031-image-crm-part2-v2-1-c224c45c381a@oss.qualcomm.com Signed-off-by: Bjorn Andersson --- diff --git a/drivers/soc/qcom/smem.c b/drivers/soc/qcom/smem.c index f4a4acfefba9a..fef840b545740 100644 --- a/drivers/soc/qcom/smem.c +++ b/drivers/soc/qcom/smem.c @@ -521,7 +521,7 @@ int qcom_smem_alloc(unsigned host, unsigned item, size_t size) return -EINVAL; } - if (WARN_ON(item >= __smem->item_count)) + if (item >= __smem->item_count) return -EINVAL; ret = hwspin_lock_timeout_irqsave(__smem->hwlock, @@ -694,7 +694,7 @@ void *qcom_smem_get(unsigned host, unsigned item, size_t *size) if (IS_ERR(__smem)) return __smem; - if (WARN_ON(item >= __smem->item_count)) + if (item >= __smem->item_count) return ERR_PTR(-EINVAL); if (host < SMEM_HOST_COUNT && __smem->partitions[host].virt_base) {