AMD Geode LX crypto accelerator (glxsb)
Ivan Voras
ivoras at freebsd.org
Sun Jun 22 17:26:52 UTC 2008
Patrick Lamaizière wrote:
> Le Fri, 6 Jun 2008 23:41:35 +0200,
> Patrick Lamaizière <patfbsd at davenulle.org> a écrit :
>
> Hello,
>
>> I'm trying to port the glxsb driver from OpenBSD to FreeBSD 7-STABLE
>> (via the NetBSD port).
>> " The glxsb driver supports the security block of the Geode LX
>> series processors. The Geode LX is a member of the AMD Geode family
>> of integrated x86 system chips.
>>
>> Driven by periodic checks for available data from the generator,
>> glxsb supplies entropy to the random(4) driver for common usage.
>>
>> glxsb also supports acceleration of AES-128-CBC operations for
>> crypto(4)."
>
> Well, I hope this is the final version.
>
> http://user.lamaiziere.net/patrick/glxsb-220608.tar.gz
>
> I added a patch for FreeBSD 6 but i'am not able to test it.
>
> On 7-STABLE, I've tested with hundred openssl encryptions and some flood
> pings under ipsec in the background. Looks good for me.
>
> If someone can test and review it, it would be cool.
Hi,
I'm having trouble testing it. My CPU is Geode LX:
CPU: Geode(TM) Integrated Processor by AMD PCS (499.91-MHz 586-class CPU)
Origin = "AuthenticAMD" Id = 0x5a2 Stepping = 2
Features=0x88a93d<FPU,DE,PSE,TSC,MSR,CX8,SEP,PGE,CMOV,CLFLUSH,MMX>
AMD Features=0xc0400000<MMX+,3DNow!+,3DNow!>
When loading the driver, it attaches:
Jun 22 18:49:41 ursaminor kernel: cryptosoft0: <software crypto> on
motherboard
Jun 22 18:49:41 ursaminor kernel: glxsb0: <AMD Geode LX Security Block
(AES-128-CBC,RNG)> mem 0xe0210000-0xe0213fff irq 11 at device 1.2 on pci0
I have the following klds loaded:
7 1 0xc3819000 4000 glxsb.ko
8 2 0xc389d000 23000 crypto.ko
9 2 0xc38c0000 a000 zlib.ko
10 1 0xc381e000 4000 cryptodev.ko
Running openssl speed without cryptodev gives:
> openssl speed aes-128-cbc
To get the most accurate results, try to run this
program when this computer is idle.
Doing aes-128 cbc for 3s on 16 size blocks: 1005506 aes-128 cbc's in 0.98s
Doing aes-128 cbc for 3s on 64 size blocks: 262185 aes-128 cbc's in 0.98s
Doing aes-128 cbc for 3s on 256 size blocks: 66055 aes-128 cbc's in 0.97s
Doing aes-128 cbc for 3s on 1024 size blocks: 16680 aes-128 cbc's in 0.98s
Doing aes-128 cbc for 3s on 8192 size blocks: 2086 aes-128 cbc's in 0.98s
OpenSSL 0.9.8e 23 Feb 2007
built on: Tue Apr 15 19:40:37 CEST 2008
options:bn(64,32) md2(int) rc4(idx,int) des(ptr,risc1,16,long)
aes(partial) blowfish(idx)
compiler: cc
available timing options: USE_TOD HZ=128 [sysconf value]
timing function used: getrusage
The 'numbers' are in 1000s of bytes per second processed.
type 16 bytes 64 bytes 256 bytes 1024 bytes 8192
bytes
aes-128 cbc 16465.91k 17171.01k 17422.55k 17486.30k
17485.16k
But running it with cryptodev gives:
> openssl speed aes-128-cbc -engine cryptodev
engine "cryptodev" set.
To get the most accurate results, try to run this
program when this computer is idle.
Doing aes-128 cbc for 3s on 16 size blocks: 1007404 aes-128 cbc's in 0.97s
Doing aes-128 cbc for 3s on 64 size blocks: 262177 aes-128 cbc's in 0.98s
Doing aes-128 cbc for 3s on 256 size blocks: 66500 aes-128 cbc's in 0.98s
Doing aes-128 cbc for 3s on 1024 size blocks: 16564 aes-128 cbc's in 0.97s
Doing aes-128 cbc for 3s on 8192 size blocks: 2087 aes-128 cbc's in 0.98s
OpenSSL 0.9.8e 23 Feb 2007
built on: Tue Apr 15 19:40:37 CEST 2008
options:bn(64,32) md2(int) rc4(idx,int) des(ptr,risc1,16,long)
aes(partial) blowfish(idx)
compiler: cc
available timing options: USE_TOD HZ=128 [sysconf value]
timing function used: getrusage
The 'numbers' are in 1000s of bytes per second processed.
type 16 bytes 64 bytes 256 bytes 1024 bytes 8192
bytes
aes-128 cbc 16545.20k 17173.92k 17417.71k 17476.48k
17485.82k
The results are practically the same.
This is on 7-STABLE from April.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 250 bytes
Desc: OpenPGP digital signature
Url : http://lists.freebsd.org/pipermail/freebsd-stable/attachments/20080622/055ee493/signature.pgp
More information about the freebsd-stable
mailing list