return PTR_ERR(dpaux->vdd);
}
+
+ dpaux->vdd = NULL;
}
platform_set_drvdata(pdev, dpaux);
output->connector.polled = DRM_CONNECTOR_POLL_HPD;
dpaux->output = output;
- err = regulator_enable(dpaux->vdd);
- if (err < 0)
- return err;
-
if (output->panel) {
enum drm_connector_status status;
+ if (dpaux->vdd) {
+ err = regulator_enable(dpaux->vdd);
+ if (err < 0)
+ return err;
+ }
+
timeout = jiffies + msecs_to_jiffies(250);
while (time_before(jiffies, timeout)) {
disable_irq(dpaux->irq);
- err = regulator_disable(dpaux->vdd);
- if (err < 0)
- return err;
-
if (dpaux->output->panel) {
enum drm_connector_status status;
+ if (dpaux->vdd) {
+ err = regulator_disable(dpaux->vdd);
+ if (err < 0)
+ return err;
+ }
+
timeout = jiffies + msecs_to_jiffies(250);
while (time_before(jiffies, timeout)) {