diff --git a/drivers/bch/bchdev_driver.c b/drivers/bch/bchdev_driver.c index 6fbea4e8ec9..e1d539a38e0 100644 --- a/drivers/bch/bchdev_driver.c +++ b/drivers/bch/bchdev_driver.c @@ -455,6 +455,13 @@ static int bch_ioctl(FAR struct file *filep, int cmd, unsigned long arg) if (bchinode->u.i_bops->ioctl != NULL) { ret = bchinode->u.i_bops->ioctl(bchinode, cmd, arg); + + /* Drivers may not support command BIOC_FLUSH */ + + if (ret == -ENOTTY && cmd == BIOC_FLUSH) + { + ret = 0; + } } } break;