1*a23fd118Syl150051# 2*a23fd118Syl150051# CDDL HEADER START 3*a23fd118Syl150051# 4*a23fd118Syl150051# The contents of this file are subject to the terms of the 5*a23fd118Syl150051# Common Development and Distribution License (the "License"). 6*a23fd118Syl150051# You may not use this file except in compliance with the License. 7*a23fd118Syl150051# 8*a23fd118Syl150051# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 9*a23fd118Syl150051# or http://www.opensolaris.org/os/licensing. 10*a23fd118Syl150051# See the License for the specific language governing permissions 11*a23fd118Syl150051# and limitations under the License. 12*a23fd118Syl150051# 13*a23fd118Syl150051# When distributing Covered Code, include this CDDL HEADER in each 14*a23fd118Syl150051# file and include the License file at usr/src/OPENSOLARIS.LICENSE. 15*a23fd118Syl150051# If applicable, add the following below this CDDL HEADER, with the 16*a23fd118Syl150051# fields enclosed by brackets "[]" replaced with your own identifying 17*a23fd118Syl150051# information: Portions Copyright [yyyy] [name of copyright owner] 18*a23fd118Syl150051# 19*a23fd118Syl150051# CDDL HEADER END 20*a23fd118Syl150051# 21*a23fd118Syl150051 22*a23fd118Syl150051# 23*a23fd118Syl150051# Copyright 2006 Sun Microsystems, Inc. All rights reserved. 24*a23fd118Syl150051# Use is subject to license terms. 25*a23fd118Syl150051# 26*a23fd118Syl150051# ident "%Z%%M% %I% %E% SMI" 27*a23fd118Syl150051# 28*a23fd118Syl150051# This makefile drives the production of the Neterion Xframe 29*a23fd118Syl150051# 10G Ethernet (XGE) driver module in x86 systems 30*a23fd118Syl150051# 31*a23fd118Syl150051 32*a23fd118Syl150051# 33*a23fd118Syl150051# Paths to the base of the uts directory trees 34*a23fd118Syl150051# 35*a23fd118Syl150051UTSBASE = ../.. 36*a23fd118Syl150051 37*a23fd118Syl150051# 38*a23fd118Syl150051# Define the module and object file sets. 39*a23fd118Syl150051# 40*a23fd118Syl150051MODULE = xge 41*a23fd118Syl150051OBJECTS = $(XGE_HAL_OBJS:%=$(OBJS_DIR)/%) $(XGE_OBJS:%=$(OBJS_DIR)/%) 42*a23fd118Syl150051LINTS = $(XGE_HAL_OBJS:%.o=$(LINTS_DIR)/%.ln) $(XGE_OBJS:%.o=$(LINTS_DIR)/%.ln) 43*a23fd118Syl150051ROOTMODULE = $(ROOT_DRV_DIR)/$(MODULE) 44*a23fd118Syl150051 45*a23fd118Syl150051# 46*a23fd118Syl150051# Include common rules. 47*a23fd118Syl150051# 48*a23fd118Syl150051include $(UTSBASE)/sparc/Makefile.sparc 49*a23fd118Syl150051 50*a23fd118Syl150051# 51*a23fd118Syl150051# Define targets 52*a23fd118Syl150051# 53*a23fd118Syl150051ALL_TARGET = $(BINARY) 54*a23fd118Syl150051LINT_TARGET = $(MODULE).lint 55*a23fd118Syl150051INSTALL_TARGET = $(BINARY) $(ROOTMODULE) 56*a23fd118Syl150051 57*a23fd118Syl150051# 58*a23fd118Syl150051# GENERAL PURPOUSE HAL FLAGS: Tuning HAL for Solaris specific modes 59*a23fd118Syl150051# 60*a23fd118Syl150051HAL_CFLAGS = -DXGE_HAL_USE_MGMT_AUX 61*a23fd118Syl150051 62*a23fd118Syl150051# 63*a23fd118Syl150051# TRACE SECTION: Possible values for MODULE, TRACE and ERR masks: 64*a23fd118Syl150051# 65*a23fd118Syl150051# XGE_COMPONENT_HAL_CONFIG 0x1 66*a23fd118Syl150051# XGE_COMPONENT_HAL_FIFO 0x2 67*a23fd118Syl150051# XGE_COMPONENT_HAL_RING 0x4 68*a23fd118Syl150051# XGE_COMPONENT_HAL_CHANNEL 0x8 69*a23fd118Syl150051# XGE_COMPONENT_HAL_DEVICE 0x10 70*a23fd118Syl150051# XGE_COMPONENT_HAL_MM 0x20 71*a23fd118Syl150051# XGE_COMPONENT_HAL_QUEUE 0x40 72*a23fd118Syl150051# XGE_COMPONENT_HAL_STATS 0x100 73*a23fd118Syl150051# XGE_COMPONENT_OSDEP 0x1000 74*a23fd118Syl150051# XGE_COMPONENT_LL 0x2000 75*a23fd118Syl150051# XGE_COMPONENT_TOE 0x4000 76*a23fd118Syl150051# XGE_COMPONENT_RDMA 0x8000 77*a23fd118Syl150051# XGE_COMPONENT_ALL 0xffffffff 78*a23fd118Syl150051#TRACE_CFLAGS = -DXGE_DEBUG_MODULE_MASK=0xffffffff \ 79*a23fd118Syl150051# -DXGE_DEBUG_TRACE_MASK=0xffffffff \ 80*a23fd118Syl150051# -DXGE_DEBUG_ERR_MASK=0xffffffff 81*a23fd118Syl150051TRACE_CFLAGS = -DXGE_DEBUG_MODULE_MASK=0x00003010 \ 82*a23fd118Syl150051 -DXGE_DEBUG_TRACE_MASK=0x00000000 \ 83*a23fd118Syl150051 -DXGE_DEBUG_ERR_MASK=0x00003010 84*a23fd118Syl150051 85*a23fd118Syl150051# 86*a23fd118Syl150051# ASSERT/DEBUG SECTION: Disable/enable assert and debug mode 87*a23fd118Syl150051# 88*a23fd118Syl150051ASSERT_CFLAGS = -DXGE_DEBUG_ASSERT 89*a23fd118Syl150051 90*a23fd118Syl150051# 91*a23fd118Syl150051# FAST PATH SECTION: Will activate usage of inlines as a regular functions 92*a23fd118Syl150051# on fast data path 93*a23fd118Syl150051#FP_CFLAGS = -DXGE_DEBUG_FP=0xff 94*a23fd118Syl150051 95*a23fd118Syl150051CPPFLAGS += $(HAL_CFLAGS) $(TRACE_CFLAGS) $(ASSERT_CFLAGS) $(CCVERBOSE) \ 96*a23fd118Syl150051 -I$(UTSBASE)/common/io/xge/hal/include \ 97*a23fd118Syl150051 -I$(UTSBASE)/common/io/xge/hal/xgehal \ 98*a23fd118Syl150051 -I$(UTSBASE)/common/io/xge/drv -DSOLARIS 99*a23fd118Syl150051 100*a23fd118Syl150051CFLAGS += $(CPPFLAGS) -xc99=%all 101*a23fd118Syl150051 102*a23fd118Syl150051# 103*a23fd118Syl150051# Driver depends on MAC & IP 104*a23fd118Syl150051# 105*a23fd118Syl150051LDFLAGS += -dy -N misc/mac -N drv/ip 106*a23fd118Syl150051 107*a23fd118Syl150051# Lint flag 108*a23fd118Syl150051# 109*a23fd118Syl150051LINTFLAGS += $(CPPFLAGS) -Xc99=%all 110*a23fd118Syl150051 111*a23fd118Syl150051# 112*a23fd118Syl150051# 113*a23fd118Syl150051# Default build targets. 114*a23fd118Syl150051# 115*a23fd118Syl150051.KEEP_STATE: 116*a23fd118Syl150051 117*a23fd118Syl150051def: $(DEF_DEPS) 118*a23fd118Syl150051 119*a23fd118Syl150051all: $(ALL_DEPS) 120*a23fd118Syl150051 121*a23fd118Syl150051clean: $(CLEAN_DEPS) 122*a23fd118Syl150051 123*a23fd118Syl150051clobber: $(CLOBBER_DEPS) 124*a23fd118Syl150051 125*a23fd118Syl150051lint: $(LINT_DEPS) 126*a23fd118Syl150051 127*a23fd118Syl150051modlintlib: $(MODLINTLIB_DEPS) 128*a23fd118Syl150051 129*a23fd118Syl150051clean.lint: $(CLEAN_LINT_DEPS) 130*a23fd118Syl150051 131*a23fd118Syl150051install: $(INSTALL_DEPS) 132*a23fd118Syl150051 133*a23fd118Syl150051# 134*a23fd118Syl150051# Include common targets. 135*a23fd118Syl150051# 136*a23fd118Syl150051include $(UTSBASE)/sparc/Makefile.targ 137