summaryrefslogtreecommitdiff
path: root/sys/arch/amd64/stand
diff options
context:
space:
mode:
Diffstat (limited to 'sys/arch/amd64/stand')
-rw-r--r--sys/arch/amd64/stand/libsa/biosdev.c5
-rw-r--r--sys/arch/amd64/stand/libsa/softraid.c4
2 files changed, 5 insertions, 4 deletions
diff --git a/sys/arch/amd64/stand/libsa/biosdev.c b/sys/arch/amd64/stand/libsa/biosdev.c
index 319d9a3bec6..379592bf964 100644
--- a/sys/arch/amd64/stand/libsa/biosdev.c
+++ b/sys/arch/amd64/stand/libsa/biosdev.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: biosdev.c,v 1.20 2013/03/23 16:08:27 deraadt Exp $ */
+/* $OpenBSD: biosdev.c,v 1.21 2013/12/28 02:40:41 jsing Exp $ */
/*
* Copyright (c) 1996 Michael Shalayeff
@@ -524,7 +524,8 @@ biosopen(struct open_file *f, ...)
}
if (bv->sbv_level == 'C' && bv->sbv_keys == NULL)
- sr_crypto_decrypt_keys(bv);
+ if (sr_crypto_decrypt_keys(bv) != 0)
+ return EPERM;
if (bv->sbv_diskinfo == NULL) {
dip = alloc(sizeof(struct diskinfo));
diff --git a/sys/arch/amd64/stand/libsa/softraid.c b/sys/arch/amd64/stand/libsa/softraid.c
index b98ec2ef680..5c7f9b3104e 100644
--- a/sys/arch/amd64/stand/libsa/softraid.c
+++ b/sys/arch/amd64/stand/libsa/softraid.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: softraid.c,v 1.5 2013/10/20 13:25:20 stsp Exp $ */
+/* $OpenBSD: softraid.c,v 1.6 2013/12/28 02:40:41 jsing Exp $ */
/*
* Copyright (c) 2012 Joel Sing <jsing@openbsd.org>
@@ -333,7 +333,7 @@ sr_strategy(struct sr_boot_volume *bv, int rw, daddr32_t blk, size_t size,
/* We only support read-only softraid. */
if (rw != F_READ)
- return EPERM;
+ return ENOTSUP;
/* Partition offset within softraid volume. */
sr_dip = (struct diskinfo *)bv->sbv_diskinfo;