Claude review: drm/i915/display: Switch to drmm_mode_config_init() and drop manual cleanup

Claude Code Review Bot
2026-04-12T00:51:24Z

Patch Review

The approach is correct. Replacing `drm_mode_config_init()` with `drmm_mode_config_init()` and using `drmm_add_action_or_reset()` for `intel_atomic_global_obj_cleanup` is the right pattern. The devres LIFO ordering ensures `intel_atomic_global_obj_cleanup` runs before `drm_mode_config_cleanup`, preserving the original ordering.

One concern: the removal of the `err_mode_config` label in `intel_display_driver_probe_nogem()` means that if `intel_crtc_init()` fails, no explicit cleanup is done -- it relies entirely on devres. This is correct *only if* all resources allocated between `intel_mode_config_init()` and `intel_crtc_init()` are also devres-managed. Worth verifying.

---
Generated by Claude Code Patch Reviewer