1. 14 4月, 2017 1 次提交
    • N
      net: stmmac: set total length of the packet to be transmitted in TDES3 · fe6af0e1
      Niklas Cassel 提交于
      Field FL/TPL in register TDES3 is not correctly set on GMAC4.
      TX appears to be functional on GMAC 4.10a even if this field is not set,
      however, to avoid relying on undefined behavior, set the length in TDES3.
      
      The field has a different meaning depending on if the TSE bit in TDES3
      is set or not (TSO). However, regardless of the TSE bit, the field is
      not optional. The field is already set correctly when the TSE bit is set.
      
      Since there is no limit for the number of descriptors that can be
      used for a single packet, the field should be set to the sum of
      the buffers contained in:
      [<desc with First Descriptor bit set> ... <desc n> ...
      <desc with Last Descriptor bit set>], which should be equal to skb->len.
      Signed-off-by: NNiklas Cassel <niklas.cassel@axis.com>
      Acked-by: NGiuseppe Cavallaro <peppe.cavallaro@st.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      fe6af0e1
  2. 25 3月, 2017 1 次提交
  3. 22 3月, 2017 2 次提交
  4. 16 3月, 2017 7 次提交
  5. 13 3月, 2017 9 次提交
  6. 25 2月, 2017 1 次提交
  7. 09 2月, 2017 3 次提交
  8. 10 1月, 2017 1 次提交
  9. 30 12月, 2016 1 次提交
  10. 09 12月, 2016 1 次提交
  11. 04 12月, 2016 1 次提交
  12. 30 11月, 2016 1 次提交
  13. 16 11月, 2016 2 次提交
  14. 13 9月, 2016 1 次提交
  15. 28 6月, 2016 3 次提交
  16. 03 4月, 2016 5 次提交
    • A
      stmmac: support new GMAC4 · f748be53
      Alexandre TORGUE 提交于
      This patch adds the whole GMAC4 support inside the
      stmmac d.d. now able to use the new HW and some new features
      i.e.: TSO.
      It is missing the multi-queue and split Header support at this
      stage.
      This patch also updates the driver version and the stmmac.txt.
      Signed-off-by: NAlexandre TORGUE <alexandre.torgue@st.com>
      Signed-off-by: NGiuseppe Cavallaro <peppe.cavallaro@st.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      f748be53
    • A
      stmmac: add GMAC4 core support · 477286b5
      Alexandre TORGUE 提交于
      This is the initial support for GMAC4 that includes
      the main callbacks to setup the core module: including
      Csum, basic filtering, mac address and interrupt (MMC,
      MTL, PMT) No LPI added.
      Signed-off-by: NAlexandre TORGUE <alexandre.torgue@st.com>
      Signed-off-by: NGiuseppe Cavallaro <peppe.cavallaro@st.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      477286b5
    • A
      stmmac: add DMA support for GMAC 4.xx · 48863ce5
      Alexandre TORGUE 提交于
      DMA behavior is linked to descriptor management:
      
      -descriptor mechanism (Tx for example, but it is exactly the same for RX):
      -useful registers:
      -DMA_CH#_TxDesc_Ring_Len: length of transmit descriptor ring
      -DMA_CH#_TxDesc_List_Address: start address of the ring
      	-DMA_CH#_TxDesc_Tail_Pointer: address of the last
      					      descriptor to send + 1.
      	-DMA_CH#_TxDesc_Current_App_TxDesc: address of the current
      						    descriptor
      
      -The descriptor Tail Pointer register contains the pointer to the
       descriptor address (N). The base address and the current
       descriptor decide the address of the current descriptor that the
       DMA can process. The descriptors up to one location less than the
       one indicated by the descriptor tail pointer (N-1) are owned by
       the DMA. The DMA continues to process the descriptors until the
       following condition occurs:
       "current descriptor pointer == Descriptor Tail pointer"
      
      Then the DMA goes into suspend mode. The application must perform
      a write to descriptor tail pointer register and update the tail
      pointer to have the following condition and to start a new transfer:
      "current descriptor pointer < Descriptor tail pointer"
      
      The DMA automatically wraps around the base address when the end
      of ring is reached.
      
      Up to 8 DMA could be use but currently we only use one (channel0)
      Signed-off-by: NAlexandre TORGUE <alexandre.torgue@st.com>
      Signed-off-by: NGiuseppe Cavallaro <peppe.cavallaro@st.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      48863ce5
    • A
      stmmac: add descriptors function for GMAC 4.xx · 753a7109
      Alexandre TORGUE 提交于
      One of main changes of GMAC 4.xx IP is descriptors management.
      -descriptors are only used in ring mode.
      -A descriptor is composed of 4 32bits registers (no more extended
       descriptors)
      -descriptor mechanism (Tx for example, but it is exactly the same for RX):
      -useful registers:
      	-DMA_CH#_TxDesc_Ring_Len: length of transmit descriptor
      				   ring
      	-DMA_CH#_TxDesc_List_Address: start address of the ring
      	-DMA_CH#_TxDesc_Tail_Pointer: address of the last
      				      descriptor to send + 1.
      	-DMA_CH#_TxDesc_Current_App_TxDesc: address of the current
      					    descriptor
      
      -The descriptor Tail Pointer register contains the pointer to the
       descriptor address (N). The base address and the current
       descriptor decide the address of the current descriptor that the
       DMA can process. The descriptors up to one location less than the
       one indicated by the descriptor tail pointer (N-1) are owned by
       the DMA. The DMA continues to process the descriptors until the
       following condition occurs:
       "current descriptor pointer == Descriptor Tail pointer"
      
        Then the DMA goes into suspend mode. The application must perform
        a write to descriptor tail pointer register and update the tail
        pointer to have the following condition and to start a new
            transfer:
        "current descriptor pointer < Descriptor tail pointer"
      
        The DMA automatically wraps around the base address when the end
        of ring is reached.
      
      -New features are available on IP:
      -TSO (TCP Segmentation Offload) for TX only
      -Split header: to have header and payload in 2 different buffers
      Signed-off-by: NAlexandre TORGUE <alexandre.torgue@st.com>
      Signed-off-by: NGiuseppe Cavallaro <peppe.cavallaro@st.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      753a7109
    • A
      stmmac: rework synopsys id read, moved to dwmac setup · c623d149
      Alexandre TORGUE 提交于
      synopsys_uid is only used once after setup, to get synopsys_id
      by using shitf/mask operation. It's no longer used then.
      So, remove this temporary variable and directly compute
      synopsys_id from setup routine.
      Acked-by: NGiuseppe Cavallaro <peppe.cavallaro@st.com>
      Signed-off-by: NFabrice Gasnier <fabrice.gasnier@st.com>
      Signed-off-by: NAlexandre TORGUE <alexandre.torgue@st.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      c623d149