stm class: Fix device leak in open error path
Make sure to drop the reference taken by class_find_device() also on allocation errors in open(). Signed-off-by: Johan Hovold <johan@kernel.org> Fixes: 7bd1d409 ("stm class: Introduce an abstraction for...") Cc: stable@vger.kernel.org # v4.6+ Signed-off-by: Alexander Shishkin <alexander.shishkin@linux.intel.com>
Showing
Please register or sign in to comment