mtd: Replace MTDIOC_XIPBASE with BIOC_XIPBASE

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
Xiang Xiao
2021-08-11 15:46:01 +08:00
committed by Alan Carvalho de Assis
parent 177e1ced3f
commit 6b6c11f0ad
13 changed files with 14 additions and 65 deletions
+1 -25
View File
@@ -506,31 +506,7 @@ static int ftl_ioctl(FAR struct inode *inode, int cmd, unsigned long arg)
dev = (struct ftl_struct_s *)inode->i_private;
/* Only one block driver ioctl command is supported by this driver (and
* that command is just passed on to the MTD driver in a slightly
* different form).
*/
if (cmd == BIOC_XIPBASE)
{
/* The argument accompanying the BIOC_XIPBASE should be non-NULL. If
* DEBUG is enabled, we will catch it here instead of in the MTD
* driver.
*/
#ifdef CONFIG_DEBUG_FEATURES
if (arg == 0)
{
ferr("ERROR: BIOC_XIPBASE argument is NULL\n");
return -EINVAL;
}
#endif
/* Change the BIOC_XIPBASE command to the MTDIOC_XIPBASE command. */
cmd = MTDIOC_XIPBASE;
}
else if (cmd == BIOC_FLUSH)
if (cmd == BIOC_FLUSH)
{
#ifdef CONFIG_FTL_WRITEBUFFER
rwb_flush(&dev->rwb);