[PING PATCH] drm/pl111: fix drm and dev leak when irq request failed.

2023-04-16 Thread Gencen Gan
Smatch reports: pl111_amba_probe() warn: missing unwind goto? Code segment for dev_put is: dev_put: drm_dev_put(drm); of_reserved_mem_device_release(dev); When err happened, jumping to dev_put will release drm and dev resources allocated or initiali

[PATCH] drm/pl111: fix drm and dev leak when irq request failed.

2023-04-10 Thread Gencen Gan
From: Gan Gecen Smatch reports: pl111_amba_probe() warn: missing unwind goto? Code segment for dev_put is: dev_put: drm_dev_put(drm); of_reserved_mem_device_release(dev); When err happened, jumping to dev_put will release drm and dev resources all

[PATCH v2] drm/bochs: fix ioremap leak of mmio in bochs

2023-04-01 Thread Gencen Gan
From: Gan Gecen Smatch reports: drivers/gpu/drm/tiny/bochs.c:290 bochs_hw_init() warn: 'bochs->mmio' from ioremap() not released on lines: 246,250,254. In the function bochs_load() that calls bochs_hw_init() only, if bochs_hw_init(dev) returns -ENODEV(-19), it will jumps

[PING PATCH] drm/bochs: replace ioremap with devm_ioremap to avoid immo leak

2023-03-28 Thread Gencen Gan
From: Gan Gecen Smatch reports: drivers/gpu/drm/tiny/bochs.c:290 bochs_hw_init() warn: 'bochs->mmio' from ioremap() not released on lines: 246,250,254. In the function bochs_load() that calls bochs_hw_init() only, if bochs_hw_init(dev) returns -ENODEV(-19), it will jumps

[PATCH] drm/bochs: replace ioremap with devm_ioremap to avoid immo leak

2023-03-22 Thread Gencen Gan
From: Gan Gecen Smatch reports: drivers/gpu/drm/tiny/bochs.c:290 bochs_hw_init() warn: 'bochs->mmio' from ioremap() not released on lines: 246,250,254. In the function bochs_load() that calls bochs_hw_init() only, if bochs_hw_init(dev) returns -ENODEV(-19), it will jumps