blob: 86c14de6dca1e8cb9dfb4e58a474459ab3e5c7ee [file] [log] [blame]
Pamidipati, Vijayc6ae5662013-06-10 11:03:55 +05301# ###################################################
2# # Makefile for the NSS driver
3# ###################################################
4
Abhishek Rastogibc74e432013-04-02 10:28:22 +05305obj-m += qca-nss-drv.o
Sol Kavy2783c072014-04-05 12:53:13 -07006
Sol Kavy879eb8b2014-04-07 19:11:31 -07007#
8# List the files that belong to the driver in alphabetical order.
9#
Sol Kavy2783c072014-04-05 12:53:13 -070010qca-nss-drv-objs := \
Stephen Wang90c67de2016-04-26 15:15:59 -070011 nss_capwap.o \
Sol Kavy2783c072014-04-05 12:53:13 -070012 nss_cmn.o \
13 nss_core.o \
Guojun Jin1cb79522015-06-22 22:34:22 -070014 nss_coredump.o \
Samarjeet Banerjeede86b802014-04-10 02:59:49 +053015 nss_crypto.o \
Tushar Mathurff8741b2015-12-02 20:28:59 +053016 nss_dtls.o \
Ankit Dhanuka9b430252014-08-12 13:53:41 +053017 nss_dynamic_interface.o \
Shashank Balashankar512cb602016-08-01 17:57:42 -070018 nss_edma.o \
Stephen Wang90c67de2016-04-26 15:15:59 -070019 nss_eth_rx.o \
Ankit Dhanuka607508d2014-08-21 20:20:34 +053020 nss_gre_redir.o \
Sol Kavya55c9a52014-04-08 14:33:16 -070021 nss_if.o \
Samarjeet Banerjeed99d9d02014-04-08 18:51:00 +053022 nss_init.o \
23 nss_ipsec.o \
Sol Kavy2783c072014-04-05 12:53:13 -070024 nss_ipv4.o \
Suruchi Agarwale3940e72016-07-06 15:56:51 -070025 nss_ipv4_log.o \
Selin Dag6d9b0c12014-11-04 18:27:21 -080026 nss_ipv4_reasm.o \
Sol Kavy879eb8b2014-04-07 19:11:31 -070027 nss_ipv6.o \
Suruchi Agarwale3940e72016-07-06 15:56:51 -070028 nss_ipv6_log.o \
Selin Dag60a2f5b2015-06-29 14:39:49 -070029 nss_ipv6_reasm.o \
ratheesh kannoth7af985d2015-06-24 15:08:40 +053030 nss_l2tpv2.o \
Stephen Wang90c67de2016-04-26 15:15:59 -070031 nss_lag.o \
32 nss_log.o \
33 nss_lso_rx.o \
ratheesh kannotha1245c32015-11-04 16:45:43 +053034 nss_map_t.o \
Stephen Wang38e89bc2014-11-06 11:34:45 -080035 nss_n2h.o \
Sivanesan Rajapupathi5c31b212016-01-06 16:21:57 -050036 nss_oam.o \
Stephen Wang90c67de2016-04-26 15:15:59 -070037 nss_phys_if.o \
38 nss_profiler.o \
39 nss_portid.o \
40 nss_pppoe.o \
41 nss_pptp.o \
42 nss_shaper.o \
43 nss_sjack.o \
44 nss_stats.o \
45 nss_tstamp.o \
46 nss_tun6rd.o \
47 nss_tunipip6.o \
48 nss_virt_if.o \
Bharath M Kumarcc666e92014-12-24 19:17:28 +053049 nss_wifi.o \
Stephen Wang90c67de2016-04-26 15:15:59 -070050 nss_wifi_if.o \
51 nss_wifi_vdev.o
Sol Kavy2783c072014-04-05 12:53:13 -070052
53#
54# TODO: Deprecated files should be removed before merge
55#
Stephen Wang90c67de2016-04-26 15:15:59 -070056qca-nss-drv-objs += nss_tx_rx_virt_if.o
57
Stephen Wang5901def2016-05-09 16:21:03 -070058# Base NSS data plane/HAL support
59qca-nss-drv-objs += nss_data_plane/nss_data_plane.o
Stephen Wang90c67de2016-04-26 15:15:59 -070060qca-nss-drv-objs += nss_hal/nss_hal.o
61
Stephen Wangbe348022016-05-02 17:11:34 -070062# All active qsdk branches (banana/coconut/trunk) supports ipq806x
Stephen Wang5901def2016-05-09 16:21:03 -070063qca-nss-drv-objs += nss_data_plane/nss_data_plane_gmac.o \
64 nss_hal/ipq806x/nss_hal_pvt.o
Stephen Wang90c67de2016-04-26 15:15:59 -070065ccflags-y += -I$(obj)/nss_hal/ipq806x -DNSS_HAL_IPQ806X_SUPPORT
Sol Kavy2783c072014-04-05 12:53:13 -070066
Stephen Wangbe348022016-05-02 17:11:34 -070067# Only 4.4 Kernel (qsdk trunk) supports ipq807x
68ifneq ($(findstring 4.4., $(KERNELVERSION)),)
Stephen Wangdf8323b2016-05-09 22:51:22 -070069qca-nss-drv-objs += nss_data_plane/nss_data_plane_edma.o \
70 nss_hal/ipq807x/nss_hal_pvt.o
Stephen Wangbe348022016-05-02 17:11:34 -070071ccflags-y += -I$(obj)/nss_hal/ipq807x -DNSS_HAL_IPQ807x_SUPPORT
72endif
73
Stephen Wang5901def2016-05-09 16:21:03 -070074ccflags-y += -I$(obj)/nss_hal/include -I$(obj)/nss_data_plane/include -I$(obj)/exports -DNSS_DEBUG_LEVEL=0 -DNSS_PKT_STATS_ENABLED=1
75
Anish Nataraj05d31f62016-08-17 17:07:14 +053076ccflags-y += -DNSS_PM_DEBUG_LEVEL=0 -DNSS_SKB_RECYCLE_SUPPORT=1
Pamidipati, Vijayc6ae5662013-06-10 11:03:55 +053077
Sundarajan Srinivasan4691ba62014-11-07 11:24:07 -080078ifneq ($(findstring 3.4, $(KERNELVERSION)),)
Ankit Dhanuka4ac3c9f2015-08-10 16:03:00 +053079NSS_CCFLAGS = -DNSS_DT_SUPPORT=0 -DNSS_FW_DBG_SUPPORT=1 -DNSS_PM_SUPPORT=1 -DNSS_EMPTY_BUFFER_SIZE=1984
Stephen Wang90c67de2016-04-26 15:15:59 -070080qca-nss-drv-objs += nss_pm.o
Sundarajan Srinivasan4691ba62014-11-07 11:24:07 -080081else
Radha krishna Simha Jiguru69224582015-11-04 15:28:58 +053082NSS_CCFLAGS = -DNSS_DT_SUPPORT=1 -DNSS_FW_DBG_SUPPORT=0 -DNSS_PM_SUPPORT=0 -DNSS_EMPTY_BUFFER_SIZE=1984
Stephen Wang90c67de2016-04-26 15:15:59 -070083
Sundarajan Srinivasan4691ba62014-11-07 11:24:07 -080084ccflags-y += -I$(obj)
85endif
86
ratheesh kannotha1245c32015-11-04 16:45:43 +053087# Only the 3.14 Kernel implements fabric scaling framework and map-t
Stephen Wang463f1cf2016-03-29 15:25:51 -070088ifneq ($(findstring 3.14, $(KERNELVERSION)),)
Stephen Wang90c67de2016-04-26 15:15:59 -070089NSS_CCFLAGS += -DNSS_FABRIC_SCALING_SUPPORT=1
Stephen Wang463f1cf2016-03-29 15:25:51 -070090else
Stephen Wang90c67de2016-04-26 15:15:59 -070091NSS_CCFLAGS += -DNSS_FABRIC_SCALING_SUPPORT=0
Stephen Wang463f1cf2016-03-29 15:25:51 -070092endif
93
Arunkumar T28b2d742015-06-16 22:15:58 +053094# Disable Frequency scaling
95ifeq "$(NSS_FREQ_SCALE_DISABLE)" "y"
96ccflags-y += -DNSS_FREQ_SCALE_SUPPORT=0
97else
98qca-nss-drv-objs += nss_freq.o
99ccflags-y += -DNSS_FREQ_SCALE_SUPPORT=1
100endif
101
Sundarajan Srinivasan4691ba62014-11-07 11:24:07 -0800102ccflags-y += $(NSS_CCFLAGS)
103
104export NSS_CCFLAGS
105
Pamidipati, Vijayc6ae5662013-06-10 11:03:55 +0530106obj ?= .
Abhishek Rastogibc74e432013-04-02 10:28:22 +0530107