commit | 388008bbd60ccf2787ebe053dd91ee92f275630f | [log] [tgz] |
---|---|---|
author | Uwe Kleine-König <u.kleine-koenig@pengutronix.de> | Fri Oct 05 21:48:30 2018 +0200 |
committer | Jonathan Cameron <Jonathan.Cameron@huawei.com> | Sun Oct 07 20:04:30 2018 +0100 |
tree | b7aeaf39d8e4d99edb678a841a2bf86662951ab9 | |
parent | 1afacfb0dfe9af88d8e831cfcfb8bda663cfc9b5 [diff] |
iio: ssp_sensors: don't manually free devm managed resources The charme of devm_* functions is that you don't need to care about them in the error path. In this case it is valid to just return NULL which makes the device fail to probe and then the two gpios and the allocated memory are freed automatically by the driver core. Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>