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