Skip to content

Commit 5378e46

Browse files
committed
Merge tag 'tegra-for-4.3-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux into next/drivers
ARM: tegra: Core SoC changes for v4.3-rc1 This contains a bit more of Tegra210 support, which is shaping up pretty nicely. Other than that there are a couple of cleanup patches here, too. * tag 'tegra-for-4.3-soc' of git://git.kernel.org/pub/scm/linux/kernel/git/tegra/linux: ARM: tegra: cpuidle: implement cpuidle_state.enter_freeze() ARM: tegra: Disable cpuidle if PSCI is available soc/tegra: pmc: Use existing pclk reference soc/tegra: pmc: Remove unnecessary return statement soc: tegra: Remove redundant $(CONFIG_ARCH_TEGRA) in Makefile soc/tegra: fuse: Add spare bit offset for Tegra210 soc/tegra: fuse: Add spare bit offset for Tegra124 soc/tegra: fuse: Add spare bit offset for Tegra114 soc/tegra: fuse: Rename core_* to soc_* soc/tegra: fuse: Add Tegra210 support soc/tegra: fuse: Unify Tegra20 and Tegra30 drivers soc/tegra: fuse: Restrict legacy code to 32-bit ARM soc/tegra: pmc: Add Tegra210 support soc/tegra: pmc: Restrict legacy code to 32-bit ARM soc/tegra: pmc: Avoid usage of uninitialized variable soc/tegra: Add Tegra210 support soc/tegra: Add Tegra132 support Signed-off-by: Olof Johansson <[email protected]>
2 parents bd90f11 + 1ec0e11 commit 5378e46

File tree

18 files changed

+853
-458
lines changed

18 files changed

+853
-458
lines changed

arch/arm/mach-tegra/cpuidle-tegra114.c

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
#include <asm/cpuidle.h>
2525
#include <asm/smp_plat.h>
2626
#include <asm/suspend.h>
27+
#include <asm/psci.h>
2728

2829
#include "pm.h"
2930
#include "sleep.h"
@@ -44,23 +45,26 @@ static int tegra114_idle_power_down(struct cpuidle_device *dev,
4445
tegra_set_cpu_in_lp2();
4546
cpu_pm_enter();
4647

47-
tick_broadcast_enter();
48-
4948
call_firmware_op(prepare_idle);
5049

5150
/* Do suspend by ourselves if the firmware does not implement it */
5251
if (call_firmware_op(do_idle, 0) == -ENOSYS)
5352
cpu_suspend(0, tegra30_sleep_cpu_secondary_finish);
5453

55-
tick_broadcast_exit();
56-
5754
cpu_pm_exit();
5855
tegra_clear_cpu_in_lp2();
5956

6057
local_fiq_enable();
6158

6259
return index;
6360
}
61+
62+
static void tegra114_idle_enter_freeze(struct cpuidle_device *dev,
63+
struct cpuidle_driver *drv,
64+
int index)
65+
{
66+
tegra114_idle_power_down(dev, drv, index);
67+
}
6468
#endif
6569

6670
static struct cpuidle_driver tegra_idle_driver = {
@@ -72,8 +76,10 @@ static struct cpuidle_driver tegra_idle_driver = {
7276
#ifdef CONFIG_PM_SLEEP
7377
[1] = {
7478
.enter = tegra114_idle_power_down,
79+
.enter_freeze = tegra114_idle_enter_freeze,
7580
.exit_latency = 500,
7681
.target_residency = 1000,
82+
.flags = CPUIDLE_FLAG_TIMER_STOP,
7783
.power_usage = 0,
7884
.name = "powered-down",
7985
.desc = "CPU power gated",
@@ -84,5 +90,8 @@ static struct cpuidle_driver tegra_idle_driver = {
8490

8591
int __init tegra114_cpuidle_init(void)
8692
{
87-
return cpuidle_register(&tegra_idle_driver, NULL);
93+
if (!psci_smp_available())
94+
return cpuidle_register(&tegra_idle_driver, NULL);
95+
96+
return 0;
8897
}

arch/arm/mach-tegra/iomap.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -82,9 +82,6 @@
8282
#define TEGRA_EMC_BASE 0x7000F400
8383
#define TEGRA_EMC_SIZE SZ_1K
8484

85-
#define TEGRA_FUSE_BASE 0x7000F800
86-
#define TEGRA_FUSE_SIZE SZ_1K
87-
8885
#define TEGRA_EMC0_BASE 0x7001A000
8986
#define TEGRA_EMC0_SIZE SZ_2K
9087

drivers/soc/tegra/Makefile

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
obj-$(CONFIG_ARCH_TEGRA) += fuse/
1+
obj-y += fuse/
22

3-
obj-$(CONFIG_ARCH_TEGRA) += common.o
4-
obj-$(CONFIG_ARCH_TEGRA) += pmc.o
3+
obj-y += common.o
4+
obj-y += pmc.o

drivers/soc/tegra/common.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ static const struct of_device_id tegra_machine_match[] = {
1515
{ .compatible = "nvidia,tegra30", },
1616
{ .compatible = "nvidia,tegra114", },
1717
{ .compatible = "nvidia,tegra124", },
18+
{ .compatible = "nvidia,tegra132", },
19+
{ .compatible = "nvidia,tegra210", },
1820
{ }
1921
};
2022

drivers/soc/tegra/fuse/Makefile

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,5 @@ obj-$(CONFIG_ARCH_TEGRA_2x_SOC) += speedo-tegra20.o
66
obj-$(CONFIG_ARCH_TEGRA_3x_SOC) += speedo-tegra30.o
77
obj-$(CONFIG_ARCH_TEGRA_114_SOC) += speedo-tegra114.o
88
obj-$(CONFIG_ARCH_TEGRA_124_SOC) += speedo-tegra124.o
9+
obj-$(CONFIG_ARCH_TEGRA_132_SOC) += speedo-tegra124.o
10+
obj-$(CONFIG_ARCH_TEGRA_210_SOC) += speedo-tegra210.o

0 commit comments

Comments
 (0)