Commit 9a457a52 authored by Linus Torvalds's avatar Linus Torvalds

Merge branch 'urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6

* 'urgent' of git://git.kernel.org/pub/scm/linux/kernel/git/brodo/pcmcia-2.6:
  pcmcia: pd6729: Fix error path
  pcmcia: preserve configuration information if request_io fails partly
parents bc5fbd9c 40d24ff9
...@@ -595,7 +595,13 @@ int pcmcia_request_io(struct pcmcia_device *p_dev) ...@@ -595,7 +595,13 @@ int pcmcia_request_io(struct pcmcia_device *p_dev)
if (c->io[1].end) { if (c->io[1].end) {
ret = alloc_io_space(s, &c->io[1], p_dev->io_lines); ret = alloc_io_space(s, &c->io[1], p_dev->io_lines);
if (ret) { if (ret) {
struct resource tmp = c->io[0];
/* release the previously allocated resource */
release_io_space(s, &c->io[0]); release_io_space(s, &c->io[0]);
/* but preserve the settings, for they worked... */
c->io[0].end = resource_size(&tmp);
c->io[0].start = tmp.start;
c->io[0].flags = tmp.flags;
goto out; goto out;
} }
} else } else
......
...@@ -646,7 +646,7 @@ static int __devinit pd6729_pci_probe(struct pci_dev *dev, ...@@ -646,7 +646,7 @@ static int __devinit pd6729_pci_probe(struct pci_dev *dev,
if (!pci_resource_start(dev, 0)) { if (!pci_resource_start(dev, 0)) {
dev_warn(&dev->dev, "refusing to load the driver as the " dev_warn(&dev->dev, "refusing to load the driver as the "
"io_base is NULL.\n"); "io_base is NULL.\n");
goto err_out_free_mem; goto err_out_disable;
} }
dev_info(&dev->dev, "Cirrus PD6729 PCI to PCMCIA Bridge at 0x%llx " dev_info(&dev->dev, "Cirrus PD6729 PCI to PCMCIA Bridge at 0x%llx "
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment