aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/mtd
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/mtd')
-rw-r--r--drivers/mtd/mtdchar.c28
1 files changed, 28 insertions, 0 deletions
diff --git a/drivers/mtd/mtdchar.c b/drivers/mtd/mtdchar.c
index 51bb0b092003..99d1fbc95011 100644
--- a/drivers/mtd/mtdchar.c
+++ b/drivers/mtd/mtdchar.c
@@ -607,6 +607,34 @@ static int mtd_ioctl(struct inode *inode, struct file *file,
607 break; 607 break;
608 } 608 }
609 609
610 case MEMWRITEOOB64:
611 {
612 struct mtd_oob_buf64 buf;
613 struct mtd_oob_buf64 __user *buf_user = argp;
614
615 if (copy_from_user(&buf, argp, sizeof(buf)))
616 ret = -EFAULT;
617 else
618 ret = mtd_do_writeoob(file, mtd, buf.start, buf.length,
619 (void __user *)(uintptr_t)buf.usr_ptr,
620 &buf_user->length);
621 break;
622 }
623
624 case MEMREADOOB64:
625 {
626 struct mtd_oob_buf64 buf;
627 struct mtd_oob_buf64 __user *buf_user = argp;
628
629 if (copy_from_user(&buf, argp, sizeof(buf)))
630 ret = -EFAULT;
631 else
632 ret = mtd_do_readoob(mtd, buf.start, buf.length,
633 (void __user *)(uintptr_t)buf.usr_ptr,
634 &buf_user->length);
635 break;
636 }
637
610 case MEMLOCK: 638 case MEMLOCK:
611 { 639 {
612 struct erase_info_user einfo; 640 struct erase_info_user einfo;