--- initial
+++ final
@@ -1,91 +1,91 @@
 int rcar_du_modeset_init(struct rcar_du_device *rcdu) {
   static const unsigned int mmio_offsets[] = {DU0_REG_OFFSET, DU2_REG_OFFSET};
   struct drm_device *dev = rcdu->ddev;
   struct drm_encoder *encoder;
   struct drm_fbdev_cma *fbdev;
   unsigned int num_encoders;
   unsigned int num_groups;
   unsigned int i;
   int ret;
   drm_mode_config_init(dev);
   dev->mode_config.min_width = 0;
   dev->mode_config.min_height = 0;
   dev->mode_config.max_width = 4095;
   dev->mode_config.max_height = 2047;
   dev->mode_config.funcs = &rcar_du_mode_config_funcs;
   rcdu->num_crtcs = rcdu->info->num_crtcs;
   ret = rcar_du_properties_init(rcdu);
   if (ret < 0) return ret;
   /* Initialize vertical blanking interrupts handling. Start with vblank
    * disabled for all CRTCs.
    */
   ret = drm_vblank_init(dev, (1 << rcdu->info->num_crtcs) - 1);
   if (ret < 0) return ret;
   /* Initialize the groups. */
   num_groups = DIV_ROUND_UP(rcdu->num_crtcs, 2);
   for (i = 0; i < num_groups; ++i) {
     struct rcar_du_group *rgrp = &rcdu->groups[i];
     mutex_init(&rgrp->lock);
     rgrp->dev = rcdu;
     rgrp->mmio_offset = mmio_offsets[i];
     rgrp->index = i;
     rgrp->num_crtcs = min(rcdu->num_crtcs - 2 * i, 2U);
     /* If we have more than one CRTCs in this group pre-associate
      * the low-order planes with CRTC 0 and the high-order planes
      * with CRTC 1 to minimize flicker occurring when the
      * association is changed.
      */
     rgrp->dptsr_planes = rgrp->num_crtcs > 1 ? (rcdu->info->gen >= 3 ? 0x04 : 0xf0) : 0;
     if (!rcar_du_has(rcdu, RCAR_DU_FEATURE_VSP1_SOURCE)) {
       ret = rcar_du_planes_init(rgrp);
       if (ret < 0) return ret;
     }
   }
   /* Initialize the compositors. */
   if (rcar_du_has(rcdu, RCAR_DU_FEATURE_VSP1_SOURCE)) {
     for (i = 0; i < rcdu->num_crtcs; ++i) {
       struct rcar_du_vsp *vsp = &rcdu->vsps[i];
       vsp->index = i;
       vsp->dev = rcdu;
       rcdu->crtcs[i].vsp = vsp;
       ret = rcar_du_vsp_init(vsp);
       if (ret < 0) return ret;
     }
   }
   /* Create the CRTCs. */
   for (i = 0; i < rcdu->num_crtcs; ++i) {
     struct rcar_du_group *rgrp = &rcdu->groups[i / 2];
     ret = rcar_du_crtc_create(rgrp, i);
     if (ret < 0) return ret;
   }
   /* Initialize the encoders. */
   ret = rcar_du_lvdsenc_init(rcdu);
   if (ret < 0) return ret;
   ret = rcar_du_encoders_init(rcdu);
   if (ret < 0) return ret;
   if (ret == 0) {
     dev_err(rcdu->dev, "error: no encoder could be initialized\n");
     return -EINVAL;
   }
   num_encoders = ret;
   /* Set the possible CRTCs and possible clones. There's always at least
    * one way for all encoders to clone each other, set all bits in the
    * possible clones field.
    */
   list_for_each_entry(encoder, &dev->mode_config.encoder_list, head) {
     struct rcar_du_encoder *renc = to_rcar_encoder(encoder);
     const struct rcar_du_output_routing *route = &rcdu->info->routes[renc->output];
     encoder->possible_crtcs = route->possible_crtcs;
     encoder->possible_clones = (1 << num_encoders) - 1;
   }
   drm_mode_config_reset(dev);
   drm_kms_helper_poll_init(dev);
   if (dev->mode_config.num_connector) {
-    fbdev = drm_fbdev_cma_init(dev, 32, dev->mode_config.num_crtc, dev->mode_config.num_connector);
+    fbdev = drm_fbdev_cma_init(dev, 32, dev->mode_config.num_connector);
     if (IS_ERR(fbdev)) return PTR_ERR(fbdev);
     rcdu->fbdev = fbdev;
   } else {
     dev_info(rcdu->dev, "no connector found, disabling fbdev emulation\n");
   }
   return 0;
 }<sep>@@
expression A,B,C,D,E;
@@
(
- drm_fb_helper_init(A,B,C,D)
+ drm_fb_helper_init(A,B,D)
|
- drm_fbdev_cma_init_with_funcs(A,B,C,D,E)
+ drm_fbdev_cma_init_with_funcs(A,B,D,E)
|
- drm_fbdev_cma_init(A,B,C,D)
+ drm_fbdev_cma_init(A,B,D)
)