Commit 79b444fa authored by Stepan Moskovchenko's avatar Stepan Moskovchenko
Browse files

ks8851: Fix freed memory reference in probe failure



If ks8851_probe fails, deregister the regulator devices,
which are part of the ks structure, before freeing the
network device rather than dereferencing a freed pointer.
The regulator devices need to be deregistered before the
network device is freed because the private pointer (ks)
is part of the ndev structure.

Change-Id: Id8e7b25e26dbae2c038f6f018931fc25efbf5cff
Signed-off-by: default avatarStepan Moskovchenko <stepanm@codeaurora.org>
parent f9f07c34
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment