summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTed Unangst <tedu@cvs.openbsd.org>2016-05-28 00:10:37 +0000
committerTed Unangst <tedu@cvs.openbsd.org>2016-05-28 00:10:37 +0000
commit91aa9be97e05cacec4f653593df2a55906c828b6 (patch)
tree688d5886f109001d143243efe331f9624ef840b5
parent736823e8b7bd5b7d4ae4fda2c44aa88f688e7ec7 (diff)
no need to open key disk for writing, from bytevolcano. ok jung
-rw-r--r--sys/dev/softraid_crypto.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/dev/softraid_crypto.c b/sys/dev/softraid_crypto.c
index 45782b8227c..3c0648b9550 100644
--- a/sys/dev/softraid_crypto.c
+++ b/sys/dev/softraid_crypto.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: softraid_crypto.c,v 1.128 2016/05/21 14:19:03 jsing Exp $ */
+/* $OpenBSD: softraid_crypto.c,v 1.129 2016/05/28 00:10:36 tedu Exp $ */
/*
* Copyright (c) 2007 Marco Peereboom <marco@peereboom.us>
* Copyright (c) 2008 Hans-Joerg Hoexer <hshoexer@openbsd.org>
@@ -795,7 +795,7 @@ sr_crypto_read_key_disk(struct sr_discipline *sd, dev_t dev)
sr_error(sc, "cannot open key disk %s", devname);
goto done;
}
- if (VOP_OPEN(vn, FREAD | FWRITE, NOCRED, curproc)) {
+ if (VOP_OPEN(vn, FREAD, NOCRED, curproc)) {
DNPRINTF(SR_D_META,"%s: sr_crypto_read_key_disk cannot "
"open %s\n", DEVNAME(sc), devname);
vput(vn);