Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4580e73c authored by Tharun Raj Soma's avatar Tharun Raj Soma Committed by Gerrit - the friendly Code Review server
Browse files

drm/msm/dsi-staging: Fix buffer overflow and Null pointer dereference



This change fixes two issues in DSI driver: fix for Buffer Overflow-
Local Array Index Out of Bounds and fix for Pointer will be dereferenced
after it was positively checked for NULL.

Change-Id: I71741ead2f34e44de73a18c480bff3c07855a885
Signed-off-by: default avatarTharun Raj Soma <tsoma@codeaurora.org>
parent e63c83bb
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -1923,7 +1923,8 @@ static void dsi_config_host_engine_state_for_cont_splash
	enum dsi_engine_state host_state = DSI_CTRL_ENGINE_ON;

	/* Sequence does not matter for split dsi usecases */
	for (i = 0; i < display->ctrl_count; i++) {
	for (i = 0; (i < display->ctrl_count) &&
			(i < MAX_DSI_CTRLS_PER_DISPLAY); i++) {
		ctrl = &display->ctrl[i];
		if (!ctrl->ctrl)
			continue;