diff options
author | Jason Wright <jason@cvs.openbsd.org> | 2001-01-29 00:39:22 +0000 |
---|---|---|
committer | Jason Wright <jason@cvs.openbsd.org> | 2001-01-29 00:39:22 +0000 |
commit | a35279642e28744be4bf4c6cfcabf0946cb41dc7 (patch) | |
tree | 048ac6293a9d0b13810e473cfc8e105a73786334 /sys/dev/pci/ubsecreg.h | |
parent | e8fe2bfa385595a419df8f916b7aa1149ff150bf (diff) |
- add infrastructure for dealing with the key generator (MCR2)
- add support for the onboard rng using that structure
- add a interrupt status mask (differs for 5501 and 5601)
- reorganize slightly to take into account that MCR1 isn't the only reason
for interrupts.
Diffstat (limited to 'sys/dev/pci/ubsecreg.h')
-rw-r--r-- | sys/dev/pci/ubsecreg.h | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/sys/dev/pci/ubsecreg.h b/sys/dev/pci/ubsecreg.h index b4b042c1620..59b90e9a4d1 100644 --- a/sys/dev/pci/ubsecreg.h +++ b/sys/dev/pci/ubsecreg.h @@ -1,4 +1,4 @@ -/* $OpenBSD: ubsecreg.h,v 1.7 2000/08/13 22:06:48 deraadt Exp $ */ +/* $OpenBSD: ubsecreg.h,v 1.8 2001/01/29 00:39:20 jason Exp $ */ /* * Copyright (c) 2000 Theo de Raadt @@ -120,3 +120,23 @@ struct ubsec_mcr_add { #define UBS_MCR_DONE 0x0001 /* mcr has been processed */ #define UBS_MCR_ERROR 0x0002 /* error in processing */ #define UBS_MCR_ERRORCODE 0xff00 /* error type */ + +struct ubsec_keyctx { + volatile u_int16_t ctx_len; /* command length */ + volatile u_int16_t ctx_op; /* operation code */ + volatile u_int8_t ctx_pad[60]; /* padding */ +}; +#define UBS_CTXOP_RNGBYPASS 0x41 + +struct ubsec_rngbypass_ctx { + volatile u_int16_t rbp_len; /* command length, 64 */ + volatile u_int16_t rbp_op; /* rng bypass, 0x41 */ + volatile u_int8_t rbp_pad[60]; /* padding */ +}; + +#define UBS_RNGBUFSZ 16 +struct ubsec_rng { + struct ubsec_mcr rng_mcr; + struct ubsec_rngbypass_ctx rng_ctx; + volatile u_int32_t rng_buf[UBS_RNGBUFSZ]; +}; |