Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1d7229dd authored by David S. Miller's avatar David S. Miller
Browse files

Merge branch 'DPAA-PTP-clock-and-timestamping'



Yangbo Lu says:

====================
Support DPAA PTP clock and timestamping

This patchset is to support DPAA FMAN PTP clock and HW timestamping.
It had been verified on both ARM platform and PPC platform.
- The patch #1 to patch #5 are to support DPAA FMAN 1588 timer in
  ptp_qoriq driver.
- The patch #6 to patch #10 are to add HW timestamping support in
  DPAA ethernet driver.
====================

Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parents 651b4513 17ae0b0e
Loading
Loading
Loading
Loading
+1 −24
Original line number Diff line number Diff line
@@ -356,30 +356,7 @@ ethernet@e0000 {
============================================================================
FMan IEEE 1588 Node

DESCRIPTION

The FMan interface to support IEEE 1588


PROPERTIES

- compatible
		Usage: required
		Value type: <stringlist>
		Definition: A standard property.
		Must include "fsl,fman-ptp-timer".

- reg
		Usage: required
		Value type: <prop-encoded-array>
		Definition: A standard property.

EXAMPLE

ptp-timer@fe000 {
	compatible = "fsl,fman-ptp-timer";
	reg = <0xfe000 0x1000>;
};
Refer to Documentation/devicetree/bindings/ptp/ptp-qoriq.txt

=============================================================================
FMan MDIO Node
+12 −3
Original line number Diff line number Diff line
@@ -2,7 +2,8 @@

General Properties:

  - compatible   Should be "fsl,etsec-ptp"
  - compatible   Should be "fsl,etsec-ptp" for eTSEC
                 Should be "fsl,fman-ptp-timer" for DPAA FMan
  - reg          Offset and length of the register set for the device
  - interrupts   There should be at least two interrupts. Some devices
                 have as many as four PTP related interrupts.
@@ -43,14 +44,22 @@ Clock Properties:
  value, which will be directly written in those bits, that is why,
  according to reference manual, the next clock sources can be used:

  For eTSEC,
  <0> - external high precision timer reference clock (TSEC_TMR_CLK
        input is used for this purpose);
  <1> - eTSEC system clock;
  <2> - eTSEC1 transmit clock;
  <3> - RTC clock input.

  When this attribute is not used, eTSEC system clock will serve as
  IEEE 1588 timer reference clock.
  For DPAA FMan,
  <0> - external high precision timer reference clock (TMR_1588_CLK)
  <1> - MAC system clock (1/2 FMan clock)
  <2> - reserved
  <3> - RTC clock oscillator

  When this attribute is not used, the IEEE 1588 timer reference clock
  will use the eTSEC system clock (for Gianfar) or the MAC system
  clock (for DPAA).

Example:

+8 −6
Original line number Diff line number Diff line
@@ -11,13 +11,14 @@ fman0: fman@1a00000 {
	#size-cells = <1>;
	cell-index = <0>;
	compatible = "fsl,fman";
	ranges = <0x0 0x0 0x1a00000 0x100000>;
	reg = <0x0 0x1a00000 0x0 0x100000>;
	ranges = <0x0 0x0 0x1a00000 0xfe000>;
	reg = <0x0 0x1a00000 0x0 0xfe000>;
	interrupts = <GIC_SPI 44 IRQ_TYPE_LEVEL_HIGH>,
		     <GIC_SPI 45 IRQ_TYPE_LEVEL_HIGH>;
	clocks = <&clockgen 3 0>;
	clock-names = "fmanclk";
	fsl,qman-channel-range = <0x800 0x10>;
	ptimer-handle = <&ptp_timer0>;

	muram@0 {
		compatible = "fsl,fman-muram";
@@ -73,9 +74,10 @@ fman0: fman@1a00000 {
		compatible = "fsl,fman-memac-mdio", "fsl,fman-xmdio";
		reg = <0xfd000 0x1000>;
	};
};

	ptp_timer0: ptp-timer@fe000 {
ptp_timer0: ptp-timer@1afe000 {
	compatible = "fsl,fman-ptp-timer";
		reg = <0xfe000 0x1000>;
	};
	reg = <0x0 0x1afe000 0x0 0x1000>;
	interrupts = <GIC_SPI 44 IRQ_TYPE_LEVEL_HIGH>;
};
+8 −6
Original line number Diff line number Diff line
@@ -37,12 +37,13 @@ fman0: fman@400000 {
	#size-cells = <1>;
	cell-index = <0>;
	compatible = "fsl,fman";
	ranges = <0 0x400000 0x100000>;
	reg = <0x400000 0x100000>;
	ranges = <0 0x400000 0xfe000>;
	reg = <0x400000 0xfe000>;
	interrupts = <96 2 0 0>, <16 2 1 1>;
	clocks = <&clockgen 3 0>;
	clock-names = "fmanclk";
	fsl,qman-channel-range = <0x40 0xc>;
	ptimer-handle = <&ptp_timer0>;

	muram@0 {
		compatible = "fsl,fman-muram";
@@ -93,9 +94,10 @@ fman0: fman@400000 {
		reg = <0x87000 0x1000>;
		status = "disabled";
	};
};

	ptp_timer0: ptp-timer@fe000 {
ptp_timer0: ptp-timer@4fe000 {
	compatible = "fsl,fman-ptp-timer";
		reg = <0xfe000 0x1000>;
	};
	reg = <0x4fe000 0x1000>;
	interrupts = <96 2 0 0>;
};
+8 −6
Original line number Diff line number Diff line
@@ -37,12 +37,13 @@ fman1: fman@500000 {
	#size-cells = <1>;
	cell-index = <1>;
	compatible = "fsl,fman";
	ranges = <0 0x500000 0x100000>;
	reg = <0x500000 0x100000>;
	ranges = <0 0x500000 0xfe000>;
	reg = <0x500000 0xfe000>;
	interrupts = <97 2 0 0>, <16 2 1 0>;
	clocks = <&clockgen 3 1>;
	clock-names = "fmanclk";
	fsl,qman-channel-range = <0x60 0xc>;
	ptimer-handle = <&ptp_timer1>;

	muram@0 {
		compatible = "fsl,fman-muram";
@@ -93,9 +94,10 @@ fman1: fman@500000 {
		reg = <0x87000 0x1000>;
		status = "disabled";
	};
};

	ptp_timer1: ptp-timer@fe000 {
ptp_timer1: ptp-timer@5fe000 {
	compatible = "fsl,fman-ptp-timer";
		reg = <0xfe000 0x1000>;
	};
	reg = <0x5fe000 0x1000>;
	interrupts = <97 2 0 0>;
};
Loading