summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/device/dev-io.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/device/dev-io.c b/lib/device/dev-io.c
index eecc759e..3bb9d65d 100644
--- a/lib/device/dev-io.c
+++ b/lib/device/dev-io.c
@@ -282,7 +282,7 @@ static int _dev_read_ahead_dev(struct device *dev, uint32_t *read_ahead)
return 1;
}
- if (!dev_open(dev))
+ if (!dev_open_readonly(dev))
return_0;
if (ioctl(dev->fd, BLKRAGET, &read_ahead_long) < 0) {