1d39a76e7Sxw161283# CDDL HEADER START 2d39a76e7Sxw161283# 3d39a76e7Sxw161283# The contents of this file are subject to the terms of the 4d39a76e7Sxw161283# Common Development and Distribution License (the "License"). 5d39a76e7Sxw161283# You may not use this file except in compliance with the License. 6d39a76e7Sxw161283# 7d39a76e7Sxw161283# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE 8d39a76e7Sxw161283# or http://www.opensolaris.org/os/licensing. 9d39a76e7Sxw161283# See the License for the specific language governing permissions 10d39a76e7Sxw161283# and limitations under the License. 11d39a76e7Sxw161283# 12d39a76e7Sxw161283# When distributing Covered Code, include this CDDL HEADER in each 13d39a76e7Sxw161283# file and include the License file at usr/src/OPENSOLARIS.LICENSE. 14d39a76e7Sxw161283# If applicable, add the following below this CDDL HEADER, with the 15d39a76e7Sxw161283# fields enclosed by brackets "[]" replaced with your own identifying 16d39a76e7Sxw161283# information: Portions Copyright [yyyy] [name of copyright owner] 17d39a76e7Sxw161283# 18d39a76e7Sxw161283# CDDL HEADER END 19d39a76e7Sxw161283# 20d39a76e7Sxw161283 21d39a76e7Sxw161283# 22d39a76e7Sxw161283# Copyright 2007 Sun Microsystems, Inc. All rights reserved. 23d39a76e7Sxw161283# Use is subject to license terms. 24d39a76e7Sxw161283# 25*7014882cSRichard Lowe 26d39a76e7Sxw161283# 27d39a76e7Sxw161283# This makefile drives the production of the Chelsio N110 28d39a76e7Sxw161283# 10G Ethernet (CH) driver module in x86 systems 29d39a76e7Sxw161283# 30d39a76e7Sxw161283 31d39a76e7Sxw161283# 32d39a76e7Sxw161283# Path to the base of the uts directory tree (usually /usr/src/uts). 33d39a76e7Sxw161283# 34d39a76e7Sxw161283UTSBASE = ../.. 35d39a76e7Sxw161283 36d39a76e7Sxw161283# 37d39a76e7Sxw161283# Define the module and object file sets. 38d39a76e7Sxw161283# 39d39a76e7Sxw161283MODULE = chxge 40d39a76e7Sxw161283OBJECTS = $(CH_OBJS:%=$(OBJS_DIR)/%) $(CH_COM_OBJS:%=$(OBJS_DIR)/%) 41d39a76e7Sxw161283LINTS = $(CH_OBJS:%.o=$(LINTS_DIR)/%.ln) $(CH_COM_OBJS:%.o=$(LINTS_DIR)/%.ln) 42d39a76e7Sxw161283ROOTMODULE = $(ROOT_DRV_DIR)/$(MODULE) 43d39a76e7Sxw161283 44d39a76e7Sxw161283# 45d39a76e7Sxw161283# Include common rules. 46d39a76e7Sxw161283# 47d39a76e7Sxw161283include $(UTSBASE)/sparc/Makefile.sparc 48d39a76e7Sxw161283 49d39a76e7Sxw161283# 50d39a76e7Sxw161283# Define targets 51d39a76e7Sxw161283# 52d39a76e7Sxw161283ALL_TARGET = $(BINARY) 53d39a76e7Sxw161283LINT_TARGET = $(MODULE).lint 54d39a76e7Sxw161283INSTALL_TARGET = $(BINARY) $(ROOTMODULE) 55d39a76e7Sxw161283 56d39a76e7Sxw161283CFLAGS += -DC99_NOT_SUPPORTED -DCONFIG_CHELSIO_T1_1G \ 57d39a76e7Sxw161283 -I$(UTSBASE)/common/io/chxge/ \ 58d39a76e7Sxw161283 -I$(UTSBASE)/common/io/chxge/com 59d39a76e7Sxw161283 60d39a76e7Sxw161283CFLAGS += -DCONFIG_SMP 61d39a76e7Sxw161283 62d39a76e7Sxw161283CFLAGS += -DRX_MAX_COUNT=256 63d39a76e7Sxw161283 64d39a76e7Sxw161283CFLAGS += -DCONFIG_CHELSIO_T1_OFFLOAD 65d39a76e7Sxw161283 66d39a76e7Sxw161283CFLAGS += -DSUN_KSTATS -DHOST_PAUSE -DTX_CKSUM_FIX -DTX_THREAD_RECLAIM 67d39a76e7Sxw161283 68d39a76e7Sxw161283CFLAGS += -xc99=%all 69d39a76e7Sxw161283 70d39a76e7Sxw161283# Debug flags 71d39a76e7Sxw161283# CFLAGS += -DCH_DEBUG=1 -DPE_DBGOUT_ENABLED=1 72d39a76e7Sxw161283 73d39a76e7Sxw161283# 74d39a76e7Sxw161283# Driver depends on GLD & IP 75d39a76e7Sxw161283# 76d39a76e7Sxw161283LDFLAGS += -dy -N misc/gld -N drv/ip 77d39a76e7Sxw161283 78d39a76e7Sxw161283# Lint flag 79d39a76e7Sxw161283# 80d39a76e7Sxw161283LINTFLAGS += -DC99_NOT_SUPPORTED -DCONFIG_CHELSIO_T1_1G \ 81d39a76e7Sxw161283 -I$(UTSBASE)/common/io/chxge/ \ 82d39a76e7Sxw161283 -I$(UTSBASE)/common/io/chxge/com 83d39a76e7Sxw161283 84d39a76e7Sxw161283LINTFLAGS += -DCONFIG_SMP 85d39a76e7Sxw161283 86d39a76e7Sxw161283LINTFLAGS += -DRX_MAX_COUNT=256 87d39a76e7Sxw161283 88d39a76e7Sxw161283LINTFLAGS += -DCONFIG_CHELSIO_T1_OFFLOAD 89d39a76e7Sxw161283 90d39a76e7Sxw161283LINTFLAGS += -DSUN_KSTATS -DHOST_PAUSE -DTX_CKSUM_FIX -DTX_THREAD_RECLAIM 91d39a76e7Sxw161283 92d39a76e7Sxw161283LINTFLAGS += -Xc99=%all 93d39a76e7Sxw161283 94d39a76e7Sxw161283# 95d39a76e7Sxw161283# For now, disable these lint checks; maintainers should endeavor 96d39a76e7Sxw161283# to investigate and remove these for maximum lint coverage. 97d39a76e7Sxw161283# Please do not carry these forward to new Makefiles. 98d39a76e7Sxw161283# 99d39a76e7Sxw161283LINTTAGS += -erroff=E_BAD_PTR_CAST_ALIGN 100d39a76e7Sxw161283LINTTAGS += -erroff=E_PTRDIFF_OVERFLOW 101d39a76e7Sxw161283LINTTAGS += -erroff=E_ASSIGN_NARROW_CONV 102d39a76e7Sxw161283LINTTAGS += -erroff=E_STATIC_UNUSED 103d39a76e7Sxw161283 104*7014882cSRichard LoweCERRWARN += -_gcc=-Wno-unused-label 105*7014882cSRichard LoweCERRWARN += -_gcc=-Wno-unused-function 106*7014882cSRichard LoweCERRWARN += -_gcc=-Wno-unused-variable 107*7014882cSRichard LoweCERRWARN += -_gcc=-Wno-parentheses 108*7014882cSRichard Lowe 109d39a76e7Sxw161283# 110d39a76e7Sxw161283# 111d39a76e7Sxw161283# Default build targets. 112d39a76e7Sxw161283# 113d39a76e7Sxw161283.KEEP_STATE: 114d39a76e7Sxw161283 115d39a76e7Sxw161283def: $(DEF_DEPS) 116d39a76e7Sxw161283 117d39a76e7Sxw161283all: $(ALL_DEPS) 118d39a76e7Sxw161283 119d39a76e7Sxw161283clean: $(CLEAN_DEPS) 120d39a76e7Sxw161283 121d39a76e7Sxw161283clobber: $(CLOBBER_DEPS) 122d39a76e7Sxw161283 123d39a76e7Sxw161283lint: $(LINT_DEPS) 124d39a76e7Sxw161283 125d39a76e7Sxw161283modlintlib: $(MODLINTLIB_DEPS) 126d39a76e7Sxw161283 127d39a76e7Sxw161283clean.lint: $(CLEAN_LINT_DEPS) 128d39a76e7Sxw161283 129d39a76e7Sxw161283install: $(INSTALL_DEPS) 130d39a76e7Sxw161283 131d39a76e7Sxw161283# 132d39a76e7Sxw161283# Include common targets. 133d39a76e7Sxw161283# 134d39a76e7Sxw161283include $(UTSBASE)/sparc/Makefile.targ 135