Received: by 2002:a6b:500f:0:0:0:0:0 with SMTP id e15csp3737204iob; Tue, 17 May 2022 06:22:52 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzOstLBX4AF1HkuxyKzkDqZmVfUd1pSmMuYIDS2Bvgj24iANPP5pM6R8fYQctxVK6rmj/pw X-Received: by 2002:a50:fd11:0:b0:42a:b6af:6e13 with SMTP id i17-20020a50fd11000000b0042ab6af6e13mr8934119eds.221.1652793772409; Tue, 17 May 2022 06:22:52 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652793772; cv=none; d=google.com; s=arc-20160816; b=m0DjX1bk5oxqJS3tU4ZpVsqDgu0LRNBmmQdZmy5I3nvMhnIv3+NwM4NDY/iD6kFNHu /t6g9uWkWDx19P1xmPOpbSyhGQJWWSadSH0g+GSWmoQPxxAbC1zFBC55m0dXMxmPZPVo G6gz2c3oljZK9JrsZ5tQO/HAydomay36HnTB72QXt8/8pFee6Q15zY0w926HAKn+NN1q YbO2+Rw7v6gFEh+rQ7ZTfhvbyRezyP7i06GKi86tCbW2gQHaPUqtsC/60Bg9YNiX4Kly FMYoFHsCPU/tREhFU/OKNTQhibv+MeQL0f/Tq/7bEnimrxIqnuKcCVUsV9YKcsZv3rUf NBjA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=6XhzmkN+HddDWqMx3Bvv+q64kMVHtkPh7MfDxdBS40M=; b=HrshvPk3pLddyAjpBviUS8ESWJC2BDeXH/KN2BSlAxh2GxOvZqty/0ByZIQm+OskH4 lgsQ+kaqJdosN92AK7JZ/FGcLY7u1wx/8Msf1027NX6ZwgIuapA+ZDBhiXIRaGp1nkwC TKWP+Bup4quoiUQTPvnq45KQoa6mQoxMn9PMn9tSqXUgDG/MfYekEh82ReTftq2gwd3G Ls5YJ2+DO/X1Dp2SmHVN8uv2PlruJwtTTXOliA9avIelDAhcmQmEDq0eGL3qaWfWcvNt VLzdVtxN7ue55fc8jlvv//HM1S+CZSZ/ZyjEZwh0ohMcSo5ZLFfLT79zW97oj2HU25LZ D/wA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=nZNiwkEV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id e9-20020a056402148900b0042ac225da48si3172122edv.496.2022.05.17.06.22.24; Tue, 17 May 2022 06:22:52 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=nZNiwkEV; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1346874AbiEPTqv (ORCPT + 99 others); Mon, 16 May 2022 15:46:51 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:44110 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1346161AbiEPTmw (ORCPT ); Mon, 16 May 2022 15:42:52 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [139.178.84.217]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5F68D3ED3A; Mon, 16 May 2022 12:42:03 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id F00D361510; Mon, 16 May 2022 19:42:02 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 069D0C385AA; Mon, 16 May 2022 19:42:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1652730122; bh=ZY7r6g2FfkeLnQCs4ZNZ/uMW7ITBX/uqL8DkAAxNV/c=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=nZNiwkEVi2elO4Qv3xA++RClnm/DycLFU6fwIjeYol+9/jU2NEqI11YA/r2szSHlb io0HyCkFSO92J8cqQ4bdYYlgjdQxDzdFAl/7XGZcNy9KLLpNclMIN2G6T0TeQt8k7d ppPOjNnVn3nVRUa8cAo/B5TBwLRB3XjgBZmwKq1g= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Zack Rusin , Daniel Vetter , Martin Krastev , Maaz Mombasawala Subject: [PATCH 4.19 29/32] drm/vmwgfx: Initialize drm_mode_fb_cmd2 Date: Mon, 16 May 2022 21:36:43 +0200 Message-Id: <20220516193615.637439172@linuxfoundation.org> X-Mailer: git-send-email 2.36.1 In-Reply-To: <20220516193614.773450018@linuxfoundation.org> References: <20220516193614.773450018@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-7.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_DNSWL_HI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Zack Rusin commit 3059d9b9f6aa433a55b9d0d21b566396d5497c33 upstream. Transition to drm_mode_fb_cmd2 from drm_mode_fb_cmd left the structure unitialized. drm_mode_fb_cmd2 adds a few additional members, e.g. flags and modifiers which were never initialized. Garbage in those members can cause random failures during the bringup of the fbcon. Initializing the structure fixes random blank screens after bootup due to flags/modifiers mismatches during the fbcon bring up. Fixes: dabdcdc9822a ("drm/vmwgfx: Switch to mode_cmd2") Signed-off-by: Zack Rusin Cc: Daniel Vetter Cc: # v4.10+ Reviewed-by: Martin Krastev Reviewed-by: Maaz Mombasawala Link: https://patchwork.freedesktop.org/patch/msgid/20220302152426.885214-7-zack@kde.org Signed-off-by: Greg Kroah-Hartman --- drivers/gpu/drm/vmwgfx/vmwgfx_fb.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_fb.c @@ -498,7 +498,7 @@ static int vmw_fb_kms_detach(struct vmw_ static int vmw_fb_kms_framebuffer(struct fb_info *info) { - struct drm_mode_fb_cmd2 mode_cmd; + struct drm_mode_fb_cmd2 mode_cmd = {0}; struct vmw_fb_par *par = info->par; struct fb_var_screeninfo *var = &info->var; struct drm_framebuffer *cur_fb;