diff options
author | Jason Wright <jason@cvs.openbsd.org> | 2002-09-24 18:33:27 +0000 |
---|---|---|
committer | Jason Wright <jason@cvs.openbsd.org> | 2002-09-24 18:33:27 +0000 |
commit | 59c0d446267e5ac5962411ba74fe8dc57703e0cf (patch) | |
tree | 4af2e32929808a2bbee2f8520a6c78f750af81c1 /sys/dev/pci/nofn.c | |
parent | 44eccc305057561641268f38e186635eaffa766c (diff) |
Don't use constants for the output parameter, use the iparam count as a pointer to the first result location.
Diffstat (limited to 'sys/dev/pci/nofn.c')
-rw-r--r-- | sys/dev/pci/nofn.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/sys/dev/pci/nofn.c b/sys/dev/pci/nofn.c index 4a5a12e5b5a..997d6c144c1 100644 --- a/sys/dev/pci/nofn.c +++ b/sys/dev/pci/nofn.c @@ -1,4 +1,4 @@ -/* $OpenBSD: nofn.c,v 1.5 2002/09/18 04:32:59 jason Exp $ */ +/* $OpenBSD: nofn.c,v 1.6 2002/09/24 18:33:26 jason Exp $ */ /* * Copyright (c) 2002 Jason L. Wright (jason@thought.net) @@ -677,15 +677,15 @@ nofn_modexp_finish(sc, q) reglen = ((PK_READ_4(sc, NOFN_PK_LENADDR(3)) & NOFN_PK_LENMASK) + 7) / 8; - crplen = (krp->krp_param[NOFN_MODEXP_PAR_C].crp_nbits + 7) / 8; + crplen = (krp->krp_param[krp->krp_iparams].crp_nbits + 7) / 8; if (crplen <= reglen) - bcopy(sc->sc_pk_tmp.b, krp->krp_param[NOFN_MODEXP_PAR_C].crp_p, + bcopy(sc->sc_pk_tmp.b, krp->krp_param[krp->krp_iparams].crp_p, reglen); else { - bcopy(sc->sc_pk_tmp.b, krp->krp_param[NOFN_MODEXP_PAR_C].crp_p, + bcopy(sc->sc_pk_tmp.b, krp->krp_param[krp->krp_iparams].crp_p, reglen); - bzero(krp->krp_param[NOFN_MODEXP_PAR_C].crp_p + reglen, + bzero(krp->krp_param[krp->krp_iparams].crp_p + reglen, crplen - reglen); } bzero(&sc->sc_pk_tmp, sizeof(sc->sc_pk_tmp)); |