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

Commit 46f3602a authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "msm: Fix camera framework NULL pointer"

parents f1ab727a 56431e73
Loading
Loading
Loading
Loading
+7 −0
Original line number Diff line number Diff line
@@ -476,6 +476,13 @@ int msm_camera_config_single_vreg(struct device *dev,
	int rc = 0;
	if (config) {
		CDBG("%s enable %s\n", __func__, cam_vreg->reg_name);

		if (dev == NULL || cam_vreg == NULL ||
			reg_ptr == NULL || *reg_ptr == NULL) {
			pr_err("%s: get failed NULL parameter\n", __func__);
			goto vreg_get_fail;
		}

		*reg_ptr = regulator_get(dev, cam_vreg->reg_name);
		if (IS_ERR(*reg_ptr)) {
			pr_err("%s: %s get failed\n", __func__,