mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-09 05:39:54 -04:00
cnss2: Update bus bandwidth device tree config read
Fix out of bounds write during device tree bus bandwidth array copy. Change-Id: I5fa1be5beabdccc4d662c74018d8fa22c547697b Signed-off-by: Manikandan Mohan <manikand@codeaurora.org>
This commit is contained in:
parent
7b54b39b21
commit
7e1ba3ba5e
1 changed files with 1 additions and 1 deletions
|
|
@ -2263,7 +2263,7 @@ static int cnss_register_bus_scale(struct cnss_plat_data *plat_priv)
|
|||
}
|
||||
cfg_arr_size = plat_priv->icc.path_count *
|
||||
plat_priv->icc.bus_bw_cfg_count * CNSS_ICC_VOTE_MAX;
|
||||
cfg_arr = kzalloc(cfg_arr_size, GFP_KERNEL);
|
||||
cfg_arr = kcalloc(cfg_arr_size, sizeof(*cfg_arr), GFP_KERNEL);
|
||||
if (!cfg_arr) {
|
||||
cnss_pr_err("Failed to alloc cfg table mem\n");
|
||||
ret = -ENOMEM;
|
||||
|
|
|
|||
Loading…
Reference in a new issue