Resetting the context on error will prevent some checks like:
if (!ctx.cur_dev)
To pass when the probe method has failed
Signed-off-by: Richard Genoud <richard.genoud@posteo.net>
[jh80.chung: cherry picked from mainline commit
56cf1ceee38435a0c105d40336d12d19e1db8b1d]
Signed-off-by: Jaehoon Chung <jh80.chung@samsung.com>
Change-Id: I998b1fa2d790bf9618d0d652663edb220a32c610
ret = sqfs_read_sblk(&sblk);
if (ret)
- return ret;
+ goto error;
/* Make sure it has a valid SquashFS magic number*/
if (get_unaligned_le32(&sblk->s_magic) != SQFS_MAGIC_NUMBER) {