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

Commit c410a9a1 authored by Animesh Kishore's avatar Animesh Kishore
Browse files

mdss: mdp: Fix access after null check



Warn and early return if arguments NULL.

Change-Id: I1453b80c9af56fe88bde3bc67b45e5952adbc984
Signed-off-by: default avatarAnimesh Kishore <animeshk@codeaurora.org>
parent a5370b86
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -4560,7 +4560,8 @@ static inline void __mdss_mdp_mixer_write_layer(struct mdss_mdp_ctl *ctl,
	u32 off[NUM_MIXERCFG_REGS];
	int i;

	WARN_ON(!values || count < NUM_MIXERCFG_REGS);
	if (WARN_ON(!values || count < NUM_MIXERCFG_REGS))
		return;

	__mdss_mdp_mixer_get_offsets(mixer_num, off, ARRAY_SIZE(off));