Commit cd2bc19c authored by Franky Lin's avatar Franky Lin Committed by Kalle Valo

brcmfmac: check return for ARP ip setting iovar

The return value of iovar set function should be saved and checked.
Reviewed-by: default avatarPieter-Paul Giesberts <pieterpg@broadcom.com>
Reviewed-by: default avatarHante Meuleman <meuleman@broadcom.com>
Signed-off-by: default avatarFranky Lin <frankyl@broadcom.com>
Signed-off-by: default avatarArend van Spriel <arend@broadcom.com>
Signed-off-by: default avatarKalle Valo <kvalo@codeaurora.org>
parent 52f22fb2
...@@ -1039,16 +1039,16 @@ static int brcmf_inetaddr_changed(struct notifier_block *nb, ...@@ -1039,16 +1039,16 @@ static int brcmf_inetaddr_changed(struct notifier_block *nb,
return NOTIFY_OK; return NOTIFY_OK;
} }
for (i = 0; i < ARPOL_MAX_ENTRIES; i++) { for (i = 0; i < ARPOL_MAX_ENTRIES; i++) {
if (addr_table[i] != 0) { if (addr_table[i] == 0)
brcmf_fil_iovar_data_set(ifp, continue;
"arp_hostip", &addr_table[i], ret = brcmf_fil_iovar_data_set(ifp, "arp_hostip",
&addr_table[i],
sizeof(addr_table[i])); sizeof(addr_table[i]));
if (ret) if (ret)
brcmf_err("add arp ip err %d\n", brcmf_err("add arp ip err %d\n",
ret); ret);
} }
} }
}
break; break;
default: default:
break; break;
......
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