mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-31 04:01:48 -04:00
rsi: consolidate kmalloc/memset 0 calls to kzalloc
This is an API consolidation only. The use of kmalloc + memset to 0 is equivalent to kzalloc. Signed-off-by: Nicholas Mc Guire <[email protected]> Signed-off-by: Kalle Valo <[email protected]>
This commit is contained in:
parent
7be0f5b5e1
commit
97d14b623c
1 changed files with 1 additions and 2 deletions
|
|
@ -1023,7 +1023,7 @@ static int rsi_send_auto_rate_request(struct rsi_common *common)
|
|||
return -ENOMEM;
|
||||
}
|
||||
|
||||
selected_rates = kmalloc(2 * RSI_TBL_SZ, GFP_KERNEL);
|
||||
selected_rates = kzalloc(2 * RSI_TBL_SZ, GFP_KERNEL);
|
||||
if (!selected_rates) {
|
||||
rsi_dbg(ERR_ZONE, "%s: Failed in allocation of mem\n",
|
||||
__func__);
|
||||
|
|
@ -1032,7 +1032,6 @@ static int rsi_send_auto_rate_request(struct rsi_common *common)
|
|||
}
|
||||
|
||||
memset(skb->data, 0, sizeof(struct rsi_auto_rate));
|
||||
memset(selected_rates, 0, 2 * RSI_TBL_SZ);
|
||||
|
||||
auto_rate = (struct rsi_auto_rate *)skb->data;
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue