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 <kathiravan.thirumoorthy@oss.qualcomm.com> Link: https://lore.kernel.org/r/20251031-image-crm-part2-v2-1-c224c45c381a@oss.qualcomm.com Signed-off-by: Bjorn Andersson <andersson@kernel.org>
This commit is contained in:
committed by
Bjorn Andersson
parent
85d55d8cc3
commit
d403276969
@@ -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) {
|
||||
|
||||
Reference in New Issue
Block a user