Skip to contentSkip to conversation

Patch "qxl: check for kmap failures" has been added to the 4.4-stable tree

PATCH [email protected] 1 participant 1 message Sep 28, 2016

Subsystems (4)
lore
Share & tools
lore

[email protected]

author maintainer Applied
#0 lore raw

This is a note to let you know that I've just added the patch titled

qxl: check for kmap failures

to the 4.4-stable tree which can be found at:
http://www.kernel.org/git/?p=linux/kernel/git/stable/stable-queue.git;a=summary

The filename of the patch is:
qxl-check-for-kmap-failures.patch
and it can be found in the queue-4.4 subdirectory.

If you, or anyone else, feels it should not be added to the stable tree, please let <[email protected]> know about it.

Quoted 1 line

From f4cceb2affcd1285d4ce498089e8a79f4cd2fa66 Mon Sep 17 00:00:00 2001

From: Dan Carpenter <[email protected]>
Date: Mon, 11 Jul 2016 11:46:33 +0300
Subject: qxl: check for kmap failures

From: Dan Carpenter <[email protected]>

commit f4cceb2affcd1285d4ce498089e8a79f4cd2fa66 upstream.

If kmap fails, it leads to memory corruption.

---
 drivers/gpu/drm/qxl/qxl_draw.c |    2 ++
 1 file changed, 2 insertions(+)
drivers/gpu/drm/qxl/qxl_draw.c +2 -0
@@ -136,6 +136,8 @@ static int qxl_palette_create_1bit(struc
 				 * correctly globaly, since that would require
 				 * tracking all of our palettes. */
 	ret = qxl_bo_kmap(palette_bo, (void **)&pal);
+	if (ret)
+		return ret;
 	pal->num_ents = 2;
 	pal->unique = unique++;
 	if (visual == FB_VISUAL_TRUECOLOR || visual == FB_VISUAL_DIRECTCOLOR) {

Patches currently in stable-queue which might be from [email protected] are

queue-4.4/mtd-pmcmsp-flash-allocating-too-much-in-init_msp_flash.patch queue-4.4/hostfs-freeing-an-err_ptr-in-hostfs_fill_sb_common.patch queue-4.4/mtd-maps-sa1100-flash-potential-null-dereference.patch queue-4.4/qxl-check-for-kmap-failures.patch queue-4.4/power-supply-max17042_battery-fix-model-download-bug.patch