Skip to content

Commit

Permalink
Merge tag 'tegra-for-3.8-single-zimage' of git://git.kernel.org/pub/s…
Browse files Browse the repository at this point in the history
…cm/linux/kernel/git/swarren/linux-tegra into next/multiplatform

From Stephen Warren:
ARM: tegra: single-zImage preparation work

Various cleanups and enhancements are made to core Tegra code towards the
aim of including Tegra in a multi-platform ARM kernel:

RTC, timer, and TWD are configured via device tree.

SPARSE_IRQ is enabled.

Tegra's debug_ll options are simplified, and the macros brought into
line with other multi-platform implementations, and moved to the new
common location.

Two headers still need to be eliminated in order to include Tegra in a
multi-platform kernel/ <mach/{clk,powergate}.h>. A new common API needs
to be invented to replace parts of clk.h. powergate.h might be replaced
by regulators; this needs more investigation.

This pull request is based on tegra-for-3.8-dt, followed by a merge of
arm-soc's devel/debug_ll_init branch.

* tag 'tegra-for-3.8-single-zimage' of git://git.kernel.org/pub/scm/linux/kernel/git/swarren/linux-tegra: (58 commits)
  ARM: tegra: move debug-macro.S to include/debug
  ARM: tegra: don't include iomap.h from debug-macro.S
  ARM: tegra: decouple uncompress.h and debug-macro.S
  ARM: tegra: simplify DEBUG_LL UART selection options
  ARM: tegra: select SPARSE_IRQ
  ARM: tegra: enhance timer.c to get IO address from device tree
  ARM: tegra: enhance timer.c to get IRQ info from device tree
  ARM: timer: fix checkpatch warnings
  ARM: tegra: add TWD to device tree
  ARM: tegra: define DT bindings for and instantiate RTC
  ARM: tegra: define DT bindings for and instantiate timer
  ARM: tegra: whistler: enable HDMI port
  ARM: tegra: tec: Enable HDMI output
  ARM: tegra: plutux: Enable HDMI output
  ARM: tegra: tamonten: Add host1x support
  ARM: tegra: trimslice: enable HDMI port
  ARM: tegra: harmony: enable HDMI port
  ARM: tegra: Add Tegra30 host1x support
  ARM: tegra: Add Tegra20 host1x support
  ARM: tegra: trimslice: enable SPI flash
  ...
  • Loading branch information
Olof Johansson committed Nov 21, 2012
2 parents 794c153 + 4606780 commit 46e8a79
Show file tree
Hide file tree
Showing 70 changed files with 1,878 additions and 966 deletions.
19 changes: 19 additions & 0 deletions Documentation/devicetree/bindings/rtc/nvidia,tegra20-rtc.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
NVIDIA Tegra20 real-time clock

The Tegra RTC maintains seconds and milliseconds counters, and five alarm
registers. The alarms and other interrupts may wake the system from low-power
state.

Required properties:

- compatible : should be "nvidia,tegra20-rtc".
- reg : Specifies base physical address and size of the registers.
- interrupts : A single interrupt specifier.

Example:

timer {
compatible = "nvidia,tegra20-rtc";
reg = <0x7000e000 0x100>;
interrupts = <0 2 0x04>;
};
21 changes: 21 additions & 0 deletions Documentation/devicetree/bindings/timer/nvidia,tegra20-timer.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
NVIDIA Tegra20 timer

The Tegra20 timer provides four 29-bit timer channels and a single 32-bit free
running counter. The first two channels may also trigger a watchdog reset.

Required properties:

- compatible : should be "nvidia,tegra20-timer".
- reg : Specifies base physical address and size of the registers.
- interrupts : A list of 4 interrupts; one per timer channel.

Example:

timer {
compatible = "nvidia,tegra20-timer";
reg = <0x60005000 0x60>;
interrupts = <0 0 0x04
0 1 0x04
0 41 0x04
0 42 0x04>;
};
23 changes: 23 additions & 0 deletions Documentation/devicetree/bindings/timer/nvidia,tegra30-timer.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
NVIDIA Tegra30 timer

The Tegra30 timer provides ten 29-bit timer channels, a single 32-bit free
running counter, and 5 watchdog modules. The first two channels may also
trigger a legacy watchdog reset.

Required properties:

- compatible : should be "nvidia,tegra30-timer", "nvidia,tegra20-timer".
- reg : Specifies base physical address and size of the registers.
- interrupts : A list of 6 interrupts; one per each of timer channels 1
through 5, and one for the shared interrupt for the remaining channels.

timer {
compatible = "nvidia,tegra30-timer", "nvidia,tegra20-timer";
reg = <0x60005000 0x400>;
interrupts = <0 0 0x04
0 1 0x04
0 41 0x04
0 42 0x04
0 121 0x04
0 122 0x04>;
};
1 change: 1 addition & 0 deletions Documentation/devicetree/bindings/vendor-prefixes.txt
Original file line number Diff line number Diff line change
Expand Up @@ -51,4 +51,5 @@ ti Texas Instruments
via VIA Technologies, Inc.
wlf Wolfson Microelectronics
wm Wondermedia Technologies, Inc.
winbond Winbond Electronics corp.
xlnx Xilinx
1 change: 1 addition & 0 deletions arch/arm/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -644,6 +644,7 @@ config ARCH_TEGRA
select HAVE_CLK
select HAVE_SMP
select MIGHT_HAVE_CACHE_L2X0
select SPARSE_IRQ
select USE_OF
help
This enables support for NVIDIA Tegra based systems (Tegra APX,
Expand Down
38 changes: 38 additions & 0 deletions arch/arm/Kconfig.debug
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,13 @@ choice
Say Y here if you want kernel low-level debugging support
on SOCFPGA based platforms.

config DEBUG_TEGRA_UART
depends on ARCH_TEGRA
bool "Use Tegra UART for low-level debug"
help
Say Y here if you want kernel low-level debugging support
on Tegra based platforms.

config DEBUG_VEXPRESS_UART0_DETECT
bool "Autodetect UART0 on Versatile Express Cortex-A core tiles"
depends on ARCH_VEXPRESS && CPU_CP15_MMU
Expand Down Expand Up @@ -409,6 +416,36 @@ choice

endchoice

choice
prompt "Low-level debug console UART"
depends on DEBUG_LL && DEBUG_TEGRA_UART

config TEGRA_DEBUG_UART_AUTO_ODMDATA
bool "Via ODMDATA"
help
Automatically determines which UART to use for low-level debug based
on the ODMDATA value. This value is part of the BCT, and is written
to the boot memory device using nvflash, or other flashing tool.
When bits 19:18 are 3, then bits 17:15 indicate which UART to use;
0/1/2/3/4 are UART A/B/C/D/E.

config TEGRA_DEBUG_UARTA
bool "UART A"

config TEGRA_DEBUG_UARTB
bool "UART B"

config TEGRA_DEBUG_UARTC
bool "UART C"

config TEGRA_DEBUG_UARTD
bool "UART D"

config TEGRA_DEBUG_UARTE
bool "UART E"

endchoice

config DEBUG_LL_INCLUDE
string
default "debug/icedcc.S" if DEBUG_ICEDCC
Expand All @@ -418,6 +455,7 @@ config DEBUG_LL_INCLUDE
default "debug/socfpga.S" if DEBUG_SOCFPGA_UART
default "debug/vexpress.S" if DEBUG_VEXPRESS_UART0_DETECT || \
DEBUG_VEXPRESS_UART0_CA9 || DEBUG_VEXPRESS_UART0_RS1
default "debug/tegra.S" if DEBUG_TEGRA_UART
default "mach/debug-macro.S"

config EARLY_PRINTK
Expand Down
84 changes: 34 additions & 50 deletions arch/arm/boot/dts/tegra20-harmony.dts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,18 @@
reg = <0x00000000 0x40000000>;
};

host1x {
hdmi {
status = "okay";

vdd-supply = <&hdmi_vdd_reg>;
pll-supply = <&hdmi_pll_reg>;

nvidia,ddc-i2c-bus = <&hdmi_ddc>;
nvidia,hpd-gpio = <&gpio 111 0>; /* PN7 */
};
};

pinmux {
pinctrl-names = "default";
pinctrl-0 = <&state_default>;
Expand Down Expand Up @@ -262,9 +274,9 @@
};
};

i2c@7000c400 {
hdmi_ddc: i2c@7000c400 {
status = "okay";
clock-frequency = <400000>;
clock-frequency = <100000>;
};

i2c@7000c500 {
Expand Down Expand Up @@ -297,138 +309,110 @@
vinldo9-supply = <&sm2_reg>;

regulators {
#address-cells = <1>;
#size-cells = <0>;

sys_reg: regulator@0 {
reg = <0>;
regulator-compatible = "sys";
sys_reg: sys {
regulator-name = "vdd_sys";
regulator-always-on;
};

regulator@1 {
reg = <1>;
regulator-compatible = "sm0";
sm0 {
regulator-name = "vdd_sm0,vdd_core";
regulator-min-microvolt = <1200000>;
regulator-max-microvolt = <1200000>;
regulator-always-on;
};

regulator@2 {
reg = <2>;
regulator-compatible = "sm1";
sm1 {
regulator-name = "vdd_sm1,vdd_cpu";
regulator-min-microvolt = <1000000>;
regulator-max-microvolt = <1000000>;
regulator-always-on;
};

sm2_reg: regulator@3 {
reg = <3>;
regulator-compatible = "sm2";
sm2_reg: sm2 {
regulator-name = "vdd_sm2,vin_ldo*";
regulator-min-microvolt = <3700000>;
regulator-max-microvolt = <3700000>;
regulator-always-on;
};

regulator@4 {
reg = <4>;
regulator-compatible = "ldo0";
ldo0 {
regulator-name = "vdd_ldo0,vddio_pex_clk";
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
};

regulator@5 {
reg = <5>;
regulator-compatible = "ldo1";
ldo1 {
regulator-name = "vdd_ldo1,avdd_pll*";
regulator-min-microvolt = <1100000>;
regulator-max-microvolt = <1100000>;
regulator-always-on;
};

regulator@6 {
reg = <6>;
regulator-compatible = "ldo2";
ldo2 {
regulator-name = "vdd_ldo2,vdd_rtc";
regulator-min-microvolt = <1200000>;
regulator-max-microvolt = <1200000>;
};

regulator@7 {
reg = <7>;
regulator-compatible = "ldo3";
ldo3 {
regulator-name = "vdd_ldo3,avdd_usb*";
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
regulator-always-on;
};

regulator@8 {
reg = <8>;
regulator-compatible = "ldo4";
ldo4 {
regulator-name = "vdd_ldo4,avdd_osc,vddio_sys";
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
regulator-always-on;
};

regulator@9 {
reg = <9>;
regulator-compatible = "ldo5";
ldo5 {
regulator-name = "vdd_ldo5,vcore_mmc";
regulator-min-microvolt = <2850000>;
regulator-max-microvolt = <2850000>;
regulator-always-on;
};

regulator@10 {
reg = <10>;
regulator-compatible = "ldo6";
ldo6 {
regulator-name = "vdd_ldo6,avdd_vdac";
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
};

regulator@11 {
reg = <11>;
regulator-compatible = "ldo7";
hdmi_vdd_reg: ldo7 {
regulator-name = "vdd_ldo7,avdd_hdmi";
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
};

regulator@12 {
reg = <12>;
regulator-compatible = "ldo8";
hdmi_pll_reg: ldo8 {
regulator-name = "vdd_ldo8,avdd_hdmi_pll";
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
};

regulator@13 {
reg = <13>;
regulator-compatible = "ldo9";
ldo9 {
regulator-name = "vdd_ldo9,avdd_2v85,vdd_ddr_rx";
regulator-min-microvolt = <2850000>;
regulator-max-microvolt = <2850000>;
regulator-always-on;
};

regulator@14 {
reg = <14>;
regulator-compatible = "ldo_rtc";
ldo_rtc {
regulator-name = "vdd_rtc_out,vdd_cell";
regulator-min-microvolt = <3300000>;
regulator-max-microvolt = <3300000>;
regulator-always-on;
};
};
};

temperature-sensor@4c {
compatible = "adi,adt7461";
reg = <0x4c>;
};
};

pmc {
Expand Down
Loading

0 comments on commit 46e8a79

Please sign in to comment.