Skip to content

Commit

Permalink
net: xilinx: Move Xilinx TSN to staging
Browse files Browse the repository at this point in the history
The newly added and existing TSN functionality is dependent on conditional
kernel config options. The AXI Ethernet and TSN functionality cannot both
be supported with the same defconfig in the current state. Hence move
TSN to staging area and split the two drivers as temporary solution until
an acceptable upstream solution is possible.

-> Move TSN specific files to staging area and make a copy of the common
files (header, mcdma and main files).
-> Remove all TSN specific code present under both dynamic and static
checks in the Axi Ethernet driver. Remove tsn compatible string.
-> The default config cannot include CONFIG_AXIENET_HAS_MCDMA because
it affects the baseline AXI Ethernet driver. Hence modify TSN
staging driver to default to MCDMA specific code as required.
-> Remove CONFIG_XILINX_AXI_EMAC_HWTSTAMP specific code in staging
as it is not used in TSN driver.
-> Remove unused non-static functions and related exported symbols in
tsn staging driver.
-> In staging, rename all non-static functions and macros with a _tsn
suffix when affected by either the above changes or by CONFIG_XILINX_TSN
being enabled in defconfig. This ensures that driver/net/ethernet/xilinx
and drivers/staging/xilinx-tsn drivers do not have any conflicts.
-> Added ethtool support
-> Fixed irq handling in mcdma_rx_probe_tsn

Signed-off-by: Pranavi Somisetty <pranavi.somisetty@xilinx.com>
Signed-off-by: Harini Katakam <harini.katakam@xilinx.com>
Reviewed-by: Radhey Shyam Pandey <radhey.shyam.pandey@xilinx.com>
  • Loading branch information
Pranavi Somisetty authored and Michal Simek committed Apr 6, 2022
1 parent 1bc2002 commit 01fee54
Show file tree
Hide file tree
Showing 35 changed files with 4,598 additions and 625 deletions.
60 changes: 0 additions & 60 deletions drivers/net/ethernet/xilinx/Kconfig
Expand Up @@ -44,15 +44,6 @@ config AXIENET_HAS_MCDMA
help
When hardware is generated with AXI Ethernet with MCDMA select this option.

config AXIENET_HAS_TADMA
bool "AxiEthernet is configured with TADMA"
depends on XILINX_TSN
help
When hardware is generated with Axi Ethernet with TADMA select this option.
This driver enables Time Aware DMA to support TSN Qbv clause accurately.
It is used to fetch schedule traffic.
It contains one queue.

config XILINX_LL_TEMAC
tristate "Xilinx LL TEMAC (LocalLink Tri-mode Ethernet MAC) driver"
depends on HAS_IOMEM
Expand All @@ -61,55 +52,4 @@ config XILINX_LL_TEMAC
This driver supports the Xilinx 10/100/1000 LocalLink TEMAC
core used in Xilinx Spartan and Virtex FPGAs

config XILINX_TSN
bool "Enable Xilinx's TSN IP"
select XILINX_AXI_EMAC
help
Enable Xilinx's TSN IP.

config XILINX_TSN_PTP
bool "Generate hardware packet timestamps using Xilinx's TSN IP"
depends on XILINX_TSN
select PTP_1588_CLOCK
default y
help
Generate hardware packet timestamps. This is to facilitate IEEE 1588.

config XILINX_TSN_QBV
bool "Support Qbv protocol in TSN"
depends on XILINX_TSN_PTP
select PTP_1588_CLOCK
default y
help
Enables TSN Qbv protocol.

config XILINX_TSN_SWITCH
bool "Support TSN switch"
depends on XILINX_TSN
select NET_SWITCHDEV
default y
help
Enable Xilinx's TSN Switch support.

config XILINX_TSN_QCI
bool "Support Qci protocol in TSN"
depends on XILINX_TSN_SWITCH
default y
help
Enable TSN QCI protocol.

config XILINX_TSN_CB
bool "Support CB protocol in TSN"
depends on XILINX_TSN_SWITCH
default y
help
Enable TSN CB protocol support.

config XILINX_TSN_QBR
bool "Support QBR protocol in TSN"
depends on XILINX_TSN_SWITCH
default y
help
Enable TSN QBR protocol support.

endif # NET_VENDOR_XILINX
8 changes: 0 additions & 8 deletions drivers/net/ethernet/xilinx/Makefile
Expand Up @@ -6,14 +6,6 @@
ll_temac-objs := ll_temac_main.o ll_temac_mdio.o
obj-$(CONFIG_XILINX_LL_TEMAC) += ll_temac.o
obj-$(CONFIG_XILINX_EMACLITE) += xilinx_emaclite.o
obj-$(CONFIG_XILINX_TSN) += xilinx_tsn_ep.o xilinx_tsn_ep_ex.o xilinx_tsn_ip.o
obj-$(CONFIG_XILINX_TSN_PTP) += xilinx_tsn_ptp_xmit.o xilinx_tsn_ptp_clock.o
obj-$(CONFIG_XILINX_TSN_QBV) += xilinx_tsn_shaper.o
obj-$(CONFIG_XILINX_TSN_QCI) += xilinx_tsn_qci.o
obj-$(CONFIG_XILINX_TSN_CB) += xilinx_tsn_cb.o
obj-$(CONFIG_XILINX_TSN_SWITCH) += xilinx_tsn_switch.o xilinx_tsn_switchdev.o
xilinx_emac-objs := xilinx_axienet_main.o xilinx_axienet_mdio.o xilinx_axienet_dma.o
obj-$(CONFIG_XILINX_AXI_EMAC) += xilinx_emac.o
obj-$(CONFIG_XILINX_TSN_QBR) += xilinx_tsn_preemption.o
obj-$(CONFIG_AXIENET_HAS_MCDMA) += xilinx_axienet_mcdma.o
obj-$(CONFIG_AXIENET_HAS_TADMA) += xilinx_tsn_tadma.o

0 comments on commit 01fee54

Please sign in to comment.