diff options
author | Alexander von Gernler <grunk@cvs.openbsd.org> | 2007-05-31 06:26:24 +0000 |
---|---|---|
committer | Alexander von Gernler <grunk@cvs.openbsd.org> | 2007-05-31 06:26:24 +0000 |
commit | 668036f12d76fd7f403cc97ccdc5357711ffa30f (patch) | |
tree | 3c3e550604ec783c9026c3ae17ee326ad566b9b9 /sys/dev/softraid.c | |
parent | b3485a3931c6c71a9c1a510da2b58847e3219cdd (diff) |
- zap unnecessary rv variable
- sprinkle an XXX to remember that we have to supply a serious key later
ok tedu@
Diffstat (limited to 'sys/dev/softraid.c')
-rw-r--r-- | sys/dev/softraid.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/dev/softraid.c b/sys/dev/softraid.c index 06ae66287f2..8cfc1f6f734 100644 --- a/sys/dev/softraid.c +++ b/sys/dev/softraid.c @@ -1,4 +1,4 @@ -/* $OpenBSD: softraid.c,v 1.61 2007/05/30 17:56:37 marco Exp $ */ +/* $OpenBSD: softraid.c,v 1.62 2007/05/31 06:26:23 grunk Exp $ */ /* * Copyright (c) 2007 Marco Peereboom <marco@peereboom.us> * @@ -2845,26 +2845,26 @@ sr_raidc_putcryptop(struct cryptop *crp) int sr_raidc_alloc_resources(struct sr_discipline *sd) { - int rv = EINVAL; struct cryptoini cri; if (!sd) - return (rv); + return (EINVAL); DNPRINTF(SR_D_DIS, "%s: sr_raidc_alloc_resources\n", DEVNAME(sd->sd_sc)); sr_alloc_wu(sd); sr_alloc_ccb(sd); + + /* XXX we need a real key later */ memset(sd->mds.mdd_raidc.src_key, 'k', sizeof sd->mds.mdd_raidc.src_key); bzero(&cri, sizeof(cri)); cri.cri_alg = CRYPTO_AES_CBC; cri.cri_klen = 256; cri.cri_rnd = 14; cri.cri_key = sd->mds.mdd_raidc.src_key; - rv = crypto_newsession(&sd->mds.mdd_raidc.src_sid, &cri, 0); - return (rv); + return (crypto_newsession(&sd->mds.mdd_raidc.src_sid, &cri, 0)); } int |