Commit 61bc76be authored by Wei Yongjun's avatar Wei Yongjun Committed by Sudeep Holla

firmware: arm_scmi: optee: Fix missing mutex_init()

The driver allocates the mutex but not initialize it.
Use mutex_init() on it to initialize it correctly.

Link: https://lore.kernel.org/r/20211123083620.2366860-1-weiyongjun1@huawei.com
Fixes: 5f90f189 ("firmware: arm_scmi: Add optee transport")
Reported-by: default avatarHulk Robot <hulkci@huawei.com>
Reviewed-by: default avatarEtienne Carriere <etienne.carriere@linaro.org>
Signed-off-by: default avatarWei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: default avatarSudeep Holla <sudeep.holla@arm.com>
parent 530897ec
......@@ -506,6 +506,7 @@ static int scmi_optee_service_probe(struct device *dev)
agent->dev = dev;
agent->tee_ctx = tee_ctx;
INIT_LIST_HEAD(&agent->channel_list);
mutex_init(&agent->mu);
ret = get_capabilities(agent);
if (ret)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment