[ Upstream commit 53c59d66c4 ]
Curtrently the error path is unsynchronised with removal due to
regulator being disabled before other device managed resources
are handled. Correct that by wrapping regulator enablement in
the respective call.
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
Stable-dep-of: 7cef813a91 ("gpio: pca953x: log an error when failing to get the reset GPIO")
Signed-off-by: Sasha Levin <sashal@kernel.org>