Skip to content

Commit e10b376

Browse files
Artem BityutskiyArtem Bityutskiy
authored andcommitted
UBI: make the control character device non-seekable
This patch makes the UBI control device (/dev/ubi_ctrl) non-seekable. The seek operation does is not applicable to this file, so it is cleaner to explicitly return error (which the added 'no_llseek()') does than trying to change the position (which the removed 'default_llseek()' does). This is an API break, but the only known user of this interface is mtd-utils which does not need the seeking functionality. And any app which relies on this is broken, but I'm not aware of such apps. Signed-off-by: Artem Bityutskiy <Artem.Bityutskiy@nokia.com>
1 parent a6360dd commit e10b376

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎drivers/mtd/ubi/cdev.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1100,5 +1100,5 @@ const struct file_operations ubi_ctrl_cdev_operations = {
11001100
.owner = THIS_MODULE,
11011101
.unlocked_ioctl = ctrl_cdev_ioctl,
11021102
.compat_ioctl = ctrl_cdev_compat_ioctl,
1103-
.llseek = noop_llseek,
1103+
.llseek = no_llseek,
11041104
};

0 commit comments

Comments
 (0)