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

Commit 69857a70 authored by Jayant Shekhar's avatar Jayant Shekhar
Browse files

msm: mdss: Fix null pointer refernce during debug init



Some targets doesnt seem to have vbif_nrt_phys in dtsi
file but we still register the debug node for vbif_nrt_reg
and off without checking whether it exists or not. Ensure
this is checked to avoid null pointer reference.

Change-Id: Icce8823f80e586bc4827d8db18dceb2fb866c2f9
Signed-off-by: default avatarJayant Shekhar <jshekhar@codeaurora.org>
parent 0579c67d
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -1713,7 +1713,9 @@ static int mdss_mdp_debug_init(struct platform_device *pdev,
	mdss_debug_register_dump_range(pdev, dbg_blk, "qcom,regs-dump-mdp",
		"qcom,regs-dump-names-mdp", "qcom,regs-dump-xin-id-mdp");

	if (mdata->vbif_io.base)
		mdss_debug_register_io("vbif", &mdata->vbif_io, NULL);
	if (mdata->vbif_nrt_io.base)
		mdss_debug_register_io("vbif_nrt", &mdata->vbif_nrt_io, NULL);

	return 0;