Makefile revision 4496171313bed39e96f21bc2f9faf2868e267ae3
7f007e36bec06aba6b3a0f84a64f2abf99edfcd8gstein#
a908203473820d096b31fc0f349711d3092ae684lars# CDDL HEADER START
2a6c49cfaef5979a5a06098f3ce987cd76769409manoj#
2a6c49cfaef5979a5a06098f3ce987cd76769409manoj# The contents of this file are subject to the terms of the
2a6c49cfaef5979a5a06098f3ce987cd76769409manoj# Common Development and Distribution License (the "License").
a8d5ccbcbde8cb6cf3a9dcf2eb05f393ab76baa9ianh# You may not use this file except in compliance with the License.
694514f7e6e99917e084943e3a05950b3c7c106ajerenkrantz#
4214e98fc9045e5010e66f9a967bd6d68f40d342aaron# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
8721697e2aece27b0e738519329f7976c72b27bfjerenkrantz# or http://www.opensolaris.org/os/licensing.
4a257be29f8aeab984fe5622fa69e0b2aab204d7jerenkrantz# See the License for the specific language governing permissions
91cacb801f6c0215b38322f6d2fc58cbfedfecfbjerenkrantz# and limitations under the License.
91cacb801f6c0215b38322f6d2fc58cbfedfecfbjerenkrantz#
df14f0d3a5191cdd7c4bb5b03acd135d43a6f51brbb# When distributing Covered Code, include this CDDL HEADER in each
df14f0d3a5191cdd7c4bb5b03acd135d43a6f51brbb# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
ab71b233b3a36489e44a7b061c48293be0b17788jwoolley# If applicable, add the following below this CDDL HEADER, with the
571760de5e60c0b459cb11be45507b923cd023eejwoolley# fields enclosed by brackets "[]" replaced with your own identifying
571760de5e60c0b459cb11be45507b923cd023eejwoolley# information: Portions Copyright [yyyy] [name of copyright owner]
9180a5933673ffb1af633c255ceee029340f3b1erbb#
bcb6e1be6041dfeb549c8ea8d37f97ad4e90a0c3rbb# CDDL HEADER END
9bd71e35f5d26d26d23fe3a677401828e842ed72wrowe#
2900ab946a2d76b73a14cebfe2985d253f01c967stoddard# uts/sun4v/nxge/Makefile
a548c09e6a8ca1b059d0e93b5256c6ccb2b3c3cdrbb#
a548c09e6a8ca1b059d0e93b5256c6ccb2b3c3cdrbb# Copyright 2006 Sun Microsystems, Inc. All rights reserved.
a548c09e6a8ca1b059d0e93b5256c6ccb2b3c3cdrbb# Use is subject to license terms.
b876b7bcf0ce3d232da723246d709e8dbbfe8762rbb#
cf6bf6c34c936e6a6fe731dbce4a5c3c8bf8e9a3gstein#
35330e0d79ceb8027223bbb8330a381b1f989d6etrawick# ident "%Z%%M% %I% %E% SMI"
6f6f4a4bca281779d196acbdd5c017bb90858305trawick#
8dd4618c4709236b4ea297d7250d282e463ce2d8rbb# This makefile drives the production of the N2 NIU
09bd86d0db1114ee23eda0a6eb76ca055877a1cftrawick# 10G Ethernet leaf driver kernel module.
2deb319e6b3de239f45c16a3e9e836d44f1f7108rbb#
bd929c73ef04789b7183b840d8db6e01d03a4d86rbb# sun4v implementation architecture dependent
70f6f32765cfaadd6da8de6f0fea97ddd72d8fadmanoj#
2a6c49cfaef5979a5a06098f3ce987cd76769409manoj
af4c982a7cf4515f124935f99a329744035fc699slive#
af4c982a7cf4515f124935f99a329744035fc699slive# Path to the base of the uts directory tree (usually /usr/src/uts).
af4c982a7cf4515f124935f99a329744035fc699slive#
af4c982a7cf4515f124935f99a329744035fc699sliveUTSBASE = ../..
af4c982a7cf4515f124935f99a329744035fc699slive
af4c982a7cf4515f124935f99a329744035fc699slive#
af4c982a7cf4515f124935f99a329744035fc699slive# Define the module and object file sets.
10270f6f94b2069d0d357805c140a9897449b9ccianh#
2a6c49cfaef5979a5a06098f3ce987cd76769409manojMODULE = nxge
10270f6f94b2069d0d357805c140a9897449b9ccianhOBJECTS = $(NXGE_OBJS:%=$(OBJS_DIR)/%) $(NXGE_NPI_OBJS:%=$(OBJS_DIR)/%)
10270f6f94b2069d0d357805c140a9897449b9ccianhLINTS = $(NXGE_OBJS:%.o=$(LINTS_DIR)/%.ln) \
a908203473820d096b31fc0f349711d3092ae684lars $(NXGE_NPI_OBJS:%.o=$(LINTS_DIR)/%.ln)
10270f6f94b2069d0d357805c140a9897449b9ccianhROOTMODULE = $(ROOT_PSM_DRV_DIR)/$(MODULE)
020fe2135763b51ac6221adcc51c3fb6509e7a95brianp
a908203473820d096b31fc0f349711d3092ae684lars#
10270f6f94b2069d0d357805c140a9897449b9ccianh# Include common rules.
10270f6f94b2069d0d357805c140a9897449b9ccianh#
10270f6f94b2069d0d357805c140a9897449b9ccianhinclude $(UTSBASE)/sun4v/Makefile.sun4v
10270f6f94b2069d0d357805c140a9897449b9ccianh
10270f6f94b2069d0d357805c140a9897449b9ccianh#
10270f6f94b2069d0d357805c140a9897449b9ccianh# Override defaults to build a unique, local modstubs.o.
10270f6f94b2069d0d357805c140a9897449b9ccianh#
10270f6f94b2069d0d357805c140a9897449b9ccianhMODSTUBS_DIR = $(OBJS_DIR)
10270f6f94b2069d0d357805c140a9897449b9ccianh
10270f6f94b2069d0d357805c140a9897449b9ccianhCLEANFILES += $(MODSTUBS_O)
58e0ed3d1f052d695078b1d2a61c19246776eab5jerenkrantz
10270f6f94b2069d0d357805c140a9897449b9ccianh#
10270f6f94b2069d0d357805c140a9897449b9ccianh# Define targets
ff42f83cbf31893bcde9712332a8e5ee970f6a74trawick#
ff42f83cbf31893bcde9712332a8e5ee970f6a74trawickALL_TARGET = $(BINARY)
ff42f83cbf31893bcde9712332a8e5ee970f6a74trawickLINT_TARGET = $(MODULE).lint
ff42f83cbf31893bcde9712332a8e5ee970f6a74trawickINSTALL_TARGET = $(BINARY) $(ROOTMODULE)
ff42f83cbf31893bcde9712332a8e5ee970f6a74trawick
ff42f83cbf31893bcde9712332a8e5ee970f6a74trawick#
ff42f83cbf31893bcde9712332a8e5ee970f6a74trawick#
ff42f83cbf31893bcde9712332a8e5ee970f6a74trawick# Turn on doubleword alignment for 64 bit registers
ff42f83cbf31893bcde9712332a8e5ee970f6a74trawick#
ff42f83cbf31893bcde9712332a8e5ee970f6a74trawickCFLAGS += -dalign
ff42f83cbf31893bcde9712332a8e5ee970f6a74trawick#
77304e37d675303eef0355fc3bb9a12bb506547ajerenkrantz# Include nxge specific header files
77304e37d675303eef0355fc3bb9a12bb506547ajerenkrantz#
77304e37d675303eef0355fc3bb9a12bb506547ajerenkrantzINC_PATH += -I$(UTSBASE)/sun4v/io/nxge/npi
ff42f83cbf31893bcde9712332a8e5ee970f6a74trawickINC_PATH += -I$(UTSBASE)/sun4v/sys/nxge
77304e37d675303eef0355fc3bb9a12bb506547ajerenkrantz#
77304e37d675303eef0355fc3bb9a12bb506547ajerenkrantz#
10270f6f94b2069d0d357805c140a9897449b9ccianh# lint pass one enforcement
10270f6f94b2069d0d357805c140a9897449b9ccianh#
531c23ff01a2489646f0a2029097013b328d935agsteinCFLAGS += -DSOLARIS
c00273b9c51c617ede471e9cb95c22420f1227fbbrianp# NEMO
c00273b9c51c617ede471e9cb95c22420f1227fbbrianp#CFLAGS += -DNEMO
c00273b9c51c617ede471e9cb95c22420f1227fbbrianp#
6758b07b4b79f898b0f56375016cea7da0bfb495wrowe# Enable the following flags to run mac internal loopback under legion
6758b07b4b79f898b0f56375016cea7da0bfb495wrowe#CFLAGS += -DLEGION -DAXIS -DAXIS_DEBUG -DAXIS_DEBUG_LB -DSAM_DEBUG
6758b07b4b79f898b0f56375016cea7da0bfb495wrowe#
6758b07b4b79f898b0f56375016cea7da0bfb495wrowe# Enable the following flags to run mac internal loopback under AXIS
020fe2135763b51ac6221adcc51c3fb6509e7a95brianp# (NOTE: LEGION flag can be enabled too)
020fe2135763b51ac6221adcc51c3fb6509e7a95brianp#CFLAGS += -DAXIS_DEBUG -DAXIS -DAXIS_DEBUG_LB -DSAM_DEBUG -DLEGION
c00273b9c51c617ede471e9cb95c22420f1227fbbrianp#
54e1babd5a5a56c576eeeace54110150769cc916coar# Enable NXGE debug
54e1babd5a5a56c576eeeace54110150769cc916coar#CFLAGS += -DNXGE_DEBUG
54e1babd5a5a56c576eeeace54110150769cc916coar# Enable NPI debug
77304e37d675303eef0355fc3bb9a12bb506547ajerenkrantz#CFLAGS += -DNPI_DEBUG
77304e37d675303eef0355fc3bb9a12bb506547ajerenkrantz#CFLAGS += -DUSE_RX_BUFF_ATTR
77304e37d675303eef0355fc3bb9a12bb506547ajerenkrantz
77304e37d675303eef0355fc3bb9a12bb506547ajerenkrantz#CFLAGS += -DNIU_PA_WORKAROUND
77304e37d675303eef0355fc3bb9a12bb506547ajerenkrantz#CFLAGS += -DNIU_HV_WORKAROUND
54e1babd5a5a56c576eeeace54110150769cc916coarCFLAGS += -DNIU_LP_WORKAROUND
7fe18c15b669db9d191859695901dc4fcf3829dawrowe
7fe18c15b669db9d191859695901dc4fcf3829dawroweLINTFLAGS += -DSOLARIS
7fe18c15b669db9d191859695901dc4fcf3829dawroweLINTFLAGS += -DNIU_LP_WORKAROUND
b84f66c93f820824b1d5455181f55598b766319cwrowe#
7fe18c15b669db9d191859695901dc4fcf3829dawrowe# STREAMS, DDI API limitations and other ON header file definitions such as ethernet.h
976501adbc040220270f7d1d77c4b8373033be69wrowe# force us to turn off these lint checks.
976501adbc040220270f7d1d77c4b8373033be69wrowe#
976501adbc040220270f7d1d77c4b8373033be69wroweLINTTAGS += -erroff=E_BAD_PTR_CAST_ALIGN
976501adbc040220270f7d1d77c4b8373033be69wroweLINTTAGS += -erroff=E_PTRDIFF_OVERFLOW
976501adbc040220270f7d1d77c4b8373033be69wrowe#
b84f66c93f820824b1d5455181f55598b766319cwrowe# Driver depends on mac & IP
bf9acc131271d18db51d30ace549d3c3b6a2b9fbrbb#
bf9acc131271d18db51d30ace549d3c3b6a2b9fbrbbLDFLAGS += -dy -N misc/mac -N drv/ip
bf9acc131271d18db51d30ace549d3c3b6a2b9fbrbb
bf9acc131271d18db51d30ace549d3c3b6a2b9fbrbb#
bf9acc131271d18db51d30ace549d3c3b6a2b9fbrbb# Default build targets.
bf9acc131271d18db51d30ace549d3c3b6a2b9fbrbb#
a9a0f66fee736c72861cb2819b67b7784896a37cjerenkrantz.KEEP_STATE:
a9a0f66fee736c72861cb2819b67b7784896a37cjerenkrantz
a9a0f66fee736c72861cb2819b67b7784896a37cjerenkrantzdef: $(DEF_DEPS)
ff42f83cbf31893bcde9712332a8e5ee970f6a74trawick
bf9acc131271d18db51d30ace549d3c3b6a2b9fbrbball: $(ALL_DEPS)
1b3f48fd6b1ccb8745f908e40156c5a85ca3c347jerenkrantz
1b3f48fd6b1ccb8745f908e40156c5a85ca3c347jerenkrantzclean: $(CLEAN_DEPS)
1b3f48fd6b1ccb8745f908e40156c5a85ca3c347jerenkrantz
1b3f48fd6b1ccb8745f908e40156c5a85ca3c347jerenkrantzclobber: $(CLOBBER_DEPS)
1b3f48fd6b1ccb8745f908e40156c5a85ca3c347jerenkrantz
1b3f48fd6b1ccb8745f908e40156c5a85ca3c347jerenkrantzlint: $(LINT_DEPS)
1b3f48fd6b1ccb8745f908e40156c5a85ca3c347jerenkrantz
020fe2135763b51ac6221adcc51c3fb6509e7a95brianpmodlintlib: $(MODLINTLIB_DEPS)
1b3f48fd6b1ccb8745f908e40156c5a85ca3c347jerenkrantz
108db76823f2261a33aaa3621af6a1e54db17a69trawickclean.lint: $(CLEAN_LINT_DEPS)
108db76823f2261a33aaa3621af6a1e54db17a69trawick
108db76823f2261a33aaa3621af6a1e54db17a69trawickinstall: $(INSTALL_DEPS)
108db76823f2261a33aaa3621af6a1e54db17a69trawick
aea283240d4222da5426169a68e307872d240044jerenkrantz#
a9a0f66fee736c72861cb2819b67b7784896a37cjerenkrantz# Include common targets.
a9a0f66fee736c72861cb2819b67b7784896a37cjerenkrantz#
a9a0f66fee736c72861cb2819b67b7784896a37cjerenkrantzinclude $(UTSBASE)/$(PLATFORM)/Makefile.targ
a9a0f66fee736c72861cb2819b67b7784896a37cjerenkrantz