HomeFreeBSD

Change movaps to movups in AES-NI code

Description

Change movaps to movups in AES-NI code

Currently, the ICP contains accelerated assembly code to be
used specifically on CPUs with AES-NI enabled. This code
makes heavy use of the movaps instruction which assumes that
it will be provided aes keys that are 16 byte aligned. This
assumption seems to hold on Illumos, but on Linux some kernel
options such as 'slub_debug=P' will violate it. This patch
changes all instances of this instruction to movups which is
the same except that it can handle unaligned memory.

This patch also adds a few flags which were accidentally never
given to the assembly compiler, resulting in objtool warnings.

Reviewed by: Gvozden Neskovic <neskovic@gmail.com>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Reviewed-by: Nathaniel R. Lewis <linux.robotdude@gmail.com>
Signed-off-by: Tom Caputi <tcaputi@datto.com>
Closes #7065
Closes #7108

Details

Provenance
Tom Caputi <tcaputi@datto.com>Authored on Jan 31 2018, 11:17 PM
Brian Behlendorf <behlendorf1@llnl.gov>Committed on Jan 31 2018, 11:17 PM
Parents
rGf90a30ad1b32: Fix txg_sync_thread hang in scan_exec_io()
Branches
Unknown
Tags
Unknown

Event Timeline

Brian Behlendorf <behlendorf1@llnl.gov> committed rGa73c94934f61: Change movaps to movups in AES-NI code (authored by Tom Caputi <tcaputi@datto.com>).Jan 31 2018, 11:17 PM