summaryrefslogtreecommitdiff
path: root/drivers/block/paride/pt.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/block/paride/pt.c')
-rw-r--r--drivers/block/paride/pt.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/block/paride/pt.c b/drivers/block/paride/pt.c
index 5ae229656eaa..1e4006e18f03 100644
--- a/drivers/block/paride/pt.c
+++ b/drivers/block/paride/pt.c
@@ -667,7 +667,7 @@ static int pt_open(struct inode *inode, struct file *file)
goto out;
err = -EROFS;
- if ((!(tape->flags & PT_WRITE_OK)) && (file->f_mode & 2))
+ if ((!(tape->flags & PT_WRITE_OK)) && (file->f_mode & FMODE_WRITE))
goto out;
if (!(iminor(inode) & 128))