drm: Nuke drm_atomic_helper_plane_set_property
authorDaniel Vetter <daniel.vetter@ffwll.ch>
Tue, 25 Jul 2017 08:01:19 +0000 (10:01 +0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Tue, 8 Aug 2017 12:45:16 +0000 (14:45 +0200)
It's dead code, the core handles all this directly now. This also
allows us to unexport drm_atomic_plane_set_property.

Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
Cc: Liviu Dudau <liviu.dudau@arm.com>
Cc: Brian Starkey <brian.starkey@arm.com>
Cc: Mali DP Maintainers <malidp@foss.arm.com>
Cc: Boris Brezillon <boris.brezillon@free-electrons.com>
Cc: Daniel Vetter <daniel.vetter@intel.com>
Cc: Jani Nikula <jani.nikula@linux.intel.com>
Cc: Sean Paul <seanpaul@chromium.org>
Cc: David Airlie <airlied@linux.ie>
Cc: Inki Dae <inki.dae@samsung.com>
Cc: Joonyoung Shim <jy0922.shim@samsung.com>
Cc: Seung-Woo Kim <sw0312.kim@samsung.com>
Cc: Kyungmin Park <kyungmin.park@samsung.com>
Cc: Kukjin Kim <kgene@kernel.org>
Cc: Krzysztof Kozlowski <krzk@kernel.org>
Cc: Ben Skeggs <bskeggs@redhat.com>
Cc: Tomi Valkeinen <tomi.valkeinen@ti.com>
Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: Benjamin Gaignard <benjamin.gaignard@linaro.org>
Cc: Vincent Abriou <vincent.abriou@st.com>
Cc: Yannick Fertre <yannick.fertre@st.com>
Cc: Philippe Cornu <philippe.cornu@st.com>
Cc: Jyri Sarha <jsarha@ti.com>
Cc: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
Cc: Rongrong Zou <zourongrong@gmail.com>
Cc: Shawn Guo <shawn.guo@linaro.org>
Cc: Alexey Brodkin <abrodkin@synopsys.com>
Cc: Eric Engestrom <eric@engestrom.ch>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Rob Clark <robdclark@gmail.com>
Cc: Archit Taneja <architt@codeaurora.org>
Cc: linux-arm-kernel@lists.infradead.org
Cc: linux-samsung-soc@vger.kernel.org
Cc: intel-gfx@lists.freedesktop.org
Cc: nouveau@lists.freedesktop.org
Cc: linux-renesas-soc@vger.kernel.org
Cc: Thomas Hellstrom <thellstrom@vmware.com>
Cc: Maxime Ripard <maxime.ripard@free-electrons.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20170725080122.20548-6-daniel.vetter@ffwll.ch
Reviewed-by: Archit Taneja <architt@codeaurora.org>
Acked-by: Philippe Cornu <philippe.cornu@st.com>
Tested-by: Philippe Cornu <philippe.cornu@st.com>
Acked-by: Liviu Dudau <Liviu.Dudau@arm.com>
Acked-by: Vincent Abriou <vincent.abriou@st.com>
Reviewed-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Reviewed-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
20 files changed:
drivers/gpu/drm/arm/malidp_planes.c
drivers/gpu/drm/atmel-hlcdc/atmel_hlcdc_plane.c
drivers/gpu/drm/drm_atomic.c
drivers/gpu/drm/drm_atomic_helper.c
drivers/gpu/drm/exynos/exynos_drm_plane.c
drivers/gpu/drm/hisilicon/hibmc/hibmc_drm_de.c
drivers/gpu/drm/hisilicon/kirin/kirin_drm_ade.c
drivers/gpu/drm/i915/intel_display.c
drivers/gpu/drm/msm/mdp/mdp5/mdp5_plane.c
drivers/gpu/drm/nouveau/nv50_display.c
drivers/gpu/drm/omapdrm/omap_plane.c
drivers/gpu/drm/rcar-du/rcar_du_plane.c
drivers/gpu/drm/rcar-du/rcar_du_vsp.c
drivers/gpu/drm/sti/sti_cursor.c
drivers/gpu/drm/sti/sti_gdp.c
drivers/gpu/drm/sti/sti_hqvdp.c
drivers/gpu/drm/stm/ltdc.c
drivers/gpu/drm/tilcdc/tilcdc_plane.c
include/drm/drm_atomic.h
include/drm/drm_atomic_helper.h

index 60402e27882fafd1650b44735341052f99e2ee7b..94e7e3fa3408cf163fda7f81b40e76ca73ac4c96 100644 (file)
@@ -128,7 +128,6 @@ static void malidp_plane_atomic_print_state(struct drm_printer *p,
 static const struct drm_plane_funcs malidp_de_plane_funcs = {
        .update_plane = drm_atomic_helper_update_plane,
        .disable_plane = drm_atomic_helper_disable_plane,
-       .set_property = drm_atomic_helper_plane_set_property,
        .destroy = malidp_de_plane_destroy,
        .reset = malidp_plane_reset,
        .atomic_duplicate_state = malidp_duplicate_plane_state,
index 3a5317bbaaeaa4dec0b4e7a9b381695b0cac6147..703c2d13603fc8f6e8cbae7fb7e1ac7c8dafda8a 100644 (file)
@@ -1052,7 +1052,6 @@ static void atmel_hlcdc_plane_atomic_destroy_state(struct drm_plane *p,
 static const struct drm_plane_funcs layer_plane_funcs = {
        .update_plane = drm_atomic_helper_update_plane,
        .disable_plane = drm_atomic_helper_disable_plane,
-       .set_property = drm_atomic_helper_plane_set_property,
        .destroy = atmel_hlcdc_plane_destroy,
        .reset = atmel_hlcdc_plane_reset,
        .atomic_duplicate_state = atmel_hlcdc_plane_atomic_duplicate_state,
index 0fd14aff7adde7e59bedd43e4d522df41e2ecc4d..395438a7a576771bf6d9bb71f1d1924d14000a04 100644 (file)
@@ -713,7 +713,7 @@ EXPORT_SYMBOL(drm_atomic_get_plane_state);
  * RETURNS:
  * Zero on success, error code on failure
  */
-int drm_atomic_plane_set_property(struct drm_plane *plane,
+static int drm_atomic_plane_set_property(struct drm_plane *plane,
                struct drm_plane_state *state, struct drm_property *property,
                uint64_t val)
 {
@@ -770,7 +770,6 @@ int drm_atomic_plane_set_property(struct drm_plane *plane,
 
        return 0;
 }
-EXPORT_SYMBOL(drm_atomic_plane_set_property);
 
 /**
  * drm_atomic_plane_get_property - get property value from plane state
index 38a7edb4779bc5e565f67bc9c356a492a42d8816..73b76166d9054b09477dd7deeea465f15faa2e48 100644 (file)
@@ -2953,61 +2953,6 @@ out:
 }
 EXPORT_SYMBOL(drm_atomic_helper_resume);
 
-/**
- * drm_atomic_helper_plane_set_property - helper for plane properties
- * @plane: DRM plane
- * @property: DRM property
- * @val: value of property
- *
- * Provides a default plane set_property handler using the atomic driver
- * interface.
- *
- * RETURNS:
- * Zero on success, error code on failure
- */
-int
-drm_atomic_helper_plane_set_property(struct drm_plane *plane,
-                                   struct drm_property *property,
-                                   uint64_t val)
-{
-       struct drm_atomic_state *state;
-       struct drm_plane_state *plane_state;
-       int ret = 0;
-
-       state = drm_atomic_state_alloc(plane->dev);
-       if (!state)
-               return -ENOMEM;
-
-       /* ->set_property is always called with all locks held. */
-       state->acquire_ctx = plane->dev->mode_config.acquire_ctx;
-retry:
-       plane_state = drm_atomic_get_plane_state(state, plane);
-       if (IS_ERR(plane_state)) {
-               ret = PTR_ERR(plane_state);
-               goto fail;
-       }
-
-       ret = drm_atomic_plane_set_property(plane, plane_state,
-                       property, val);
-       if (ret)
-               goto fail;
-
-       ret = drm_atomic_commit(state);
-fail:
-       if (ret == -EDEADLK)
-               goto backoff;
-
-       drm_atomic_state_put(state);
-       return ret;
-
-backoff:
-       drm_atomic_state_clear(state);
-       drm_atomic_legacy_backoff(state);
-
-       goto retry;
-}
-EXPORT_SYMBOL(drm_atomic_helper_plane_set_property);
-
 /**
  * drm_atomic_helper_connector_set_property - helper for connector properties
  * @connector: DRM connector
index e5099bc9f21a0fcf23b57ded2671bdc40ec3ad9b..8de74009dee4f439bbf2306c254c95723a1ac1fd 100644 (file)
@@ -173,7 +173,6 @@ static struct drm_plane_funcs exynos_plane_funcs = {
        .update_plane   = drm_atomic_helper_update_plane,
        .disable_plane  = drm_atomic_helper_disable_plane,
        .destroy        = drm_plane_cleanup,
-       .set_property   = drm_atomic_helper_plane_set_property,
        .reset          = exynos_drm_plane_reset,
        .atomic_duplicate_state = exynos_drm_plane_duplicate_state,
        .atomic_destroy_state = exynos_drm_plane_destroy_state,
index bec0a8726c6baac4add6dfb11a9436f6fe5afa90..a956545774a39225702ac05243769ed7cc3e76af 100644 (file)
@@ -150,7 +150,6 @@ static const u32 channel_formats1[] = {
 static struct drm_plane_funcs hibmc_plane_funcs = {
        .update_plane   = drm_atomic_helper_update_plane,
        .disable_plane  = drm_atomic_helper_disable_plane,
-       .set_property = drm_atomic_helper_plane_set_property,
        .destroy = drm_plane_cleanup,
        .reset = drm_atomic_helper_plane_reset,
        .atomic_duplicate_state = drm_atomic_helper_plane_duplicate_state,
index 6e5fd4f29ccb3f5984ecf4f2a9465b15ba741d1f..39f7d15673ed9f03a7a1666135246dd77d3ff25f 100644 (file)
@@ -889,7 +889,6 @@ static const struct drm_plane_helper_funcs ade_plane_helper_funcs = {
 static struct drm_plane_funcs ade_plane_funcs = {
        .update_plane   = drm_atomic_helper_update_plane,
        .disable_plane  = drm_atomic_helper_disable_plane,
-       .set_property = drm_atomic_helper_plane_set_property,
        .destroy = drm_plane_cleanup,
        .reset = drm_atomic_helper_plane_reset,
        .atomic_duplicate_state = drm_atomic_helper_plane_duplicate_state,
index f6fbbceb0bac37006c620005c4bc0085cea77eca..684d653bfddb556b2fbb0c11edc201796fd475c2 100644 (file)
@@ -13599,7 +13599,6 @@ const struct drm_plane_funcs intel_plane_funcs = {
        .update_plane = drm_atomic_helper_update_plane,
        .disable_plane = drm_atomic_helper_disable_plane,
        .destroy = intel_plane_destroy,
-       .set_property = drm_atomic_helper_plane_set_property,
        .atomic_get_property = intel_plane_atomic_get_property,
        .atomic_set_property = intel_plane_atomic_set_property,
        .atomic_duplicate_state = intel_plane_duplicate_state,
@@ -13734,7 +13733,6 @@ static const struct drm_plane_funcs intel_cursor_plane_funcs = {
        .update_plane = intel_legacy_cursor_update,
        .disable_plane = drm_atomic_helper_disable_plane,
        .destroy = intel_plane_destroy,
-       .set_property = drm_atomic_helper_plane_set_property,
        .atomic_get_property = intel_plane_atomic_get_property,
        .atomic_set_property = intel_plane_atomic_set_property,
        .atomic_duplicate_state = intel_plane_duplicate_state,
index 61dfea791f3f90ef7a1de1ebf3a5d852cb4a0855..818244ac4a4b5f945361342aa4dfaa2a01cbc76b 100644 (file)
@@ -246,7 +246,6 @@ static const struct drm_plane_funcs mdp5_plane_funcs = {
                .update_plane = drm_atomic_helper_update_plane,
                .disable_plane = drm_atomic_helper_disable_plane,
                .destroy = mdp5_plane_destroy,
-               .set_property = drm_atomic_helper_plane_set_property,
                .atomic_set_property = mdp5_plane_atomic_set_property,
                .atomic_get_property = mdp5_plane_atomic_get_property,
                .reset = mdp5_plane_reset,
@@ -259,7 +258,6 @@ static const struct drm_plane_funcs mdp5_cursor_plane_funcs = {
                .update_plane = mdp5_update_cursor_plane_legacy,
                .disable_plane = drm_atomic_helper_disable_plane,
                .destroy = mdp5_plane_destroy,
-               .set_property = drm_atomic_helper_plane_set_property,
                .atomic_set_property = mdp5_plane_atomic_set_property,
                .atomic_get_property = mdp5_plane_atomic_get_property,
                .reset = mdp5_plane_reset,
index 762fb5b9b83b0803a783e019eec8fe34289868fa..5ed88e75c21ebdd0c61bab42b6d37432e146417a 100644 (file)
@@ -1055,7 +1055,6 @@ nv50_wndw = {
        .disable_plane = drm_atomic_helper_disable_plane,
        .destroy = nv50_wndw_destroy,
        .reset = nv50_wndw_reset,
-       .set_property = drm_atomic_helper_plane_set_property,
        .atomic_duplicate_state = nv50_wndw_atomic_duplicate_state,
        .atomic_destroy_state = nv50_wndw_atomic_destroy_state,
 };
index b92a8f1d01550a70099d822dad285d07a3c5b0e6..15e5d5d325c617b8cf00dc84dad5bf299897f24c 100644 (file)
@@ -235,7 +235,6 @@ static const struct drm_plane_funcs omap_plane_funcs = {
        .disable_plane = drm_atomic_helper_disable_plane,
        .reset = omap_plane_reset,
        .destroy = omap_plane_destroy,
-       .set_property = drm_atomic_helper_plane_set_property,
        .atomic_duplicate_state = drm_atomic_helper_plane_duplicate_state,
        .atomic_destroy_state = drm_atomic_helper_plane_destroy_state,
        .atomic_set_property = omap_plane_atomic_set_property,
index 2b02eccbfb709f97f1a3b59c7ae10a445cc07d7e..5a79674986282c054024a683b10bb48594f11661 100644 (file)
@@ -698,7 +698,6 @@ static const struct drm_plane_funcs rcar_du_plane_funcs = {
        .update_plane = drm_atomic_helper_update_plane,
        .disable_plane = drm_atomic_helper_disable_plane,
        .reset = rcar_du_plane_reset,
-       .set_property = drm_atomic_helper_plane_set_property,
        .destroy = drm_plane_cleanup,
        .atomic_duplicate_state = rcar_du_plane_atomic_duplicate_state,
        .atomic_destroy_state = rcar_du_plane_atomic_destroy_state,
index 7362d80d236b8af4892ad240a21984908af1a8ba..4e46e479e9613c637450d921c457a1530bb696fa 100644 (file)
@@ -383,7 +383,6 @@ static const struct drm_plane_funcs rcar_du_vsp_plane_funcs = {
        .update_plane = drm_atomic_helper_update_plane,
        .disable_plane = drm_atomic_helper_disable_plane,
        .reset = rcar_du_vsp_plane_reset,
-       .set_property = drm_atomic_helper_plane_set_property,
        .destroy = drm_plane_cleanup,
        .atomic_duplicate_state = rcar_du_vsp_plane_atomic_duplicate_state,
        .atomic_destroy_state = rcar_du_vsp_plane_atomic_destroy_state,
index f31cbe898eb33884510566936c09503694aa7ec8..b709ebbec09589f138f9ba7de3cf9bfcbc1856bd 100644 (file)
@@ -348,7 +348,6 @@ static const struct drm_plane_funcs sti_cursor_plane_helpers_funcs = {
        .update_plane = drm_atomic_helper_update_plane,
        .disable_plane = drm_atomic_helper_disable_plane,
        .destroy = sti_cursor_destroy,
-       .set_property = drm_atomic_helper_plane_set_property,
        .reset = sti_plane_reset,
        .atomic_duplicate_state = drm_atomic_helper_plane_duplicate_state,
        .atomic_destroy_state = drm_atomic_helper_plane_destroy_state,
index dceedbe702d77eb0884f821161f96cf9c8b30cf4..b65eea4f2c973ea9b416ac275a08f00cf3496cda 100644 (file)
@@ -895,7 +895,6 @@ static const struct drm_plane_funcs sti_gdp_plane_helpers_funcs = {
        .update_plane = drm_atomic_helper_update_plane,
        .disable_plane = drm_atomic_helper_disable_plane,
        .destroy = sti_gdp_destroy,
-       .set_property = drm_atomic_helper_plane_set_property,
        .reset = sti_plane_reset,
        .atomic_duplicate_state = drm_atomic_helper_plane_duplicate_state,
        .atomic_destroy_state = drm_atomic_helper_plane_destroy_state,
index f112308531162c476b3cf7d384ba0bd13dadfe0e..b19b3430b2962d1d9c25b46bc3341f13827fc015 100644 (file)
@@ -1276,7 +1276,6 @@ static const struct drm_plane_funcs sti_hqvdp_plane_helpers_funcs = {
        .update_plane = drm_atomic_helper_update_plane,
        .disable_plane = drm_atomic_helper_disable_plane,
        .destroy = sti_hqvdp_destroy,
-       .set_property = drm_atomic_helper_plane_set_property,
        .reset = sti_plane_reset,
        .atomic_duplicate_state = drm_atomic_helper_plane_duplicate_state,
        .atomic_destroy_state = drm_atomic_helper_plane_destroy_state,
index 059769a096d9ffa7b790dc8c37ae031da33b92e7..d394a03632c450e011744c1cf10cc931ea396b01 100644 (file)
@@ -685,7 +685,6 @@ static const struct drm_plane_funcs ltdc_plane_funcs = {
        .update_plane = drm_atomic_helper_update_plane,
        .disable_plane = drm_atomic_helper_disable_plane,
        .destroy = drm_plane_cleanup,
-       .set_property = drm_atomic_helper_plane_set_property,
        .reset = drm_atomic_helper_plane_reset,
        .atomic_duplicate_state = drm_atomic_helper_plane_duplicate_state,
        .atomic_destroy_state = drm_atomic_helper_plane_destroy_state,
index ba0d66c0d8ac8965056026354b5a591e3f6dd210..7667b038ae7fec5162aa392a8c1f2c6882d67c09 100644 (file)
@@ -28,7 +28,6 @@ static struct drm_plane_funcs tilcdc_plane_funcs = {
        .update_plane   = drm_atomic_helper_update_plane,
        .disable_plane  = drm_atomic_helper_disable_plane,
        .destroy        = drm_plane_cleanup,
-       .set_property   = drm_atomic_helper_plane_set_property,
        .reset          = drm_atomic_helper_plane_reset,
        .atomic_duplicate_state = drm_atomic_helper_plane_duplicate_state,
        .atomic_destroy_state = drm_atomic_helper_plane_destroy_state,
index a7adbf57b8864220ce01a75dcee7139dc18ddbab..7d0d110f911d57dc1b20bcb48b283222d8e4312b 100644 (file)
@@ -315,9 +315,6 @@ int drm_atomic_crtc_set_property(struct drm_crtc *crtc,
 struct drm_plane_state * __must_check
 drm_atomic_get_plane_state(struct drm_atomic_state *state,
                           struct drm_plane *plane);
-int drm_atomic_plane_set_property(struct drm_plane *plane,
-               struct drm_plane_state *state, struct drm_property *property,
-               uint64_t val);
 struct drm_connector_state * __must_check
 drm_atomic_get_connector_state(struct drm_atomic_state *state,
                               struct drm_connector *connector);
index e5c835d94540c40333b3e7e59e5ea59161fb2946..a62aeb816dd8acb1971102a283d003a1c84e7e23 100644 (file)
@@ -124,9 +124,6 @@ int drm_atomic_helper_commit_duplicated_state(struct drm_atomic_state *state,
 int drm_atomic_helper_resume(struct drm_device *dev,
                             struct drm_atomic_state *state);
 
-int drm_atomic_helper_plane_set_property(struct drm_plane *plane,
-                                       struct drm_property *property,
-                                       uint64_t val);
 int drm_atomic_helper_connector_set_property(struct drm_connector *connector,
                                        struct drm_property *property,
                                        uint64_t val);