Displaying 2 results from an estimated 2 matches for "free_img_sig".
2017 May 08
0
[PATCH] drm/nouveau/secboot: fix some error handling in 'ls_ucode_img_load_gr'
...size, GFP_KERNEL);
if (!img->sig) {
ret = -ENOMEM;
@@ -127,10 +128,12 @@ ls_ucode_img_load_gr(const struct nvkm_subdev *subdev, struct ls_ucode_img *img,
&img->ucode_desc);
if (IS_ERR(img->ucode_data)) {
ret = PTR_ERR(img->ucode_data);
- goto free_data;
+ goto free_img_sig;
}
img->ucode_size = img->ucode_desc.image_size;
+free_img_sig:
+ kfree(img->sig);
free_sig:
nvkm_firmware_put(sig);
free_data:
--
2.11.0
2017 May 08
0
[PATCH] drm/nouveau/secboot: fix some error handling in 'ls_ucode_img_load_gr'
...nst struct nvkm_subdev *subdev, struct ls_ucode_img *img,
> &img->ucode_desc);
> if (IS_ERR(img->ucode_data)) {
> ret = PTR_ERR(img->ucode_data);
> - goto free_data;
> + goto free_img_sig;
Thus I'd just move the free here and use goto free_sig.
Regards,
Emil