xref: /titanic_52/usr/src/uts/intel/sfe/Makefile (revision f8919bdadda3ebb97bd55cc14a16e0271ed57615)
1*f8919bdaSduboff#
2*f8919bdaSduboff# CDDL HEADER START
3*f8919bdaSduboff#
4*f8919bdaSduboff# The contents of this file are subject to the terms of the
5*f8919bdaSduboff# Common Development and Distribution License (the "License").
6*f8919bdaSduboff# You may not use this file except in compliance with the License.
7*f8919bdaSduboff#
8*f8919bdaSduboff# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
9*f8919bdaSduboff# or http://www.opensolaris.org/os/licensing.
10*f8919bdaSduboff# See the License for the specific language governing permissions
11*f8919bdaSduboff# and limitations under the License.
12*f8919bdaSduboff#
13*f8919bdaSduboff# When distributing Covered Code, include this CDDL HEADER in each
14*f8919bdaSduboff# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
15*f8919bdaSduboff# If applicable, add the following below this CDDL HEADER, with the
16*f8919bdaSduboff# fields enclosed by brackets "[]" replaced with your own identifying
17*f8919bdaSduboff# information: Portions Copyright [yyyy] [name of copyright owner]
18*f8919bdaSduboff#
19*f8919bdaSduboff# CDDL HEADER END
20*f8919bdaSduboff#
21*f8919bdaSduboff#
22*f8919bdaSduboff# Copyright 2007 Sun Microsystems, Inc.  All rights reserved.
23*f8919bdaSduboff# Use is subject to license terms.
24*f8919bdaSduboff#
25*f8919bdaSduboff# ident	"%Z%%M%	%I%	%E% SMI"
26*f8919bdaSduboff#
27*f8919bdaSduboff#	This makefile drives the production of NS/SiS
28*f8919bdaSduboff#	Fast Ethernet (SFE) driver module in intel systems
29*f8919bdaSduboff#
30*f8919bdaSduboff
31*f8919bdaSduboff#
32*f8919bdaSduboff#	Path to the base of the uts directory tree (usually /usr/src/uts).
33*f8919bdaSduboff#
34*f8919bdaSduboffUTSBASE		= ../..
35*f8919bdaSduboff
36*f8919bdaSduboff#
37*f8919bdaSduboff#	Define the module and object file sets.
38*f8919bdaSduboff#
39*f8919bdaSduboffMODULE		= sfe
40*f8919bdaSduboffOBJECTS		= $(SFE_OBJS:%=$(OBJS_DIR)/%)
41*f8919bdaSduboffLINTS		= $(SFE_OBJS:%.o=$(LINTS_DIR)/%.ln)
42*f8919bdaSduboffROOTMODULE	= $(ROOT_DRV_DIR)/$(MODULE)
43*f8919bdaSduboff
44*f8919bdaSduboff#
45*f8919bdaSduboff#	Include common rules.
46*f8919bdaSduboff#
47*f8919bdaSduboffinclude $(UTSBASE)/intel/Makefile.intel
48*f8919bdaSduboff
49*f8919bdaSduboff#
50*f8919bdaSduboff#	Define targets
51*f8919bdaSduboff#
52*f8919bdaSduboffALL_TARGET	= $(BINARY)
53*f8919bdaSduboffLINT_TARGET	= $(MODULE).lint
54*f8919bdaSduboffINSTALL_TARGET	= $(BINARY) $(ROOTMODULE)
55*f8919bdaSduboff
56*f8919bdaSduboff#
57*f8919bdaSduboff#	Overrides
58*f8919bdaSduboff#
59*f8919bdaSduboff#
60*f8919bdaSduboff# For now, disable these lint checks; maintainers should endeavor
61*f8919bdaSduboff# to investigate and remove these for maximum lint coverage.
62*f8919bdaSduboff# Please do not carry these forward to new Makefiles.
63*f8919bdaSduboff#
64*f8919bdaSduboff# LINTTAGS	+= -erroff=E_SUSPICIOUS_COMPARISON
65*f8919bdaSduboff# LINTTAGS	+= -erroff=E_BAD_PTR_CAST_ALIGN
66*f8919bdaSduboff# LINTTAGS	+= -erroff=E_PTRDIFF_OVERFLOW
67*f8919bdaSduboff# LINTTAGS	+= -erroff=E_ASSIGN_NARROW_CONV
68*f8919bdaSduboff# LINTTAGS	+= -erroff=E_STATIC_UNUSED
69*f8919bdaSduboff
70*f8919bdaSduboff#
71*f8919bdaSduboff#	GENERAL PURPOUSE GEM FLAGS: Tuning GEM for Solaris specific modes
72*f8919bdaSduboff#
73*f8919bdaSduboffVFLAGS		= -DVERSION='"2.6.1"'
74*f8919bdaSduboffAFLAGS		= -Di86pc
75*f8919bdaSduboffDFLAGS		= -D"__INLINE__="
76*f8919bdaSduboffCFGFLAGS	= -DGEM_CONFIG_POLLING -DGEM_CONFIG_GLDv3 -DGEM_CONFIG_VLAN \
77*f8919bdaSduboff	-DGEM_CONFIG_CKSUM_OFFLOAD -DGEM_CONFIG_ND \
78*f8919bdaSduboff	-DCONFIG_DP83815 -DCONFIG_SIS900 -DCONFIG_SIS7016 \
79*f8919bdaSduboff	-DCONFIG_MAC_ADDR_SIS630E -DCONFIG_OPT_IO -UCONFIG_OO \
80*f8919bdaSduboff	-DCONFIG_PATTERN_MATCH_DP83815
81*f8919bdaSduboff#
82*f8919bdaSduboff#	FAST PATH SECTION: Will activate usage of inlines as a regular functions
83*f8919bdaSduboff#	on fast data path
84*f8919bdaSduboff
85*f8919bdaSduboffCPPFLAGS	+= $(VFLAGS) $(AFLAGS) $(DFLAGS) $(CFGFLAGS) $(CCVERBOSE) \
86*f8919bdaSduboff	-I$(UTSBASE)/common/io/sfe
87*f8919bdaSduboff
88*f8919bdaSduboffCFLAGS		+= $(CPPFLAGS) -xc99=%all
89*f8919bdaSduboff
90*f8919bdaSduboff#
91*f8919bdaSduboff# Driver depends on MAC & IP
92*f8919bdaSduboff#
93*f8919bdaSduboffLDFLAGS		+= -dy -N misc/mac -N drv/ip
94*f8919bdaSduboff
95*f8919bdaSduboff#
96*f8919bdaSduboff#	Default build targets.
97*f8919bdaSduboff#
98*f8919bdaSduboff.KEEP_STATE:
99*f8919bdaSduboff
100*f8919bdaSduboffdef:		$(DEF_DEPS)
101*f8919bdaSduboff
102*f8919bdaSduboffall:		$(ALL_DEPS)
103*f8919bdaSduboff
104*f8919bdaSduboffclean:		$(CLEAN_DEPS)
105*f8919bdaSduboff
106*f8919bdaSduboffclobber:	$(CLOBBER_DEPS)
107*f8919bdaSduboff
108*f8919bdaSdubofflint:		$(LINT_DEPS)
109*f8919bdaSduboff
110*f8919bdaSduboffmodlintlib:	$(MODLINTLIB_DEPS)
111*f8919bdaSduboff
112*f8919bdaSduboffclean.lint:	$(CLEAN_LINT_DEPS)
113*f8919bdaSduboff
114*f8919bdaSduboffinstall:	$(INSTALL_DEPS)
115*f8919bdaSduboff
116*f8919bdaSduboff#
117*f8919bdaSduboff#	Include common targets.
118*f8919bdaSduboff#
119*f8919bdaSduboffinclude $(UTSBASE)/intel/Makefile.targ
120