diff options
Diffstat (limited to 'drivers/block/paride/pf.c')
-rw-r--r-- | drivers/block/paride/pf.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/block/paride/pf.c b/drivers/block/paride/pf.c index e7fe6ca97dd8..a902d84fd330 100644 --- a/drivers/block/paride/pf.c +++ b/drivers/block/paride/pf.c | |||
@@ -305,7 +305,7 @@ static int pf_open(struct inode *inode, struct file *file) | |||
305 | if (pf->media_status == PF_NM) | 305 | if (pf->media_status == PF_NM) |
306 | return -ENODEV; | 306 | return -ENODEV; |
307 | 307 | ||
308 | if ((pf->media_status == PF_RO) && (file->f_mode & 2)) | 308 | if ((pf->media_status == PF_RO) && (file->f_mode & FMODE_WRITE)) |
309 | return -EROFS; | 309 | return -EROFS; |
310 | 310 | ||
311 | pf->access++; | 311 | pf->access++; |