aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/staging/ice4100/sgx535/Makefile
blob: d097496a4b8ffeb16fd57ab06c9c91c0ffe23907 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
#
# Makefile for the graphics hardware.  This driver provides support for the
# Power VR accelerated 2D and 3D cores


PVR_BUILD_DIR ?= $(PWD)


# Services module name
PVRSRV_MODNAME = pvrsrvkm

# FIXME do we need these
# -DSUPPORT_SGX_HWPERF

#-DPVR_LINUX_USING_WORKQUEUES \
#-DPVR_LINUX_MISR_USING_PRIVATE_WORKQUEUE \
#-DPVR_LINUX_TIMERS_USING_WORKQUEUES \
#-DSYS_CUSTOM_POWERLOCK_WRAP


INCDIR=drivers/staging/ice4100/sgx535

include_dirs := -I$(INCDIR)/ \
	-I$(INCDIR)/include \
	-I$(INCDIR)/include/env/linux \
	-I$(INCDIR)/bridged \
	-I$(INCDIR)/bridged/sgx \
	-I$(INCDIR)/devices/sgx \
	-I$(INCDIR)/system \
	-I$(INCDIR)/system/include \
	-I$(INCDIR)/system/sgx_intel_ce \
	-I$(INCDIR)/hwdefs \
	$(ALL_CFLAGS_kbuild)

ccflags-y := $(include_dirs)

# X86_INTEL_CE device information
ccflags-y += -DSGX535 -DSUPPORT_SGX535 -DSGX_CORE_REV=121

ccflags-y += \
	-Werror \
	-DLINUX \
	-DPVR_BUILD_DATE="\"$(DATE)\"" \
	-DPVR_BUILD_DIR="\"$(PVR_BUILD_DIR)\"" \
	-DSERVICES4 \
	-D_XOPEN_SOURCE=600 \
	-DPVR2D_VALIDATE_INPUT_PARAMS \
	-UDEBUG_LOG_PATH_TRUNCATE \
	-DSUPPORT_SRVINIT \
	-DSUPPORT_SGX \
	-DSUPPORT_PERCONTEXT_PB \
	-DSUPPORT_LINUX_X86_WRITECOMBINE \
	-DTRANSFER_QUEUE \
	-DSUPPORT_DRI_DRM \
	-DSYS_USING_INTERRUPTS \
	-DSUPPORT_HW_RECOVERY \
	-DPVR_SECURE_HANDLES \
	-DUSE_PTHREADS \
	-DSUPPORT_SGX_EVENT_OBJECT \
	-DSUPPORT_SGX_LOW_LATENCY_SCHEDULING \
	-DSUPPORT_LINUX_X86_PAT \
	-DPVR_PROC_USE_SEQ_FILE


# Defaults for useful things on the Intel CE platform.
ccflags-$(CONFIG_X86_INTEL_CE) += -DPVRSRV_MODNAME="\"$(PVRSRV_MODNAME)"\"

ccflags-$(CONFIG_X86_INTEL_CE) += -DINTEL_D3_CHANGES=1
ccflags-$(CONFIG_X86_INTEL_CE) += -DINTEL_D3_PAD=1
ccflags-$(CONFIG_X86_INTEL_CE) += -DINTEL_D3_FLUSH=1
ccflags-$(CONFIG_X86_INTEL_CE) += -DINTEL_D3_DISABLE_TEXTURE_STREAM=1
#ccflags-$(CONFIG_X86_INTEL_CE) += -DINTEL_D3_GDL=1
#ccflags-$(CONFIG_X86_INTEL_CE) += -DINTEL_D3_NO_PCI_ENUM=1
ccflags-$(CONFIG_X86_INTEL_CE) += -DINTEL_D3_P_CHANGES=1
ccflags-$(CONFIG_X86_INTEL_CE) += -DINTEL_D3_CACHED_CBUF=1
ccflags-$(CONFIG_X86_INTEL_CE) += -DINTEL_D3_MEEGO=1

# FIXME not sure if we need these
#ccflags-$(CONFIG_CE_RELEASE) += -DUSE_FBDEV
#ccflags-$(CONFIG_CE_RELEASE) += -DFBDEV_NAME="\"$(FBDEV_NAME)\""


ccflags-$(CONFIG_CE_RELEASE) += -DBUILD="\"release\"" -DPVR_BUILD_TYPE="\"release\"" -DRELEASE

ccflags-$(CONFIG_CE_DEBUG) += -DBUILD="\"debug\"" -DPVR_BUILD_TYPE="\"debug\"" -DDEBUG
ccflags-$(CONFIG_CE_DEBUG) += -DDEBUG_LINUX_MEMORY_ALLOCATIONS
ccflags-$(CONFIG_CE_DEBUG) += -DDEBUG_LINUX_MEM_AREAS
ccflags-$(CONFIG_CE_DEBUG) += -DDEBUG_LINUX_MMAP_AREAS
#ccflags-$(CONFIG_CE_DEBUG) += -DDEBUG_LINUX_XML_PROC_FILES
#ccflags-$(CONFIG_CE_DEBUG) += -DDEBUG_LINUX_SLAB_ALLOCATIONS
ccflags-$(CONFIG_CE_DEBUG) += -DDEBUG_BRIDGE_KM
#ccflags-$(CONFIG_CE_DEBUG) += -DDEBUG_TRACE_BRIDGE_KM
#ccflags-$(CONFIG_CE_DEBUG) += -DDEBUG_BRIDGE_KM_DISPATCH_TABLE
#ccflags-$(CONFIG_CE_DEBUG) += -DSUPPORT_HW_RECOVERY

COMMONDIR = common
BRIDGEDIR = bridged
SGXDIR = devices/sgx
SYSDIR = system/sgx_intel_ce
SYSCONFIGDIR = system/sgx_intel_ce

pvrsrvkm-y := osfunc.o \
	 mmap.o \
	 module.o \
	 pdump.o \
	 proc.o \
	 pvr_bridge_k.o \
	 pvr_debug.o \
	 pvr_drm.o \
	 mm.o \
	 mutils.o \
	 event.o \
	 osperproc.o

pvrsrvkm-y += $(COMMONDIR)/buffer_manager.o \
	$(COMMONDIR)/devicemem.o \
	$(COMMONDIR)/deviceclass.o \
	$(COMMONDIR)/handle.o \
	$(COMMONDIR)/hash.o \
	$(COMMONDIR)/metrics.o \
	$(COMMONDIR)/pvrsrv.o \
	$(COMMONDIR)/queue.o \
	$(COMMONDIR)/ra.o \
	$(COMMONDIR)/resman.o \
	$(COMMONDIR)/power.o \
	$(COMMONDIR)/mem.o \
	$(COMMONDIR)/pdump_common.o \
	$(COMMONDIR)/perproc.o \
	$(COMMONDIR)/lists.o

pvrsrvkm-y += $(BRIDGEDIR)/bridged_support.o \
	$(BRIDGEDIR)/bridged_pvr_bridge.o \
	$(BRIDGEDIR)/sgx/bridged_sgx_bridge.o

pvrsrvkm-y += $(SGXDIR)/sgxinit.o \
	$(SGXDIR)/sgxpower.o \
	$(SGXDIR)/sgxreset.o \
	$(SGXDIR)/sgxutils.o \
	$(SGXDIR)/sgxkick.o \
	$(SGXDIR)/sgxtransfer.o \
	$(SGXDIR)/mmu.o \
	$(SGXDIR)/pb.o

pvrsrvkm-y += $(SYSCONFIGDIR)/sysconfig.o \
	$(SYSCONFIGDIR)/sysutils.o

obj-$(CONFIG_CE_SGX_GFX) += pvrsrvkm.o