forked from luck/tmp_suning_uos_patched
net: clear heap allocation for ethtool_get_regs()
There is a conflict between commitb00916b1
anda77f5db3
. This patch resolves the conflict by clearing the heap allocation in ethtool_get_regs(). Cc: stable@kernel.org Signed-off-by: Eugene Teo <eugeneteo@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
d80bc0fd26
commit
b7c7d01aae
|
@ -817,7 +817,7 @@ static int ethtool_get_regs(struct net_device *dev, char __user *useraddr)
|
|||
if (regs.len > reglen)
|
||||
regs.len = reglen;
|
||||
|
||||
regbuf = vmalloc(reglen);
|
||||
regbuf = vzalloc(reglen);
|
||||
if (!regbuf)
|
||||
return -ENOMEM;
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user