All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/i915: Inject a failure point when registering a connector
@ 2018-10-10 11:50 Chris Wilson
  2018-10-10 12:07 ` Maarten Lankhorst
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Chris Wilson @ 2018-10-10 11:50 UTC (permalink / raw)
  To: intel-gfx; +Cc: Daniel Vetter

Check we can handle a late display load failure where the final act of
registering the connector fails.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Jani Nikula <jani.nikula@linux.intel.com>
Cc: Ville Syrjala <ville.syrjala@linux.intel.com>
Cc: Daniel Vetter <daniel.vetter@intel.com>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
---
 drivers/gpu/drm/i915/intel_display.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
index fd27b9b0b4d8..c24314da741b 100644
--- a/drivers/gpu/drm/i915/intel_display.c
+++ b/drivers/gpu/drm/i915/intel_display.c
@@ -15867,8 +15867,15 @@ int intel_connector_register(struct drm_connector *connector)
 	if (ret)
 		goto err;
 
+	if (i915_inject_load_failure()) {
+		ret = -EFAULT;
+		goto err_backlight;
+	}
+
 	return 0;
 
+err_backlight:
+	intel_backlight_device_unregister(intel_connector);
 err:
 	return ret;
 }
-- 
2.19.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

^ permalink raw reply related	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2018-10-10 12:29 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-10-10 11:50 [PATCH] drm/i915: Inject a failure point when registering a connector Chris Wilson
2018-10-10 12:07 ` Maarten Lankhorst
2018-10-10 12:10 ` Jani Nikula
2018-10-10 12:22   ` Chris Wilson
2018-10-10 12:29 ` ✓ Fi.CI.BAT: success for " Patchwork

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.