diff options
-rw-r--r-- | drivers/block/pktcdvd.c | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/drivers/block/pktcdvd.c b/drivers/block/pktcdvd.c index 73999762582e..edf6bf29002e 100644 --- a/drivers/block/pktcdvd.c +++ b/drivers/block/pktcdvd.c | |||
@@ -1895,7 +1895,7 @@ static int pkt_open_write(struct pktcdvd_device *pd) | |||
1895 | 1895 | ||
1896 | if ((ret = pkt_probe_settings(pd))) { | 1896 | if ((ret = pkt_probe_settings(pd))) { |
1897 | VPRINTK("pktcdvd: %s failed probe\n", pd->name); | 1897 | VPRINTK("pktcdvd: %s failed probe\n", pd->name); |
1898 | return -EIO; | 1898 | return -EROFS; |
1899 | } | 1899 | } |
1900 | 1900 | ||
1901 | if ((ret = pkt_set_write_settings(pd))) { | 1901 | if ((ret = pkt_set_write_settings(pd))) { |
@@ -2053,10 +2053,9 @@ static int pkt_open(struct inode *inode, struct file *file) | |||
2053 | goto out_dec; | 2053 | goto out_dec; |
2054 | } | 2054 | } |
2055 | } else { | 2055 | } else { |
2056 | if (pkt_open_dev(pd, file->f_mode & FMODE_WRITE)) { | 2056 | ret = pkt_open_dev(pd, file->f_mode & FMODE_WRITE); |
2057 | ret = -EIO; | 2057 | if (ret) |
2058 | goto out_dec; | 2058 | goto out_dec; |
2059 | } | ||
2060 | /* | 2059 | /* |
2061 | * needed here as well, since ext2 (among others) may change | 2060 | * needed here as well, since ext2 (among others) may change |
2062 | * the blocksize at mount time | 2061 | * the blocksize at mount time |