From: David Vrabel <dvrabel@arcom.com>
To: linux-mtd list <linux-mtd@lists.infradead.org>
Subject: [patch] Only probe for device combinations that fit in map's bankwidth.
Date: Thu, 16 Sep 2004 11:49:09 +0100 [thread overview]
Message-ID: <41496FA5.5010901@arcom.com> (raw)
Hi,
Recent MTD changed how chip probing is done and it now probes for chips
of all bus widths. On my board (IXP425 with 16-bit AMD AM29LV128 flash)
probing for 8-bit wide devices cannot work because 8-bit writes/reads to
16-bit devices aren't allowed (they cause data aborts). So...
Make genprobe_new_chip() only probe for combinations that fit in the
map's bankwidth.
Index: linux-2.6-armbe/drivers/mtd/chips/gen_probe.c
===================================================================
--- linux-2.6-armbe.orig/drivers/mtd/chips/gen_probe.c 2004-09-15
17:06:44.000000000 +0100
+++ linux-2.6-armbe/drivers/mtd/chips/gen_probe.c 2004-09-16
11:37:15.000000000 +0100
@@ -172,8 +172,9 @@
for (type = 0; type < 3; type++) {
cfi->device_type = 1<<type;
- if (cp->probe_chip(map, 0, NULL, cfi))
- return 1;
+ if (cfi->device_type * cfi->interleave == map_bankwidth(map))
+ if (cp->probe_chip(map, 0, NULL, cfi))
+ return 1;
}
}
return 0;
David Vrabel
--
David Vrabel, Design Engineer
Arcom, Clifton Road Tel: +44 (0)1223 411200 ext. 3233
Cambridge CB1 7EA, UK Web: http://www.arcom.com/
next reply other threads:[~2004-09-16 10:51 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-09-16 10:49 David Vrabel [this message]
2004-09-16 11:50 ` [patch] Only probe for device combinations that fit in map's bankwidth 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=41496FA5.5010901@arcom.com \
--to=dvrabel@arcom.com \
--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