public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Arnd Bergmann <arnd@arndb.de>
To: paulus@samba.org
Cc: linux-kernel@vger.kernel.org, linuxppc-dev@ozlabs.org,
	cbe-oss-dev@ozlabs.org, Maximilian <maxim@de.ibm.com>,
	Arnd Bergmann <arnd.bergmann@de.ibm.com>
Subject: [patch 4/5] axonram: do not delete gendisks queue in error path
Date: Wed, 22 Aug 2007 19:01:28 +0200	[thread overview]
Message-ID: <20070822170732.517188445@arndb.de> (raw)
In-Reply-To: 20070822170124.764128591@arndb.de

[-- Attachment #1: 37801.diff --]
[-- Type: text/plain, Size: 1114 bytes --]

From: Maxim Shchetynin <maxim@de.ibm.com>
On exit do not delete gendisk's queue because this is already done by
del_gendisk(). Doing it twice may cause memory damage.

Signed-off-by: Maximilian <maxim@de.ibm.com>
Signed-off-by: Arnd Bergmann <arnd.bergmann@de.ibm.com>
---

Index: linux-2.6/arch/powerpc/sysdev/axonram.c
===================================================================
--- linux-2.6.orig/arch/powerpc/sysdev/axonram.c
+++ linux-2.6/arch/powerpc/sysdev/axonram.c
@@ -281,8 +281,6 @@ failed:
 		if (bank->irq_id != NO_IRQ)
 			free_irq(bank->irq_id, device);
 		if (bank->disk != NULL) {
-			if (bank->disk->queue != NULL)
-				blk_cleanup_queue(bank->disk->queue);
 			if (bank->disk->major > 0)
 				unregister_blkdev(bank->disk->major,
 						bank->disk->disk_name);
@@ -310,7 +308,6 @@ axon_ram_remove(struct of_device *device
 
 	device_remove_file(&device->dev, &dev_attr_ecc);
 	free_irq(bank->irq_id, device);
-	blk_cleanup_queue(bank->disk->queue);
 	unregister_blkdev(bank->disk->major, bank->disk->disk_name);
 	del_gendisk(bank->disk);
 	iounmap((void __iomem *) bank->io_addr);

--


  parent reply	other threads:[~2007-08-22 17:21 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-08-22 17:01 [patch 0/5] (hopefully) final 2.6.23 fixes for cell platform Arnd Bergmann
2007-08-22 17:01 ` [patch 1/5] spu_manage: use newer physical-id attribute Arnd Bergmann
2007-08-22 17:01 ` [patch 2/5] cell: support pinhole-reset on IBM cell blades Arnd Bergmann
2007-08-22 17:01 ` [patch 3/5] Axonram module modification for latest firmware API changes Arnd Bergmann
2007-08-22 17:01 ` Arnd Bergmann [this message]
2007-08-22 17:09 ` [patch 5/5] update cell_defconfig for 2.6.23 Arnd Bergmann
2007-08-22 17:15 ` git tree, Re: [patch 0/5] (hopefully) final 2.6.23 fixes for cell platform Arnd Bergmann

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=20070822170732.517188445@arndb.de \
    --to=arnd@arndb.de \
    --cc=arnd.bergmann@de.ibm.com \
    --cc=cbe-oss-dev@ozlabs.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@ozlabs.org \
    --cc=maxim@de.ibm.com \
    --cc=paulus@samba.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox