Skip to content
Snippets Groups Projects
Commit 6e1b58bd authored by Jonas Höppner's avatar Jonas Höppner
Browse files

touch:scx0500633:Add missing cleanup code when probe routine exits with error

The regulator was left on in error case, but devm/regulator core
complained about it.
parent 616e83a7
No related branches found
No related tags found
1 merge request!94touch:scx0500633:Add missing cleanup code when probe routine exits with error
Pipeline #17055 passed with stages
in 23 minutes and 4 seconds
......@@ -774,6 +774,8 @@ err_unregister_device:
err_free_gpios:
touch_gpio_free(tsdata->gpios);
err_free_tsdata:
if(tsdata->regulator && !IS_ERR(tsdata->regulator))
regulator_disable(tsdata->regulator);
return error;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment