summaryrefslogtreecommitdiff
path: root/target/linux/generic/patches-3.0/400-rootfs_split.patch
diff options
context:
space:
mode:
authorImre Kaloz <kaloz@openwrt.org>2011-07-06 12:55:21 +0000
committerImre Kaloz <kaloz@openwrt.org>2011-07-06 12:55:21 +0000
commit90bd74dd8b87d84697efbd3c2624c58496783dad (patch)
treef3d7e3f4ddf9d27b5c462dfbaed9de66214ad814 /target/linux/generic/patches-3.0/400-rootfs_split.patch
parentf24764a37211d2068889186d7c5e08978ef13dc3 (diff)
downloadmtk-20170518-90bd74dd8b87d84697efbd3c2624c58496783dad.zip
mtk-20170518-90bd74dd8b87d84697efbd3c2624c58496783dad.tar.gz
mtk-20170518-90bd74dd8b87d84697efbd3c2624c58496783dad.tar.bz2
fixup mtd refresh and co.
SVN-Revision: 27491
Diffstat (limited to 'target/linux/generic/patches-3.0/400-rootfs_split.patch')
-rw-r--r--target/linux/generic/patches-3.0/400-rootfs_split.patch21
1 files changed, 16 insertions, 5 deletions
diff --git a/target/linux/generic/patches-3.0/400-rootfs_split.patch b/target/linux/generic/patches-3.0/400-rootfs_split.patch
index d623bfd..db736c3 100644
--- a/target/linux/generic/patches-3.0/400-rootfs_split.patch
+++ b/target/linux/generic/patches-3.0/400-rootfs_split.patch
@@ -257,18 +257,19 @@
--- a/drivers/mtd/mtdchar.c
+++ b/drivers/mtd/mtdchar.c
-@@ -834,6 +834,11 @@ static int mtd_ioctl(struct file *file,
- file->f_pos = 0;
+@@ -948,6 +948,12 @@ static int mtd_ioctl(struct file *file,
break;
}
+
+ case MTDREFRESH:
+ {
+ ret = mtd_device_refresh(mtd);
+ break;
+ }
-
- case OTPGETREGIONCOUNT:
- case OTPGETREGIONINFO:
++
+ default:
+ ret = -ENOTTY;
+ }
--- a/include/linux/mtd/mtd.h
+++ b/include/linux/mtd/mtd.h
@@ -125,6 +125,7 @@ struct nand_ecclayout {
@@ -314,3 +315,13 @@
};
#define MTDPART_OFS_NXTBLK (-2)
+--- a/include/mtd/mtd-abi.h
++++ b/include/mtd/mtd-abi.h
+@@ -127,6 +127,7 @@ struct otp_info {
+ #define MEMWRITEOOB64 _IOWR('M', 21, struct mtd_oob_buf64)
+ #define MEMREADOOB64 _IOWR('M', 22, struct mtd_oob_buf64)
+ #define MEMISLOCKED _IOR('M', 23, struct erase_info_user)
++#define MTDREFRESH _IO('M', 24)
+
+ /*
+ * Obsolete legacy interface. Keep it in order not to break userspace