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

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

Merge "msm: sps: Add integer wrap check for debugfs buffer"

parents 521bc983 981a0047
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -184,6 +184,11 @@ static ssize_t sps_set_info(struct file *file, const char __user *buf,
		return -EFAULT;
	}

	if (buf_size_kb > (INT_MAX/SZ_1K)) {
		pr_err("sps:debugfs: buffer size is too large\n");
		return -EFAULT;
	}

	new_buf_size = buf_size_kb * SZ_1K;

	if (debugfs_record_enabled) {