mbox series

[v3,0/7] driver: net: ti: clean up and code optimization

Message ID 20181031212145.32761-1-grygorii.strashko@ti.com
Headers show
Series driver: net: ti: clean up and code optimization | expand

Message

Grygorii Strashko Oct. 31, 2018, 9:21 p.m. UTC
This series contains set of code clean up and optimizations for TI networking drivers.
Patch 1 - Adds drivers/net/ti/ folder and moves all TI's networking code
 in this folder.
Patches 2,3 - keystone2 clean up
Patch 5 - introduces common TI MDIO support library as existing TI SoCs network
 HW IPs have similar MDIO implementation.
Patches 6-7 - conversation of TI CPSW and keystone_net drivers to use common
 TI MDIO support library

tested dhcp and kernel boot on:
- k2e/g/hk/l evms 
- am437x-gpevm and AM5748 IDK

changes in v3:
 - patch 5 comments applied
changes in v2:
 - patch 5 comments fixed: use wait_for_bit, snprintf, mdelay, mdio_free 

v2: https://patchwork.ozlabs.org/cover/991649/
v1: https://patchwork.ozlabs.org/cover/989449/

TODO: TODO: As per code and documentation davinci_emac.c seems also can be
re-worked to use common TI MDIO support library and network PHYs framework.
Unfortunately, I have no HW to work with.

Grygorii Strashko (7):
  driver: net: consolidate ti's code in separate folder
  configs: net: convert DRIVER_TI_KEYSTONE_NET kconfig
  drivers: net: keystone_net: drop non dm code
  driver: net: ti: cpsw: update to use SPDX identifier
  driver: net: ti: introduce common mdio support library
  driver: net: ti: cpsw: switch to use common mdio lib
  driver: net: ti: keystone_net: switch to use common mdio lib

 arch/arm/include/asm/ti-common/keystone_net.h |  27 --
 arch/arm/mach-davinci/dp83848.c               |   2 +-
 arch/arm/mach-davinci/et1011c.c               |   2 +-
 arch/arm/mach-davinci/ksz8873.c               |   2 +-
 arch/arm/mach-davinci/lxt972.c                |   2 +-
 board/ti/ks2_evm/board.c                      |  53 ----
 board/ti/ks2_evm/board.h                      |   3 -
 board/ti/ks2_evm/board_k2e.c                  |  74 -----
 board/ti/ks2_evm/board_k2g.c                  |  18 --
 board/ti/ks2_evm/board_k2hk.c                 |  42 ---
 board/ti/ks2_evm/board_k2l.c                  |  42 ---
 configs/k2e_evm_defconfig                     |   1 +
 configs/k2e_hs_evm_defconfig                  |   1 +
 configs/k2g_evm_defconfig                     |   1 +
 configs/k2g_hs_evm_defconfig                  |   1 +
 configs/k2hk_evm_defconfig                    |   1 +
 configs/k2hk_hs_evm_defconfig                 |   1 +
 configs/k2l_evm_defconfig                     |   1 +
 configs/k2l_hs_evm_defconfig                  |   1 +
 drivers/net/Kconfig                           |  13 +-
 drivers/net/Makefile                          |   4 +-
 drivers/net/ti/Kconfig                        |  20 ++
 drivers/net/ti/Makefile                       |   7 +
 drivers/net/{ => ti}/cpsw-common.c            |   0
 drivers/net/{ => ti}/cpsw.c                   | 146 +---------
 drivers/net/ti/cpsw_mdio.c                    | 203 +++++++++++++
 drivers/net/ti/cpsw_mdio.h                    |  18 ++
 drivers/net/{ => ti}/davinci_emac.c           |   0
 drivers/net/{ => ti}/davinci_emac.h           |   0
 drivers/net/{ => ti}/keystone_net.c           | 401 +-------------------------
 include/configs/ti_armv7_keystone2.h          |   1 -
 31 files changed, 286 insertions(+), 802 deletions(-)
 create mode 100644 drivers/net/ti/Kconfig
 create mode 100644 drivers/net/ti/Makefile
 rename drivers/net/{ => ti}/cpsw-common.c (100%)
 rename drivers/net/{ => ti}/cpsw.c (90%)
 create mode 100644 drivers/net/ti/cpsw_mdio.c
 create mode 100644 drivers/net/ti/cpsw_mdio.h
 rename drivers/net/{ => ti}/davinci_emac.c (100%)
 rename drivers/net/{ => ti}/davinci_emac.h (100%)
 rename drivers/net/{ => ti}/keystone_net.c (68%)