Merge branch 'linus-4.14-rc4-acp-prereq' of git://people.freedesktop.org/~agd5f/linux...
[sfrench/cifs-2.6.git] / drivers / gpu / drm / drm_plane_helper.c
index 06aee1741e96a78f91e582eda88e4c4bc94b3f13..759ed93f4ba8fdf3b8be604f745479ee27838d0b 100644 (file)
@@ -354,7 +354,7 @@ int drm_primary_helper_update(struct drm_plane *plane, struct drm_crtc *crtc,
        /* Find current connectors for CRTC */
        num_connectors = get_connectors_for_crtc(crtc, NULL, 0);
        BUG_ON(num_connectors == 0);
-       connector_list = kzalloc(num_connectors * sizeof(*connector_list),
+       connector_list = kcalloc(num_connectors, sizeof(*connector_list),
                                 GFP_KERNEL);
        if (!connector_list)
                return -ENOMEM;