mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-25 14:13:01 -04:00
mtd: m25p80: fixup device removal failure path
Device removal should fail if MTD unregistration fails. Signed-off-by: Brian Norris <computersforpeace@gmail.com> Reviewed-by: Marek Vasut <marex@denx.de>
This commit is contained in:
parent
d367e37e00
commit
9650b9bec6
1 changed files with 1 additions and 3 deletions
|
|
@ -1125,9 +1125,7 @@ static int m25p_remove(struct spi_device *spi)
|
|||
struct m25p *flash = spi_get_drvdata(spi);
|
||||
|
||||
/* Clean up MTD stuff. */
|
||||
mtd_device_unregister(&flash->mtd);
|
||||
|
||||
return 0;
|
||||
return mtd_device_unregister(&flash->mtd);
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue