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

Commit 0040476b authored by Roel Kluin's avatar Roel Kluin Committed by David Woodhouse
Browse files

mtd: change positive error return into negative

parent 4335c100
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -373,7 +373,7 @@ static int mtd_do_writeoob(struct file *file, struct mtd_info *mtd,
	if (!mtd->write_oob)
		ret = -EOPNOTSUPP;
	else
		ret = access_ok(VERIFY_READ, ptr, length) ? 0 : EFAULT;
		ret = access_ok(VERIFY_READ, ptr, length) ? 0 : -EFAULT;

	if (ret)
		return ret;