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

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

Merge "msm: cpp: Add error handling for invalid ioctl pointer"

parents 4fe4c046 3005ca5d
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -3007,6 +3007,10 @@ static long msm_cpp_subdev_fops_compat_ioctl(struct file *file,
	kp_ioctl.trans_code = up32_ioctl.trans_code;
	/* Convert the 32 bit pointer to 64 bit pointer */
	kp_ioctl.ioctl_ptr = compat_ptr(up32_ioctl.ioctl_ptr);
	if (!kp_ioctl.ioctl_ptr) {
		pr_err("%s: Invalid ioctl pointer\n", __func__);
		return -EINVAL;
	}

	/*
	 * Convert 32 bit IOCTL ID's to 64 bit IOCTL ID's