Hi folks, crypto(9) describes functions and constants that are not part of crypto/cryptodev.h anymore (see 1.58 -> 1.60), this patch fixes that.
Cheers, -- Vincent / dermiste Index: crypto.9 =================================================================== RCS file: /cvs/src/share/man/man9/crypto.9,v retrieving revision 1.37 diff -u -p -r1.37 crypto.9 --- crypto.9 20 Aug 2014 11:23:42 -0000 1.37 +++ crypto.9 2 May 2015 20:02:31 -0000 @@ -28,21 +28,15 @@ .Ft int .Fn crypto_register "u_int32_t" "int *" "int (*)(u_int32_t *, struct cryptoini *)" "int (*)(u_int64_t)" "int (*)(struct cryptop *)" .Ft int -.Fn crypto_kregister "u_int32_t" "int *" "int (*)(struct cryptkop *)" -.Ft int .Fn crypto_unregister "u_int32_t" "int" .Ft void .Fn crypto_done "struct cryptop *" -.Ft void -.Fn crypto_kdone "struct cryptkop *" .Ft int .Fn crypto_newsession "u_int64_t *" "struct cryptoini *" "int" .Ft int .Fn crypto_freesession "u_int64_t" .Ft int .Fn crypto_dispatch "struct cryptop *" -.Ft int -.Fn crypto_kdispatch "struct cryptkop *" .Ft struct cryptop * .Fn crypto_getreq "int" .Ft void @@ -84,23 +78,6 @@ struct cryptop { caddr_t crp_mac; }; -struct crparam { - caddr_t crp_p; - u_int crp_nbits; -}; - -#define CRK_MAXPARAM 8 - -struct cryptkop { - u_int krp_op; /* ie. CRK_MOD_EXP or other */ - u_int krp_status; /* return status */ - u_short krp_iparams; /* # of input parameters */ - u_short krp_oparams; /* # of output parameters */ - u_int32_t krp_hid; - struct crparam krp_param[CRK_MAXPARAM]; /* kvm */ - int (*krp_callback)(struct cryptkop *); - struct cryptkop *krp_next; -}; .Ed .Sh DESCRIPTION .Nm @@ -119,11 +96,6 @@ descriptors that instruct the framework with it) of the operations that should be applied on the data (more than one cryptographic operation can be requested). .Pp -Keying operations are supported as well. -Unlike the symmetric operators described above, -these sessionless commands perform mathematical operations using -input and output parameters. -.Pp Since the consumers may not be associated with a process, drivers may not use .Xr tsleep 9 . @@ -168,8 +140,6 @@ CRYPTO_CAST_CBC CRYPTO_MD5_HMAC CRYPTO_SHA1_HMAC CRYPTO_RIPEMD160_HMAC -CRYPTO_MD5_KPDK -CRYPTO_SHA1_KPDK CRYPTO_AES_CBC CRYPTO_AES_CTR CRYPTO_AES_XTS @@ -391,37 +361,11 @@ callback routine to do the necessary cle opaque field in the .Fa cryptop structure. -.Pp -.Fn crypto_kdispatch -is called to perform a keying operation. -The various fields in the -.Fa cryptkop -structure are: -.Bl -tag -width crp_alloctype -.It Fa krp_op -Operation code, such as CRK_MOD_EXP. -.It Fa krp_status -Return code. -This errno-style variable indicates whether there were lower level reasons -for operation failure. -.It Fa krp_iparams -Number of input parameters to the specified operation. -Note that each operation has a (typically hardwired) number of such parameters. -.It Fa krp_oparams -Number of output parameters from the specified operation. -Note that each operation has a (typically hardwired) number of such parameters. -.It Fa krp_kvp -An array of kernel memory blocks containing the parameters. -.It Fa krp_hid -Identifier specifying which low-level driver is being used. -.It Fa krp_callback -Callback called on completion of a keying operation. .El .Sh DRIVER-SIDE API The .Fn crypto_get_driverid , .Fn crypto_register , -.Fn crypto_kregister , .Fn crypto_unregister , and .Fn crypto_done @@ -465,7 +409,6 @@ The calling convention for the three dri int (*newsession) (u_int32_t *, struct cryptoini *); int (*freesession) (u_int64_t); int (*process) (struct cryptop *); -int (*kprocess) (struct cryptkop *); .Ed .Pp On invocation, the first argument to @@ -501,24 +444,8 @@ routine should invoke .Fn crypto_done . Session migration may be performed, as mentioned previously. .Pp -The -.Fn kprocess -routine is invoked with a request to perform crypto key processing. -This routine must not block, but should queue the request and return -immediately. -Upon processing the request, the callback routine should be invoked. -In case of error, the error indication must be placed in the -.Fa krp_status -field of the -.Fa cryptkop -structure. -When the request is completed, or an error is detected, the -.Fn kprocess -routine should invoke -.Fn crypto_kdone . .Sh RETURN VALUES .Fn crypto_register , -.Fn crypto_kregister , .Fn crypto_unregister , .Fn crypto_newsession , and