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

Commit 53d66bae authored by Brian Norris's avatar Brian Norris
Browse files

mtd: onenand: remove redundant offset check



The mtd_block_isbad() interface already checks for this.

Signed-off-by: default avatarBrian Norris <computersforpeace@gmail.com>
parent 8c519436
Loading
Loading
Loading
Loading
+0 −4
Original line number Diff line number Diff line
@@ -2556,10 +2556,6 @@ static int onenand_block_isbad(struct mtd_info *mtd, loff_t ofs)
{
	int ret;

	/* Check for invalid offset */
	if (ofs > mtd->size)
		return -EINVAL;

	onenand_get_device(mtd, FL_READING);
	ret = onenand_block_isbad_nolock(mtd, ofs, 0);
	onenand_release_device(mtd);