aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/pcmcia/aha152x_stub.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi/pcmcia/aha152x_stub.c')
-rw-r--r--drivers/scsi/pcmcia/aha152x_stub.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/drivers/scsi/pcmcia/aha152x_stub.c b/drivers/scsi/pcmcia/aha152x_stub.c
index 7caa700cf189..ee449b29fc82 100644
--- a/drivers/scsi/pcmcia/aha152x_stub.c
+++ b/drivers/scsi/pcmcia/aha152x_stub.c
@@ -122,7 +122,6 @@ static int aha152x_probe(struct pcmcia_device *link)
122 link->conf.IntType = INT_MEMORY_AND_IO; 122 link->conf.IntType = INT_MEMORY_AND_IO;
123 link->conf.Present = PRESENT_OPTION; 123 link->conf.Present = PRESENT_OPTION;
124 124
125 link->state |= DEV_PRESENT | DEV_CONFIG_PENDING;
126 return aha152x_config_cs(link); 125 return aha152x_config_cs(link);
127} /* aha152x_attach */ 126} /* aha152x_attach */
128 127
@@ -132,8 +131,7 @@ static void aha152x_detach(struct pcmcia_device *link)
132{ 131{
133 DEBUG(0, "aha152x_detach(0x%p)\n", link); 132 DEBUG(0, "aha152x_detach(0x%p)\n", link);
134 133
135 if (link->state & DEV_CONFIG) 134 aha152x_release_cs(link);
136 aha152x_release_cs(link);
137 135
138 /* Unlink device structure, free bits */ 136 /* Unlink device structure, free bits */
139 kfree(link->priv); 137 kfree(link->priv);
@@ -165,9 +163,6 @@ static int aha152x_config_cs(struct pcmcia_device *link)
165 CS_CHECK(ParseTuple, pcmcia_parse_tuple(link, &tuple, &parse)); 163 CS_CHECK(ParseTuple, pcmcia_parse_tuple(link, &tuple, &parse));
166 link->conf.ConfigBase = parse.config.base; 164 link->conf.ConfigBase = parse.config.base;
167 165
168 /* Configure card */
169 link->state |= DEV_CONFIG;
170
171 tuple.DesiredTuple = CISTPL_CFTABLE_ENTRY; 166 tuple.DesiredTuple = CISTPL_CFTABLE_ENTRY;
172 CS_CHECK(GetFirstTuple, pcmcia_get_first_tuple(link, &tuple)); 167 CS_CHECK(GetFirstTuple, pcmcia_get_first_tuple(link, &tuple));
173 while (1) { 168 while (1) {
@@ -216,7 +211,6 @@ static int aha152x_config_cs(struct pcmcia_device *link)
216 link->dev_node = &info->node; 211 link->dev_node = &info->node;
217 info->host = host; 212 info->host = host;
218 213
219 link->state &= ~DEV_CONFIG_PENDING;
220 return 0; 214 return 0;
221 215
222cs_failed: 216cs_failed: