diff options
author | Kang Chen <void0red@gmail.com> | 2023-02-25 12:11:48 +0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2023-03-09 15:33:14 +0100 |
commit | 5aacc9d540cea790fe4419b61bfa8a1218a4474a (patch) | |
tree | cfd217490cbb8c43ec6c9d170c4ccfab44be766a /drivers/usb/cdns3/cdns3-debug.h | |
parent | 2ae4e0dea3b0c7b380821bac05e03a71da1f452f (diff) | |
download | linux-5aacc9d540cea790fe4419b61bfa8a1218a4474a.tar.gz linux-5aacc9d540cea790fe4419b61bfa8a1218a4474a.tar.bz2 linux-5aacc9d540cea790fe4419b61bfa8a1218a4474a.zip |
usb: gadget: udc: add return value check of kzalloc in mv_udc_probe
Even an 8-byte kzalloc will fail when we don't have enough memory,
so we need a nullptr check and do the cleanup when it fails.
Reported-by: eriri <1527030098@qq.com>
Link: https://bugzilla.kernel.org/show_bug.cgi?id=217081
Signed-off-by: Kang Chen <void0red@gmail.com>
Link: https://lore.kernel.org/r/20230225041149.136-1-void0red@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/cdns3/cdns3-debug.h')
0 files changed, 0 insertions, 0 deletions