]> www.infradead.org Git - users/jedix/linux-maple.git/commit
crypto: scatterwalk - Hide PageSlab call to optimise away flush_dcache_page
authorHerbert Xu <herbert@gondor.apana.org.au>
Mon, 1 Jun 2015 08:22:03 +0000 (16:22 +0800)
committerChuck Anderson <chuck.anderson@oracle.com>
Sun, 26 Feb 2017 05:34:34 +0000 (21:34 -0800)
commit9277f3f76aee2c491f1a3826e0c84be7784fdd2f
tree606c81aff8d54927416466f1981cc6f591ffc181
parentc7f2297f90aa14467e6cfa34f30c0c83d933c62c
crypto: scatterwalk - Hide PageSlab call to optimise away flush_dcache_page

Orabug: 25243093

On architectures where flush_dcache_page is not needed, we will
end up generating all the code up to the PageSlab call.  This is
because PageSlab operates on a volatile pointer and thus cannot
be optimised away.

This patch works around this by checking whether flush_dcache_page
is needed before we call PageSlab which then allows PageSlab to be
compiled awy.

Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
(cherry picked from commit 160544075f2a4028209721723a51f16add7b08b9)
Signed-off-by: Ethan Zhao <ethan.zhao@oracle.com>
crypto/scatterwalk.c