Johan Hovold d1d5c31fc3 rfkill: gpio: fix memory leak in probe error path
commit 4bf01ca21e2e0e4561d1a03c48c3d740418702db upstream.

Make sure to free the rfkill device in case registration fails during
probe.

Fixes: 5e7ca3937fbe ("net: rfkill: gpio: convert to resource managed allocation")
Cc: stable <stable@vger.kernel.org>	# 3.13
Cc: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Signed-off-by: Johan Hovold <johan@kernel.org>
Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2018-05-16 10:10:26 +02:00
..
2018-05-16 10:10:24 +02:00
2017-08-29 15:16:52 -07:00
2018-04-29 11:33:12 +02:00
2017-11-08 14:32:18 +09:00
2018-04-26 11:02:17 +02:00
2018-02-22 15:42:23 +01:00