forked from luck/tmp_suning_uos_patched
tty: serial: max310x: Remove explicit use of devm_kfree
There is no reason to explicitly call devm_kfree in probe or remove functions. Signed-off-by: Emil Goode <emilgoode@gmail.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
23e7c6a765
commit
fd7c81f864
@ -1198,7 +1198,6 @@ static int __devinit max310x_probe(struct spi_device *spi)
|
|||||||
|
|
||||||
err_out:
|
err_out:
|
||||||
dev_set_drvdata(dev, NULL);
|
dev_set_drvdata(dev, NULL);
|
||||||
devm_kfree(dev, s);
|
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
@ -1234,8 +1233,6 @@ static int __devexit max310x_remove(struct spi_device *spi)
|
|||||||
if (s->pdata->exit)
|
if (s->pdata->exit)
|
||||||
s->pdata->exit();
|
s->pdata->exit();
|
||||||
|
|
||||||
devm_kfree(dev, s);
|
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user