Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/spi m25p: change devices recently added from 4kB "se...
details: https://anonhg.NetBSD.org/src/rev/add8af577552
branches: trunk
changeset: 964493:add8af577552
user: tnn <tnn%NetBSD.org@localhost>
date: Sun Aug 04 22:13:24 2019 +0000
description:
m25p: change devices recently added from 4kB "sector size" to 64kB ...
... even though it is wrong and these devices really use 4kB sector size.
Despite the struct member being named sector size it is actually used as
block size. Our spiflash driver doesn't issue sector erase commands.
Stopgap measure to fix data corruption until the driver is fixed.
diffstat:
sys/dev/spi/m25p.c | 22 +++++++++++-----------
1 files changed, 11 insertions(+), 11 deletions(-)
diffs (43 lines):
diff -r 1c516665a72a -r add8af577552 sys/dev/spi/m25p.c
--- a/sys/dev/spi/m25p.c Sun Aug 04 20:49:54 2019 +0000
+++ b/sys/dev/spi/m25p.c Sun Aug 04 22:13:24 2019 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: m25p.c,v 1.9 2019/08/04 20:49:54 tnn Exp $ */
+/* $NetBSD: m25p.c,v 1.10 2019/08/04 22:13:24 tnn Exp $ */
/*-
* Copyright (c) 2006 Urbana-Champaign Independent Media Center.
@@ -42,7 +42,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: m25p.c,v 1.9 2019/08/04 20:49:54 tnn Exp $");
+__KERNEL_RCSID(0, "$NetBSD: m25p.c,v 1.10 2019/08/04 22:13:24 tnn Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -98,15 +98,15 @@
{ 0xc0, 0x20, 0x7117, "STMicro M25PX64", 8192, 64 }, /* 64Mbit */
{ 0x00, 0x20, 0xBB18, "Numonyx N25Q128", 16384, 64 }, /* 128Mbit */
{ 0x00, 0xBF, 0x2541, "Microchip SST25VF016B", 2048, 64 }, /* 16Mbit */
- { 0x00, 0xC2, 0x2011, "Macronix MX25L10", 128, 4 }, /* 1Mbit */
- { 0x00, 0xC2, 0x2012, "Macronix MX25L20", 256, 4 }, /* 2Mbit */
- { 0x00, 0xC2, 0x2013, "Macronix MX25L40", 512, 4 }, /* 4Mbit */
- { 0x00, 0xC2, 0x2014, "Macronix MX25L80", 1024, 4 }, /* 8Mbit */
- { 0x00, 0xC8, 0x4018, "GigaDevice 25Q127CSIG", 16384, 4 }, /* 128Mbit */
- { 0x00, 0xEF, 0x3011, "Winbond W25X10", 128, 4 }, /* 1Mbit */
- { 0x00, 0xEF, 0x3012, "Winbond W25X20", 256, 4 }, /* 2Mbit */
- { 0x00, 0xEF, 0x3013, "Winbond W25X40", 512, 4 }, /* 4Mbit */
- { 0x00, 0xEF, 0x3014, "Winbond W25X80", 1024, 4 }, /* 8Mbit */
+ { 0x00, 0xC2, 0x2011, "Macronix MX25L10", 128, 64 }, /* 1Mbit */
+ { 0x00, 0xC2, 0x2012, "Macronix MX25L20", 256, 64 }, /* 2Mbit */
+ { 0x00, 0xC2, 0x2013, "Macronix MX25L40", 512, 64 }, /* 4Mbit */
+ { 0x00, 0xC2, 0x2014, "Macronix MX25L80", 1024, 64 }, /* 8Mbit */
+ { 0x00, 0xC8, 0x4018, "GigaDevice 25Q127CSIG", 16384, 64 }, /* 128Mbit */
+ { 0x00, 0xEF, 0x3011, "Winbond W25X10", 128, 64 }, /* 1Mbit */
+ { 0x00, 0xEF, 0x3012, "Winbond W25X20", 256, 64 }, /* 2Mbit */
+ { 0x00, 0xEF, 0x3013, "Winbond W25X40", 512, 64 }, /* 4Mbit */
+ { 0x00, 0xEF, 0x3014, "Winbond W25X80", 1024, 64 }, /* 8Mbit */
{ 0x13, 0xEF, 0x4014, "Winbond W25Q80.V", 1024, 64 }, /* 8Mbit */
{ 0x14, 0xEF, 0x4015, "Winbond W25Q16.V", 2048, 64 }, /* 16Mbit */
{ 0x15, 0xEF, 0x4016, "Winbond W25Q32.V", 4096, 64 }, /* 32Mbit */
Home |
Main Index |
Thread Index |
Old Index