]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
can: ucan: fix non-atomic allocation in completion handler
authorJohan Hovold <johan@kernel.org>
Thu, 28 Nov 2019 18:26:03 +0000 (19:26 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 13 Dec 2019 07:49:38 +0000 (08:49 +0100)
commit333b7396439ac287013e51c3d493f37afa639c34
treee6acabb2539184da9c87c2ba2b7bb1b2595ba4c7
parente081b64f18b420a12c9eff18c7e1e35753db249d
can: ucan: fix non-atomic allocation in completion handler

commit 870db5d1015c8bd63e93b579e857223c96249ff7 upstream.

USB completion handlers are called in atomic context and must
specifically not allocate memory using GFP_KERNEL.

Fixes: 9f2d3eae88d2 ("can: ucan: add driver for Theobroma Systems UCAN devices")
Cc: stable <stable@vger.kernel.org> # 4.19
Cc: Jakob Unterwurzacher <jakob.unterwurzacher@theobroma-systems.com>
Cc: Martin Elshuber <martin.elshuber@theobroma-systems.com>
Cc: Philipp Tomsich <philipp.tomsich@theobroma-systems.com>
Signed-off-by: Johan Hovold <johan@kernel.org>
Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/net/can/usb/ucan.c