diff options
Diffstat (limited to 'kernel/rpmsg/ethosu_rpmsg_cancel_inference.c')
-rw-r--r-- | kernel/rpmsg/ethosu_rpmsg_cancel_inference.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/kernel/rpmsg/ethosu_rpmsg_cancel_inference.c b/kernel/rpmsg/ethosu_rpmsg_cancel_inference.c index 5fa7515..b07c0ec 100644 --- a/kernel/rpmsg/ethosu_rpmsg_cancel_inference.c +++ b/kernel/rpmsg/ethosu_rpmsg_cancel_inference.c @@ -83,8 +83,11 @@ int ethosu_rpmsg_cancel_inference_request(struct device *dev, devm_kzalloc(dev, sizeof(struct ethosu_rpmsg_cancel_inference), GFP_KERNEL); - if (!cancellation) + if (!cancellation) { + dev_err(dev, "Cancel inference. Failed to allocate struct"); + return -ENOMEM; + } /* increase ref count on the inference we are refering to */ ethosu_rpmsg_inference_get(inf); |