]> asedeno.scripts.mit.edu Git - linux.git/commit
x86/power/hibernate_64: Remove VLA usage
authorKees Cook <keescook@chromium.org>
Tue, 24 Jul 2018 16:49:28 +0000 (09:49 -0700)
committerRafael J. Wysocki <rafael.j.wysocki@intel.com>
Thu, 26 Jul 2018 08:26:31 +0000 (10:26 +0200)
commitc2cd0b08e1efd9ee58d09049a6c77e5efa0ef627
treeb771156d6c486adbbc39d589a880fdfe17df90dc
parentd5641c64c48f4408500a348301bff01fbf2c1ec5
x86/power/hibernate_64: Remove VLA usage

In the quest to remove all stack VLA usage from the kernel [1], this
removes the discouraged use of AHASH_REQUEST_ON_STACK by switching to
shash directly and allocating the descriptor in heap memory (which should
be fine: the tfm has already been allocated there too).

Link: https://lkml.kernel.org/r/CA+55aFzCG-zNmZwX4A2FQpadafLfEzK6CC=qPXydAacU1RqZWA@mail.gmail.com
Signed-off-by: Kees Cook <keescook@chromium.org>
Acked-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
arch/x86/power/hibernate_64.c