drm/i915: Rename plane_config to initial_plane_config
authorDamien Lespiau <damien.lespiau@intel.com>
Tue, 20 Jan 2015 12:51:52 +0000 (12:51 +0000)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Tue, 27 Jan 2015 08:51:04 +0000 (09:51 +0100)
This vfunc and related structure are only used for fast boot, so let's
rename them to not take them as general purpose ones.

v2: Fix conflicts caused by the introduction of struct intel_crtc_state

Reviewed-By: Tvrtko Ursulin <tvrtko.ursulin@intel.com> (v1)
Suggested-by: Daniel Vetter <daniel@ffwll.ch>
Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/i915_drv.h
drivers/gpu/drm/i915/intel_display.c
drivers/gpu/drm/i915/intel_drv.h
drivers/gpu/drm/i915/intel_fbdev.c

index dd1cdc81b15019ddaa28d55a94c210213ab677c4..56fd2b80f8afea7175c3ecfc58da400cab5f7c8d 100644 (file)
@@ -504,7 +504,7 @@ struct drm_i915_error_state {
 struct intel_connector;
 struct intel_encoder;
 struct intel_crtc_state;
-struct intel_plane_config;
+struct intel_initial_plane_config;
 struct intel_crtc;
 struct intel_limit;
 struct dpll;
@@ -543,8 +543,8 @@ struct drm_i915_display_funcs {
         * fills out the pipe-config with the hw state. */
        bool (*get_pipe_config)(struct intel_crtc *,
                                struct intel_crtc_state *);
-       void (*get_plane_config)(struct intel_crtc *,
-                                struct intel_plane_config *);
+       void (*get_initial_plane_config)(struct intel_crtc *,
+                                        struct intel_initial_plane_config *);
        int (*crtc_compute_clock)(struct intel_crtc *crtc,
                                  struct intel_crtc_state *crtc_state);
        void (*crtc_enable)(struct drm_crtc *crtc);
index 30d99017f6cca0e65421083ae31d771f8c4e4325..65fce56646b994715323394a628d65a24b9aea24 100644 (file)
@@ -2363,8 +2363,9 @@ static int skl_format_to_fourcc(int format, bool rgb_order, bool alpha)
        }
 }
 
-static bool intel_alloc_plane_obj(struct intel_crtc *crtc,
-                                 struct intel_plane_config *plane_config)
+static bool
+intel_alloc_plane_obj(struct intel_crtc *crtc,
+                     struct intel_initial_plane_config *plane_config)
 {
        struct drm_device *dev = crtc->base.dev;
        struct drm_i915_gem_object *obj = NULL;
@@ -2408,8 +2409,9 @@ out_unref_obj:
        return false;
 }
 
-static void intel_find_plane_obj(struct intel_crtc *intel_crtc,
-                                struct intel_plane_config *plane_config)
+static void
+intel_find_plane_obj(struct intel_crtc *intel_crtc,
+                    struct intel_initial_plane_config *plane_config)
 {
        struct drm_device *dev = intel_crtc->base.dev;
        struct drm_i915_private *dev_priv = dev->dev_private;
@@ -6571,8 +6573,9 @@ static void vlv_crtc_clock_get(struct intel_crtc *crtc,
        pipe_config->port_clock = clock.dot / 5;
 }
 
-static void i9xx_get_plane_config(struct intel_crtc *crtc,
-                                 struct intel_plane_config *plane_config)
+static void
+i9xx_get_initial_plane_config(struct intel_crtc *crtc,
+                             struct intel_initial_plane_config *plane_config)
 {
        struct drm_device *dev = crtc->base.dev;
        struct drm_i915_private *dev_priv = dev->dev_private;
@@ -7599,8 +7602,9 @@ static void skylake_get_pfit_config(struct intel_crtc *crtc,
        }
 }
 
-static void skylake_get_plane_config(struct intel_crtc *crtc,
-                                     struct intel_plane_config *plane_config)
+static void
+skylake_get_initial_plane_config(struct intel_crtc *crtc,
+                                struct intel_initial_plane_config *plane_config)
 {
        struct drm_device *dev = crtc->base.dev;
        struct drm_i915_private *dev_priv = dev->dev_private;
@@ -7691,8 +7695,9 @@ static void ironlake_get_pfit_config(struct intel_crtc *crtc,
        }
 }
 
-static void ironlake_get_plane_config(struct intel_crtc *crtc,
-                                     struct intel_plane_config *plane_config)
+static void
+ironlake_get_initial_plane_config(struct intel_crtc *crtc,
+                                 struct intel_initial_plane_config *plane_config)
 {
        struct drm_device *dev = crtc->base.dev;
        struct drm_i915_private *dev_priv = dev->dev_private;
@@ -12764,7 +12769,8 @@ static void intel_init_display(struct drm_device *dev)
 
        if (INTEL_INFO(dev)->gen >= 9) {
                dev_priv->display.get_pipe_config = haswell_get_pipe_config;
-               dev_priv->display.get_plane_config = skylake_get_plane_config;
+               dev_priv->display.get_initial_plane_config =
+                       skylake_get_initial_plane_config;
                dev_priv->display.crtc_compute_clock =
                        haswell_crtc_compute_clock;
                dev_priv->display.crtc_enable = haswell_crtc_enable;
@@ -12774,7 +12780,8 @@ static void intel_init_display(struct drm_device *dev)
                        skylake_update_primary_plane;
        } else if (HAS_DDI(dev)) {
                dev_priv->display.get_pipe_config = haswell_get_pipe_config;
-               dev_priv->display.get_plane_config = ironlake_get_plane_config;
+               dev_priv->display.get_initial_plane_config =
+                       ironlake_get_initial_plane_config;
                dev_priv->display.crtc_compute_clock =
                        haswell_crtc_compute_clock;
                dev_priv->display.crtc_enable = haswell_crtc_enable;
@@ -12784,7 +12791,8 @@ static void intel_init_display(struct drm_device *dev)
                        ironlake_update_primary_plane;
        } else if (HAS_PCH_SPLIT(dev)) {
                dev_priv->display.get_pipe_config = ironlake_get_pipe_config;
-               dev_priv->display.get_plane_config = ironlake_get_plane_config;
+               dev_priv->display.get_initial_plane_config =
+                       ironlake_get_initial_plane_config;
                dev_priv->display.crtc_compute_clock =
                        ironlake_crtc_compute_clock;
                dev_priv->display.crtc_enable = ironlake_crtc_enable;
@@ -12794,7 +12802,8 @@ static void intel_init_display(struct drm_device *dev)
                        ironlake_update_primary_plane;
        } else if (IS_VALLEYVIEW(dev)) {
                dev_priv->display.get_pipe_config = i9xx_get_pipe_config;
-               dev_priv->display.get_plane_config = i9xx_get_plane_config;
+               dev_priv->display.get_initial_plane_config =
+                       i9xx_get_initial_plane_config;
                dev_priv->display.crtc_compute_clock = i9xx_crtc_compute_clock;
                dev_priv->display.crtc_enable = valleyview_crtc_enable;
                dev_priv->display.crtc_disable = i9xx_crtc_disable;
@@ -12803,7 +12812,8 @@ static void intel_init_display(struct drm_device *dev)
                        i9xx_update_primary_plane;
        } else {
                dev_priv->display.get_pipe_config = i9xx_get_pipe_config;
-               dev_priv->display.get_plane_config = i9xx_get_plane_config;
+               dev_priv->display.get_initial_plane_config =
+                       i9xx_get_initial_plane_config;
                dev_priv->display.crtc_compute_clock = i9xx_crtc_compute_clock;
                dev_priv->display.crtc_enable = i9xx_crtc_enable;
                dev_priv->display.crtc_disable = i9xx_crtc_disable;
@@ -13175,8 +13185,8 @@ void intel_modeset_init(struct drm_device *dev)
                 * can even allow for smooth boot transitions if the BIOS
                 * fb is large enough for the active pipe configuration.
                 */
-               if (dev_priv->display.get_plane_config) {
-                       dev_priv->display.get_plane_config(crtc,
+               if (dev_priv->display.get_initial_plane_config) {
+                       dev_priv->display.get_initial_plane_config(crtc,
                                                           &crtc->plane_config);
                        /*
                         * If the fb is shared between multiple heads, we'll
index 7f7407af8c191708350b7baa3b02d90d55aef49f..e957d4d938e7f05f11bbd5bc50a7268d5abd233a 100644 (file)
@@ -257,7 +257,7 @@ struct intel_plane_state {
        bool hides_primary;
 };
 
-struct intel_plane_config {
+struct intel_initial_plane_config {
        unsigned int tiling;
        int size;
        u32 base;
@@ -468,7 +468,7 @@ struct intel_crtc {
        uint32_t cursor_size;
        uint32_t cursor_base;
 
-       struct intel_plane_config plane_config;
+       struct intel_initial_plane_config plane_config;
        struct intel_crtc_state *config;
        struct intel_crtc_state *new_config;
        bool new_enabled;
index ece702235b38aa14e5583f1261a95e08a5b02a68..3001a86746111f0045362161c8e5acdb6d78480a 100644 (file)
@@ -531,7 +531,7 @@ static bool intel_fbdev_init_bios(struct drm_device *dev,
        struct intel_framebuffer *fb = NULL;
        struct drm_crtc *crtc;
        struct intel_crtc *intel_crtc;
-       struct intel_plane_config *plane_config = NULL;
+       struct intel_initial_plane_config *plane_config = NULL;
        unsigned int max_size = 0;
 
        if (!i915.fastboot)