drm: Remove unused arg from drm_fb_helper_init
authorPankaj Bharadiya <pankaj.laxminarayan.bharadiya@intel.com>
Thu, 5 Mar 2020 12:04:28 +0000 (17:34 +0530)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Fri, 6 Mar 2020 13:19:57 +0000 (14:19 +0100)
The max connector argument for drm_fb_helper_init() isn't used anymore
hence remove it.

All the drm_fb_helper_init() calls are modified with below sementic
patch.

@@
expression E1, E2, E3;
@@
-  drm_fb_helper_init(E1,E2, E3)
+  drm_fb_helper_init(E1,E2)

Signed-off-by: Pankaj Bharadiya <pankaj.laxminarayan.bharadiya@intel.com>
Reviewed-by: Emil Velikov <emil.velikov@collabora.com>
Reviewed-by: Thomas Zimmermann <tzimmermann@suse.de>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/20200305120434.111091-2-pankaj.laxminarayan.bharadiya@intel.com
13 files changed:
drivers/gpu/drm/amd/amdgpu/amdgpu_fb.c
drivers/gpu/drm/armada/armada_fbdev.c
drivers/gpu/drm/drm_fb_helper.c
drivers/gpu/drm/exynos/exynos_drm_fbdev.c
drivers/gpu/drm/gma500/framebuffer.c
drivers/gpu/drm/i915/display/intel_fbdev.c
drivers/gpu/drm/msm/msm_fbdev.c
drivers/gpu/drm/nouveau/nouveau_fbcon.c
drivers/gpu/drm/omapdrm/omap_fbdev.c
drivers/gpu/drm/radeon/radeon_fb.c
drivers/gpu/drm/rockchip/rockchip_drm_fbdev.c
drivers/gpu/drm/tegra/fb.c
include/drm/drm_fb_helper.h

index 2672dc64a3101a220e4e8b2cf4d1f6dbf3901b95..579d614c7b70b62d68ca51c5034ab1c1b281dc08 100644 (file)
@@ -336,8 +336,7 @@ int amdgpu_fbdev_init(struct amdgpu_device *adev)
        drm_fb_helper_prepare(adev->ddev, &rfbdev->helper,
                        &amdgpu_fb_helper_funcs);
 
-       ret = drm_fb_helper_init(adev->ddev, &rfbdev->helper,
-                                AMDGPUFB_CONN_LIMIT);
+       ret = drm_fb_helper_init(adev->ddev, &rfbdev->helper);
        if (ret) {
                kfree(rfbdev);
                return ret;
index ac8a78bfda032006ba0731bb69b2b8bdb96c5720..6254353c00ae3d7fdfdf9ede92a26d2fbfe02316 100644 (file)
@@ -129,7 +129,7 @@ int armada_fbdev_init(struct drm_device *dev)
 
        drm_fb_helper_prepare(dev, fbh, &armada_fb_helper_funcs);
 
-       ret = drm_fb_helper_init(dev, fbh, 1);
+       ret = drm_fb_helper_init(dev, fbh);
        if (ret) {
                DRM_ERROR("failed to initialize drm fb helper\n");
                goto err_fb_helper;
index 490a99de6ec1662f818e0ea2ae2a7bdf3a66ce4f..a9771de4d17e64816964c8a7244a46216814cd0e 100644 (file)
@@ -450,7 +450,6 @@ EXPORT_SYMBOL(drm_fb_helper_prepare);
  * drm_fb_helper_init - initialize a &struct drm_fb_helper
  * @dev: drm device
  * @fb_helper: driver-allocated fbdev helper structure to initialize
- * @max_conn_count: max connector count (not used)
  *
  * This allocates the structures for the fbdev helper with the given limits.
  * Note that this won't yet touch the hardware (through the driver interfaces)
@@ -463,8 +462,7 @@ EXPORT_SYMBOL(drm_fb_helper_prepare);
  * Zero if everything went ok, nonzero otherwise.
  */
 int drm_fb_helper_init(struct drm_device *dev,
-                      struct drm_fb_helper *fb_helper,
-                      int max_conn_count)
+                      struct drm_fb_helper *fb_helper)
 {
        int ret;
 
@@ -2125,7 +2123,7 @@ static int drm_fbdev_client_hotplug(struct drm_client_dev *client)
 
        drm_fb_helper_prepare(dev, fb_helper, &drm_fb_helper_generic_funcs);
 
-       ret = drm_fb_helper_init(dev, fb_helper, 0);
+       ret = drm_fb_helper_init(dev, fb_helper);
        if (ret)
                goto err;
 
index 647a1fd1d815b6135253caa3c70c5fbb15489cf0..5afecb6a30adde3cef6a347c4b17b9f66844ce61 100644 (file)
@@ -200,7 +200,7 @@ int exynos_drm_fbdev_init(struct drm_device *dev)
 
        drm_fb_helper_prepare(dev, helper, &exynos_drm_fb_helper_funcs);
 
-       ret = drm_fb_helper_init(dev, helper, MAX_CONNECTOR);
+       ret = drm_fb_helper_init(dev, helper);
        if (ret < 0) {
                DRM_DEV_ERROR(dev->dev,
                              "failed to initialize drm fb helper.\n");
index 1459076d1980232b012a6187b57415a9f3c058f5..fe892e1243db5740de077b759d2ae0b7ca1cd791 100644 (file)
@@ -513,7 +513,7 @@ int psb_fbdev_init(struct drm_device *dev)
 
        drm_fb_helper_prepare(dev, fb_helper, &psb_fb_helper_funcs);
 
-       ret = drm_fb_helper_init(dev, fb_helper, INTELFB_CONN_LIMIT);
+       ret = drm_fb_helper_init(dev, fb_helper);
        if (ret)
                goto free;
 
index b4ff772252369d746528b3ca97a7d4c608f13c99..66e94e6b9764e74e589fe8e31600ad72fe4dda2f 100644 (file)
@@ -453,7 +453,7 @@ int intel_fbdev_init(struct drm_device *dev)
        if (!intel_fbdev_init_bios(dev, ifbdev))
                ifbdev->preferred_bpp = 32;
 
-       ret = drm_fb_helper_init(dev, &ifbdev->helper, 4);
+       ret = drm_fb_helper_init(dev, &ifbdev->helper);
        if (ret) {
                kfree(ifbdev);
                return ret;
index db48867df47dd2a785b273bc4ead0b7aa7ec7ec5..b4f44146d9de240b714e92a7da7ba90ea0729b81 100644 (file)
@@ -160,7 +160,7 @@ struct drm_fb_helper *msm_fbdev_init(struct drm_device *dev)
 
        drm_fb_helper_prepare(dev, helper, &msm_fb_helper_funcs);
 
-       ret = drm_fb_helper_init(dev, helper, priv->num_connectors);
+       ret = drm_fb_helper_init(dev, helper);
        if (ret) {
                DRM_DEV_ERROR(dev->dev, "could not init fbdev: ret=%d\n", ret);
                goto fail;
index 0c5cdda3c336508eb74aba563decad1db63f9b84..21fc7c63e2f7024a31ed10dd01359f2ca1d74447 100644 (file)
@@ -558,7 +558,7 @@ nouveau_fbcon_init(struct drm_device *dev)
 
        drm_fb_helper_prepare(dev, &fbcon->helper, &nouveau_fbcon_helper_funcs);
 
-       ret = drm_fb_helper_init(dev, &fbcon->helper, 4);
+       ret = drm_fb_helper_init(dev, &fbcon->helper);
        if (ret)
                goto free;
 
index b06e5cbfd03afcef4a9f0e74a329490efcdf03dc..eba57ac31cc6e1a10b888e15a2c06d99dff0c386 100644 (file)
@@ -242,7 +242,7 @@ void omap_fbdev_init(struct drm_device *dev)
 
        drm_fb_helper_prepare(dev, helper, &omap_fb_helper_funcs);
 
-       ret = drm_fb_helper_init(dev, helper, priv->num_pipes);
+       ret = drm_fb_helper_init(dev, helper);
        if (ret)
                goto fail;
 
index ec0b7d6c994dc63bb69405c8fea0a2b2f6783410..85548cf2529afd72beffa310376a0caa5bb10f7b 100644 (file)
@@ -354,8 +354,7 @@ int radeon_fbdev_init(struct radeon_device *rdev)
        drm_fb_helper_prepare(rdev->ddev, &rfbdev->helper,
                              &radeon_fb_helper_funcs);
 
-       ret = drm_fb_helper_init(rdev->ddev, &rfbdev->helper,
-                                RADEONFB_CONN_LIMIT);
+       ret = drm_fb_helper_init(rdev->ddev, &rfbdev->helper);
        if (ret)
                goto free;
 
index 521fe42ac5e258560eeefcda9231f5a2af294187..6ad4cce17089e6d8b0c7af6168c8420f520d8065 100644 (file)
@@ -124,7 +124,7 @@ int rockchip_drm_fbdev_init(struct drm_device *dev)
 
        drm_fb_helper_prepare(dev, helper, &rockchip_drm_fb_helper_funcs);
 
-       ret = drm_fb_helper_init(dev, helper, ROCKCHIP_MAX_CONNECTOR);
+       ret = drm_fb_helper_init(dev, helper);
        if (ret < 0) {
                DRM_DEV_ERROR(dev->dev,
                              "Failed to initialize drm fb helper - %d.\n",
index 84f0e01e34284732422eebc807b364427d9cf411..feefe62be8dd4a358250a1660fdccb8c8414fae8 100644 (file)
@@ -314,7 +314,7 @@ static int tegra_fbdev_init(struct tegra_fbdev *fbdev,
        struct drm_device *drm = fbdev->base.dev;
        int err;
 
-       err = drm_fb_helper_init(drm, &fbdev->base, max_connectors);
+       err = drm_fb_helper_init(drm, &fbdev->base);
        if (err < 0) {
                dev_err(drm->dev, "failed to initialize DRM FB helper: %d\n",
                        err);
index 1c6633da0f91d694c69e00c913f2fc04e0c8d668..62e8dda6d1d16017e66d9c9e15ac33256021a89f 100644 (file)
@@ -213,8 +213,7 @@ drm_fb_helper_from_client(struct drm_client_dev *client)
 #ifdef CONFIG_DRM_FBDEV_EMULATION
 void drm_fb_helper_prepare(struct drm_device *dev, struct drm_fb_helper *helper,
                           const struct drm_fb_helper_funcs *funcs);
-int drm_fb_helper_init(struct drm_device *dev,
-                      struct drm_fb_helper *helper, int max_conn);
+int drm_fb_helper_init(struct drm_device *dev, struct drm_fb_helper *helper);
 void drm_fb_helper_fini(struct drm_fb_helper *helper);
 int drm_fb_helper_blank(int blank, struct fb_info *info);
 int drm_fb_helper_pan_display(struct fb_var_screeninfo *var,
@@ -279,8 +278,7 @@ static inline void drm_fb_helper_prepare(struct drm_device *dev,
 }
 
 static inline int drm_fb_helper_init(struct drm_device *dev,
-                      struct drm_fb_helper *helper,
-                      int max_conn)
+                      struct drm_fb_helper *helper)
 {
        /* So drivers can use it to free the struct */
        helper->dev = dev;