Re: [PATCH 1/2] x86, crypto, Generate .byte code for some new instructions via gas macro

2009-11-09 Thread Herbert Xu
On Sun, Nov 08, 2009 at 11:56:19AM +0100, Ingo Molnar wrote: I'm not Ingo, but: Acked-by: H. Peter Anvin h...@zytor.com Fine to me too and for future variations thereof. Thanks guys I'll put this into cryptodev now. -- Visit Openswan at http://www.openswan.org/ Email: Herbert Xu

Re: [PATCH 2/2] x86, crypto, Use gas macro for AES-NI instructions

2009-11-09 Thread Herbert Xu
On Thu, Nov 05, 2009 at 02:44:17PM +0800, Huang Ying wrote: Old binutils do not support AES-NI instructions, to make kernel can be compiled by them, .byte code is used instead of AES-NI assembly instructions. But the readability and flexibility of raw .byte code is not good. So

Re: [PATCH 2/2] x86, crypto, Use gas macro for AES-NI instructions

2009-11-09 Thread Huang Ying
On Tue, 2009-11-10 at 02:56 +0800, Herbert Xu wrote: On Thu, Nov 05, 2009 at 02:44:17PM +0800, Huang Ying wrote: Old binutils do not support AES-NI instructions, to make kernel can be compiled by them, .byte code is used instead of AES-NI assembly instructions. But the readability and

Re: [BUGFIX -v2 for .32] crypto, gcm, fix another complete call in complete fuction

2009-11-09 Thread Herbert Xu
On Tue, Nov 10, 2009 at 10:49:59AM +0800, Huang Ying wrote: Yes. This is for performance only. Because crypto_gcm_reqctx(req) is not so trivial (it needs access tfm), and used by every xxx_done function, so I think it is better to just call crypto_gcm_reqctx once and pass it down. Do you

[BUGFIX -v3 for .32] crypto, gcm, fix another complete call in complete fuction

2009-11-09 Thread Huang Ying
The flow of the complete function (xxx_done) in gcm.c is as follow: void complete(struct crypto_async_request *areq, int err) { struct aead_request *req = areq-data; if (!err) { err = async_next_step(); if (err == -EINPROGRESS || err == -EBUSY)

[PATCH 2/2] x86, crypto, Use gas macro for PCLMULQDQ-NI and PSHUFB

2009-11-09 Thread Huang Ying
Old binutils do not support PCLMULQDQ-NI and PSHUFB, to make kernel can be compiled by them, .byte code is used instead of assembly instructions. But the readability and flexibility of raw .byte code is not good. So corresponding assembly instruction like gas macro is used instead.

[PATCH 1/2] x86, crypto, Use gas macro for AES-NI instructions

2009-11-09 Thread Huang Ying
Old binutils do not support AES-NI instructions, to make kernel can be compiled by them, .byte code is used instead of AES-NI assembly instructions. But the readability and flexibility of raw .byte code is not good. So corresponding assembly instruction like gas macro is used instead.