From: Pantelis Antoniou <panto@intracom.gr>
To: linux-mtd@lists.infradead.org
Subject: [PATCH] Trivial fix for Oops on unmount.
Date: Thu, 12 Jun 2003 17:21:56 +0300 [thread overview]
Message-ID: <3EE88C84.6020803@intracom.gr> (raw)
[-- Attachment #1: Type: text/plain, Size: 134 bytes --]
Hi
This is a trivial patch which fixes some oopses for me in 2.4.21-rc7 with
MTD compiled in instead of modules.
Regards
Pantelis
[-- Attachment #2: oops.patch --]
[-- Type: text/plain, Size: 554 bytes --]
--- drivers/mtd/mtd_blkdevs-24.c Thu Jun 12 15:44:47 2003
+++ drivers-nand/mtd/mtd_blkdevs-24.c Thu Jun 12 17:21:15 2003
@@ -239,8 +239,10 @@
tr->usecount--;
dev->usecount--;
dev->mtd->usecount--;
+ if (dev->mtd->owner)
__MOD_DEC_USE_COUNT(dev->mtd->owner);
out_tr:
+ if (tr->owner)
__MOD_DEC_USE_COUNT(tr->owner);
}
out:
@@ -279,7 +281,9 @@
tr->usecount--;
dev->usecount--;
dev->mtd->usecount--;
+ if (dev->mtd->owner)
__MOD_DEC_USE_COUNT(dev->mtd->owner);
+ if (tr->owner)
__MOD_DEC_USE_COUNT(tr->owner);
}
next reply other threads:[~2003-06-12 14:22 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-06-12 14:21 Pantelis Antoniou [this message]
2003-06-12 14:43 ` [PATCH] Trivial fix for Oops on unmount David Woodhouse
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=3EE88C84.6020803@intracom.gr \
--to=panto@intracom.gr \
--cc=linux-mtd@lists.infradead.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