Commit ee44f98f authored by Junhao He's avatar Junhao He Committed by Zheng Zengkai
Browse files

coresight: ultrasoc-smb: Fix uninitialized before use buf_hw_base

stable inclusion
from stable-v6.6.7
commit c541d0edd82764017d69b78e479bf0db8acf8202
category: bugfix
bugzilla: https://gitee.com/openeuler/kernel/issues/I8SSQ4

Reference: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=c541d0edd82764017d69b78e479bf0db8acf8202



--------------------------------

[ Upstream commit 862c135bde8bc185e8aae2110374175e6a1b6ed5 ]

In smb_reset_buffer, the sdb->buf_hw_base variable is uninitialized
before use, which initializes it in smb_init_data_buffer. And the SMB
regiester are set in smb_config_inport.
So move the call after smb_config_inport.

Fixes: 06f5c292 ("drivers/coresight: Add UltraSoc System Memory Buffer driver")
Signed-off-by: default avatarJunhao He <hejunhao3@huawei.com>
Reviewed-by: default avatarJames Clark <james.clark@arm.com>
Signed-off-by: default avatarSuzuki K Poulose <suzuki.poulose@arm.com>
Link: https://lore.kernel.org/r/20231114133346.30489-4-hejunhao3@huawei.com


Signed-off-by: default avatarSasha Levin <sashal@kernel.org>
Signed-off-by: default avatarZheng Zengkai <zhengzengkai@huawei.com>
parent 06a82795
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment