Skip to content

Commit 0919a5b

Browse files
committed
Merge tag 'soc-arm-6.17' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc
Pull ARM SoC code updates from Arnd Bergmann: "Another small set of code changes for the 32-bit Arm platforms, and a trivial update to the Kconfig entry for the arm64 TI K3 chip. Andrew Davis cleans up the system reset handling, which touches a couple of platforms. The mediatek platform needs some code changes to support multiprocessing in the newly added support for the old mt6572 chip" * tag 'soc-arm-6.17' of git://git.kernel.org/pub/scm/linux/kernel/git/soc/soc: ARM: sa110/gpio: convert set_multiple() to returning an integer ARM: rockchip: fix kernel hang during smp initialization ARM: mediatek: add MT6572 smp bring up code ARM: mediatek: add board_dt_compat entry for the MT6572 SoC ARM: tegra: Use I/O memcpy to write to IRAM arm: orion: use string choices helper ARM: Switch to new sys-off handler API arm64: Kconfig.platforms: remove useless select for ARCH_K3
2 parents 4c10d22 + 8c1f5a1 commit 0919a5b

File tree

13 files changed

+35
-22
lines changed

13 files changed

+35
-22
lines changed

arch/arm/common/sa1111.c

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -578,8 +578,8 @@ static int sa1111_gpio_set(struct gpio_chip *gc, unsigned int offset, int value)
578578
return 0;
579579
}
580580

581-
static void sa1111_gpio_set_multiple(struct gpio_chip *gc, unsigned long *mask,
582-
unsigned long *bits)
581+
static int sa1111_gpio_set_multiple(struct gpio_chip *gc, unsigned long *mask,
582+
unsigned long *bits)
583583
{
584584
struct sa1111 *sachip = gc_to_sa1111(gc);
585585
unsigned long flags;
@@ -597,6 +597,8 @@ static void sa1111_gpio_set_multiple(struct gpio_chip *gc, unsigned long *mask,
597597
sa1111_gpio_modify(reg + SA1111_GPIO_PCDWR, (msk >> 12) & 255, val >> 12);
598598
sa1111_gpio_modify(reg + SA1111_GPIO_PCSSR, (msk >> 12) & 255, val >> 12);
599599
spin_unlock_irqrestore(&sachip->lock, flags);
600+
601+
return 0;
600602
}
601603

602604
static int sa1111_gpio_to_irq(struct gpio_chip *gc, unsigned offset)
@@ -616,7 +618,7 @@ static int sa1111_setup_gpios(struct sa1111 *sachip)
616618
sachip->gc.direction_output = sa1111_gpio_direction_output;
617619
sachip->gc.get = sa1111_gpio_get;
618620
sachip->gc.set_rv = sa1111_gpio_set;
619-
sachip->gc.set_multiple = sa1111_gpio_set_multiple;
621+
sachip->gc.set_multiple_rv = sa1111_gpio_set_multiple;
620622
sachip->gc.to_irq = sa1111_gpio_to_irq;
621623
sachip->gc.base = -1;
622624
sachip->gc.ngpio = 18;

arch/arm/mach-highbank/highbank.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@ static void __init highbank_init(void)
143143
sregs_base = of_iomap(np, 0);
144144
WARN_ON(!sregs_base);
145145

146-
pm_power_off = highbank_power_off;
146+
register_platform_power_off(highbank_power_off);
147147
highbank_pm_init();
148148

149149
bus_register_notifier(&platform_bus_type, &highbank_platform_nb);

arch/arm/mach-mediatek/Kconfig

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,10 @@ config MACH_MT2701
1515
bool "MediaTek MT2701 SoCs support"
1616
default ARCH_MEDIATEK
1717

18+
config MACH_MT6572
19+
bool "MediaTek MT6572 SoCs support"
20+
default ARCH_MEDIATEK
21+
1822
config MACH_MT6589
1923
bool "MediaTek MT6589 SoCs support"
2024
default ARCH_MEDIATEK

arch/arm/mach-mediatek/mediatek.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,7 @@ static void __init mediatek_timer_init(void)
3838

3939
static const char * const mediatek_board_dt_compat[] = {
4040
"mediatek,mt2701",
41+
"mediatek,mt6572",
4142
"mediatek,mt6589",
4243
"mediatek,mt6592",
4344
"mediatek,mt7623",

arch/arm/mach-mediatek/platsmp.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,12 @@ static const struct mtk_smp_boot_info mtk_mt8135_tz_boot = {
2929
{ 0x3f8, 0x3f8, 0x3f8 },
3030
};
3131

32+
static const struct mtk_smp_boot_info mtk_mt6572_boot = {
33+
0x10001400, 0x08,
34+
{ 0x534c4131 },
35+
{ 0x0c },
36+
};
37+
3238
static const struct mtk_smp_boot_info mtk_mt6589_boot = {
3339
0x10002000, 0x34,
3440
{ 0x534c4131, 0x4c415332, 0x41534c33 },
@@ -49,6 +55,7 @@ static const struct of_device_id mtk_tz_smp_boot_infos[] __initconst = {
4955
};
5056

5157
static const struct of_device_id mtk_smp_boot_infos[] __initconst = {
58+
{ .compatible = "mediatek,mt6572", .data = &mtk_mt6572_boot },
5259
{ .compatible = "mediatek,mt6589", .data = &mtk_mt6589_boot },
5360
{ .compatible = "mediatek,mt7623", .data = &mtk_mt7623_boot },
5461
{ .compatible = "mediatek,mt7629", .data = &mtk_mt7623_boot },

arch/arm/mach-pxa/spitz.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1096,7 +1096,7 @@ static void __init spitz_init(void)
10961096
software_node_register(&spitz_scoop_2_gpiochip_node);
10971097

10981098
init_gpio_reset(SPITZ_GPIO_ON_RESET, 1, 0);
1099-
pm_power_off = spitz_poweroff;
1099+
register_platform_power_off(spitz_poweroff);
11001100

11011101
PMCR = 0x00;
11021102

arch/arm/mach-rockchip/platsmp.c

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -279,11 +279,6 @@ static void __init rockchip_smp_prepare_cpus(unsigned int max_cpus)
279279
}
280280

281281
if (read_cpuid_part() == ARM_CPU_PART_CORTEX_A9) {
282-
if (rockchip_smp_prepare_sram(node)) {
283-
of_node_put(node);
284-
return;
285-
}
286-
287282
/* enable the SCU power domain */
288283
pmu_set_power_domain(PMU_PWRDN_SCU, true);
289284

@@ -316,11 +311,19 @@ static void __init rockchip_smp_prepare_cpus(unsigned int max_cpus)
316311
asm ("mrc p15, 1, %0, c9, c0, 2\n" : "=r" (l2ctlr));
317312
ncores = ((l2ctlr >> 24) & 0x3) + 1;
318313
}
319-
of_node_put(node);
320314

321315
/* Make sure that all cores except the first are really off */
322316
for (i = 1; i < ncores; i++)
323317
pmu_set_power_domain(0 + i, false);
318+
319+
if (read_cpuid_part() == ARM_CPU_PART_CORTEX_A9) {
320+
if (rockchip_smp_prepare_sram(node)) {
321+
of_node_put(node);
322+
return;
323+
}
324+
}
325+
326+
of_node_put(node);
324327
}
325328

326329
static void __init rk3036_smp_prepare_cpus(unsigned int max_cpus)

arch/arm/mach-sa1100/generic.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -298,7 +298,7 @@ static struct platform_device *sa11x0_devices[] __initdata = {
298298
static int __init sa1100_init(void)
299299
{
300300
struct resource wdt_res = DEFINE_RES_MEM(0x90000000, 0x20);
301-
pm_power_off = sa1100_power_off;
301+
register_platform_power_off(sa1100_power_off);
302302

303303
regulator_has_full_constraints();
304304

arch/arm/mach-tegra/reset.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ static void __init tegra_cpu_reset_handler_enable(void)
6363
BUG_ON(is_enabled);
6464
BUG_ON(tegra_cpu_reset_handler_size > TEGRA_IRAM_RESET_HANDLER_SIZE);
6565

66-
memcpy(iram_base, (void *)__tegra_cpu_reset_handler_start,
66+
memcpy_toio(iram_base, (void *)__tegra_cpu_reset_handler_start,
6767
tegra_cpu_reset_handler_size);
6868

6969
err = call_firmware_op(set_cpu_boot_addr, 0, reset_address);

arch/arm/mach-vt8500/vt8500.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ static void __init vt8500_init(void)
141141
pr_err("%s:ioremap(power_off) failed\n", __func__);
142142
}
143143
if (pmc_base)
144-
pm_power_off = &vt8500_power_off;
144+
register_platform_power_off(vt8500_power_off);
145145
else
146146
pr_err("%s: PMC Hibernation register could not be remapped, not enabling power off!\n", __func__);
147147
}

0 commit comments

Comments
 (0)