[PATCH 3/5] ARM: shmobile: R-Mobile: add missing of_node_put
Geert Uytterhoeven
geert at linux-m68k.org
Mon Oct 12 00:18:52 PDT 2015
Hi Julia,
On Sat, Oct 10, 2015 at 2:30 PM, Julia Lawall <Julia.Lawall at lip6.fr> wrote:
> --- a/arch/arm/mach-shmobile/pm-rmobile.c
> +++ b/arch/arm/mach-shmobile/pm-rmobile.c
> @@ -313,8 +313,10 @@ static int __init rmobile_add_pm_domains(void __iomem *base,
> }
>
> pd = kzalloc(sizeof(*pd), GFP_KERNEL);
> - if (!pd)
> + if (!pd) {
> + of_node_put(np);
> return -ENOMEM;
> + }
While technically this patch is correct, the system will be dead anyway if it
ever goes OOM at core_initcall() time.
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert at linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
More information about the linux-arm-kernel
mailing list