]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blobdiff - drivers/mtd/devices/mtd_dataflash.c
[MTD] mtd_dataflash: Incorrect compare-after-write check
[linux-2.6-omap-h63xx.git] / drivers / mtd / devices / mtd_dataflash.c
index a5ed6d232c357b16b7ffacfedd10d81a9915dad8..b35e4813a3a5e146f6725fb13d6d3be0f588bfe6 100644 (file)
@@ -420,7 +420,7 @@ static int dataflash_write(struct mtd_info *mtd, loff_t to, size_t len,
                status = dataflash_waitready(priv->spi);
 
                /* Check result of the compare operation */
-               if ((status & (1 << 6)) == 1) {
+               if (status & (1 << 6)) {
                        printk(KERN_ERR "%s: compare page %u, err %d\n",
                                spi->dev.bus_id, pageaddr, status);
                        remaining = 0;