1.\" $OpenBSD: hifn.4,v 1.32 2002/09/26 07:55:40 miod Exp $ 2.\" 3.\" Copyright (c) 2000 Theo de Raadt 4.\" All rights reserved. 5.\" 6.\" Redistribution and use in source and binary forms, with or without 7.\" modification, are permitted provided that the following conditions 8.\" are met: 9.\" 1. Redistributions of source code must retain the above copyright 10.\" notice, this list of conditions and the following disclaimer. 11.\" 2. Redistributions in binary form must reproduce the above copyright 12.\" notice, this list of conditions and the following disclaimer in the 13.\" documentation and/or other materials provided with the distribution. 14.\" 15.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR 16.\" IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 17.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 18.\" DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, 19.\" INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES 20.\" (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 21.\" SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 22.\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, 23.\" STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 24.\" ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 25.\" POSSIBILITY OF SUCH DAMAGE. 26.\" 27.\" $FreeBSD$ 28.\" 29.Dd April 1, 2006 30.Dt HIFN 4 31.Os 32.Sh NAME 33.Nm hifn 34.Nd Hifn 7751/7951/7811/7955/7956 crypto accelerator 35.Sh SYNOPSIS 36To compile this driver into the kernel, 37place the following lines in your 38kernel configuration file: 39.Bd -ragged -offset indent 40.Cd "device crypto" 41.Cd "device cryptodev" 42.Cd "device hifn" 43.Ed 44.Pp 45Alternatively, to load the driver as a 46module at boot time, place the following line in 47.Xr loader.conf 5 : 48.Bd -literal -offset indent 49hifn_load="YES" 50.Ed 51.Sh DESCRIPTION 52The 53.Nm 54driver supports various cards containing the Hifn 7751, 7951, 557811, 7955, and 7956 chipsets. 56.Pp 57The 58.Nm 59driver registers itself to accelerate DES, Triple-DES, 60AES (7955 and 7956 only), ARC4, MD5, 61MD5-HMAC, SHA1, and SHA1-HMAC operations for 62.Xr ipsec 4 63and 64.Xr crypto 4 . 65.Pp 66The Hifn 67.Tn 7951 , 68.Tn 7811 , 69.Tn 7955 , 70and 71.Tn 7956 72will also supply data to the kernel 73.Xr random 4 74subsystem. 75.Sh HARDWARE 76The 77.Nm 78driver supports various cards containing the Hifn 7751, 7951, 797811, 7955, and 7956 80chipsets, such as: 81.Bl -tag -width namenamenamena -offset indent 82.It Invertex AEON 83No longer being made. 84Came as 128KB SRAM model, or 2MB DRAM model. 85.It Hifn 7751 86Reference board with 512KB SRAM. 87.It PowerCrypt 88See 89.Pa http://www.powercrypt.com/ . 90Comes with 512KB SRAM. 91.It XL-Crypt 92See 93.Pa http://www.powercrypt.com/ . 94Only board based on 7811 (which is faster than 7751 and has 95a random number generator). 96.It NetSec 7751 97See 98.Pa http://www.netsec.net/ . 99Supports the most IPsec sessions, with 1MB SRAM. 100.It Soekris Engineering vpn1201 and vpn1211 101See 102.Pa http://www.soekris.com/ . 103Contains a 7951 and supports symmetric and random number operations. 104.It Soekris Engineering vpn1401 and vpn1411 105See 106.Pa http://www.soekris.com/ . 107Contains a 7955 and supports symmetric and random number operations. 108.El 109.Sh SEE ALSO 110.Xr crypt 3 , 111.Xr crypto 4 , 112.Xr intro 4 , 113.Xr ipsec 4 , 114.Xr random 4 , 115.Xr crypto 9 116.Sh CAVEATS 117The Hifn 9751 shares the same PCI ID. 118This chip is basically a 7751, but with the cryptographic functions missing. 119Instead, the 9751 is only capable of doing compression. 120Since we do not currently attempt to use any of these chips to do 121compression, the 9751-based cards are not useful. 122.Pp 123Support for the 7955 and 7956 is incomplete; the asymmetric crypto 124facilities are to be added and the performance is suboptimal. 125.Sh HISTORY 126The 127.Nm 128device driver appeared in 129.Ox 2.7 . 130The 131.Nm 132device driver was imported to 133.Fx 5.0 . 134.Sh BUGS 135The 7751 chip starts out at initialization by only supporting compression. 136A proprietary algorithm, which has been reverse engineered, is required to 137unlock the cryptographic functionality of the chip. 138It is possible for vendors to make boards which have a lock ID not known 139to the driver, but all vendors currently just use the obvious ID which is 14013 bytes of 0. 141