Lines Matching defs:file
56 #include <linux/file.h>
816 * while holding the file unremovable, which leads to
1190 if (!mddev->bitmap_info.file && !mddev->bitmap_info.offset)
1380 mddev->bitmap_info.file == NULL) {
1509 if (mddev->bitmap && mddev->bitmap_info.file == NULL)
1865 mddev->bitmap_info.file == NULL) {
2073 if (mddev->bitmap && mddev->bitmap_info.file == NULL) {
2290 if (bitmap && !rdev->mddev->bitmap_info.file &&
2949 /* See if cmd, written into a sysfs file, matches
3544 * Writing "sector length" to this file adds an acknowledged
3547 * been acknowledged. Writing to this file adds bad blocks
6023 (mddev->bitmap_info.file || mddev->bitmap_info.offset)) {
6485 if (mddev->bitmap_info.file) {
6486 struct file *f = mddev->bitmap_info.file;
6488 mddev->bitmap_info.file = NULL;
6694 mdu_bitmap_file_t *file = NULL; /* too big for stack allocation */
6698 file = kzalloc(sizeof(*file), GFP_NOIO);
6699 if (!file)
6705 if (mddev->bitmap_info.file) {
6706 ptr = file_path(mddev->bitmap_info.file, file->pathname,
6707 sizeof(file->pathname));
6711 memmove(file->pathname, ptr,
6712 sizeof(file->pathname)-(ptr-file->pathname));
6717 copy_to_user(arg, file, sizeof(*file)))
6720 kfree(file);
7099 struct file *f;
7101 if (mddev->bitmap || mddev->bitmap_info.file)
7106 pr_warn("%s: error: failed to get bitmap file\n",
7113 pr_warn("%s: error: bitmap file must be a regular file\n",
7117 pr_warn("%s: error: bitmap file must open for write\n",
7121 pr_warn("%s: error: bitmap file is already in use\n",
7129 mddev->bitmap_info.file = f;
7130 mddev->bitmap_info.offset = 0; /* file overrides offset */
7157 struct file *f = mddev->bitmap_info.file;
7160 mddev->bitmap_info.file = NULL;
7457 if (mddev->bitmap->storage.file) {
8380 static int md_seq_open(struct inode *inode, struct file *file)
8385 error = seq_open(file, &md_seq_ops);
8389 seq = file->private_data;
8395 static __poll_t mdstat_poll(struct file *filp, poll_table *wait)