[PATCH 1/1] pcmcia: Fix resource leaks in yenta_probe() and _close()

2015-06-14 Thread Takeshi Yoshimura
d In yenta_close(): - kfree(sock) is not called - sock->base is always set to non-NULL when yenta_close() is called, therefore the check in yenta_close() is not necessary. Signed-off-by: Takeshi Yoshimura --- drivers/pcmcia/yenta_socket.c | 33 + 1 file cha

Re: [PATCH 1/1] pcmcia: Add missing free_irq()

2015-06-14 Thread Takeshi Yoshimura
d kfree() appropriately. I guess you meant to kfree() is not called in yenta_close(). > Would you be willing to update your patch to address also these issues? > Then, I'll happily push it upstream. > Sure. I'll send the updated patch in another mail. Regards, Takeshi Yoshimura

[PATCH 1/1] pcmcia: Add missing free_irq()

2015-06-14 Thread Takeshi Yoshimura
In yenta_probe(), an irq leak potentially happens when pcmcia_register_socket() fails. I added the missed call. Signed-off-by: Takeshi Yoshimura --- drivers/pcmcia/yenta_socket.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/pcmcia/yenta_socket.c b/drivers/pcmcia/yenta_socket.c

[PATCH 1/1] wm831x_power: Fix off-by-one at free_irq()

2015-06-14 Thread Takeshi Yoshimura
An error handling in wm831x_power_probe() mistakenly frees a failed-to- request irq as well as other irqs. I added missing decrement of the loop counter. Signed-off-by: Takeshi Yoshimura --- drivers/power/wm831x_power.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/power

[PATCH 1/1] clocksource: sh_mtu2: Fix irq leaks when sh_mtu2_setup() fails

2015-06-14 Thread Takeshi Yoshimura
ensure the consistency of all the clockevent and irqs even if the error occurs. Signed-off-by: Takeshi Yoshimura --- drivers/clocksource/sh_mtu2.c | 65 ++- 1 file changed, 39 insertions(+), 26 deletions(-) diff --git a/drivers/clocksource/sh_mtu2.c b/drivers

[PATCH 1/1] usb: gadget: udc: fix free_irq() after request_irq() failed

2015-06-14 Thread Takeshi Yoshimura
My static checker detected the mistake. I fix this by changing "goto err_irq" to "goto err_req". The label err_irq is not used now so this patch also removes it. Signed-off-by: Takeshi Yoshimura --- drivers/usb/gadget/udc/fotg210-udc.c | 3 +-- 1 file changed, 1 inser

[PATCH 1/1] power_supply: 88pm860x_charger: Do not call free_irq() twice

2015-05-29 Thread Takeshi Yoshimura
My static checker detected double free_irq() in pm860x_charger_remove(). Unloading this module always causes a warning. This patch removes the first redundant free_irq() call. Signed-off-by: Takeshi Yoshimura --- drivers/power/88pm860x_charger.c | 1 - 1 file changed, 1 deletion(-) diff --git

[PATCH 1/1] [media] ddbridge: Do not free_irq() if request_irq() failed

2015-05-27 Thread Takeshi Yoshimura
From: Takeshi Yoshimura My static checker detected that free_irq() is called even after request_irq() failed in ddb_probe(). In this case, the kernel may try to free dev->pdev->irq although the IRQ is not assigned. This event rarely occurs, but always introduces a warning if it h