Merge with Linux 2.3.40.
[linux-2.6/linux-mips.git] / drivers / Makefile
blob71ee973cfc7a95a663aa559545012410ecab91a4
2 # Makefile for the Linux kernel device drivers.
4 # Note! Dependencies are done automagically by 'make dep', which also
5 # removes any old dependencies. DON'T put your own dependencies here
6 # unless it's something special (not a .c file).
8 # Note 2! The CFLAGS definitions are now in the main makefile.
10 SUB_DIRS := block char net parport sound misc
11 MOD_SUB_DIRS := $(SUB_DIRS)
12 ALL_SUB_DIRS := $(SUB_DIRS) pci sgi scsi sbus cdrom isdn pnp i2o ieee1394 \
13 macintosh video dio zorro fc4 usb \
14 nubus tc ap1000 atm pcmcia i2c telephony
16 ifdef CONFIG_DIO
17 SUB_DIRS += dio
18 MOD_SUB_DIRS += dio
19 endif
21 ifdef CONFIG_PCI
22 SUB_DIRS += pci
23 endif
25 ifeq ($(CONFIG_PCMCIA),y)
26 SUB_DIRS += pcmcia
27 else
28 ifeq ($(CONFIG_PCMCIA),m)
29 MOD_SUB_DIRS += pcmcia
30 endif
31 endif
33 ifdef CONFIG_SBUS
34 SUB_DIRS += sbus
35 MOD_SUB_DIRS += sbus
36 endif
38 ifdef CONFIG_ZORRO
39 SUB_DIRS += zorro
40 endif
42 ifdef CONFIG_NUBUS
43 SUB_DIRS += nubus
44 endif
46 ifdef CONFIG_TC
47 SUB_DIRS += tc
48 endif
50 ifdef CONFIG_VT
51 SUB_DIRS += video
52 MOD_SUB_DIRS += video
53 endif
55 ifdef CONFIG_PPC
56 SUB_DIRS += macintosh
57 MOD_SUB_DIRS += macintosh
58 endif
60 ifeq ($(CONFIG_USB),y)
61 SUB_DIRS += usb
62 MOD_SUB_DIRS += usb
63 else
64 ifeq ($(CONFIG_USB),m)
65 MOD_SUB_DIRS += usb
66 endif
67 endif
69 ifeq ($(CONFIG_PHONE),y)
70 SUB_DIRS += telephony
71 MOD_SUB_DIRS += telephony
72 else
73 ifeq ($(CONFIG_PHONE),m)
74 MOD_SUB_DIRS += telephony
75 endif
76 endif
78 ifdef CONFIG_SGI_IP22
79 SUB_DIRS += sgi
80 MOD_SUB_DIRS += sgi
81 endif
83 ifeq ($(CONFIG_I2O),y)
84 SUB_DIRS += i2o
85 MOD_SUB_DIRS += i2o
86 else
87 ifeq ($(CONFIG_I2O),m)
88 MOD_SUB_DIRS += i2o
89 endif
90 endif
92 # If CONFIG_SCSI is set, the core of SCSI support will be added to the kernel,
93 # but some of the low-level things may also be modules.
94 ifeq ($(CONFIG_SCSI),y)
95 SUB_DIRS += scsi
96 MOD_SUB_DIRS += scsi
97 else
98 ifeq ($(CONFIG_SCSI),m)
99 MOD_SUB_DIRS += scsi
100 endif
101 endif
103 ifeq ($(CONFIG_IEEE1394),y)
104 SUB_DIRS += ieee1394
105 MOD_SUB_DIRS += ieee1394
106 else
107 ifeq ($(CONFIG_IEEE1394),m)
108 MOD_SUB_DIRS += ieee1394
109 endif
110 endif
112 ifeq ($(CONFIG_PNP),y)
113 SUB_DIRS += pnp
114 MOD_SUB_DIRS += pnp
115 else
116 ifeq ($(CONFIG_PNP),m)
117 MOD_SUB_DIRS += pnp
118 endif
119 endif
121 ifneq ($(CONFIG_CD_NO_IDESCSI)$(CONFIG_BLK_DEV_IDECD)$(CONFIG_BLK_DEV_SR)$(CONFIG_PARIDE_PCD),)
122 SUB_DIRS += cdrom
123 MOD_SUB_DIRS += cdrom
124 endif
126 ifeq ($(CONFIG_ISDN),y)
127 SUB_DIRS += isdn
128 MOD_SUB_DIRS += isdn
129 else
130 ifeq ($(CONFIG_ISDN),m)
131 MOD_SUB_DIRS += isdn
132 endif
133 endif
135 ifdef CONFIG_ATM
136 SUB_DIRS += atm
137 MOD_SUB_DIRS += atm
138 endif
140 ifeq ($(CONFIG_AP1000),y)
141 SUB_DIRS += ap1000
142 endif
144 ifeq ($(CONFIG_FC4),y)
145 SUB_DIRS += fc4
146 MOD_SUB_DIRS += fc4
147 else
148 ifeq ($(CONFIG_FC4),m)
149 MOD_SUB_DIRS += fc4
150 endif
151 endif
153 # When MOD_LIST_NAME is set, make will try to add $(MOD_SUB_DIRS).o to
154 # modules/MOD_LIST_NAME. We don't have hamradio.o and Linus
155 # sort of insisted on making hamradio/ a subdirectory of drivers/net/.
157 ifeq ($(CONFIG_HAMRADIO),y)
158 SUB_DIRS += net/hamradio
159 MOD_SUB_DIRS += net/hamradio
160 endif
162 ifeq ($(CONFIG_I2C),y)
163 SUB_DIRS += i2c
164 MOD_SUB_DIRS += i2c
165 else
166 ifeq ($(CONFIG_I2C),m)
167 MOD_SUB_DIRS += i2c
168 endif
169 endif
171 include $(TOPDIR)/Rules.make