Skip to content

Commit 552c0e3

Browse files
committed
Merge tag 'at91-soc-5.9' of git://git.kernel.org/pub/scm/linux/kernel/git/at91/linux into arm/soc
AT91 SoC for 5.9 - Two small fixes * tag 'at91-soc-5.9' of git://git.kernel.org/pub/scm/linux/kernel/git/at91/linux: ARM: at91: Replace HTTP links with HTTPS ones ARM: at91: pm: add missing put_device() call in at91_pm_sram_init() Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Arnd Bergmann <[email protected]>
2 parents 5f3991b + f3a49f1 commit 552c0e3

File tree

2 files changed

+9
-4
lines changed

2 files changed

+9
-4
lines changed

arch/arm/mach-at91/Makefile.boot

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
# SPDX-License-Identifier: GPL-2.0-only
22
# Empty file waiting for deletion once Makefile.boot isn't needed any more.
33
# Patch waits for application at
4-
# http://www.arm.linux.org.uk/developer/patches/viewpatch.php?id=7889/1 .
4+
# https://www.arm.linux.org.uk/developer/patches/viewpatch.php?id=7889/1 .

arch/arm/mach-at91/pm.c

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -592,26 +592,31 @@ static void __init at91_pm_sram_init(void)
592592
sram_pool = gen_pool_get(&pdev->dev, NULL);
593593
if (!sram_pool) {
594594
pr_warn("%s: sram pool unavailable!\n", __func__);
595-
return;
595+
goto out_put_device;
596596
}
597597

598598
sram_base = gen_pool_alloc(sram_pool, at91_pm_suspend_in_sram_sz);
599599
if (!sram_base) {
600600
pr_warn("%s: unable to alloc sram!\n", __func__);
601-
return;
601+
goto out_put_device;
602602
}
603603

604604
sram_pbase = gen_pool_virt_to_phys(sram_pool, sram_base);
605605
at91_suspend_sram_fn = __arm_ioremap_exec(sram_pbase,
606606
at91_pm_suspend_in_sram_sz, false);
607607
if (!at91_suspend_sram_fn) {
608608
pr_warn("SRAM: Could not map\n");
609-
return;
609+
goto out_put_device;
610610
}
611611

612612
/* Copy the pm suspend handler to SRAM */
613613
at91_suspend_sram_fn = fncpy(at91_suspend_sram_fn,
614614
&at91_pm_suspend_in_sram, at91_pm_suspend_in_sram_sz);
615+
return;
616+
617+
out_put_device:
618+
put_device(&pdev->dev);
619+
return;
615620
}
616621

617622
static bool __init at91_is_pm_mode_active(int pm_mode)

0 commit comments

Comments
 (0)