aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/isdn/hisax
diff options
context:
space:
mode:
authorDominik Brodowski <linux@dominikbrodowski.net>2010-07-29 13:27:09 -0400
committerDominik Brodowski <linux@dominikbrodowski.net>2010-09-29 11:20:23 -0400
commit1ac71e5a35eebee60cdcf15b3980bd94498f037b (patch)
tree22fa9342ccccce6a774af029ce51a526e55f8180 /drivers/isdn/hisax
parent7feabb6412ea23edd298c0fa90e5aa6733eb4a42 (diff)
pcmcia: convert pcmcia_request_configuration to pcmcia_enable_device
pcmcia_enable_device() now replaces pcmcia_request_configuration(). Instead of config_req_t, all necessary flags are either passed as a parameter to pcmcia_enable_device(), or (in rare circumstances) set in struct pcmcia_device -> flags. With the last remaining user of include/pcmcia/cs.h gone, remove all references. CC: netdev@vger.kernel.org CC: linux-wireless@vger.kernel.org CC: linux-ide@vger.kernel.org CC: linux-usb@vger.kernel.org CC: laforge@gnumonks.org CC: linux-mtd@lists.infradead.org CC: alsa-devel@alsa-project.org CC: linux-serial@vger.kernel.org CC: Jiri Kosina <jkosina@suse.cz> CC: linux-scsi@vger.kernel.org Acked-by: Gustavo F. Padovan <padovan@profusion.mobi> (for drivers/bluetooth) Tested-by: Wolfram Sang <w.sang@pengutronix.de> Signed-off-by: Dominik Brodowski <linux@dominikbrodowski.net>
Diffstat (limited to 'drivers/isdn/hisax')
-rw-r--r--drivers/isdn/hisax/avma1_cs.c5
-rw-r--r--drivers/isdn/hisax/elsa_cs.c8
-rw-r--r--drivers/isdn/hisax/sedlbauer_cs.c12
-rw-r--r--drivers/isdn/hisax/teles_cs.c8
4 files changed, 11 insertions, 22 deletions
diff --git a/drivers/isdn/hisax/avma1_cs.c b/drivers/isdn/hisax/avma1_cs.c
index e25f6c7376ed..5dd47ad6ecc9 100644
--- a/drivers/isdn/hisax/avma1_cs.c
+++ b/drivers/isdn/hisax/avma1_cs.c
@@ -20,7 +20,6 @@
20#include <asm/io.h> 20#include <asm/io.h>
21#include <asm/system.h> 21#include <asm/system.h>
22 22
23#include <pcmcia/cs.h>
24#include <pcmcia/cistpl.h> 23#include <pcmcia/cistpl.h>
25#include <pcmcia/ds.h> 24#include <pcmcia/ds.h>
26#include "hisax_cfg.h" 25#include "hisax_cfg.h"
@@ -84,7 +83,7 @@ static int __devinit avma1cs_probe(struct pcmcia_device *p_dev)
84 p_dev->resource[1]->flags |= IO_DATA_PATH_WIDTH_16; 83 p_dev->resource[1]->flags |= IO_DATA_PATH_WIDTH_16;
85 84
86 /* General socket configuration */ 85 /* General socket configuration */
87 p_dev->conf.Attributes = CONF_ENABLE_IRQ; 86 p_dev->config_flags |= CONF_ENABLE_IRQ;
88 p_dev->config_index = 1; 87 p_dev->config_index = 1;
89 p_dev->config_regs = PRESENT_OPTION; 88 p_dev->config_regs = PRESENT_OPTION;
90 89
@@ -160,7 +159,7 @@ static int __devinit avma1cs_config(struct pcmcia_device *link)
160 /* 159 /*
161 * configure the PCMCIA socket 160 * configure the PCMCIA socket
162 */ 161 */
163 i = pcmcia_request_configuration(link, &link->conf); 162 i = pcmcia_enable_device(link);
164 if (i != 0) { 163 if (i != 0) {
165 pcmcia_disable_device(link); 164 pcmcia_disable_device(link);
166 break; 165 break;
diff --git a/drivers/isdn/hisax/elsa_cs.c b/drivers/isdn/hisax/elsa_cs.c
index f276e8428960..368c8a213f0b 100644
--- a/drivers/isdn/hisax/elsa_cs.c
+++ b/drivers/isdn/hisax/elsa_cs.c
@@ -46,7 +46,6 @@
46#include <asm/io.h> 46#include <asm/io.h>
47#include <asm/system.h> 47#include <asm/system.h>
48 48
49#include <pcmcia/cs.h>
50#include <pcmcia/cistpl.h> 49#include <pcmcia/cistpl.h>
51#include <pcmcia/cisreg.h> 50#include <pcmcia/cisreg.h>
52#include <pcmcia/ds.h> 51#include <pcmcia/ds.h>
@@ -129,8 +128,6 @@ static int __devinit elsa_cs_probe(struct pcmcia_device *link)
129 link->resource[0]->end = 8; 128 link->resource[0]->end = 8;
130 link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO; 129 link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
131 130
132 link->conf.Attributes = CONF_ENABLE_IRQ;
133
134 return elsa_cs_config(link); 131 return elsa_cs_config(link);
135} /* elsa_cs_attach */ 132} /* elsa_cs_attach */
136 133
@@ -205,15 +202,14 @@ static int __devinit elsa_cs_config(struct pcmcia_device *link)
205 if (!link->irq) 202 if (!link->irq)
206 goto failed; 203 goto failed;
207 204
208 i = pcmcia_request_configuration(link, &link->conf); 205 i = pcmcia_enable_device(link);
209 if (i != 0) 206 if (i != 0)
210 goto failed; 207 goto failed;
211 208
212 /* Finally, report what we've done */ 209 /* Finally, report what we've done */
213 dev_info(&link->dev, "index 0x%02x: ", 210 dev_info(&link->dev, "index 0x%02x: ",
214 link->config_index); 211 link->config_index);
215 if (link->conf.Attributes & CONF_ENABLE_IRQ) 212 printk(", irq %d", link->irq);
216 printk(", irq %d", link->irq);
217 if (link->resource[0]) 213 if (link->resource[0])
218 printk(" & %pR", link->resource[0]); 214 printk(" & %pR", link->resource[0]);
219 if (link->resource[1]) 215 if (link->resource[1])
diff --git a/drivers/isdn/hisax/sedlbauer_cs.c b/drivers/isdn/hisax/sedlbauer_cs.c
index 43d0a4e97ead..791e23a75f78 100644
--- a/drivers/isdn/hisax/sedlbauer_cs.c
+++ b/drivers/isdn/hisax/sedlbauer_cs.c
@@ -46,7 +46,6 @@
46#include <asm/io.h> 46#include <asm/io.h>
47#include <asm/system.h> 47#include <asm/system.h>
48 48
49#include <pcmcia/cs.h>
50#include <pcmcia/cistpl.h> 49#include <pcmcia/cistpl.h>
51#include <pcmcia/cisreg.h> 50#include <pcmcia/cisreg.h>
52#include <pcmcia/ds.h> 51#include <pcmcia/ds.h>
@@ -132,8 +131,6 @@ static int __devinit sedlbauer_probe(struct pcmcia_device *link)
132 link->resource[0]->end = 8; 131 link->resource[0]->end = 8;
133 link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8; 132 link->resource[0]->flags |= IO_DATA_PATH_WIDTH_8;
134 133
135 link->conf.Attributes = 0;
136
137 return sedlbauer_config(link); 134 return sedlbauer_config(link);
138} /* sedlbauer_attach */ 135} /* sedlbauer_attach */
139 136
@@ -175,7 +172,7 @@ static int sedlbauer_config_check(struct pcmcia_device *p_dev,
175 172
176 /* Does this card need audio output? */ 173 /* Does this card need audio output? */
177 if (cfg->flags & CISTPL_CFTABLE_AUDIO) 174 if (cfg->flags & CISTPL_CFTABLE_AUDIO)
178 p_dev->conf.Attributes |= CONF_ENABLE_SPKR; 175 p_dev->config_flags |= CONF_ENABLE_SPKR;
179 176
180 /* Use power settings for Vcc and Vpp if present */ 177 /* Use power settings for Vcc and Vpp if present */
181 /* Note that the CIS values need to be rescaled */ 178 /* Note that the CIS values need to be rescaled */
@@ -192,7 +189,7 @@ static int sedlbauer_config_check(struct pcmcia_device *p_dev,
192 else if (dflt->vpp1.present & (1<<CISTPL_POWER_VNOM)) 189 else if (dflt->vpp1.present & (1<<CISTPL_POWER_VNOM))
193 p_dev->vpp = dflt->vpp1.param[CISTPL_POWER_VNOM]/10000; 190 p_dev->vpp = dflt->vpp1.param[CISTPL_POWER_VNOM]/10000;
194 191
195 p_dev->conf.Attributes |= CONF_ENABLE_IRQ; 192 p_dev->config_flags |= CONF_ENABLE_IRQ;
196 193
197 /* IO window settings */ 194 /* IO window settings */
198 p_dev->resource[0]->end = p_dev->resource[1]->end = 0; 195 p_dev->resource[0]->end = p_dev->resource[1]->end = 0;
@@ -247,7 +244,7 @@ static int __devinit sedlbauer_config(struct pcmcia_device *link)
247 the I/O windows and the interrupt mapping, and putting the 244 the I/O windows and the interrupt mapping, and putting the
248 card and host interface into "Memory and IO" mode. 245 card and host interface into "Memory and IO" mode.
249 */ 246 */
250 ret = pcmcia_request_configuration(link, &link->conf); 247 ret = pcmcia_enable_device(link);
251 if (ret) 248 if (ret)
252 goto failed; 249 goto failed;
253 250
@@ -256,8 +253,7 @@ static int __devinit sedlbauer_config(struct pcmcia_device *link)
256 link->config_index); 253 link->config_index);
257 if (link->vpp) 254 if (link->vpp)
258 printk(", Vpp %d.%d", link->vpp/10, link->vpp%10); 255 printk(", Vpp %d.%d", link->vpp/10, link->vpp%10);
259 if (link->conf.Attributes & CONF_ENABLE_IRQ) 256 printk(", irq %d", link->irq);
260 printk(", irq %d", link->irq);
261 if (link->resource[0]) 257 if (link->resource[0])
262 printk(" & %pR", link->resource[0]); 258 printk(" & %pR", link->resource[0]);
263 if (link->resource[1]) 259 if (link->resource[1])
diff --git a/drivers/isdn/hisax/teles_cs.c b/drivers/isdn/hisax/teles_cs.c
index 614afc64b5b1..2ae71e3297ba 100644
--- a/drivers/isdn/hisax/teles_cs.c
+++ b/drivers/isdn/hisax/teles_cs.c
@@ -27,7 +27,6 @@
27#include <asm/io.h> 27#include <asm/io.h>
28#include <asm/system.h> 28#include <asm/system.h>
29 29
30#include <pcmcia/cs.h>
31#include <pcmcia/cistpl.h> 30#include <pcmcia/cistpl.h>
32#include <pcmcia/cisreg.h> 31#include <pcmcia/cisreg.h>
33#include <pcmcia/ds.h> 32#include <pcmcia/ds.h>
@@ -109,7 +108,7 @@ static int __devinit teles_probe(struct pcmcia_device *link)
109 link->resource[0]->end = 96; 108 link->resource[0]->end = 96;
110 link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO; 109 link->resource[0]->flags |= IO_DATA_PATH_WIDTH_AUTO;
111 110
112 link->conf.Attributes = CONF_ENABLE_IRQ; 111 link->config_flags |= CONF_ENABLE_IRQ;
113 112
114 return teles_cs_config(link); 113 return teles_cs_config(link);
115} /* teles_attach */ 114} /* teles_attach */
@@ -185,15 +184,14 @@ static int __devinit teles_cs_config(struct pcmcia_device *link)
185 if (!link->irq) 184 if (!link->irq)
186 goto cs_failed; 185 goto cs_failed;
187 186
188 i = pcmcia_request_configuration(link, &link->conf); 187 i = pcmcia_enable_device(link);
189 if (i != 0) 188 if (i != 0)
190 goto cs_failed; 189 goto cs_failed;
191 190
192 /* Finally, report what we've done */ 191 /* Finally, report what we've done */
193 dev_info(&link->dev, "index 0x%02x:", 192 dev_info(&link->dev, "index 0x%02x:",
194 link->config_index); 193 link->config_index);
195 if (link->conf.Attributes & CONF_ENABLE_IRQ) 194 printk(", irq %d", link->irq);
196 printk(", irq %d", link->irq);
197 if (link->resource[0]) 195 if (link->resource[0])
198 printk(" & %pR", link->resource[0]); 196 printk(" & %pR", link->resource[0]);
199 if (link->resource[1]) 197 if (link->resource[1])