summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/libmtd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libmtd.c b/lib/libmtd.c
index 1b16de5..9b247ae 100644
--- a/lib/libmtd.c
+++ b/lib/libmtd.c
@@ -1151,7 +1151,7 @@ int mtd_write(libmtd_t desc, const struct mtd_dev_info *mtd, int fd, int eb,
ret = ioctl(fd, MEMWRITE, &ops);
if (ret == 0)
return 0;
- else if (errno != ENOTTY)
+ else if (errno != ENOTTY && errno != EOPNOTSUPP)
return mtd_ioctl_error(mtd, eb, "MEMWRITE");
/* Fall back to old methods if necessary */