Re: [PATCH 8/8] drm/i915: Remove redundant drm_connector_register_all()

Daniel Vetter
2016-06-21T13:28:32Z

On Tue, Jun 21, 2016 at 09:53:48AM +0100, Chris Wilson wrote:
> drm_connector_register_all() is now automatically called by
> drm_dev_register(), and so we no longer have to do so ourselves (via
> intel_modeset_register() after calling drm_dev_register()). Similarly
> for unregistering.
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>

Ok, they disappear again. Feel free to ignore my earlier comment. With the
other nitpicks fixed, on the entire series:

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>

> ---
> drivers/gpu/drm/i915/i915_dma.c | 2 --
> drivers/gpu/drm/i915/i915_drv.h | 2 --
> drivers/gpu/drm/i915/intel_display.c | 10 ----------
> 3 files changed, 14 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/i915_dma.c b/drivers/gpu/drm/i915/i915_dma.c
> index b6e7aab109d6..af77c18ee2de 100644
> --- a/drivers/gpu/drm/i915/i915_dma.c
> +++ b/drivers/gpu/drm/i915/i915_dma.c
> @@ -1403,7 +1403,6 @@ static void i915_driver_register(struct drm_i915_private *dev_priv)
> if (drm_dev_register(dev, 0) == 0) {
> i915_debugfs_register(dev_priv);
> i915_setup_sysfs(dev);
> - intel_modeset_register(dev_priv);
> } else
> DRM_ERROR("Failed to register driver for userspace access!\n");
>
> @@ -1440,7 +1439,6 @@ static void i915_driver_unregister(struct drm_i915_private *dev_priv)
> acpi_video_unregister();
> intel_opregion_unregister(dev_priv);
>
> - intel_modeset_unregister(dev_priv);
> i915_teardown_sysfs(dev_priv->dev);
> i915_debugfs_unregister(dev_priv);
> drm_dev_unregister(dev_priv->dev);
> diff --git a/drivers/gpu/drm/i915/i915_drv.h b/drivers/gpu/drm/i915/i915_drv.h
> index 20a82b6a050d..ac4fc5e6f14f 100644
> --- a/drivers/gpu/drm/i915/i915_drv.h
> +++ b/drivers/gpu/drm/i915/i915_drv.h
> @@ -3733,8 +3733,6 @@ extern void intel_modeset_init_hw(struct drm_device *dev);
> extern void intel_modeset_init(struct drm_device *dev);
> extern void intel_modeset_gem_init(struct drm_device *dev);
> extern void intel_modeset_cleanup(struct drm_device *dev);
> -extern void intel_modeset_register(struct drm_i915_private *dev_priv);
> -extern void intel_modeset_unregister(struct drm_i915_private *dev_priv);
> extern int intel_connector_register(struct drm_connector *);
> extern void intel_connector_unregister(struct drm_connector *);
> extern int intel_modeset_vga_set_state(struct drm_device *dev, bool state);
> diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c
> index 1557b00836fe..254a5679954f 100644
> --- a/drivers/gpu/drm/i915/intel_display.c
> +++ b/drivers/gpu/drm/i915/intel_display.c
> @@ -15546,16 +15546,6 @@ void intel_modeset_init_hw(struct drm_device *dev)
> intel_enable_gt_powersave(dev_priv);
> }
>
> -void intel_modeset_register(struct drm_i915_private *dev_priv)
> -{
> - drm_connector_register_all(dev_priv->dev);
> -}
> -
> -void intel_modeset_unregister(struct drm_i915_private *dev_priv)
> -{
> - drm_connector_unregister_all(dev_priv->dev);
> -}
> -
> /*
> * Calculate what we think the watermarks should be for the state we've read
> * out of the hardware and then immediately program those watermarks so that
> --
> 2.8.1
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx

--
Daniel Vetter
Software Engineer, Intel Corporation