fs: Move mmap callback before truncate in [file|mountpt]_operations

since mmap may exist in block_operations, but truncate may not,
moving mmap beforee truncate could make three struct more compatible

Signed-off-by: Xiang Xiao <xiaoxiang@xiaomi.com>
This commit is contained in:
Xiang Xiao
2023-01-03 01:06:12 +08:00
committed by Petro Karashchenko
parent c623ee20f1
commit b0a0ba3ad7
103 changed files with 105 additions and 106 deletions
+1 -1
View File
@@ -122,8 +122,8 @@ static const struct file_operations ads7843e_fops =
NULL, /* write */
NULL, /* seek */
ads7843e_ioctl, /* ioctl */
NULL, /* truncate */
NULL, /* mmap */
NULL, /* truncate */
ads7843e_poll /* poll */
};
+1 -1
View File
@@ -135,8 +135,8 @@ static const struct file_operations ajoy_fops =
NULL, /* write */
NULL, /* seek */
ajoy_ioctl, /* ioctl */
NULL, /* truncate */
NULL, /* mmap */
NULL, /* truncate */
ajoy_poll /* poll */
};
+1 -1
View File
@@ -133,8 +133,8 @@ static const struct file_operations btn_fops =
btn_write, /* write */
NULL, /* seek */
btn_ioctl, /* ioctl */
NULL, /* truncate */
NULL, /* mmap */
NULL, /* truncate */
btn_poll /* poll */
};
+1 -1
View File
@@ -224,8 +224,8 @@ static const struct file_operations g_mbr3108_fileops =
mbr3108_write, /* write */
NULL, /* seek */
NULL, /* ioctl */
NULL, /* truncate */
NULL, /* mmap */
NULL, /* truncate */
mbr3108_poll /* poll */
};
+1 -1
View File
@@ -135,8 +135,8 @@ static const struct file_operations djoy_fops =
NULL, /* write */
NULL, /* seek */
djoy_ioctl, /* ioctl */
NULL, /* truncate */
NULL, /* mmap */
NULL, /* truncate */
djoy_poll /* poll */
};
+1 -1
View File
@@ -176,8 +176,8 @@ static const struct file_operations ft5x06_fops =
NULL, /* write */
NULL, /* seek */
ft5x06_ioctl, /* ioctl */
NULL, /* truncate */
NULL, /* mmap */
NULL, /* truncate */
ft5x06_poll /* poll */
};
+1 -1
View File
@@ -88,8 +88,8 @@ static const struct file_operations g_keyboard_fops =
keyboard_write, /* write */
NULL, /* seek */
NULL, /* ioctl */
NULL, /* truncate */
NULL, /* mmap */
NULL, /* truncate */
keyboard_poll /* poll */
};
+1 -1
View File
@@ -115,8 +115,8 @@ static const struct file_operations max11802_fops =
NULL, /* write */
NULL, /* seek */
max11802_ioctl, /* ioctl */
NULL, /* truncate */
NULL, /* mmap */
NULL, /* truncate */
max11802_poll /* poll */
};
+1 -1
View File
@@ -280,8 +280,8 @@ static const struct file_operations mxt_fops =
NULL, /* write */
NULL, /* seek */
mxt_ioctl, /* ioctl */
NULL, /* truncate */
NULL, /* mmap */
NULL, /* truncate */
mxt_poll /* poll */
};
+1 -1
View File
@@ -255,8 +255,8 @@ static const struct file_operations g_hidkbd_fops =
spq10kbd_write, /* write */
NULL, /* seek */
NULL, /* ioctl */
NULL, /* truncate */
NULL, /* mmap */
NULL, /* truncate */
spq10kbd_poll /* poll */
};
+1 -1
View File
@@ -124,8 +124,8 @@ static const struct file_operations g_stmpe811fops =
NULL, /* write */
NULL, /* seek */
stmpe811_ioctl, /* ioctl */
NULL, /* truncate */
NULL, /* mmap */
NULL, /* truncate */
stmpe811_poll /* poll */
};
+1 -1
View File
@@ -90,8 +90,8 @@ static const struct file_operations g_touch_fops =
touch_write, /* write */
NULL, /* seek */
touch_ioctl, /* ioctl */
NULL, /* truncate */
NULL, /* mmap */
NULL, /* truncate */
touch_poll /* poll */
};
+1 -1
View File
@@ -209,8 +209,8 @@ static const struct file_operations tsc2007_fops =
NULL, /* write */
NULL, /* seek */
tsc2007_ioctl, /* ioctl */
NULL, /* truncate */
NULL, /* mmap */
NULL, /* truncate */
tsc2007_poll /* poll */
};