From: Sergei Shtylyov <sshtylyov@ru.mvista.com>
To: bzolnier@gmail.com
Cc: linux-ide@vger.kernel.org, jeremy@sgi.com
Subject: [PATCH 1/2] sgiioc4: fix error cleanup path (take 2)
Date: Mon, 20 Oct 2008 17:23:06 +0400 [thread overview]
Message-ID: <200810201723.06653.sshtylyov@ru.mvista.com> (raw)
The driver "forgot" to call iounmap() iff request_mem_region() call failed in
sgiioc4_ide_setup_pci_device()...
Signed-off-by: Sergei Shtylyov <sshtylyov@ru.mvista.com>
---
This patch is against the recent Linus' tree.
drivers/ide/pci/sgiioc4.c | 4 +++-
1 files changed, 3 insertions(+), 1 deletion(-)
Index: linux-2.6/drivers/ide/pci/sgiioc4.c
===================================================================
--- linux-2.6.orig/drivers/ide/pci/sgiioc4.c
+++ linux-2.6/drivers/ide/pci/sgiioc4.c
@@ -617,7 +617,8 @@ sgiioc4_ide_setup_pci_device(struct pci_
printk(KERN_ERR "%s %s -- ERROR: addresses 0x%08lx to 0x%08lx "
"already in use\n", DRV_NAME, pci_name(dev),
cmd_phys_base, cmd_phys_base + IOC4_CMD_CTL_BLK_SIZE);
- return -EBUSY;
+ rc = -EBUSY;
+ goto req_mem_rgn_err;
}
/* Initialize the IO registers */
@@ -645,6 +646,7 @@ err_free:
ide_host_free(host);
err:
release_mem_region(cmd_phys_base, IOC4_CMD_CTL_BLK_SIZE);
+req_mem_rgn_err:
iounmap(virt_base);
return rc;
}
next reply other threads:[~2008-10-20 13:23 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-10-20 13:23 Sergei Shtylyov [this message]
2008-10-23 19:28 ` [PATCH 1/2] sgiioc4: fix error cleanup path (take 2) Bartlomiej Zolnierkiewicz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200810201723.06653.sshtylyov@ru.mvista.com \
--to=sshtylyov@ru.mvista.com \
--cc=bzolnier@gmail.com \
--cc=jeremy@sgi.com \
--cc=linux-ide@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.