mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] firewire: fw-ohci: missing PPC PMac feature calls in failure path
@ 2008-03-24 19:55 Stefan Richter
  0 siblings, 0 replies; only message in thread
From: Stefan Richter @ 2008-03-24 19:55 UTC (permalink / raw)
  To: linux1394-devel; +Cc: linux-kernel

Balance ohci_pmac_on and ohci_pmac_off if pci_driver.probe fails.

Signed-off-by: Stefan Richter <stefanr@s5r6.in-berlin.de>
---
 drivers/firewire/fw-ohci.c |    5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

Index: linux/drivers/firewire/fw-ohci.c
===================================================================
--- linux.orig/drivers/firewire/fw-ohci.c
+++ linux/drivers/firewire/fw-ohci.c
@@ -2285,8 +2285,6 @@ pci_probe(struct pci_dev *dev, const str
 	int err;
 	size_t size;
 
-	ohci_pmac_on(dev);
-
 	ohci = kzalloc(sizeof(*ohci), GFP_KERNEL);
 	if (ohci == NULL) {
 		fw_error("Could not malloc fw_ohci data.\n");
@@ -2295,6 +2293,8 @@ pci_probe(struct pci_dev *dev, const str
 
 	fw_card_initialize(&ohci->card, &ohci_driver, &dev->dev);
 
+	ohci_pmac_on(dev);
+
 	err = pci_enable_device(dev);
 	if (err) {
 		fw_error("Failed to enable OHCI hardware.\n");
@@ -2396,6 +2396,7 @@ pci_probe(struct pci_dev *dev, const str
 	pci_disable_device(dev);
  fail_free:
 	kfree(&ohci->card);
+	ohci_pmac_off(dev);
 
 	return err;
 }

-- 
Stefan Richter
-=====-==--- --== ==---
http://arcgraph.de/sr/


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2008-03-24 19:57 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-03-24 19:55 [PATCH] firewire: fw-ohci: missing PPC PMac feature calls in failure path Stefan Richter

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®