diff mbox

gen_probe.c: Probe chips in decreasing device size (most significant first)

Message ID 1221390552.25179.14.camel@Mikeul
State Changes Requested
Headers show

Commit Message

Michel Stempin Sept. 14, 2008, 11:09 a.m. UTC
Probe chips in decreasing device size to detect most significant chip
IDs first in case there are two chips with the same LSB.

This case has been found between SST39VF3201 (Mfr: 0x0020, Id: 0x235B)
and SST49LF080A (Mfr: 0x0020, Id: 0x005B) chips.

Signed-off-by: Michel Stempin <michel.stempin@wanadoo.fr>

Comments

Josh Boyer Oct. 8, 2008, 12:46 p.m. UTC | #1
On Sun, Sep 14, 2008 at 01:09:12PM +0200, Michel Stempin wrote:
>Probe chips in decreasing device size to detect most significant chip
>IDs first in case there are two chips with the same LSB.
>
>This case has been found between SST39VF3201 (Mfr: 0x0020, Id: 0x235B)
>and SST49LF080A (Mfr: 0x0020, Id: 0x005B) chips.
>
>Signed-off-by: Michel Stempin <michel.stempin@wanadoo.fr>

Your patch is word-wrapped.

josh
diff mbox

Patch

diff --git a/drivers/mtd/chips/gen_probe.c
b/drivers/mtd/chips/gen_probe.c
index f061885..d1875f8 100644
--- a/drivers/mtd/chips/gen_probe.c
+++ b/drivers/mtd/chips/gen_probe.c
@@ -170,7 +170,7 @@  static int genprobe_new_chip(struct map_info *map,
struct chip_probe *cp,
 {
        int min_chips = (map_bankwidth(map)/4?:1); /* At most 4-bytes
wide. */
        int max_chips = map_bankwidth(map); /* And minimum 1 */
-       int nr_chips, type;
+       int nr_chips, min_type, type;