Skip to contentSkip to conversation

ARM: tegra: pcie: Add tegra3 support

PATCH In review Jay Agarwal 3 participants 4 messages Jun 5, 2013 – Jun 11, 2013

Subsystems (5)
lore
Share & tools
lore
#0 lore raw

PATCH v4 2/4 ARM: tegra: pcie: Add tegra3 support

- Make private data structure for each SoC
- Add required Tegra30 clocks and regulators
- Add Tegra30 specific code in enable controller
- Added Tegra30 specific properties in pci binding document

---
Patch is based on remotes/gitorious_thierryreding_linux/tegra/next and should be applied on top of this.

Changes in V4:
As per review comment
- Corrected pci document
- Removed fix in read/write config space
- modified num_max_ports -> num_ports
- Avoided changes in tegra_pcie_remove

---
 .../bindings/pci/nvidia,tegra20-pcie.txt           |    4 +-
 drivers/pci/host/pci-tegra.c                       |  147 +++++++++++++++++---
 2 files changed, 130 insertions(+), 21 deletions(-)
Documentation/devicetree/bindings/pci/nvidia,tegra20-pcie.txt +3 -1
index 90c112f..db673c0 100644
@@ -1,7 +1,7 @@
 NVIDIA Tegra PCIe controller
 
 Required properties:
-- compatible: "nvidia,tegra20-pcie"
+- compatible: "nvidia,tegra20-pcie" "nvidia,tegra30-pcie"
 - device_type: Must be "pci"
 - reg: A list of physical base address and length for each set of controller
   registers. Must contain an entry for each entry in the reg-names property.
@@ -16,6 +16,7 @@ Required properties:
   "msi": The Tegra interrupt that is asserted when an MSI is received
 - pex-clk-supply: Supply voltage for internal reference clock
 - vdd-supply: Power supply for controller (1.05V)
+- avdd-supply: Power supply for controller (1.05V) (not required for tegra20)
 - bus-range: Range of bus numbers associated with this controller
 - #address-cells: Address representation for root ports (must be 3)
   - cell 0 specifies the bus and device numbers of the root port:
@@ -48,6 +49,7 @@ Required properties:
   "afi": The Tegra clock of that name
   "pcie_xclk": The Tegra clock of that name
   "pll_e": The Tegra clock of that name
+  "cml": The Tegra clock of that name (not required for tegra20)
 
 Root ports are defined as subnodes of the PCIe controller node.
 
drivers/pci/host/pci-tegra.c +127 -20

356 lines not on this page · raw message

Signature · 1 line
1.7.0.4
#1 lore raw
Quoted 4 lines · Jay Agarwal

- Make private data structure for each SoC
- Add required Tegra30 clocks and regulators
- Add Tegra30 specific code in enable controller
- Added Tegra30 specific properties in pci binding document

It's a bit odd to send an updated version of just some of the patches; reposting a whole series is much easier for the person applying the patches. However, hopefully Thierry can handle it in this case.

Documentation/devicetree/bindings/pci/nvidia,tegra20-pcie.txt line 4

Quoted 5 lines
Documentation/devicetree/bindings/pci/nvidia,tegra20-pcie.txt +1 -1
 
 Required properties:
-- compatible: "nvidia,tegra20-pcie"
+- compatible: "nvidia,tegra20-pcie" "nvidia,tegra30-pcie"

perhaps add "or" between those two entries?

Quoted 1 line

+- avdd-supply: Power supply for controller (1.05V) (not required for tegra20)

...

Quoted 1 line

+ "cml": The Tegra clock of that name (not required for tegra20)

Tegra20 should be capitalized in both those two lines.

I assume that Thierry can fix up these nits when he applies the patches, so you don't need to repost. Thierry can correct me if I'm wrong.

#2 lore raw
Quoted 9 lines · Stephen Warren
Quoted 4 lines · Jay Agarwal

- Make private data structure for each SoC
- Add required Tegra30 clocks and regulators
- Add Tegra30 specific code in enable controller
- Added Tegra30 specific properties in pci binding document

It's a bit odd to send an updated version of just some of the patches; reposting a whole series is much easier for the person applying the patches. However, hopefully Thierry can handle it in this case.

Yes, I think I can handle it. It might be good to have Jay look at the final patches when I'm done, though, to make sure I haven't forgotten anything.

Quoted 8 lines

Documentation/devicetree/bindings/pci/nvidia,tegra20-pcie.txt line 4

Quoted 5 lines
Documentation/devicetree/bindings/pci/nvidia,tegra20-pcie.txt +1 -1
 
 Required properties:
-- compatible: "nvidia,tegra20-pcie"
+- compatible: "nvidia,tegra20-pcie" "nvidia,tegra30-pcie"

perhaps add "or" between those two entries?

Quoted 8 lines
Quoted 1 line

+- avdd-supply: Power supply for controller (1.05V) (not required for tegra20)

...

Quoted 1 line

+ "cml": The Tegra clock of that name (not required for tegra20)

Tegra20 should be capitalized in both those two lines.

I assume that Thierry can fix up these nits when he applies the patches, so you don't need to repost. Thierry can correct me if I'm wrong.

I've found a few other nits that I can take care of myself when applying.

Thierry
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20130610/3a5f629d/attachment.sig>

#3 lore raw
Quoted 10 lines

* PGP Signed by an unknown key

Quoted 6 lines · Stephen Warren
Quoted 4 lines · Jay Agarwal

- Make private data structure for each SoC
- Add required Tegra30 clocks and regulators
- Add Tegra30 specific code in enable controller
- Added Tegra30 specific properties in pci binding document

Quoted 7 lines
Quoted 3 lines

It's a bit odd to send an updated version of just some of the patches; reposting a whole series is much easier for the person applying the patches. However, hopefully Thierry can handle it in this case.

Yes, I think I can handle it. It might be good to have Jay look at the final patches when I'm done, though, to make sure I haven't forgotten anything.

Yes, please let me know whenever you have integrated my patches to your repo, so that I can sync, review & verify again.