mtd: cfi_cmdset_0001: use defined value of P_ID_INTEL_PERFORMANCE instead of hardcode...
authorGuillaume LECERF <glecerf@gmail.com>
Tue, 26 Oct 2010 09:55:29 +0000 (10:55 +0100)
committerDavid Woodhouse <David.Woodhouse@intel.com>
Tue, 26 Oct 2010 10:00:18 +0000 (11:00 +0100)
Signed-off-by: Guillaume LECERF <glecerf@gmail.com>
Signed-off-by: David Woodhouse <David.Woodhouse@intel.com>
drivers/mtd/chips/cfi_cmdset_0001.c

index 9e2b7e9e0ad91b4871423cf2f449c1b63329cb10..ad9268b444163e2df218b3ff5b3bee8bdfdca0a6 100644 (file)
@@ -1496,7 +1496,7 @@ static int __xipram do_write_oneword(struct map_info *map, struct flchip *chip,
 
        switch (mode) {
        case FL_WRITING:
-               write_cmd = (cfi->cfiq->P_ID != 0x0200) ? CMD(0x40) : CMD(0x41);
+               write_cmd = (cfi->cfiq->P_ID != P_ID_INTEL_PERFORMANCE) ? CMD(0x40) : CMD(0x41);
                break;
        case FL_OTP_WRITE:
                write_cmd = CMD(0xc0);
@@ -1661,7 +1661,7 @@ static int __xipram do_write_buffer(struct map_info *map, struct flchip *chip,
        cmd_adr = adr & ~(wbufsize-1);
 
        /* Let's determine this according to the interleave only once */
-       write_cmd = (cfi->cfiq->P_ID != 0x0200) ? CMD(0xe8) : CMD(0xe9);
+       write_cmd = (cfi->cfiq->P_ID != P_ID_INTEL_PERFORMANCE) ? CMD(0xe8) : CMD(0xe9);
 
        mutex_lock(&chip->mutex);
        ret = get_chip(map, chip, cmd_adr, FL_WRITING);