1. 15 2月, 2013 16 次提交
  2. 14 2月, 2013 5 次提交
  3. 13 2月, 2013 8 次提交
    • P
      gianfar: convert u64 status counters to atomic64_t · 212079df
      Paul Gortmaker 提交于
      While looking at some asm dump for an unrelated change, Eric
      noticed in the following stats count increment code:
      
          50b8:       81 3c 01 f8     lwz     r9,504(r28)
          50bc:       81 5c 01 fc     lwz     r10,508(r28)
          50c0:       31 4a 00 01     addic   r10,r10,1
          50c4:       7d 29 01 94     addze   r9,r9
          50c8:       91 3c 01 f8     stw     r9,504(r28)
          50cc:       91 5c 01 fc     stw     r10,508(r28)
      
      that a 64 bit counter was used on ppc-32 without sync
      and hence the "ethtool -S" output was racy.
      
      Here we convert all the values to use atomic64_t so that
      the output will always be consistent.
      Reported-by: NEric Dumazet <edumazet@google.com>
      Signed-off-by: NPaul Gortmaker <paul.gortmaker@windriver.com>
      212079df
    • P
      gianfar: remove largely unused gfar_stats struct · 68719786
      Paul Gortmaker 提交于
      The gfar_stats struct is only used in copying out data
      via ethtool.  It is declared as the extra stats, followed
      by the rmon stats.  However, the rmon stats are never
      actually ever used in the driver; instead the rmon data
      is a u32 register read that is cast directly into the
      ethtool buf.
      
      It seems the only reason rmon is in the struct at all is
      to give the offset(s) at which it should be exported into
      the ethtool buffer.  But note gfar_stats doesn't contain
      a gfar_extra_stats as a substruct -- instead it contains
      a u64 array of equal element count.  This implicitly means
      we have two independent declarations of what gfar_extra_stats
      really is.  Rather than have this duality, we already have
      defines which give us the offset directly, and hence do not
      need the struct at all.
      
      Further, since we know the extra_stats is unconditionally
      always present, we can write it out to the ethtool buf
      1st, and then optionally write out the rmon data.  There
      is no need for two independent loops, both of which are
      simply copying out the extra_stats to buf offset zero.
      
      This also helps pave the way towards allowing the extra
      stats fields to be converted to atomic64_t values, without
      having their types directly influencing the ethtool stats
      export code (gfar_fill_stats) that expects to deal with u64.
      Signed-off-by: NPaul Gortmaker <paul.gortmaker@windriver.com>
      68719786
    • S
      net: fec_mpc52xx: Read MAC address from device-tree · db98f081
      Stefan Roese 提交于
      Until now, the MPC5200 FEC ethernet driver relied upon the bootloader
      (U-Boot) to write the MAC address into the ethernet controller
      registers. The Linux driver should not rely on such a thing. So
      lets read the MAC address from the DT as it should be done here.
      
      The following priority is now used to read the MAC address:
      
      1) First, try OF node MAC address, if not present or invalid, then:
      
      2) Read from MAC address registers, if invalid, then:
      
      3) Log a warning message, and choose a random MAC address.
      
      This fixes a problem with a MPC5200 board that uses the SPL U-Boot
      version without FEC initialization before Linux booting for
      boot speedup.
      
      Additionally a status line is now be printed upon successful
      driver probing, also displaying this MAC address.
      Signed-off-by: NStefan Roese <sr@denx.de>
      Cc: Anatolij Gustschin <agust@denx.de>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      db98f081
    • V
      af32de0e
    • M
      driver: net: ethernet: cpsw: dual emac interface implementation · d9ba8f9e
      Mugunthan V N 提交于
      The CPSW switch can act as Dual EMAC by segregating the switch ports
      using VLAN and port VLAN as per the TRM description in
      14.3.2.10.2 Dual Mac Mode
      
      Following CPSW components will be common for both the interfaces.
      * Interrupt source is common for both eth interfaces
      * Interrupt pacing is common for both interfaces
      * Hardware statistics is common for all the ports
      * CPDMA is common for both eth interface
      * CPTS is common for both the interface and it should not be enabled on
        both the interface as timestamping information doesn't contain port
        information.
      
      Constrains
      * Reserved VID of One port should not be used in other interface which will
        enable switching functionality
      * Same VID must not be used in both the interface which will enable switching
        functionality
      Signed-off-by: NMugunthan V N <mugunthanvnm@ti.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      d9ba8f9e
    • M
      driver: net: ethernet: cpsw: make cpts as pointer · 9232b16d
      Mugunthan V N 提交于
      As CPTS is common module for both EMAC in Dual EMAC mode so making cpts as
      pointer.
      Signed-off-by: NMugunthan V N <mugunthanvnm@ti.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      9232b16d
    • M
      driver: net: ethernet: davinci_cpdma: add support for directed packet and source port detection · f6e135c8
      Mugunthan V N 提交于
      * Introduced parameter to add port number for directed packet in cpdma_chan_submit
      * Source port detection macro with DMA descriptor status
      Signed-off-by: NMugunthan V N <mugunthanvnm@ti.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      f6e135c8
    • A
      ixgbe: Only set gso_type to SKB_GSO_TCPV4 as RSC does not support IPv6 · 96be80ab
      Alexander Duyck 提交于
      The original fix that was applied for setting gso_type required more change
      than necessary because it was assumed ixgbe does RSC on IPv6 frames and this
      is not correct.  RSC is only supported with IPv4/TCP frames only.  As such we
      can simplify the fix and avoid the unnecessary move of eth_type_trans.
      
      The previous patch "ixgbe: fix gso type" and this patch reduce the entire fix
      to one line that sets gso_type to TCPV4 if the frame is RSC.
      Signed-off-by: NAlexander Duyck <alexander.h.duyck@intel.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      96be80ab
  4. 11 2月, 2013 11 次提交