From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E2E6F79C9 for ; Thu, 12 Jan 2023 14:19:51 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 47285C433EF; Thu, 12 Jan 2023 14:19:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1673533191; bh=iTNFMNNwZZhGXBQzlLPWpwR3MRVJdJY4XBWn7m6QOBE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=IuPEyOMOS/+xlb0SD8FckR839HkvO+490w2dBakT+ZgM6s/dFe5rwnrLCY+nI9iga FJtZzSQpdU92cM2p+15qRzG8VDQwee5X6zTOg01lg4B7B8nB1XAz7utkYbmjgjBxvA kDcf7mFKPUiWzi+630A+DyT4HUZgc6hxAc5hkHEQ= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Christophe JAILLET , Helge Deller , Sasha Levin Subject: [PATCH 5.10 398/783] fbdev: uvesafb: Fixes an error handling path in uvesafb_probe() Date: Thu, 12 Jan 2023 14:51:54 +0100 Message-Id: <20230112135542.760868708@linuxfoundation.org> X-Mailer: git-send-email 2.39.0 In-Reply-To: <20230112135524.143670746@linuxfoundation.org> References: <20230112135524.143670746@linuxfoundation.org> User-Agent: quilt/0.67 Precedence: bulk X-Mailing-List: patches@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit From: Christophe JAILLET [ Upstream commit a94371040712031ba129c7e9d8ff04a06a2f8207 ] If an error occurs after a successful uvesafb_init_mtrr() call, it must be undone by a corresponding arch_phys_wc_del() call, as already done in the remove function. This has been added in the remove function in commit 63e28a7a5ffc ("uvesafb: Clean up MTRR code") Fixes: 8bdb3a2d7df4 ("uvesafb: the driver core") Signed-off-by: Christophe JAILLET Signed-off-by: Helge Deller Signed-off-by: Sasha Levin --- drivers/video/fbdev/uvesafb.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/video/fbdev/uvesafb.c b/drivers/video/fbdev/uvesafb.c index def14ac0ebe1..661f12742e4f 100644 --- a/drivers/video/fbdev/uvesafb.c +++ b/drivers/video/fbdev/uvesafb.c @@ -1756,6 +1756,7 @@ static int uvesafb_probe(struct platform_device *dev) out_unmap: iounmap(info->screen_base); out_mem: + arch_phys_wc_del(par->mtrr_handle); release_mem_region(info->fix.smem_start, info->fix.smem_len); out_reg: release_region(0x3c0, 32); -- 2.35.1