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

Commit 2ea88198 authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "lkdtm: Correct the size value for WRITE_KERN"

parents 7324fee3 8aee7c9b
Loading
Loading
Loading
Loading
+6 −1
Original line number Diff line number Diff line
@@ -109,7 +109,12 @@ void lkdtm_WRITE_KERN(void)
	size_t size;
	unsigned char *ptr;

	size = (unsigned long)do_overwritten - (unsigned long)do_nothing;
	if ((unsigned long)do_overwritten < (unsigned long)do_nothing)
		size = (unsigned long)do_nothing -
			(unsigned long)do_overwritten;
	else
		size = (unsigned long)do_overwritten -
			(unsigned long)do_nothing;
	ptr = (unsigned char *)do_overwritten;

	pr_info("attempting bad %zu byte write at %px\n", size, ptr);