Bug 228693 - Bad: cfi_cmdset_0001 sets incorrect write/erase wait timeout if jedec_probe was used to detect a flash [NEEDINFO]
Bad: cfi_cmdset_0001 sets incorrect write/erase wait timeout if jedec_probe w...
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: kernel (Show other bugs)
x86_64 Linux
medium Severity medium
: ---
: ---
Assigned To: Ric Wheeler
Brian Brock
Depends On:
  Show dependency treegraph
Reported: 2007-02-14 10:20 EST by Ekaterina Nosova
Modified: 2014-06-02 09:18 EDT (History)
1 user (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed: 2014-06-02 09:18:19 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---
pm-rhel: needinfo? (ekaterina.nosova)

Attachments (Terms of Use)

  None (edit)
Description Ekaterina Nosova 2007-02-14 10:20:42 EST
From Bugzilla Helper:
User-Agent: Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322; InfoPath.1; .NET CLR 2.0.50727)

Description of problem:
If a map driver uses jedec_probe to detect a flash (e.g. ST M50FW080), then erase and write operations on this flash breaks by timeout.
The following patch helps to fix the problem:

diff --git a/drivers/mtd/chips/cfi_cmdset_0001.c b/drivers/mtd/chips/cfi_cmdset_0001.c
index f69184a..fed9d5b 100644
--- a/drivers/mtd/chips/cfi_cmdset_0001.c
+++ b/drivers/mtd/chips/cfi_cmdset_0001.c
@@ -402,6 +402,12 @@ struct mtd_info *cfi_cmdset_0001(struct map_info *map, int primary)
                cfi->chips[i].erase_time = 1000<<cfi->cfiq-BlockEraseTimeoutTyp;
                cfi->chips[i].ref_point_counter = 0;
+               /* If no times specified, put some reasonable defaults in */
+               if (!cfi->chips[i].WordWriteTimeoutTyp)
+                       cfi->chips[i].word_write_time = 100;
+               if (!cfi->chips[i].BlockEraseTimeoutTyp)
+                       cfi->chips[i].erase_time = 2000000;

        map->fldrv = &cfi_intelext_chipdrv;

Version-Release number of selected component (if applicable):
kernel 2.6.18-1.2747.el5

How reproducible:

Steps to Reproduce:
1. Load Motorola atca7221 map driver
2. Try to erase flash on /dev/mtd0 or /dev/mtd1
3. See 'Timeout expired' messages
(Contact David Woodhouse dwmw2@redhat.com for more details)

Actual Results:

Expected Results:

Additional info:
Comment 4 RHEL Product and Program Management 2014-03-07 08:43:59 EST
This bug/component is not included in scope for RHEL-5.11.0 which is the last RHEL5 minor release. This Bugzilla will soon be CLOSED as WONTFIX (at the end of RHEL5.11 development phase (Apr 22, 2014)). Please contact your account manager or support representative in case you need to escalate this bug.
Comment 5 RHEL Product and Program Management 2014-06-02 09:18:19 EDT
Thank you for submitting this request for inclusion in Red Hat Enterprise Linux 5. We've carefully evaluated the request, but are unable to include it in RHEL5 stream. If the issue is critical for your business, please provide additional business justification through the appropriate support channels (https://access.redhat.com/site/support).

Note You need to log in before you can comment on or make changes to this bug.