git: padlock - Properly align data

看板DFBSD_commit作者時間15年前 (2010/08/21 21:32), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串1/1
commit a702ec91d1960a1d75cebedfe310096377682ff8 Author: Alex Hornung <ahornung@gmail.com> Date: Sat Aug 21 11:46:17 2010 +0100 padlock - Properly align data * Most parameters to the xcrypt instruction need to be aligned to 16 bytes. So far we haven't been aligning some of the data such as the key, iv and control structure. Refer to the "VIA PadLock Programming Guide" for more details. * Address this by allocating a bit more space and setting stuff up at 16-byte boundaries and ensuring gcc aligns the whole structure 16-bytish. While this wastes some memory, it is negligible. * This fixes the issue with encryption and decryption with padlock causing general protection faults. Reported-by: Jan Lentfer (lentferj@) Summary of changes: sys/crypto/via/padlock.c | 14 +++++++++++--- sys/crypto/via/padlock.h | 3 ++- 2 files changed, 13 insertions(+), 4 deletions(-) http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/a702ec91d1960a1d75cebedfe310096377682ff8 -- DragonFly BSD source repository
文章代碼(AID): #1CRzLTBi (DFBSD_commit)