LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
From: "Vijay Sampath" <vsampath@gmail.com>
To: joern@wohnheim.fh-wedel.de, linux-mtd@lists.infradead.org
Cc: linux-kernel@vger.kernel.org
Subject: [PATCH] [MTD] CHIPS: oops in cfi_amdstd_sync
Date: Tue, 20 Feb 2007 17:46:13 -0800 [thread overview]
Message-ID: <758a2bbf0702201746p3959235ele3db9b600a9f8104@mail.gmail.com> (raw)
From: Vijay Sampath <vsampath@gmail.com>
The files cfi_cmdset_0002.c and cfi_cmdset_0020.c do not initialize
their wait queues like is done in cfi_cmdset_0001.c. This causes an
oops when the wait queue is accessed. I have copied the code from
cfi_cmdset_0001.c that is pertinent to initialization of the wait
queue.
Signed-off-by: Vijay Sampath <vsampath@gmail.com>
---
diff -uprN -X linux-2.6.20.1-vanilla/Documentation/dontdiff
linux-2.6.20.1-vanilla/drivers/mtd/chips/cfi_cmdset_0002.c
linux-2.6/drivers/mtd/chips/cfi_cmdset_0002.c
--- linux-2.6.20.1-vanilla/drivers/mtd/chips/cfi_cmdset_0002.c 2007-02-20
17:01:57.000000000 -0800
+++ linux-2.6/drivers/mtd/chips/cfi_cmdset_0002.c 2007-02-20
17:05:23.000000000 -0800
@@ -359,6 +359,8 @@ struct mtd_info *cfi_cmdset_0002(struct
cfi->chips[i].word_write_time = 1<<cfi->cfiq->WordWriteTimeoutTyp;
cfi->chips[i].buffer_write_time = 1<<cfi->cfiq->BufWriteTimeoutTyp;
cfi->chips[i].erase_time = 1<<cfi->cfiq->BlockEraseTimeoutTyp;
+ cfi->chips[i].ref_point_counter = 0;
+ init_waitqueue_head(&(cfi->chips[i].wq));
}
map->fldrv = &cfi_amdstd_chipdrv;
diff -uprN -X linux-2.6.20.1-vanilla/Documentation/dontdiff
linux-2.6.20.1-vanilla/drivers/mtd/chips/cfi_cmdset_0020.c
linux-2.6/drivers/mtd/chips/cfi_cmdset_0020.c
--- linux-2.6.20.1-vanilla/drivers/mtd/chips/cfi_cmdset_0020.c 2007-02-20
17:01:57.000000000 -0800
+++ linux-2.6/drivers/mtd/chips/cfi_cmdset_0020.c 2007-02-20
17:06:14.000000000 -0800
@@ -158,6 +158,8 @@ struct mtd_info *cfi_cmdset_0020(struct
cfi->chips[i].word_write_time = 128;
cfi->chips[i].buffer_write_time = 128;
cfi->chips[i].erase_time = 1024;
+ cfi->chips[i].ref_point_counter = 0;
+ init_waitqueue_head(&(cfi->chips[i].wq));
}
return cfi_staa_setup(map);
next reply other threads:[~2007-02-21 1:46 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-02-21 1:46 Vijay Sampath [this message]
2007-02-21 14:54 ` Jörn Engel
2007-02-21 15:18 ` Josh Boyer
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=758a2bbf0702201746p3959235ele3db9b600a9f8104@mail.gmail.com \
--to=vsampath@gmail.com \
--cc=joern@wohnheim.fh-wedel.de \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mtd@lists.infradead.org \
--subject='Re: [PATCH] [MTD] CHIPS: oops in cfi_amdstd_sync' \
/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
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).