blob: f9f04a879d6e3bf1505ead06a404e08c439f4cbf [file] [log] [blame]
Ollie Lho184a4042005-11-26 21:55:36 +00001/*
Uwe Hermannd1107642007-08-29 17:52:32 +00002 * This file is part of the flashrom project.
Ollie Lho184a4042005-11-26 21:55:36 +00003 *
Uwe Hermannd22a1d42007-09-09 20:21:05 +00004 * Copyright (C) 2000 Silicon Integrated System Corporation
5 * Copyright (C) 2004 Tyan Corp
Stefan Reinauer4c390c82008-07-02 13:33:09 +00006 * Copyright (C) 2005-2008 coresystems GmbH <stepan@openbios.org>
Carl-Daniel Hailfinger66afb362009-03-19 12:18:13 +00007 * Copyright (C) 2006-2009 Carl-Daniel Hailfinger
Sean Nelsonc57a9202010-01-04 17:15:23 +00008 * Copyright (C) 2009 Sean Nelson <audiohacked@gmail.com>
Uwe Hermannd1107642007-08-29 17:52:32 +00009 *
Stefan Reinauerce532972007-05-23 17:20:56 +000010 * This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2 of the License, or
13 * (at your option) any later version.
Ollie Lho184a4042005-11-26 21:55:36 +000014 *
Stefan Reinauerce532972007-05-23 17:20:56 +000015 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU General Public License for more details.
Ollie Lho184a4042005-11-26 21:55:36 +000019 */
20
21#include "flash.h"
Carl-Daniel Hailfinger08454642009-06-15 14:14:48 +000022#include "flashchips.h"
Sean Nelson14ba6682010-02-26 05:48:29 +000023#include "chipdrivers.h"
Nico Huberaabb3e02023-01-13 00:22:30 +010024#include "writeprotect.h"
Ollie Lho184a4042005-11-26 21:55:36 +000025
Uwe Hermannfc425e82008-03-16 02:06:25 +000026/**
Uwe Hermanna9720402009-05-21 15:55:46 +000027 * List of supported flash chips.
Uwe Hermannfc425e82008-03-16 02:06:25 +000028 *
Alan Green1f9cc7d2019-07-01 11:10:45 +100029 * Temporarily, this file is sorted alphabetically by vendor and name to
Nico Huberc3b02dc2023-08-12 01:13:45 +020030 * assist with merging the Chromium fork of flashprog.
Alan Green1f9cc7d2019-07-01 11:10:45 +100031 *
32 * The usual intention is that that this list is sorted by vendor, then chip
Nico Huberc3b02dc2023-08-12 01:13:45 +020033 * family and chip density, which is useful for the output of 'flashprog -L'.
Uwe Hermannfc425e82008-03-16 02:06:25 +000034 */
Carl-Daniel Hailfinger4c823182011-05-04 00:39:50 +000035const struct flashchip flashchips[] = {
Uwe Hermannfc425e82008-03-16 02:06:25 +000036
Carl-Daniel Hailfinger21eedec2009-07-23 12:42:01 +000037 /*
38 * .vendor = Vendor name
39 * .name = Chip name
40 * .bustype = Supported flash bus types (Parallel, LPC...)
41 * .manufacture_id = Manufacturer chip ID
42 * .model_id = Model chip ID
43 * .total_size = Total size in (binary) kbytes
44 * .page_size = Page or eraseblock(?) size in bytes
45 * .tested = Test status
46 * .probe = Probe function
47 * .probe_timing = Probe function delay
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +000048 * .block_erasers[] = Array of erase layouts and erase functions
49 * {
50 * .eraseblocks[] = Array of { blocksize, blockcount }
51 * .block_erase = Block erase function
52 * }
Sean Nelson6e0b9122010-02-19 00:52:10 +000053 * .printlock = Chip lock status function
54 * .unlock = Chip unlock function
Carl-Daniel Hailfinger21eedec2009-07-23 12:42:01 +000055 * .write = Chip write function
56 * .read = Chip read function
Steven Zakuleccbe370e2011-06-03 07:26:31 +000057 * .voltage = Voltage range in millivolt
FENG yu ningff692fb2008-12-08 18:15:10 +000058 */
59
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000060 {
61 .vendor = "AMD",
62 .name = "Am29F002(N)BB",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000063 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000064 .manufacture_id = AMD_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000065 .model_id = AMD_AM29F002BB,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000066 .total_size = 256,
67 .page_size = 256,
Sean Nelson35727f72010-01-28 23:55:12 +000068 .feature_bits = FEATURE_SHORT_RESET | FEATURE_ADDR_2AA,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000069 .tested = TEST_UNTESTED,
70 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000071 .probe_timing = TIMING_ZERO,
Sean Nelson72a9a022009-12-22 22:15:33 +000072 .block_erasers =
73 {
74 {
75 .eraseblocks = {
76 {16 * 1024, 1},
77 {8 * 1024, 2},
78 {32 * 1024, 1},
79 {64 * 1024, 3},
80 },
81 .block_erase = erase_sector_jedec,
82 }, {
83 .eraseblocks = { {256 * 1024, 1} },
84 .block_erase = erase_chip_block_jedec,
85 },
86 },
Michael Karcher1c296ca2009-11-27 17:49:42 +000087 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000088 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +000089 .voltage = {4750, 5250}, /* 4.75-5.25V for type -55, others 4.5-5.5V */
Nico Huber9eec4072023-01-12 01:17:30 +010090 .prepare_access = prepare_memory_access,
91 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000092 },
93
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000094 {
95 .vendor = "AMD",
96 .name = "Am29F002(N)BT",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000097 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000098 .manufacture_id = AMD_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000099 .model_id = AMD_AM29F002BT,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000100 .total_size = 256,
101 .page_size = 256,
Sean Nelson35727f72010-01-28 23:55:12 +0000102 .feature_bits = FEATURE_EITHER_RESET | FEATURE_ADDR_2AA,
103 .tested = TEST_UNTESTED,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000104 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +0000105 .probe_timing = TIMING_ZERO,
Sean Nelson72a9a022009-12-22 22:15:33 +0000106 .block_erasers =
107 {
108 {
109 .eraseblocks = {
110 {64 * 1024, 3},
111 {32 * 1024, 1},
112 {8 * 1024, 2},
113 {16 * 1024, 1},
114 },
115 .block_erase = erase_sector_jedec,
116 }, {
117 .eraseblocks = { {256 * 1024, 1} },
118 .block_erase = erase_chip_block_jedec,
119 },
120 },
Michael Karcher1c296ca2009-11-27 17:49:42 +0000121 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +0000122 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +0000123 .voltage = {4750, 5250}, /* 4.75-5.25V for type -55, others 4.5-5.5V */
Nico Huber9eec4072023-01-12 01:17:30 +0100124 .prepare_access = prepare_memory_access,
125 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +0000126 },
127
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000128 {
129 .vendor = "AMD",
Alan Green1f9cc7d2019-07-01 11:10:45 +1000130 .name = "Am29F010",
131 .bustype = BUS_PARALLEL,
132 .manufacture_id = AMD_ID,
133 .model_id = AMD_AM29F010,
134 .total_size = 128,
135 .page_size = 16 * 1024,
136 .feature_bits = FEATURE_SHORT_RESET,
137 .tested = TEST_UNTESTED,
138 .probe = probe_jedec,
139 .probe_timing = TIMING_ZERO,
140 .block_erasers =
141 {
142 {
143 .eraseblocks = { {16 * 1024, 8} },
144 .block_erase = erase_sector_jedec,
145 }, {
146 .eraseblocks = { {128 * 1024, 1} },
147 .block_erase = erase_chip_block_jedec,
148 },
149 },
150 .write = write_jedec_1,
151 .read = read_memmapped,
152 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +0100153 .prepare_access = prepare_memory_access,
154 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +1000155 },
156
157 {
158 .vendor = "AMD",
159 .name = "Am29F010A/B",
160 .bustype = BUS_PARALLEL,
161 .manufacture_id = AMD_ID,
162 .model_id = AMD_AM29F010,
163 .total_size = 128,
164 .page_size = 16 * 1024,
165 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Alan Greena4e579f2019-07-24 14:18:39 +1000166 .tested = TEST_OK_PRE,
Alan Green1f9cc7d2019-07-01 11:10:45 +1000167 .probe = probe_jedec,
168 .probe_timing = TIMING_ZERO,
169 .block_erasers =
170 {
171 {
172 .eraseblocks = { {16 * 1024, 8} },
173 .block_erase = erase_sector_jedec,
174 }, {
175 .eraseblocks = { {128 * 1024, 1} },
176 .block_erase = erase_chip_block_jedec,
177 },
178 },
179 .write = write_jedec_1,
180 .read = read_memmapped,
181 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +0100182 .prepare_access = prepare_memory_access,
183 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +1000184 },
185
186 {
187 .vendor = "AMD",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000188 .name = "Am29F016D",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000189 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000190 .manufacture_id = AMD_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +0000191 .model_id = AMD_AM29F016D,
Sean Nelson72a9a022009-12-22 22:15:33 +0000192 .total_size = 2 * 1024,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000193 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +0000194 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000195 .tested = TEST_UNTESTED,
Sean Nelson35727f72010-01-28 23:55:12 +0000196 .probe = probe_jedec,
David Borg204f4652010-12-04 03:26:40 +0000197 .probe_timing = TIMING_ZERO,
Sean Nelson72a9a022009-12-22 22:15:33 +0000198 .block_erasers =
199 {
200 {
201 .eraseblocks = { {64 * 1024, 32} },
Sean Nelson35727f72010-01-28 23:55:12 +0000202 .block_erase = erase_sector_jedec,
Sean Nelson72a9a022009-12-22 22:15:33 +0000203 }, {
204 .eraseblocks = { {2048 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +0000205 .block_erase = erase_chip_block_jedec,
Sean Nelson72a9a022009-12-22 22:15:33 +0000206 },
207 },
Sean Nelson35727f72010-01-28 23:55:12 +0000208 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +0000209 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +0000210 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +0100211 .prepare_access = prepare_memory_access,
212 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +0000213 },
214
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000215 {
216 .vendor = "AMD",
Stefan Taunerd1ca1e82016-01-31 23:17:35 +0000217 .name = "Am29F040",
218 .bustype = BUS_PARALLEL,
219 .manufacture_id = AMD_ID,
220 .model_id = AMD_AM29F040,
221 .total_size = 512,
222 .page_size = 64 * 1024,
223 .feature_bits = FEATURE_EITHER_RESET,
224 .tested = TEST_UNTESTED,
225 .probe = probe_jedec,
226 .probe_timing = TIMING_ZERO,
227 .block_erasers =
228 {
229 {
230 .eraseblocks = { {64 * 1024, 8} },
231 .block_erase = erase_sector_jedec,
232 }, {
233 .eraseblocks = { {512 * 1024, 1} },
234 .block_erase = erase_chip_block_jedec,
235 },
236 },
237 .write = write_jedec_1,
238 .read = read_memmapped,
239 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +0100240 .prepare_access = prepare_memory_access,
241 .finish_access = finish_memory_access,
Stefan Taunerd1ca1e82016-01-31 23:17:35 +0000242 },
243
244 {
245 .vendor = "AMD",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000246 .name = "Am29F040B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000247 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000248 .manufacture_id = AMD_ID,
Stefan Taunerd1ca1e82016-01-31 23:17:35 +0000249 .model_id = AMD_AM29F040,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000250 .total_size = 512,
251 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +0000252 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
253 .tested = TEST_UNTESTED,
254 .probe = probe_jedec,
David Borg204f4652010-12-04 03:26:40 +0000255 .probe_timing = TIMING_ZERO,
Sean Nelson72a9a022009-12-22 22:15:33 +0000256 .block_erasers =
257 {
258 {
259 .eraseblocks = { {64 * 1024, 8} },
Sean Nelson35727f72010-01-28 23:55:12 +0000260 .block_erase = erase_sector_jedec,
Sean Nelson72a9a022009-12-22 22:15:33 +0000261 }, {
262 .eraseblocks = { {512 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +0000263 .block_erase = erase_chip_block_jedec,
Sean Nelson72a9a022009-12-22 22:15:33 +0000264 },
265 },
Sean Nelson35727f72010-01-28 23:55:12 +0000266 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +0000267 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +0000268 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +0100269 .prepare_access = prepare_memory_access,
270 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +0000271 },
272
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000273 {
274 .vendor = "AMD",
Stefan Taunerd1ca1e82016-01-31 23:17:35 +0000275 .name = "Am29F080",
276 .bustype = BUS_PARALLEL,
277 .manufacture_id = AMD_ID,
278 .model_id = AMD_AM29F080,
279 .total_size = 1024,
280 .page_size = 64 * 1024,
281 .feature_bits = FEATURE_EITHER_RESET,
282 .tested = TEST_UNTESTED,
283 .probe = probe_jedec,
284 .probe_timing = TIMING_ZERO,
285 .block_erasers =
286 {
287 {
288 .eraseblocks = { {64 * 1024, 16} },
289 .block_erase = erase_sector_jedec,
290 }, {
291 .eraseblocks = { {1024 * 1024, 1} },
292 .block_erase = erase_chip_block_jedec,
293 },
294 },
295 .write = write_jedec_1,
296 .read = read_memmapped,
297 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +0100298 .prepare_access = prepare_memory_access,
299 .finish_access = finish_memory_access,
Stefan Taunerd1ca1e82016-01-31 23:17:35 +0000300 },
301
302 {
303 .vendor = "AMD",
Peter Stuge8440cc02009-01-25 23:55:12 +0000304 .name = "Am29F080B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000305 .bustype = BUS_PARALLEL,
Mateusz Murawski5bae4382009-06-02 00:38:14 +0000306 .manufacture_id = AMD_ID,
Stefan Taunerd1ca1e82016-01-31 23:17:35 +0000307 .model_id = AMD_AM29F080,
Peter Stuge8440cc02009-01-25 23:55:12 +0000308 .total_size = 1024,
309 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +0000310 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
Peter Stuge8440cc02009-01-25 23:55:12 +0000311 .tested = TEST_UNTESTED,
312 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +0000313 .probe_timing = TIMING_ZERO,
Sean Nelson72a9a022009-12-22 22:15:33 +0000314 .block_erasers =
315 {
316 {
317 .eraseblocks = { {64 * 1024, 16} },
Sean Nelson35727f72010-01-28 23:55:12 +0000318 .block_erase = erase_sector_jedec,
Sean Nelson72a9a022009-12-22 22:15:33 +0000319 }, {
320 .eraseblocks = { {1024 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +0000321 .block_erase = erase_chip_block_jedec,
Sean Nelson72a9a022009-12-22 22:15:33 +0000322 },
323 },
Sean Nelson35727f72010-01-28 23:55:12 +0000324 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +0000325 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +0000326 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +0100327 .prepare_access = prepare_memory_access,
328 .finish_access = finish_memory_access,
Peter Stuge8440cc02009-01-25 23:55:12 +0000329 },
330
331 {
332 .vendor = "AMD",
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000333 .name = "Am29LV001BB",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000334 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000335 .manufacture_id = AMD_ID,
336 .model_id = AMD_AM29LV001BB,
337 .total_size = 128,
338 .page_size = 64 * 1024, /* unused */
339 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
340 .tested = TEST_OK_PREW,
341 .probe = probe_jedec,
342 .probe_timing = TIMING_ZERO,
343 .block_erasers =
344 {
345 {
346 .eraseblocks = {
347 {8 * 1024, 1},
348 {4 * 1024, 2},
349 {16 * 1024, 7},
350 },
351 .block_erase = erase_sector_jedec,
352 }, {
353 .eraseblocks = { {128 * 1024, 1} },
354 .block_erase = erase_chip_block_jedec,
355 },
356 },
357 .write = write_jedec_1,
358 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +0000359 .voltage = {3000, 3600}, /* 3.0-3.6V for type -45R, others 2.7-3.6V */
Nico Huber9eec4072023-01-12 01:17:30 +0100360 .prepare_access = prepare_memory_access,
361 .finish_access = finish_memory_access,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000362 },
363
364 {
365 .vendor = "AMD",
366 .name = "Am29LV001BT",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000367 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000368 .manufacture_id = AMD_ID,
369 .model_id = AMD_AM29LV001BT,
370 .total_size = 128,
371 .page_size = 64 * 1024, /* unused */
372 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
373 .tested = TEST_UNTESTED,
374 .probe = probe_jedec,
375 .probe_timing = TIMING_ZERO,
376 .block_erasers =
377 {
378 {
379 .eraseblocks = {
380 {16 * 1024, 7},
381 {4 * 1024, 2},
382 {8 * 1024, 1},
383 },
384 .block_erase = erase_sector_jedec,
385 }, {
386 .eraseblocks = { {128 * 1024, 1} },
387 .block_erase = erase_chip_block_jedec,
388 },
389 },
390 .write = write_jedec_1,
391 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +0000392 .voltage = {3000, 3600}, /* 3.0-3.6V for type -45R, others 2.7-3.6V */
Nico Huber9eec4072023-01-12 01:17:30 +0100393 .prepare_access = prepare_memory_access,
394 .finish_access = finish_memory_access,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000395 },
396
397 {
398 .vendor = "AMD",
399 .name = "Am29LV002BB",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000400 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000401 .manufacture_id = AMD_ID,
402 .model_id = AMD_AM29LV002BB,
403 .total_size = 256,
404 .page_size = 64 * 1024, /* unused */
405 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
406 .tested = TEST_UNTESTED,
407 .probe = probe_jedec,
408 .probe_timing = TIMING_ZERO,
409 .block_erasers =
410 {
411 {
412 .eraseblocks = {
413 {16 * 1024, 1},
414 {8 * 1024, 2},
415 {32 * 1024, 1},
416 {64 * 1024, 3},
417 },
418 .block_erase = erase_sector_jedec,
419 }, {
420 .eraseblocks = { {256 * 1024, 1} },
421 .block_erase = erase_chip_block_jedec,
422 },
423 },
424 .write = write_jedec_1,
425 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +0000426 .voltage = {3000, 3600}, /* 3.0-3.6V for type -55, others 2.7-3.6V */
Nico Huber9eec4072023-01-12 01:17:30 +0100427 .prepare_access = prepare_memory_access,
428 .finish_access = finish_memory_access,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000429 },
430
431 {
432 .vendor = "AMD",
433 .name = "Am29LV002BT",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000434 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000435 .manufacture_id = AMD_ID,
436 .model_id = AMD_AM29LV002BT,
437 .total_size = 256,
438 .page_size = 64 * 1024, /* unused */
439 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
440 .tested = TEST_UNTESTED,
441 .probe = probe_jedec,
442 .probe_timing = TIMING_ZERO,
443 .block_erasers =
444 {
445 {
446 .eraseblocks = {
447 {64 * 1024, 3},
448 {32 * 1024, 1},
449 {8 * 1024, 2},
450 {16 * 1024, 1},
451 },
452 .block_erase = erase_sector_jedec,
453 }, {
454 .eraseblocks = { {256 * 1024, 1} },
455 .block_erase = erase_chip_block_jedec,
456 },
457 },
458 .write = write_jedec_1,
459 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +0000460 .voltage = {3000, 3600}, /* 3.0-3.6V for type -55, others 2.7-3.6V */
Nico Huber9eec4072023-01-12 01:17:30 +0100461 .prepare_access = prepare_memory_access,
462 .finish_access = finish_memory_access,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000463 },
464
465 {
466 .vendor = "AMD",
467 .name = "Am29LV004BB",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000468 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000469 .manufacture_id = AMD_ID,
470 .model_id = AMD_AM29LV004BB,
471 .total_size = 512,
472 .page_size = 64 * 1024, /* unused */
473 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
474 .tested = TEST_UNTESTED,
475 .probe = probe_jedec,
476 .probe_timing = TIMING_ZERO,
477 .block_erasers =
478 {
479 {
480 .eraseblocks = {
481 {16 * 1024, 1},
482 {8 * 1024, 2},
483 {32 * 1024, 1},
484 {64 * 1024, 7},
485 },
486 .block_erase = erase_sector_jedec,
487 }, {
488 .eraseblocks = { {512 * 1024, 1} },
489 .block_erase = erase_chip_block_jedec,
490 },
491 },
492 .write = write_jedec_1,
493 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +0000494 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +0100495 .prepare_access = prepare_memory_access,
496 .finish_access = finish_memory_access,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000497 },
498
499 {
500 .vendor = "AMD",
501 .name = "Am29LV004BT",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000502 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000503 .manufacture_id = AMD_ID,
504 .model_id = AMD_AM29LV004BT,
505 .total_size = 512,
506 .page_size = 64 * 1024, /* unused */
507 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
508 .tested = TEST_UNTESTED,
509 .probe = probe_jedec,
510 .probe_timing = TIMING_ZERO,
511 .block_erasers =
512 {
513 {
514 .eraseblocks = {
515 {64 * 1024, 7},
516 {32 * 1024, 1},
517 {8 * 1024, 2},
518 {16 * 1024, 1},
519 },
520 .block_erase = erase_sector_jedec,
521 }, {
522 .eraseblocks = { {512 * 1024, 1} },
523 .block_erase = erase_chip_block_jedec,
524 },
525 },
526 .write = write_jedec_1,
527 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +0000528 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +0100529 .prepare_access = prepare_memory_access,
530 .finish_access = finish_memory_access,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000531 },
532
533 {
534 .vendor = "AMD",
535 .name = "Am29LV008BB",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000536 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000537 .manufacture_id = AMD_ID,
538 .model_id = AMD_AM29LV008BB,
539 .total_size = 1024,
540 .page_size = 64 * 1024, /* unused */
541 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
Uwe Hermann09ebd522011-08-25 22:54:23 +0000542 .tested = TEST_OK_PREW,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000543 .probe = probe_jedec,
544 .probe_timing = TIMING_ZERO,
545 .block_erasers =
546 {
547 {
548 .eraseblocks = {
549 {16 * 1024, 1},
550 {8 * 1024, 2},
551 {32 * 1024, 1},
552 {64 * 1024, 15},
553 },
554 .block_erase = erase_sector_jedec,
555 }, {
556 .eraseblocks = { {1024 * 1024, 1} },
557 .block_erase = erase_chip_block_jedec,
558 },
559 },
560 .write = write_jedec_1,
561 .read = read_memmapped,
Alan Greenf5ad6882019-06-27 12:09:13 +1000562 .voltage = {3000, 3600}, /* 3.0-3.6V for type -70R, others 2.7-3.6V */
Nico Huber9eec4072023-01-12 01:17:30 +0100563 .prepare_access = prepare_memory_access,
564 .finish_access = finish_memory_access,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000565 },
566
567 {
568 .vendor = "AMD",
569 .name = "Am29LV008BT",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000570 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000571 .manufacture_id = AMD_ID,
572 .model_id = AMD_AM29LV008BT,
573 .total_size = 1024,
574 .page_size = 64 * 1024, /* unused */
575 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
576 .tested = TEST_UNTESTED,
577 .probe = probe_jedec,
578 .probe_timing = TIMING_ZERO,
579 .block_erasers =
580 {
581 {
582 .eraseblocks = {
583 {64 * 1024, 15},
584 {32 * 1024, 1},
585 {8 * 1024, 2},
586 {16 * 1024, 1},
587 },
588 .block_erase = erase_sector_jedec,
589 }, {
590 .eraseblocks = { {1024 * 1024, 1} },
591 .block_erase = erase_chip_block_jedec,
592 },
593 },
594 .write = write_jedec_1,
595 .read = read_memmapped,
Alan Greenf5ad6882019-06-27 12:09:13 +1000596 .voltage = {3000, 3600}, /* 3.0-3.6V for type -70R, others 2.7-3.6V */
Nico Huber9eec4072023-01-12 01:17:30 +0100597 .prepare_access = prepare_memory_access,
598 .finish_access = finish_memory_access,
Carl-Daniel Hailfingerc753e5b2011-02-05 12:11:17 +0000599 },
600
601 {
602 .vendor = "AMD",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000603 .name = "Am29LV040B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000604 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000605 .manufacture_id = AMD_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +0000606 .model_id = AMD_AM29LV040B,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000607 .total_size = 512,
608 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +0000609 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
Carl-Daniel Hailfingerf52f7842010-10-08 18:52:29 +0000610 .tested = TEST_OK_PRE,
Sean Nelson35727f72010-01-28 23:55:12 +0000611 .probe = probe_jedec,
David Borg204f4652010-12-04 03:26:40 +0000612 .probe_timing = TIMING_ZERO,
Sean Nelson72a9a022009-12-22 22:15:33 +0000613 .block_erasers =
614 {
615 {
616 .eraseblocks = { {64 * 1024, 8} },
Sean Nelson35727f72010-01-28 23:55:12 +0000617 .block_erase = erase_sector_jedec,
Sean Nelson72a9a022009-12-22 22:15:33 +0000618 }, {
619 .eraseblocks = { {512 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +0000620 .block_erase = erase_chip_block_jedec,
Sean Nelson72a9a022009-12-22 22:15:33 +0000621 },
622 },
Sean Nelson35727f72010-01-28 23:55:12 +0000623 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +0000624 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +0000625 .voltage = {3000, 3600}, /* 3.0-3.6V for type -60R, others 2.7-3.6V*/
Nico Huber9eec4072023-01-12 01:17:30 +0100626 .prepare_access = prepare_memory_access,
627 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +0000628 },
629
Stephan Guilloux5c5b5252009-01-08 03:40:17 +0000630 {
Peter Stuge8440cc02009-01-25 23:55:12 +0000631 .vendor = "AMD",
632 .name = "Am29LV081B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000633 .bustype = BUS_PARALLEL,
Mateusz Murawski5bae4382009-06-02 00:38:14 +0000634 .manufacture_id = AMD_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +0000635 .model_id = AMD_AM29LV080B,
Peter Stuge8440cc02009-01-25 23:55:12 +0000636 .total_size = 1024,
637 .page_size = 64 * 1024,
David Borg204f4652010-12-04 03:26:40 +0000638 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET, /* datasheet specifies address as don't care */
Peter Stuge8440cc02009-01-25 23:55:12 +0000639 .tested = TEST_UNTESTED,
Sean Nelson35727f72010-01-28 23:55:12 +0000640 .probe = probe_jedec,
David Borg204f4652010-12-04 03:26:40 +0000641 .probe_timing = TIMING_ZERO,
Sean Nelson72a9a022009-12-22 22:15:33 +0000642 .block_erasers =
643 {
644 {
645 .eraseblocks = { {64 * 1024, 16} },
Sean Nelson35727f72010-01-28 23:55:12 +0000646 .block_erase = erase_sector_jedec,
Sean Nelson72a9a022009-12-22 22:15:33 +0000647 }, {
648 .eraseblocks = { {1024 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +0000649 .block_erase = erase_chip_block_jedec,
Sean Nelson72a9a022009-12-22 22:15:33 +0000650 },
651 },
Sean Nelson35727f72010-01-28 23:55:12 +0000652 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +0000653 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +0000654 .voltage = {3000, 3600}, /* 3.0-3.6V for type -70R, others 2.7-3.6V */
Nico Huber9eec4072023-01-12 01:17:30 +0100655 .prepare_access = prepare_memory_access,
656 .finish_access = finish_memory_access,
Peter Stuge8440cc02009-01-25 23:55:12 +0000657 },
658
659 {
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000660 .vendor = "AMIC",
Alan Green1f9cc7d2019-07-01 11:10:45 +1000661 .name = "A25L010",
662 .bustype = BUS_SPI,
663 .manufacture_id = AMIC_ID_NOPREFIX,
664 .model_id = AMIC_A25L010,
665 .total_size = 128,
666 .page_size = 256,
667 .feature_bits = FEATURE_WRSR_WREN,
668 .tested = TEST_UNTESTED,
669 .probe = probe_spi_rdid,
670 .probe_timing = TIMING_ZERO,
671 .block_erasers =
672 {
673 {
674 .eraseblocks = { { 4 * 1024, 32 } },
675 .block_erase = spi_block_erase_20,
676 }, {
677 .eraseblocks = { { 64 * 1024, 2 } },
678 .block_erase = spi_block_erase_d8,
679 }, {
680 .eraseblocks = { { 128 * 1024, 1 } },
681 .block_erase = spi_block_erase_c7,
682 }
683 },
684 .printlock = spi_prettyprint_status_register_bp2_srwd,
685 .unlock = spi_disable_blockprotect,
686 .write = spi_chip_write_256,
687 .read = spi_chip_read,
688 .voltage = {2700, 3600},
689 },
690
691 {
692 .vendor = "AMIC",
693 .name = "A25L016",
694 .bustype = BUS_SPI,
695 .manufacture_id = AMIC_ID_NOPREFIX,
696 .model_id = AMIC_A25L016,
697 .total_size = 2048,
698 .page_size = 256,
699 .feature_bits = FEATURE_WRSR_WREN,
700 .tested = TEST_UNTESTED,
701 .probe = probe_spi_rdid,
702 .probe_timing = TIMING_ZERO,
703 .block_erasers =
704 {
705 {
706 .eraseblocks = { { 4 * 1024, 512 } },
707 .block_erase = spi_block_erase_20,
708 }, {
709 .eraseblocks = { { 64 * 1024, 32 } },
710 .block_erase = spi_block_erase_d8,
711 }, {
712 .eraseblocks = { { 2048 * 1024, 1 } },
713 .block_erase = spi_block_erase_c7,
714 }
715 },
716 .printlock = spi_prettyprint_status_register_bp2_srwd,
717 .unlock = spi_disable_blockprotect,
718 .write = spi_chip_write_256,
719 .read = spi_chip_read,
720 .voltage = {2700, 3600},
721 },
722
723 {
724 .vendor = "AMIC",
725 .name = "A25L020",
726 .bustype = BUS_SPI,
727 .manufacture_id = AMIC_ID_NOPREFIX,
728 .model_id = AMIC_A25L020,
729 .total_size = 256,
730 .page_size = 256,
731 .feature_bits = FEATURE_WRSR_WREN,
732 .tested = TEST_UNTESTED,
733 .probe = probe_spi_rdid,
734 .probe_timing = TIMING_ZERO,
735 .block_erasers =
736 {
737 {
738 .eraseblocks = { { 4 * 1024, 64 } },
739 .block_erase = spi_block_erase_20,
740 }, {
741 .eraseblocks = { { 64 * 1024, 4 } },
742 .block_erase = spi_block_erase_d8,
743 }, {
744 .eraseblocks = { { 256 * 1024, 1 } },
745 .block_erase = spi_block_erase_c7,
746 }
747 },
748 .printlock = spi_prettyprint_status_register_bp2_srwd,
749 .unlock = spi_disable_blockprotect,
750 .write = spi_chip_write_256,
751 .read = spi_chip_read,
752 .voltage = {2700, 3600},
753 },
754
755 {
756 .vendor = "AMIC",
757 .name = "A25L032",
758 .bustype = BUS_SPI,
759 .manufacture_id = AMIC_ID_NOPREFIX,
760 .model_id = AMIC_A25L032,
761 .total_size = 4096,
762 .page_size = 256,
763 /* OTP: 64B total; read 0x4B, 0x48; write 0x42 */
764 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
765 .tested = TEST_OK_PREW,
766 .probe = probe_spi_rdid,
767 .probe_timing = TIMING_ZERO,
768 .block_erasers =
769 {
770 {
771 .eraseblocks = { { 4 * 1024, 1024 } },
772 .block_erase = spi_block_erase_20,
773 }, {
774 .eraseblocks = { { 64 * 1024, 64 } },
775 .block_erase = spi_block_erase_52,
776 }, {
777 .eraseblocks = { { 64 * 1024, 64 } },
778 .block_erase = spi_block_erase_d8,
779 }, {
780 .eraseblocks = { { 4096 * 1024, 1 } },
781 .block_erase = spi_block_erase_60,
782 }, {
783 .eraseblocks = { { 4096 * 1024, 1 } },
784 .block_erase = spi_block_erase_c7,
785 }
786 },
787 .printlock = spi_prettyprint_status_register_amic_a25l032, /* bit5: T/B, bit6: prot size */
788 .unlock = spi_disable_blockprotect_bp2_srwd, /* TODO: 2nd status reg (read with 0x35) */
789 .write = spi_chip_write_256,
790 .read = spi_chip_read,
791 .voltage = {2700, 3600},
792 },
793
794 {
795 .vendor = "AMIC",
796 .name = "A25L040",
797 .bustype = BUS_SPI,
798 .manufacture_id = AMIC_ID_NOPREFIX,
799 .model_id = AMIC_A25L040,
800 .total_size = 512,
801 .page_size = 256,
802 .feature_bits = FEATURE_WRSR_WREN,
803 .tested = TEST_UNTESTED,
804 .probe = probe_spi_rdid,
805 .probe_timing = TIMING_ZERO,
806 .block_erasers =
807 {
808 {
809 .eraseblocks = { { 4 * 1024, 128 } },
810 .block_erase = spi_block_erase_20,
811 }, {
812 .eraseblocks = { { 64 * 1024, 8 } },
813 .block_erase = spi_block_erase_d8,
814 }, {
815 .eraseblocks = { { 512 * 1024, 1 } },
816 .block_erase = spi_block_erase_c7,
817 }
818 },
819 .printlock = spi_prettyprint_status_register_bp2_srwd,
820 .unlock = spi_disable_blockprotect,
821 .write = spi_chip_write_256,
822 .read = spi_chip_read,
823 .voltage = {2700, 3600},
824 },
825
826 {
827 .vendor = "AMIC",
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000828 .name = "A25L05PT",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000829 .bustype = BUS_SPI,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000830 .manufacture_id = AMIC_ID,
831 .model_id = AMIC_A25L05PT,
832 .total_size = 64,
833 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +0000834 .feature_bits = FEATURE_WRSR_WREN,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000835 .tested = TEST_UNTESTED,
836 .probe = probe_spi_rdid4,
837 .probe_timing = TIMING_ZERO,
838 .block_erasers =
839 {
840 {
841 .eraseblocks = {
842 {32 * 1024, 1},
843 {16 * 1024, 1},
844 {8 * 1024, 1},
845 {4 * 1024, 2},
846 },
847 .block_erase = spi_block_erase_d8,
848 }, {
849 .eraseblocks = { {64 * 1024, 1} },
850 .block_erase = spi_block_erase_c7,
851 }
852 },
Stefan Tauner12f3d512014-05-27 21:27:27 +0000853 .printlock = spi_prettyprint_status_register_bp1_srwd,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000854 .unlock = spi_disable_blockprotect,
855 .write = spi_chip_write_256,
856 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +0000857 .voltage = {2700, 3600},
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000858 },
859
860 {
861 .vendor = "AMIC",
862 .name = "A25L05PU",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000863 .bustype = BUS_SPI,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000864 .manufacture_id = AMIC_ID,
865 .model_id = AMIC_A25L05PU,
866 .total_size = 64,
867 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +0000868 .feature_bits = FEATURE_WRSR_WREN,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000869 .tested = TEST_UNTESTED,
870 .probe = probe_spi_rdid4,
871 .probe_timing = TIMING_ZERO,
872 .block_erasers =
873 {
874 {
875 .eraseblocks = {
876 {4 * 1024, 2},
877 {8 * 1024, 1},
878 {16 * 1024, 1},
879 {32 * 1024, 1},
880 },
881 .block_erase = spi_block_erase_d8,
882 }, {
883 .eraseblocks = { {64 * 1024, 1} },
884 .block_erase = spi_block_erase_c7,
885 }
886 },
Stefan Tauner12f3d512014-05-27 21:27:27 +0000887 .printlock = spi_prettyprint_status_register_bp1_srwd,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000888 .unlock = spi_disable_blockprotect,
889 .write = spi_chip_write_256,
890 .read = spi_chip_read,
Steven Zakulec7d257b42011-07-19 08:50:18 +0000891 .voltage = {2700, 3600},
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000892 },
893
894 {
895 .vendor = "AMIC",
Alan Green1f9cc7d2019-07-01 11:10:45 +1000896 .name = "A25L080",
897 .bustype = BUS_SPI,
898 .manufacture_id = AMIC_ID_NOPREFIX,
899 .model_id = AMIC_A25L080,
900 .total_size = 1024,
901 .page_size = 256,
902 .feature_bits = FEATURE_WRSR_WREN,
903 .tested = TEST_UNTESTED,
904 .probe = probe_spi_rdid,
905 .probe_timing = TIMING_ZERO,
906 .block_erasers =
907 {
908 {
909 .eraseblocks = { { 4 * 1024, 256 } },
910 .block_erase = spi_block_erase_20,
911 }, {
912 .eraseblocks = { { 64 * 1024, 16 } },
913 .block_erase = spi_block_erase_d8,
914 }, {
915 .eraseblocks = { { 1024 * 1024, 1 } },
916 .block_erase = spi_block_erase_c7,
917 }
918 },
919 .printlock = spi_prettyprint_status_register_bp2_srwd,
920 .unlock = spi_disable_blockprotect,
921 .write = spi_chip_write_256,
922 .read = spi_chip_read,
923 .voltage = {2700, 3600},
924 },
925
926 {
927 .vendor = "AMIC",
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000928 .name = "A25L10PT",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000929 .bustype = BUS_SPI,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000930 .manufacture_id = AMIC_ID,
931 .model_id = AMIC_A25L10PT,
932 .total_size = 128,
933 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +0000934 .feature_bits = FEATURE_WRSR_WREN,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000935 .tested = TEST_UNTESTED,
936 .probe = probe_spi_rdid4,
937 .probe_timing = TIMING_ZERO,
938 .block_erasers =
939 {
940 {
941 .eraseblocks = {
942 {64 * 1024, 1},
943 {32 * 1024, 1},
944 {16 * 1024, 1},
945 {8 * 1024, 1},
946 {4 * 1024, 2},
947 },
948 .block_erase = spi_block_erase_d8,
949 }, {
950 .eraseblocks = { {128 * 1024, 1} },
951 .block_erase = spi_block_erase_c7,
952 }
953 },
Stefan Tauner12f3d512014-05-27 21:27:27 +0000954 .printlock = spi_prettyprint_status_register_bp1_srwd,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000955 .unlock = spi_disable_blockprotect,
956 .write = spi_chip_write_256,
957 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +0000958 .voltage = {2700, 3600},
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000959 },
960
961 {
962 .vendor = "AMIC",
963 .name = "A25L10PU",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +0000964 .bustype = BUS_SPI,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000965 .manufacture_id = AMIC_ID,
966 .model_id = AMIC_A25L10PU,
967 .total_size = 128,
968 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +0000969 .feature_bits = FEATURE_WRSR_WREN,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000970 .tested = TEST_UNTESTED,
971 .probe = probe_spi_rdid4,
972 .probe_timing = TIMING_ZERO,
973 .block_erasers =
974 {
975 {
976 .eraseblocks = {
977 {4 * 1024, 2},
978 {8 * 1024, 1},
979 {16 * 1024, 1},
980 {32 * 1024, 1},
981 {64 * 1024, 1},
982 },
983 .block_erase = spi_block_erase_d8,
984 }, {
985 .eraseblocks = { {128 * 1024, 1} },
986 .block_erase = spi_block_erase_c7,
987 }
988 },
Stefan Tauner12f3d512014-05-27 21:27:27 +0000989 .printlock = spi_prettyprint_status_register_bp1_srwd,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000990 .unlock = spi_disable_blockprotect,
991 .write = spi_chip_write_256,
992 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +0000993 .voltage = {2700, 3600},
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +0000994 },
995
996 {
997 .vendor = "AMIC",
Alan Green1f9cc7d2019-07-01 11:10:45 +1000998 .name = "A25L16PT",
999 .bustype = BUS_SPI,
1000 .manufacture_id = AMIC_ID,
1001 .model_id = AMIC_A25L16PT,
1002 .total_size = 2048,
1003 .page_size = 256,
1004 .feature_bits = FEATURE_WRSR_WREN,
1005 .tested = TEST_UNTESTED,
1006 .probe = probe_spi_rdid4,
1007 .probe_timing = TIMING_ZERO,
1008 .block_erasers =
1009 {
1010 {
1011 .eraseblocks = {
1012 {64 * 1024, 31},
1013 {32 * 1024, 1},
1014 {16 * 1024, 1},
1015 {8 * 1024, 1},
1016 {4 * 1024, 2},
1017 },
1018 .block_erase = spi_block_erase_d8,
1019 }, {
1020 .eraseblocks = { {2048 * 1024, 1} },
1021 .block_erase = spi_block_erase_60,
1022 }, {
1023 .eraseblocks = { {2048 * 1024, 1} },
1024 .block_erase = spi_block_erase_c7,
1025 }
1026 },
1027 .printlock = spi_prettyprint_status_register_bp2_srwd,
1028 .unlock = spi_disable_blockprotect,
1029 .write = spi_chip_write_256,
1030 .read = spi_chip_read,
1031 .voltage = {2700, 3600},
1032 },
1033
1034 {
1035 .vendor = "AMIC",
1036 .name = "A25L16PU",
1037 .bustype = BUS_SPI,
1038 .manufacture_id = AMIC_ID,
1039 .model_id = AMIC_A25L16PU,
1040 .total_size = 2048,
1041 .page_size = 256,
1042 .feature_bits = FEATURE_WRSR_WREN,
1043 .tested = TEST_OK_PR,
1044 .probe = probe_spi_rdid4,
1045 .probe_timing = TIMING_ZERO,
1046 .block_erasers =
1047 {
1048 {
1049 .eraseblocks = {
1050 {4 * 1024, 2},
1051 {8 * 1024, 1},
1052 {16 * 1024, 1},
1053 {32 * 1024, 1},
1054 {64 * 1024, 31},
1055 },
1056 .block_erase = spi_block_erase_d8,
1057 }, {
1058 .eraseblocks = { {2048 * 1024, 1} },
1059 .block_erase = spi_block_erase_60,
1060 }, {
1061 .eraseblocks = { {2048 * 1024, 1} },
1062 .block_erase = spi_block_erase_c7,
1063 }
1064 },
1065 .printlock = spi_prettyprint_status_register_bp2_srwd,
1066 .unlock = spi_disable_blockprotect,
1067 .write = spi_chip_write_256,
1068 .read = spi_chip_read,
1069 .voltage = {2700, 3600},
1070 },
1071
1072 {
1073 .vendor = "AMIC",
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001074 .name = "A25L20PT",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001075 .bustype = BUS_SPI,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001076 .manufacture_id = AMIC_ID,
1077 .model_id = AMIC_A25L20PT,
1078 .total_size = 256,
1079 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00001080 .feature_bits = FEATURE_WRSR_WREN,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001081 .tested = TEST_UNTESTED,
1082 .probe = probe_spi_rdid4,
1083 .probe_timing = TIMING_ZERO,
1084 .block_erasers =
1085 {
1086 {
1087 .eraseblocks = {
1088 {64 * 1024, 3},
1089 {32 * 1024, 1},
1090 {16 * 1024, 1},
1091 {8 * 1024, 1},
1092 {4 * 1024, 2},
1093 },
1094 .block_erase = spi_block_erase_d8,
1095 }, {
1096 .eraseblocks = { {256 * 1024, 1} },
1097 .block_erase = spi_block_erase_c7,
1098 }
1099 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00001100 .printlock = spi_prettyprint_status_register_bp1_srwd,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001101 .unlock = spi_disable_blockprotect,
1102 .write = spi_chip_write_256,
1103 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001104 .voltage = {2700, 3600},
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001105 },
1106
1107 {
1108 .vendor = "AMIC",
1109 .name = "A25L20PU",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001110 .bustype = BUS_SPI,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001111 .manufacture_id = AMIC_ID,
1112 .model_id = AMIC_A25L20PU,
1113 .total_size = 256,
1114 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00001115 .feature_bits = FEATURE_WRSR_WREN,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001116 .tested = TEST_UNTESTED,
1117 .probe = probe_spi_rdid4,
1118 .probe_timing = TIMING_ZERO,
1119 .block_erasers =
1120 {
1121 {
1122 .eraseblocks = {
1123 {4 * 1024, 2},
1124 {8 * 1024, 1},
1125 {16 * 1024, 1},
1126 {32 * 1024, 1},
1127 {64 * 1024, 3},
1128 },
1129 .block_erase = spi_block_erase_d8,
1130 }, {
1131 .eraseblocks = { {256 * 1024, 1} },
1132 .block_erase = spi_block_erase_c7,
1133 }
1134 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00001135 .printlock = spi_prettyprint_status_register_bp1_srwd,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001136 .unlock = spi_disable_blockprotect,
1137 .write = spi_chip_write_256,
1138 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001139 .voltage = {2700, 3600},
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001140 },
1141
1142 /* The A25L40P{T,U} chips are distinguished by their
1143 * erase block layouts, but without any distinction in RDID.
1144 * This inexplicable quirk was verified by Rudolf Marek
Nico Huberc3b02dc2023-08-12 01:13:45 +02001145 * and discussed on the flashprog mailing list on 2010-07-12.
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001146 */
1147 {
1148 .vendor = "AMIC",
1149 .name = "A25L40PT",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001150 .bustype = BUS_SPI,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001151 .manufacture_id = AMIC_ID,
1152 .model_id = AMIC_A25L40PT,
1153 .total_size = 512,
1154 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00001155 .feature_bits = FEATURE_WRSR_WREN,
Carl-Daniel Hailfingerf52f7842010-10-08 18:52:29 +00001156 .tested = TEST_OK_PR,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001157 .probe = probe_spi_rdid4,
1158 .probe_timing = TIMING_ZERO,
1159 .block_erasers =
1160 {
1161 {
1162 .eraseblocks = {
1163 {64 * 1024, 7},
1164 {32 * 1024, 1},
1165 {16 * 1024, 1},
1166 {8 * 1024, 1},
1167 {4 * 1024, 2},
1168 },
1169 .block_erase = spi_block_erase_d8,
1170 }, {
1171 .eraseblocks = { {512 * 1024, 1} },
1172 .block_erase = spi_block_erase_c7,
1173 }
1174 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00001175 .printlock = spi_prettyprint_status_register_bp2_srwd,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001176 .unlock = spi_disable_blockprotect,
1177 .write = spi_chip_write_256,
1178 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001179 .voltage = {2700, 3600},
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001180 },
1181
1182 {
1183 .vendor = "AMIC",
1184 .name = "A25L40PU",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001185 .bustype = BUS_SPI,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001186 .manufacture_id = AMIC_ID,
1187 .model_id = AMIC_A25L40PU,
1188 .total_size = 512,
1189 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00001190 .feature_bits = FEATURE_WRSR_WREN,
Angel Pons6f088352018-09-30 19:59:42 +02001191 .tested = TEST_OK_PREW,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001192 .probe = probe_spi_rdid4,
1193 .probe_timing = TIMING_ZERO,
1194 .block_erasers =
1195 {
1196 {
1197 .eraseblocks = {
1198 {4 * 1024, 2},
1199 {8 * 1024, 1},
1200 {16 * 1024, 1},
1201 {32 * 1024, 1},
1202 {64 * 1024, 7},
1203 },
1204 .block_erase = spi_block_erase_d8,
1205 }, {
1206 .eraseblocks = { {512 * 1024, 1} },
1207 .block_erase = spi_block_erase_c7,
1208 }
1209 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00001210 .printlock = spi_prettyprint_status_register_bp2_srwd,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001211 .unlock = spi_disable_blockprotect,
1212 .write = spi_chip_write_256,
1213 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001214 .voltage = {2700, 3600},
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001215 },
1216
1217 {
1218 .vendor = "AMIC",
Alan Green1f9cc7d2019-07-01 11:10:45 +10001219 .name = "A25L512",
1220 .bustype = BUS_SPI,
1221 .manufacture_id = AMIC_ID_NOPREFIX,
1222 .model_id = AMIC_A25L512,
1223 .total_size = 64,
1224 .page_size = 256,
1225 .feature_bits = FEATURE_WRSR_WREN,
1226 .tested = TEST_UNTESTED,
1227 .probe = probe_spi_rdid,
1228 .probe_timing = TIMING_ZERO,
1229 .block_erasers =
1230 {
1231 {
1232 .eraseblocks = { { 4 * 1024, 16 } },
1233 .block_erase = spi_block_erase_20,
1234 }, {
1235 .eraseblocks = { { 64 * 1024, 1 } },
1236 .block_erase = spi_block_erase_d8,
1237 }, {
1238 .eraseblocks = { { 64 * 1024, 1 } },
1239 .block_erase = spi_block_erase_c7,
1240 }
1241 },
1242 .printlock = spi_prettyprint_status_register_bp2_srwd,
1243 .unlock = spi_disable_blockprotect,
1244 .write = spi_chip_write_256,
1245 .read = spi_chip_read,
1246 .voltage = {2700, 3600},
1247 },
1248
1249 {
1250 .vendor = "AMIC",
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001251 .name = "A25L80P",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001252 .bustype = BUS_SPI,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001253 .manufacture_id = AMIC_ID,
1254 .model_id = AMIC_A25L80P,
1255 .total_size = 1024,
1256 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00001257 .feature_bits = FEATURE_WRSR_WREN,
Carl-Daniel Hailfingerf52f7842010-10-08 18:52:29 +00001258 .tested = TEST_OK_PRE,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001259 .probe = probe_spi_rdid4,
1260 .probe_timing = TIMING_ZERO,
1261 .block_erasers =
1262 {
1263 {
1264 .eraseblocks = {
1265 {4 * 1024, 2},
1266 {8 * 1024, 1},
1267 {16 * 1024, 1},
1268 {32 * 1024, 1},
1269 {64 * 1024, 15},
1270 },
1271 .block_erase = spi_block_erase_d8,
1272 }, {
1273 .eraseblocks = { {1024 * 1024, 1} },
1274 .block_erase = spi_block_erase_c7,
1275 }
1276 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00001277 .printlock = spi_prettyprint_status_register_bp2_srwd,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001278 .unlock = spi_disable_blockprotect,
1279 .write = spi_chip_write_256,
1280 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001281 .voltage = {2700, 3600},
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001282 },
1283
1284 {
1285 .vendor = "AMIC",
Alan Green1f9cc7d2019-07-01 11:10:45 +10001286 .name = "A25LQ032/A25LQ32A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001287 .bustype = BUS_SPI,
Dan Lenski11617122010-07-29 15:00:40 +00001288 .manufacture_id = AMIC_ID_NOPREFIX,
Alan Green1f9cc7d2019-07-01 11:10:45 +10001289 .model_id = AMIC_A25LQ032,
Dan Lenski11617122010-07-29 15:00:40 +00001290 .total_size = 4096,
1291 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +10001292 /* A25LQ32A supports SFDP */
Daniel Lenski65922a32012-02-15 23:40:23 +00001293 /* OTP: 64B total; read 0x4B, 0x48; write 0x42 */
1294 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Alan Green1f9cc7d2019-07-01 11:10:45 +10001295 .tested = TEST_UNTESTED,
Dan Lenski11617122010-07-29 15:00:40 +00001296 .probe = probe_spi_rdid,
1297 .probe_timing = TIMING_ZERO,
1298 .block_erasers =
1299 {
1300 {
1301 .eraseblocks = { { 4 * 1024, 1024 } },
1302 .block_erase = spi_block_erase_20,
1303 }, {
1304 .eraseblocks = { { 64 * 1024, 64 } },
1305 .block_erase = spi_block_erase_52,
1306 }, {
1307 .eraseblocks = { { 64 * 1024, 64 } },
1308 .block_erase = spi_block_erase_d8,
1309 }, {
1310 .eraseblocks = { { 4096 * 1024, 1 } },
1311 .block_erase = spi_block_erase_60,
1312 }, {
1313 .eraseblocks = { { 4096 * 1024, 1 } },
1314 .block_erase = spi_block_erase_c7,
Stefan Taunerd7d423b2012-10-20 09:13:16 +00001315 }
Dan Lenski11617122010-07-29 15:00:40 +00001316 },
Nikolay Nikolaevd07fde62013-06-28 21:29:21 +00001317 .printlock = spi_prettyprint_status_register_amic_a25l032, /* bit5: T/B, bit6: prot size */
1318 .unlock = spi_disable_blockprotect_bp2_srwd, /* TODO: 2nd status reg (read with 0x35) */
Dan Lenski11617122010-07-29 15:00:40 +00001319 .write = spi_chip_write_256,
1320 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001321 .voltage = {2700, 3600},
Dan Lenski11617122010-07-29 15:00:40 +00001322 },
1323
1324 {
1325 .vendor = "AMIC",
Nikolay Nikolaevd07fde62013-06-28 21:29:21 +00001326 .name = "A25LQ16",
1327 .bustype = BUS_SPI,
1328 .manufacture_id = AMIC_ID_NOPREFIX,
1329 .model_id = AMIC_A25LQ16,
1330 .total_size = 2048,
1331 .page_size = 256,
1332 /* supports SFDP */
1333 /* OTP: 64B total; read 0x4B, 0x48; write 0x42 */
1334 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
1335 .tested = TEST_UNTESTED,
1336 .probe = probe_spi_rdid,
1337 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +10001338 .block_erasers =
1339 {
Nikolay Nikolaevd07fde62013-06-28 21:29:21 +00001340 {
1341 .eraseblocks = { { 4 * 1024, 512 } },
1342 .block_erase = spi_block_erase_20,
1343 }, {
1344 .eraseblocks = { { 64 * 1024, 32 } },
1345 .block_erase = spi_block_erase_52,
1346 }, {
1347 .eraseblocks = { { 64 * 1024, 32 } },
1348 .block_erase = spi_block_erase_d8,
1349 }, {
1350 .eraseblocks = { { 2048 * 1024, 1 } },
1351 .block_erase = spi_block_erase_60,
1352 }, {
1353 .eraseblocks = { { 2048 * 1024, 1 } },
1354 .block_erase = spi_block_erase_c7,
1355 }
1356 },
1357 .printlock = spi_prettyprint_status_register_amic_a25l032, /* bit5: T/B, bit6: prot size */
1358 .unlock = spi_disable_blockprotect_bp2_srwd, /* TODO: 2nd status reg (read with 0x35) */
1359 .write = spi_chip_write_256,
1360 .read = spi_chip_read,
1361 .voltage = {2700, 3600},
1362 },
1363
1364 {
1365 .vendor = "AMIC",
Nikolay Nikolaevd07fde62013-06-28 21:29:21 +00001366 .name = "A25LQ64",
1367 .bustype = BUS_SPI,
1368 .manufacture_id = AMIC_ID_NOPREFIX,
Stefan Tauner23e10b82016-01-23 16:16:49 +00001369 .model_id = AMIC_A25LQ64,
Nikolay Nikolaevd07fde62013-06-28 21:29:21 +00001370 .total_size = 8192,
1371 .page_size = 256,
1372 /* supports SFDP */
1373 /* OTP: 512B total; enter 0xB1, exit 0xC1 */
Nico Huber1412d9f2024-01-06 18:25:49 +01001374 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP |
1375 FEATURE_FAST_READ | FEATURE_FAST_READ_DOUT |
1376 FEATURE_FAST_READ_DIO | FEATURE_FAST_READ_QIO |
1377 FEATURE_QPI_35_F5,
1378 .dummy_cycles =
1379 {
1380 .qpi_fast_read = 4,
1381 .qpi_fast_read_qio = 6,
1382 },
Nikolay Nikolaevd07fde62013-06-28 21:29:21 +00001383 .tested = TEST_UNTESTED,
1384 .probe = probe_spi_rdid,
1385 .probe_timing = TIMING_ZERO,
1386 .block_erasers =
1387 {
1388 {
1389 .eraseblocks = { { 4 * 1024, 2048 } },
1390 .block_erase = spi_block_erase_20,
1391 }, {
1392 .eraseblocks = { { 32 * 1024, 256 } },
1393 .block_erase = spi_block_erase_52,
1394 }, {
1395 .eraseblocks = { { 64 * 1024, 128 } },
1396 .block_erase = spi_block_erase_d8,
1397 }, {
1398 .eraseblocks = { { 8192 * 1024, 1 } },
1399 .block_erase = spi_block_erase_60,
1400 }, {
1401 .eraseblocks = { { 8192 * 1024, 1 } },
1402 .block_erase = spi_block_erase_c7,
1403 }
1404 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00001405 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enhance (sic!) */
Stefan Tauner5c316f92015-02-08 21:57:52 +00001406 .unlock = spi_disable_blockprotect_bp3_srwd,
Dan Lenski11617122010-07-29 15:00:40 +00001407 .write = spi_chip_write_256,
1408 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001409 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02001410 .prepare_access = spi_prepare_io,
1411 .finish_access = spi_finish_io,
Dan Lenski11617122010-07-29 15:00:40 +00001412 },
1413
1414 {
1415 .vendor = "AMIC",
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001416 .name = "A29002B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001417 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001418 .manufacture_id = AMIC_ID_NOPREFIX,
1419 .model_id = AMIC_A29002B,
1420 .total_size = 256,
1421 .page_size = 64 * 1024,
1422 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
1423 .tested = TEST_UNTESTED,
1424 .probe = probe_jedec,
David Borg204f4652010-12-04 03:26:40 +00001425 .probe_timing = TIMING_ZERO,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001426 .block_erasers =
1427 {
1428 {
Stefan Tauner0554ca52013-07-25 22:54:25 +00001429 .eraseblocks = {
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001430 {16 * 1024, 1},
1431 {8 * 1024, 2},
1432 {32 * 1024, 1},
1433 {64 * 1024, 3},
1434 },
1435 .block_erase = erase_sector_jedec,
1436 }, {
1437 .eraseblocks = { {256 * 1024, 1} },
1438 .block_erase = erase_chip_block_jedec,
1439 },
1440 },
1441 .write = write_jedec_1,
1442 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001443 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01001444 .prepare_access = prepare_memory_access,
1445 .finish_access = finish_memory_access,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001446 },
1447
1448 {
1449 .vendor = "AMIC",
1450 .name = "A29002T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001451 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001452 .manufacture_id = AMIC_ID_NOPREFIX,
1453 .model_id = AMIC_A29002T,
1454 .total_size = 256,
1455 .page_size = 64 * 1024,
1456 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
Paul Menzel018d4822011-10-21 12:33:07 +00001457 .tested = TEST_OK_PREW,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001458 .probe = probe_jedec,
David Borg204f4652010-12-04 03:26:40 +00001459 .probe_timing = TIMING_ZERO,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001460 .block_erasers =
1461 {
1462 {
Stefan Tauner0554ca52013-07-25 22:54:25 +00001463 .eraseblocks = {
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001464 {64 * 1024, 3},
1465 {32 * 1024, 1},
1466 {8 * 1024, 2},
1467 {16 * 1024, 1},
1468 },
1469 .block_erase = erase_sector_jedec,
1470 }, {
1471 .eraseblocks = { {256 * 1024, 1} },
1472 .block_erase = erase_chip_block_jedec,
1473 },
1474 },
1475 .write = write_jedec_1,
1476 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001477 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01001478 .prepare_access = prepare_memory_access,
1479 .finish_access = finish_memory_access,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001480 },
1481
1482 {
1483 .vendor = "AMIC",
1484 .name = "A29040B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001485 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001486 .manufacture_id = AMIC_ID_NOPREFIX,
1487 .model_id = AMIC_A29040B,
1488 .total_size = 512,
1489 .page_size = 64 * 1024,
1490 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
Corey Osgoodcbd56652013-09-10 10:42:48 +00001491 .tested = TEST_OK_PREW,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001492 .probe = probe_jedec,
David Borg204f4652010-12-04 03:26:40 +00001493 .probe_timing = TIMING_ZERO,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001494 .block_erasers =
1495 {
1496 {
1497 .eraseblocks = { {64 * 1024, 8} },
1498 .block_erase = erase_sector_jedec,
1499 }, {
1500 .eraseblocks = { {512 * 1024, 1} },
1501 .block_erase = erase_chip_block_jedec,
1502 },
1503 },
1504 .write = write_jedec_1,
1505 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001506 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01001507 .prepare_access = prepare_memory_access,
1508 .finish_access = finish_memory_access,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001509 },
1510
1511 {
1512 .vendor = "AMIC",
1513 .name = "A49LF040A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001514 .bustype = BUS_LPC,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001515 .manufacture_id = AMIC_ID_NOPREFIX,
1516 .model_id = AMIC_A49LF040A,
1517 .total_size = 512,
1518 .page_size = 64 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +01001519 .feature_bits = FEATURE_EITHER_RESET,
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +00001520 .tested = TEST_OK_PR,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001521 .probe = probe_jedec,
1522 .probe_timing = TIMING_ZERO, /* routine is wrapper to probe_jedec (pm49fl00x.c) */
1523 .block_erasers =
1524 {
1525 {
1526 .eraseblocks = { {64 * 1024, 8} },
1527 .block_erase = erase_block_jedec,
1528 }, {
1529 .eraseblocks = { {512 * 1024, 1} },
1530 .block_erase = erase_chip_block_jedec,
1531 }
1532 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +00001533 .unlock = unlock_regspace2_uniform_64k,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001534 .write = write_jedec_1,
1535 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001536 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +01001537 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +01001538 .finish_access = finish_memory_access,
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00001539 },
1540
1541 {
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001542 .vendor = "Atmel",
1543 .name = "AT25DF021",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001544 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001545 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00001546 .model_id = ATMEL_AT25DF021,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001547 .total_size = 256,
1548 .page_size = 256,
Daniel Lenski65922a32012-02-15 23:40:23 +00001549 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
1550 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001551 .tested = TEST_UNTESTED,
1552 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00001553 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00001554 .block_erasers =
1555 {
1556 {
1557 .eraseblocks = { {4 * 1024, 64} },
1558 .block_erase = spi_block_erase_20,
1559 }, {
1560 .eraseblocks = { {32 * 1024, 8} },
1561 .block_erase = spi_block_erase_52,
1562 }, {
1563 .eraseblocks = { {64 * 1024, 4} },
1564 .block_erase = spi_block_erase_d8,
1565 }, {
1566 .eraseblocks = { {256 * 1024, 1} },
1567 .block_erase = spi_block_erase_60,
1568 }, {
1569 .eraseblocks = { {256 * 1024, 1} },
1570 .block_erase = spi_block_erase_c7,
1571 }
1572 },
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001573 .printlock = spi_prettyprint_status_register_at25df,
Stefan Taunercecb2c52013-06-20 22:55:41 +00001574 .unlock = spi_disable_blockprotect_at2x_global_unprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00001575 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001576 .read = spi_chip_read,
Steven Zakulec7d257b42011-07-19 08:50:18 +00001577 .voltage = {2700, 3600}, /* 2.3-3.6V & 2.7-3.6V models available */
FENG yu ningff692fb2008-12-08 18:15:10 +00001578 },
1579
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001580 {
1581 .vendor = "Atmel",
Steffen Mauch0b59b0d2018-06-02 23:46:03 +02001582 .name = "AT25DF021A",
1583 .bustype = BUS_SPI,
1584 .manufacture_id = ATMEL_ID,
1585 .model_id = ATMEL_AT25DF021A,
1586 .total_size = 256,
1587 .page_size = 256,
1588 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
1589 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
1590 .tested = TEST_OK_PREW,
1591 .probe = probe_spi_rdid,
1592 .probe_timing = TIMING_ZERO,
1593 .block_erasers =
1594 {
1595 {
1596 .eraseblocks = { {4 * 1024, 64} },
1597 .block_erase = spi_block_erase_20,
1598 }, {
1599 .eraseblocks = { {32 * 1024, 8} },
1600 .block_erase = spi_block_erase_52,
1601 }, {
1602 .eraseblocks = { {64 * 1024, 4} },
1603 .block_erase = spi_block_erase_d8,
1604 }, {
1605 .eraseblocks = { {256 * 1024, 1} },
1606 .block_erase = spi_block_erase_60,
1607 }, {
1608 .eraseblocks = { {256 * 1024, 1} },
1609 .block_erase = spi_block_erase_c7,
1610 }
1611 },
1612 .printlock = spi_prettyprint_status_register_at25df,
1613 .unlock = spi_disable_blockprotect_at2x_global_unprotect,
1614 .write = spi_chip_write_256,
1615 .read = spi_chip_read,
1616 .voltage = {1650, 3600},
1617 },
1618
1619 {
1620 .vendor = "Atmel",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001621 .name = "AT25DF041A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001622 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001623 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00001624 .model_id = ATMEL_AT25DF041A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001625 .total_size = 512,
1626 .page_size = 256,
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001627 .feature_bits = FEATURE_WRSR_WREN,
Stefan Tauner5c316f92015-02-08 21:57:52 +00001628 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001629 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00001630 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00001631 .block_erasers =
1632 {
1633 {
1634 .eraseblocks = { {4 * 1024, 128} },
1635 .block_erase = spi_block_erase_20,
1636 }, {
1637 .eraseblocks = { {32 * 1024, 16} },
1638 .block_erase = spi_block_erase_52,
1639 }, {
1640 .eraseblocks = { {64 * 1024, 8} },
1641 .block_erase = spi_block_erase_d8,
1642 }, {
1643 .eraseblocks = { {512 * 1024, 1} },
1644 .block_erase = spi_block_erase_60,
1645 }, {
1646 .eraseblocks = { {512 * 1024, 1} },
1647 .block_erase = spi_block_erase_c7,
1648 }
1649 },
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001650 .printlock = spi_prettyprint_status_register_at25df,
Stefan Taunercecb2c52013-06-20 22:55:41 +00001651 .unlock = spi_disable_blockprotect_at2x_global_unprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00001652 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001653 .read = spi_chip_read,
Steven Zakulec7d257b42011-07-19 08:50:18 +00001654 .voltage = {2700, 3600}, /* 2.3-3.6V & 2.7-3.6V models available */
FENG yu ningff692fb2008-12-08 18:15:10 +00001655 },
1656
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001657 {
1658 .vendor = "Atmel",
1659 .name = "AT25DF081",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001660 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001661 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00001662 .model_id = ATMEL_AT25DF081,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001663 .total_size = 1024,
1664 .page_size = 256,
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001665 .feature_bits = FEATURE_WRSR_WREN,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001666 .tested = TEST_UNTESTED,
1667 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00001668 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00001669 .block_erasers =
1670 {
1671 {
1672 .eraseblocks = { {4 * 1024, 256} },
1673 .block_erase = spi_block_erase_20,
1674 }, {
1675 .eraseblocks = { {32 * 1024, 32} },
1676 .block_erase = spi_block_erase_52,
1677 }, {
1678 .eraseblocks = { {64 * 1024, 16} },
1679 .block_erase = spi_block_erase_d8,
1680 }, {
1681 .eraseblocks = { {1024 * 1024, 1} },
1682 .block_erase = spi_block_erase_60,
1683 }, {
1684 .eraseblocks = { {1024 * 1024, 1} },
1685 .block_erase = spi_block_erase_c7,
1686 }
1687 },
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001688 .printlock = spi_prettyprint_status_register_at25df,
Stefan Taunercecb2c52013-06-20 22:55:41 +00001689 .unlock = spi_disable_blockprotect_at2x_global_unprotect,
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001690 .write = spi_chip_write_256,
1691 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001692 .voltage = {1600, 2000}, /* Datasheet says range is 1.65-1.95 V */
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001693 },
1694
1695 {
1696 .vendor = "Atmel",
1697 .name = "AT25DF081A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001698 .bustype = BUS_SPI,
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001699 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00001700 .model_id = ATMEL_AT25DF081A,
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001701 .total_size = 1024,
1702 .page_size = 256,
1703 .feature_bits = FEATURE_WRSR_WREN,
1704 .tested = TEST_UNTESTED,
1705 .probe = probe_spi_rdid,
1706 .probe_timing = TIMING_ZERO,
1707 .block_erasers =
1708 {
1709 {
1710 .eraseblocks = { {4 * 1024, 256} },
1711 .block_erase = spi_block_erase_20,
1712 }, {
1713 .eraseblocks = { {32 * 1024, 32} },
1714 .block_erase = spi_block_erase_52,
1715 }, {
1716 .eraseblocks = { {64 * 1024, 16} },
1717 .block_erase = spi_block_erase_d8,
1718 }, {
1719 .eraseblocks = { {1024 * 1024, 1} },
1720 .block_erase = spi_block_erase_60,
1721 }, {
1722 .eraseblocks = { {1024 * 1024, 1} },
1723 .block_erase = spi_block_erase_c7,
1724 }
1725 },
1726 .printlock = spi_prettyprint_status_register_at25df_sec,
Stefan Taunercecb2c52013-06-20 22:55:41 +00001727 .unlock = spi_disable_blockprotect_at2x_global_unprotect_sec,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00001728 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001729 .read = spi_chip_read,
Steven Zakulec7d257b42011-07-19 08:50:18 +00001730 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00001731 },
1732
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001733 {
1734 .vendor = "Atmel",
1735 .name = "AT25DF161",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001736 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001737 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00001738 .model_id = ATMEL_AT25DF161,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001739 .total_size = 2048,
1740 .page_size = 256,
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001741 .feature_bits = FEATURE_WRSR_WREN,
Angel Pons8b5b9622018-09-30 19:13:15 +02001742 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001743 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00001744 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00001745 .block_erasers =
1746 {
1747 {
1748 .eraseblocks = { {4 * 1024, 512} },
1749 .block_erase = spi_block_erase_20,
1750 }, {
1751 .eraseblocks = { {32 * 1024, 64} },
1752 .block_erase = spi_block_erase_52,
1753 }, {
1754 .eraseblocks = { {64 * 1024, 32} },
1755 .block_erase = spi_block_erase_d8,
1756 }, {
1757 .eraseblocks = { {2 * 1024 * 1024, 1} },
1758 .block_erase = spi_block_erase_60,
1759 }, {
1760 .eraseblocks = { {2 * 1024 * 1024, 1} },
1761 .block_erase = spi_block_erase_c7,
1762 }
1763 },
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001764 .printlock = spi_prettyprint_status_register_at25df_sec,
Stefan Taunercecb2c52013-06-20 22:55:41 +00001765 .unlock = spi_disable_blockprotect_at2x_global_unprotect_sec,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00001766 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001767 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001768 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00001769 },
1770
Alan Green86bf6ab2019-06-27 16:58:20 +10001771 /*The AT26DF321 has the same ID as the AT25DF321. */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001772 {
1773 .vendor = "Atmel",
1774 .name = "AT25DF321",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001775 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001776 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00001777 .model_id = ATMEL_AT25DF321,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001778 .total_size = 4096,
1779 .page_size = 256,
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001780 .feature_bits = FEATURE_WRSR_WREN,
Stefan Taunerd06d9412011-06-12 19:47:55 +00001781 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001782 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00001783 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00001784 .block_erasers =
1785 {
1786 {
1787 .eraseblocks = { {4 * 1024, 1024} },
1788 .block_erase = spi_block_erase_20,
1789 }, {
1790 .eraseblocks = { {32 * 1024, 128} },
1791 .block_erase = spi_block_erase_52,
1792 }, {
1793 .eraseblocks = { {64 * 1024, 64} },
1794 .block_erase = spi_block_erase_d8,
1795 }, {
1796 .eraseblocks = { {4 * 1024 * 1024, 1} },
1797 .block_erase = spi_block_erase_60,
1798 }, {
1799 .eraseblocks = { {4 * 1024 * 1024, 1} },
1800 .block_erase = spi_block_erase_c7,
1801 }
1802 },
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001803 .printlock = spi_prettyprint_status_register_at25df,
Stefan Taunercecb2c52013-06-20 22:55:41 +00001804 .unlock = spi_disable_blockprotect_at2x_global_unprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00001805 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001806 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001807 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00001808 },
1809
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001810 {
1811 .vendor = "Atmel",
1812 .name = "AT25DF321A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001813 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001814 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00001815 .model_id = ATMEL_AT25DF321A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001816 .total_size = 4096,
1817 .page_size = 256,
Daniel Lenski65922a32012-02-15 23:40:23 +00001818 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
1819 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Stefan Taunerd94d25d2012-07-28 03:17:15 +00001820 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001821 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00001822 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00001823 .block_erasers =
1824 {
1825 {
1826 .eraseblocks = { {4 * 1024, 1024} },
1827 .block_erase = spi_block_erase_20,
1828 }, {
1829 .eraseblocks = { {32 * 1024, 128} },
1830 .block_erase = spi_block_erase_52,
1831 }, {
1832 .eraseblocks = { {64 * 1024, 64} },
1833 .block_erase = spi_block_erase_d8,
1834 }, {
1835 .eraseblocks = { {4 * 1024 * 1024, 1} },
1836 .block_erase = spi_block_erase_60,
1837 }, {
1838 .eraseblocks = { {4 * 1024 * 1024, 1} },
1839 .block_erase = spi_block_erase_c7,
1840 }
1841 },
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001842 .printlock = spi_prettyprint_status_register_at25df_sec,
Stefan Taunercecb2c52013-06-20 22:55:41 +00001843 .unlock = spi_disable_blockprotect_at2x_global_unprotect_sec,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00001844 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001845 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001846 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00001847 },
1848
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001849 {
1850 .vendor = "Atmel",
Paul Menzelac427b22012-02-16 21:07:07 +00001851 .name = "AT25DF641(A)",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001852 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001853 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00001854 .model_id = ATMEL_AT25DF641,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001855 .total_size = 8192,
1856 .page_size = 256,
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001857 .feature_bits = FEATURE_WRSR_WREN,
Stefan Tauner0554ca52013-07-25 22:54:25 +00001858 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00001859 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00001860 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00001861 .block_erasers =
1862 {
1863 {
1864 .eraseblocks = { {4 * 1024, 2048} },
1865 .block_erase = spi_block_erase_20,
1866 }, {
1867 .eraseblocks = { {32 * 1024, 256} },
1868 .block_erase = spi_block_erase_52,
1869 }, {
1870 .eraseblocks = { {64 * 1024, 128} },
1871 .block_erase = spi_block_erase_d8,
1872 }, {
1873 .eraseblocks = { {8 * 1024 * 1024, 1} },
1874 .block_erase = spi_block_erase_60,
1875 }, {
1876 .eraseblocks = { {8 * 1024 * 1024, 1} },
1877 .block_erase = spi_block_erase_c7,
1878 }
1879 },
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001880 .printlock = spi_prettyprint_status_register_at25df_sec,
Stefan Taunercecb2c52013-06-20 22:55:41 +00001881 .unlock = spi_disable_blockprotect_at2x_global_unprotect_sec,
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001882 .write = spi_chip_write_256,
1883 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00001884 .voltage = {2700, 3600},
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001885 },
1886
1887 {
1888 .vendor = "Atmel",
Stefan Taunerc9d8b272014-06-01 13:22:35 +00001889 .name = "AT25DL081",
1890 .bustype = BUS_SPI,
Alan Greenfa3fcd32019-06-27 15:41:50 +10001891 .manufacture_id = ATMEL_ID,
Stefan Taunerc9d8b272014-06-01 13:22:35 +00001892 .model_id = ATMEL_AT25DF081,
1893 .total_size = 1024,
1894 .page_size = 256,
1895 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
1896 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
1897 .tested = TEST_UNTESTED,
1898 .probe = probe_spi_rdid,
1899 .probe_timing = TIMING_ZERO,
1900 .block_erasers =
1901 {
1902 {
1903 .eraseblocks = { {4 * 1024, 256} },
1904 .block_erase = spi_block_erase_20,
1905 }, {
1906 .eraseblocks = { {32 * 1024, 32} },
1907 .block_erase = spi_block_erase_52,
1908 }, {
1909 .eraseblocks = { {64 * 1024, 16} },
1910 .block_erase = spi_block_erase_d8,
1911 }, {
1912 .eraseblocks = { {1 * 1024 * 1024, 1} },
1913 .block_erase = spi_block_erase_60,
1914 }, {
1915 .eraseblocks = { {1 * 1024 * 1024, 1} },
1916 .block_erase = spi_block_erase_c7,
1917 }
1918 },
1919 .printlock = spi_prettyprint_status_register_at25df_sec,
1920 .unlock = spi_disable_blockprotect_at2x_global_unprotect_sec,
1921 .write = spi_chip_write_256, /* Dual I/O (0xA2) supported */
1922 .read = spi_chip_read, /* Fast read (0x0B), dual I/O (0x3B) supported */
1923 .voltage = {1650, 1950},
1924 },
1925
1926 {
1927 .vendor = "Atmel",
1928 .name = "AT25DL161",
1929 .bustype = BUS_SPI,
Alan Greenfa3fcd32019-06-27 15:41:50 +10001930 .manufacture_id = ATMEL_ID,
Stefan Taunerc9d8b272014-06-01 13:22:35 +00001931 .model_id = ATMEL_AT25DL161,
1932 .total_size = 2048,
1933 .page_size = 256,
1934 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
1935 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
1936 .tested = TEST_UNTESTED,
1937 .probe = probe_spi_rdid,
1938 .probe_timing = TIMING_ZERO,
1939 .block_erasers =
1940 {
1941 {
1942 .eraseblocks = { {4 * 1024, 512} },
1943 .block_erase = spi_block_erase_20,
1944 }, {
1945 .eraseblocks = { {32 * 1024, 64} },
1946 .block_erase = spi_block_erase_52,
1947 }, {
1948 .eraseblocks = { {64 * 1024, 32} },
1949 .block_erase = spi_block_erase_d8,
1950 }, {
1951 .eraseblocks = { {2 * 1024 * 1024, 1} },
1952 .block_erase = spi_block_erase_60,
1953 }, {
1954 .eraseblocks = { {2 * 1024 * 1024, 1} },
1955 .block_erase = spi_block_erase_c7,
1956 }
1957 },
1958 .printlock = spi_prettyprint_status_register_at25df_sec,
1959 .unlock = spi_disable_blockprotect_at2x_global_unprotect_sec,
1960 .write = spi_chip_write_256, /* Dual I/O (0xA2) supported */
1961 .read = spi_chip_read, /* Fast read (0x0B), dual I/O (0x3B) supported */
1962 .voltage = {1650, 1950},
1963 },
1964
1965 {
1966 .vendor = "Atmel",
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001967 .name = "AT25DQ161",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00001968 .bustype = BUS_SPI,
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001969 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00001970 .model_id = ATMEL_AT25DQ161,
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001971 .total_size = 2048,
1972 .page_size = 256,
Daniel Lenski65922a32012-02-15 23:40:23 +00001973 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
1974 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00001975 .tested = TEST_UNTESTED,
1976 .probe = probe_spi_rdid,
1977 .probe_timing = TIMING_ZERO,
1978 .block_erasers =
1979 {
1980 {
1981 .eraseblocks = { {4 * 1024, 512} },
1982 .block_erase = spi_block_erase_20,
1983 }, {
1984 .eraseblocks = { {32 * 1024, 64} },
1985 .block_erase = spi_block_erase_52,
1986 }, {
1987 .eraseblocks = { {64 * 1024, 32} },
1988 .block_erase = spi_block_erase_d8,
1989 }, {
1990 .eraseblocks = { {2 * 1024 * 1024, 1} },
1991 .block_erase = spi_block_erase_60,
1992 }, {
1993 .eraseblocks = { {2 * 1024 * 1024, 1} },
1994 .block_erase = spi_block_erase_c7,
1995 }
1996 },
1997 .printlock = spi_prettyprint_status_register_at25df_sec,
Stefan Taunercecb2c52013-06-20 22:55:41 +00001998 .unlock = spi_disable_blockprotect_at2x_global_unprotect_sec,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00001999 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002000 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002001 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00002002 },
2003
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002004 {
2005 .vendor = "Atmel",
Alan Green1f9cc7d2019-07-01 11:10:45 +10002006 /* The A suffix indicates 33MHz instead of 20MHz clock rate.
2007 * All other properties seem to be the same.*/
2008 .name = "AT25F1024(A)",
2009 .bustype = BUS_SPI,
2010 .manufacture_id = ATMEL_ID,
2011 .model_id = ATMEL_AT25F1024,
2012 .total_size = 128,
2013 .page_size = 256,
2014 .feature_bits = FEATURE_WRSR_WREN,
2015 .tested = TEST_OK_PREW,
2016 .probe = probe_spi_at25f,
2017 .probe_timing = TIMING_ZERO,
2018 .block_erasers =
2019 {
2020 {
2021 .eraseblocks = { {32 * 1024, 4} },
2022 .block_erase = spi_block_erase_52,
2023 }, {
2024 .eraseblocks = { {128 * 1024, 1} },
2025 .block_erase = spi_block_erase_62,
2026 }
2027 },
2028 .printlock = spi_prettyprint_status_register_at25f,
2029 .unlock = spi_disable_blockprotect_at25f,
2030 .write = spi_chip_write_256,
2031 .read = spi_chip_read,
2032 .voltage = {2700, 3600},
2033 },
2034
2035 {
2036 .vendor = "Atmel",
2037 .name = "AT25F2048",
2038 .bustype = BUS_SPI,
2039 .manufacture_id = ATMEL_ID,
2040 .model_id = ATMEL_AT25F2048,
2041 .total_size = 256,
2042 .page_size = 256,
2043 .feature_bits = FEATURE_WRSR_WREN,
2044 .tested = TEST_UNTESTED,
2045 .probe = probe_spi_at25f,
2046 .probe_timing = TIMING_ZERO,
2047 .block_erasers =
2048 {
2049 {
2050 .eraseblocks = { {64 * 1024, 4} },
2051 .block_erase = spi_block_erase_52,
2052 }, {
2053 .eraseblocks = { {256 * 1024, 1} },
2054 .block_erase = spi_block_erase_62,
2055 }
2056 },
2057 .printlock = spi_prettyprint_status_register_at25f,
2058 .unlock = spi_disable_blockprotect_at25f,
2059 .write = spi_chip_write_256,
2060 .read = spi_chip_read,
2061 .voltage = {2700, 3600},
2062 },
2063
2064 {
2065 .vendor = "Atmel",
2066 .name = "AT25F4096",
2067 .bustype = BUS_SPI,
2068 .manufacture_id = ATMEL_ID,
2069 .model_id = ATMEL_AT25F4096,
2070 .total_size = 512,
2071 .page_size = 256,
2072 .feature_bits = FEATURE_WRSR_WREN,
2073 .tested = TEST_OK_PREW,
2074 .probe = probe_spi_at25f,
2075 .probe_timing = TIMING_ZERO,
2076 .block_erasers =
2077 {
2078 {
2079 .eraseblocks = { {64 * 1024, 8} },
2080 .block_erase = spi_block_erase_52,
2081 }, {
2082 .eraseblocks = { {512 * 1024, 1} },
2083 .block_erase = spi_block_erase_62,
2084 }
2085 },
2086 .printlock = spi_prettyprint_status_register_at25f4096,
2087 /* "Bits 5-6 are 0s when device is not in an internal write cycle." Better leave them alone: */
2088 .unlock = spi_disable_blockprotect_bp2_srwd,
2089 .write = spi_chip_write_256,
2090 .read = spi_chip_read,
2091 .voltage = {2700, 3600},
2092 },
2093
2094 {
2095 .vendor = "Atmel",
Stefan Tauner57794ac2012-12-29 15:04:20 +00002096 .name = "AT25F512",
2097 .bustype = BUS_SPI,
2098 .manufacture_id = ATMEL_ID,
2099 .model_id = ATMEL_AT25F512,
2100 .total_size = 64,
2101 .page_size = 256,
2102 .feature_bits = FEATURE_WRSR_WREN,
Stefan Tauner0554ca52013-07-25 22:54:25 +00002103 .tested = TEST_OK_PREW,
Stefan Tauner57794ac2012-12-29 15:04:20 +00002104 .probe = probe_spi_at25f,
2105 .probe_timing = TIMING_ZERO,
2106 .block_erasers =
2107 {
2108 {
2109 .eraseblocks = { {32 * 1024, 2} },
2110 .block_erase = spi_block_erase_52,
2111 }, {
2112 .eraseblocks = { {64 * 1024, 1} },
2113 .block_erase = spi_block_erase_62,
2114 }
2115 },
2116 .printlock = spi_prettyprint_status_register_at25f,
2117 .unlock = spi_disable_blockprotect_at25f,
2118 .write = spi_chip_write_256,
2119 .read = spi_chip_read,
2120 .voltage = {2700, 3600},
2121 },
2122
2123 {
2124 .vendor = "Atmel",
2125 .name = "AT25F512A",
2126 .bustype = BUS_SPI,
2127 .manufacture_id = ATMEL_ID,
2128 .model_id = ATMEL_AT25F512A,
2129 .total_size = 64,
2130 .page_size = 128,
2131 .feature_bits = FEATURE_WRSR_WREN,
Stefan Tauner0554ca52013-07-25 22:54:25 +00002132 .tested = TEST_OK_PREW,
Stefan Tauner57794ac2012-12-29 15:04:20 +00002133 .probe = probe_spi_at25f,
2134 .probe_timing = TIMING_ZERO,
2135 .block_erasers =
2136 {
2137 {
2138 .eraseblocks = { {32 * 1024, 2} },
2139 .block_erase = spi_block_erase_52,
2140 }, {
2141 .eraseblocks = { {64 * 1024, 1} },
2142 .block_erase = spi_block_erase_62,
2143 }
2144 },
2145 .printlock = spi_prettyprint_status_register_at25f512a,
2146 /* FIXME: It is not correct to use this one, because the BP1 bit is N/A. */
2147 .unlock = spi_disable_blockprotect_at25f512a,
2148 .write = spi_chip_write_256,
2149 .read = spi_chip_read,
2150 .voltage = {2700, 3600},
2151 },
2152
2153 {
2154 .vendor = "Atmel",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002155 .name = "AT25F512B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002156 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002157 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002158 .model_id = ATMEL_AT25F512B,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002159 .total_size = 64,
2160 .page_size = 256,
Daniel Lenski65922a32012-02-15 23:40:23 +00002161 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
2162 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002163 .tested = TEST_UNTESTED,
2164 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002165 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00002166 .block_erasers =
2167 {
2168 {
2169 .eraseblocks = { {4 * 1024, 16} },
2170 .block_erase = spi_block_erase_20,
2171 }, {
2172 .eraseblocks = { {32 * 1024, 2} },
2173 .block_erase = spi_block_erase_52,
2174 }, {
2175 .eraseblocks = { {32 * 1024, 2} },
2176 .block_erase = spi_block_erase_d8,
2177 }, {
2178 .eraseblocks = { {64 * 1024, 1} },
2179 .block_erase = spi_block_erase_60,
2180 }, {
2181 .eraseblocks = { {64 * 1024, 1} },
2182 .block_erase = spi_block_erase_c7,
Stefan Tauner3c0fcd02012-09-21 12:46:56 +00002183 }, {
2184 .eraseblocks = { {64 * 1024, 1} },
2185 .block_erase = spi_block_erase_62,
Sean Nelson89187292009-12-23 12:02:55 +00002186 }
2187 },
Stefan Tauner7bf4ed92012-08-26 21:04:27 +00002188 .printlock = spi_prettyprint_status_register_at25f512b,
2189 .unlock = spi_disable_blockprotect_at25f512b,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00002190 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002191 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002192 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00002193 },
2194
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002195 {
2196 .vendor = "Atmel",
2197 .name = "AT25FS010",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002198 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002199 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002200 .model_id = ATMEL_AT25FS010,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002201 .total_size = 128,
2202 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00002203 .feature_bits = FEATURE_WRSR_WREN,
Stefan Taunere34e3e82013-01-01 00:06:51 +00002204 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002205 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002206 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00002207 .block_erasers =
2208 {
2209 {
2210 .eraseblocks = { {4 * 1024, 32} },
2211 .block_erase = spi_block_erase_20,
2212 }, {
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00002213 .eraseblocks = { {4 * 1024, 32} },
2214 .block_erase = spi_block_erase_d7,
2215 }, {
Sean Nelson89187292009-12-23 12:02:55 +00002216 .eraseblocks = { {32 * 1024, 4} },
2217 .block_erase = spi_block_erase_52,
2218 }, {
2219 .eraseblocks = { {32 * 1024, 4} },
2220 .block_erase = spi_block_erase_d8,
2221 }, {
2222 .eraseblocks = { {128 * 1024, 1} },
2223 .block_erase = spi_block_erase_60,
2224 }, {
2225 .eraseblocks = { {128 * 1024, 1} },
2226 .block_erase = spi_block_erase_c7,
2227 }
2228 },
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00002229 .printlock = spi_prettyprint_status_register_at25fs010,
2230 .unlock = spi_disable_blockprotect_at25fs010,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00002231 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002232 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002233 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00002234 },
2235
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002236 {
2237 .vendor = "Atmel",
2238 .name = "AT25FS040",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002239 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002240 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002241 .model_id = ATMEL_AT25FS040,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002242 .total_size = 512,
2243 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00002244 .feature_bits = FEATURE_WRSR_WREN,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002245 .tested = TEST_UNTESTED,
2246 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002247 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00002248 .block_erasers =
2249 {
2250 {
2251 .eraseblocks = { {4 * 1024, 128} },
2252 .block_erase = spi_block_erase_20,
2253 }, {
2254 .eraseblocks = { {64 * 1024, 8} },
2255 .block_erase = spi_block_erase_52,
2256 }, {
2257 .eraseblocks = { {64 * 1024, 8} },
2258 .block_erase = spi_block_erase_d8,
2259 }, {
2260 .eraseblocks = { {512 * 1024, 1} },
2261 .block_erase = spi_block_erase_60,
2262 }, {
2263 .eraseblocks = { {512 * 1024, 1} },
2264 .block_erase = spi_block_erase_c7,
2265 }
2266 },
Carl-Daniel Hailfingerfd7075a2010-07-29 13:09:18 +00002267 .printlock = spi_prettyprint_status_register_at25fs040,
2268 .unlock = spi_disable_blockprotect_at25fs040,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00002269 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002270 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002271 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00002272 },
2273
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002274 {
2275 .vendor = "Atmel",
jvma3ab6c62018-03-08 15:43:20 +01002276 .name = "AT25SF041",
2277 .bustype = BUS_SPI,
2278 .manufacture_id = ATMEL_ID,
2279 .model_id = ATMEL_AT25SF041,
2280 .total_size = 512,
2281 .page_size = 256,
2282 .feature_bits = FEATURE_WRSR_WREN,
2283 .tested = TEST_OK_PREW,
2284 .probe = probe_spi_rdid,
2285 .probe_timing = TIMING_ZERO,
2286 .block_erasers =
2287 {
2288 {
2289 .eraseblocks = { {4 * 1024, 128} },
2290 .block_erase = spi_block_erase_20,
2291 }, {
2292 .eraseblocks = { {32 * 1024, 16} },
2293 .block_erase = spi_block_erase_52,
2294 }, {
2295 .eraseblocks = { {64 * 1024, 8} },
2296 .block_erase = spi_block_erase_d8,
2297 }, {
2298 .eraseblocks = { {512 * 1024, 1} },
2299 .block_erase = spi_block_erase_60,
2300 }, {
2301 .eraseblocks = { {512 * 1024, 1} },
2302 .block_erase = spi_block_erase_c7,
2303 }
2304 },
2305 .printlock = spi_prettyprint_status_register_plain,
2306 .unlock = spi_disable_blockprotect,
2307 .write = spi_chip_write_256,
2308 .read = spi_chip_read,
2309 .voltage = {2500, 3600},
2310 },
2311
2312 {
2313 .vendor = "Atmel",
Evan Jensen291c1012018-05-17 14:30:19 -07002314 .name = "AT25SF081",
2315 .bustype = BUS_SPI,
2316 .manufacture_id = ATMEL_ID,
2317 .model_id = ATMEL_AT25SF081,
2318 .total_size = 1024,
2319 .page_size = 256,
2320 .feature_bits = FEATURE_WRSR_WREN,
2321 .tested = TEST_OK_PREW,
2322 .probe = probe_spi_rdid,
2323 .probe_timing = TIMING_ZERO,
2324 .block_erasers =
2325 {
2326 {
2327 .eraseblocks = { {4 * 1024, 256} },
2328 .block_erase = spi_block_erase_20,
2329 }, {
2330 .eraseblocks = { {32 * 1024, 32} },
2331 .block_erase = spi_block_erase_52,
2332 }, {
2333 .eraseblocks = { {64 * 1024, 16} },
2334 .block_erase = spi_block_erase_d8,
2335 }, {
2336 .eraseblocks = { {1024 * 1024, 1} },
2337 .block_erase = spi_block_erase_60,
2338 }, {
2339 .eraseblocks = { {1024 * 1024, 1} },
2340 .block_erase = spi_block_erase_c7,
2341 }
2342 },
2343 .printlock = spi_prettyprint_status_register_plain,
2344 .unlock = spi_disable_blockprotect,
2345 .write = spi_chip_write_256,
2346 .read = spi_chip_read,
2347 .voltage = {2300, 3600},
2348 },
2349
2350 {
2351 .vendor = "Atmel",
Stanislav Sedovf5775442018-03-07 14:16:51 -08002352 .name = "AT25SF161",
2353 .bustype = BUS_SPI,
2354 .manufacture_id = ATMEL_ID,
2355 .model_id = ATMEL_AT25SF161,
2356 .total_size = 2048,
2357 .page_size = 256,
2358 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
2359 .tested = TEST_OK_PREW,
2360 .probe = probe_spi_rdid,
2361 .probe_timing = TIMING_ZERO,
2362 .block_erasers =
2363 {
2364 {
2365 .eraseblocks = { {4 * 1024, 512} },
2366 .block_erase = spi_block_erase_20,
2367 }, {
2368 .eraseblocks = { {32 * 1024, 64} },
2369 .block_erase = spi_block_erase_52,
2370 }, {
2371 .eraseblocks = { {64 * 1024, 32} },
2372 .block_erase = spi_block_erase_d8,
2373 }, {
2374 .eraseblocks = { {2048 * 1024, 1} },
2375 .block_erase = spi_block_erase_60,
2376 }, {
2377 .eraseblocks = { {2048 * 1024, 1} },
2378 .block_erase = spi_block_erase_c7,
2379 }
2380 },
2381 .printlock = spi_prettyprint_status_register_plain,
2382 .unlock = spi_disable_blockprotect,
2383 .write = spi_chip_write_256,
2384 .read = spi_chip_read,
2385 .voltage = {2500, 3600},
2386 },
2387
2388 {
Alan Green57938f82019-06-27 15:06:43 +10002389 .vendor = "Atmel",
darkarnium41394382019-11-04 20:06:48 +00002390 .name = "AT25SF321",
2391 .bustype = BUS_SPI,
2392 .manufacture_id = ATMEL_ID,
2393 .model_id = ATMEL_AT25SF321,
2394 .total_size = 4096,
2395 .page_size = 256,
2396 .feature_bits = FEATURE_WRSR_WREN,
2397 .tested = TEST_OK_PR,
2398 .probe = probe_spi_rdid,
2399 .probe_timing = TIMING_ZERO,
2400 .block_erasers =
2401 {
2402 {
2403 .eraseblocks = { {4 * 1024, 1024} },
2404 .block_erase = spi_block_erase_20,
2405 }, {
2406 .eraseblocks = { {32 * 1024, 128} },
2407 .block_erase = spi_block_erase_52,
2408 }, {
2409 .eraseblocks = { {64 * 1024, 64} },
2410 .block_erase = spi_block_erase_d8,
2411 }, {
2412 .eraseblocks = { {4096 * 1024, 1} },
2413 .block_erase = spi_block_erase_60,
2414 }, {
2415 .eraseblocks = { {4096 * 1024, 1} },
2416 .block_erase = spi_block_erase_c7,
2417 }
2418 },
2419 .printlock = spi_prettyprint_status_register_plain,
2420 .unlock = spi_disable_blockprotect,
2421 .write = spi_chip_write_256,
2422 .read = spi_chip_read,
2423 .voltage = {2500, 3600},
2424 },
2425
2426 {
2427 .vendor = "Atmel",
Hal Martin49e23d22018-05-27 14:18:43 +02002428 .name = "AT25SL128A",
2429 .bustype = BUS_SPI,
2430 .manufacture_id = ATMEL_ID,
2431 .model_id = ATMEL_AT25SL128A,
2432 .total_size = 16384,
2433 .page_size = 256,
2434 /* supports SFDP */
Nico Huber1412d9f2024-01-06 18:25:49 +01002435 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP | FEATURE_QPI_SRP,
2436 .dummy_cycles = { .qpi_read_params = { 4, 4, 6, 8 } },
Hal Martin49e23d22018-05-27 14:18:43 +02002437 .tested = TEST_OK_PREW,
2438 .probe = probe_spi_rdid,
2439 .probe_timing = TIMING_ZERO,
2440 .block_erasers =
2441 {
2442 {
2443 .eraseblocks = { {4 * 1024, 4096} },
2444 .block_erase = spi_block_erase_20,
2445 }, {
2446 .eraseblocks = { {32 * 1024, 512} },
2447 .block_erase = spi_block_erase_52,
2448 }, {
2449 .eraseblocks = { {64 * 1024, 256} },
2450 .block_erase = spi_block_erase_d8,
2451 }, {
2452 .eraseblocks = { {16 * 1024 * 1024, 1} },
2453 .block_erase = spi_block_erase_60,
2454 }, {
2455 .eraseblocks = { {16 * 1024 * 1024, 1} },
2456 .block_erase = spi_block_erase_c7,
2457 }
2458 },
2459 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
2460 .unlock = spi_disable_blockprotect,
2461 .write = spi_chip_write_256,
2462 .read = spi_chip_read,
2463 .voltage = {1700, 2000},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11002464 .reg_bits =
2465 {
Nico Huber226bb872024-04-09 23:30:34 +02002466 .qe = {STATUS2, 1, RW},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11002467 .srp = {STATUS1, 7, RW},
2468 .srl = {STATUS2, 0, RW},
2469 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
2470 .tb = {STATUS1, 5, RW},
2471 .sec = {STATUS1, 6, RW},
2472 .cmp = {STATUS2, 6, RW},
2473 },
Nico Huberaabb3e02023-01-13 00:22:30 +01002474 .wp_write_cfg = spi_wp_write_cfg,
2475 .wp_read_cfg = spi_wp_read_cfg,
2476 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11002477 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +02002478 .prepare_access = spi_prepare_io,
2479 .finish_access = spi_finish_io,
Hal Martin49e23d22018-05-27 14:18:43 +02002480 },
2481
2482 {
Stanislav Sedovf5775442018-03-07 14:16:51 -08002483 .vendor = "Atmel",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002484 .name = "AT26DF041",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002485 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002486 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002487 .model_id = ATMEL_AT26DF041,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002488 .total_size = 512,
2489 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00002490 /* does not support EWSR nor WREN and has no writable status register bits whatsoever */
Stefan Tauner94b39b42012-10-27 00:06:02 +00002491 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002492 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002493 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00002494 .block_erasers =
2495 {
2496 {
Stefan Tauner94b39b42012-10-27 00:06:02 +00002497 .eraseblocks = { {256, 2048} },
2498 .block_erase = spi_block_erase_81,
2499 }, {
2500 .eraseblocks = { {2 * 1024, 256} },
2501 .block_erase = spi_block_erase_50,
2502 }, {
Sean Nelson89187292009-12-23 12:02:55 +00002503 .eraseblocks = { {4 * 1024, 128} },
2504 .block_erase = spi_block_erase_20,
2505 }
Stefan Tauner6ee37e22012-12-29 15:03:51 +00002506 },
Stefan Taunercecb2c52013-06-20 22:55:41 +00002507 .printlock = spi_prettyprint_status_register_plain,
Stefan Tauner6ee37e22012-12-29 15:03:51 +00002508 /* Supports also an incompatible page write (of exactly 256 B) and an auto-erasing write. */
Stefan Tauner94b39b42012-10-27 00:06:02 +00002509 .write = spi_chip_write_1,
2510 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakulec7d257b42011-07-19 08:50:18 +00002511 .voltage = {2700, 3600}, /* 3.0-3.6V for higher speed, 2.7-3.6V normal */
FENG yu ningff692fb2008-12-08 18:15:10 +00002512 },
2513
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002514 {
2515 .vendor = "Atmel",
2516 .name = "AT26DF081A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002517 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002518 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002519 .model_id = ATMEL_AT26DF081A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002520 .total_size = 1024,
2521 .page_size = 256,
Mathias Krause2c3afa32011-01-17 07:45:54 +00002522 .feature_bits = FEATURE_WRSR_WREN,
2523 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002524 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002525 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00002526 .block_erasers =
2527 {
2528 {
2529 .eraseblocks = { {4 * 1024, 256} },
2530 .block_erase = spi_block_erase_20,
2531 }, {
2532 .eraseblocks = { {32 * 1024, 32} },
2533 .block_erase = spi_block_erase_52,
2534 }, {
2535 .eraseblocks = { {64 * 1024, 16} },
2536 .block_erase = spi_block_erase_d8,
2537 }, {
2538 .eraseblocks = { {1024 * 1024, 1} },
2539 .block_erase = spi_block_erase_60,
2540 }, {
2541 .eraseblocks = { {1024 * 1024, 1} },
2542 .block_erase = spi_block_erase_c7,
2543 }
2544 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00002545 .printlock = spi_prettyprint_status_register_at26df081a,
Stefan Taunercecb2c52013-06-20 22:55:41 +00002546 .unlock = spi_disable_blockprotect_at2x_global_unprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00002547 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002548 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002549 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00002550 },
2551
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002552 {
2553 .vendor = "Atmel",
2554 .name = "AT26DF161",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002555 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002556 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002557 .model_id = ATMEL_AT26DF161,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002558 .total_size = 2048,
2559 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00002560 .feature_bits = FEATURE_WRSR_WREN,
Stefan Tauner5c316f92015-02-08 21:57:52 +00002561 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002562 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002563 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00002564 .block_erasers =
2565 {
2566 {
2567 .eraseblocks = { {4 * 1024, 512} },
2568 .block_erase = spi_block_erase_20,
2569 }, {
2570 .eraseblocks = { {32 * 1024, 64} },
2571 .block_erase = spi_block_erase_52,
2572 }, {
2573 .eraseblocks = { {64 * 1024, 32} },
2574 .block_erase = spi_block_erase_d8,
2575 }, {
2576 .eraseblocks = { {2 * 1024 * 1024, 1} },
2577 .block_erase = spi_block_erase_60,
2578 }, {
2579 .eraseblocks = { {2 * 1024 * 1024, 1} },
2580 .block_erase = spi_block_erase_c7,
2581 }
2582 },
Carl-Daniel Hailfinger7a3bd8f2011-05-19 00:06:06 +00002583 .printlock = spi_prettyprint_status_register_at25df,
Stefan Taunercecb2c52013-06-20 22:55:41 +00002584 .unlock = spi_disable_blockprotect_at2x_global_unprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00002585 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002586 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002587 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00002588 },
2589
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002590 {
2591 .vendor = "Atmel",
2592 .name = "AT26DF161A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002593 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002594 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002595 .model_id = ATMEL_AT26DF161A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002596 .total_size = 2048,
2597 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00002598 .feature_bits = FEATURE_WRSR_WREN,
Stefan Taunercecb2c52013-06-20 22:55:41 +00002599 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002600 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002601 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00002602 .block_erasers =
2603 {
2604 {
2605 .eraseblocks = { {4 * 1024, 512} },
2606 .block_erase = spi_block_erase_20,
2607 }, {
2608 .eraseblocks = { {32 * 1024, 64} },
2609 .block_erase = spi_block_erase_52,
2610 }, {
2611 .eraseblocks = { {64 * 1024, 32} },
2612 .block_erase = spi_block_erase_d8,
2613 }, {
2614 .eraseblocks = { {2 * 1024 * 1024, 1} },
2615 .block_erase = spi_block_erase_60,
2616 }, {
2617 .eraseblocks = { {2 * 1024 * 1024, 1} },
2618 .block_erase = spi_block_erase_c7,
2619 }
2620 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00002621 .printlock = spi_prettyprint_status_register_at26df081a,
Stefan Taunercecb2c52013-06-20 22:55:41 +00002622 .unlock = spi_disable_blockprotect_at2x_global_unprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00002623 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002624 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002625 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00002626 },
2627
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002628 {
2629 .vendor = "Atmel",
2630 .name = "AT26F004",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002631 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002632 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002633 .model_id = ATMEL_AT26F004,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002634 .total_size = 512,
2635 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00002636 .feature_bits = FEATURE_WRSR_WREN,
Alan Green908adf42019-07-03 15:34:06 +10002637 .tested = {.probe = NT, .read = NT, .erase = NT, .write = BAD},
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002638 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002639 .probe_timing = TIMING_ZERO,
Sean Nelson89187292009-12-23 12:02:55 +00002640 .block_erasers =
2641 {
2642 {
2643 .eraseblocks = { {4 * 1024, 128} },
2644 .block_erase = spi_block_erase_20,
2645 }, {
2646 .eraseblocks = { {32 * 1024, 16} },
2647 .block_erase = spi_block_erase_52,
2648 }, {
2649 .eraseblocks = { {64 * 1024, 8} },
2650 .block_erase = spi_block_erase_d8,
2651 }, {
2652 .eraseblocks = { {512 * 1024, 1} },
2653 .block_erase = spi_block_erase_60,
2654 }, {
2655 .eraseblocks = { {512 * 1024, 1} },
2656 .block_erase = spi_block_erase_c7,
2657 }
2658 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00002659 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Alan Greencbb85c02019-06-25 13:42:34 +10002660 .write = NULL, /* Incompatible Page write */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002661 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002662 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00002663 },
2664
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002665 {
2666 .vendor = "Atmel",
Uwe Hermann8403ccb2009-05-16 21:39:19 +00002667 .name = "AT29C010A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002668 .bustype = BUS_PARALLEL,
Uwe Hermann8403ccb2009-05-16 21:39:19 +00002669 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002670 .model_id = ATMEL_AT29C010A,
Uwe Hermann8403ccb2009-05-16 21:39:19 +00002671 .total_size = 128,
2672 .page_size = 128,
Sean Nelson35727f72010-01-28 23:55:12 +00002673 .feature_bits = FEATURE_LONG_RESET,
Carl-Daniel Hailfingerf52f7842010-10-08 18:52:29 +00002674 .tested = TEST_OK_PRE,
Uwe Hermann8403ccb2009-05-16 21:39:19 +00002675 .probe = probe_jedec,
Maciej Pijankac6e11112009-06-03 14:46:22 +00002676 .probe_timing = 10000, /* 10mS, Enter=Exec */
Sean Nelson89187292009-12-23 12:02:55 +00002677 .block_erasers =
2678 {
2679 {
2680 .eraseblocks = { {128 * 1024, 1} },
2681 .block_erase = erase_chip_block_jedec,
2682 }
2683 },
Uwe Hermann8403ccb2009-05-16 21:39:19 +00002684 .write = write_jedec, /* FIXME */
2685 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002686 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01002687 .prepare_access = prepare_memory_access,
2688 .finish_access = finish_memory_access,
Uwe Hermann8403ccb2009-05-16 21:39:19 +00002689 },
2690
2691 {
2692 .vendor = "Atmel",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002693 .name = "AT29C020",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002694 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002695 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002696 .model_id = ATMEL_AT29C020,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002697 .total_size = 256,
2698 .page_size = 256,
Sean Nelson35727f72010-01-28 23:55:12 +00002699 .feature_bits = FEATURE_LONG_RESET,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +00002700 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002701 .probe = probe_jedec,
Uwe Hermann431f4f72010-09-05 12:41:25 +00002702 .probe_timing = 10000, /* 10ms */
Sean Nelson89187292009-12-23 12:02:55 +00002703 .block_erasers =
2704 {
2705 {
2706 .eraseblocks = { {256 * 1024, 1} },
2707 .block_erase = erase_chip_block_jedec,
2708 }
2709 },
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002710 .write = write_jedec,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +00002711 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002712 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01002713 .prepare_access = prepare_memory_access,
2714 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +00002715 },
2716
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002717 {
2718 .vendor = "Atmel",
2719 .name = "AT29C040A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002720 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002721 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002722 .model_id = ATMEL_AT29C040A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002723 .total_size = 512,
2724 .page_size = 256,
Sean Nelson35727f72010-01-28 23:55:12 +00002725 .feature_bits = FEATURE_LONG_RESET,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002726 .tested = TEST_UNTESTED,
2727 .probe = probe_jedec,
Mateusz Murawski8b2f46b2009-06-12 21:29:36 +00002728 .probe_timing = 10000, /* 10 ms */
Sean Nelson89187292009-12-23 12:02:55 +00002729 .block_erasers =
2730 {
2731 {
2732 .eraseblocks = { {512 * 1024, 1} },
2733 .block_erase = erase_chip_block_jedec,
2734 }
2735 },
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002736 .write = write_jedec,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +00002737 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002738 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01002739 .prepare_access = prepare_memory_access,
2740 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +00002741 },
2742
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002743 {
2744 .vendor = "Atmel",
Alan Green1f9cc7d2019-07-01 11:10:45 +10002745 .name = "AT29C512",
2746 .bustype = BUS_PARALLEL,
2747 .manufacture_id = ATMEL_ID,
2748 .model_id = ATMEL_AT29C512,
2749 .total_size = 64,
2750 .page_size = 128,
2751 .feature_bits = FEATURE_LONG_RESET,
2752 .tested = TEST_OK_PREW,
2753 .probe = probe_jedec,
2754 .probe_timing = 10000, /* 10mS, Enter=Exec */
2755 .block_erasers =
2756 {
2757 {
2758 .eraseblocks = { {64 * 1024, 1} },
2759 .block_erase = erase_chip_block_jedec,
2760 }
2761 },
2762 .write = write_jedec,
2763 .read = read_memmapped,
2764 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01002765 .prepare_access = prepare_memory_access,
2766 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10002767 },
2768
2769 {
2770 .vendor = "Atmel",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002771 .name = "AT45CS1282",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002772 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002773 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002774 .model_id = ATMEL_AT45CS1282,
Alan Greencbb85c02019-06-25 13:42:34 +10002775 .total_size = 16896, /* No power of two sizes */
2776 .page_size = 1056, /* No power of two sizes */
Steven Zakulec3603a282012-05-02 20:07:57 +00002777 /* does not support EWSR nor WREN and has no writable status register bits whatsoever */
Stefan Tauner1dd5d3a2013-08-27 18:02:19 +00002778 /* OTP: 128B total, 64B pre-programmed; read 0x77 (4 dummy bytes); write 0x9A (via buffer) */
2779 .feature_bits = FEATURE_OTP,
2780 .tested = TEST_UNTESTED,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002781 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002782 .probe_timing = TIMING_ZERO,
Stefan Tauner1dd5d3a2013-08-27 18:02:19 +00002783 .block_erasers =
2784 {
2785 {
2786 .eraseblocks = {
2787 {8 * 1056, 1}, /* sector 0a: opcode 50h */
2788 {248 * 1056, 1}, /* sector 0b: opcode 7Ch */
2789 {256 * 1056, 63}, /* sectors 1 - 63: opcode 7Ch */
2790 },
2791 .block_erase = spi_erase_at45cs_sector,
2792 }
2793 },
2794 .printlock = spi_prettyprint_status_register_plain,
Stefan Tauner1dd5d3a2013-08-27 18:02:19 +00002795 .write = spi_write_at45db,
2796 .read = spi_read_at45db,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002797 .voltage = {2700, 3600},
Alan Greenc1863ca2019-06-27 15:08:03 +10002798 .gran = write_gran_1056bytes,
Carl-Daniel Hailfinger66afb362009-03-19 12:18:13 +00002799 },
FENG yu ningff692fb2008-12-08 18:15:10 +00002800
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002801 {
2802 .vendor = "Atmel",
2803 .name = "AT45DB011D",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002804 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002805 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002806 .model_id = ATMEL_AT45DB011D,
Alan Greencbb85c02019-06-25 13:42:34 +10002807 .total_size = 128, /* or 132, determined from status register */
2808 .page_size = 256, /* or 264, determined from status register */
Steven Zakulec3603a282012-05-02 20:07:57 +00002809 /* does not support EWSR nor WREN and has no writable status register bits whatsoever */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002810 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
2811 .feature_bits = FEATURE_OTP,
Stefan Tauner5c316f92015-02-08 21:57:52 +00002812 .tested = TEST_OK_PREW,
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002813 .probe = probe_spi_at45db,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002814 .probe_timing = TIMING_ZERO,
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002815 .block_erasers =
2816 {
2817 {
2818 .eraseblocks = { {256, 512} },
2819 .block_erase = spi_erase_at45db_page,
2820 }, {
2821 .eraseblocks = { {8 * 256, 512/8} },
2822 .block_erase = spi_erase_at45db_block,
2823 }, {
2824 .eraseblocks = {
2825 {8 * 256, 1},
2826 {120 * 256, 1},
2827 {128 * 256, 3},
2828 },
2829 .block_erase = spi_erase_at45db_sector
2830 }, {
2831 .eraseblocks = { {128 * 1024, 1} },
2832 .block_erase = spi_erase_at45db_chip,
2833 }
2834 },
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002835 .printlock = spi_prettyprint_status_register_at45db,
Alan Greenc1863ca2019-06-27 15:08:03 +10002836 .unlock = spi_disable_blockprotect_at45db, /* Impossible if locked down or #WP is low */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002837 /* granularity will be set by the probing function. */
2838 .write = spi_write_at45db,
2839 .read = spi_read_at45db, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002840 .voltage = {2700, 3600},
Carl-Daniel Hailfinger66afb362009-03-19 12:18:13 +00002841 },
FENG yu ningff692fb2008-12-08 18:15:10 +00002842
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002843 {
2844 .vendor = "Atmel",
2845 .name = "AT45DB021D",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002846 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002847 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002848 .model_id = ATMEL_AT45DB021D,
Alan Greencbb85c02019-06-25 13:42:34 +10002849 .total_size = 256, /* or 264, determined from status register */
2850 .page_size = 256, /* or 264, determined from status register */
Steven Zakulec3603a282012-05-02 20:07:57 +00002851 /* does not support EWSR nor WREN and has no writable status register bits whatsoever */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002852 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
2853 .feature_bits = FEATURE_OTP,
Stefan Tauner6697f712014-08-06 15:09:15 +00002854 .tested = TEST_OK_PREW,
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002855 .probe = probe_spi_at45db,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002856 .probe_timing = TIMING_ZERO,
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002857 .block_erasers =
2858 {
2859 {
2860 .eraseblocks = { {256, 1024} },
2861 .block_erase = spi_erase_at45db_page,
2862 }, {
2863 .eraseblocks = { {8 * 256, 1024/8} },
2864 .block_erase = spi_erase_at45db_block,
2865 }, {
2866 .eraseblocks = {
2867 {8 * 256, 1},
2868 {120 * 256, 1},
2869 {128 * 256, 7},
2870 },
2871 .block_erase = spi_erase_at45db_sector
2872 }, {
2873 .eraseblocks = { {256 * 1024, 1} },
2874 .block_erase = spi_erase_at45db_chip,
2875 }
2876 },
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002877 .printlock = spi_prettyprint_status_register_at45db,
Alan Greenc1863ca2019-06-27 15:08:03 +10002878 .unlock = spi_disable_blockprotect_at45db, /* Impossible if locked down or #WP is low */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002879 /* granularity will be set by the probing function. */
2880 .write = spi_write_at45db,
2881 .read = spi_read_at45db, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +00002882 .voltage = {2700, 3600},
Carl-Daniel Hailfinger66afb362009-03-19 12:18:13 +00002883 },
FENG yu ningff692fb2008-12-08 18:15:10 +00002884
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002885 {
2886 .vendor = "Atmel",
2887 .name = "AT45DB041D",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002888 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002889 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002890 .model_id = ATMEL_AT45DB041D,
Alan Greencbb85c02019-06-25 13:42:34 +10002891 .total_size = 512, /* or 528, determined from status register */
2892 .page_size = 256, /* or 264, determined from status register */
Steven Zakulec3603a282012-05-02 20:07:57 +00002893 /* does not support EWSR nor WREN and has no writable status register bits whatsoever */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002894 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
2895 .feature_bits = FEATURE_OTP,
2896 .tested = TEST_OK_PREW,
2897 .probe = probe_spi_at45db,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002898 .probe_timing = TIMING_ZERO,
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002899 .block_erasers =
2900 {
2901 {
2902 .eraseblocks = { {256, 2048} },
2903 .block_erase = spi_erase_at45db_page,
2904 }, {
2905 .eraseblocks = { {8 * 256, 2048/8} },
2906 .block_erase = spi_erase_at45db_block,
2907 }, {
2908 .eraseblocks = {
2909 {8 * 256, 1},
2910 {248 * 256, 1},
2911 {256 * 256, 7},
2912 },
2913 .block_erase = spi_erase_at45db_sector
2914 }, {
2915 .eraseblocks = { {512 * 1024, 1} },
2916 .block_erase = spi_erase_at45db_chip,
2917 }
2918 },
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002919 .printlock = spi_prettyprint_status_register_at45db,
Alan Greenc1863ca2019-06-27 15:08:03 +10002920 .unlock = spi_disable_blockprotect_at45db, /* Impossible if locked down or #WP is low */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002921 /* granularity will be set by the probing function. */
2922 .write = spi_write_at45db,
2923 .read = spi_read_at45db, /* Fast read (0x0B) supported */
2924 .voltage = {2700, 3600}, /* 2.5-3.6V & 2.7-3.6V models available */
Carl-Daniel Hailfinger66afb362009-03-19 12:18:13 +00002925 },
FENG yu ningff692fb2008-12-08 18:15:10 +00002926
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002927 {
2928 .vendor = "Atmel",
2929 .name = "AT45DB081D",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002930 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002931 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002932 .model_id = ATMEL_AT45DB081D,
Alan Greencbb85c02019-06-25 13:42:34 +10002933 .total_size = 1024, /* or 1056, determined from status register */
2934 .page_size = 256, /* or 264, determined from status register */
Steven Zakulec3603a282012-05-02 20:07:57 +00002935 /* does not support EWSR nor WREN and has no writable status register bits whatsoever */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002936 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
2937 .feature_bits = FEATURE_OTP,
Angel Pons250aeba2018-09-30 20:28:22 +02002938 .tested = TEST_OK_PREW,
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002939 .probe = probe_spi_at45db,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002940 .probe_timing = TIMING_ZERO,
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002941 .block_erasers =
2942 {
2943 {
2944 .eraseblocks = { {256, 4096} },
2945 .block_erase = spi_erase_at45db_page,
2946 }, {
2947 .eraseblocks = { {8 * 256, 4096/8} },
2948 .block_erase = spi_erase_at45db_block,
2949 }, {
2950 .eraseblocks = {
2951 {8 * 256, 1},
2952 {248 * 256, 1},
2953 {256 * 256, 15},
2954 },
2955 .block_erase = spi_erase_at45db_sector
2956 }, {
2957 .eraseblocks = { {1024 * 1024, 1} },
2958 .block_erase = spi_erase_at45db_chip,
2959 }
2960 },
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002961 .printlock = spi_prettyprint_status_register_at45db,
Alan Greenc1863ca2019-06-27 15:08:03 +10002962 .unlock = spi_disable_blockprotect_at45db, /* Impossible if locked down or #WP is low */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002963 /* granularity will be set by the probing function. */
2964 .write = spi_write_at45db,
2965 .read = spi_read_at45db, /* Fast read (0x0B) supported */
Steven Zakulec7d257b42011-07-19 08:50:18 +00002966 .voltage = {2700, 3600}, /* 2.5-3.6V & 2.7-3.6V models available */
Carl-Daniel Hailfinger66afb362009-03-19 12:18:13 +00002967 },
FENG yu ningff692fb2008-12-08 18:15:10 +00002968
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002969 {
2970 .vendor = "Atmel",
2971 .name = "AT45DB161D",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00002972 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00002973 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00002974 .model_id = ATMEL_AT45DB161D,
Alan Greencbb85c02019-06-25 13:42:34 +10002975 .total_size = 2048, /* or 2112, determined from status register */
2976 .page_size = 512, /* or 528, determined from status register */
Steven Zakulec3603a282012-05-02 20:07:57 +00002977 /* does not support EWSR nor WREN and has no writable status register bits whatsoever */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002978 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
2979 .feature_bits = FEATURE_OTP,
2980 .tested = TEST_OK_PREW,
2981 .probe = probe_spi_at45db,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00002982 .probe_timing = TIMING_ZERO,
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00002983 .block_erasers =
2984 {
2985 {
2986 .eraseblocks = { {512, 4096} },
2987 .block_erase = spi_erase_at45db_page,
2988 }, {
2989 .eraseblocks = { {8 * 512, 4096/8} },
2990 .block_erase = spi_erase_at45db_block,
2991 }, {
2992 .eraseblocks = {
2993 {8 * 512, 1},
2994 {248 * 512, 1},
2995 {256 * 512, 15},
2996 },
2997 .block_erase = spi_erase_at45db_sector
2998 }, {
2999 .eraseblocks = { {2048 * 1024, 1} },
3000 .block_erase = spi_erase_at45db_chip,
3001 }
3002 },
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003003 .printlock = spi_prettyprint_status_register_at45db,
Alan Greenc1863ca2019-06-27 15:08:03 +10003004 .unlock = spi_disable_blockprotect_at45db, /* Impossible if locked down or #WP is low */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003005 /* granularity will be set by the probing function. */
3006 .write = spi_write_at45db,
3007 .read = spi_read_at45db, /* Fast read (0x0B) supported */
Steven Zakulec7d257b42011-07-19 08:50:18 +00003008 .voltage = {2700, 3600}, /* 2.5-3.6V & 2.7-3.6V models available */
Carl-Daniel Hailfinger66afb362009-03-19 12:18:13 +00003009 },
FENG yu ningff692fb2008-12-08 18:15:10 +00003010
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003011 {
3012 .vendor = "Atmel",
3013 .name = "AT45DB321C",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00003014 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003015 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00003016 .model_id = ATMEL_AT45DB321C,
Alan Greencbb85c02019-06-25 13:42:34 +10003017 .total_size = 4224, /* No power of two sizes */
3018 .page_size = 528, /* No power of two sizes */
Steven Zakulec3603a282012-05-02 20:07:57 +00003019 /* does not support EWSR nor WREN and has no writable status register bits whatsoever */
Stefan Taunerfdc4f7e2013-08-27 18:02:12 +00003020 /* OTP: 128B total, 64B pre-programmed; read 0x77 (4 dummy bytes); write 0x9A (via buffer) */
3021 .feature_bits = FEATURE_OTP,
3022 .tested = TEST_UNTESTED,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003023 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00003024 .probe_timing = TIMING_ZERO,
Stefan Taunerfdc4f7e2013-08-27 18:02:12 +00003025 .block_erasers =
3026 {
3027 {
3028 .eraseblocks = { {528, 8192} },
3029 .block_erase = spi_erase_at45db_page,
3030 }, {
3031 .eraseblocks = { {8 * 528, 8192/8} },
3032 .block_erase = spi_erase_at45db_block,
3033 }, /* Although the datasheets describes sectors (which can be write protected)
3034 * there seems to be no erase functions for them.
Stefan Tauner23e10b82016-01-23 16:16:49 +00003035 {
Stefan Taunerfdc4f7e2013-08-27 18:02:12 +00003036 .eraseblocks = {
3037 {8 * 528, 1},
3038 {120 * 528, 1},
3039 {128 * 528, 63},
3040 },
3041 .block_erase = spi_erase_at45db_sector
3042 }, */ {
3043 .eraseblocks = { {4224 * 1024, 1} },
3044 .block_erase = spi_erase_at45db_chip,
3045 }
3046 },
3047 .printlock = spi_prettyprint_status_register_at45db, /* Bit 0 is undefined, no lockdown */
Stefan Taunerfdc4f7e2013-08-27 18:02:12 +00003048 .write = spi_write_at45db,
3049 .read = spi_read_at45db_e8, /* 3 address and 4 dummy bytes */
Steven Zakuleccbe370e2011-06-03 07:26:31 +00003050 .voltage = {2700, 3600},
Alan Greenc1863ca2019-06-27 15:08:03 +10003051 .gran = write_gran_528bytes,
Carl-Daniel Hailfinger66afb362009-03-19 12:18:13 +00003052 },
FENG yu ningff692fb2008-12-08 18:15:10 +00003053
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003054 {
3055 .vendor = "Atmel",
3056 .name = "AT45DB321D",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00003057 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003058 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00003059 .model_id = ATMEL_AT45DB321D,
Alan Greencbb85c02019-06-25 13:42:34 +10003060 .total_size = 4096, /* or 4224, determined from status register */
3061 .page_size = 512, /* or 528, determined from status register */
Steven Zakulec3603a282012-05-02 20:07:57 +00003062 /* does not support EWSR nor WREN and has no writable status register bits whatsoever */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003063 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
Daniel Lenski65922a32012-02-15 23:40:23 +00003064 .feature_bits = FEATURE_OTP,
Stefan Tauner23e10b82016-01-23 16:16:49 +00003065 .tested = TEST_OK_PREW,
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003066 .probe = probe_spi_at45db,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00003067 .probe_timing = TIMING_ZERO,
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003068 .block_erasers =
3069 {
3070 {
3071 .eraseblocks = { {512, 8192} },
3072 .block_erase = spi_erase_at45db_page,
3073 }, {
3074 .eraseblocks = { {8 * 512, 8192/8} },
3075 .block_erase = spi_erase_at45db_block,
3076 }, {
3077 .eraseblocks = {
3078 {8 * 512, 1},
3079 {120 * 512, 1},
3080 {128 * 512, 63},
3081 },
3082 .block_erase = spi_erase_at45db_sector
3083 }, {
3084 .eraseblocks = { {4096 * 1024, 1} },
3085 .block_erase = spi_erase_at45db_chip,
3086 }
3087 },
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003088 .printlock = spi_prettyprint_status_register_at45db,
Alan Greenc1863ca2019-06-27 15:08:03 +10003089 .unlock = spi_disable_blockprotect_at45db, /* Impossible if locked down or #WP is low */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003090 /* granularity will be set by the probing function. */
3091 .write = spi_write_at45db,
3092 .read = spi_read_at45db, /* Fast read (0x0B) supported */
3093 .voltage = {2700, 3600}, /* 2.5-3.6V & 2.7-3.6V models available */
3094 },
3095
3096 {
3097 .vendor = "Atmel",
3098 .name = "AT45DB321E",
3099 .bustype = BUS_SPI,
3100 .manufacture_id = ATMEL_ID,
3101 .model_id = ATMEL_AT45DB321C,
Alan Greencbb85c02019-06-25 13:42:34 +10003102 .total_size = 4096, /* or 4224, determined from status register */
3103 .page_size = 512, /* or 528, determined from status register */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003104 /* does not support EWSR nor WREN and has no writable status register bits whatsoever */
3105 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
3106 .feature_bits = FEATURE_OTP,
3107 .tested = TEST_UNTESTED,
3108 .probe = probe_spi_at45db,
3109 .probe_timing = TIMING_ZERO,
3110 .block_erasers =
3111 {
3112 {
3113 .eraseblocks = { {512, 8192} },
3114 .block_erase = spi_erase_at45db_page,
3115 }, {
3116 .eraseblocks = { {8 * 512, 8192/8} },
3117 .block_erase = spi_erase_at45db_block,
3118 }, {
3119 .eraseblocks = {
3120 {8 * 512, 1},
3121 {120 * 512, 1},
3122 {128 * 512, 63},
3123 },
3124 .block_erase = spi_erase_at45db_sector
3125 }, {
3126 .eraseblocks = { {4096 * 1024, 1} },
3127 .block_erase = spi_erase_at45db_chip,
3128 }
3129 },
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003130 .printlock = spi_prettyprint_status_register_at45db, /* has a 2nd status register */
Alan Greenc1863ca2019-06-27 15:08:03 +10003131 .unlock = spi_disable_blockprotect_at45db, /* Impossible if locked down or #WP is low */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003132 /* granularity will be set by the probing function. */
3133 .write = spi_write_at45db,
3134 .read = spi_read_at45db, /* Fast read (0x0B) supported */
3135 .voltage = {2500, 3600}, /* 2.3-3.6V & 2.5-3.6V models available */
Carl-Daniel Hailfinger66afb362009-03-19 12:18:13 +00003136 },
FENG yu ningff692fb2008-12-08 18:15:10 +00003137
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003138 {
3139 .vendor = "Atmel",
3140 .name = "AT45DB642D",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00003141 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003142 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00003143 .model_id = ATMEL_AT45DB642D,
Alan Greencbb85c02019-06-25 13:42:34 +10003144 .total_size = 8192, /* or 8448, determined from status register */
3145 .page_size = 1024, /* or 1056, determined from status register */
Steven Zakulec3603a282012-05-02 20:07:57 +00003146 /* does not support EWSR nor WREN and has no writable status register bits whatsoever */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003147 /* OTP: 128B total, 64B pre-programmed; read 0x77; write 0x9B */
3148 .feature_bits = FEATURE_OTP,
Stefan Tauner5c316f92015-02-08 21:57:52 +00003149 .tested = TEST_OK_PREW,
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003150 .probe = probe_spi_at45db,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00003151 .probe_timing = TIMING_ZERO,
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003152 .block_erasers =
3153 {
3154 {
3155 .eraseblocks = { {1024, 8192} },
3156 .block_erase = spi_erase_at45db_page,
3157 }, {
3158 .eraseblocks = { {8 * 1024, 8192/8} },
3159 .block_erase = spi_erase_at45db_block,
3160 }, {
3161 .eraseblocks = {
3162 {8 * 1024, 1},
3163 {248 * 1024, 1},
3164 {256 * 1024, 31},
3165 },
3166 .block_erase = spi_erase_at45db_sector
3167 }, {
3168 .eraseblocks = { {8192 * 1024, 1} },
3169 .block_erase = spi_erase_at45db_chip,
3170 }
3171 },
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003172 .printlock = spi_prettyprint_status_register_at45db,
Alan Greenc1863ca2019-06-27 15:08:03 +10003173 .unlock = spi_disable_blockprotect_at45db, /* Impossible if locked down or #WP is low */
Aidan Thorntondb4e87d2013-08-27 18:01:53 +00003174 /* granularity will be set by the probing function. */
3175 .write = spi_write_at45db,
3176 .read = spi_read_at45db, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +00003177 .voltage = {2700, 3600},
Carl-Daniel Hailfinger66afb362009-03-19 12:18:13 +00003178 },
FENG yu ningff692fb2008-12-08 18:15:10 +00003179
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003180 {
3181 .vendor = "Atmel",
Alan Green1f9cc7d2019-07-01 11:10:45 +10003182 .name = "AT49(H)F010",
3183 .bustype = BUS_PARALLEL,
3184 .manufacture_id = ATMEL_ID,
3185 .model_id = ATMEL_AT49F010,
3186 .total_size = 128,
3187 .page_size = 0, /* unused */
3188 .feature_bits = FEATURE_EITHER_RESET,
3189 .tested = TEST_OK_PREW,
3190 .probe = probe_jedec,
3191 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
3192 .block_erasers =
3193 {
3194 {
3195 .eraseblocks = { {128 * 1024, 1} },
3196 .block_erase = erase_chip_block_jedec,
3197 }
3198 },
3199 .printlock = printlock_at49f,
3200 .write = write_jedec_1,
3201 .read = read_memmapped,
3202 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01003203 .prepare_access = prepare_memory_access,
3204 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10003205 },
3206
3207 {
3208 .vendor = "Atmel",
Uwe Hermannb4dcb712009-05-13 11:36:06 +00003209 .name = "AT49BV512",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00003210 .bustype = BUS_PARALLEL,
Uwe Hermannb4dcb712009-05-13 11:36:06 +00003211 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00003212 .model_id = ATMEL_AT49BV512,
Uwe Hermannb4dcb712009-05-13 11:36:06 +00003213 .total_size = 64,
3214 .page_size = 64,
Sean Nelson35727f72010-01-28 23:55:12 +00003215 .feature_bits = FEATURE_EITHER_RESET,
Stefan Tauner8179be52011-06-04 13:13:34 +00003216 .tested = TEST_OK_PREW,
Uwe Hermannb4dcb712009-05-13 11:36:06 +00003217 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +00003218 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson89187292009-12-23 12:02:55 +00003219 .block_erasers =
3220 {
3221 {
3222 .eraseblocks = { {64 * 1024, 1} },
3223 .block_erase = erase_chip_block_jedec,
3224 }
3225 },
Sean Nelson35727f72010-01-28 23:55:12 +00003226 .write = write_jedec_1,
Uwe Hermannb4dcb712009-05-13 11:36:06 +00003227 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00003228 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +01003229 .prepare_access = prepare_memory_access,
3230 .finish_access = finish_memory_access,
Uwe Hermannb4dcb712009-05-13 11:36:06 +00003231 },
3232
3233 {
3234 .vendor = "Atmel",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003235 .name = "AT49F002(N)",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00003236 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003237 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00003238 .model_id = ATMEL_AT49F002N,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003239 .total_size = 256,
3240 .page_size = 256,
Sean Nelson35727f72010-01-28 23:55:12 +00003241 .feature_bits = FEATURE_EITHER_RESET,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003242 .tested = TEST_UNTESTED,
3243 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +00003244 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson89187292009-12-23 12:02:55 +00003245 .block_erasers =
3246 {
3247 {
3248 .eraseblocks = {
3249 {16 * 1024, 1},
3250 {8 * 1024, 2},
3251 {96 * 1024, 1},
3252 {128 * 1024, 1},
3253 },
3254 .block_erase = erase_sector_jedec,
3255 }, {
3256 .eraseblocks = { {256 * 1024, 1} },
3257 .block_erase = erase_chip_block_jedec,
3258 }
3259 },
Sean Nelson35727f72010-01-28 23:55:12 +00003260 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +00003261 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00003262 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01003263 .prepare_access = prepare_memory_access,
3264 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +00003265 },
3266
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003267 {
3268 .vendor = "Atmel",
3269 .name = "AT49F002(N)T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00003270 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003271 .manufacture_id = ATMEL_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00003272 .model_id = ATMEL_AT49F002NT,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003273 .total_size = 256,
3274 .page_size = 256,
Sean Nelson35727f72010-01-28 23:55:12 +00003275 .feature_bits = FEATURE_EITHER_RESET,
Carl-Daniel Hailfingerf52f7842010-10-08 18:52:29 +00003276 .tested = TEST_OK_PR,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003277 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +00003278 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson89187292009-12-23 12:02:55 +00003279 .block_erasers =
3280 {
3281 {
3282 .eraseblocks = {
3283 {128 * 1024, 1},
3284 {96 * 1024, 1},
3285 {8 * 1024, 2},
3286 {16 * 1024, 1},
3287 },
3288 .block_erase = erase_sector_jedec,
3289 }, {
3290 .eraseblocks = { {256 * 1024, 1} },
3291 .block_erase = erase_chip_block_jedec,
3292 }
3293 },
Sean Nelson35727f72010-01-28 23:55:12 +00003294 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +00003295 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00003296 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01003297 .prepare_access = prepare_memory_access,
3298 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +00003299 },
3300
Daniel Lenskidf90d3a2010-07-22 11:44:38 +00003301 {
Uwe Hermannc74e9772011-09-08 19:55:18 +00003302 .vendor = "Atmel",
David Borgf5a30f62012-04-15 13:16:32 +00003303 .name = "AT49F020",
3304 .bustype = BUS_PARALLEL,
3305 .manufacture_id = ATMEL_ID,
3306 .model_id = ATMEL_AT49F020,
3307 .total_size = 256,
Andrew Morgan8dd97f92012-08-13 23:43:46 +00003308 .page_size = 0, /* unused */
David Borgf5a30f62012-04-15 13:16:32 +00003309 .feature_bits = FEATURE_EITHER_RESET,
3310 .tested = TEST_OK_PRE,
3311 .probe = probe_jedec,
3312 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
3313 .block_erasers =
3314 {
3315 {
3316 .eraseblocks = { {256 * 1024, 1} },
3317 .block_erase = erase_chip_block_jedec,
3318 }
3319 /* Chip features an optional permanent write protection
3320 * of the first 8 kB. The erase function is the same as
3321 * above, but 00000H to 01FFFH will not be erased.
3322 * FIXME: add another eraser when partial erasers are
3323 * supported.
3324 */
3325 },
3326 .printlock = printlock_at49f,
3327 .write = write_jedec_1,
3328 .read = read_memmapped,
3329 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01003330 .prepare_access = prepare_memory_access,
3331 .finish_access = finish_memory_access,
David Borgf5a30f62012-04-15 13:16:32 +00003332 },
3333
3334 {
3335 .vendor = "Atmel",
3336 .name = "AT49F040",
3337 .bustype = BUS_PARALLEL,
3338 .manufacture_id = ATMEL_ID,
3339 .model_id = ATMEL_AT49F040,
3340 .total_size = 512,
Andrew Morgan8dd97f92012-08-13 23:43:46 +00003341 .page_size = 0, /* unused */
David Borgf5a30f62012-04-15 13:16:32 +00003342 .feature_bits = FEATURE_EITHER_RESET,
3343 .tested = TEST_UNTESTED,
3344 .probe = probe_jedec,
3345 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
3346 .block_erasers =
3347 {
3348 {
3349 .eraseblocks = { {512 * 1024, 1} },
3350 .block_erase = erase_chip_block_jedec,
3351 }
3352 /* Chip features an optional permanent write protection
3353 * of the first 16 kB. The erase function is the same as
3354 * above, but 00000H to 03FFFH will not be erased.
3355 * FIXME: add another eraser when partial erasers are
3356 * supported.
3357 */
3358 },
3359 .printlock = printlock_at49f,
3360 .write = write_jedec_1,
3361 .read = read_memmapped,
3362 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01003363 .prepare_access = prepare_memory_access,
3364 .finish_access = finish_memory_access,
David Borgf5a30f62012-04-15 13:16:32 +00003365 },
3366
3367 {
3368 .vendor = "Atmel",
Andrew Morgan8dd97f92012-08-13 23:43:46 +00003369 .name = "AT49F080",
3370 .bustype = BUS_PARALLEL,
3371 .manufacture_id = ATMEL_ID,
3372 .model_id = ATMEL_AT49F080,
3373 .total_size = 1024,
3374 .page_size = 0, /* unused */
3375 .feature_bits = FEATURE_EITHER_RESET,
3376 .tested = TEST_UNTESTED,
3377 .probe = probe_jedec,
3378 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
3379 .block_erasers =
3380 {
3381 {
3382 .eraseblocks = { {1024 * 1024, 1} },
3383 .block_erase = erase_chip_block_jedec,
3384 }
3385 /* Chip features an optional permanent write protection
3386 * of the first 16 kB. The erase function is the same as
3387 * above, but 00000H to 03FFFH will not be erased.
3388 * FIXME: add another eraser when partial erasers are
3389 * supported.
3390 */
3391 },
3392 .printlock = printlock_at49f,
3393 .write = write_jedec_1,
3394 .read = read_memmapped,
3395 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01003396 .prepare_access = prepare_memory_access,
3397 .finish_access = finish_memory_access,
Andrew Morgan8dd97f92012-08-13 23:43:46 +00003398 },
3399
3400 {
3401 /* 'top' version of AT49F080. equal in all aspects but the boot block address */
3402 .vendor = "Atmel",
3403 .name = "AT49F080T",
3404 .bustype = BUS_PARALLEL,
3405 .manufacture_id = ATMEL_ID,
3406 .model_id = ATMEL_AT49F080T,
3407 .total_size = 1024,
3408 .page_size = 0, /* unused */
3409 .feature_bits = FEATURE_EITHER_RESET,
3410 .tested = TEST_UNTESTED,
3411 .probe = probe_jedec,
3412 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
3413 .block_erasers =
3414 {
3415 {
3416 .eraseblocks = { {1024 * 1024, 1} },
3417 .block_erase = erase_chip_block_jedec,
3418 }
3419 /* Chip features an optional permanent write protection
3420 * of the first 16 kB. The erase function is the same as
3421 * above, but FC000H to FFFFFH will not be erased.
3422 * FIXME: add another eraser when partial erasers are
3423 * supported.
3424 */
3425 },
3426 .printlock = printlock_at49f,
3427 .write = write_jedec_1,
3428 .read = read_memmapped,
3429 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01003430 .prepare_access = prepare_memory_access,
3431 .finish_access = finish_memory_access,
Andrew Morgan8dd97f92012-08-13 23:43:46 +00003432 },
3433
3434 {
3435 .vendor = "Atmel",
Uwe Hermannc74e9772011-09-08 19:55:18 +00003436 .name = "AT49LH002",
3437 .bustype = BUS_LPC | BUS_FWH, /* A/A Mux */
3438 .manufacture_id = ATMEL_ID,
3439 .model_id = ATMEL_AT49LH002,
3440 .total_size = 256,
3441 .page_size = 0, /* unused */
Uwe Hermannc74e9772011-09-08 19:55:18 +00003442 .tested = TEST_UNTESTED,
Stefan Tauner7de93932014-08-03 13:05:45 +00003443 .probe = probe_82802ab,
3444 .probe_timing = TIMING_ZERO,
Uwe Hermannc74e9772011-09-08 19:55:18 +00003445 .block_erasers =
3446 {
3447 {
3448 .eraseblocks = {
3449 {64 * 1024, 3},
3450 {32 * 1024, 1},
3451 {8 * 1024, 2},
3452 {16 * 1024, 1},
3453 },
Stefan Tauner7de93932014-08-03 13:05:45 +00003454 .block_erase = NULL, /* TODO: Implement. */
Uwe Hermannc74e9772011-09-08 19:55:18 +00003455 }, {
3456 .eraseblocks = {
3457 {64 * 1024, 4},
3458 },
Stefan Tauner7de93932014-08-03 13:05:45 +00003459 .block_erase = erase_block_82802ab,
3460 },
3461 },
3462 .printlock = printlock_regspace2_block_eraser_0,
3463 .unlock = unlock_regspace2_block_eraser_0,
3464 .write = write_82802ab,
3465 .read = read_memmapped,
3466 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +01003467 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +01003468 .finish_access = finish_memory_access,
Stefan Tauner7de93932014-08-03 13:05:45 +00003469 },
3470
3471 {
3472 .vendor = "Atmel",
Stefan Tauner7de93932014-08-03 13:05:45 +00003473 .name = "AT49LH004",
3474 .bustype = BUS_LPC | BUS_FWH, /* A/A Mux */
3475 .manufacture_id = ATMEL_ID,
3476 .model_id = ATMEL_AT49LH004,
3477 .total_size = 512,
3478 .page_size = 0, /* unused */
Stefan Tauner7de93932014-08-03 13:05:45 +00003479 .tested = TEST_UNTESTED,
3480 .probe = probe_82802ab,
3481 .probe_timing = TIMING_ZERO,
3482 .block_erasers =
3483 {
3484 {
3485 .eraseblocks = {
3486 {64 * 1024, 7},
3487 {32 * 1024, 1},
3488 {8 * 1024, 2},
3489 {16 * 1024, 1},
3490 },
3491 .block_erase = erase_block_82802ab,
3492 }, {
3493 .eraseblocks = {
3494 {64 * 1024, 8},
3495 },
Uwe Hermannc74e9772011-09-08 19:55:18 +00003496 .block_erase = NULL, /* TODO: Implement. */
3497 },
3498 },
Stefan Tauner7de93932014-08-03 13:05:45 +00003499 .printlock = printlock_regspace2_block_eraser_0,
3500 .unlock = unlock_regspace2_block_eraser_0,
Uwe Hermannc74e9772011-09-08 19:55:18 +00003501 .write = write_82802ab,
3502 .read = read_memmapped,
3503 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +01003504 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +01003505 .finish_access = finish_memory_access,
Uwe Hermannc74e9772011-09-08 19:55:18 +00003506 },
3507
3508 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10003509 .vendor = "Atmel",
3510 .name = "AT49LH00B4",
3511 .bustype = BUS_LPC | BUS_FWH, /* A/A Mux */
3512 .manufacture_id = ATMEL_ID,
3513 .model_id = ATMEL_AT49LH00B4,
3514 .total_size = 512,
Andrew Morganca081462011-09-13 22:05:44 +00003515 .page_size = 0, /* unused */
Alan Green1f9cc7d2019-07-01 11:10:45 +10003516 .tested = TEST_UNTESTED,
3517 .probe = probe_82802ab,
Andrew Morganca081462011-09-13 22:05:44 +00003518 .probe_timing = TIMING_ZERO,
3519 .block_erasers =
3520 {
3521 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10003522 .eraseblocks = {
3523 {8 * 1024, 2},
3524 {16 * 1024, 1},
3525 {32 * 1024, 1},
3526 {64 * 1024, 7},
3527 },
3528 .block_erase = NULL, /* TODO: Implement. */
3529 }, {
3530 .eraseblocks = {
3531 {64 * 1024, 8},
3532 },
3533 .block_erase = erase_block_82802ab,
Andrew Morganca081462011-09-13 22:05:44 +00003534 },
3535 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10003536 .printlock = printlock_regspace2_block_eraser_0,
3537 .unlock = unlock_regspace2_block_eraser_0,
3538 .write = write_82802ab,
Andrew Morganca081462011-09-13 22:05:44 +00003539 .read = read_memmapped,
Alan Green1f9cc7d2019-07-01 11:10:45 +10003540 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +01003541 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +01003542 .finish_access = finish_memory_access,
Andrew Morganca081462011-09-13 22:05:44 +00003543 },
3544
3545 {
Angel Pons1ebda782021-04-20 21:39:11 +02003546 .vendor = "Boya/BoHong Microelectronics",
Christian Kudera475a7ee2021-04-20 22:50:01 +02003547 .name = "B.25D16A",
3548 .bustype = BUS_SPI,
3549 .manufacture_id = BOYA_BOHONG_ID,
3550 .model_id = BOYA_BOHONG_B_25D16A,
3551 .total_size = 2048,
3552 .page_size = 256,
3553 .feature_bits = FEATURE_WRSR_WREN,
3554 .tested = TEST_OK_PR,
3555 .probe = probe_spi_rdid,
3556 .probe_timing = TIMING_ZERO,
3557 .block_erasers =
3558 {
3559 {
3560 .eraseblocks = { {4 * 1024, 512} },
3561 .block_erase = spi_block_erase_20,
3562 }, {
3563 .eraseblocks = { {32 * 1024, 64} },
3564 .block_erase = spi_block_erase_52,
3565 }, {
3566 .eraseblocks = { {64 * 1024, 32} },
3567 .block_erase = spi_block_erase_d8,
3568 }, {
3569 .eraseblocks = { {2 * 1024 * 1024, 1} },
3570 .block_erase = spi_block_erase_60,
3571 }, {
3572 .eraseblocks = { {2 * 1024 * 1024, 1} },
3573 .block_erase = spi_block_erase_c7,
3574 }
3575 },
3576 .printlock = spi_prettyprint_status_register_bp2_srwd,
3577 .unlock = spi_disable_blockprotect_bp2_srwd,
3578 .write = spi_chip_write_256,
3579 .read = spi_chip_read,
3580 .voltage = {2700, 3600},
3581 },
3582
3583 {
3584 .vendor = "Boya/BoHong Microelectronics",
Angel Pons1ebda782021-04-20 21:39:11 +02003585 .name = "B.25Q128AS",
Jack Olsen73ae5ef2020-08-08 21:12:13 -05003586 .bustype = BUS_SPI,
Angel Pons1ebda782021-04-20 21:39:11 +02003587 .manufacture_id = BOYA_BOHONG_ID,
3588 .model_id = BOYA_BOHONG_B_25Q128AS,
Jack Olsen73ae5ef2020-08-08 21:12:13 -05003589 .total_size = 16384,
3590 .page_size = 256,
Nico Huber226bb872024-04-09 23:30:34 +02003591 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_WRSR3 |
3592 FEATURE_OTP | FEATURE_QIO,
Jack Olsen73ae5ef2020-08-08 21:12:13 -05003593 .tested = TEST_OK_PREW,
3594 .probe = probe_spi_rdid,
3595 .probe_timing = TIMING_ZERO,
3596 .block_erasers =
3597 {
3598 {
3599 .eraseblocks = { {4 * 1024, 4096} },
3600 .block_erase = spi_block_erase_20,
3601 }, {
3602 .eraseblocks = { {32 * 1024, 512} },
3603 .block_erase = spi_block_erase_52,
3604 }, {
3605 .eraseblocks = { {64 * 1024, 256} },
3606 .block_erase = spi_block_erase_d8,
3607 }, {
3608 .eraseblocks = { {16 * 1024 * 1024, 1} },
3609 .block_erase = spi_block_erase_60,
3610 }, {
3611 .eraseblocks = { {16 * 1024 * 1024, 1} },
3612 .block_erase = spi_block_erase_c7,
3613 }
3614 },
Nico Huber226bb872024-04-09 23:30:34 +02003615 .reg_bits =
3616 {
3617 .qe = {STATUS2, 1, RW},
3618 },
Jack Olsen73ae5ef2020-08-08 21:12:13 -05003619 .printlock = spi_prettyprint_status_register_plain,
3620 .unlock = spi_disable_blockprotect_at25fs040,
3621 .write = spi_chip_write_256,
3622 .read = spi_chip_read,
3623 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02003624 .prepare_access = spi_prepare_io,
3625 .finish_access = spi_finish_io,
Jack Olsen73ae5ef2020-08-08 21:12:13 -05003626 },
3627
3628 {
Joshua Roysf1324e02010-09-16 00:51:51 +00003629 .vendor = "Bright",
3630 .name = "BM29F040",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00003631 .bustype = BUS_PARALLEL,
Joshua Roysf1324e02010-09-16 00:51:51 +00003632 .manufacture_id = BRIGHT_ID,
3633 .model_id = BRIGHT_BM29F040,
3634 .total_size = 512,
3635 .page_size = 64 * 1024,
3636 .feature_bits = FEATURE_EITHER_RESET,
3637 .tested = TEST_OK_PR,
3638 .probe = probe_jedec,
3639 .probe_timing = TIMING_ZERO,
3640 .block_erasers =
3641 {
3642 {
3643 .eraseblocks = { {64 * 1024, 8} },
3644 .block_erase = erase_sector_jedec,
3645 }, {
3646 .eraseblocks = { {512 * 1024, 1} },
3647 .block_erase = erase_chip_block_jedec,
3648 },
3649 },
3650 .write = write_jedec_1,
3651 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +00003652 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01003653 .prepare_access = prepare_memory_access,
3654 .finish_access = finish_memory_access,
Joshua Roysf1324e02010-09-16 00:51:51 +00003655 },
3656
3657 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10003658 .vendor = "Catalyst",
3659 .name = "CAT28F512",
3660 .bustype = BUS_PARALLEL,
3661 .manufacture_id = CATALYST_ID,
3662 .model_id = CATALYST_CAT28F512,
3663 .total_size = 64,
3664 .page_size = 0, /* unused */
3665 .feature_bits = 0,
Alan Green908adf42019-07-03 15:34:06 +10003666 .tested = {.probe = OK, .read = OK, .erase = BAD, .write = BAD},
Alan Green1f9cc7d2019-07-01 11:10:45 +10003667 .probe = probe_jedec, /* FIXME! */
3668 .probe_timing = TIMING_ZERO,
3669 .block_erasers =
3670 {
3671 {
3672 .eraseblocks = { {64 * 1024, 1} },
3673 .block_erase = NULL, /* TODO */
3674 },
3675 },
3676 .write = NULL, /* TODO */
3677 .read = read_memmapped,
3678 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01003679 .prepare_access = prepare_memory_access,
3680 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10003681 },
3682
3683 {
Paul Kocialkowski80ae14e2018-01-15 01:07:46 +03003684 .vendor = "ENE",
3685 .name = "KB9012 (EDI)",
3686 .bustype = BUS_SPI,
Paul Kocialkowski80ae14e2018-01-15 01:07:46 +03003687 .total_size = 128,
3688 .page_size = 128,
3689 .feature_bits = FEATURE_ERASED_ZERO,
3690 .tested = TEST_OK_PREW,
Alan Greenc1863ca2019-06-27 15:08:03 +10003691 .spi_cmd_set = SPI_EDI,
Paul Kocialkowski80ae14e2018-01-15 01:07:46 +03003692 .probe = edi_probe_kb9012,
3693 .probe_timing = TIMING_ZERO,
3694 .block_erasers =
3695 {
3696 {
3697 .eraseblocks = { {128, 1024} },
3698 .block_erase = edi_chip_block_erase,
3699 },
3700 },
Paul Kocialkowski80ae14e2018-01-15 01:07:46 +03003701 .write = edi_chip_write,
3702 .read = edi_chip_read,
3703 .voltage = {2700, 3600},
Alan Greenc1863ca2019-06-27 15:08:03 +10003704 .gran = write_gran_128bytes,
Paul Kocialkowski80ae14e2018-01-15 01:07:46 +03003705 },
3706
3707 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10003708 .vendor = "ESI",
3709 .name = "ES25P16",
3710 .bustype = BUS_SPI,
3711 .manufacture_id = EXCEL_ID_NOPREFIX,
3712 .model_id = EXCEL_ES25P16,
3713 .total_size = 2 * 1024,
3714 .page_size = 256,
3715 /* 256-byte parameter page separate from memory array:
3716 * supports read (0x53), fast read (0x5B), erase (0xD5) and program (0x52) instructions. */
3717 .feature_bits = FEATURE_WRSR_WREN,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003718 .tested = TEST_UNTESTED,
Alan Green1f9cc7d2019-07-01 11:10:45 +10003719 .probe = probe_spi_rdid,
3720 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00003721 .block_erasers =
3722 {
3723 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10003724 .eraseblocks = { {64 * 1024, 32} },
3725 .block_erase = spi_block_erase_d8,
Sean Nelson54596372010-01-09 05:30:14 +00003726 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10003727 .eraseblocks = { {2 * 1024 * 1024, 1} },
3728 .block_erase = spi_block_erase_c7,
Sean Nelson54596372010-01-09 05:30:14 +00003729 }
3730 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10003731 .printlock = spi_prettyprint_status_register_bp2_srwd,
3732 .unlock = spi_disable_blockprotect_bp2_srwd,
3733 .write = spi_chip_write_256,
3734 .read = spi_chip_read, /* Fast Read (0x0B) supported */
3735 .voltage = {2700, 3600},
3736 },
3737
3738 {
3739 .vendor = "ESI",
3740 .name = "ES25P40",
3741 .bustype = BUS_SPI,
3742 .manufacture_id = EXCEL_ID_NOPREFIX,
3743 .model_id = EXCEL_ES25P40,
3744 .total_size = 512,
3745 .page_size = 256,
3746 /* 256-byte parameter page separate from memory array:
3747 * supports read (0x53), fast read (0x5B), erase (0xD5) and program (0x52) instructions. */
3748 .feature_bits = FEATURE_WRSR_WREN,
3749 .tested = TEST_UNTESTED,
3750 .probe = probe_spi_rdid,
3751 .probe_timing = TIMING_ZERO,
3752 .block_erasers =
3753 {
3754 {
3755 .eraseblocks = { {64 * 1024, 8} },
3756 .block_erase = spi_block_erase_d8,
3757 }, {
3758 .eraseblocks = { {512 * 1024, 1} },
3759 .block_erase = spi_block_erase_c7,
3760 }
3761 },
3762 .printlock = spi_prettyprint_status_register_bp2_srwd,
3763 .unlock = spi_disable_blockprotect_bp2_srwd,
3764 .write = spi_chip_write_256,
3765 .read = spi_chip_read, /* Fast Read (0x0B) supported */
3766 .voltage = {2700, 3600},
3767 },
3768
3769 {
3770 .vendor = "ESI",
3771 .name = "ES25P80",
3772 .bustype = BUS_SPI,
3773 .manufacture_id = EXCEL_ID_NOPREFIX,
3774 .model_id = EXCEL_ES25P80,
3775 .total_size = 1024,
3776 .page_size = 256,
3777 /* 256-byte parameter page separate from memory array:
3778 * supports read (0x53), fast read (0x5B), erase (0xD5) and program (0x52) instructions. */
3779 .feature_bits = FEATURE_WRSR_WREN,
3780 .tested = TEST_UNTESTED,
3781 .probe = probe_spi_rdid,
3782 .probe_timing = TIMING_ZERO,
3783 .block_erasers =
3784 {
3785 {
3786 .eraseblocks = { {64 * 1024, 16} },
3787 .block_erase = spi_block_erase_d8,
3788 }, {
3789 .eraseblocks = { {1024 * 1024, 1} },
3790 .block_erase = spi_block_erase_c7,
3791 }
3792 },
3793 .printlock = spi_prettyprint_status_register_bp2_srwd,
3794 .unlock = spi_disable_blockprotect_bp2_srwd,
3795 .write = spi_chip_write_256,
3796 .read = spi_chip_read, /* Fast Read (0x0B) supported */
3797 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00003798 },
3799
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00003800 {
Stefan Tauner352e50b2013-02-22 15:58:45 +00003801 .vendor = "ESMT",
Michael Karcher80a59ea2010-06-19 22:06:35 +00003802 .name = "F25L008A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00003803 .bustype = BUS_SPI,
Stefan Tauner352e50b2013-02-22 15:58:45 +00003804 .manufacture_id = ESMT_ID,
3805 .model_id = ESMT_F25L008A,
Michael Karcher80a59ea2010-06-19 22:06:35 +00003806 .total_size = 1024,
3807 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00003808 .feature_bits = FEATURE_WRSR_EITHER,
Stefan Taunereb582572012-09-21 12:52:50 +00003809 .tested = TEST_OK_PREW,
Michael Karcher80a59ea2010-06-19 22:06:35 +00003810 .probe = probe_spi_rdid,
3811 .probe_timing = TIMING_ZERO,
3812 .block_erasers =
3813 {
3814 {
3815 .eraseblocks = { {4 * 1024, 256} },
3816 .block_erase = spi_block_erase_20,
3817 }, {
3818 .eraseblocks = { {64 * 1024, 16} },
3819 .block_erase = spi_block_erase_d8,
3820 }, {
3821 .eraseblocks = { {1024 * 1024, 1} },
3822 .block_erase = spi_block_erase_60,
3823 }, {
3824 .eraseblocks = { {1024 * 1024, 1} },
3825 .block_erase = spi_block_erase_c7,
3826 }
3827 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00003828 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00003829 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger9a795d82010-07-14 16:19:05 +00003830 .write = spi_chip_write_1,
Michael Karcher4497e862010-07-10 19:34:15 +00003831 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00003832 .voltage = {2700, 3600},
Michael Karcher80a59ea2010-06-19 22:06:35 +00003833 },
3834
3835 {
Stefan Tauner85f09f72014-05-27 21:27:14 +00003836 .vendor = "ESMT",
3837 .name = "F25L32PA",
3838 .bustype = BUS_SPI,
3839 .manufacture_id = ESMT_ID,
3840 .model_id = ESMT_F25L32PA,
3841 .total_size = 4096,
3842 .page_size = 256,
3843 .feature_bits = FEATURE_WRSR_EITHER | FEATURE_OTP,
3844 .tested = TEST_UNTESTED,
3845 .probe = probe_spi_rdid,
3846 .probe_timing = TIMING_ZERO,
3847 .block_erasers =
3848 {
3849 {
3850 .eraseblocks = { {4 * 1024, 1024} },
3851 .block_erase = spi_block_erase_20,
3852 }, {
3853 .eraseblocks = { {64 * 1024, 64} },
3854 .block_erase = spi_block_erase_d8,
3855 }, {
3856 .eraseblocks = { {4 * 1024 * 1024, 1} },
3857 .block_erase = spi_block_erase_60,
3858 }, {
3859 .eraseblocks = { {4 * 1024 * 1024, 1} },
3860 .block_erase = spi_block_erase_c7,
3861 }
3862 },
3863 .printlock = spi_prettyprint_status_register_bp2_bpl,
3864 .unlock = spi_disable_blockprotect,
3865 .write = spi_chip_write_256,
3866 .read = spi_chip_read,
3867 .voltage = {2700, 3600},
3868 },
3869
3870 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10003871 .vendor = "ESMT",
3872 .name = "F49B002UA",
3873 .bustype = BUS_PARALLEL,
3874 .manufacture_id = ESMT_ID,
3875 .model_id = ESMT_F49B002UA,
3876 .total_size = 256,
3877 .page_size = 4096,
3878 .feature_bits = FEATURE_EITHER_RESET,
3879 .tested = TEST_UNTESTED,
3880 .probe = probe_jedec,
3881 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
3882 .block_erasers =
3883 {
3884 {
3885 .eraseblocks = {
3886 {128 * 1024, 1},
3887 {96 * 1024, 1},
3888 {8 * 1024, 2},
3889 {16 * 1024, 1},
3890 },
3891 .block_erase = erase_sector_jedec,
3892 }, {
3893 .eraseblocks = { {256 * 1024, 1} },
3894 .block_erase = erase_chip_block_jedec,
3895 }
3896 },
3897 .write = write_jedec_1,
3898 .read = read_memmapped,
3899 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01003900 .prepare_access = prepare_memory_access,
3901 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10003902 },
3903
3904 {
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00003905 .vendor = "Eon",
3906 .name = "EN25B05",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00003907 .bustype = BUS_SPI,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00003908 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00003909 .model_id = EON_EN25B05,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00003910 .total_size = 64,
3911 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00003912 .feature_bits = FEATURE_WRSR_WREN,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00003913 .tested = TEST_UNTESTED,
3914 .probe = probe_spi_rdid,
3915 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00003916 .block_erasers =
3917 {
3918 {
3919 .eraseblocks = {
3920 {4 * 1024, 2},
3921 {8 * 1024, 1},
3922 {16 * 1024, 1},
3923 {32 * 1024, 1},
3924 },
3925 .block_erase = spi_block_erase_d8,
3926 }, {
3927 .eraseblocks = { {64 * 1024, 1} },
3928 .block_erase = spi_block_erase_c7,
3929 }
3930 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00003931 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00003932 .unlock = spi_disable_blockprotect,
Sean Nelson54596372010-01-09 05:30:14 +00003933 .write = spi_chip_write_256,
Stefan Taunerb175af52015-01-24 15:06:27 +00003934 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +00003935 .voltage = {2700, 3600},
Sean Nelson54596372010-01-09 05:30:14 +00003936 },
3937
3938 {
3939 .vendor = "Eon",
3940 .name = "EN25B05T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00003941 .bustype = BUS_SPI,
Sean Nelson54596372010-01-09 05:30:14 +00003942 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00003943 .model_id = EON_EN25B05,
Sean Nelson54596372010-01-09 05:30:14 +00003944 .total_size = 64,
3945 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00003946 .feature_bits = FEATURE_WRSR_WREN,
Sean Nelson54596372010-01-09 05:30:14 +00003947 .tested = TEST_UNTESTED,
3948 .probe = probe_spi_rdid,
3949 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00003950 .block_erasers =
3951 {
3952 {
3953 .eraseblocks = {
3954 {32 * 1024, 1},
3955 {16 * 1024, 1},
3956 {8 * 1024, 1},
3957 {4 * 1024, 2},
3958 },
3959 .block_erase = spi_block_erase_d8,
3960 }, {
3961 .eraseblocks = { {64 * 1024, 1} },
3962 .block_erase = spi_block_erase_c7,
3963 }
3964 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00003965 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00003966 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00003967 .write = spi_chip_write_256,
Stefan Taunerb175af52015-01-24 15:06:27 +00003968 .read = spi_chip_read, /* Fast read (0x0B) supported */
3969 .voltage = {2700, 3600},
3970 },
3971
3972 {
3973 .vendor = "Eon",
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00003974 .name = "EN25B10",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00003975 .bustype = BUS_SPI,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00003976 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00003977 .model_id = EON_EN25B10,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00003978 .total_size = 128,
3979 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00003980 .feature_bits = FEATURE_WRSR_WREN,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00003981 .tested = TEST_UNTESTED,
3982 .probe = probe_spi_rdid,
3983 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00003984 .block_erasers =
3985 {
3986 {
3987 .eraseblocks = {
3988 {4 * 1024, 2},
3989 {8 * 1024, 1},
3990 {16 * 1024, 1},
3991 {32 * 1024, 3},
3992 },
3993 .block_erase = spi_block_erase_d8,
3994 }, {
3995 .eraseblocks = { {128 * 1024, 1} },
3996 .block_erase = spi_block_erase_c7,
3997 }
3998 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00003999 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00004000 .unlock = spi_disable_blockprotect,
Sean Nelson54596372010-01-09 05:30:14 +00004001 .write = spi_chip_write_256,
Stefan Taunerb175af52015-01-24 15:06:27 +00004002 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +00004003 .voltage = {2700, 3600},
Sean Nelson54596372010-01-09 05:30:14 +00004004 },
4005
4006 {
4007 .vendor = "Eon",
4008 .name = "EN25B10T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00004009 .bustype = BUS_SPI,
Sean Nelson54596372010-01-09 05:30:14 +00004010 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00004011 .model_id = EON_EN25B10,
Sean Nelson54596372010-01-09 05:30:14 +00004012 .total_size = 128,
4013 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00004014 .feature_bits = FEATURE_WRSR_WREN,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +00004015 .tested = TEST_OK_PREW,
Sean Nelson54596372010-01-09 05:30:14 +00004016 .probe = probe_spi_rdid,
4017 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00004018 .block_erasers =
4019 {
4020 {
4021 .eraseblocks = {
4022 {32 * 1024, 3},
4023 {16 * 1024, 1},
4024 {8 * 1024, 1},
4025 {4 * 1024, 2},
4026 },
4027 .block_erase = spi_block_erase_d8,
4028 }, {
4029 .eraseblocks = { {128 * 1024, 1} },
4030 .block_erase = spi_block_erase_c7,
4031 }
4032 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00004033 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00004034 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004035 .write = spi_chip_write_256,
Stefan Taunerb175af52015-01-24 15:06:27 +00004036 .read = spi_chip_read, /* Fast read (0x0B) supported */
4037 .voltage = {2700, 3600},
4038 },
4039
4040 {
4041 .vendor = "Eon",
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004042 .name = "EN25B16",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00004043 .bustype = BUS_SPI,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004044 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00004045 .model_id = EON_EN25B16,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004046 .total_size = 2048,
4047 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00004048 .feature_bits = FEATURE_WRSR_WREN,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004049 .tested = TEST_UNTESTED,
4050 .probe = probe_spi_rdid,
4051 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00004052 .block_erasers =
4053 {
4054 {
4055 .eraseblocks = {
4056 {4 * 1024, 2},
4057 {8 * 1024, 1},
4058 {16 * 1024, 1},
4059 {32 * 1024, 1},
4060 {64 * 1024, 31},
4061 },
4062 .block_erase = spi_block_erase_d8,
4063 }, {
4064 .eraseblocks = { {2 * 1024 * 1024, 1} },
4065 .block_erase = spi_block_erase_c7,
4066 }
4067 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00004068 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00004069 .unlock = spi_disable_blockprotect,
Sean Nelson54596372010-01-09 05:30:14 +00004070 .write = spi_chip_write_256,
Stefan Taunerb175af52015-01-24 15:06:27 +00004071 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +00004072 .voltage = {2700, 3600},
Sean Nelson54596372010-01-09 05:30:14 +00004073 },
4074
4075 {
4076 .vendor = "Eon",
4077 .name = "EN25B16T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00004078 .bustype = BUS_SPI,
Sean Nelson54596372010-01-09 05:30:14 +00004079 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00004080 .model_id = EON_EN25B16,
Sean Nelson54596372010-01-09 05:30:14 +00004081 .total_size = 2048,
4082 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +00004083 .feature_bits = FEATURE_WRSR_WREN,
Sean Nelson54596372010-01-09 05:30:14 +00004084 .tested = TEST_UNTESTED,
4085 .probe = probe_spi_rdid,
4086 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00004087 .block_erasers =
4088 {
4089 {
4090 .eraseblocks = {
4091 {64 * 1024, 31},
4092 {32 * 1024, 1},
4093 {16 * 1024, 1},
4094 {8 * 1024, 1},
4095 {4 * 1024, 2},
4096 },
4097 .block_erase = spi_block_erase_d8,
4098 }, {
4099 .eraseblocks = { {2 * 1024 * 1024, 1} },
4100 .block_erase = spi_block_erase_c7,
4101 }
4102 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00004103 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00004104 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004105 .write = spi_chip_write_256,
Stefan Taunerb175af52015-01-24 15:06:27 +00004106 .read = spi_chip_read, /* Fast read (0x0B) supported */
4107 .voltage = {2700, 3600},
4108 },
4109
4110 {
4111 .vendor = "Eon",
Alan Green1f9cc7d2019-07-01 11:10:45 +10004112 .name = "EN25B20",
Stefan Taunerb175af52015-01-24 15:06:27 +00004113 .bustype = BUS_SPI,
4114 .manufacture_id = EON_ID_NOPREFIX,
Alan Green1f9cc7d2019-07-01 11:10:45 +10004115 .model_id = EON_EN25B20,
4116 .total_size = 256,
Stefan Taunerb175af52015-01-24 15:06:27 +00004117 .page_size = 256,
4118 .feature_bits = FEATURE_WRSR_WREN,
4119 .tested = TEST_UNTESTED,
4120 .probe = probe_spi_rdid,
4121 .probe_timing = TIMING_ZERO,
4122 .block_erasers =
4123 {
4124 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10004125 .eraseblocks = {
4126 {4 * 1024, 2},
4127 {8 * 1024, 1},
4128 {16 * 1024, 1},
4129 {32 * 1024, 1},
4130 {64 * 1024, 3}
4131 },
Stefan Taunerb175af52015-01-24 15:06:27 +00004132 .block_erase = spi_block_erase_d8,
4133 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10004134 .eraseblocks = { {256 * 1024, 1} },
4135 .block_erase = spi_block_erase_c7,
4136 }
4137 },
4138 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4139 .unlock = spi_disable_blockprotect,
4140 .write = spi_chip_write_256,
4141 .read = spi_chip_read, /* Fast read (0x0B) supported */
4142 .voltage = {2700, 3600},
4143 },
4144
4145 {
4146 .vendor = "Eon",
4147 .name = "EN25B20T",
4148 .bustype = BUS_SPI,
4149 .manufacture_id = EON_ID_NOPREFIX,
4150 .model_id = EON_EN25B20,
4151 .total_size = 256,
4152 .page_size = 256,
4153 .feature_bits = FEATURE_WRSR_WREN,
4154 .tested = TEST_UNTESTED,
4155 .probe = probe_spi_rdid,
4156 .probe_timing = TIMING_ZERO,
4157 .block_erasers =
4158 {
4159 {
4160 .eraseblocks = {
4161 {64 * 1024, 3},
4162 {32 * 1024, 1},
4163 {16 * 1024, 1},
4164 {8 * 1024, 1},
4165 {4 * 1024, 2},
4166 },
4167 .block_erase = spi_block_erase_d8,
4168 }, {
4169 .eraseblocks = { {256 * 1024, 1} },
Stefan Taunerb175af52015-01-24 15:06:27 +00004170 .block_erase = spi_block_erase_c7,
4171 }
4172 },
4173 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4174 .unlock = spi_disable_blockprotect,
4175 .write = spi_chip_write_256,
4176 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +00004177 .voltage = {2700, 3600},
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004178 },
4179
4180 {
4181 .vendor = "Eon",
4182 .name = "EN25B32",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00004183 .bustype = BUS_SPI,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004184 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00004185 .model_id = EON_EN25B32,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004186 .total_size = 4096,
4187 .page_size = 256,
Stefan Taunerb175af52015-01-24 15:06:27 +00004188 /* OTP: 512B total; enter 0x3A */
4189 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004190 .tested = TEST_UNTESTED,
4191 .probe = probe_spi_rdid,
4192 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00004193 .block_erasers =
4194 {
4195 {
4196 .eraseblocks = {
4197 {4 * 1024, 2},
4198 {8 * 1024, 1},
4199 {16 * 1024, 1},
4200 {32 * 1024, 1},
4201 {64 * 1024, 63},
4202 },
4203 .block_erase = spi_block_erase_d8,
4204 }, {
4205 .eraseblocks = { {4 * 1024 * 1024, 1} },
4206 .block_erase = spi_block_erase_c7,
4207 }
4208 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00004209 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00004210 .unlock = spi_disable_blockprotect,
Sean Nelson54596372010-01-09 05:30:14 +00004211 .write = spi_chip_write_256,
Stefan Taunerb175af52015-01-24 15:06:27 +00004212 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +00004213 .voltage = {2700, 3600},
Sean Nelson54596372010-01-09 05:30:14 +00004214 },
4215
4216 {
4217 .vendor = "Eon",
4218 .name = "EN25B32T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00004219 .bustype = BUS_SPI,
Sean Nelson54596372010-01-09 05:30:14 +00004220 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00004221 .model_id = EON_EN25B32,
Sean Nelson54596372010-01-09 05:30:14 +00004222 .total_size = 4096,
4223 .page_size = 256,
Stefan Taunerb175af52015-01-24 15:06:27 +00004224 /* OTP: 512B total; enter 0x3A */
4225 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Sean Nelson54596372010-01-09 05:30:14 +00004226 .tested = TEST_UNTESTED,
4227 .probe = probe_spi_rdid,
4228 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00004229 .block_erasers =
4230 {
4231 {
4232 .eraseblocks = {
4233 {64 * 1024, 63},
4234 {32 * 1024, 1},
4235 {16 * 1024, 1},
4236 {8 * 1024, 1},
4237 {4 * 1024, 2},
4238 },
4239 .block_erase = spi_block_erase_d8,
4240 }, {
4241 .eraseblocks = { {4 * 1024 * 1024, 1} },
4242 .block_erase = spi_block_erase_c7,
4243 }
4244 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00004245 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00004246 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004247 .write = spi_chip_write_256,
Stefan Taunerb175af52015-01-24 15:06:27 +00004248 .read = spi_chip_read, /* Fast read (0x0B) supported */
4249 .voltage = {2700, 3600},
4250 },
4251
4252 {
4253 .vendor = "Eon",
Alan Green1f9cc7d2019-07-01 11:10:45 +10004254 .name = "EN25B40",
Stefan Taunerb175af52015-01-24 15:06:27 +00004255 .bustype = BUS_SPI,
4256 .manufacture_id = EON_ID_NOPREFIX,
Alan Green1f9cc7d2019-07-01 11:10:45 +10004257 .model_id = EON_EN25B40,
4258 .total_size = 512,
Stefan Taunerb175af52015-01-24 15:06:27 +00004259 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +10004260 .feature_bits = FEATURE_WRSR_WREN,
Stefan Taunerb175af52015-01-24 15:06:27 +00004261 .tested = TEST_UNTESTED,
4262 .probe = probe_spi_rdid,
4263 .probe_timing = TIMING_ZERO,
4264 .block_erasers =
4265 {
4266 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10004267 .eraseblocks = {
4268 {4 * 1024, 2},
4269 {8 * 1024, 1},
4270 {16 * 1024, 1},
4271 {32 * 1024, 1},
4272 {64 * 1024, 7}
4273 },
Stefan Taunerb175af52015-01-24 15:06:27 +00004274 .block_erase = spi_block_erase_d8,
4275 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10004276 .eraseblocks = { {512 * 1024, 1} },
4277 .block_erase = spi_block_erase_c7,
4278 }
4279 },
4280 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4281 .unlock = spi_disable_blockprotect,
4282 .write = spi_chip_write_256,
4283 .read = spi_chip_read, /* Fast read (0x0B) supported */
4284 .voltage = {2700, 3600},
4285 },
4286
4287 {
4288 .vendor = "Eon",
4289 .name = "EN25B40T",
4290 .bustype = BUS_SPI,
4291 .manufacture_id = EON_ID_NOPREFIX,
4292 .model_id = EON_EN25B40,
4293 .total_size = 512,
4294 .page_size = 256,
4295 .feature_bits = FEATURE_WRSR_WREN,
4296 .tested = TEST_UNTESTED,
4297 .probe = probe_spi_rdid,
4298 .probe_timing = TIMING_ZERO,
4299 .block_erasers =
4300 {
4301 {
4302 .eraseblocks = {
4303 {64 * 1024, 7},
4304 {32 * 1024, 1},
4305 {16 * 1024, 1},
4306 {8 * 1024, 1},
4307 {4 * 1024, 2},
4308 },
4309 .block_erase = spi_block_erase_d8,
4310 }, {
4311 .eraseblocks = { {512 * 1024, 1} },
Stefan Taunerb175af52015-01-24 15:06:27 +00004312 .block_erase = spi_block_erase_c7,
4313 }
4314 },
4315 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4316 .unlock = spi_disable_blockprotect,
4317 .write = spi_chip_write_256,
4318 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +00004319 .voltage = {2700, 3600},
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004320 },
4321
4322 {
4323 .vendor = "Eon",
4324 .name = "EN25B64",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00004325 .bustype = BUS_SPI,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004326 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00004327 .model_id = EON_EN25B64,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004328 .total_size = 8192,
4329 .page_size = 256,
Stefan Taunerb175af52015-01-24 15:06:27 +00004330 /* OTP: 512B total; enter 0x3A */
4331 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004332 .tested = TEST_UNTESTED,
4333 .probe = probe_spi_rdid,
4334 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00004335 .block_erasers =
4336 {
4337 {
4338 .eraseblocks = {
4339 {4 * 1024, 2},
4340 {8 * 1024, 1},
4341 {16 * 1024, 1},
4342 {32 * 1024, 1},
4343 {64 * 1024, 127},
4344 },
4345 .block_erase = spi_block_erase_d8,
4346 }, {
4347 .eraseblocks = { {8 * 1024 * 1024, 1} },
4348 .block_erase = spi_block_erase_c7,
4349 }
4350 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00004351 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00004352 .unlock = spi_disable_blockprotect,
Sean Nelson54596372010-01-09 05:30:14 +00004353 .write = spi_chip_write_256,
Stefan Taunerb175af52015-01-24 15:06:27 +00004354 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +00004355 .voltage = {2700, 3600},
Sean Nelson54596372010-01-09 05:30:14 +00004356 },
4357
4358 {
4359 .vendor = "Eon",
4360 .name = "EN25B64T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00004361 .bustype = BUS_SPI,
Sean Nelson54596372010-01-09 05:30:14 +00004362 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00004363 .model_id = EON_EN25B64,
Sean Nelson54596372010-01-09 05:30:14 +00004364 .total_size = 8192,
4365 .page_size = 256,
Stefan Taunerb175af52015-01-24 15:06:27 +00004366 /* OTP: 512B total; enter 0x3A */
4367 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Sean Nelson54596372010-01-09 05:30:14 +00004368 .tested = TEST_UNTESTED,
4369 .probe = probe_spi_rdid,
4370 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00004371 .block_erasers =
4372 {
4373 {
4374 .eraseblocks = {
4375 {64 * 1024, 127},
4376 {32 * 1024, 1},
4377 {16 * 1024, 1},
4378 {8 * 1024, 1},
4379 {4 * 1024, 2},
4380 },
4381 .block_erase = spi_block_erase_d8,
4382 }, {
4383 .eraseblocks = { {8 * 1024 * 1024, 1} },
4384 .block_erase = spi_block_erase_c7,
4385 }
4386 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00004387 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00004388 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004389 .write = spi_chip_write_256,
Stefan Taunerb175af52015-01-24 15:06:27 +00004390 .read = spi_chip_read, /* Fast read (0x0B) supported */
4391 .voltage = {2700, 3600},
4392 },
4393
4394 {
4395 .vendor = "Eon",
Alan Green1f9cc7d2019-07-01 11:10:45 +10004396 .name = "EN25B80",
Stefan Taunerb175af52015-01-24 15:06:27 +00004397 .bustype = BUS_SPI,
4398 .manufacture_id = EON_ID_NOPREFIX,
Alan Green1f9cc7d2019-07-01 11:10:45 +10004399 .model_id = EON_EN25B80,
4400 .total_size = 1024,
Stefan Taunerb175af52015-01-24 15:06:27 +00004401 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +10004402 .feature_bits = FEATURE_WRSR_WREN,
Stefan Taunerb175af52015-01-24 15:06:27 +00004403 .tested = TEST_UNTESTED,
4404 .probe = probe_spi_rdid,
4405 .probe_timing = TIMING_ZERO,
4406 .block_erasers =
4407 {
4408 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10004409 .eraseblocks = {
4410 {4 * 1024, 2},
4411 {8 * 1024, 1},
4412 {16 * 1024, 1},
4413 {32 * 1024, 1},
4414 {64 * 1024, 15}
4415 },
Stefan Taunerb175af52015-01-24 15:06:27 +00004416 .block_erase = spi_block_erase_d8,
4417 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10004418 .eraseblocks = { {1024 * 1024, 1} },
4419 .block_erase = spi_block_erase_c7,
4420 }
4421 },
4422 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4423 .unlock = spi_disable_blockprotect,
4424 .write = spi_chip_write_256,
4425 .read = spi_chip_read, /* Fast read (0x0B) supported */
4426 .voltage = {2700, 3600},
4427 },
4428
4429 {
4430 .vendor = "Eon",
4431 .name = "EN25B80T",
4432 .bustype = BUS_SPI,
4433 .manufacture_id = EON_ID_NOPREFIX,
4434 .model_id = EON_EN25B80,
4435 .total_size = 1024,
4436 .page_size = 256,
4437 .feature_bits = FEATURE_WRSR_WREN,
4438 .tested = TEST_UNTESTED,
4439 .probe = probe_spi_rdid,
4440 .probe_timing = TIMING_ZERO,
4441 .block_erasers =
4442 {
4443 {
4444 .eraseblocks = {
4445 {64 * 1024, 15},
4446 {32 * 1024, 1},
4447 {16 * 1024, 1},
4448 {8 * 1024, 1},
4449 {4 * 1024, 2},
4450 },
4451 .block_erase = spi_block_erase_d8,
4452 }, {
4453 .eraseblocks = { {1024 * 1024, 1} },
Stefan Taunerb175af52015-01-24 15:06:27 +00004454 .block_erase = spi_block_erase_c7,
4455 }
4456 },
4457 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4458 .unlock = spi_disable_blockprotect,
4459 .write = spi_chip_write_256,
4460 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +00004461 .voltage = {2700, 3600},
Carl-Daniel Hailfinger80243c92009-06-05 20:53:07 +00004462 },
4463
4464 {
4465 .vendor = "Eon",
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004466 .name = "EN25F05",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00004467 .bustype = BUS_SPI,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004468 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00004469 .model_id = EON_EN25F05,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004470 .total_size = 64,
4471 .page_size = 256,
David Hendricksd6c5dfc2010-09-03 03:18:26 +00004472 .feature_bits = FEATURE_WRSR_WREN,
Stefan Tauner0554ca52013-07-25 22:54:25 +00004473 .tested = TEST_OK_PREW,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004474 .probe = probe_spi_rdid,
4475 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00004476 .block_erasers =
4477 {
4478 {
4479 .eraseblocks = { {4 * 1024, 16} },
4480 .block_erase = spi_block_erase_20,
4481 }, {
4482 .eraseblocks = { {32 * 1024, 2} },
4483 .block_erase = spi_block_erase_d8,
4484 }, {
4485 .eraseblocks = { {32 * 1024, 2} },
4486 .block_erase = spi_block_erase_52,
4487 }, {
4488 .eraseblocks = { {64 * 1024, 1} },
4489 .block_erase = spi_block_erase_60,
4490 }, {
4491 .eraseblocks = { {64 * 1024, 1} },
4492 .block_erase = spi_block_erase_c7,
4493 }
4494 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00004495 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00004496 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004497 .write = spi_chip_write_256,
4498 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00004499 .voltage = {2700, 3600},
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004500 },
4501
4502 {
4503 .vendor = "Eon",
4504 .name = "EN25F10",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00004505 .bustype = BUS_SPI,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004506 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00004507 .model_id = EON_EN25F10,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004508 .total_size = 128,
4509 .page_size = 256,
David Hendricksd6c5dfc2010-09-03 03:18:26 +00004510 .feature_bits = FEATURE_WRSR_WREN,
Simon Buhrowd173ed42021-09-29 09:28:07 +02004511 .tested = TEST_OK_PREW,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004512 .probe = probe_spi_rdid,
4513 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00004514 .block_erasers =
4515 {
4516 {
4517 .eraseblocks = { {4 * 1024, 32} },
4518 .block_erase = spi_block_erase_20,
4519 }, {
4520 .eraseblocks = { {32 * 1024, 4} },
4521 .block_erase = spi_block_erase_d8,
4522 }, {
4523 .eraseblocks = { {32 * 1024, 4} },
4524 .block_erase = spi_block_erase_52,
4525 }, {
4526 .eraseblocks = { {128 * 1024, 1} },
4527 .block_erase = spi_block_erase_60,
4528 }, {
4529 .eraseblocks = { {128 * 1024, 1} },
4530 .block_erase = spi_block_erase_c7,
4531 }
4532 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00004533 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00004534 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004535 .write = spi_chip_write_256,
4536 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00004537 .voltage = {2700, 3600},
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004538 },
4539
4540 {
4541 .vendor = "Eon",
Alan Green1f9cc7d2019-07-01 11:10:45 +10004542 .name = "EN25F16",
4543 .bustype = BUS_SPI,
4544 .manufacture_id = EON_ID_NOPREFIX,
4545 .model_id = EON_EN25F16,
4546 .total_size = 2048,
4547 .page_size = 256,
4548 .feature_bits = FEATURE_WRSR_WREN,
4549 .tested = TEST_OK_PREW,
4550 .probe = probe_spi_rdid,
4551 .probe_timing = TIMING_ZERO,
4552 .block_erasers =
4553 {
4554 {
4555 .eraseblocks = { {4 * 1024, 512} },
4556 .block_erase = spi_block_erase_20,
4557 }, {
4558 .eraseblocks = { {64 * 1024, 32} },
4559 .block_erase = spi_block_erase_d8,
4560 }, {
4561 .eraseblocks = { {2 * 1024 * 1024, 1} },
4562 .block_erase = spi_block_erase_60,
4563 }, {
4564 .eraseblocks = { {2 * 1024 * 1024, 1} },
4565 .block_erase = spi_block_erase_c7,
4566 }
4567 },
4568 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4569 .unlock = spi_disable_blockprotect,
4570 .write = spi_chip_write_256,
4571 .read = spi_chip_read,
4572 .voltage = {2700, 3600},
4573 },
4574
4575 {
4576 .vendor = "Eon",
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004577 .name = "EN25F20",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00004578 .bustype = BUS_SPI,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004579 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00004580 .model_id = EON_EN25F20,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004581 .total_size = 256,
4582 .page_size = 256,
David Hendricksd6c5dfc2010-09-03 03:18:26 +00004583 .feature_bits = FEATURE_WRSR_WREN,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004584 .tested = TEST_UNTESTED,
4585 .probe = probe_spi_rdid,
4586 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00004587 .block_erasers =
4588 {
4589 {
4590 .eraseblocks = { {4 * 1024, 64} },
4591 .block_erase = spi_block_erase_20,
4592 }, {
4593 .eraseblocks = { {64 * 1024, 4} },
4594 .block_erase = spi_block_erase_d8,
4595 }, {
4596 .eraseblocks = { {64 * 1024, 4} },
4597 .block_erase = spi_block_erase_52,
4598 }, {
4599 .eraseblocks = { {256 * 1024, 1} },
4600 .block_erase = spi_block_erase_60,
4601 }, {
4602 .eraseblocks = { {256 * 1024, 1} },
4603 .block_erase = spi_block_erase_c7,
4604 }
4605 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00004606 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00004607 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004608 .write = spi_chip_write_256,
4609 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00004610 .voltage = {2700, 3600},
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004611 },
4612
4613 {
4614 .vendor = "Eon",
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004615 .name = "EN25F32",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00004616 .bustype = BUS_SPI,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004617 .manufacture_id = EON_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00004618 .model_id = EON_EN25F32,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004619 .total_size = 4096,
4620 .page_size = 256,
David Hendricksd6c5dfc2010-09-03 03:18:26 +00004621 .feature_bits = FEATURE_WRSR_WREN,
Stefan Tauner5c316f92015-02-08 21:57:52 +00004622 .tested = TEST_OK_PREW,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004623 .probe = probe_spi_rdid,
4624 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00004625 .block_erasers =
4626 {
4627 {
4628 .eraseblocks = { {4 * 1024, 1024} },
4629 .block_erase = spi_block_erase_20,
4630 }, {
4631 .eraseblocks = { {64 * 1024, 64} },
4632 .block_erase = spi_block_erase_d8,
4633 }, {
4634 .eraseblocks = { {4 * 1024 * 1024, 1} },
4635 .block_erase = spi_block_erase_60,
4636 }, {
4637 .eraseblocks = { {4 * 1024 * 1024, 1} },
4638 .block_erase = spi_block_erase_c7,
4639 }
4640 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00004641 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00004642 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004643 .write = spi_chip_write_256,
4644 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00004645 .voltage = {2700, 3600},
Carl-Daniel Hailfingera0a6ae92009-06-15 12:10:57 +00004646 },
4647
4648 {
Russ Dill3cd5a122010-03-05 08:44:11 +00004649 .vendor = "Eon",
Alan Green1f9cc7d2019-07-01 11:10:45 +10004650 .name = "EN25F40",
4651 .bustype = BUS_SPI,
4652 .manufacture_id = EON_ID_NOPREFIX,
4653 .model_id = EON_EN25F40,
4654 .total_size = 512,
4655 .page_size = 256,
4656 .feature_bits = FEATURE_WRSR_WREN,
4657 .tested = TEST_OK_PREW,
4658 .probe = probe_spi_rdid,
4659 .probe_timing = TIMING_ZERO,
4660 .block_erasers =
4661 {
4662 {
4663 .eraseblocks = { {4 * 1024, 128} },
4664 .block_erase = spi_block_erase_20,
4665 }, {
4666 .eraseblocks = { {64 * 1024, 8} },
4667 .block_erase = spi_block_erase_d8,
4668 }, {
4669 .eraseblocks = { {512 * 1024, 1} },
4670 .block_erase = spi_block_erase_60,
4671 }, {
4672 .eraseblocks = { {512 * 1024, 1} },
4673 .block_erase = spi_block_erase_c7,
4674 },
4675 },
4676 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4677 .unlock = spi_disable_blockprotect,
4678 .write = spi_chip_write_256,
4679 .read = spi_chip_read,
4680 .voltage = {2700, 3600},
4681 },
4682
4683 {
4684 .vendor = "Eon",
Stefan Taunerd932fd02012-09-06 17:37:16 +00004685 .name = "EN25F64",
4686 .bustype = BUS_SPI,
4687 .manufacture_id = EON_ID_NOPREFIX,
Stefan Taunerd7d423b2012-10-20 09:13:16 +00004688 .model_id = EON_EN25F64,
Stefan Taunerd932fd02012-09-06 17:37:16 +00004689 .total_size = 8192,
4690 .page_size = 256,
4691 .feature_bits = FEATURE_WRSR_WREN,
Stefan Taunere34e3e82013-01-01 00:06:51 +00004692 .tested = TEST_OK_PREW,
Stefan Taunerd932fd02012-09-06 17:37:16 +00004693 .probe = probe_spi_rdid,
4694 .probe_timing = TIMING_ZERO,
4695 .block_erasers =
4696 {
4697 {
4698 .eraseblocks = { {4 * 1024, 2048} },
4699 .block_erase = spi_block_erase_20,
4700 }, {
4701 .eraseblocks = { {64 * 1024, 128} },
4702 .block_erase = spi_block_erase_d8,
4703 }, {
4704 .eraseblocks = { {8 * 1024 * 1024, 1} },
4705 .block_erase = spi_block_erase_60,
4706 }, {
4707 .eraseblocks = { {8 * 1024 * 1024, 1} },
4708 .block_erase = spi_block_erase_c7,
4709 }
4710 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00004711 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Stefan Taunerd932fd02012-09-06 17:37:16 +00004712 .unlock = spi_disable_blockprotect,
4713 .write = spi_chip_write_256,
4714 .read = spi_chip_read,
4715 .voltage = {2700, 3600},
4716 },
4717
4718 {
4719 .vendor = "Eon",
Alan Green1f9cc7d2019-07-01 11:10:45 +10004720 .name = "EN25F80",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00004721 .bustype = BUS_SPI,
David Hendricks6d715302011-07-24 22:21:57 +00004722 .manufacture_id = EON_ID_NOPREFIX,
Alan Green1f9cc7d2019-07-01 11:10:45 +10004723 .model_id = EON_EN25F80,
David Hendricks6d715302011-07-24 22:21:57 +00004724 .total_size = 1024,
4725 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +10004726 .feature_bits = FEATURE_WRSR_WREN,
4727 .tested = TEST_OK_PREW,
David Hendricks6d715302011-07-24 22:21:57 +00004728 .probe = probe_spi_rdid,
4729 .probe_timing = TIMING_ZERO,
4730 .block_erasers =
4731 {
4732 {
4733 .eraseblocks = { {4 * 1024, 256} },
4734 .block_erase = spi_block_erase_20,
4735 }, {
4736 .eraseblocks = { {64 * 1024, 16} },
4737 .block_erase = spi_block_erase_d8,
4738 }, {
4739 .eraseblocks = { {1024 * 1024, 1} },
4740 .block_erase = spi_block_erase_60,
4741 }, {
4742 .eraseblocks = { {1024 * 1024, 1} },
4743 .block_erase = spi_block_erase_c7,
4744 }
4745 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00004746 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
David Hendricks6d715302011-07-24 22:21:57 +00004747 .unlock = spi_disable_blockprotect,
4748 .write = spi_chip_write_256,
4749 .read = spi_chip_read,
Stefan Taunereb582572012-09-21 12:52:50 +00004750 .voltage = {2700, 3600},
David Hendricks6d715302011-07-24 22:21:57 +00004751 },
4752
4753 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10004754 .vendor = "Eon",
4755 .name = "EN25P05",
4756 .bustype = BUS_SPI,
4757 .manufacture_id = EON_ID_NOPREFIX,
4758 .model_id = EON_EN25B05,
4759 .total_size = 64,
4760 .page_size = 256,
4761 .feature_bits = FEATURE_WRSR_WREN,
4762 .tested = TEST_UNTESTED,
4763 .probe = probe_spi_rdid,
4764 .probe_timing = TIMING_ZERO,
4765 .block_erasers =
4766 {
4767 {
4768 .eraseblocks = {
4769 {32 * 1024, 2} },
4770 .block_erase = spi_block_erase_d8,
4771 }, {
4772 .eraseblocks = { {64 * 1024, 1} },
4773 .block_erase = spi_block_erase_c7,
4774 }
4775 },
4776 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4777 .unlock = spi_disable_blockprotect,
4778 .write = spi_chip_write_256,
4779 .read = spi_chip_read, /* Fast read (0x0B) supported */
4780 .voltage = {2700, 3600},
4781 },
4782
4783 {
4784 .vendor = "Eon",
4785 .name = "EN25P10",
4786 .bustype = BUS_SPI,
4787 .manufacture_id = EON_ID_NOPREFIX,
4788 .model_id = EON_EN25B10,
4789 .total_size = 128,
4790 .page_size = 256,
4791 .feature_bits = FEATURE_WRSR_WREN,
4792 .tested = TEST_UNTESTED,
4793 .probe = probe_spi_rdid,
4794 .probe_timing = TIMING_ZERO,
4795 .block_erasers =
4796 {
4797 {
4798 .eraseblocks = { {32 * 1024, 4} },
4799 .block_erase = spi_block_erase_d8,
4800 }, {
4801 .eraseblocks = { {128 * 1024, 1} },
4802 .block_erase = spi_block_erase_c7,
4803 }
4804 },
4805 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4806 .unlock = spi_disable_blockprotect,
4807 .write = spi_chip_write_256,
4808 .read = spi_chip_read, /* Fast read (0x0B) supported */
4809 .voltage = {2700, 3600},
4810 },
4811
4812 {
4813 .vendor = "Eon",
4814 .name = "EN25P16",
4815 .bustype = BUS_SPI,
4816 .manufacture_id = EON_ID_NOPREFIX,
4817 .model_id = EON_EN25B16,
4818 .total_size = 2048,
4819 .page_size = 256,
4820 .feature_bits = FEATURE_WRSR_WREN,
4821 .tested = TEST_UNTESTED,
4822 .probe = probe_spi_rdid,
4823 .probe_timing = TIMING_ZERO,
4824 .block_erasers =
4825 {
4826 {
4827 .eraseblocks = { {64 * 1024, 32} },
4828 .block_erase = spi_block_erase_d8,
4829 }, {
4830 .eraseblocks = { {2 * 1024 * 1024, 1} },
4831 .block_erase = spi_block_erase_c7,
4832 }
4833 },
4834 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4835 .unlock = spi_disable_blockprotect,
4836 .write = spi_chip_write_256,
4837 .read = spi_chip_read, /* Fast read (0x0B) supported */
4838 .voltage = {2700, 3600},
4839 },
4840
4841 {
4842 .vendor = "Eon",
4843 .name = "EN25P20",
4844 .bustype = BUS_SPI,
4845 .manufacture_id = EON_ID_NOPREFIX,
4846 .model_id = EON_EN25B20,
4847 .total_size = 256,
4848 .page_size = 256,
4849 .feature_bits = FEATURE_WRSR_WREN,
4850 .tested = TEST_UNTESTED,
4851 .probe = probe_spi_rdid,
4852 .probe_timing = TIMING_ZERO,
4853 .block_erasers =
4854 {
4855 {
4856 .eraseblocks = { {64 * 1024, 4} },
4857 .block_erase = spi_block_erase_d8,
4858 }, {
4859 .eraseblocks = { {256 * 1024, 1} },
4860 .block_erase = spi_block_erase_c7,
4861 }
4862 },
4863 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4864 .unlock = spi_disable_blockprotect,
4865 .write = spi_chip_write_256,
4866 .read = spi_chip_read, /* Fast read (0x0B) supported */
4867 .voltage = {2700, 3600},
4868 },
4869
4870 {
4871 .vendor = "Eon",
4872 .name = "EN25P32", /* Uniform version of EN25B32 */
4873 .bustype = BUS_SPI,
4874 .manufacture_id = EON_ID_NOPREFIX,
4875 .model_id = EON_EN25B32,
4876 .total_size = 4096,
4877 .page_size = 256,
4878 /* OTP: 512B total; enter 0x3A */
4879 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
4880 .tested = TEST_UNTESTED,
4881 .probe = probe_spi_rdid,
4882 .probe_timing = TIMING_ZERO,
4883 .block_erasers =
4884 {
4885 {
4886 .eraseblocks = { {64 * 1024, 64} },
4887 .block_erase = spi_block_erase_d8,
4888 }, {
4889 .eraseblocks = { {4 * 1024 * 1024, 1} },
4890 .block_erase = spi_block_erase_c7,
4891 }
4892 },
4893 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4894 .unlock = spi_disable_blockprotect,
4895 .write = spi_chip_write_256,
4896 .read = spi_chip_read, /* Fast read (0x0B) supported */
4897 .voltage = {2700, 3600},
4898 },
4899
4900 {
4901 .vendor = "Eon",
4902 .name = "EN25P40",
4903 .bustype = BUS_SPI,
4904 .manufacture_id = EON_ID_NOPREFIX,
4905 .model_id = EON_EN25B40,
4906 .total_size = 512,
4907 .page_size = 256,
4908 .feature_bits = FEATURE_WRSR_WREN,
4909 .tested = TEST_UNTESTED,
4910 .probe = probe_spi_rdid,
4911 .probe_timing = TIMING_ZERO,
4912 .block_erasers =
4913 {
4914 {
4915 .eraseblocks = { {64 * 1024, 8} },
4916 .block_erase = spi_block_erase_d8,
4917 }, {
4918 .eraseblocks = { {512 * 1024, 1} },
4919 .block_erase = spi_block_erase_c7,
4920 }
4921 },
4922 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4923 .unlock = spi_disable_blockprotect,
4924 .write = spi_chip_write_256,
4925 .read = spi_chip_read, /* Fast read (0x0B) supported */
4926 .voltage = {2700, 3600},
4927 },
4928
4929 {
4930 .vendor = "Eon",
4931 .name = "EN25P64",
4932 .bustype = BUS_SPI,
4933 .manufacture_id = EON_ID_NOPREFIX,
4934 .model_id = EON_EN25B64,
4935 .total_size = 8192,
4936 .page_size = 256,
4937 /* OTP: 512B total; enter 0x3A */
4938 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
4939 .tested = TEST_UNTESTED,
4940 .probe = probe_spi_rdid,
4941 .probe_timing = TIMING_ZERO,
4942 .block_erasers =
4943 {
4944 {
4945 .eraseblocks = { {64 * 1024, 128} },
4946 .block_erase = spi_block_erase_d8,
4947 }, {
4948 .eraseblocks = { {8 * 1024 * 1024, 1} },
4949 .block_erase = spi_block_erase_c7,
4950 }
4951 },
4952 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4953 .unlock = spi_disable_blockprotect,
4954 .write = spi_chip_write_256,
4955 .read = spi_chip_read, /* Fast read (0x0B) supported */
4956 .voltage = {2700, 3600},
4957 },
4958
4959 {
4960 .vendor = "Eon",
4961 .name = "EN25P80",
4962 .bustype = BUS_SPI,
4963 .manufacture_id = EON_ID_NOPREFIX,
4964 .model_id = EON_EN25B80,
4965 .total_size = 1024,
4966 .page_size = 256,
4967 .feature_bits = FEATURE_WRSR_WREN,
4968 .tested = TEST_UNTESTED,
4969 .probe = probe_spi_rdid,
4970 .probe_timing = TIMING_ZERO,
4971 .block_erasers =
4972 {
4973 {
4974 .eraseblocks = { {64 * 1024, 16} },
4975 .block_erase = spi_block_erase_d8,
4976 }, {
4977 .eraseblocks = { {1024 * 1024, 1} },
4978 .block_erase = spi_block_erase_c7,
4979 }
4980 },
4981 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
4982 .unlock = spi_disable_blockprotect,
4983 .write = spi_chip_write_256,
4984 .read = spi_chip_read, /* Fast read (0x0B) supported */
4985 .voltage = {2700, 3600},
4986 },
4987
4988 {
4989 .vendor = "Eon",
4990 .name = "EN25Q128",
4991 .bustype = BUS_SPI,
4992 .manufacture_id = EON_ID_NOPREFIX,
4993 .model_id = EON_EN25Q128,
4994 .total_size = 16384,
4995 .page_size = 256,
4996 /* OTP: 512B total; enter 0x3A */
4997 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
4998 .tested = TEST_OK_PREW,
4999 .probe = probe_spi_rdid,
5000 .probe_timing = TIMING_ZERO,
5001 .block_erasers =
5002 {
5003 {
5004 .eraseblocks = { {4 * 1024, 4096} },
5005 .block_erase = spi_block_erase_20,
5006 }, {
5007 .eraseblocks = { {64 * 1024, 256} },
5008 .block_erase = spi_block_erase_d8,
5009 }, {
5010 .eraseblocks = { {16 * 1024 * 1024, 1} },
5011 .block_erase = spi_block_erase_60,
5012 }, {
5013 .eraseblocks = { {16 * 1024 * 1024, 1} },
5014 .block_erase = spi_block_erase_c7,
5015 }
5016 },
5017 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
5018 .unlock = spi_disable_blockprotect,
5019 .write = spi_chip_write_256,
5020 .read = spi_chip_read,
5021 },
5022
5023 {
David Hendricks6d715302011-07-24 22:21:57 +00005024 /* Note: EN25D16 is an evil twin which shares the model ID
5025 but has different write protection capabilities */
5026 .vendor = "Eon",
5027 .name = "EN25Q16",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00005028 .bustype = BUS_SPI,
David Hendricks6d715302011-07-24 22:21:57 +00005029 .manufacture_id = EON_ID_NOPREFIX,
5030 .model_id = EON_EN25Q16,
5031 .total_size = 2048,
5032 .page_size = 256,
Daniel Lenski65922a32012-02-15 23:40:23 +00005033 /* OTP: D16 512B/Q16 128B total; enter 0x3A */
5034 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
David Hendricks6d715302011-07-24 22:21:57 +00005035 .tested = TEST_UNTESTED,
5036 .probe = probe_spi_rdid,
5037 .probe_timing = TIMING_ZERO,
5038 .block_erasers =
5039 {
5040 {
5041 .eraseblocks = { {4 * 1024, 512} },
5042 .block_erase = spi_block_erase_20,
5043 }, {
5044 .eraseblocks = { {64 * 1024, 32} },
5045 .block_erase = spi_block_erase_d8,
5046 }, {
5047 /* not supported by Q16 version */
5048 .eraseblocks = { {64 * 1024, 32} },
5049 .block_erase = spi_block_erase_52,
5050 }, {
5051 .eraseblocks = { {2 * 1024 * 1024, 1} },
5052 .block_erase = spi_block_erase_60,
5053 }, {
5054 .eraseblocks = { {2 * 1024 * 1024, 1} },
5055 .block_erase = spi_block_erase_c7,
5056 }
5057 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00005058 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
David Hendricks6d715302011-07-24 22:21:57 +00005059 .unlock = spi_disable_blockprotect,
5060 .write = spi_chip_write_256,
5061 .read = spi_chip_read,
5062 .voltage = {2700, 3600},
5063 },
5064
5065 {
5066 .vendor = "Eon",
5067 .name = "EN25Q32(A/B)",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00005068 .bustype = BUS_SPI,
David Hendricks6d715302011-07-24 22:21:57 +00005069 .manufacture_id = EON_ID_NOPREFIX,
5070 .model_id = EON_EN25Q32,
5071 .total_size = 4096,
5072 .page_size = 256,
Daniel Lenski65922a32012-02-15 23:40:23 +00005073 /* OTP: 512B total; enter 0x3A */
5074 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Stefan Tauner352e50b2013-02-22 15:58:45 +00005075 .tested = TEST_OK_PREW,
David Hendricks6d715302011-07-24 22:21:57 +00005076 .probe = probe_spi_rdid,
5077 .probe_timing = TIMING_ZERO,
5078 .block_erasers =
5079 {
5080 {
5081 .eraseblocks = { {4 * 1024, 1024} },
5082 .block_erase = spi_block_erase_20,
5083 }, {
5084 .eraseblocks = { {64 * 1024, 64} },
5085 .block_erase = spi_block_erase_d8,
5086 }, {
5087 .eraseblocks = { {4 * 1024 * 1024, 1} },
5088 .block_erase = spi_block_erase_60,
5089 }, {
5090 .eraseblocks = { {4 * 1024 * 1024, 1} },
5091 .block_erase = spi_block_erase_c7,
5092 }
5093 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00005094 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
David Hendricks6d715302011-07-24 22:21:57 +00005095 .unlock = spi_disable_blockprotect,
5096 .write = spi_chip_write_256,
5097 .read = spi_chip_read,
Stefan Taunereb582572012-09-21 12:52:50 +00005098 .voltage = {2700, 3600},
David Hendricks6d715302011-07-24 22:21:57 +00005099 },
5100
5101 {
5102 .vendor = "Eon",
Alan Green1f9cc7d2019-07-01 11:10:45 +10005103 .name = "EN25Q40",
5104 .bustype = BUS_SPI,
5105 .manufacture_id = EON_ID_NOPREFIX,
5106 .model_id = EON_EN25Q40,
5107 .total_size = 512,
5108 .page_size = 256,
5109 /* OTP: 256B total; enter 0x3A */
5110 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
5111 .tested = TEST_UNTESTED,
5112 .probe = probe_spi_rdid,
5113 .probe_timing = TIMING_ZERO,
5114 .block_erasers =
5115 {
5116 {
5117 .eraseblocks = { {4 * 1024, 128} },
5118 .block_erase = spi_block_erase_20,
5119 }, {
5120 .eraseblocks = { {64 * 1024, 8} },
5121 .block_erase = spi_block_erase_d8,
5122 }, {
5123 .eraseblocks = { {512 * 1024, 1} },
5124 .block_erase = spi_block_erase_60,
5125 }, {
5126 .eraseblocks = { {512 * 1024, 1} },
5127 .block_erase = spi_block_erase_c7,
5128 }
5129 },
5130 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
5131 .unlock = spi_disable_blockprotect,
5132 .write = spi_chip_write_256,
5133 .read = spi_chip_read,
5134 .voltage = {2700, 3600},
5135 },
5136
5137 {
5138 .vendor = "Eon",
David Hendricks6d715302011-07-24 22:21:57 +00005139 .name = "EN25Q64",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00005140 .bustype = BUS_SPI,
David Hendricks6d715302011-07-24 22:21:57 +00005141 .manufacture_id = EON_ID_NOPREFIX,
5142 .model_id = EON_EN25Q64,
5143 .total_size = 8192,
5144 .page_size = 256,
Daniel Lenski65922a32012-02-15 23:40:23 +00005145 /* OTP: 512B total; enter 0x3A */
5146 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Stefan Tauner352e50b2013-02-22 15:58:45 +00005147 .tested = TEST_OK_PREW,
David Hendricks6d715302011-07-24 22:21:57 +00005148 .probe = probe_spi_rdid,
5149 .probe_timing = TIMING_ZERO,
5150 .block_erasers =
5151 {
5152 {
5153 .eraseblocks = { {4 * 1024, 2048} },
5154 .block_erase = spi_block_erase_20,
5155 }, {
5156 .eraseblocks = { {64 * 1024, 128} },
5157 .block_erase = spi_block_erase_d8,
5158 }, {
5159 .eraseblocks = { {8 * 1024 * 1024, 1} },
5160 .block_erase = spi_block_erase_60,
5161 }, {
5162 .eraseblocks = { {8 * 1024 * 1024, 1} },
5163 .block_erase = spi_block_erase_c7,
5164 }
5165 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00005166 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
David Hendricks6d715302011-07-24 22:21:57 +00005167 .unlock = spi_disable_blockprotect,
5168 .write = spi_chip_write_256,
5169 .read = spi_chip_read,
Stefan Taunereb582572012-09-21 12:52:50 +00005170 .voltage = {2700, 3600},
David Hendricks6d715302011-07-24 22:21:57 +00005171 },
5172
5173 {
5174 .vendor = "Eon",
Alan Green1f9cc7d2019-07-01 11:10:45 +10005175 .name = "EN25Q80(A)",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00005176 .bustype = BUS_SPI,
David Hendricks6d715302011-07-24 22:21:57 +00005177 .manufacture_id = EON_ID_NOPREFIX,
Alan Green1f9cc7d2019-07-01 11:10:45 +10005178 .model_id = EON_EN25Q80,
5179 .total_size = 1024,
5180 .page_size = 256,
5181 /* OTP: 256B total; enter 0x3A */
5182 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
5183 .tested = TEST_UNTESTED,
5184 .probe = probe_spi_rdid,
5185 .probe_timing = TIMING_ZERO,
5186 .block_erasers =
5187 {
5188 {
5189 .eraseblocks = { {4 * 1024, 256} },
5190 .block_erase = spi_block_erase_20,
5191 }, {
5192 .eraseblocks = { {64 * 1024, 16} },
5193 .block_erase = spi_block_erase_d8,
5194 }, {
5195 .eraseblocks = { {1024 * 1024, 1} },
5196 .block_erase = spi_block_erase_60,
5197 }, {
5198 .eraseblocks = { {1024 * 1024, 1} },
5199 .block_erase = spi_block_erase_c7,
5200 }
5201 },
5202 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
5203 .unlock = spi_disable_blockprotect,
5204 .write = spi_chip_write_256,
5205 .read = spi_chip_read,
5206 .voltage = {2700, 3600},
5207 },
5208
5209 {
5210 .vendor = "Eon",
5211 .name = "EN25QH128",
5212 .bustype = BUS_SPI,
5213 .manufacture_id = EON_ID_NOPREFIX,
5214 .model_id = EON_EN25QH128,
David Hendricks6d715302011-07-24 22:21:57 +00005215 .total_size = 16384,
5216 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +10005217 /* supports SFDP */
Daniel Lenski65922a32012-02-15 23:40:23 +00005218 /* OTP: 512B total; enter 0x3A */
Nico Huber1412d9f2024-01-06 18:25:49 +01005219 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | (FEATURE_QPI_38 & ~FEATURE_FAST_READ_QOUT),
5220 .dummy_cycles =
5221 {
5222 .qpi_fast_read = 6,
5223 .qpi_fast_read_qio = 6,
5224 },
Tim Chenbfe149a2020-07-06 14:59:21 +08005225 .tested = TEST_OK_PREW,
David Hendricks6d715302011-07-24 22:21:57 +00005226 .probe = probe_spi_rdid,
5227 .probe_timing = TIMING_ZERO,
5228 .block_erasers =
5229 {
5230 {
5231 .eraseblocks = { {4 * 1024, 4096} },
5232 .block_erase = spi_block_erase_20,
5233 }, {
5234 .eraseblocks = { {64 * 1024, 256} },
5235 .block_erase = spi_block_erase_d8,
5236 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10005237 .eraseblocks = { { 16384 * 1024, 1} },
David Hendricks6d715302011-07-24 22:21:57 +00005238 .block_erase = spi_block_erase_60,
5239 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10005240 .eraseblocks = { { 16384 * 1024, 1} },
David Hendricks6d715302011-07-24 22:21:57 +00005241 .block_erase = spi_block_erase_c7,
5242 }
5243 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10005244 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enable */
5245 .unlock = spi_disable_blockprotect_bp3_srwd,
David Hendricks6d715302011-07-24 22:21:57 +00005246 .write = spi_chip_write_256,
5247 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10005248 .voltage = {2700, 3600},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11005249 .reg_bits =
5250 {
5251 .srp = {STATUS1, 7, RW},
5252 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
5253 .tb = {STATUS1, 5, RW}, /* Called BP3 in datasheet, acts like TB */
5254 },
Nico Huberaabb3e02023-01-13 00:22:30 +01005255 .wp_write_cfg = spi_wp_write_cfg,
5256 .wp_read_cfg = spi_wp_read_cfg,
5257 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11005258 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +02005259 .prepare_access = spi_prepare_io,
5260 .finish_access = spi_finish_io,
David Hendricks6d715302011-07-24 22:21:57 +00005261 },
5262
5263 {
5264 .vendor = "Eon",
5265 .name = "EN25QH16",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00005266 .bustype = BUS_SPI,
David Hendricks6d715302011-07-24 22:21:57 +00005267 .manufacture_id = EON_ID_NOPREFIX,
5268 .model_id = EON_EN25QH16,
5269 .total_size = 2048,
5270 .page_size = 256,
Daniel Lenski65922a32012-02-15 23:40:23 +00005271 /* supports SFDP */
5272 /* OTP: 512B total; enter 0x3A */
Nico Huber1412d9f2024-01-06 18:25:49 +01005273 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | (FEATURE_QPI_38 & ~FEATURE_FAST_READ_QOUT),
5274 .dummy_cycles =
5275 {
5276 .qpi_fast_read = 6,
5277 .qpi_fast_read_qio = 6,
5278 },
Stefan Tauner5c316f92015-02-08 21:57:52 +00005279 .tested = TEST_OK_PREW,
David Hendricks6d715302011-07-24 22:21:57 +00005280 .probe = probe_spi_rdid,
5281 .probe_timing = TIMING_ZERO,
5282 .block_erasers =
5283 {
5284 {
5285 .eraseblocks = { {4 * 1024, 512} },
5286 .block_erase = spi_block_erase_20,
5287 }, {
5288 .eraseblocks = { {64 * 1024, 32} },
5289 .block_erase = spi_block_erase_d8,
5290 }, {
5291 .eraseblocks = { {1024 * 2048, 1} },
5292 .block_erase = spi_block_erase_60,
5293 }, {
5294 .eraseblocks = { {1024 * 2048, 1} },
5295 .block_erase = spi_block_erase_c7,
5296 }
5297 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00005298 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enable */
Nikolay Nikolaevc08542b2013-06-28 21:29:14 +00005299 .unlock = spi_disable_blockprotect_bp3_srwd,
David Hendricks6d715302011-07-24 22:21:57 +00005300 .write = spi_chip_write_256,
5301 .read = spi_chip_read,
Stefan Tauner2cef9162012-05-14 01:51:46 +00005302 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02005303 .prepare_access = spi_prepare_io,
5304 .finish_access = spi_finish_io,
Stefan Tauner2cef9162012-05-14 01:51:46 +00005305 },
5306
5307 {
5308 .vendor = "Eon",
5309 .name = "EN25QH32",
5310 .bustype = BUS_SPI,
5311 .manufacture_id = EON_ID_NOPREFIX,
5312 .model_id = EON_EN25QH32,
5313 .total_size = 4096,
5314 .page_size = 256,
5315 /* supports SFDP */
5316 /* OTP: 512B total; enter 0x3A */
Nico Huber1412d9f2024-01-06 18:25:49 +01005317 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | (FEATURE_QPI_38 & ~FEATURE_FAST_READ_QOUT),
5318 .dummy_cycles =
5319 {
5320 .qpi_fast_read = 6,
5321 .qpi_fast_read_qio = 6,
5322 },
Stefan Tauner23e10b82016-01-23 16:16:49 +00005323 .tested = TEST_OK_PREW,
Stefan Tauner2cef9162012-05-14 01:51:46 +00005324 .probe = probe_spi_rdid,
5325 .probe_timing = TIMING_ZERO,
5326 .block_erasers =
5327 {
5328 {
5329 .eraseblocks = { {4 * 1024, 1024} },
5330 .block_erase = spi_block_erase_20,
5331 }, {
5332 .eraseblocks = { {64 * 1024, 64} },
5333 .block_erase = spi_block_erase_d8,
5334 }, {
5335 .eraseblocks = { {1024 * 4096, 1} },
5336 .block_erase = spi_block_erase_60,
5337 }, {
5338 .eraseblocks = { {1024 * 4096, 1} },
5339 .block_erase = spi_block_erase_c7,
5340 }
5341 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00005342 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enable */
Nikolay Nikolaevc08542b2013-06-28 21:29:14 +00005343 .unlock = spi_disable_blockprotect_bp3_srwd,
5344 .write = spi_chip_write_256,
5345 .read = spi_chip_read,
5346 .voltage = {2700, 3600},
Sergii Dmytrukc6e8b1a2022-08-14 20:57:48 +03005347 .reg_bits =
5348 {
5349 .srp = {STATUS1, 7, RW},
5350 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
5351 .tb = {STATUS1, 5, RW}, /* Called BP3 in datasheet, acts like TB */
5352 },
Nico Huberaabb3e02023-01-13 00:22:30 +01005353 .wp_write_cfg = spi_wp_write_cfg,
5354 .wp_read_cfg = spi_wp_read_cfg,
5355 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukc6e8b1a2022-08-14 20:57:48 +03005356 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +02005357 .prepare_access = spi_prepare_io,
5358 .finish_access = spi_finish_io,
Sergii Dmytrukc6e8b1a2022-08-14 20:57:48 +03005359 },
5360
5361 {
5362 .vendor = "Eon",
5363 .name = "EN25QH32B",
5364 .bustype = BUS_SPI,
5365 .manufacture_id = EON_ID_NOPREFIX,
5366 .model_id = EON_EN25QH32,
5367 .total_size = 4096,
5368 .page_size = 256,
5369 /* supports SFDP */
5370 /* OTP: 1536B total; enter 0x3A */
Nico Huber1412d9f2024-01-06 18:25:49 +01005371 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QPI_38,
5372 .dummy_cycles =
5373 {
5374 .qpi_fast_read = 6,
5375 .qpi_fast_read_qio = 6,
5376 },
Sergii Dmytrukc6e8b1a2022-08-14 20:57:48 +03005377 .tested = TEST_OK_PREW,
5378 .probe = probe_spi_rdid,
5379 .probe_timing = TIMING_ZERO,
5380 .block_erasers =
5381 {
5382 {
5383 .eraseblocks = { {4 * 1024, 1024} },
5384 .block_erase = spi_block_erase_20,
5385 }, {
5386 .eraseblocks = { {32 * 1024, 128} },
5387 .block_erase = spi_block_erase_52,
5388 }, {
5389 .eraseblocks = { {64 * 1024, 64} },
5390 .block_erase = spi_block_erase_d8,
5391 }, {
5392 .eraseblocks = { {1024 * 4096, 1} },
5393 .block_erase = spi_block_erase_60,
5394 }, {
5395 .eraseblocks = { {1024 * 4096, 1} },
5396 .block_erase = spi_block_erase_c7,
5397 }
5398 },
5399 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enable */
5400 .unlock = spi_disable_blockprotect_bp3_srwd,
5401 .write = spi_chip_write_256,
5402 .read = spi_chip_read,
5403 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02005404 .prepare_access = spi_prepare_io,
5405 .finish_access = spi_finish_io,
Nikolay Nikolaevc08542b2013-06-28 21:29:14 +00005406 },
5407
5408 {
5409 .vendor = "Eon",
5410 .name = "EN25QH64",
5411 .bustype = BUS_SPI,
5412 .manufacture_id = EON_ID_NOPREFIX,
5413 .model_id = EON_EN25QH64,
5414 .total_size = 8192,
5415 .page_size = 256,
5416 /* supports SFDP */
5417 /* OTP: 512B total; enter 0x3A */
Nico Huber1412d9f2024-01-06 18:25:49 +01005418 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | (FEATURE_QPI_38 & ~FEATURE_FAST_READ_QOUT),
5419 .dummy_cycles =
5420 {
5421 .qpi_fast_read = 6,
5422 .qpi_fast_read_qio = 6,
5423 },
Stefan Tauner23e10b82016-01-23 16:16:49 +00005424 .tested = TEST_OK_PREW,
Nikolay Nikolaevc08542b2013-06-28 21:29:14 +00005425 .probe = probe_spi_rdid,
5426 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +10005427 .block_erasers =
5428 {
Nikolay Nikolaevc08542b2013-06-28 21:29:14 +00005429 {
5430 .eraseblocks = { {4 * 1024, 2048} },
5431 .block_erase = spi_block_erase_20,
5432 }, {
5433 .eraseblocks = { {64 * 1024, 128} },
5434 .block_erase = spi_block_erase_d8,
5435 }, {
5436 .eraseblocks = { { 8192 * 1024, 1} },
5437 .block_erase = spi_block_erase_60,
5438 }, {
5439 .eraseblocks = { { 8192 * 1024, 1} },
5440 .block_erase = spi_block_erase_c7,
5441 }
5442 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00005443 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enable */
Nikolay Nikolaevc08542b2013-06-28 21:29:14 +00005444 .unlock = spi_disable_blockprotect_bp3_srwd,
5445 .write = spi_chip_write_256,
5446 .read = spi_chip_read,
5447 .voltage = {2700, 3600},
Sergii Dmytrukc6e8b1a2022-08-14 20:57:48 +03005448 .reg_bits =
5449 {
5450 .srp = {STATUS1, 7, RW},
5451 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
5452 .tb = {STATUS1, 5, RW}, /* Called BP3 in datasheet, acts like TB */
5453 },
Nico Huberaabb3e02023-01-13 00:22:30 +01005454 .wp_write_cfg = spi_wp_write_cfg,
5455 .wp_read_cfg = spi_wp_read_cfg,
5456 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukc6e8b1a2022-08-14 20:57:48 +03005457 .decode_range = decode_range_spi25_64k_block,
Nico Huber930d4212024-05-04 18:59:15 +02005458 .prepare_access = spi_prepare_io,
5459 .finish_access = spi_finish_io,
Sergii Dmytrukc6e8b1a2022-08-14 20:57:48 +03005460 },
5461
5462 {
5463 .vendor = "Eon",
5464 .name = "EN25QH64A",
5465 .bustype = BUS_SPI,
5466 .manufacture_id = EON_ID_NOPREFIX,
5467 .model_id = EON_EN25QH64,
5468 .total_size = 8192,
5469 .page_size = 256,
5470 /* supports SFDP */
5471 /* OTP: 512B total; enter 0x3A */
Nico Huber1412d9f2024-01-06 18:25:49 +01005472 /* Has a special, volatile status register 3 that is written with
5473 0xc0 like Set Read Parameters. Hence treating as QPI_SRP. */
5474 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QPI_SRP,
5475 .dummy_cycles = { .qpi_read_params = { 6, 4, 8, 10 } },
Sergii Dmytrukc6e8b1a2022-08-14 20:57:48 +03005476 .tested = TEST_OK_PREW,
5477 .probe = probe_spi_rdid,
5478 .probe_timing = TIMING_ZERO,
5479 .block_erasers =
5480 {
5481 {
5482 .eraseblocks = { {4 * 1024, 2048} },
5483 .block_erase = spi_block_erase_20,
5484 }, {
5485 .eraseblocks = { {32 * 1024, 256} },
5486 .block_erase = spi_block_erase_52,
5487 }, {
5488 .eraseblocks = { {64 * 1024, 128} },
5489 .block_erase = spi_block_erase_d8,
5490 }, {
5491 .eraseblocks = { { 8192 * 1024, 1} },
5492 .block_erase = spi_block_erase_60,
5493 }, {
5494 .eraseblocks = { { 8192 * 1024, 1} },
5495 .block_erase = spi_block_erase_c7,
5496 }
5497 },
5498 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enable */
5499 .unlock = spi_disable_blockprotect_bp3_srwd,
5500 .write = spi_chip_write_256,
5501 .read = spi_chip_read,
5502 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02005503 .prepare_access = spi_prepare_io,
5504 .finish_access = spi_finish_io,
Nikolay Nikolaevc08542b2013-06-28 21:29:14 +00005505 },
5506
5507 {
5508 .vendor = "Eon",
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005509 .name = "EN25S10",
5510 .bustype = BUS_SPI,
5511 .manufacture_id = EON_ID_NOPREFIX,
5512 .model_id = EON_EN25S10,
5513 .total_size = 128,
5514 .page_size = 256,
5515 /* OTP: 256B total; enter 0x3A */
5516 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
5517 .tested = TEST_UNTESTED,
5518 .probe = probe_spi_rdid,
5519 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +10005520 .block_erasers =
5521 {
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005522 {
5523 .eraseblocks = { {4 * 1024, 32} },
5524 .block_erase = spi_block_erase_20,
5525 }, {
5526 .eraseblocks = { {32 * 1024, 4} },
5527 .block_erase = spi_block_erase_52,
5528 }, {
5529 .eraseblocks = { {128 * 1024, 1} },
5530 .block_erase = spi_block_erase_60,
5531 }, {
5532 .eraseblocks = { {128 * 1024, 1} },
5533 .block_erase = spi_block_erase_c7,
5534 }
5535 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00005536 .printlock = spi_prettyprint_status_register_bp2_srwd,
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005537 .unlock = spi_disable_blockprotect,
5538 .write = spi_chip_write_256,
5539 .read = spi_chip_read,
5540 .voltage = {1650, 1950},
5541 },
5542
5543 {
5544 .vendor = "Eon",
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005545 .name = "EN25S16",
5546 .bustype = BUS_SPI,
5547 .manufacture_id = EON_ID_NOPREFIX,
5548 .model_id = EON_EN25S16,
5549 .total_size = 2048,
5550 .page_size = 256,
5551 /* OTP: 512B total; enter 0x3A */
Nico Huber1412d9f2024-01-06 18:25:49 +01005552 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | (FEATURE_QPI_38 & ~FEATURE_FAST_READ_QOUT),
5553 .dummy_cycles =
5554 {
5555 .qpi_fast_read = 6,
5556 .qpi_fast_read_qio = 6,
5557 },
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005558 .tested = TEST_UNTESTED,
5559 .probe = probe_spi_rdid,
5560 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +10005561 .block_erasers =
5562 {
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005563 {
5564 .eraseblocks = { {4 * 1024, 512} },
5565 .block_erase = spi_block_erase_20,
5566 }, {
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005567 .eraseblocks = { {32 * 1024, 64} },
5568 .block_erase = spi_block_erase_d8,
5569 }, {
Aarya Chaumal478e1792022-06-04 01:34:44 +05305570 .eraseblocks = { {64 * 1024, 32} },
5571 .block_erase = spi_block_erase_52,
5572 }, {
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005573 .eraseblocks = { {2048 * 1024, 1} },
5574 .block_erase = spi_block_erase_60,
5575 }, {
5576 .eraseblocks = { {2048 * 1024, 1} },
5577 .block_erase = spi_block_erase_c7,
5578 }
5579 },
5580 .printlock = spi_prettyprint_status_register_en25s_wp,
5581 .unlock = spi_disable_blockprotect_bp3_srwd,
5582 .write = spi_chip_write_256,
5583 .read = spi_chip_read,
5584 .voltage = {1650, 1950},
Nico Huber930d4212024-05-04 18:59:15 +02005585 .prepare_access = spi_prepare_io,
5586 .finish_access = spi_finish_io,
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005587 },
5588
5589 {
5590 .vendor = "Eon",
Alan Green1f9cc7d2019-07-01 11:10:45 +10005591 .name = "EN25S20",
5592 .bustype = BUS_SPI,
5593 .manufacture_id = EON_ID_NOPREFIX,
5594 .model_id = EON_EN25S20,
5595 .total_size = 256,
5596 .page_size = 256,
5597 /* OTP: 256B total; enter 0x3A */
5598 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
5599 .tested = TEST_UNTESTED,
5600 .probe = probe_spi_rdid,
5601 .probe_timing = TIMING_ZERO,
5602 .block_erasers =
5603 {
5604 {
5605 .eraseblocks = { {4 * 1024, 64} },
5606 .block_erase = spi_block_erase_20,
5607 }, {
5608 .eraseblocks = { {64 * 1024, 4} },
5609 .block_erase = spi_block_erase_d8,
5610 }, {
5611 .eraseblocks = { {256 * 1024, 1} },
5612 .block_erase = spi_block_erase_60,
5613 }, {
5614 .eraseblocks = { {256 * 1024, 1} },
5615 .block_erase = spi_block_erase_c7,
5616 }
5617 },
5618 .printlock = spi_prettyprint_status_register_bp2_srwd,
5619 .unlock = spi_disable_blockprotect,
5620 .write = spi_chip_write_256,
5621 .read = spi_chip_read,
5622 .voltage = {1650, 1950},
5623 },
5624
5625 {
5626 .vendor = "Eon",
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005627 .name = "EN25S32",
5628 .bustype = BUS_SPI,
5629 .manufacture_id = EON_ID_NOPREFIX,
5630 .model_id = EON_EN25S32,
5631 .total_size = 4096,
5632 .page_size = 256,
5633 /* OTP: 512B total; enter 0x3A */
Nico Huber1412d9f2024-01-06 18:25:49 +01005634 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | (FEATURE_QPI_38 & ~FEATURE_FAST_READ_QOUT),
5635 .dummy_cycles =
5636 {
5637 .qpi_fast_read = 6,
5638 .qpi_fast_read_qio = 6,
5639 },
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005640 .tested = TEST_UNTESTED,
5641 .probe = probe_spi_rdid,
5642 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +10005643 .block_erasers =
5644 {
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005645 {
5646 .eraseblocks = { {4 * 1024, 1024} },
5647 .block_erase = spi_block_erase_20,
5648 }, {
5649 .eraseblocks = { {32 * 1024, 128} },
5650 .block_erase = spi_block_erase_52,
5651 }, {
5652 .eraseblocks = { {64 * 1024, 64} },
5653 .block_erase = spi_block_erase_d8,
5654 }, {
5655 .eraseblocks = { {4096 * 1024, 1} },
5656 .block_erase = spi_block_erase_60,
5657 }, {
5658 .eraseblocks = { {4096 * 1024, 1} },
5659 .block_erase = spi_block_erase_c7,
5660 }
5661 },
5662 .printlock = spi_prettyprint_status_register_en25s_wp,
5663 .unlock = spi_disable_blockprotect_bp3_srwd,
5664 .write = spi_chip_write_256,
5665 .read = spi_chip_read,
5666 .voltage = {1650, 1950},
Nico Huber930d4212024-05-04 18:59:15 +02005667 .prepare_access = spi_prepare_io,
5668 .finish_access = spi_finish_io,
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005669 },
5670
5671 {
5672 .vendor = "Eon",
Alan Green1f9cc7d2019-07-01 11:10:45 +10005673 .name = "EN25S40",
5674 .bustype = BUS_SPI,
5675 .manufacture_id = EON_ID_NOPREFIX,
5676 .model_id = EON_EN25S40,
5677 .total_size = 512,
5678 .page_size = 256,
5679 /* OTP: 256B total; enter 0x3A */
5680 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
5681 .tested = TEST_OK_PREW,
5682 .probe = probe_spi_rdid,
5683 .probe_timing = TIMING_ZERO,
5684 .block_erasers =
5685 {
5686 {
5687 .eraseblocks = { {4 * 1024, 128} },
5688 .block_erase = spi_block_erase_20,
5689 }, {
5690 .eraseblocks = { {64 * 1024, 8} },
5691 .block_erase = spi_block_erase_d8,
5692 }, {
5693 .eraseblocks = { {512 * 1024, 1} },
5694 .block_erase = spi_block_erase_60,
5695 }, {
5696 .eraseblocks = { {512 * 1024, 1} },
5697 .block_erase = spi_block_erase_c7,
5698 }
5699 },
5700 .printlock = spi_prettyprint_status_register_bp2_srwd,
5701 .unlock = spi_disable_blockprotect,
5702 .write = spi_chip_write_256,
5703 .read = spi_chip_read,
5704 .voltage = {1650, 1950},
5705 },
5706
5707 {
5708 .vendor = "Eon",
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005709 .name = "EN25S64",
5710 .bustype = BUS_SPI,
5711 .manufacture_id = EON_ID_NOPREFIX,
5712 .model_id = EON_EN25S64,
5713 .total_size = 8192,
5714 .page_size = 256,
5715 /* OTP: 512B total; enter 0x3A */
Nico Huber1412d9f2024-01-06 18:25:49 +01005716 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | (FEATURE_QPI_38 & ~FEATURE_FAST_READ_QOUT),
5717 .dummy_cycles =
5718 {
5719 .qpi_fast_read = 6,
5720 .qpi_fast_read_qio = 6,
5721 },
Nikolai Artemievdf889fa2021-03-23 17:10:45 +11005722 .tested = TEST_OK_PREW,
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005723 .probe = probe_spi_rdid,
5724 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +10005725 .block_erasers =
5726 {
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005727 {
5728 .eraseblocks = { {4 * 1024, 2048} },
5729 .block_erase = spi_block_erase_20,
5730 }, {
5731 .eraseblocks = { {64 * 1024, 128} },
5732 .block_erase = spi_block_erase_d8,
5733 }, {
5734 .eraseblocks = { {8192 * 1024, 1} },
5735 .block_erase = spi_block_erase_60,
5736 }, {
5737 .eraseblocks = { {8192 * 1024, 1} },
5738 .block_erase = spi_block_erase_c7,
5739 }
5740 },
5741 .printlock = spi_prettyprint_status_register_en25s_wp,
5742 .unlock = spi_disable_blockprotect_bp3_srwd,
5743 .write = spi_chip_write_256,
5744 .read = spi_chip_read,
5745 .voltage = {1650, 1950},
Nico Huber930d4212024-05-04 18:59:15 +02005746 .prepare_access = spi_prepare_io,
5747 .finish_access = spi_finish_io,
Nikolay Nikolaevd0e3ea12013-06-28 21:29:08 +00005748 },
5749
5750 {
5751 .vendor = "Eon",
Alan Green1f9cc7d2019-07-01 11:10:45 +10005752 .name = "EN25S80",
5753 .bustype = BUS_SPI,
5754 .manufacture_id = EON_ID_NOPREFIX,
5755 .model_id = EON_EN25S80,
5756 .total_size = 1024,
5757 .page_size = 256,
5758 /* OTP: 256B total; enter 0x3A */
5759 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
5760 .tested = TEST_UNTESTED,
5761 .probe = probe_spi_rdid,
5762 .probe_timing = TIMING_ZERO,
Russ Dill3cd5a122010-03-05 08:44:11 +00005763 .block_erasers =
5764 {
5765 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10005766 .eraseblocks = { {4 * 1024, 256} },
5767 .block_erase = spi_block_erase_20,
5768 }, {
5769 .eraseblocks = { {64 * 1024, 16} },
5770 .block_erase = spi_block_erase_d8,
5771 }, {
5772 .eraseblocks = { {1024 * 1024, 1} },
5773 .block_erase = spi_block_erase_60,
5774 }, {
5775 .eraseblocks = { {1024 * 1024, 1} },
5776 .block_erase = spi_block_erase_c7,
5777 }
Russ Dill3cd5a122010-03-05 08:44:11 +00005778 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10005779 .printlock = spi_prettyprint_status_register_bp2_srwd,
5780 .unlock = spi_disable_blockprotect,
5781 .write = spi_chip_write_256,
5782 .read = spi_chip_read,
5783 .voltage = {1650, 1950},
Russ Dill3cd5a122010-03-05 08:44:11 +00005784 },
5785
5786 {
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00005787 .vendor = "Eon",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00005788 .name = "EN29F002(A)(N)B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00005789 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00005790 .manufacture_id = EON_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00005791 .model_id = EON_EN29F002B,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00005792 .total_size = 256,
5793 .page_size = 256,
Sean Nelson35727f72010-01-28 23:55:12 +00005794 .feature_bits = FEATURE_ADDR_AAA | FEATURE_EITHER_RESET,
Alan Green4362e622019-08-26 15:02:12 +10005795 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00005796 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +00005797 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson6b11ad22009-12-23 17:05:59 +00005798 .block_erasers =
5799 {
5800 {
Rudolf Marek47eff6b2012-04-14 22:51:40 +00005801 .eraseblocks = {
Sean Nelson6b11ad22009-12-23 17:05:59 +00005802 {16 * 1024, 1},
Michael Karchere3cb0a12010-03-13 23:47:09 +00005803 {8 * 1024, 2},
5804 {32 * 1024, 1},
5805 {64 * 1024, 3},
Sean Nelson6b11ad22009-12-23 17:05:59 +00005806 },
5807 .block_erase = erase_sector_jedec,
5808 }, {
5809 .eraseblocks = { {256 * 1024, 1} },
5810 .block_erase = erase_chip_block_jedec,
5811 },
5812 },
Michael Karcher1c296ca2009-11-27 17:49:42 +00005813 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +00005814 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00005815 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01005816 .prepare_access = prepare_memory_access,
5817 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +00005818 },
5819
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00005820 {
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +00005821 .vendor = "Eon",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00005822 .name = "EN29F002(A)(N)T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00005823 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00005824 .manufacture_id = EON_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00005825 .model_id = EON_EN29F002T,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00005826 .total_size = 256,
5827 .page_size = 256,
Sean Nelson35727f72010-01-28 23:55:12 +00005828 .feature_bits = FEATURE_ADDR_AAA | FEATURE_EITHER_RESET,
Paul Menzel018d4822011-10-21 12:33:07 +00005829 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00005830 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +00005831 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson6b11ad22009-12-23 17:05:59 +00005832 .block_erasers =
5833 {
5834 {
Rudolf Marek47eff6b2012-04-14 22:51:40 +00005835 .eraseblocks = {
Sean Nelson6b11ad22009-12-23 17:05:59 +00005836 {64 * 1024, 3},
Michael Karchere3cb0a12010-03-13 23:47:09 +00005837 {32 * 1024, 1},
5838 {8 * 1024, 2},
5839 {16 * 1024, 1},
Sean Nelson6b11ad22009-12-23 17:05:59 +00005840 },
5841 .block_erase = erase_sector_jedec,
5842 }, {
5843 .eraseblocks = { {256 * 1024, 1} },
5844 .block_erase = erase_chip_block_jedec,
5845 },
5846 },
Michael Karcher1c296ca2009-11-27 17:49:42 +00005847 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +00005848 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00005849 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01005850 .prepare_access = prepare_memory_access,
5851 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +00005852 },
5853
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00005854 {
Rudolf Marek47eff6b2012-04-14 22:51:40 +00005855 .vendor = "Eon",
Alan Green1f9cc7d2019-07-01 11:10:45 +10005856 .name = "EN29F010",
Denis 'GNUtoo' Cariklib5f9d5c2014-12-07 21:57:53 +00005857 .bustype = BUS_PARALLEL,
5858 .manufacture_id = EON_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +10005859 .model_id = EON_EN29F010,
5860 .total_size = 128,
5861 .page_size = 128,
5862 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
5863 .tested = TEST_OK_PRE,
Denis 'GNUtoo' Cariklib5f9d5c2014-12-07 21:57:53 +00005864 .probe = probe_jedec,
Alan Green1f9cc7d2019-07-01 11:10:45 +10005865 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Denis 'GNUtoo' Cariklib5f9d5c2014-12-07 21:57:53 +00005866 .block_erasers =
5867 {
5868 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10005869 .eraseblocks = { {16 * 1024, 8} },
Denis 'GNUtoo' Cariklib5f9d5c2014-12-07 21:57:53 +00005870 .block_erase = erase_sector_jedec,
5871 },
5872 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10005873 .eraseblocks = { {128 * 1024, 1} },
Denis 'GNUtoo' Cariklib5f9d5c2014-12-07 21:57:53 +00005874 .block_erase = erase_chip_block_jedec,
5875 },
5876 },
5877 .write = write_jedec_1,
5878 .read = read_memmapped,
Alan Green1f9cc7d2019-07-01 11:10:45 +10005879 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01005880 .prepare_access = prepare_memory_access,
5881 .finish_access = finish_memory_access,
Rudolf Marek47eff6b2012-04-14 22:51:40 +00005882 },
5883
5884 {
Stefan Tauner03a9c3c2014-08-03 14:15:14 +00005885 .vendor = "Eon",
5886 .name = "EN29GL064(A)B",
5887 .bustype = BUS_PARALLEL,
5888 .manufacture_id = EON_ID,
5889 .model_id = EON_EN29GL064B,
5890 .total_size = 8192,
5891 .page_size = 128 * 1024, /* actual page size is 16 */
5892 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
5893 .tested = TEST_UNTESTED,
5894 .probe = probe_jedec_29gl,
5895 .probe_timing = TIMING_ZERO,
5896 .block_erasers =
5897 {
5898 {
5899 .eraseblocks = {
5900 {8 * 1024, 8},
5901 {64 * 1024, 127},
5902 },
5903 .block_erase = erase_sector_jedec,
5904 }, {
5905 .eraseblocks = { {8 * 1024 * 1024, 1} },
5906 .block_erase = erase_chip_block_jedec,
5907 },
5908 },
5909 .write = write_jedec_1,
5910 .read = read_memmapped,
5911 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +01005912 .prepare_access = prepare_memory_access,
5913 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +00005914 },
5915
5916 {
5917 .vendor = "Eon",
5918 .name = "EN29GL064(A)T",
5919 .bustype = BUS_PARALLEL,
5920 .manufacture_id = EON_ID,
5921 .model_id = EON_EN29GL064T,
5922 .total_size = 8192,
5923 .page_size = 128 * 1024, /* actual page size is 16 */
5924 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
5925 .tested = TEST_UNTESTED,
5926 .probe = probe_jedec_29gl,
5927 .probe_timing = TIMING_ZERO,
5928 .block_erasers =
5929 {
5930 {
5931 .eraseblocks = {
5932 {64 * 1024, 127},
5933 {8 * 1024, 8},
5934 },
5935 .block_erase = erase_sector_jedec,
5936 }, {
5937 .eraseblocks = { {8 * 1024 * 1024, 1} },
5938 .block_erase = erase_chip_block_jedec,
5939 },
5940 },
5941 .write = write_jedec_1,
5942 .read = read_memmapped,
5943 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +01005944 .prepare_access = prepare_memory_access,
5945 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +00005946 },
5947
5948 {
5949 .vendor = "Eon",
5950 .name = "EN29GL064H/L",
5951 .bustype = BUS_PARALLEL,
5952 .manufacture_id = EON_ID,
5953 .model_id = EON_EN29GL064HL,
5954 .total_size = 8192,
5955 .page_size = 128 * 1024, /* actual page size is 16 */
5956 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
5957 .tested = TEST_UNTESTED,
5958 .probe = probe_jedec_29gl,
5959 .probe_timing = TIMING_ZERO,
5960 .block_erasers =
5961 {
5962 {
5963 .eraseblocks = { {64 * 1024, 128} },
5964 .block_erase = erase_sector_jedec,
5965 }, {
5966 .eraseblocks = { {8 * 1024 * 1024, 1} },
5967 .block_erase = erase_chip_block_jedec,
5968 },
5969 },
5970 .write = write_jedec_1,
5971 .read = read_memmapped,
5972 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +01005973 .prepare_access = prepare_memory_access,
5974 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +00005975 },
5976
5977 {
5978 .vendor = "Eon",
5979 .name = "EN29GL128",
5980 .bustype = BUS_PARALLEL,
5981 .manufacture_id = EON_ID,
5982 .model_id = EON_EN29GL128HL,
5983 .total_size = 16384,
5984 .page_size = 128 * 1024, /* actual page size is 16 */
5985 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
5986 .tested = TEST_UNTESTED,
5987 .probe = probe_jedec_29gl,
5988 .probe_timing = TIMING_ZERO,
5989 .block_erasers =
5990 {
5991 {
5992 .eraseblocks = { {128 * 1024, 128} },
5993 .block_erase = erase_sector_jedec,
5994 }, {
5995 .eraseblocks = { {16 * 1024 * 1024, 1} },
5996 .block_erase = erase_chip_block_jedec,
5997 },
5998 },
5999 .write = write_jedec_1,
6000 .read = read_memmapped,
6001 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +01006002 .prepare_access = prepare_memory_access,
6003 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +00006004 },
6005
6006 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006007 .vendor = "Eon",
6008 .name = "EN29LV040(A)",
6009 .bustype = BUS_PARALLEL,
6010 .manufacture_id = EON_ID,
6011 .model_id = EON_EN29LV040,
Hatim Kanchwalab3d7fba2016-02-01 00:27:25 +00006012 .total_size = 512,
Alan Green1f9cc7d2019-07-01 11:10:45 +10006013 .page_size = 4 * 1024,
6014 .tested = TEST_OK_PREW,
6015 .probe = probe_jedec,
Hatim Kanchwalab3d7fba2016-02-01 00:27:25 +00006016 .probe_timing = TIMING_ZERO,
6017 .block_erasers =
6018 {
Stefan Tauner0be072c2016-03-13 15:16:30 +00006019 {
6020 .eraseblocks = { {64 * 1024, 8} },
Alan Green1f9cc7d2019-07-01 11:10:45 +10006021 .block_erase = erase_sector_jedec,
6022 },
6023 {
Stefan Tauner0be072c2016-03-13 15:16:30 +00006024 .eraseblocks = { {512 * 1024, 1} },
Alan Green1f9cc7d2019-07-01 11:10:45 +10006025 .block_erase = erase_chip_block_jedec,
6026 },
Hatim Kanchwalab3d7fba2016-02-01 00:27:25 +00006027 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10006028 .write = write_jedec_1,
6029 .read = read_memmapped,
6030 .voltage = {3000, 3600}, /* 3.0-3.6V for type -45R and 55R, others 2.7-3.6V */
Nico Huber9eec4072023-01-12 01:17:30 +01006031 .prepare_access = prepare_memory_access,
6032 .finish_access = finish_memory_access,
Hatim Kanchwalab3d7fba2016-02-01 00:27:25 +00006033 },
6034
6035 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006036 .vendor = "Eon",
6037 .name = "EN29LV640B",
6038 .bustype = BUS_PARALLEL,
6039 .manufacture_id = EON_ID,
6040 .model_id = EON_EN29LV640B,
6041 .total_size = 8192,
6042 .page_size = 8192,
6043 .feature_bits = FEATURE_ADDR_SHIFTED,
6044 .tested = TEST_OK_PREW,
6045 .probe = probe_en29lv640b,
6046 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Hatim Kanchwalab3d7fba2016-02-01 00:27:25 +00006047 .block_erasers =
6048 {
Stefan Tauner0be072c2016-03-13 15:16:30 +00006049 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006050 .eraseblocks = {
6051 {8 * 1024, 8},
6052 {64 * 1024, 127},
6053 },
6054 .block_erase = erase_block_jedec,
Stefan Tauner0be072c2016-03-13 15:16:30 +00006055 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006056 .eraseblocks = { {8 * 1024 * 1024, 1} },
6057 .block_erase = erase_chip_block_jedec,
6058 },
Hatim Kanchwalab3d7fba2016-02-01 00:27:25 +00006059 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10006060 .write = write_en29lv640b,
6061 .read = read_memmapped,
Hatim Kanchwalab3d7fba2016-02-01 00:27:25 +00006062 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +01006063 .prepare_access = prepare_memory_access,
6064 .finish_access = finish_memory_access,
Hatim Kanchwalab3d7fba2016-02-01 00:27:25 +00006065 },
6066
6067 {
Jakob Petersson0cf3e122019-02-18 01:55:43 +01006068 .vendor = "Fudan",
6069 .name = "FM25F005",
6070 .bustype = BUS_SPI,
6071 .manufacture_id = FUDAN_ID_NOPREFIX,
6072 .model_id = FUDAN_FM25F005,
6073 .total_size = 64,
6074 .page_size = 256,
6075 /* OTP: 256B total; enter 0x3A */
6076 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
6077 .tested = TEST_UNTESTED,
6078 .probe = probe_spi_rdid,
6079 .probe_timing = TIMING_ZERO,
6080 .block_erasers = {
6081 {
6082 .eraseblocks = { {4 * 1024, 16} },
6083 .block_erase = spi_block_erase_20,
6084 }, {
6085 .eraseblocks = { {32 * 1024, 2} },
6086 .block_erase = spi_block_erase_52,
6087 }, {
6088 .eraseblocks = { {64 * 1024, 1} },
6089 .block_erase = spi_block_erase_d8,
6090 }, {
6091 .eraseblocks = { {64 * 1024, 1} },
6092 .block_erase = spi_block_erase_60,
6093 }, {
6094 .eraseblocks = { {64 * 1024, 1} },
6095 .block_erase = spi_block_erase_c7,
6096 }
6097 },
6098 .printlock = spi_prettyprint_status_register_bp2_tb_bpl,
6099 .unlock = spi_disable_blockprotect_bp2_srwd,
6100 .write = spi_chip_write_256,
6101 .read = spi_chip_read, /* Fast read (0x0B), dual I/O (0x3B) supported */
6102 .voltage = {2700, 3600}, /* 2.3-2.7V acceptable results in lower performance */
6103 },
6104
6105 {
6106 .vendor = "Fudan",
6107 .name = "FM25F01",
6108 .bustype = BUS_SPI,
6109 .manufacture_id = FUDAN_ID_NOPREFIX,
6110 .model_id = FUDAN_FM25F01,
6111 .total_size = 128,
6112 .page_size = 256,
6113 /* OTP: 256B total; enter 0x3A */
6114 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
6115 .tested = TEST_UNTESTED,
6116 .probe = probe_spi_rdid,
6117 .probe_timing = TIMING_ZERO,
6118 .block_erasers = {
6119 {
6120 .eraseblocks = { {4 * 1024, 32} },
6121 .block_erase = spi_block_erase_20,
6122 }, {
6123 .eraseblocks = { {32 * 1024, 4} },
6124 .block_erase = spi_block_erase_52,
6125 }, {
6126 .eraseblocks = { {64 * 1024, 2} },
6127 .block_erase = spi_block_erase_d8,
6128 }, {
6129 .eraseblocks = { {128 * 1024, 1} },
6130 .block_erase = spi_block_erase_60,
6131 }, {
6132 .eraseblocks = { {128 * 1024, 1} },
6133 .block_erase = spi_block_erase_c7,
6134 }
6135 },
6136 .printlock = spi_prettyprint_status_register_bp2_tb_bpl,
6137 .unlock = spi_disable_blockprotect_bp2_srwd,
6138 .write = spi_chip_write_256,
6139 .read = spi_chip_read, /* Fast read (0x0B), dual I/O (0x3B) supported */
6140 .voltage = {2700, 3600}, /* 2.3-2.7V acceptable results in lower performance */
6141 },
6142
6143 {
6144 .vendor = "Fudan",
6145 .name = "FM25F02(A)",
6146 .bustype = BUS_SPI,
6147 .manufacture_id = FUDAN_ID_NOPREFIX,
6148 .model_id = FUDAN_FM25F02,
6149 .total_size = 256,
6150 .page_size = 256,
6151 /* OTP: 256B total; enter 0x3A, (A version only:) read ID 0x4B */
6152 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
6153 .tested = TEST_UNTESTED,
6154 .probe = probe_spi_rdid,
6155 .probe_timing = TIMING_ZERO,
6156 .block_erasers = {
6157 {
6158 .eraseblocks = { {4 * 1024, 64} },
6159 .block_erase = spi_block_erase_20,
6160 }, {
6161 .eraseblocks = { {32 * 1024, 8} },
6162 .block_erase = spi_block_erase_52,
6163 }, {
6164 .eraseblocks = { {64 * 1024, 4} },
6165 .block_erase = spi_block_erase_d8,
6166 }, {
6167 .eraseblocks = { {1024 * 256, 1} },
6168 .block_erase = spi_block_erase_60,
6169 }, {
6170 .eraseblocks = { {1024 * 256, 1} },
6171 .block_erase = spi_block_erase_c7,
6172 },
6173 },
6174 .printlock = spi_prettyprint_status_register_bp2_tb_bpl,
6175 .unlock = spi_disable_blockprotect_bp2_srwd,
6176 .write = spi_chip_write_256,
6177 .read = spi_chip_read, /* Fast read (0x0B), dual I/O (0x3B) supported */
6178 .voltage = {2700, 3600}, /* 2.3-2.7V acceptable results in lower performance */
6179 },
6180
6181 {
6182 .vendor = "Fudan",
6183 .name = "FM25F04(A)",
6184 .bustype = BUS_SPI,
6185 .manufacture_id = FUDAN_ID_NOPREFIX,
6186 .model_id = FUDAN_FM25F04,
6187 .total_size = 512,
6188 .page_size = 256,
6189 /* OTP: 256B total; enter 0x3A, (A version only:) read ID 0x4B */
6190 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
6191 .tested = TEST_UNTESTED,
6192 .probe = probe_spi_rdid,
6193 .probe_timing = TIMING_ZERO,
6194 .block_erasers = {
6195 {
6196 .eraseblocks = { {4 * 1024, 128} },
6197 .block_erase = spi_block_erase_20,
6198 }, {
6199 .eraseblocks = { {32 * 1024, 16} },
6200 .block_erase = spi_block_erase_52,
6201 }, {
6202 .eraseblocks = { {64 * 1024, 8} },
6203 .block_erase = spi_block_erase_d8,
6204 }, {
6205 .eraseblocks = { {1024 * 512, 1} },
6206 .block_erase = spi_block_erase_60,
6207 }, {
6208 .eraseblocks = { {1024 * 512, 1} },
6209 .block_erase = spi_block_erase_c7,
6210 },
6211 },
6212 .printlock = spi_prettyprint_status_register_bp2_tb_bpl,
6213 .unlock = spi_disable_blockprotect_bp2_srwd,
6214 .write = spi_chip_write_256,
6215 .read = spi_chip_read, /* Fast read (0x0B), dual I/O (0x3B) supported */
6216 .voltage = {2700, 3600},
6217 },
6218
6219 {
6220 .vendor = "Fudan",
6221 .name = "FM25Q08",
6222 .bustype = BUS_SPI,
6223 .manufacture_id = FUDAN_ID_NOPREFIX,
6224 .model_id = FUDAN_FM25Q08,
6225 .total_size = 1024,
6226 .page_size = 256,
6227 /* supports SFDP */
6228 /* OTP: 1024B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber226bb872024-04-09 23:30:34 +02006229 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 |
6230 FEATURE_OTP | FEATURE_QPI_SRP,
Nico Huber1412d9f2024-01-06 18:25:49 +01006231 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Jakob Petersson0cf3e122019-02-18 01:55:43 +01006232 .tested = TEST_UNTESTED,
6233 .probe = probe_spi_rdid,
6234 .probe_timing = TIMING_ZERO,
6235 .block_erasers = {
6236 {
6237 .eraseblocks = { {4 * 1024, 256} },
6238 .block_erase = spi_block_erase_20,
6239 }, {
6240 .eraseblocks = { {32 * 1024, 32} },
6241 .block_erase = spi_block_erase_52,
6242 }, {
6243 .eraseblocks = { {64 * 1024, 16} },
6244 .block_erase = spi_block_erase_d8,
6245 }, {
6246 .eraseblocks = { {1024 * 1024, 1} },
6247 .block_erase = spi_block_erase_60,
6248 }, {
6249 .eraseblocks = { {1024 * 1024, 1} },
6250 .block_erase = spi_block_erase_c7,
6251 },
6252 },
Nico Huber226bb872024-04-09 23:30:34 +02006253 .reg_bits =
6254 {
6255 .qe = {STATUS2, 1, RW},
6256 },
Jakob Petersson0cf3e122019-02-18 01:55:43 +01006257 .printlock = spi_prettyprint_status_register_bp2_tb_bpl, /* bit6 selects size of protected blocks; TODO: SR2 */
6258 .unlock = spi_disable_blockprotect_bp2_srwd,
6259 .write = spi_chip_write_256,
Nico Huber1412d9f2024-01-06 18:25:49 +01006260 .read = spi_chip_read,
Jakob Petersson0cf3e122019-02-18 01:55:43 +01006261 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02006262 .prepare_access = spi_prepare_io,
6263 .finish_access = spi_finish_io,
Jakob Petersson0cf3e122019-02-18 01:55:43 +01006264 },
6265
6266 {
6267 .vendor = "Fudan",
6268 .name = "FM25Q16",
6269 .bustype = BUS_SPI,
6270 .manufacture_id = FUDAN_ID_NOPREFIX,
6271 .model_id = FUDAN_FM25Q16,
6272 .total_size = 2048,
6273 .page_size = 256,
6274 /* supports SFDP */
6275 /* OTP: 1024B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber226bb872024-04-09 23:30:34 +02006276 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 |
6277 FEATURE_OTP | FEATURE_QPI_SRP,
Nico Huber1412d9f2024-01-06 18:25:49 +01006278 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Jakob Petersson0cf3e122019-02-18 01:55:43 +01006279 .tested = TEST_UNTESTED,
6280 .probe = probe_spi_rdid,
6281 .probe_timing = TIMING_ZERO,
6282 .block_erasers = {
6283 {
6284 .eraseblocks = { {4 * 1024, 512} },
6285 .block_erase = spi_block_erase_20,
6286 }, {
6287 .eraseblocks = { {32 * 1024, 64} },
6288 .block_erase = spi_block_erase_52,
6289 }, {
6290 .eraseblocks = { {64 * 1024, 32} },
6291 .block_erase = spi_block_erase_d8,
6292 }, {
6293 .eraseblocks = { {2 * 1024 * 1024, 1} },
6294 .block_erase = spi_block_erase_60,
6295 }, {
6296 .eraseblocks = { {2 * 1024 * 1024, 1} },
6297 .block_erase = spi_block_erase_c7,
6298 }
6299 },
Nico Huber226bb872024-04-09 23:30:34 +02006300 .reg_bits =
6301 {
6302 .qe = {STATUS2, 1, RW},
6303 },
Jakob Petersson0cf3e122019-02-18 01:55:43 +01006304 .printlock = spi_prettyprint_status_register_bp2_tb_bpl, /* bit6 selects size of protected blocks; TODO: SR2 */
6305 .unlock = spi_disable_blockprotect_bp2_srwd,
6306 .write = spi_chip_write_256,
Nico Huber1412d9f2024-01-06 18:25:49 +01006307 .read = spi_chip_read,
Jakob Petersson0cf3e122019-02-18 01:55:43 +01006308 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02006309 .prepare_access = spi_prepare_io,
6310 .finish_access = spi_finish_io,
Jakob Petersson0cf3e122019-02-18 01:55:43 +01006311 },
6312
6313 {
6314 .vendor = "Fudan",
6315 .name = "FM25Q32",
6316 .bustype = BUS_SPI,
6317 .manufacture_id = FUDAN_ID_NOPREFIX,
6318 .model_id = FUDAN_FM25Q32,
6319 .total_size = 4096,
6320 .page_size = 256,
6321 /* supports SFDP */
6322 /* OTP: 1024B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber226bb872024-04-09 23:30:34 +02006323 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 |
6324 FEATURE_OTP | FEATURE_QPI_SRP,
Nico Huber1412d9f2024-01-06 18:25:49 +01006325 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Jakob Petersson0cf3e122019-02-18 01:55:43 +01006326 .tested = TEST_UNTESTED,
6327 .probe = probe_spi_rdid,
6328 .probe_timing = TIMING_ZERO,
6329 .block_erasers = {
6330 {
6331 .eraseblocks = { {4 * 1024, 1024} },
6332 .block_erase = spi_block_erase_20,
6333 }, {
6334 .eraseblocks = { {32 * 1024, 128} },
6335 .block_erase = spi_block_erase_52,
6336 }, {
6337 .eraseblocks = { {64 * 1024, 64} },
6338 .block_erase = spi_block_erase_d8,
6339 }, {
6340 .eraseblocks = { {4 * 1024 * 1024, 1} },
6341 .block_erase = spi_block_erase_60,
6342 }, {
6343 .eraseblocks = { {4 * 1024 * 1024, 1} },
6344 .block_erase = spi_block_erase_c7,
6345 },
6346 },
Nico Huber226bb872024-04-09 23:30:34 +02006347 .reg_bits =
6348 {
6349 .qe = {STATUS2, 1, RW},
6350 },
Jakob Petersson0cf3e122019-02-18 01:55:43 +01006351 .printlock = spi_prettyprint_status_register_bp2_tb_bpl, /* bit6 selects size of protected blocks; TODO: SR2 */
6352 .unlock = spi_disable_blockprotect_bp2_srwd,
6353 .write = spi_chip_write_256,
Nico Huber1412d9f2024-01-06 18:25:49 +01006354 .read = spi_chip_read,
Jakob Petersson0cf3e122019-02-18 01:55:43 +01006355 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02006356 .prepare_access = spi_prepare_io,
6357 .finish_access = spi_finish_io,
Jakob Petersson0cf3e122019-02-18 01:55:43 +01006358 },
6359
6360 {
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006361 .vendor = "Fujitsu",
6362 .name = "MBM29F004BC",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00006363 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006364 .manufacture_id = FUJITSU_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00006365 .model_id = FUJITSU_MBM29F004BC,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006366 .total_size = 512,
6367 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +00006368 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006369 .tested = TEST_UNTESTED,
6370 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +00006371 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson6b11ad22009-12-23 17:05:59 +00006372 .block_erasers =
6373 {
6374 {
Stefan Tauner0554ca52013-07-25 22:54:25 +00006375 .eraseblocks = {
Sean Nelson6b11ad22009-12-23 17:05:59 +00006376 {16 * 1024, 1},
6377 {8 * 1024, 2},
6378 {32 * 1024, 1},
6379 {64 * 1024, 7},
6380 },
Sean Nelson35727f72010-01-28 23:55:12 +00006381 .block_erase = erase_sector_jedec,
Sean Nelson6b11ad22009-12-23 17:05:59 +00006382 }, {
6383 .eraseblocks = { {512 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +00006384 .block_erase = erase_chip_block_jedec,
Sean Nelson6b11ad22009-12-23 17:05:59 +00006385 },
6386 },
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006387 .write = NULL,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +00006388 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00006389 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01006390 .prepare_access = prepare_memory_access,
6391 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +00006392 },
6393
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006394 {
6395 .vendor = "Fujitsu",
6396 .name = "MBM29F004TC",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00006397 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006398 .manufacture_id = FUJITSU_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00006399 .model_id = FUJITSU_MBM29F004TC,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006400 .total_size = 512,
6401 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +00006402 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006403 .tested = TEST_UNTESTED,
6404 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +00006405 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson6b11ad22009-12-23 17:05:59 +00006406 .block_erasers =
6407 {
6408 {
Stefan Tauner0554ca52013-07-25 22:54:25 +00006409 .eraseblocks = {
Sean Nelson6b11ad22009-12-23 17:05:59 +00006410 {64 * 1024, 7},
6411 {32 * 1024, 1},
6412 {8 * 1024, 2},
6413 {16 * 1024, 1},
6414 },
Sean Nelson35727f72010-01-28 23:55:12 +00006415 .block_erase = erase_sector_jedec,
Sean Nelson6b11ad22009-12-23 17:05:59 +00006416 }, {
6417 .eraseblocks = { {512 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +00006418 .block_erase = erase_chip_block_jedec,
Sean Nelson6b11ad22009-12-23 17:05:59 +00006419 },
6420 },
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006421 .write = NULL,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +00006422 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00006423 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01006424 .prepare_access = prepare_memory_access,
6425 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +00006426 },
6427
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006428 {
Sean Nelson35727f72010-01-28 23:55:12 +00006429 /* FIXME: this has WORD/BYTE sequences; 2AA for word, 555 for byte */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006430 .vendor = "Fujitsu",
6431 .name = "MBM29F400BC",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00006432 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006433 .manufacture_id = FUJITSU_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00006434 .model_id = FUJITSU_MBM29F400BC,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006435 .total_size = 512,
6436 .page_size = 64 * 1024,
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006437 .feature_bits = FEATURE_ADDR_SHIFTED | FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Carl-Daniel Hailfinger79e67572010-10-13 21:49:30 +00006438 .tested = TEST_UNTESTED,
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006439 .probe = probe_jedec,
6440 .probe_timing = 10, // FIXME: check datasheet. Using the 10 us from probe_m29f400bt
Sean Nelson6b11ad22009-12-23 17:05:59 +00006441 .block_erasers =
6442 {
6443 {
Stefan Tauner0554ca52013-07-25 22:54:25 +00006444 .eraseblocks = {
Sean Nelson6b11ad22009-12-23 17:05:59 +00006445 {16 * 1024, 1},
6446 {8 * 1024, 2},
6447 {32 * 1024, 1},
6448 {64 * 1024, 7},
6449 },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006450 .block_erase = erase_sector_jedec,
Sean Nelson6b11ad22009-12-23 17:05:59 +00006451 }, {
6452 .eraseblocks = { {512 * 1024, 1} },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006453 .block_erase = erase_chip_block_jedec,
Sean Nelson6b11ad22009-12-23 17:05:59 +00006454 },
6455 },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006456 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +00006457 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +00006458 .voltage = {4750, 5250}, /* 4.75-5.25V for type -55, others 4.5-5.5V */
Nico Huber9eec4072023-01-12 01:17:30 +01006459 .prepare_access = prepare_memory_access,
6460 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +00006461 },
6462
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006463 {
6464 .vendor = "Fujitsu",
6465 .name = "MBM29F400TC",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00006466 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006467 .manufacture_id = FUJITSU_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00006468 .model_id = FUJITSU_MBM29F400TC,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006469 .total_size = 512,
6470 .page_size = 64 * 1024,
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006471 .feature_bits = FEATURE_ADDR_SHIFTED | FEATURE_ADDR_AAA | FEATURE_EITHER_RESET,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006472 .tested = TEST_UNTESTED,
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006473 .probe = probe_jedec,
6474 .probe_timing = 10, // FIXME: check datasheet. Using the 10 us from probe_m29f400bt
Sean Nelson6b11ad22009-12-23 17:05:59 +00006475 .block_erasers =
6476 {
6477 {
Stefan Tauner0554ca52013-07-25 22:54:25 +00006478 .eraseblocks = {
Sean Nelson6b11ad22009-12-23 17:05:59 +00006479 {64 * 1024, 7},
6480 {32 * 1024, 1},
6481 {8 * 1024, 2},
6482 {16 * 1024, 1},
6483 },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006484 .block_erase = erase_sector_jedec,
Sean Nelson6b11ad22009-12-23 17:05:59 +00006485 }, {
6486 .eraseblocks = { {512 * 1024, 1} },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006487 .block_erase = erase_chip_block_jedec,
Sean Nelson6b11ad22009-12-23 17:05:59 +00006488 },
6489 },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006490 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +00006491 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +00006492 .voltage = {4750, 5250}, /* 4.75-5.25V for type -55, others 4.5-5.5V */
Nico Huber9eec4072023-01-12 01:17:30 +01006493 .prepare_access = prepare_memory_access,
6494 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +00006495 },
6496
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00006497 {
Stefan Tauner6db8bad2013-08-25 13:31:43 +00006498 .vendor = "Fujitsu",
6499 .name = "MBM29LV160BE",
6500 .bustype = BUS_PARALLEL,
6501 .manufacture_id = FUJITSU_ID,
6502 .model_id = FUJITSU_MBM29LV160BE,
6503 .total_size = 2 * 1024,
6504 .page_size = 0,
6505 .feature_bits = FEATURE_ADDR_SHIFTED | FEATURE_SHORT_RESET,
6506 .tested = TEST_UNTESTED,
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006507 .probe = probe_jedec,
6508 .probe_timing = 10, // FIXME: check datasheet. Using the 10 us from probe_m29f400bt
Stefan Tauner6db8bad2013-08-25 13:31:43 +00006509 .block_erasers =
6510 {
6511 {
6512 .eraseblocks = {
6513 {16 * 1024, 1},
6514 {8 * 1024, 2},
6515 {32 * 1024, 1},
6516 {64 * 1024, 31},
6517 },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006518 .block_erase = erase_block_jedec,
Stefan Tauner6db8bad2013-08-25 13:31:43 +00006519 }, {
6520 .eraseblocks = { {2048 * 1024, 1} },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006521 .block_erase = erase_chip_block_jedec,
Stefan Tauner6db8bad2013-08-25 13:31:43 +00006522 },
6523 },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006524 .write = write_jedec_1, /* Supports a fast mode too */
Stefan Tauner6db8bad2013-08-25 13:31:43 +00006525 .read = read_memmapped,
6526 .voltage = {3000, 3600}, /* 3.0-3.6V for type -70, others 2.7-3.6V */
Nico Huber9eec4072023-01-12 01:17:30 +01006527 .prepare_access = prepare_memory_access,
6528 .finish_access = finish_memory_access,
Stefan Tauner6db8bad2013-08-25 13:31:43 +00006529 },
6530
6531 {
6532 .vendor = "Fujitsu",
6533 .name = "MBM29LV160TE",
6534 .bustype = BUS_PARALLEL,
6535 .manufacture_id = FUJITSU_ID,
6536 .model_id = FUJITSU_MBM29LV160TE,
6537 .total_size = 2 * 1024,
6538 .page_size = 0,
6539 .feature_bits = FEATURE_ADDR_SHIFTED | FEATURE_SHORT_RESET,
6540 .tested = TEST_UNTESTED,
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006541 .probe = probe_jedec,
6542 .probe_timing = 10, // FIXME: check datasheet. Using the 10 us from probe_m29f400bt
Stefan Tauner6db8bad2013-08-25 13:31:43 +00006543 .block_erasers =
6544 {
6545 {
6546 .eraseblocks = {
6547 {64 * 1024, 31},
6548 {32 * 1024, 1},
6549 {8 * 1024, 2},
6550 {16 * 1024, 1},
6551 },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006552 .block_erase = erase_block_jedec,
Stefan Tauner6db8bad2013-08-25 13:31:43 +00006553 }, {
6554 .eraseblocks = { {2048 * 1024, 1} },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006555 .block_erase = erase_chip_block_jedec,
Stefan Tauner6db8bad2013-08-25 13:31:43 +00006556 },
6557 },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +00006558 .write = write_jedec_1, /* Supports a fast mode too */
Stefan Tauner6db8bad2013-08-25 13:31:43 +00006559 .read = read_memmapped,
6560 .voltage = {3000, 3600}, /* 3.0-3.6V for type -70, others 2.7-3.6V */
Nico Huber9eec4072023-01-12 01:17:30 +01006561 .prepare_access = prepare_memory_access,
6562 .finish_access = finish_memory_access,
Stefan Tauner6db8bad2013-08-25 13:31:43 +00006563 },
6564
6565 {
Justin Chevrier1525b2a2012-04-14 21:59:23 +00006566 .vendor = "GigaDevice",
Alan Green1f9cc7d2019-07-01 11:10:45 +10006567 .name = "GD25B128B/GD25Q128B",
Roman Titov95edc892015-04-03 21:29:04 +00006568 .bustype = BUS_SPI,
6569 .manufacture_id = GIGADEVICE_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +10006570 .model_id = GIGADEVICE_GD25Q128,
6571 .total_size = 16384,
Roman Titov95edc892015-04-03 21:29:04 +00006572 .page_size = 256,
6573 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01006574 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +10006575 .tested = TEST_OK_PREW,
Roman Titov95edc892015-04-03 21:29:04 +00006576 .probe = probe_spi_rdid,
6577 .probe_timing = TIMING_ZERO,
6578 .block_erasers =
6579 {
6580 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006581 .eraseblocks = { {4 * 1024, 4096} },
Roman Titov95edc892015-04-03 21:29:04 +00006582 .block_erase = spi_block_erase_20,
6583 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006584 .eraseblocks = { {32 * 1024, 512} },
Roman Titov95edc892015-04-03 21:29:04 +00006585 .block_erase = spi_block_erase_52,
6586 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006587 .eraseblocks = { {64 * 1024, 256} },
Roman Titov95edc892015-04-03 21:29:04 +00006588 .block_erase = spi_block_erase_d8,
6589 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006590 .eraseblocks = { {16 * 1024 * 1024, 1} },
Roman Titov95edc892015-04-03 21:29:04 +00006591 .block_erase = spi_block_erase_60,
6592 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006593 .eraseblocks = { {16 * 1024 * 1024, 1} },
Roman Titov95edc892015-04-03 21:29:04 +00006594 .block_erase = spi_block_erase_c7,
6595 }
6596 },
Nico Huber4da971f2024-03-27 01:18:12 +01006597 .reg_bits =
6598 {
6599 .qe = {STATUS2, 1, RW}, /* RO 1 in GD25B128B case */
6600 },
Roman Titov95edc892015-04-03 21:29:04 +00006601 .printlock = spi_prettyprint_status_register_bp4_srwd,
6602 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
6603 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01006604 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10006605 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02006606 .prepare_access = spi_prepare_io,
6607 .finish_access = spi_finish_io,
Roman Titov95edc892015-04-03 21:29:04 +00006608 },
6609
6610 {
6611 .vendor = "GigaDevice",
Edward O'Callaghan981a3442021-06-22 11:16:55 +10006612 .name = "GD25LQ128C/GD25LQ128D/GD25LQ128E",
Roman Titov95edc892015-04-03 21:29:04 +00006613 .bustype = BUS_SPI,
6614 .manufacture_id = GIGADEVICE_ID,
Alan Green188127e2019-08-06 16:10:34 +10006615 .model_id = GIGADEVICE_GD25LQ128CD,
Alan Green1f9cc7d2019-07-01 11:10:45 +10006616 .total_size = 16384,
Roman Titov95edc892015-04-03 21:29:04 +00006617 .page_size = 256,
6618 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01006619 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QPI_SRP,
6620 .dummy_cycles = { .qpi_read_params = { 4, 6, 8, 8 } },
Sergii Dmytrukc74eac22022-10-06 18:17:58 +03006621 .tested = TEST_OK_PREWB,
Roman Titov95edc892015-04-03 21:29:04 +00006622 .probe = probe_spi_rdid,
6623 .probe_timing = TIMING_ZERO,
6624 .block_erasers =
6625 {
6626 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006627 .eraseblocks = { {4 * 1024, 4096} },
Roman Titov95edc892015-04-03 21:29:04 +00006628 .block_erase = spi_block_erase_20,
6629 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006630 .eraseblocks = { {32 * 1024, 512} },
Roman Titov95edc892015-04-03 21:29:04 +00006631 .block_erase = spi_block_erase_52,
6632 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006633 .eraseblocks = { {64 * 1024, 256} },
Roman Titov95edc892015-04-03 21:29:04 +00006634 .block_erase = spi_block_erase_d8,
6635 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006636 .eraseblocks = { {16 * 1024 * 1024, 1} },
Roman Titov95edc892015-04-03 21:29:04 +00006637 .block_erase = spi_block_erase_60,
6638 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006639 .eraseblocks = { {16 * 1024 * 1024, 1} },
Roman Titov95edc892015-04-03 21:29:04 +00006640 .block_erase = spi_block_erase_c7,
6641 }
6642 },
6643 .printlock = spi_prettyprint_status_register_bp4_srwd,
6644 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
6645 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01006646 .read = spi_chip_read,
Roman Titov95edc892015-04-03 21:29:04 +00006647 .voltage = {1695, 1950},
Nikolai Artemievc6c3f282021-10-20 23:34:15 +11006648 .reg_bits =
6649 {
Nico Huber4da971f2024-03-27 01:18:12 +01006650 .qe = {STATUS2, 1, RW},
Nikolai Artemievc6c3f282021-10-20 23:34:15 +11006651 .srp = {STATUS1, 7, RW},
6652 .srl = {STATUS2, 0, RW},
6653 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
6654 .tb = {STATUS1, 5, RW}, /* Called BP3 in datasheet, acts like TB */
6655 .sec = {STATUS1, 6, RW}, /* Called BP4 in datasheet, acts like SEC */
6656 .cmp = {STATUS2, 6, RW},
6657 },
Nico Huberaabb3e02023-01-13 00:22:30 +01006658 .wp_write_cfg = spi_wp_write_cfg,
6659 .wp_read_cfg = spi_wp_read_cfg,
6660 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievc9feb1b2021-10-21 01:35:13 +11006661 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +02006662 .prepare_access = spi_prepare_io,
6663 .finish_access = spi_finish_io,
Roman Titov95edc892015-04-03 21:29:04 +00006664 },
6665
6666 {
6667 .vendor = "GigaDevice",
6668 .name = "GD25LQ16",
6669 .bustype = BUS_SPI,
6670 .manufacture_id = GIGADEVICE_ID,
6671 .model_id = GIGADEVICE_GD25LQ16,
6672 .total_size = 2048,
6673 .page_size = 256,
6674 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01006675 /* FEATURE_QPI_SRP(4, 4, 6, 8) except for LQ16C */
6676 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Roman Titov95edc892015-04-03 21:29:04 +00006677 .tested = TEST_UNTESTED,
6678 .probe = probe_spi_rdid,
6679 .probe_timing = TIMING_ZERO,
6680 .block_erasers =
6681 {
6682 {
6683 .eraseblocks = { {4 * 1024, 512} },
6684 .block_erase = spi_block_erase_20,
6685 }, {
6686 .eraseblocks = { {32 * 1024, 64} },
6687 .block_erase = spi_block_erase_52,
6688 }, {
6689 .eraseblocks = { {64 * 1024, 32} },
6690 .block_erase = spi_block_erase_d8,
6691 }, {
6692 .eraseblocks = { {2 * 1024 * 1024, 1} },
6693 .block_erase = spi_block_erase_60,
6694 }, {
6695 .eraseblocks = { {2 * 1024 * 1024, 1} },
6696 .block_erase = spi_block_erase_c7,
6697 }
6698 },
Nico Huber4da971f2024-03-27 01:18:12 +01006699 .reg_bits =
6700 {
6701 .qe = {STATUS2, 1, RW},
6702 },
Roman Titov95edc892015-04-03 21:29:04 +00006703 .printlock = spi_prettyprint_status_register_bp4_srwd,
6704 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
6705 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01006706 .read = spi_chip_read,
Roman Titov95edc892015-04-03 21:29:04 +00006707 .voltage = {1695, 1950},
Nico Huber930d4212024-05-04 18:59:15 +02006708 .prepare_access = spi_prepare_io,
6709 .finish_access = spi_finish_io,
Roman Titov95edc892015-04-03 21:29:04 +00006710 },
6711
6712 {
6713 .vendor = "GigaDevice",
Nikolay Nikolaev3f3390b2013-06-28 21:28:56 +00006714 .name = "GD25LQ32",
6715 .bustype = BUS_SPI,
6716 .manufacture_id = GIGADEVICE_ID,
6717 .model_id = GIGADEVICE_GD25LQ32,
6718 .total_size = 4096,
6719 .page_size = 256,
6720 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01006721 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QPI_SRP,
6722 .dummy_cycles = { .qpi_read_params = { 4, 4, 6, 8 } },
Nikolay Nikolaev3f3390b2013-06-28 21:28:56 +00006723 .tested = TEST_OK_PREW,
6724 .probe = probe_spi_rdid,
6725 .probe_timing = TIMING_ZERO,
6726 .block_erasers =
6727 {
6728 {
6729 .eraseblocks = { {4 * 1024, 1024} },
6730 .block_erase = spi_block_erase_20,
6731 }, {
6732 .eraseblocks = { {32 * 1024, 128} },
6733 .block_erase = spi_block_erase_52,
6734 }, {
6735 .eraseblocks = { {64 * 1024, 64} },
6736 .block_erase = spi_block_erase_d8,
6737 }, {
6738 .eraseblocks = { {4 * 1024 * 1024, 1} },
6739 .block_erase = spi_block_erase_60,
6740 }, {
6741 .eraseblocks = { {4 * 1024 * 1024, 1} },
6742 .block_erase = spi_block_erase_c7,
6743 }
6744 },
Nico Huber4da971f2024-03-27 01:18:12 +01006745 .reg_bits =
6746 {
6747 .qe = {STATUS2, 1, RW},
6748 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00006749 .printlock = spi_prettyprint_status_register_bp4_srwd,
Nikolay Nikolaev3f3390b2013-06-28 21:28:56 +00006750 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
6751 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01006752 .read = spi_chip_read,
Roman Titov95edc892015-04-03 21:29:04 +00006753 .voltage = {1695, 1950},
Nico Huber930d4212024-05-04 18:59:15 +02006754 .prepare_access = spi_prepare_io,
6755 .finish_access = spi_finish_io,
Roman Titov95edc892015-04-03 21:29:04 +00006756 },
6757
6758 {
6759 .vendor = "GigaDevice",
Alan Green1f9cc7d2019-07-01 11:10:45 +10006760 .name = "GD25LQ40",
6761 .bustype = BUS_SPI,
6762 .manufacture_id = GIGADEVICE_ID,
6763 .model_id = GIGADEVICE_GD25LQ40,
6764 .total_size = 512,
6765 .page_size = 256,
6766 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01006767 /* FEATURE_QPI_SRP(4, 4, 6, 8) except for LQ40B, LQ40C */
6768 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +10006769 .tested = TEST_UNTESTED,
6770 .probe = probe_spi_rdid,
6771 .probe_timing = TIMING_ZERO,
6772 .block_erasers =
6773 {
6774 {
6775 .eraseblocks = { {4 * 1024, 128} },
6776 .block_erase = spi_block_erase_20,
6777 }, {
6778 .eraseblocks = { {32 * 1024, 16} },
6779 .block_erase = spi_block_erase_52,
6780 }, {
6781 .eraseblocks = { {64 * 1024, 8} },
6782 .block_erase = spi_block_erase_d8,
6783 }, {
6784 .eraseblocks = { {512 * 1024, 1} },
6785 .block_erase = spi_block_erase_60,
6786 }, {
6787 .eraseblocks = { {512 * 1024, 1} },
6788 .block_erase = spi_block_erase_c7,
6789 }
6790 },
Nico Huber4da971f2024-03-27 01:18:12 +01006791 .reg_bits =
6792 {
6793 .qe = {STATUS2, 1, RW},
6794 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10006795 .printlock = spi_prettyprint_status_register_bp4_srwd,
6796 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
6797 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01006798 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10006799 .voltage = {1695, 1950},
Nico Huber930d4212024-05-04 18:59:15 +02006800 .prepare_access = spi_prepare_io,
6801 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +10006802 },
6803
6804 {
6805 .vendor = "GigaDevice",
Roman Titov95edc892015-04-03 21:29:04 +00006806 .name = "GD25LQ64(B)",
6807 .bustype = BUS_SPI,
6808 .manufacture_id = GIGADEVICE_ID,
6809 .model_id = GIGADEVICE_GD25LQ64,
6810 .total_size = 8192,
6811 .page_size = 256,
6812 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01006813 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QPI_SRP,
6814 .dummy_cycles = { .qpi_read_params = { 4, 4, 6, 8 } },
Sergii Dmytrukc74eac22022-10-06 18:17:58 +03006815 .tested = TEST_OK_PREWB,
Roman Titov95edc892015-04-03 21:29:04 +00006816 .probe = probe_spi_rdid,
6817 .probe_timing = TIMING_ZERO,
6818 .block_erasers =
6819 {
6820 {
6821 .eraseblocks = { {4 * 1024, 2048} },
6822 .block_erase = spi_block_erase_20,
6823 }, {
6824 .eraseblocks = { {32 * 1024, 256} },
6825 .block_erase = spi_block_erase_52,
6826 }, {
6827 .eraseblocks = { {64 * 1024, 128} },
6828 .block_erase = spi_block_erase_d8,
6829 }, {
6830 .eraseblocks = { {8 * 1024 * 1024, 1} },
6831 .block_erase = spi_block_erase_60,
6832 }, {
6833 .eraseblocks = { {8 * 1024 * 1024, 1} },
6834 .block_erase = spi_block_erase_c7,
6835 }
6836 },
6837 .printlock = spi_prettyprint_status_register_bp4_srwd,
6838 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
6839 .write = spi_chip_write_256,
6840 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
6841 .voltage = {1695, 1950},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11006842 .reg_bits =
6843 {
Nico Huber4da971f2024-03-27 01:18:12 +01006844 .qe = {STATUS2, 1, RW},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11006845 .srp = {STATUS1, 7, RW},
6846 .srl = {STATUS2, 0, RW},
6847 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
6848 .tb = {STATUS1, 5, RW}, /* Called BP3 in datasheet, acts like TB */
6849 .sec = {STATUS1, 6, RW}, /* Called BP4 in datasheet, acts like SEC */
6850 .cmp = {STATUS2, 6, RW},
6851 },
Nico Huberaabb3e02023-01-13 00:22:30 +01006852 .wp_write_cfg = spi_wp_write_cfg,
6853 .wp_read_cfg = spi_wp_read_cfg,
6854 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11006855 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +02006856 .prepare_access = spi_prepare_io,
6857 .finish_access = spi_finish_io,
Roman Titov95edc892015-04-03 21:29:04 +00006858 },
6859
6860 {
6861 .vendor = "GigaDevice",
Alan Green1f9cc7d2019-07-01 11:10:45 +10006862 .name = "GD25LQ80",
Roman Titov95edc892015-04-03 21:29:04 +00006863 .bustype = BUS_SPI,
6864 .manufacture_id = GIGADEVICE_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +10006865 .model_id = GIGADEVICE_GD25LQ80,
6866 .total_size = 1024,
Roman Titov95edc892015-04-03 21:29:04 +00006867 .page_size = 256,
6868 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01006869 /* FEATURE_QPI_SRP(4, 4, 6, 8) except for LQ80B, LQ80C */
6870 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Roman Titov95edc892015-04-03 21:29:04 +00006871 .tested = TEST_UNTESTED,
6872 .probe = probe_spi_rdid,
6873 .probe_timing = TIMING_ZERO,
6874 .block_erasers =
6875 {
6876 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006877 .eraseblocks = { {4 * 1024, 256} },
Roman Titov95edc892015-04-03 21:29:04 +00006878 .block_erase = spi_block_erase_20,
6879 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006880 .eraseblocks = { {32 * 1024, 32} },
Roman Titov95edc892015-04-03 21:29:04 +00006881 .block_erase = spi_block_erase_52,
6882 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006883 .eraseblocks = { {64 * 1024, 16} },
Roman Titov95edc892015-04-03 21:29:04 +00006884 .block_erase = spi_block_erase_d8,
6885 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006886 .eraseblocks = { {1 * 1024 * 1024, 1} },
Roman Titov95edc892015-04-03 21:29:04 +00006887 .block_erase = spi_block_erase_60,
6888 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10006889 .eraseblocks = { {1 * 1024 * 1024, 1} },
Roman Titov95edc892015-04-03 21:29:04 +00006890 .block_erase = spi_block_erase_c7,
6891 }
6892 },
Nico Huber4da971f2024-03-27 01:18:12 +01006893 .reg_bits =
6894 {
6895 .qe = {STATUS2, 1, RW},
6896 },
Roman Titov95edc892015-04-03 21:29:04 +00006897 .printlock = spi_prettyprint_status_register_bp4_srwd,
6898 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
6899 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01006900 .read = spi_chip_read,
Roman Titov95edc892015-04-03 21:29:04 +00006901 .voltage = {1695, 1950},
Nico Huber930d4212024-05-04 18:59:15 +02006902 .prepare_access = spi_prepare_io,
6903 .finish_access = spi_finish_io,
Nikolay Nikolaev3f3390b2013-06-28 21:28:56 +00006904 },
6905
6906 {
6907 .vendor = "GigaDevice",
Naresh Solanki768cfc42024-10-04 20:17:34 +05306908 .name = "GD25LR512ME",
6909 .bustype = BUS_SPI,
6910 .manufacture_id = GIGADEVICE_ID,
6911 .model_id = GIGADEVICE_GD25LR512ME,
6912 .total_size = 65536,
6913 .page_size = 256,
6914 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA,
6915 .tested = TEST_OK_PREW,
6916 .probe = probe_spi_rdid,
6917 .probe_timing = TIMING_ZERO,
6918 .block_erasers =
6919 {
6920 {
6921 .eraseblocks = { {4 * 1024, 16384} },
6922 .block_erase = spi_block_erase_21,
6923 }, {
6924 .eraseblocks = { {4 * 1024, 16384} },
6925 .block_erase = spi_block_erase_20,
6926 }, {
6927 .eraseblocks = { {32 * 1024, 2048} },
6928 .block_erase = spi_block_erase_52,
6929 }, {
6930 .eraseblocks = { {32 * 1024, 2048} },
6931 .block_erase = spi_block_erase_5c,
6932 }, {
6933 .eraseblocks = { {64 * 1024, 1024} },
6934 .block_erase = spi_block_erase_dc,
6935 }, {
6936 .eraseblocks = { {64 * 1024, 1024} },
6937 .block_erase = spi_block_erase_d8,
6938 }, {
6939 .eraseblocks = { {64 * 1024 * 1024, 1} },
6940 .block_erase = spi_block_erase_60,
6941 }, {
6942 .eraseblocks = { {64 * 1024 * 1024, 1} },
6943 .block_erase = spi_block_erase_c7,
6944 }
6945 },
6946 .printlock = spi_prettyprint_status_register_bp4_srwd,
6947 .unlock = spi_disable_blockprotect_bp4_srwd,
6948 .write = spi_chip_write_256,
6949 .read = spi_chip_read,
6950 .voltage = {1650, 2000},
6951 .prepare_access = spi_prepare_io,
6952 .finish_access = spi_finish_io,
6953 },
6954
6955 {
6956 .vendor = "GigaDevice",
Nikolay Nikolaev3f3390b2013-06-28 21:28:56 +00006957 .name = "GD25Q10",
6958 .bustype = BUS_SPI,
6959 .manufacture_id = GIGADEVICE_ID,
6960 .model_id = GIGADEVICE_GD25Q10,
6961 .total_size = 128,
6962 .page_size = 256,
Nico Huber4da971f2024-03-27 01:18:12 +01006963 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_QIO,
Nikolay Nikolaev3f3390b2013-06-28 21:28:56 +00006964 .tested = TEST_UNTESTED,
6965 .probe = probe_spi_rdid,
6966 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +10006967 .block_erasers =
6968 {
Nikolay Nikolaev3f3390b2013-06-28 21:28:56 +00006969 {
6970 .eraseblocks = { {4 * 1024, 32} },
6971 .block_erase = spi_block_erase_20,
6972 }, {
6973 .eraseblocks = { {32 * 1024, 4} },
6974 .block_erase = spi_block_erase_52,
6975 }, {
6976 .eraseblocks = { {64 * 1024, 2} },
6977 .block_erase = spi_block_erase_d8,
6978 }, {
6979 .eraseblocks = { {128 * 1024, 1} },
6980 .block_erase = spi_block_erase_60,
6981 }, {
6982 .eraseblocks = { {128 * 1024, 1} },
6983 .block_erase = spi_block_erase_c7,
6984 }
6985 },
Nico Huber4da971f2024-03-27 01:18:12 +01006986 .reg_bits =
6987 {
6988 .qe = {STATUS2, 1, RW},
6989 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00006990 .printlock = spi_prettyprint_status_register_bp4_srwd,
Nikolay Nikolaev3f3390b2013-06-28 21:28:56 +00006991 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
6992 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01006993 .read = spi_chip_read,
Nikolay Nikolaev3f3390b2013-06-28 21:28:56 +00006994 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02006995 .prepare_access = spi_prepare_io,
6996 .finish_access = spi_finish_io,
Nikolay Nikolaev3f3390b2013-06-28 21:28:56 +00006997 },
6998
6999 {
7000 .vendor = "GigaDevice",
Nico Huber68573af2024-01-06 18:28:22 +01007001 .name = "GD25Q127C",
Hatim Kanchwalae0c7abf2016-02-21 00:21:11 +00007002 .bustype = BUS_SPI,
7003 .manufacture_id = GIGADEVICE_ID,
7004 .model_id = GIGADEVICE_GD25Q128,
7005 .total_size = 16384,
7006 .page_size = 256,
7007 /* OTP: 1536B total; read 0x48; write 0x42, erase 0x44 */
Nico Huber1412d9f2024-01-06 18:25:49 +01007008 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP | FEATURE_QIO,
Sergii Dmytrukc74eac22022-10-06 18:17:58 +03007009 .tested = TEST_OK_PREWB,
Hatim Kanchwalae0c7abf2016-02-21 00:21:11 +00007010 .probe = probe_spi_rdid,
7011 .probe_timing = TIMING_ZERO,
7012 .block_erasers =
7013 {
7014 {
7015 .eraseblocks = { {4 * 1024, 4096} },
7016 .block_erase = spi_block_erase_20,
7017 }, {
7018 .eraseblocks = { {32 * 1024, 512} },
7019 .block_erase = spi_block_erase_52,
7020 }, {
7021 .eraseblocks = { {64 * 1024, 256} },
7022 .block_erase = spi_block_erase_d8,
7023 }, {
7024 .eraseblocks = { {16 * 1024 * 1024, 1} },
7025 .block_erase = spi_block_erase_60,
7026 }, {
7027 .eraseblocks = { {16 * 1024 * 1024, 1} },
7028 .block_erase = spi_block_erase_c7,
7029 }
7030 },
7031 /* TODO: 2nd status reg (read 0x35, write 0x31) and 3rd status reg (read 0x15, write 0x11) */
7032 .printlock = spi_prettyprint_status_register_bp4_srwd,
7033 .unlock = spi_disable_blockprotect_bp4_srwd,
7034 .write = spi_chip_write_256,
Nico Huber1412d9f2024-01-06 18:25:49 +01007035 .read = spi_chip_read,
Hatim Kanchwalae0c7abf2016-02-21 00:21:11 +00007036 .voltage = {2700, 3600},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11007037 .reg_bits =
7038 {
Nico Huber4da971f2024-03-27 01:18:12 +01007039 .qe = {STATUS2, 1, RW},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11007040 .srp = {STATUS1, 7, RW},
7041 .srl = {STATUS2, 0, RW},
7042 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
7043 .tb = {STATUS1, 5, RW}, /* Called BP3 in datasheet, acts like TB */
7044 .sec = {STATUS1, 6, RW}, /* Called BP4 in datasheet, acts like SEC */
7045 .cmp = {STATUS2, 6, RW},
7046 },
Nico Huberaabb3e02023-01-13 00:22:30 +01007047 .wp_write_cfg = spi_wp_write_cfg,
7048 .wp_read_cfg = spi_wp_read_cfg,
7049 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11007050 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +02007051 .prepare_access = spi_prepare_io,
7052 .finish_access = spi_finish_io,
Hatim Kanchwalae0c7abf2016-02-21 00:21:11 +00007053 },
7054
7055 {
7056 .vendor = "GigaDevice",
Nico Huber68573af2024-01-06 18:28:22 +01007057 .name = "GD25Q128C",
7058 .bustype = BUS_SPI,
7059 .manufacture_id = GIGADEVICE_ID,
7060 .model_id = GIGADEVICE_GD25Q128,
7061 .total_size = 16384,
7062 .page_size = 256,
7063 /* OTP: 1536B total; read 0x48; write 0x42, erase 0x44 */
7064 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP | FEATURE_QPI_SRP,
7065 .dummy_cycles = { .qpi_read_params = { 4, 6, 8, 8 } },
7066 .tested = TEST_OK_PREWB,
7067 .probe = probe_spi_rdid,
7068 .probe_timing = TIMING_ZERO,
7069 .block_erasers =
7070 {
7071 {
7072 .eraseblocks = { {4 * 1024, 4096} },
7073 .block_erase = spi_block_erase_20,
7074 }, {
7075 .eraseblocks = { {32 * 1024, 512} },
7076 .block_erase = spi_block_erase_52,
7077 }, {
7078 .eraseblocks = { {64 * 1024, 256} },
7079 .block_erase = spi_block_erase_d8,
7080 }, {
7081 .eraseblocks = { {16 * 1024 * 1024, 1} },
7082 .block_erase = spi_block_erase_60,
7083 }, {
7084 .eraseblocks = { {16 * 1024 * 1024, 1} },
7085 .block_erase = spi_block_erase_c7,
7086 }
7087 },
7088 /* TODO: 2nd status reg (read 0x35, write 0x31) and 3rd status reg (read 0x15, write 0x11) */
7089 .printlock = spi_prettyprint_status_register_bp4_srwd,
7090 .unlock = spi_disable_blockprotect_bp4_srwd,
7091 .write = spi_chip_write_256,
7092 .read = spi_chip_read,
7093 .voltage = {2700, 3600},
7094 .reg_bits =
7095 {
7096 .qe = {STATUS2, 1, RW},
7097 .srp = {STATUS1, 7, RW},
7098 .srl = {STATUS2, 0, RW},
7099 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
7100 .tb = {STATUS1, 5, RW}, /* Called BP3 in datasheet, acts like TB */
7101 .sec = {STATUS1, 6, RW}, /* Called BP4 in datasheet, acts like SEC */
7102 .cmp = {STATUS2, 6, RW},
7103 },
7104 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +02007105 .prepare_access = spi_prepare_io,
7106 .finish_access = spi_finish_io,
Nico Huber68573af2024-01-06 18:28:22 +01007107 },
7108
7109 {
7110 .vendor = "GigaDevice",
Alan Green1f9cc7d2019-07-01 11:10:45 +10007111 .name = "GD25Q16(B)",
7112 .bustype = BUS_SPI,
7113 .manufacture_id = GIGADEVICE_ID,
7114 .model_id = GIGADEVICE_GD25Q16,
7115 .total_size = 2048,
7116 .page_size = 256,
7117 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44 (B version only) */
Nico Huber4da971f2024-03-27 01:18:12 +01007118 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007119 .tested = TEST_OK_PREW,
7120 .probe = probe_spi_rdid,
7121 .probe_timing = TIMING_ZERO,
7122 .block_erasers =
7123 {
7124 {
7125 .eraseblocks = { {4 * 1024, 512} },
7126 .block_erase = spi_block_erase_20,
7127 }, {
7128 .eraseblocks = { {32 * 1024, 64} },
7129 .block_erase = spi_block_erase_52,
7130 }, {
7131 .eraseblocks = { {64 * 1024, 32} },
7132 .block_erase = spi_block_erase_d8,
7133 }, {
7134 .eraseblocks = { {2 * 1024 * 1024, 1} },
7135 .block_erase = spi_block_erase_60,
7136 }, {
7137 .eraseblocks = { {2 * 1024 * 1024, 1} },
7138 .block_erase = spi_block_erase_c7,
7139 }
7140 },
Nico Huber4da971f2024-03-27 01:18:12 +01007141 .reg_bits =
7142 {
7143 .qe = {STATUS2, 1, RW},
7144 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10007145 .printlock = spi_prettyprint_status_register_bp4_srwd,
7146 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
7147 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01007148 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007149 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02007150 .prepare_access = spi_prepare_io,
7151 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007152 },
7153
7154 {
7155 .vendor = "GigaDevice",
7156 .name = "GD25Q20(B)",
7157 .bustype = BUS_SPI,
7158 .manufacture_id = GIGADEVICE_ID,
7159 .model_id = GIGADEVICE_GD25Q20,
7160 .total_size = 256,
7161 .page_size = 256,
Nico Huber4da971f2024-03-27 01:18:12 +01007162 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007163 .tested = TEST_OK_PREW,
7164 .probe = probe_spi_rdid,
7165 .probe_timing = TIMING_ZERO,
7166 .block_erasers =
7167 {
7168 {
7169 .eraseblocks = { {4 * 1024, 64} },
7170 .block_erase = spi_block_erase_20,
7171 }, {
7172 .eraseblocks = { {32 * 1024, 8} },
7173 .block_erase = spi_block_erase_52,
7174 }, {
7175 .eraseblocks = { {64 * 1024, 4} },
7176 .block_erase = spi_block_erase_d8,
7177 }, {
7178 .eraseblocks = { {256 * 1024, 1} },
7179 .block_erase = spi_block_erase_60,
7180 }, {
7181 .eraseblocks = { {256 * 1024, 1} },
7182 .block_erase = spi_block_erase_c7,
7183 }
7184 },
Nico Huber4da971f2024-03-27 01:18:12 +01007185 .reg_bits = {
7186 .qe = {STATUS2, 1, RW},
7187 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10007188 .printlock = spi_prettyprint_status_register_bp4_srwd,
7189 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
7190 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01007191 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007192 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02007193 .prepare_access = spi_prepare_io,
7194 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007195 },
7196
7197 {
7198 .vendor = "GigaDevice",
Nikolai Artemiev3ca0af02022-06-17 15:10:18 +10007199 .name = "GD25Q256D/GD25Q256E",
Alan Green86fc9cf2019-08-26 15:02:12 +10007200 .bustype = BUS_SPI,
7201 .manufacture_id = GIGADEVICE_ID,
7202 .model_id = GIGADEVICE_GD25Q256D,
7203 .total_size = 32768,
7204 .page_size = 256,
Nikolai Artemievb931e7a2022-12-05 13:06:14 +11007205 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA |
Nico Huber4da971f2024-03-27 01:18:12 +01007206 FEATURE_WRSR_EXT2 | FEATURE_WRSR2 | FEATURE_WRSR3 |
7207 FEATURE_QIO,
Sergii Dmytrukc74eac22022-10-06 18:17:58 +03007208 .tested = TEST_OK_PREWB,
Alan Green86fc9cf2019-08-26 15:02:12 +10007209 .probe = probe_spi_rdid,
7210 .probe_timing = TIMING_ZERO,
7211 .block_erasers =
7212 {
7213 {
7214 .eraseblocks = { {4 * 1024, 8192} },
Nico Huber5374dc32019-10-04 16:16:15 +02007215 .block_erase = spi_block_erase_21,
7216 }, {
7217 .eraseblocks = { {4 * 1024, 8192} },
Alan Green86fc9cf2019-08-26 15:02:12 +10007218 .block_erase = spi_block_erase_20,
7219 }, {
7220 .eraseblocks = { {32 * 1024, 1024} },
Nico Huber5374dc32019-10-04 16:16:15 +02007221 .block_erase = spi_block_erase_5c,
7222 }, {
7223 .eraseblocks = { {32 * 1024, 1024} },
Alan Green86fc9cf2019-08-26 15:02:12 +10007224 .block_erase = spi_block_erase_52,
7225 }, {
7226 .eraseblocks = { {64 * 1024, 512} },
Nico Huber5374dc32019-10-04 16:16:15 +02007227 .block_erase = spi_block_erase_dc,
7228 }, {
7229 .eraseblocks = { {64 * 1024, 512} },
Alan Green86fc9cf2019-08-26 15:02:12 +10007230 .block_erase = spi_block_erase_d8,
7231 }, {
7232 .eraseblocks = { {32 * 1024 * 1024, 1} },
7233 .block_erase = spi_block_erase_60,
7234 }, {
7235 .eraseblocks = { {32 * 1024 * 1024, 1} },
7236 .block_erase = spi_block_erase_c7,
7237 }
7238 },
7239 .printlock = spi_prettyprint_status_register_bp3_srwd,
7240 .unlock = spi_disable_blockprotect,
7241 .write = spi_chip_write_256,
7242 .read = spi_chip_read,
7243 .voltage = {2700, 3600},
Nikolai Artemievc6c3f282021-10-20 23:34:15 +11007244 .reg_bits =
7245 {
Nico Huber4da971f2024-03-27 01:18:12 +01007246 .qe = {STATUS2, 1, RW},
Nikolai Artemievc6c3f282021-10-20 23:34:15 +11007247 .srp = {STATUS1, 7, RW},
7248 .srl = {STATUS2, 6, RW},
7249 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}, {STATUS1, 5, RW}},
7250 .tb = {STATUS1, 6, RW},
7251 },
Nico Huberaabb3e02023-01-13 00:22:30 +01007252 .wp_write_cfg = spi_wp_write_cfg,
7253 .wp_read_cfg = spi_wp_read_cfg,
7254 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievc9feb1b2021-10-21 01:35:13 +11007255 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +02007256 .prepare_access = spi_prepare_io,
7257 .finish_access = spi_finish_io,
Alan Green86fc9cf2019-08-26 15:02:12 +10007258 },
7259
7260 {
7261 .vendor = "GigaDevice",
Alan Green1f9cc7d2019-07-01 11:10:45 +10007262 .name = "GD25Q32(B)",
7263 .bustype = BUS_SPI,
7264 .manufacture_id = GIGADEVICE_ID,
7265 .model_id = GIGADEVICE_GD25Q32,
7266 .total_size = 4096,
7267 .page_size = 256,
7268 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01007269 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP | FEATURE_QIO,
Sergii Dmytrukc74eac22022-10-06 18:17:58 +03007270 .tested = TEST_OK_PREWB,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007271 .probe = probe_spi_rdid,
7272 .probe_timing = TIMING_ZERO,
7273 .block_erasers =
7274 {
7275 {
7276 .eraseblocks = { {4 * 1024, 1024} },
7277 .block_erase = spi_block_erase_20,
7278 }, {
7279 .eraseblocks = { {32 * 1024, 128} },
7280 .block_erase = spi_block_erase_52,
7281 }, {
7282 .eraseblocks = { {64 * 1024, 64} },
7283 .block_erase = spi_block_erase_d8,
7284 }, {
7285 .eraseblocks = { {4 * 1024 * 1024, 1} },
7286 .block_erase = spi_block_erase_60,
7287 }, {
7288 .eraseblocks = { {4 * 1024 * 1024, 1} },
7289 .block_erase = spi_block_erase_c7,
7290 }
7291 },
7292 .printlock = spi_prettyprint_status_register_bp4_srwd,
7293 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
7294 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01007295 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007296 .voltage = {2700, 3600},
Nikolai Artemievc6c3f282021-10-20 23:34:15 +11007297 .reg_bits =
7298 {
Nico Huber4da971f2024-03-27 01:18:12 +01007299 .qe = {STATUS2, 1, RW},
Nikolai Artemievc6c3f282021-10-20 23:34:15 +11007300 .srp = {STATUS1, 7, RW},
7301 .srl = {STATUS2, 0, RW},
7302 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
7303 .tb = {STATUS1, 5, RW}, /* Called BP3 in datasheet, acts like TB */
7304 .sec = {STATUS1, 6, RW}, /* Called BP4 in datasheet, acts like SEC */
7305 .cmp = {STATUS2, 6, RW},
7306 },
Nico Huberaabb3e02023-01-13 00:22:30 +01007307 .wp_write_cfg = spi_wp_write_cfg,
7308 .wp_read_cfg = spi_wp_read_cfg,
7309 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievc9feb1b2021-10-21 01:35:13 +11007310 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +02007311 .prepare_access = spi_prepare_io,
7312 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007313 },
7314
7315 {
7316 .vendor = "GigaDevice",
7317 .name = "GD25Q40(B)",
7318 .bustype = BUS_SPI,
7319 .manufacture_id = GIGADEVICE_ID,
7320 .model_id = GIGADEVICE_GD25Q40,
7321 .total_size = 512,
7322 .page_size = 256,
Nico Huber4da971f2024-03-27 01:18:12 +01007323 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_QIO,
Simon Buhrow551664c2022-03-09 16:09:08 +01007324 .tested = TEST_OK_PREW,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007325 .probe = probe_spi_rdid,
7326 .probe_timing = TIMING_ZERO,
7327 .block_erasers =
7328 {
7329 {
7330 .eraseblocks = { {4 * 1024, 128} },
7331 .block_erase = spi_block_erase_20,
7332 }, {
7333 .eraseblocks = { {32 * 1024, 16} },
7334 .block_erase = spi_block_erase_52,
7335 }, {
7336 .eraseblocks = { {64 * 1024, 8} },
7337 .block_erase = spi_block_erase_d8,
7338 }, {
7339 .eraseblocks = { {512 * 1024, 1} },
7340 .block_erase = spi_block_erase_60,
7341 }, {
7342 .eraseblocks = { {512 * 1024, 1} },
7343 .block_erase = spi_block_erase_c7,
7344 }
7345 },
Nico Huber4da971f2024-03-27 01:18:12 +01007346 .reg_bits =
7347 {
7348 .qe = {STATUS2, 1, RW},
7349 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10007350 .printlock = spi_prettyprint_status_register_bp4_srwd,
7351 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
7352 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01007353 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007354 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02007355 .prepare_access = spi_prepare_io,
7356 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007357 },
7358
7359 {
7360 .vendor = "GigaDevice",
7361 .name = "GD25Q512",
7362 .bustype = BUS_SPI,
7363 .manufacture_id = GIGADEVICE_ID,
7364 .model_id = GIGADEVICE_GD25Q512,
7365 .total_size = 64,
7366 .page_size = 256,
Nico Huber4da971f2024-03-27 01:18:12 +01007367 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007368 .tested = TEST_OK_PREW,
7369 .probe = probe_spi_rdid,
7370 .probe_timing = TIMING_ZERO,
7371 .block_erasers =
7372 {
7373 {
7374 .eraseblocks = { {4 * 1024, 16} },
7375 .block_erase = spi_block_erase_20,
7376 }, {
7377 .eraseblocks = { {32 * 1024, 2} },
7378 .block_erase = spi_block_erase_52,
7379 }, {
7380 .eraseblocks = { {64 * 1024, 1} },
7381 .block_erase = spi_block_erase_60,
7382 }, {
7383 .eraseblocks = { {64 * 1024, 1} },
7384 .block_erase = spi_block_erase_c7,
7385 }
7386 },
Nico Huber4da971f2024-03-27 01:18:12 +01007387 .reg_bits =
7388 {
7389 .qe = {STATUS2, 1, RW},
7390 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10007391 .printlock = spi_prettyprint_status_register_bp4_srwd,
7392 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
7393 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01007394 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007395 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02007396 .prepare_access = spi_prepare_io,
7397 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007398 },
7399
7400 {
7401 .vendor = "GigaDevice",
7402 .name = "GD25Q64(B)",
7403 .bustype = BUS_SPI,
7404 .manufacture_id = GIGADEVICE_ID,
7405 .model_id = GIGADEVICE_GD25Q64,
7406 .total_size = 8192,
7407 .page_size = 256,
7408 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01007409 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP | FEATURE_QIO,
Sergii Dmytrukc74eac22022-10-06 18:17:58 +03007410 .tested = TEST_OK_PREWB,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007411 .probe = probe_spi_rdid,
7412 .probe_timing = TIMING_ZERO,
7413 .block_erasers =
7414 {
7415 {
7416 .eraseblocks = { {4 * 1024, 2048} },
7417 .block_erase = spi_block_erase_20,
7418 }, {
7419 .eraseblocks = { {32 * 1024, 256} },
7420 .block_erase = spi_block_erase_52,
7421 }, {
7422 .eraseblocks = { {64 * 1024, 128} },
7423 .block_erase = spi_block_erase_d8,
7424 }, {
7425 .eraseblocks = { {8 * 1024 * 1024, 1} },
7426 .block_erase = spi_block_erase_60,
7427 }, {
7428 .eraseblocks = { {8 * 1024 * 1024, 1} },
7429 .block_erase = spi_block_erase_c7,
7430 }
7431 },
7432 .printlock = spi_prettyprint_status_register_bp4_srwd,
7433 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
7434 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01007435 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007436 .voltage = {2700, 3600},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11007437 .reg_bits =
7438 {
Nico Huber4da971f2024-03-27 01:18:12 +01007439 .qe = {STATUS2, 1, RW},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11007440 .srp = {STATUS1, 7, RW},
7441 .srl = {STATUS2, 0, RW},
7442 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
7443 .tb = {STATUS1, 5, RW}, /* Called BP3 in datasheet, acts like TB */
7444 .sec = {STATUS1, 6, RW}, /* Called BP4 in datasheet, acts like SEC */
7445 .cmp = {STATUS2, 6, RW},
7446 },
Nico Huberaabb3e02023-01-13 00:22:30 +01007447 .wp_write_cfg = spi_wp_write_cfg,
7448 .wp_read_cfg = spi_wp_read_cfg,
7449 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievd32e18b2022-02-15 18:06:55 +11007450 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +02007451 .prepare_access = spi_prepare_io,
7452 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007453 },
7454
7455 {
7456 .vendor = "GigaDevice",
7457 .name = "GD25Q80(B)",
7458 .bustype = BUS_SPI,
7459 .manufacture_id = GIGADEVICE_ID,
7460 .model_id = GIGADEVICE_GD25Q80,
7461 .total_size = 1024,
7462 .page_size = 256,
7463 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44 (B version only) */
Nico Huber4da971f2024-03-27 01:18:12 +01007464 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007465 .tested = TEST_OK_PREW,
7466 .probe = probe_spi_rdid,
7467 .probe_timing = TIMING_ZERO,
7468 .block_erasers =
7469 {
7470 {
7471 .eraseblocks = { {4 * 1024, 256} },
7472 .block_erase = spi_block_erase_20,
7473 }, {
7474 .eraseblocks = { {32 * 1024, 32} },
7475 .block_erase = spi_block_erase_52,
7476 }, {
7477 .eraseblocks = { {64 * 1024, 16} },
7478 .block_erase = spi_block_erase_d8,
7479 }, {
7480 .eraseblocks = { {1024 * 1024, 1} },
7481 .block_erase = spi_block_erase_60,
7482 }, {
7483 .eraseblocks = { {1024 * 1024, 1} },
7484 .block_erase = spi_block_erase_c7,
7485 }
7486 },
Nico Huber4da971f2024-03-27 01:18:12 +01007487 .reg_bits =
7488 {
7489 .qe = {STATUS2, 1, RW},
7490 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10007491 .printlock = spi_prettyprint_status_register_bp4_srwd,
7492 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
7493 .write = spi_chip_write_256,
Nico Huber4da971f2024-03-27 01:18:12 +01007494 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007495 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02007496 .prepare_access = spi_prepare_io,
7497 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007498 },
7499
7500 {
7501 .vendor = "GigaDevice",
Nikolay Nikolaev3f3390b2013-06-28 21:28:56 +00007502 .name = "GD25T80",
7503 .bustype = BUS_SPI,
7504 .manufacture_id = GIGADEVICE_ID,
7505 .model_id = GIGADEVICE_GD25T80,
7506 .total_size = 1024,
7507 .page_size = 256,
7508 /* OTP: 256B total; enter 0x3A */
7509 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
7510 .tested = TEST_UNTESTED,
7511 .probe = probe_spi_rdid,
7512 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +10007513 .block_erasers =
7514 {
Nikolay Nikolaev3f3390b2013-06-28 21:28:56 +00007515 {
7516 .eraseblocks = { {4 * 1024, 256} },
7517 .block_erase = spi_block_erase_20,
7518 }, {
7519 .eraseblocks = { {64 * 1024, 16} },
7520 .block_erase = spi_block_erase_52,
7521 }, {
7522 .eraseblocks = { {64 * 1024, 16} },
7523 .block_erase = spi_block_erase_d8,
7524 }, {
7525 .eraseblocks = { {1024 * 1024, 1} },
7526 .block_erase = spi_block_erase_60,
7527 }, {
7528 .eraseblocks = { {1024 * 1024, 1} },
7529 .block_erase = spi_block_erase_c7,
7530 }
7531 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +00007532 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Justin Chevrier1525b2a2012-04-14 21:59:23 +00007533 .unlock = spi_disable_blockprotect,
7534 .write = spi_chip_write_256,
7535 .read = spi_chip_read,
Stefan Tauner352e50b2013-02-22 15:58:45 +00007536 .voltage = {2700, 3600},
Justin Chevrier1525b2a2012-04-14 21:59:23 +00007537 },
7538
7539 {
Hatim Kanchwalae0c7abf2016-02-21 00:21:11 +00007540 .vendor = "GigaDevice",
Alan Green1f9cc7d2019-07-01 11:10:45 +10007541 .name = "GD25VQ16C",
7542 .bustype = BUS_SPI,
7543 .manufacture_id = GIGADEVICE_ID,
7544 .model_id = GIGADEVICE_GD25VQ16C,
7545 .total_size = 2 * 1024,
7546 .page_size = 256,
7547 /* Supports SFDP */
7548 /* OTP: 1024B total; read 0x48, write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01007549 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007550 .tested = TEST_UNTESTED,
7551 .probe = probe_spi_rdid,
7552 .probe_timing = TIMING_ZERO,
7553 .block_erasers =
7554 {
7555 {
7556 .eraseblocks = { { 4 * 1024, 512} },
7557 .block_erase = spi_block_erase_20,
7558 }, {
7559 .eraseblocks = { { 32 * 1024, 64} },
7560 .block_erase = spi_block_erase_52,
7561 }, {
7562 .eraseblocks = { { 64 * 1024, 32} },
7563 .block_erase = spi_block_erase_d8,
7564 }, {
7565 .eraseblocks = { {2 * 1024 * 1024, 1} },
7566 .block_erase = spi_block_erase_60,
7567 }, {
7568 .eraseblocks = { {2 * 1024 * 1024, 1} },
7569 .block_erase = spi_block_erase_c7,
7570 }
7571 },
Nico Huber4da971f2024-03-27 01:18:12 +01007572 .reg_bits =
7573 {
7574 .qe = {STATUS2, 1, RW},
7575 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10007576 .printlock = spi_prettyprint_status_register_bp4_srwd,
7577 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
7578 .write = spi_chip_write_256,
Nico Huber1412d9f2024-01-06 18:25:49 +01007579 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007580 .voltage = {2300, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02007581 .prepare_access = spi_prepare_io,
7582 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007583 },
7584
7585 {
7586 .vendor = "GigaDevice",
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007587 .name = "GD25VQ21B",
7588 .bustype = BUS_SPI,
7589 .manufacture_id = GIGADEVICE_ID,
7590 .model_id = GIGADEVICE_GD25VQ21B,
7591 .total_size = 256,
7592 .page_size = 256,
7593 /* OTP: 1536B total; read 0x48, write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01007594 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_WRSR2 |
7595 FEATURE_OTP | FEATURE_QIO,
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007596 .tested = TEST_UNTESTED,
7597 .probe = probe_spi_rdid,
7598 .probe_timing = TIMING_ZERO,
7599 .block_erasers =
7600 {
7601 {
7602 .eraseblocks = { { 4 * 1024, 64} },
7603 .block_erase = spi_block_erase_20,
7604 }, {
7605 .eraseblocks = { { 32 * 1024, 8} },
7606 .block_erase = spi_block_erase_52,
7607 }, {
7608 .eraseblocks = { { 64 * 1024, 4} },
7609 .block_erase = spi_block_erase_d8,
7610 }, {
7611 .eraseblocks = { {256 * 1024, 1} },
7612 .block_erase = spi_block_erase_60,
7613 }, {
7614 .eraseblocks = { {256 * 1024, 1} },
7615 .block_erase = spi_block_erase_c7,
7616 }
7617 },
Nico Huber4da971f2024-03-27 01:18:12 +01007618 .reg_bits =
7619 {
7620 .qe = {STATUS2, 1, RW},
7621 },
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007622 .printlock = spi_prettyprint_status_register_bp4_srwd,
7623 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
7624 .write = spi_chip_write_256,
Nico Huber1412d9f2024-01-06 18:25:49 +01007625 .read = spi_chip_read,
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007626 .voltage = {2300, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02007627 .prepare_access = spi_prepare_io,
7628 .finish_access = spi_finish_io,
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007629 },
7630
7631 {
7632 .vendor = "GigaDevice",
7633 .name = "GD25VQ40C",
7634 .bustype = BUS_SPI,
7635 .manufacture_id = GIGADEVICE_ID,
7636 .model_id = GIGADEVICE_GD25VQ41B,
7637 .total_size = 512,
7638 .page_size = 256,
7639 /* Supports SFDP */
7640 /* OTP: 1024B total; read 0x48, write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01007641 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007642 .tested = TEST_UNTESTED,
7643 .probe = probe_spi_rdid,
7644 .probe_timing = TIMING_ZERO,
7645 .block_erasers =
7646 {
7647 {
7648 .eraseblocks = { { 4 * 1024, 128} },
7649 .block_erase = spi_block_erase_20,
7650 }, {
7651 .eraseblocks = { { 32 * 1024, 16} },
7652 .block_erase = spi_block_erase_52,
7653 }, {
7654 .eraseblocks = { { 64 * 1024, 8} },
7655 .block_erase = spi_block_erase_d8,
7656 }, {
7657 .eraseblocks = { {512 * 1024, 1} },
7658 .block_erase = spi_block_erase_60,
7659 }, {
7660 .eraseblocks = { {512 * 1024, 1} },
7661 .block_erase = spi_block_erase_c7,
7662 }
7663 },
Nico Huber4da971f2024-03-27 01:18:12 +01007664 .reg_bits =
7665 {
7666 .qe = {STATUS2, 1, RW},
7667 },
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007668 .printlock = spi_prettyprint_status_register_bp4_srwd,
7669 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
7670 .write = spi_chip_write_256,
Nico Huber1412d9f2024-01-06 18:25:49 +01007671 .read = spi_chip_read,
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007672 .voltage = {2300, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02007673 .prepare_access = spi_prepare_io,
7674 .finish_access = spi_finish_io,
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007675 },
7676
7677 {
7678 .vendor = "GigaDevice",
Hatim Kanchwalae0c7abf2016-02-21 00:21:11 +00007679 .name = "GD25VQ41B",
7680 .bustype = BUS_SPI,
7681 .manufacture_id = GIGADEVICE_ID,
7682 .model_id = GIGADEVICE_GD25VQ41B,
7683 .total_size = 512,
7684 .page_size = 256,
7685 /* OTP: 1536B total; read 0x48, write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01007686 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_WRSR2 |
7687 FEATURE_OTP | FEATURE_QIO,
Stefan Tauner0be072c2016-03-13 15:16:30 +00007688 .tested = TEST_OK_PREW,
Hatim Kanchwalae0c7abf2016-02-21 00:21:11 +00007689 .probe = probe_spi_rdid,
7690 .probe_timing = TIMING_ZERO,
Stefan Tauner0be072c2016-03-13 15:16:30 +00007691 .block_erasers =
Hatim Kanchwalae0c7abf2016-02-21 00:21:11 +00007692 {
Stefan Tauner0be072c2016-03-13 15:16:30 +00007693 {
7694 .eraseblocks = { { 4 * 1024, 128} },
7695 .block_erase = spi_block_erase_20,
7696 }, {
7697 .eraseblocks = { { 32 * 1024, 16} },
7698 .block_erase = spi_block_erase_52,
7699 }, {
7700 .eraseblocks = { { 64 * 1024, 8} },
7701 .block_erase = spi_block_erase_d8,
7702 }, {
7703 .eraseblocks = { {512 * 1024, 1} },
7704 .block_erase = spi_block_erase_60,
7705 }, {
7706 .eraseblocks = { {512 * 1024, 1} },
7707 .block_erase = spi_block_erase_c7,
7708 }
Hatim Kanchwalae0c7abf2016-02-21 00:21:11 +00007709 },
Nico Huber4da971f2024-03-27 01:18:12 +01007710 .reg_bits =
7711 {
7712 .qe = {STATUS2, 1, RW},
7713 },
Hatim Kanchwalae0c7abf2016-02-21 00:21:11 +00007714 .printlock = spi_prettyprint_status_register_bp4_srwd,
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007715 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
7716 .write = spi_chip_write_256,
Nico Huber1412d9f2024-01-06 18:25:49 +01007717 .read = spi_chip_read,
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007718 .voltage = {2300, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02007719 .prepare_access = spi_prepare_io,
7720 .finish_access = spi_finish_io,
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007721 },
7722
7723 {
7724 .vendor = "GigaDevice",
7725 .name = "GD25VQ80C",
7726 .bustype = BUS_SPI,
7727 .manufacture_id = GIGADEVICE_ID,
7728 .model_id = GIGADEVICE_GD25VQ80C,
7729 .total_size = 1024,
7730 .page_size = 256,
7731 /* Supports SFDP */
7732 /* OTP: 1024B total; read 0x48, write 0x42, erase 0x44 */
Nico Huber4da971f2024-03-27 01:18:12 +01007733 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007734 .tested = TEST_UNTESTED,
7735 .probe = probe_spi_rdid,
7736 .probe_timing = TIMING_ZERO,
7737 .block_erasers =
7738 {
7739 {
7740 .eraseblocks = { { 4 * 1024, 256} },
7741 .block_erase = spi_block_erase_20,
7742 }, {
7743 .eraseblocks = { { 32 * 1024, 32} },
7744 .block_erase = spi_block_erase_52,
7745 }, {
7746 .eraseblocks = { { 64 * 1024, 16} },
7747 .block_erase = spi_block_erase_d8,
7748 }, {
7749 .eraseblocks = { {1024 * 1024, 1} },
7750 .block_erase = spi_block_erase_60,
7751 }, {
7752 .eraseblocks = { {1024 * 1024, 1} },
7753 .block_erase = spi_block_erase_c7,
7754 }
7755 },
Nico Huber4da971f2024-03-27 01:18:12 +01007756 .reg_bits =
7757 {
7758 .qe = {STATUS2, 1, RW},
7759 },
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007760 .printlock = spi_prettyprint_status_register_bp4_srwd,
7761 .unlock = spi_disable_blockprotect_bp4_srwd, /* TODO: 2nd status reg (read with 0x35) */
7762 .write = spi_chip_write_256,
Nico Huber1412d9f2024-01-06 18:25:49 +01007763 .read = spi_chip_read,
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007764 .voltage = {2300, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02007765 .prepare_access = spi_prepare_io,
7766 .finish_access = spi_finish_io,
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007767 },
7768
7769 {
Dino Li3214f582020-03-25 17:39:53 +08007770 .vendor = "GigaDevice",
7771 .name = "GD25WQ80E",
7772 .bustype = BUS_SPI,
7773 .manufacture_id = GIGADEVICE_ID,
7774 .model_id = GIGADEVICE_GD25WQ80E,
7775 .total_size = 1024,
7776 .page_size = 256,
Nico Huber4da971f2024-03-27 01:18:12 +01007777 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_QIO,
Dino Li3214f582020-03-25 17:39:53 +08007778 .tested = TEST_OK_PREW,
7779 .probe = probe_spi_rdid,
7780 .probe_timing = TIMING_ZERO,
7781 .block_erasers =
7782 {
7783 {
7784 .eraseblocks = { {4 * 1024, 256} },
7785 .block_erase = spi_block_erase_20,
7786 }, {
7787 .eraseblocks = { {32 * 1024, 32} },
7788 .block_erase = spi_block_erase_52,
7789 }, {
7790 .eraseblocks = { {64 * 1024, 16} },
7791 .block_erase = spi_block_erase_d8,
7792 }, {
7793 .eraseblocks = { {1 * 1024 * 1024, 1} },
7794 .block_erase = spi_block_erase_60,
7795 }, {
7796 .eraseblocks = { {1 * 1024 * 1024, 1} },
7797 .block_erase = spi_block_erase_c7,
7798 }
7799 },
Nico Huber4da971f2024-03-27 01:18:12 +01007800 .reg_bits =
7801 {
7802 .qe = {STATUS2, 1, RW},
7803 },
Dino Li3214f582020-03-25 17:39:53 +08007804 .printlock = spi_prettyprint_status_register_bp4_srwd,
7805 .unlock = spi_disable_blockprotect_bp4_srwd,
7806 .write = spi_chip_write_256,
7807 .read = spi_chip_read,
7808 .voltage = {1650, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02007809 .prepare_access = spi_prepare_io,
7810 .finish_access = spi_finish_io,
Dino Li3214f582020-03-25 17:39:53 +08007811 },
7812
7813 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10007814 .vendor = "Hyundai",
7815 .name = "HY29F002B",
7816 .bustype = BUS_PARALLEL,
7817 .manufacture_id = HYUNDAI_ID,
7818 .model_id = HYUNDAI_HY29F002B,
7819 .total_size = 256,
7820 .page_size = 256 * 1024,
7821 .feature_bits = FEATURE_EITHER_RESET, /* Some revisions may need FEATURE_ADDR_2AA */
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007822 .tested = TEST_UNTESTED,
Alan Green1f9cc7d2019-07-01 11:10:45 +10007823 .probe = probe_jedec,
7824 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007825 .block_erasers =
7826 {
7827 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10007828 .eraseblocks = {
7829 {16 * 1024, 1},
7830 {8 * 1024, 2},
7831 {32 * 1024, 1},
7832 {64 * 1024, 3},
7833 },
7834 .block_erase = erase_sector_jedec,
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007835 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10007836 .eraseblocks = { {256 * 1024, 1} },
7837 .block_erase = erase_chip_block_jedec,
7838 },
Hatim Kanchwalad0595352016-03-06 14:33:49 +00007839 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10007840 .write = write_jedec_1,
7841 .read = read_memmapped,
7842 .voltage = {4750, 5250}, /* 4.75-5.25V for type -45, others 4.5-5.5V */
Nico Huber9eec4072023-01-12 01:17:30 +01007843 .prepare_access = prepare_memory_access,
7844 .finish_access = finish_memory_access,
Hatim Kanchwalae0c7abf2016-02-21 00:21:11 +00007845 },
7846
7847 {
David Borgc96a8bd2010-06-21 16:12:22 +00007848 .vendor = "Hyundai",
7849 .name = "HY29F002T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00007850 .bustype = BUS_PARALLEL,
David Borgc96a8bd2010-06-21 16:12:22 +00007851 .manufacture_id = HYUNDAI_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00007852 .model_id = HYUNDAI_HY29F002T,
David Borgc96a8bd2010-06-21 16:12:22 +00007853 .total_size = 256,
7854 .page_size = 256 * 1024,
7855 .feature_bits = FEATURE_EITHER_RESET, /* Some revisions may need FEATURE_ADDR_2AA */
Carl-Daniel Hailfingerf52f7842010-10-08 18:52:29 +00007856 .tested = TEST_OK_PRE,
David Borgc96a8bd2010-06-21 16:12:22 +00007857 .probe = probe_jedec,
7858 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
7859 .block_erasers =
7860 {
7861 {
7862 .eraseblocks = {
7863 {64 * 1024, 3},
7864 {32 * 1024, 1},
7865 {8 * 1024, 2},
7866 {16 * 1024, 1},
7867 },
7868 .block_erase = erase_sector_jedec,
7869 }, {
7870 .eraseblocks = { {256 * 1024, 1} },
7871 .block_erase = erase_chip_block_jedec,
7872 },
7873 },
7874 .write = write_jedec_1,
7875 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +00007876 .voltage = {4750, 5250}, /* 4.75-5.25V for type -45, others 4.5-5.5V */
Nico Huber9eec4072023-01-12 01:17:30 +01007877 .prepare_access = prepare_memory_access,
7878 .finish_access = finish_memory_access,
David Borgc96a8bd2010-06-21 16:12:22 +00007879 },
7880
7881 {
7882 .vendor = "Hyundai",
Joshua Roysf1324e02010-09-16 00:51:51 +00007883 .name = "HY29F040A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00007884 .bustype = BUS_PARALLEL,
Joshua Roysf1324e02010-09-16 00:51:51 +00007885 .manufacture_id = HYUNDAI_ID,
7886 .model_id = HYUNDAI_HY29F040A,
7887 .total_size = 512,
7888 .page_size = 64 * 1024,
7889 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
7890 .tested = TEST_UNTESTED,
7891 .probe = probe_jedec,
7892 .probe_timing = TIMING_ZERO,
7893 .block_erasers =
7894 {
7895 {
7896 .eraseblocks = { {64 * 1024, 8} },
7897 .block_erase = erase_sector_jedec,
7898 }, {
7899 .eraseblocks = { {512 * 1024, 1} },
7900 .block_erase = erase_chip_block_jedec,
7901 },
7902 },
7903 .write = write_jedec_1,
7904 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +00007905 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01007906 .prepare_access = prepare_memory_access,
7907 .finish_access = finish_memory_access,
Joshua Roysf1324e02010-09-16 00:51:51 +00007908 },
7909
7910 {
Stefan Tauner03a9c3c2014-08-03 14:15:14 +00007911 .vendor = "ISSI",
Angel Pons2ef47f32018-09-30 16:47:30 +02007912 .name = "IS25LP064",
7913 .bustype = BUS_SPI,
7914 .manufacture_id = ISSI_ID_SPI,
7915 .model_id = ISSI_IS25LP064,
7916 .total_size = 8192,
7917 .page_size = 256,
7918 /* OTP: 1024B total; read 0x48; write 0x42 */
7919 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Simon Buhrow9bf829d2021-10-20 17:09:09 +02007920 .tested = TEST_OK_PREW,
Angel Pons2ef47f32018-09-30 16:47:30 +02007921 .probe = probe_spi_rdid,
7922 .probe_timing = TIMING_ZERO,
7923 .block_erasers =
7924 {
7925 {
7926 .eraseblocks = { {4 * 1024, 2048} },
7927 .block_erase = spi_block_erase_20,
7928 }, {
7929 .eraseblocks = { {4 * 1024, 2048} },
7930 .block_erase = spi_block_erase_d7,
7931 }, {
7932 .eraseblocks = { {32 * 1024, 256} },
7933 .block_erase = spi_block_erase_52,
7934 }, {
7935 .eraseblocks = { {64 * 1024, 128} },
7936 .block_erase = spi_block_erase_d8,
7937 }, {
7938 .eraseblocks = { {8 * 1024 * 1024, 1} },
7939 .block_erase = spi_block_erase_60,
7940 }, {
7941 .eraseblocks = { {8 * 1024 * 1024, 1} },
7942 .block_erase = spi_block_erase_c7,
7943 }
7944 },
7945 .unlock = spi_disable_blockprotect,
7946 .write = spi_chip_write_256,
7947 .read = spi_chip_read,
7948 .voltage = {2300, 3600},
7949 },
7950
7951 {
7952 .vendor = "ISSI",
David Hendricks3083ed92017-05-02 13:25:56 -07007953 .name = "IS25LP128",
7954 .bustype = BUS_SPI,
7955 .manufacture_id = ISSI_ID_SPI,
7956 .model_id = ISSI_IS25LP128,
7957 .total_size = 16384,
7958 .page_size = 256,
7959 /* OTP: 1024B total; read 0x48; write 0x42 */
7960 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
7961 .tested = TEST_OK_PREW,
7962 .probe = probe_spi_rdid,
7963 .probe_timing = TIMING_ZERO,
7964 .block_erasers =
7965 {
7966 {
7967 .eraseblocks = { {4 * 1024, 4096} },
7968 .block_erase = spi_block_erase_20,
7969 }, {
7970 .eraseblocks = { {4 * 1024, 4096} },
7971 .block_erase = spi_block_erase_d7,
7972 }, {
7973 .eraseblocks = { {32 * 1024, 512} },
7974 .block_erase = spi_block_erase_52,
7975 }, {
7976 .eraseblocks = { {64 * 1024, 256} },
7977 .block_erase = spi_block_erase_d8,
7978 }, {
7979 .eraseblocks = { {16 * 1024 * 1024, 1} },
7980 .block_erase = spi_block_erase_60,
7981 }, {
7982 .eraseblocks = { {16 * 1024 * 1024, 1} },
7983 .block_erase = spi_block_erase_c7,
7984 }
7985 },
7986 .unlock = spi_disable_blockprotect,
7987 .write = spi_chip_write_256,
7988 .read = spi_chip_read,
7989 .voltage = {2300, 3600},
7990 },
7991
7992 {
7993 .vendor = "ISSI",
David Hendricks61818dc2018-10-28 01:02:21 +00007994 .name = "IS25LP256",
7995 .bustype = BUS_SPI,
7996 .manufacture_id = ISSI_ID_SPI,
7997 .model_id = ISSI_IS25LP256,
7998 .total_size = 32768,
7999 .page_size = 256,
8000 /* supports SFDP */
8001 /* OTP: 1024B total; read 0x68; write 0x62, erase 0x64, read ID 0x4B */
Nico Huberad55d5a2022-06-20 19:32:16 +02008002 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP |
8003 FEATURE_4BA | FEATURE_4BA_ENTER_EAR7 | FEATURE_4BA_EAR_1716,
David Hendricks61818dc2018-10-28 01:02:21 +00008004 .tested = TEST_OK_PREW,
8005 .probe = probe_spi_rdid,
8006 .probe_timing = TIMING_ZERO,
8007 .block_erasers =
8008 {
8009 {
8010 .eraseblocks = { {4 * 1024, 8192} },
8011 .block_erase = spi_block_erase_21,
8012 }, {
8013 .eraseblocks = { {4 * 1024, 8192} },
8014 .block_erase = spi_block_erase_20,
8015 /* could also use spi_block_erase_d7 */
8016 }, {
8017 .eraseblocks = { {32 * 1024, 1024} },
8018 .block_erase = spi_block_erase_5c,
8019 }, {
8020 .eraseblocks = { {32 * 1024, 1024} },
8021 .block_erase = spi_block_erase_52,
8022 }, {
8023 .eraseblocks = { {64 * 1024, 512} },
8024 .block_erase = spi_block_erase_dc,
8025 }, {
8026 .eraseblocks = { {64 * 1024, 512} },
8027 .block_erase = spi_block_erase_d8,
8028 }, {
8029 .eraseblocks = { {32 * 1024 * 1024, 1} },
8030 .block_erase = spi_block_erase_60,
8031 }, {
8032 .eraseblocks = { {32 * 1024 * 1024, 1} },
8033 .block_erase = spi_block_erase_c7,
8034 }
8035 },
8036 .unlock = spi_disable_blockprotect,
8037 .write = spi_chip_write_256,
8038 .read = spi_chip_read,
8039 .voltage = {2300, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02008040 .prepare_access = spi_prepare_io,
8041 .finish_access = spi_finish_io,
David Hendricks61818dc2018-10-28 01:02:21 +00008042 },
8043
8044 {
8045 .vendor = "ISSI",
Nico Huberb27b8d12018-10-02 20:46:21 +02008046 .name = "IS25WP032",
8047 .bustype = BUS_SPI,
Alan Greenfa3fcd32019-06-27 15:41:50 +10008048 .manufacture_id = ISSI_ID_SPI,
Nico Huberb27b8d12018-10-02 20:46:21 +02008049 .model_id = ISSI_IS25WP032,
8050 .total_size = 4096,
8051 .page_size = 256,
8052 /* OTP: 1024B total; read 0x48; write 0x42 */
Nico Huber1412d9f2024-01-06 18:25:49 +01008053 /* QPI: enter/exit 35/f5, SRP with 4 bits directly specifying
8054 dummy cycles; non-volatile read parameters, so disable for now */
8055 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Nico Huberb27b8d12018-10-02 20:46:21 +02008056 .tested = TEST_UNTESTED,
8057 .probe = probe_spi_rdid,
8058 .probe_timing = TIMING_ZERO,
8059 .block_erasers =
8060 {
8061 {
8062 .eraseblocks = { {4 * 1024, 1024} },
8063 .block_erase = spi_block_erase_20,
8064 }, {
8065 .eraseblocks = { {4 * 1024, 1024} },
8066 .block_erase = spi_block_erase_d7,
8067 }, {
8068 .eraseblocks = { {32 * 1024, 128} },
8069 .block_erase = spi_block_erase_52,
8070 }, {
8071 .eraseblocks = { {64 * 1024, 64} },
8072 .block_erase = spi_block_erase_d8,
8073 }, {
8074 .eraseblocks = { {4 * 1024 * 1024, 1} },
8075 .block_erase = spi_block_erase_60,
8076 }, {
8077 .eraseblocks = { {4 * 1024 * 1024, 1} },
8078 .block_erase = spi_block_erase_c7,
8079 }
8080 },
8081 .unlock = spi_disable_blockprotect,
8082 .write = spi_chip_write_256,
8083 .read = spi_chip_read,
8084 .voltage = {1650, 1950},
8085 },
8086
8087 {
8088 .vendor = "ISSI",
8089 .name = "IS25WP064",
8090 .bustype = BUS_SPI,
Alan Greenfa3fcd32019-06-27 15:41:50 +10008091 .manufacture_id = ISSI_ID_SPI,
Nico Huberb27b8d12018-10-02 20:46:21 +02008092 .model_id = ISSI_IS25WP064,
8093 .total_size = 8192,
8094 .page_size = 256,
8095 /* OTP: 1024B total; read 0x48; write 0x42 */
Nico Huber1412d9f2024-01-06 18:25:49 +01008096 /* QPI: enter/exit 35/f5, SRP with 4 bits directly specifying
8097 dummy cycles; non-volatile read parameters, so disable for now */
8098 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Nico Huberb27b8d12018-10-02 20:46:21 +02008099 .tested = TEST_OK_PREW,
8100 .probe = probe_spi_rdid,
8101 .probe_timing = TIMING_ZERO,
8102 .block_erasers =
8103 {
8104 {
8105 .eraseblocks = { {4 * 1024, 2048} },
8106 .block_erase = spi_block_erase_20,
8107 }, {
8108 .eraseblocks = { {4 * 1024, 2048} },
8109 .block_erase = spi_block_erase_d7,
8110 }, {
8111 .eraseblocks = { {32 * 1024, 256} },
8112 .block_erase = spi_block_erase_52,
8113 }, {
8114 .eraseblocks = { {64 * 1024, 128} },
8115 .block_erase = spi_block_erase_d8,
8116 }, {
8117 .eraseblocks = { {8 * 1024 * 1024, 1} },
8118 .block_erase = spi_block_erase_60,
8119 }, {
8120 .eraseblocks = { {8 * 1024 * 1024, 1} },
8121 .block_erase = spi_block_erase_c7,
8122 }
8123 },
8124 .unlock = spi_disable_blockprotect,
8125 .write = spi_chip_write_256,
8126 .read = spi_chip_read,
8127 .voltage = {1650, 1950},
8128 },
8129
8130 {
8131 .vendor = "ISSI",
David Hendricks3083ed92017-05-02 13:25:56 -07008132 .name = "IS25WP128",
8133 .bustype = BUS_SPI,
8134 .manufacture_id = ISSI_ID_SPI,
8135 .model_id = ISSI_IS25WP128,
8136 .total_size = 16384,
8137 .page_size = 256,
8138 /* OTP: 1024B total; read 0x48; write 0x42 */
Nico Huber1412d9f2024-01-06 18:25:49 +01008139 /* QPI: enter/exit 35/f5, SRP with 4 bits directly specifying
8140 dummy cycles; non-volatile read parameters, so disable for now */
8141 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
David Hendricks3083ed92017-05-02 13:25:56 -07008142 .tested = TEST_OK_PREW,
8143 .probe = probe_spi_rdid,
8144 .probe_timing = TIMING_ZERO,
8145 .block_erasers =
8146 {
8147 {
8148 .eraseblocks = { {4 * 1024, 4096} },
8149 .block_erase = spi_block_erase_20,
8150 }, {
8151 .eraseblocks = { {4 * 1024, 4096} },
8152 .block_erase = spi_block_erase_d7,
8153 }, {
8154 .eraseblocks = { {32 * 1024, 512} },
8155 .block_erase = spi_block_erase_52,
8156 }, {
8157 .eraseblocks = { {64 * 1024, 256} },
8158 .block_erase = spi_block_erase_d8,
8159 }, {
8160 .eraseblocks = { {16 * 1024 * 1024, 1} },
8161 .block_erase = spi_block_erase_60,
8162 }, {
8163 .eraseblocks = { {16 * 1024 * 1024, 1} },
8164 .block_erase = spi_block_erase_c7,
8165 }
8166 },
8167 .unlock = spi_disable_blockprotect,
8168 .write = spi_chip_write_256,
8169 .read = spi_chip_read,
8170 .voltage = {1650, 1950},
8171 },
8172
8173 {
8174 .vendor = "ISSI",
David Hendricks61818dc2018-10-28 01:02:21 +00008175 .name = "IS25WP256",
8176 .bustype = BUS_SPI,
8177 .manufacture_id = ISSI_ID_SPI,
8178 .model_id = ISSI_IS25WP256,
8179 .total_size = 32768,
8180 .page_size = 256,
8181 /* supports SFDP */
8182 /* OTP: 1024B total; read 0x68; write 0x62, erase 0x64, read ID 0x4B */
Nico Huberad55d5a2022-06-20 19:32:16 +02008183 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP |
8184 FEATURE_4BA | FEATURE_4BA_ENTER_EAR7 | FEATURE_4BA_EAR_1716,
David Hendricks61818dc2018-10-28 01:02:21 +00008185 .tested = TEST_OK_PREW,
8186 .probe = probe_spi_rdid,
8187 .probe_timing = TIMING_ZERO,
8188 .block_erasers =
8189 {
8190 {
8191 .eraseblocks = { {4 * 1024, 8192} },
8192 .block_erase = spi_block_erase_21,
8193 }, {
8194 .eraseblocks = { {4 * 1024, 8192} },
8195 .block_erase = spi_block_erase_20,
8196 /* could also use spi_block_erase_d7 */
8197 }, {
8198 .eraseblocks = { {32 * 1024, 1024} },
8199 .block_erase = spi_block_erase_5c,
8200 }, {
8201 .eraseblocks = { {32 * 1024, 1024} },
8202 .block_erase = spi_block_erase_52,
8203 }, {
8204 .eraseblocks = { {64 * 1024, 512} },
8205 .block_erase = spi_block_erase_dc,
8206 }, {
8207 .eraseblocks = { {64 * 1024, 512} },
8208 .block_erase = spi_block_erase_d8,
8209 }, {
8210 .eraseblocks = { {32 * 1024 * 1024, 1} },
8211 .block_erase = spi_block_erase_60,
8212 }, {
8213 .eraseblocks = { {32 * 1024 * 1024, 1} },
8214 .block_erase = spi_block_erase_c7,
8215 }
8216 },
8217 .unlock = spi_disable_blockprotect,
8218 .write = spi_chip_write_256,
8219 .read = spi_chip_read,
8220 .voltage = {1650, 1950},
Nico Huber930d4212024-05-04 18:59:15 +02008221 .prepare_access = spi_prepare_io,
8222 .finish_access = spi_finish_io,
David Hendricks61818dc2018-10-28 01:02:21 +00008223 },
8224
8225 {
8226 .vendor = "ISSI",
Stefan Tauner03a9c3c2014-08-03 14:15:14 +00008227 .name = "IS29GL064B",
8228 .bustype = BUS_PARALLEL,
8229 .manufacture_id = ISSI_ID,
8230 .model_id = ISSI_PMC_IS29GL064B,
8231 .total_size = 8192,
8232 .page_size = 128 * 1024, /* actual page size is 16 */
8233 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
8234 .tested = TEST_UNTESTED,
8235 .probe = probe_jedec_29gl,
8236 .probe_timing = TIMING_ZERO,
8237 .block_erasers =
8238 {
8239 {
8240 .eraseblocks = {
8241 {8 * 1024, 8},
8242 {64 * 1024, 127},
8243 },
8244 .block_erase = erase_sector_jedec,
8245 }, {
8246 .eraseblocks = { {8 * 1024 * 1024, 1} },
8247 .block_erase = erase_chip_block_jedec,
8248 },
8249 },
8250 .write = write_jedec_1,
8251 .read = read_memmapped,
8252 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +01008253 .prepare_access = prepare_memory_access,
8254 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +00008255 },
8256
8257 {
8258 .vendor = "ISSI",
Alan Green1f9cc7d2019-07-01 11:10:45 +10008259 .name = "IS29GL064H/L",
8260 .bustype = BUS_PARALLEL,
8261 .manufacture_id = ISSI_ID,
8262 .model_id = ISSI_PMC_IS29GL064HL,
8263 .total_size = 8192,
8264 .page_size = 128 * 1024, /* actual page size is 16 */
8265 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
8266 .tested = TEST_UNTESTED,
8267 .probe = probe_jedec_29gl,
8268 .probe_timing = TIMING_ZERO,
8269 .block_erasers =
8270 {
8271 {
8272 .eraseblocks = { {64 * 1024, 128} },
8273 .block_erase = erase_sector_jedec,
8274 }, {
8275 .eraseblocks = { {8 * 1024 * 1024, 1} },
8276 .block_erase = erase_chip_block_jedec,
8277 },
8278 },
8279 .write = write_jedec_1,
8280 .read = read_memmapped,
8281 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +01008282 .prepare_access = prepare_memory_access,
8283 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008284 },
8285
8286 {
8287 .vendor = "ISSI",
Stefan Tauner03a9c3c2014-08-03 14:15:14 +00008288 .name = "IS29GL064T",
8289 .bustype = BUS_PARALLEL,
8290 .manufacture_id = ISSI_ID,
8291 .model_id = ISSI_PMC_IS29GL064T,
8292 .total_size = 8192,
8293 .page_size = 128 * 1024, /* actual page size is 16 */
8294 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
8295 .tested = TEST_UNTESTED,
8296 .probe = probe_jedec_29gl,
8297 .probe_timing = TIMING_ZERO,
8298 .block_erasers =
8299 {
8300 {
8301 .eraseblocks = {
8302 {64 * 1024, 127},
8303 {8 * 1024, 8},
8304 },
8305 .block_erase = erase_sector_jedec,
8306 }, {
8307 .eraseblocks = { {8 * 1024 * 1024, 1} },
8308 .block_erase = erase_chip_block_jedec,
8309 },
8310 },
8311 .write = write_jedec_1,
8312 .read = read_memmapped,
8313 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +01008314 .prepare_access = prepare_memory_access,
8315 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +00008316 },
8317
8318 {
8319 .vendor = "ISSI",
Stefan Tauner03a9c3c2014-08-03 14:15:14 +00008320 .name = "IS29GL128H/L",
8321 .bustype = BUS_PARALLEL,
8322 .manufacture_id = ISSI_ID,
8323 .model_id = ISSI_PMC_IS29GL128HL,
8324 .total_size = 16384,
8325 .page_size = 128 * 1024, /* actual page size is 16 */
8326 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
8327 .tested = TEST_UNTESTED,
8328 .probe = probe_jedec_29gl,
8329 .probe_timing = TIMING_ZERO,
8330 .block_erasers =
8331 {
8332 {
8333 .eraseblocks = { {128 * 1024, 128} },
8334 .block_erase = erase_sector_jedec,
8335 }, {
8336 .eraseblocks = { {16 * 1024 * 1024, 1} },
8337 .block_erase = erase_chip_block_jedec,
8338 },
8339 },
8340 .write = write_jedec_1,
8341 .read = read_memmapped,
8342 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +01008343 .prepare_access = prepare_memory_access,
8344 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +00008345 },
8346
8347 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10008348 .vendor = "Intel",
8349 .name = "25F160S33B8",
8350 .bustype = BUS_SPI,
8351 .manufacture_id = INTEL_ID,
8352 .model_id = INTEL_25F160S33B8,
8353 .total_size = 2048,
8354 .page_size = 256,
8355 /* OTP: 506B total (2x 8B, 30x 16B, 1x 10B); read 0x4B; write 0x42 */
8356 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
8357 .tested = TEST_UNTESTED,
8358 .probe = probe_spi_rdid,
8359 .probe_timing = TIMING_ZERO,
8360 .block_erasers =
8361 {
8362 {
8363 /* This chip supports erasing of the 8 so-called "parameter blocks" with
8364 * opcode 0x40. Trying to access an address outside these 8 8kB blocks does
8365 * have no effect on the memory contents, but sets a flag in the SR.
8366 .eraseblocks = {
8367 {8 * 1024, 8},
8368 {64 * 1024, 31} // inaccessible
8369 },
8370 .block_erase = spi_block_erase_40,
8371 }, { */
8372 .eraseblocks = { {64 * 1024, 32} },
8373 .block_erase = spi_block_erase_d8,
8374 }, {
8375 .eraseblocks = { {2 * 1024 * 1024, 1} },
8376 .block_erase = spi_block_erase_c7,
8377 }
8378 },
8379 .printlock = spi_prettyprint_status_register_bp2_ep_srwd,
8380 .unlock = spi_disable_blockprotect_bp2_ep_srwd,
8381 .write = spi_chip_write_256,
8382 .read = spi_chip_read, /* also fast read 0x0B */
8383 .voltage = {2700, 3600},
8384 },
8385
8386 {
8387 .vendor = "Intel",
8388 .name = "25F160S33T8",
8389 .bustype = BUS_SPI,
8390 .manufacture_id = INTEL_ID,
8391 .model_id = INTEL_25F160S33T8,
8392 .total_size = 2048,
8393 .page_size = 256,
8394 /* OTP: 506B total (2x 8B, 30x 16B, 1x 10B); read 0x4B; write 0x42 */
8395 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
8396 .tested = TEST_UNTESTED,
8397 .probe = probe_spi_rdid,
8398 .probe_timing = TIMING_ZERO,
8399 .block_erasers =
8400 {
8401 {
8402 /* This chip supports erasing of the 8 so-called "parameter blocks" with
8403 * opcode 0x40. Trying to access an address outside these 8 8kB blocks does
8404 * have no effect on the memory contents, but sets a flag in the SR.
8405 .eraseblocks = {
8406 {64 * 1024, 31}, // inaccessible
8407 {8 * 1024, 8}
8408 },
8409 .block_erase = spi_block_erase_40,
8410 }, { */
8411 .eraseblocks = { {64 * 1024, 32} },
8412 .block_erase = spi_block_erase_d8,
8413 }, {
8414 .eraseblocks = { {2 * 1024 * 1024, 1} },
8415 .block_erase = spi_block_erase_c7,
8416 }
8417 },
8418 .printlock = spi_prettyprint_status_register_bp2_ep_srwd,
8419 .unlock = spi_disable_blockprotect_bp2_ep_srwd,
8420 .write = spi_chip_write_256,
8421 .read = spi_chip_read, /* also fast read 0x0B */
8422 .voltage = {2700, 3600},
8423 },
8424
8425 {
8426 .vendor = "Intel",
8427 .name = "25F320S33B8",
8428 .bustype = BUS_SPI,
8429 .manufacture_id = INTEL_ID,
8430 .model_id = INTEL_25F320S33B8,
8431 .total_size = 4096,
8432 .page_size = 256,
8433 /* OTP: 506B total (2x 8B, 30x 16B, 1x 10B); read 0x4B; write 0x42 */
8434 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
8435 .tested = TEST_UNTESTED,
8436 .probe = probe_spi_rdid,
8437 .probe_timing = TIMING_ZERO,
8438 .block_erasers =
8439 {
8440 {
8441 /* This chip supports erasing of the 8 so-called "parameter blocks" with
8442 * opcode 0x40. Trying to access an address outside these 8 8kB blocks does
8443 * have no effect on the memory contents, but sets a flag in the SR.
8444 .eraseblocks = {
8445 {8 * 1024, 8},
8446 {64 * 1024, 63} // inaccessible
8447 },
8448 .block_erase = spi_block_erase_40,
8449 }, { */
8450 .eraseblocks = { {64 * 1024, 64} },
8451 .block_erase = spi_block_erase_d8,
8452 }, {
8453 .eraseblocks = { {4 * 1024 * 1024, 1} },
8454 .block_erase = spi_block_erase_c7,
8455 }
8456 },
8457 .printlock = spi_prettyprint_status_register_bp2_ep_srwd,
8458 .unlock = spi_disable_blockprotect_bp2_ep_srwd,
8459 .write = spi_chip_write_256,
8460 .read = spi_chip_read, /* also fast read 0x0B */
8461 .voltage = {2700, 3600},
8462 },
8463
8464 {
8465 .vendor = "Intel",
8466 .name = "25F320S33T8",
8467 .bustype = BUS_SPI,
8468 .manufacture_id = INTEL_ID,
8469 .model_id = INTEL_25F320S33T8,
8470 .total_size = 4096,
8471 .page_size = 256,
8472 /* OTP: 506B total (2x 8B, 30x 16B, 1x 10B); read 0x4B; write 0x42 */
8473 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
8474 .tested = TEST_UNTESTED,
8475 .probe = probe_spi_rdid,
8476 .probe_timing = TIMING_ZERO,
8477 .block_erasers =
8478 {
8479 {
8480 /* This chip supports erasing of the 8 so-called "parameter blocks" with
8481 * opcode 0x40. Trying to access an address outside these 8 8kB blocks does
8482 * have no effect on the memory contents, but sets a flag in the SR.
8483 .eraseblocks = {
8484 {64 * 1024, 63}, // inaccessible
8485 {8 * 1024, 8}
8486 },
8487 .block_erase = spi_block_erase_40,
8488 }, { */
8489 .eraseblocks = { {64 * 1024, 64} },
8490 .block_erase = spi_block_erase_d8,
8491 }, {
8492 .eraseblocks = { {4 * 1024 * 1024, 1} },
8493 .block_erase = spi_block_erase_c7,
8494 }
8495 },
8496 .printlock = spi_prettyprint_status_register_bp2_ep_srwd,
8497 .unlock = spi_disable_blockprotect_bp2_ep_srwd,
8498 .write = spi_chip_write_256,
8499 .read = spi_chip_read, /* also fast read 0x0B */
8500 .voltage = {2700, 3600},
8501 },
8502
8503 {
8504 .vendor = "Intel",
8505 .name = "25F640S33B8",
8506 .bustype = BUS_SPI,
8507 .manufacture_id = INTEL_ID,
8508 .model_id = INTEL_25F640S33B8,
8509 .total_size = 8192,
8510 .page_size = 256,
8511 /* OTP: 506B total (2x 8B, 30x 16B, 1x 10B); read 0x4B; write 0x42 */
8512 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Zoltan HERPAIe0e8b2b2020-08-08 16:04:34 +02008513 .tested = TEST_OK_PREW,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008514 .probe = probe_spi_rdid,
8515 .probe_timing = TIMING_ZERO,
8516 .block_erasers =
8517 {
8518 {
8519 /* This chip supports erasing of the 8 so-called "parameter blocks" with
8520 * opcode 0x40. Trying to access an address outside these 8 8kB blocks does
8521 * have no effect on the memory contents, but sets a flag in the SR.
8522 .eraseblocks = {
8523 {8 * 1024, 8},
8524 {64 * 1024, 127} // inaccessible
8525 },
8526 .block_erase = spi_block_erase_40,
8527 }, { */
8528 .eraseblocks = { {64 * 1024, 128} },
8529 .block_erase = spi_block_erase_d8,
8530 }, {
8531 .eraseblocks = { {8 * 1024 * 1024, 1} },
8532 .block_erase = spi_block_erase_c7,
8533 }
8534 },
8535 .printlock = spi_prettyprint_status_register_bp2_ep_srwd,
8536 .unlock = spi_disable_blockprotect_bp2_ep_srwd,
8537 .write = spi_chip_write_256,
8538 .read = spi_chip_read, /* also fast read 0x0B */
8539 .voltage = {2700, 3600},
8540 },
8541
8542 {
8543 .vendor = "Intel",
8544 .name = "25F640S33T8",
8545 .bustype = BUS_SPI,
8546 .manufacture_id = INTEL_ID,
8547 .model_id = INTEL_25F640S33T8,
8548 .total_size = 8192,
8549 .page_size = 256,
8550 /* OTP: 506B total (2x 8B, 30x 16B, 1x 10B); read 0x4B; write 0x42 */
8551 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
8552 .tested = TEST_UNTESTED,
8553 .probe = probe_spi_rdid,
8554 .probe_timing = TIMING_ZERO,
8555 .block_erasers =
8556 {
8557 {
8558 /* This chip supports erasing of the 8 so-called "parameter blocks" with
8559 * opcode 0x40. Trying to access an address outside these 8 8kB blocks does
8560 * have no effect on the memory contents, but sets a flag in the SR.
8561 .eraseblocks = {
8562 {64 * 1024, 127}, // inaccessible
8563 {8 * 1024, 8}
8564 },
8565 .block_erase = spi_block_erase_40,
8566 }, { */
8567 .eraseblocks = { {64 * 1024, 128} },
8568 .block_erase = spi_block_erase_d8,
8569 }, {
8570 .eraseblocks = { {8 * 1024 * 1024, 1} },
8571 .block_erase = spi_block_erase_c7,
8572 }
8573 },
8574 .printlock = spi_prettyprint_status_register_bp2_ep_srwd,
8575 .unlock = spi_disable_blockprotect_bp2_ep_srwd,
8576 .write = spi_chip_write_256,
8577 .read = spi_chip_read, /* also fast read 0x0B */
8578 .voltage = {2700, 3600},
8579 },
8580
8581 {
8582 .vendor = "Intel",
8583 .name = "28F001BN/BX-B",
8584 .bustype = BUS_PARALLEL,
8585 .manufacture_id = INTEL_ID,
8586 .model_id = INTEL_28F001B,
8587 .total_size = 128,
8588 .page_size = 128 * 1024, /* 8k + 2x4k + 112k */
8589 .tested = TEST_UNTESTED,
8590 .probe = probe_jedec,
8591 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
8592 .block_erasers =
8593 {
8594 {
8595 .eraseblocks = {
8596 {8 * 1024, 1},
8597 {4 * 1024, 2},
8598 {112 * 1024, 1},
8599 },
8600 .block_erase = erase_block_82802ab,
8601 },
8602 },
8603 .write = write_82802ab,
8604 .read = read_memmapped,
8605 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01008606 .prepare_access = prepare_memory_access,
8607 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008608 },
8609
8610 {
8611 .vendor = "Intel",
8612 .name = "28F001BN/BX-T",
8613 .bustype = BUS_PARALLEL,
8614 .manufacture_id = INTEL_ID,
8615 .model_id = INTEL_28F001T,
8616 .total_size = 128,
8617 .page_size = 128 * 1024, /* 112k + 2x4k + 8k */
8618 .tested = TEST_OK_PREW,
8619 .probe = probe_jedec,
8620 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
8621 .block_erasers =
8622 {
8623 {
8624 .eraseblocks = {
8625 {112 * 1024, 1},
8626 {4 * 1024, 2},
8627 {8 * 1024, 1},
8628 },
8629 .block_erase = erase_block_82802ab,
8630 },
8631 },
8632 .write = write_82802ab,
8633 .read = read_memmapped,
8634 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +01008635 .prepare_access = prepare_memory_access,
8636 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008637 },
8638
8639 {
8640 .vendor = "Intel",
8641 .name = "28F002BC/BL/BV/BX-T",
8642 .bustype = BUS_PARALLEL,
8643 .manufacture_id = INTEL_ID,
8644 .model_id = INTEL_28F002T,
8645 .total_size = 256,
8646 .page_size = 256 * 1024,
8647 .tested = TEST_OK_PRE,
8648 .probe = probe_82802ab,
8649 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
8650 .block_erasers =
8651 {
8652 {
8653 .eraseblocks = {
8654 {128 * 1024, 1},
8655 {96 * 1024, 1},
8656 {8 * 1024, 2},
8657 {16 * 1024, 1},
8658 },
8659 .block_erase = erase_block_82802ab,
8660 },
8661 },
8662 .write = write_82802ab,
8663 .read = read_memmapped,
Nico Huber9eec4072023-01-12 01:17:30 +01008664 .prepare_access = prepare_memory_access,
8665 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008666 },
8667
8668 {
8669 .vendor = "Intel",
8670 .name = "28F004B5/BE/BV/BX-B",
8671 .bustype = BUS_PARALLEL,
8672 .manufacture_id = INTEL_ID,
8673 .model_id = INTEL_28F004B,
8674 .total_size = 512,
8675 .page_size = 128 * 1024, /* maximal block size */
8676 .tested = TEST_UNTESTED,
8677 .probe = probe_82802ab,
8678 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
8679 .block_erasers =
8680 {
8681 {
8682 .eraseblocks = {
8683 {16 * 1024, 1},
8684 {8 * 1024, 2},
8685 {96 * 1024, 1},
8686 {128 * 1024, 3},
8687 },
8688 .block_erase = erase_block_82802ab,
8689 },
8690 },
8691 .write = write_82802ab,
8692 .read = read_memmapped,
Nico Huber9eec4072023-01-12 01:17:30 +01008693 .prepare_access = prepare_memory_access,
8694 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008695 },
8696
8697 {
8698 .vendor = "Intel",
8699 .name = "28F004B5/BE/BV/BX-T",
8700 .bustype = BUS_PARALLEL,
8701 .manufacture_id = INTEL_ID,
8702 .model_id = INTEL_28F004T,
8703 .total_size = 512,
8704 .page_size = 128 * 1024, /* maximal block size */
8705 .tested = TEST_UNTESTED,
8706 .probe = probe_82802ab,
8707 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
8708 .block_erasers =
8709 {
8710 {
8711 .eraseblocks = {
8712 {128 * 1024, 3},
8713 {96 * 1024, 1},
8714 {8 * 1024, 2},
8715 {16 * 1024, 1},
8716 },
8717 .block_erase = erase_block_82802ab,
8718 },
8719 },
8720 .write = write_82802ab,
8721 .read = read_memmapped,
Nico Huber9eec4072023-01-12 01:17:30 +01008722 .prepare_access = prepare_memory_access,
8723 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008724 },
8725
8726 {
8727 .vendor = "Intel",
8728 .name = "28F008S3/S5/SC",
8729 .bustype = BUS_PARALLEL,
8730 .manufacture_id = INTEL_ID,
8731 .model_id = INTEL_28F004S3,
8732 .total_size = 512,
8733 .page_size = 256,
8734 .tested = TEST_UNTESTED,
8735 .probe = probe_82802ab,
8736 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
8737 .block_erasers =
8738 {
8739 {
8740 .eraseblocks = { {64 * 1024, 8} },
8741 .block_erase = erase_block_82802ab,
8742 },
8743 },
8744 .unlock = unlock_28f004s5,
8745 .write = write_82802ab,
8746 .read = read_memmapped,
Nico Huber9eec4072023-01-12 01:17:30 +01008747 .prepare_access = prepare_memory_access,
8748 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008749 },
8750
8751 {
8752 .vendor = "Intel",
8753 .name = "28F400BV/BX/CE/CV-B",
8754 .bustype = BUS_PARALLEL,
8755 .manufacture_id = INTEL_ID,
8756 .model_id = INTEL_28F400B,
8757 .total_size = 512,
8758 .page_size = 128 * 1024, /* maximal block size */
8759 .feature_bits = FEATURE_ADDR_SHIFTED,
8760 .tested = TEST_UNTESTED,
8761 .probe = probe_82802ab,
8762 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
8763 .block_erasers =
8764 {
8765 {
8766 .eraseblocks = {
8767 {16 * 1024, 1},
8768 {8 * 1024, 2},
8769 {96 * 1024, 1},
8770 {128 * 1024, 3},
8771 },
8772 .block_erase = erase_block_82802ab,
8773 },
8774 },
8775 .write = write_82802ab,
8776 .read = read_memmapped,
Nico Huber9eec4072023-01-12 01:17:30 +01008777 .prepare_access = prepare_memory_access,
8778 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008779 },
8780
8781 {
8782 .vendor = "Intel",
8783 .name = "28F400BV/BX/CE/CV-T",
8784 .bustype = BUS_PARALLEL,
8785 .manufacture_id = INTEL_ID,
8786 .model_id = INTEL_28F400T,
8787 .total_size = 512,
8788 .page_size = 128 * 1024, /* maximal block size */
8789 .feature_bits = FEATURE_ADDR_SHIFTED,
8790 .tested = TEST_UNTESTED,
8791 .probe = probe_82802ab,
8792 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
8793 .block_erasers =
8794 {
8795 {
8796 .eraseblocks = {
8797 {128 * 1024, 3},
8798 {96 * 1024, 1},
8799 {8 * 1024, 2},
8800 {16 * 1024, 1},
8801 },
8802 .block_erase = erase_block_82802ab,
8803 },
8804 },
8805 .write = write_82802ab,
8806 .read = read_memmapped,
Nico Huber9eec4072023-01-12 01:17:30 +01008807 .prepare_access = prepare_memory_access,
8808 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008809 },
8810
8811 {
8812 .vendor = "Intel",
8813 .name = "82802AB",
8814 .bustype = BUS_FWH,
8815 .manufacture_id = INTEL_ID,
8816 .model_id = INTEL_82802AB,
8817 .total_size = 512,
8818 .page_size = 64 * 1024,
Alan Green88552572019-07-24 13:56:06 +10008819 .tested = TEST_OK_PREW,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008820 .probe = probe_82802ab,
8821 .probe_timing = TIMING_IGNORED, /* routine does not use probe_timing (82802ab.c) */
8822 .block_erasers =
8823 {
8824 {
8825 .eraseblocks = { {64 * 1024, 8} },
8826 .block_erase = erase_block_82802ab,
8827 },
8828 },
8829 .unlock = unlock_regspace2_uniform_64k,
8830 .write = write_82802ab,
8831 .read = read_memmapped,
8832 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +01008833 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +01008834 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008835 },
8836
8837 {
8838 .vendor = "Intel",
8839 .name = "82802AC",
8840 .bustype = BUS_FWH,
8841 .manufacture_id = INTEL_ID,
8842 .model_id = INTEL_82802AC,
8843 .total_size = 1024,
8844 .page_size = 64 * 1024,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008845 .tested = TEST_OK_PR,
8846 .probe = probe_82802ab,
8847 .probe_timing = TIMING_IGNORED, /* routine does not use probe_timing (82802ab.c) */
8848 .block_erasers =
8849 {
8850 {
8851 .eraseblocks = { {64 * 1024, 16} },
8852 .block_erase = erase_block_82802ab,
8853 },
8854 },
8855 .unlock = unlock_regspace2_uniform_64k,
8856 .write = write_82802ab,
8857 .read = read_memmapped,
8858 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +01008859 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +01008860 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008861 },
8862
8863 {
8864 .vendor = "Macronix",
8865 .name = "MX23L12854",
8866 .bustype = BUS_SPI,
8867 .manufacture_id = MACRONIX_ID,
8868 .model_id = MACRONIX_MX23L12854,
8869 .total_size = 16384,
8870 .page_size = 256,
8871 .tested = {.probe = NT, .read = NT, .erase = NA, .write = NA},
8872 .probe = probe_spi_rdid,
8873 .probe_timing = TIMING_ZERO,
8874 .write = NULL, /* MX23L12854 is a mask ROM, so it is read-only */
8875 .read = spi_chip_read, /* Fast read (0x0B) supported */
8876 .voltage = {3000, 3600},
8877 },
8878
8879 {
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00008880 .vendor = "Macronix",
Michael Coppola583ea322014-08-20 18:56:35 +00008881 .name = "MX23L1654",
8882 .bustype = BUS_SPI,
8883 .manufacture_id = MACRONIX_ID,
8884 .model_id = MACRONIX_MX23L1654,
8885 .total_size = 2048,
8886 .page_size = 256,
8887 .tested = {.probe = NT, .read = NT, .erase = NA, .write = NA},
8888 .probe = probe_spi_rdid,
8889 .probe_timing = TIMING_ZERO,
8890 .write = NULL, /* MX23L1654 is a mask ROM, so it is read-only */
8891 .read = spi_chip_read, /* Fast read (0x0B) supported */
8892 .voltage = {3000, 3600},
8893 },
8894
8895 {
8896 .vendor = "Macronix",
Michael Coppola4e7f36e2014-05-03 23:01:18 +00008897 .name = "MX23L3254",
8898 .bustype = BUS_SPI,
8899 .manufacture_id = MACRONIX_ID,
8900 .model_id = MACRONIX_MX23L3254,
8901 .total_size = 4096,
8902 .page_size = 256,
Stefan Tauner6455dff2014-05-26 00:36:24 +00008903 .tested = {.probe = OK, .read = OK, .erase = NA, .write = NA},
Michael Coppola4e7f36e2014-05-03 23:01:18 +00008904 .probe = probe_spi_rdid,
8905 .probe_timing = TIMING_ZERO,
8906 .write = NULL, /* MX23L3254 is a mask ROM, so it is read-only */
8907 .read = spi_chip_read, /* Fast read (0x0B) supported */
8908 .voltage = {3000, 3600},
8909 },
8910
8911 {
8912 .vendor = "Macronix",
Michael Coppola583ea322014-08-20 18:56:35 +00008913 .name = "MX23L6454",
8914 .bustype = BUS_SPI,
8915 .manufacture_id = MACRONIX_ID,
8916 .model_id = MACRONIX_MX23L6454,
8917 .total_size = 8192,
8918 .page_size = 256,
Stefan Tauner23e10b82016-01-23 16:16:49 +00008919 .tested = {.probe = OK, .read = OK, .erase = NA, .write = NA},
Michael Coppola583ea322014-08-20 18:56:35 +00008920 .probe = probe_spi_rdid,
8921 .probe_timing = TIMING_ZERO,
8922 .write = NULL, /* MX23L6454 is a mask ROM, so it is read-only */
8923 .read = spi_chip_read, /* Fast read (0x0B) supported */
8924 .voltage = {3000, 3600},
8925 },
8926
8927 {
8928 .vendor = "Macronix",
Stefan Taunerf656e802013-02-02 15:35:44 +00008929 .name = "MX25L1005(C)/MX25L1006E",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00008930 .bustype = BUS_SPI,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00008931 .manufacture_id = MACRONIX_ID,
8932 .model_id = MACRONIX_MX25L1005,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00008933 .total_size = 128,
8934 .page_size = 256,
Stefan Taunerf656e802013-02-02 15:35:44 +00008935 /* MX25L1006E supports SFDP */
Nico Huber46552c82024-03-27 01:18:12 +01008936 /* FEATURE_FAST_READ_DOUT: MX25L1006E */
8937 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ,
Stefan Taunerd7d423b2012-10-20 09:13:16 +00008938 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00008939 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00008940 .probe_timing = TIMING_ZERO,
Carl-Daniel Hailfingerf38431a2009-09-05 02:30:58 +00008941 .block_erasers =
8942 {
8943 {
8944 .eraseblocks = { {4 * 1024, 32} },
8945 .block_erase = spi_block_erase_20,
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00008946 }, {
Carl-Daniel Hailfingerf38431a2009-09-05 02:30:58 +00008947 .eraseblocks = { {64 * 1024, 2} },
8948 .block_erase = spi_block_erase_d8,
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00008949 }, {
Carl-Daniel Hailfingerf38431a2009-09-05 02:30:58 +00008950 .eraseblocks = { {128 * 1024, 1} },
8951 .block_erase = spi_block_erase_60,
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00008952 }, {
Carl-Daniel Hailfingerf38431a2009-09-05 02:30:58 +00008953 .eraseblocks = { {128 * 1024, 1} },
8954 .block_erase = spi_block_erase_c7,
8955 },
8956 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00008957 .printlock = spi_prettyprint_status_register_bp1_srwd,
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00008958 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00008959 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01008960 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00008961 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02008962 .prepare_access = spi_prepare_io,
8963 .finish_access = spi_finish_io,
FENG yu ningff692fb2008-12-08 18:15:10 +00008964 },
8965
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00008966 {
8967 .vendor = "Macronix",
Alan Green1f9cc7d2019-07-01 11:10:45 +10008968 .name = "MX25L12805D",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00008969 .bustype = BUS_SPI,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00008970 .manufacture_id = MACRONIX_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008971 .model_id = MACRONIX_MX25L12805D,
8972 .total_size = 16384,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00008973 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008974 /* OTP: 64B total; enter 0xB1, exit 0xC1 */
Nico Huber46552c82024-03-27 01:18:12 +01008975 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_FAST_READ,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +00008976 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00008977 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00008978 .probe_timing = TIMING_ZERO,
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00008979 .block_erasers =
8980 {
8981 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10008982 .eraseblocks = { {4 * 1024, 4096} },
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00008983 .block_erase = spi_block_erase_20,
8984 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10008985 .eraseblocks = { {64 * 1024, 256} },
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00008986 .block_erase = spi_block_erase_d8,
8987 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10008988 .eraseblocks = { {16 * 1024 * 1024, 1} },
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00008989 .block_erase = spi_block_erase_60,
8990 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10008991 .eraseblocks = { {16 * 1024 * 1024, 1} },
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00008992 .block_erase = spi_block_erase_c7,
Alan Green1f9cc7d2019-07-01 11:10:45 +10008993 }
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00008994 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10008995 .printlock = spi_prettyprint_status_register_bp3_srwd,
8996 .unlock = spi_disable_blockprotect_bp3_srwd,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00008997 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01008998 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00008999 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00009000 },
9001
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009002 {
9003 .vendor = "Macronix",
Tao Xia571f6ad2021-07-21 16:41:53 +08009004 .name = "MX25L12833F/MX25L12835F/MX25L12845E/MX25L12865E/MX25L12873F",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00009005 .bustype = BUS_SPI,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00009006 .manufacture_id = MACRONIX_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009007 .model_id = MACRONIX_MX25L12805D,
9008 .total_size = 16384,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009009 .page_size = 256,
Tao Xia571f6ad2021-07-21 16:41:53 +08009010 /* OTP: MX25L12833F has 1KB total, others have 512B total; enter 0xB1, exit 0xC1 */
Nico Huber46552c82024-03-27 01:18:12 +01009011 /* *F versions: FEATURE_QPI_35 + DC bits (6, 4, 8, 10) in configuration register */
9012 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP |
9013 FEATURE_FAST_READ | FEATURE_FAST_READ_DIO | FEATURE_FAST_READ_QIO,
Stefan Tauner8179be52011-06-04 13:13:34 +00009014 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009015 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00009016 .probe_timing = TIMING_ZERO,
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00009017 .block_erasers =
9018 {
9019 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009020 .eraseblocks = { {4 * 1024, 4096} },
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00009021 .block_erase = spi_block_erase_20,
9022 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009023 .eraseblocks = { {32 * 1024, 512} },
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00009024 .block_erase = spi_block_erase_52,
9025 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009026 .eraseblocks = { {64 * 1024, 256} },
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00009027 .block_erase = spi_block_erase_d8,
9028 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009029 .eraseblocks = { {16 * 1024 * 1024, 1} },
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00009030 .block_erase = spi_block_erase_60,
9031 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009032 .eraseblocks = { {16 * 1024 * 1024, 1} },
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00009033 .block_erase = spi_block_erase_c7,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009034 }
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00009035 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10009036 /* TODO: security register and SBLK/SBULK; MX25L12835F: configuration register */
Nico Huber46552c82024-03-27 01:18:12 +01009037 .reg_bits =
9038 {
9039 .qe = {STATUS1, 6, RW},
9040 },
9041 .printlock = spi_prettyprint_status_register_bp3_srwd,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009042 .unlock = spi_disable_blockprotect_bp3_srwd,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00009043 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009044 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00009045 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009046 .prepare_access = spi_prepare_io,
9047 .finish_access = spi_finish_io,
FENG yu ningff692fb2008-12-08 18:15:10 +00009048 },
9049
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009050 {
9051 .vendor = "Macronix",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009052 .name = "MX25L1605",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00009053 .bustype = BUS_SPI,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00009054 .manufacture_id = MACRONIX_ID,
9055 .model_id = MACRONIX_MX25L1605,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009056 .total_size = 2048,
9057 .page_size = 256,
Nico Huber46552c82024-03-27 01:18:12 +01009058 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ,
Sven Schnelle4bd8a402011-03-07 10:59:06 +00009059 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009060 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00009061 .probe_timing = TIMING_ZERO,
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00009062 .block_erasers =
9063 {
9064 {
Stefan Tauner226037d2013-03-16 01:22:12 +00009065 .eraseblocks = { {64 * 1024, 32} },
9066 .block_erase = spi_block_erase_20,
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00009067 }, {
Stefan Tauner226037d2013-03-16 01:22:12 +00009068 .eraseblocks = { {64 * 1024, 32} },
9069 .block_erase = spi_block_erase_d8,
9070 }, {
9071 .eraseblocks = { {2 * 1024 * 1024, 1} },
9072 .block_erase = spi_block_erase_60,
9073 }, {
9074 .eraseblocks = { {2 * 1024 * 1024, 1} },
9075 .block_erase = spi_block_erase_c7,
9076 },
9077 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00009078 .printlock = spi_prettyprint_status_register_bp2_srwd, /* bit6: error flag */
Stefan Tauner226037d2013-03-16 01:22:12 +00009079 .unlock = spi_disable_blockprotect,
9080 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009081 .read = spi_chip_read,
Stefan Tauner226037d2013-03-16 01:22:12 +00009082 .voltage = {2700, 3600},
9083 },
9084
9085 {
9086 .vendor = "Macronix",
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009087 .name = "MX25L1605A/MX25L1606E/MX25L1608E",
Stefan Tauner226037d2013-03-16 01:22:12 +00009088 .bustype = BUS_SPI,
9089 .manufacture_id = MACRONIX_ID,
9090 .model_id = MACRONIX_MX25L1605,
9091 .total_size = 2048,
9092 .page_size = 256,
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009093 /* OTP: 64B total; enter 0xB1, exit 0xC1 (MX25L1606E and MX25L1608E only) */
Nico Huber46552c82024-03-27 01:18:12 +01009094 /* FEATURE_FAST_READ_DOUT: MX25L1606E & MX25L1608E */
9095 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_FAST_READ,
Stefan Tauner226037d2013-03-16 01:22:12 +00009096 .tested = TEST_OK_PREW,
9097 .probe = probe_spi_rdid,
9098 .probe_timing = TIMING_ZERO,
9099 .block_erasers =
9100 {
9101 {
9102 .eraseblocks = { {4 * 1024, 512} },
9103 .block_erase = spi_block_erase_20,
9104 }, {
9105 .eraseblocks = { {64 * 1024, 32} },
Carl-Daniel Hailfinger40107122009-10-01 13:15:01 +00009106 .block_erase = spi_block_erase_52,
9107 }, {
9108 .eraseblocks = { {64 * 1024, 32} },
9109 .block_erase = spi_block_erase_d8,
9110 }, {
9111 .eraseblocks = { {2 * 1024 * 1024, 1} },
9112 .block_erase = spi_block_erase_60,
9113 }, {
9114 .eraseblocks = { {2 * 1024 * 1024, 1} },
9115 .block_erase = spi_block_erase_c7,
9116 },
9117 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00009118 .printlock = spi_prettyprint_status_register_bp3_srwd, /* MX25L1605A bp2 only */
Stefan Tauner5c316f92015-02-08 21:57:52 +00009119 .unlock = spi_disable_blockprotect_bp3_srwd,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00009120 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009121 .read = spi_chip_read,
Stefan Tauner226037d2013-03-16 01:22:12 +00009122 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009123 .prepare_access = spi_prepare_io,
9124 .finish_access = spi_finish_io,
Stefan Tauner226037d2013-03-16 01:22:12 +00009125 },
9126
9127 {
9128 .vendor = "Macronix",
Stefan Taunerc2eec2c2014-05-03 21:33:01 +00009129 .name = "MX25L1605D/MX25L1608D/MX25L1673E",
Stefan Tauner226037d2013-03-16 01:22:12 +00009130 .bustype = BUS_SPI,
9131 .manufacture_id = MACRONIX_ID,
9132 .model_id = MACRONIX_MX25L1605,
9133 .total_size = 2048,
9134 .page_size = 256,
Nico Huber46552c82024-03-27 01:18:12 +01009135 /* FEATURE_QIO: MX25L1673E */
9136 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ | FEATURE_FAST_READ_DIO,
Stefan Tauner226037d2013-03-16 01:22:12 +00009137 .tested = TEST_OK_PREW,
9138 .probe = probe_spi_rdid,
9139 .probe_timing = TIMING_ZERO,
9140 .block_erasers =
9141 {
9142 {
9143 .eraseblocks = { {4 * 1024, 512} },
9144 .block_erase = spi_block_erase_20,
9145 }, {
9146 .eraseblocks = { {64 * 1024, 32} },
9147 .block_erase = spi_block_erase_d8,
9148 }, {
9149 .eraseblocks = { {2 * 1024 * 1024, 1} },
9150 .block_erase = spi_block_erase_60,
9151 }, {
9152 .eraseblocks = { {2 * 1024 * 1024, 1} },
9153 .block_erase = spi_block_erase_c7,
9154 },
9155 },
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009156 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6: Continuously Program (CP) mode, for 73E is quad enable */
Stefan Tauner5c316f92015-02-08 21:57:52 +00009157 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Tauner226037d2013-03-16 01:22:12 +00009158 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009159 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00009160 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009161 .prepare_access = spi_prepare_io,
9162 .finish_access = spi_finish_io,
FENG yu ningff692fb2008-12-08 18:15:10 +00009163 },
9164
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009165 {
9166 .vendor = "Macronix",
Stephan Guillouxf5c70902009-04-19 23:04:00 +00009167 .name = "MX25L1635D",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00009168 .bustype = BUS_SPI,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00009169 .manufacture_id = MACRONIX_ID,
9170 .model_id = MACRONIX_MX25L1635D,
Stephan Guillouxf5c70902009-04-19 23:04:00 +00009171 .total_size = 2048,
9172 .page_size = 256,
Stefan Tauner226037d2013-03-16 01:22:12 +00009173 /* OTP: 64B total; enter 0xB1, exit 0xC1 */
Nico Huber46552c82024-03-27 01:18:12 +01009174 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP |
9175 FEATURE_FAST_READ | FEATURE_FAST_READ_DIO | FEATURE_FAST_READ_QIO,
Angel Ponsc2054872021-01-15 18:57:32 +01009176 .tested = TEST_OK_PREW,
Stephan Guillouxf5c70902009-04-19 23:04:00 +00009177 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00009178 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00009179 .block_erasers =
9180 {
9181 {
9182 .eraseblocks = { {4 * 1024, 512} },
9183 .block_erase = spi_block_erase_20,
9184 }, {
9185 .eraseblocks = { {64 * 1024, 32} },
9186 .block_erase = spi_block_erase_d8,
9187 }, {
9188 .eraseblocks = { {2 * 1024 * 1024, 1} },
9189 .block_erase = spi_block_erase_60,
9190 }, {
9191 .eraseblocks = { {2 * 1024 * 1024, 1} },
9192 .block_erase = spi_block_erase_c7,
9193 }
9194 },
Nico Huber46552c82024-03-27 01:18:12 +01009195 .reg_bits =
9196 {
9197 .qe = {STATUS1, 6, RW},
9198 },
9199 .printlock = spi_prettyprint_status_register_bp3_srwd,
Stefan Tauner5c316f92015-02-08 21:57:52 +00009200 .unlock = spi_disable_blockprotect_bp3_srwd,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00009201 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009202 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00009203 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009204 .prepare_access = spi_prepare_io,
9205 .finish_access = spi_finish_io,
Stephan Guillouxf5c70902009-04-19 23:04:00 +00009206 },
Stephan Guillouxfd315502009-04-20 22:54:13 +00009207
Stephan Guillouxf5c70902009-04-19 23:04:00 +00009208 {
9209 .vendor = "Macronix",
Stephan Guilloux3611b802010-09-13 19:59:28 +00009210 .name = "MX25L1635E",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00009211 .bustype = BUS_SPI,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00009212 .manufacture_id = MACRONIX_ID,
9213 .model_id = MACRONIX_MX25L1635E,
Stephan Guilloux3611b802010-09-13 19:59:28 +00009214 .total_size = 2048,
9215 .page_size = 256,
Stefan Tauner226037d2013-03-16 01:22:12 +00009216 /* OTP: 64B total; enter 0xB1, exit 0xC1 */
Nico Huber46552c82024-03-27 01:18:12 +01009217 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP |
9218 FEATURE_FAST_READ | FEATURE_FAST_READ_DIO | FEATURE_FAST_READ_QIO,
Stephan Guilloux3611b802010-09-13 19:59:28 +00009219 .tested = TEST_UNTESTED,
9220 .probe = probe_spi_rdid,
9221 .probe_timing = TIMING_ZERO,
9222 .block_erasers =
9223 {
9224 {
9225 .eraseblocks = { {4 * 1024, 512} },
9226 .block_erase = spi_block_erase_20,
9227 }, {
9228 .eraseblocks = { {64 * 1024, 32} },
9229 .block_erase = spi_block_erase_d8,
9230 }, {
9231 .eraseblocks = { {2 * 1024 * 1024, 1} },
9232 .block_erase = spi_block_erase_60,
9233 }, {
9234 .eraseblocks = { {2 * 1024 * 1024, 1} },
9235 .block_erase = spi_block_erase_c7,
9236 }
9237 },
Nico Huber46552c82024-03-27 01:18:12 +01009238 .reg_bits =
9239 {
9240 .qe = {STATUS1, 6, RW},
9241 },
9242 .printlock = spi_prettyprint_status_register_bp3_srwd,
Stefan Tauner5c316f92015-02-08 21:57:52 +00009243 .unlock = spi_disable_blockprotect_bp3_srwd,
Stephan Guilloux3611b802010-09-13 19:59:28 +00009244 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009245 .read = spi_chip_read,
Steven Zakulec7d257b42011-07-19 08:50:18 +00009246 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009247 .prepare_access = spi_prepare_io,
9248 .finish_access = spi_finish_io,
Stephan Guilloux3611b802010-09-13 19:59:28 +00009249 },
9250
9251 {
9252 .vendor = "Macronix",
Alan Green1f9cc7d2019-07-01 11:10:45 +10009253 .name = "MX25L2005(C)/MX25L2006E",
9254 .bustype = BUS_SPI,
9255 .manufacture_id = MACRONIX_ID,
9256 .model_id = MACRONIX_MX25L2005,
9257 .total_size = 256,
9258 .page_size = 256,
Nico Huber46552c82024-03-27 01:18:12 +01009259 /* FEATURE_FAST_READ_DOUT: MX25L2006E */
9260 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009261 .tested = TEST_OK_PREW,
9262 .probe = probe_spi_rdid,
9263 .probe_timing = TIMING_ZERO,
9264 .block_erasers =
9265 {
9266 {
9267 .eraseblocks = { {4 * 1024, 64} },
9268 .block_erase = spi_block_erase_20,
9269 }, {
9270 .eraseblocks = { {64 * 1024, 4} },
9271 .block_erase = spi_block_erase_52,
9272 }, {
9273 .eraseblocks = { {64 * 1024, 4} },
9274 .block_erase = spi_block_erase_d8,
9275 }, {
9276 .eraseblocks = { {256 * 1024, 1} },
9277 .block_erase = spi_block_erase_60,
9278 }, {
9279 .eraseblocks = { {256 * 1024, 1} },
9280 .block_erase = spi_block_erase_c7,
9281 },
9282 },
9283 .printlock = spi_prettyprint_status_register_bp1_srwd,
9284 .unlock = spi_disable_blockprotect,
9285 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009286 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009287 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009288 .prepare_access = spi_prepare_io,
9289 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009290 },
9291
9292 {
9293 .vendor = "Macronix",
Alan Green03707302019-08-26 12:50:43 +10009294 .name = "MX25L25635F/MX25L25645G",
Alan Green1f9cc7d2019-07-01 11:10:45 +10009295 .bustype = BUS_SPI,
9296 .manufacture_id = MACRONIX_ID,
9297 .model_id = MACRONIX_MX25L25635F,
9298 .total_size = 32768,
9299 .page_size = 256,
9300 /* OTP: 512B total; enter 0xB1, exit 0xC1 */
Nico Huber46552c82024-03-27 01:18:12 +01009301 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP |
9302 FEATURE_4BA | FEATURE_QPI_35 | FEATURE_FAST_READ_QPI4B,
9303 .dummy_cycles = { .qpi_read_params = { 6, 4, 8, 10 } },
Nico Huberc972aed2024-08-30 02:06:41 +02009304 .tested = TEST_OK_PREWB,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009305 .probe = probe_spi_rdid,
9306 .probe_timing = TIMING_ZERO,
9307 .block_erasers =
9308 {
9309 {
9310 .eraseblocks = { {4 * 1024, 8192} },
9311 .block_erase = spi_block_erase_21,
9312 }, {
9313 .eraseblocks = { {4 * 1024, 8192} },
9314 .block_erase = spi_block_erase_20,
9315 }, {
9316 .eraseblocks = { {32 * 1024, 1024} },
9317 .block_erase = spi_block_erase_5c,
9318 }, {
9319 .eraseblocks = { {32 * 1024, 1024} },
9320 .block_erase = spi_block_erase_52,
9321 }, {
9322 .eraseblocks = { {64 * 1024, 512} },
9323 .block_erase = spi_block_erase_dc,
9324 }, {
9325 .eraseblocks = { {64 * 1024, 512} },
9326 .block_erase = spi_block_erase_d8,
9327 }, {
9328 .eraseblocks = { {32 * 1024 * 1024, 1} },
9329 .block_erase = spi_block_erase_60,
9330 }, {
9331 .eraseblocks = { {32 * 1024 * 1024, 1} },
9332 .block_erase = spi_block_erase_c7,
9333 }
9334 },
9335 /* TODO: security register and SBLK/SBULK; MX25L12835F: configuration register */
Nico Huber46552c82024-03-27 01:18:12 +01009336 .reg_bits = {
9337 .qe = {STATUS1, 6, RW},
9338 .dc = {{CONFIG, 6, RW}, {CONFIG, 7, RW}},
Nico Huberc972aed2024-08-30 02:06:41 +02009339 .srp = {STATUS1, 7, RW},
9340 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}, {STATUS1, 5, RW}},
9341 .tb = {CONFIG, 3, OTP},
Nico Huber46552c82024-03-27 01:18:12 +01009342 },
Nico Huberc972aed2024-08-30 02:06:41 +02009343 .wp_write_cfg = spi_wp_write_cfg,
9344 .wp_read_cfg = spi_wp_read_cfg,
9345 .wp_get_ranges = spi_wp_get_available_ranges,
9346 .decode_range = decode_range_spi25,
Nico Huber46552c82024-03-27 01:18:12 +01009347 .printlock = spi_prettyprint_status_register_bp3_srwd,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009348 .unlock = spi_disable_blockprotect_bp3_srwd,
9349 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009350 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009351 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009352 .prepare_access = spi_prepare_io,
9353 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009354 },
9355
9356 {
9357 .vendor = "Macronix",
Stefan Tauner226037d2013-03-16 01:22:12 +00009358 .name = "MX25L3205(A)",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00009359 .bustype = BUS_SPI,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00009360 .manufacture_id = MACRONIX_ID,
9361 .model_id = MACRONIX_MX25L3205,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009362 .total_size = 4096,
9363 .page_size = 256,
Nico Huber46552c82024-03-27 01:18:12 +01009364 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ,
David Hendricks22e05322010-12-13 23:54:59 +00009365 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009366 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00009367 .probe_timing = TIMING_ZERO,
Sean Nelson6b11ad22009-12-23 17:05:59 +00009368 .block_erasers =
9369 {
9370 {
Stefan Tauner226037d2013-03-16 01:22:12 +00009371 .eraseblocks = { {64 * 1024, 64} },
Sean Nelson6b11ad22009-12-23 17:05:59 +00009372 .block_erase = spi_block_erase_20,
9373 }, {
Stefan Tauner226037d2013-03-16 01:22:12 +00009374 .eraseblocks = { {64 * 1024, 64} },
Sean Nelson6b11ad22009-12-23 17:05:59 +00009375 .block_erase = spi_block_erase_d8,
9376 }, {
9377 .eraseblocks = { {4 * 1024 * 1024, 1} },
9378 .block_erase = spi_block_erase_60,
9379 }, {
9380 .eraseblocks = { {4 * 1024 * 1024, 1} },
9381 .block_erase = spi_block_erase_c7,
9382 },
9383 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00009384 .printlock = spi_prettyprint_status_register_bp2_srwd, /* bit6: error flag */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +00009385 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00009386 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009387 .read = spi_chip_read,
Stefan Tauner226037d2013-03-16 01:22:12 +00009388 .voltage = {2700, 3600},
9389 },
9390
9391 {
9392 .vendor = "Macronix",
9393 .name = "MX25L3205D/MX25L3208D",
9394 .bustype = BUS_SPI,
9395 .manufacture_id = MACRONIX_ID,
9396 .model_id = MACRONIX_MX25L3205,
9397 .total_size = 4096,
9398 .page_size = 256,
9399 /* OTP: 64B total; enter 0xB1, exit 0xC1 */
Nico Huber46552c82024-03-27 01:18:12 +01009400 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_FAST_READ | FEATURE_FAST_READ_DIO,
Stefan Tauner226037d2013-03-16 01:22:12 +00009401 .tested = TEST_OK_PREW,
9402 .probe = probe_spi_rdid,
9403 .probe_timing = TIMING_ZERO,
9404 .block_erasers =
9405 {
9406 {
9407 .eraseblocks = { {4 * 1024, 1024} },
9408 .block_erase = spi_block_erase_20,
9409 }, {
9410 .eraseblocks = { {64 * 1024, 64} },
9411 .block_erase = spi_block_erase_d8,
9412 }, {
9413 .eraseblocks = { {4 * 1024 * 1024, 1} },
9414 .block_erase = spi_block_erase_60,
9415 }, {
9416 .eraseblocks = { {4 * 1024 * 1024, 1} },
9417 .block_erase = spi_block_erase_c7,
9418 },
9419 },
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009420 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6: continuously program mode */
Stefan Tauner5c316f92015-02-08 21:57:52 +00009421 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Tauner226037d2013-03-16 01:22:12 +00009422 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009423 .read = spi_chip_read,
Stefan Tauner226037d2013-03-16 01:22:12 +00009424 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009425 .prepare_access = spi_prepare_io,
9426 .finish_access = spi_finish_io,
Stefan Tauner226037d2013-03-16 01:22:12 +00009427 },
9428
9429 {
9430 .vendor = "Macronix",
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009431 .name = "MX25L3206E/MX25L3208E",
Stefan Tauner226037d2013-03-16 01:22:12 +00009432 .bustype = BUS_SPI,
9433 .manufacture_id = MACRONIX_ID,
9434 .model_id = MACRONIX_MX25L3205,
9435 .total_size = 4096,
9436 .page_size = 256,
9437 /* OTP: 64B total; enter 0xB1, exit 0xC1 */
Nico Huber46552c82024-03-27 01:18:12 +01009438 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_FAST_READ | FEATURE_FAST_READ_DOUT,
Stefan Tauner226037d2013-03-16 01:22:12 +00009439 .tested = TEST_OK_PREW,
9440 .probe = probe_spi_rdid,
9441 .probe_timing = TIMING_ZERO,
9442 .block_erasers =
9443 {
9444 {
9445 .eraseblocks = { {4 * 1024, 1024} },
9446 .block_erase = spi_block_erase_20,
9447 }, {
9448 .eraseblocks = { {64 * 1024, 64} },
9449 .block_erase = spi_block_erase_d8,
9450 }, {
9451 .eraseblocks = { {64 * 1024, 64} },
9452 .block_erase = spi_block_erase_52,
9453 }, {
9454 .eraseblocks = { {4 * 1024 * 1024, 1} },
9455 .block_erase = spi_block_erase_60,
9456 }, {
9457 .eraseblocks = { {4 * 1024 * 1024, 1} },
9458 .block_erase = spi_block_erase_c7,
9459 },
9460 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00009461 .printlock = spi_prettyprint_status_register_bp3_srwd,
Stefan Tauner5c316f92015-02-08 21:57:52 +00009462 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Tauner226037d2013-03-16 01:22:12 +00009463 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009464 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00009465 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009466 .prepare_access = spi_prepare_io,
9467 .finish_access = spi_finish_io,
FENG yu ningff692fb2008-12-08 18:15:10 +00009468 },
9469
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009470 {
9471 .vendor = "Macronix",
Alan Green1f9cc7d2019-07-01 11:10:45 +10009472 .name = "MX25L3235D",
9473 .bustype = BUS_SPI,
9474 .manufacture_id = MACRONIX_ID,
9475 .model_id = MACRONIX_MX25L3235D,
9476 .total_size = 4096,
9477 .page_size = 256,
9478 /* OTP: 256B total; enter 0xB1, exit 0xC1 */
Nico Huber46552c82024-03-27 01:18:12 +01009479 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP |
9480 FEATURE_FAST_READ | FEATURE_FAST_READ_DIO | FEATURE_FAST_READ_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009481 .tested = TEST_UNTESTED,
9482 .probe = probe_spi_rdid,
9483 .probe_timing = TIMING_ZERO,
9484 .block_erasers =
9485 {
9486 {
9487 .eraseblocks = { {4 * 1024, 1024} },
9488 .block_erase = spi_block_erase_20,
9489 }, {
9490 .eraseblocks = { {64 * 1024, 64} },
9491 .block_erase = spi_block_erase_d8,
9492 }, {
9493 .eraseblocks = { {4 * 1024 * 1024, 1} },
9494 .block_erase = spi_block_erase_60,
9495 }, {
9496 .eraseblocks = { {4 * 1024 * 1024, 1} },
9497 .block_erase = spi_block_erase_c7,
9498 }
9499 },
Nico Huber46552c82024-03-27 01:18:12 +01009500 .reg_bits =
9501 {
9502 .qe = {STATUS1, 6, RW},
9503 },
9504 .printlock = spi_prettyprint_status_register_bp3_srwd,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009505 .unlock = spi_disable_blockprotect_bp3_srwd,
9506 .write = spi_chip_write_256,
9507 .read = spi_chip_read,
9508 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009509 .prepare_access = spi_prepare_io,
9510 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009511 },
9512
9513 {
9514 .vendor = "Macronix",
Nico Huberb6683e02021-04-21 13:04:29 +02009515 .name = "MX25L3233F/MX25L3273E",
Stefan Taunerc2eec2c2014-05-03 21:33:01 +00009516 .bustype = BUS_SPI,
9517 .manufacture_id = MACRONIX_ID,
9518 .model_id = MACRONIX_MX25L3205,
9519 .total_size = 4096,
9520 .page_size = 256,
Nico Huber6e69e2b2021-04-21 13:03:13 +02009521 /* OTP: 512B total; enter 0xB1, exit 0xC1 */
Nico Huber46552c82024-03-27 01:18:12 +01009522 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QIO,
Stefan Tauner23e10b82016-01-23 16:16:49 +00009523 .tested = TEST_OK_PREW,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +00009524 .probe = probe_spi_rdid,
9525 .probe_timing = TIMING_ZERO,
9526 .block_erasers =
9527 {
9528 {
9529 .eraseblocks = { {4 * 1024, 1024} },
9530 .block_erase = spi_block_erase_20,
9531 }, {
9532 .eraseblocks = { {32 * 1024, 128} },
9533 .block_erase = spi_block_erase_52,
9534 }, {
9535 .eraseblocks = { {64 * 1024, 64} },
9536 .block_erase = spi_block_erase_d8,
9537 }, {
9538 .eraseblocks = { {4 * 1024 * 1024, 1} },
9539 .block_erase = spi_block_erase_60,
9540 }, {
9541 .eraseblocks = { {4 * 1024 * 1024, 1} },
9542 .block_erase = spi_block_erase_c7,
9543 },
9544 },
Nico Huber46552c82024-03-27 01:18:12 +01009545 .reg_bits =
9546 {
9547 .qe = {STATUS1, 6, RW},
9548 },
Stefan Tauner12f3d512014-05-27 21:27:27 +00009549 .printlock = spi_prettyprint_status_register_bp3_srwd,
Stefan Tauner5c316f92015-02-08 21:57:52 +00009550 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +00009551 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009552 .read = spi_chip_read,
Nico Huberb6683e02021-04-21 13:04:29 +02009553 .voltage = {2700, 3600}, /* 33F 2.65V..3.6V */
Nico Huber930d4212024-05-04 18:59:15 +02009554 .prepare_access = spi_prepare_io,
9555 .finish_access = spi_finish_io,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +00009556 },
9557
9558 {
9559 .vendor = "Macronix",
Alan Green1f9cc7d2019-07-01 11:10:45 +10009560 .name = "MX25L4005(A/C)/MX25L4006E",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00009561 .bustype = BUS_SPI,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00009562 .manufacture_id = MACRONIX_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009563 .model_id = MACRONIX_MX25L4005,
9564 .total_size = 512,
Stephan Guilloux70ea9a32009-04-23 22:51:56 +00009565 .page_size = 256,
Nico Huber46552c82024-03-27 01:18:12 +01009566 /* FEATURE_FAST_READ_DOUT: MX25L4006E */
9567 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009568 .tested = TEST_OK_PREW,
Stephan Guilloux70ea9a32009-04-23 22:51:56 +00009569 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00009570 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00009571 .block_erasers =
9572 {
9573 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009574 .eraseblocks = { {4 * 1024, 128} },
Sean Nelson54596372010-01-09 05:30:14 +00009575 .block_erase = spi_block_erase_20,
9576 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009577 .eraseblocks = { {64 * 1024, 8} },
9578 .block_erase = spi_block_erase_52,
9579 }, {
9580 .eraseblocks = { {64 * 1024, 8} },
Sean Nelson54596372010-01-09 05:30:14 +00009581 .block_erase = spi_block_erase_d8,
9582 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009583 .eraseblocks = { {512 * 1024, 1} },
Sean Nelson54596372010-01-09 05:30:14 +00009584 .block_erase = spi_block_erase_60,
9585 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009586 .eraseblocks = { {512 * 1024, 1} },
Sean Nelson54596372010-01-09 05:30:14 +00009587 .block_erase = spi_block_erase_c7,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009588 },
Sean Nelson54596372010-01-09 05:30:14 +00009589 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10009590 .printlock = spi_prettyprint_status_register_bp2_srwd,
9591 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00009592 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009593 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +00009594 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009595 .prepare_access = spi_prepare_io,
9596 .finish_access = spi_finish_io,
Stephan Guilloux70ea9a32009-04-23 22:51:56 +00009597 },
9598
9599 {
9600 .vendor = "Macronix",
Alan Green1f9cc7d2019-07-01 11:10:45 +10009601 .name = "MX25L512(E)/MX25V512(C)",
9602 .bustype = BUS_SPI,
9603 .manufacture_id = MACRONIX_ID,
9604 .model_id = MACRONIX_MX25L512,
9605 .total_size = 64,
9606 .page_size = 256,
9607 /* MX25L512E supports SFDP */
Nico Huber46552c82024-03-27 01:18:12 +01009608 /* FEATURE_FAST_READ_DOUT: MX25L512E */
9609 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009610 .tested = TEST_OK_PREW,
9611 .probe = probe_spi_rdid,
9612 .probe_timing = TIMING_ZERO,
9613 .block_erasers =
9614 {
9615 {
9616 .eraseblocks = { {4 * 1024, 16} },
9617 .block_erase = spi_block_erase_20,
9618 }, {
9619 .eraseblocks = { {64 * 1024, 1} },
9620 .block_erase = spi_block_erase_52,
9621 }, {
9622 .eraseblocks = { {64 * 1024, 1} },
9623 .block_erase = spi_block_erase_d8,
9624 }, {
9625 .eraseblocks = { {64 * 1024, 1} },
9626 .block_erase = spi_block_erase_60,
9627 }, {
9628 .eraseblocks = { {64 * 1024, 1} },
9629 .block_erase = spi_block_erase_c7,
9630 },
9631 },
9632 .printlock = spi_prettyprint_status_register_bp1_srwd,
9633 .unlock = spi_disable_blockprotect,
9634 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009635 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009636 .voltage = {2700, 3600}, /* 2.35-3.6V for MX25V512(C) */
9637 },
9638
9639 {
9640 .vendor = "Macronix",
Steve Markgraf7e6f3a72020-07-13 18:22:56 +02009641 .name = "MX25L5121E",
9642 .bustype = BUS_SPI,
9643 .manufacture_id = MACRONIX_ID,
9644 .model_id = MACRONIX_MX25L5121E,
9645 .total_size = 64,
9646 .page_size = 32,
Nico Huber46552c82024-03-27 01:18:12 +01009647 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ,
Steve Markgraf7e6f3a72020-07-13 18:22:56 +02009648 .tested = TEST_OK_PREW,
9649 .probe = probe_spi_rdid,
9650 .probe_timing = TIMING_ZERO,
9651 .block_erasers =
9652 {
9653 {
9654 .eraseblocks = { {4 * 1024, 16} },
9655 .block_erase = spi_block_erase_20,
9656 }, {
9657 .eraseblocks = { {64 * 1024, 1} },
9658 .block_erase = spi_block_erase_52,
9659 }, {
9660 .eraseblocks = { {64 * 1024, 1} },
9661 .block_erase = spi_block_erase_d8,
9662 }, {
9663 .eraseblocks = { {64 * 1024, 1} },
9664 .block_erase = spi_block_erase_60,
9665 }, {
9666 .eraseblocks = { {64 * 1024, 1} },
9667 .block_erase = spi_block_erase_c7,
9668 },
9669 },
9670 .printlock = spi_prettyprint_status_register_bp1_srwd,
9671 .unlock = spi_disable_blockprotect,
9672 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009673 .read = spi_chip_read,
Steve Markgraf7e6f3a72020-07-13 18:22:56 +02009674 .voltage = {2700, 3600},
9675 },
9676
9677 {
9678 .vendor = "Macronix",
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009679 .name = "MX25L6405",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00009680 .bustype = BUS_SPI,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00009681 .manufacture_id = MACRONIX_ID,
9682 .model_id = MACRONIX_MX25L6405,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009683 .total_size = 8192,
9684 .page_size = 256,
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009685 /* Has an additional 512B EEPROM sector */
9686 .feature_bits = FEATURE_WRSR_WREN,
Paul Menzelac427b22012-02-16 21:07:07 +00009687 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009688 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00009689 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00009690 .block_erasers =
9691 {
9692 {
9693 .eraseblocks = { {64 * 1024, 128} },
9694 .block_erase = spi_block_erase_20,
9695 }, {
9696 .eraseblocks = { {64 * 1024, 128} },
9697 .block_erase = spi_block_erase_d8,
9698 }, {
9699 .eraseblocks = { {8 * 1024 * 1024, 1} },
9700 .block_erase = spi_block_erase_60,
9701 }, {
9702 .eraseblocks = { {8 * 1024 * 1024, 1} },
9703 .block_erase = spi_block_erase_c7,
9704 }
9705 },
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009706 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6: error flag */
Stefan Tauner5c316f92015-02-08 21:57:52 +00009707 .unlock = spi_disable_blockprotect_bp3_srwd,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00009708 .write = spi_chip_write_256,
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009709 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +00009710 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +00009711 },
9712
Stephan Guilloux5c5b5252009-01-08 03:40:17 +00009713 {
9714 .vendor = "Macronix",
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009715 .name = "MX25L6405D",
Stefan Tauner226037d2013-03-16 01:22:12 +00009716 .bustype = BUS_SPI,
9717 .manufacture_id = MACRONIX_ID,
9718 .model_id = MACRONIX_MX25L6405,
9719 .total_size = 8192,
9720 .page_size = 256,
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009721 /* OTP: 64B total; enter 0xB1, exit 0xC1 */
Nico Huber46552c82024-03-27 01:18:12 +01009722 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_FAST_READ | FEATURE_FAST_READ_DIO,
Stefan Tauner226037d2013-03-16 01:22:12 +00009723 .tested = TEST_OK_PREW,
9724 .probe = probe_spi_rdid,
9725 .probe_timing = TIMING_ZERO,
9726 .block_erasers =
9727 {
9728 {
9729 .eraseblocks = { {4 * 1024, 2048} },
9730 .block_erase = spi_block_erase_20,
9731 }, {
9732 .eraseblocks = { {64 * 1024, 128} },
9733 .block_erase = spi_block_erase_d8,
9734 }, {
9735 .eraseblocks = { {8 * 1024 * 1024, 1} },
9736 .block_erase = spi_block_erase_60,
9737 }, {
9738 .eraseblocks = { {8 * 1024 * 1024, 1} },
9739 .block_erase = spi_block_erase_c7,
9740 }
9741 },
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009742 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6: continuously program mode */
Stefan Tauner5c316f92015-02-08 21:57:52 +00009743 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Tauner226037d2013-03-16 01:22:12 +00009744 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009745 .read = spi_chip_read,
Stefan Tauner226037d2013-03-16 01:22:12 +00009746 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009747 .prepare_access = spi_prepare_io,
9748 .finish_access = spi_finish_io,
Stefan Tauner226037d2013-03-16 01:22:12 +00009749 },
9750
9751 {
9752 .vendor = "Macronix",
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009753 .name = "MX25L6406E/MX25L6408E",
9754 .bustype = BUS_SPI,
9755 .manufacture_id = MACRONIX_ID,
9756 .model_id = MACRONIX_MX25L6405,
9757 .total_size = 8192,
9758 .page_size = 256,
9759 /* MX25L6406E supports SFDP */
9760 /* OTP: 06E 64B total; enter 0xB1, exit 0xC1 */
Nico Huber46552c82024-03-27 01:18:12 +01009761 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_FAST_READ | FEATURE_FAST_READ_DOUT,
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009762 .tested = TEST_OK_PREW,
9763 .probe = probe_spi_rdid,
9764 .probe_timing = TIMING_ZERO,
9765 .block_erasers =
9766 {
9767 {
9768 .eraseblocks = { {4 * 1024, 2048} },
9769 .block_erase = spi_block_erase_20,
9770 }, {
9771 .eraseblocks = { {64 * 1024, 128} },
9772 .block_erase = spi_block_erase_52,
9773 }, {
9774 .eraseblocks = { {64 * 1024, 128} },
9775 .block_erase = spi_block_erase_d8,
9776 }, {
9777 .eraseblocks = { {8 * 1024 * 1024, 1} },
9778 .block_erase = spi_block_erase_60,
9779 }, {
9780 .eraseblocks = { {8 * 1024 * 1024, 1} },
9781 .block_erase = spi_block_erase_c7,
9782 }
9783 },
9784 .printlock = spi_prettyprint_status_register_bp3_srwd,
9785 .unlock = spi_disable_blockprotect_bp3_srwd,
9786 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009787 .read = spi_chip_read,
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009788 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009789 .prepare_access = spi_prepare_io,
9790 .finish_access = spi_finish_io,
Stefan Tauner74dc73f2015-03-01 22:04:38 +00009791 },
9792
9793 {
9794 .vendor = "Macronix",
Nico Huberb0072782017-12-06 21:02:57 +01009795 .name = "MX25L6436E/MX25L6445E/MX25L6465E/MX25L6473E/MX25L6473F",
Stefan Tauner226037d2013-03-16 01:22:12 +00009796 .bustype = BUS_SPI,
9797 .manufacture_id = MACRONIX_ID,
9798 .model_id = MACRONIX_MX25L6405,
9799 .total_size = 8192,
9800 .page_size = 256,
9801 /* supports SFDP */
9802 /* OTP: 512B total; enter 0xB1, exit 0xC1 */
Nico Huber46552c82024-03-27 01:18:12 +01009803 /* FEATURE_QIO: MX25L6473E, MX25L6473F */
9804 /* FEATURE_FAST_READ_DOUT, _QOUT: MX25L6436E */
9805 /* FEATURE_FAST_READ_DIO, _QIO: MX25L6445E, MX25L6465E */
9806 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_FAST_READ,
Stefan Tauner226037d2013-03-16 01:22:12 +00009807 .tested = TEST_OK_PREW,
9808 .probe = probe_spi_rdid,
9809 .probe_timing = TIMING_ZERO,
9810 .block_erasers =
9811 {
9812 {
9813 .eraseblocks = { {4 * 1024, 2048} },
9814 .block_erase = spi_block_erase_20,
9815 }, {
9816 .eraseblocks = { {32 * 1024, 256} },
9817 .block_erase = spi_block_erase_52,
9818 }, {
9819 .eraseblocks = { {64 * 1024, 128} },
9820 .block_erase = spi_block_erase_d8,
9821 }, {
9822 .eraseblocks = { {8 * 1024 * 1024, 1} },
9823 .block_erase = spi_block_erase_60,
9824 }, {
9825 .eraseblocks = { {8 * 1024 * 1024, 1} },
9826 .block_erase = spi_block_erase_c7,
9827 }
9828 },
Nico Huber46552c82024-03-27 01:18:12 +01009829 .reg_bits =
9830 {
9831 .qe = {STATUS1, 6, RW},
9832 },
9833 .printlock = spi_prettyprint_status_register_bp3_srwd,
Stefan Tauner5c316f92015-02-08 21:57:52 +00009834 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Tauner226037d2013-03-16 01:22:12 +00009835 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009836 .read = spi_chip_read,
Stefan Tauner226037d2013-03-16 01:22:12 +00009837 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009838 .prepare_access = spi_prepare_io,
9839 .finish_access = spi_finish_io,
Stefan Tauner226037d2013-03-16 01:22:12 +00009840 },
9841
9842 {
9843 .vendor = "Macronix",
Alan Green1f9cc7d2019-07-01 11:10:45 +10009844 .name = "MX25L6495F",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +00009845 .bustype = BUS_SPI,
Mattias Mattsson6eabe282010-09-15 23:31:03 +00009846 .manufacture_id = MACRONIX_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009847 .model_id = MACRONIX_MX25L6495F,
9848 .total_size = 8192,
Stephan Guilloux2f132fe2009-04-21 01:47:16 +00009849 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009850 /* OTP: 1024B total; enter 0xB1, exit 0xC1 */
Stefan Tauner226037d2013-03-16 01:22:12 +00009851 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Stefan Tauner0554ca52013-07-25 22:54:25 +00009852 .tested = TEST_OK_PREW,
Stephan Guilloux2f132fe2009-04-21 01:47:16 +00009853 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +00009854 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +00009855 .block_erasers =
9856 {
9857 {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009858 .eraseblocks = { {4 * 1024, 2048} },
Sean Nelson54596372010-01-09 05:30:14 +00009859 .block_erase = spi_block_erase_20,
9860 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009861 .eraseblocks = { {32 * 1024, 256} },
9862 .block_erase = spi_block_erase_52,
9863 }, {
Aarya Chaumal478e1792022-06-04 01:34:44 +05309864 .eraseblocks = { {64 * 1024, 128} },
9865 .block_erase = spi_block_erase_d8,
9866 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009867 .eraseblocks = { {8 * 1024 * 1024, 1} },
Sean Nelson54596372010-01-09 05:30:14 +00009868 .block_erase = spi_block_erase_60,
9869 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009870 .eraseblocks = { {8 * 1024 * 1024, 1} },
Sean Nelson54596372010-01-09 05:30:14 +00009871 .block_erase = spi_block_erase_c7,
9872 }
9873 },
Alan Green1f9cc7d2019-07-01 11:10:45 +10009874 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +00009875 .write = spi_chip_write_256,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009876 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
Stefan Tauner5c316f92015-02-08 21:57:52 +00009877 .voltage = {2700, 3600},
9878 },
9879
9880 {
9881 .vendor = "Macronix",
Alan Green1f9cc7d2019-07-01 11:10:45 +10009882 .name = "MX25L8005/MX25L8006E/MX25L8008E/MX25V8005",
Stefan Tauner5c316f92015-02-08 21:57:52 +00009883 .bustype = BUS_SPI,
9884 .manufacture_id = MACRONIX_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009885 .model_id = MACRONIX_MX25L8005,
9886 .total_size = 1024,
9887 .page_size = 256,
9888 /* MX25L8006E, MX25L8008E support SFDP */
9889 /* OTP: 64B total; enter 0xB1, exit 0xC1 (MX25L8006E, MX25L8008E only) */
Nico Huber46552c82024-03-27 01:18:12 +01009890 /* FEATURE_FAST_READ_DOUT: MX25L8006E, MX25L8008E */
9891 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009892 .tested = TEST_OK_PREW,
9893 .probe = probe_spi_rdid,
9894 .probe_timing = TIMING_ZERO,
9895 .block_erasers =
9896 {
9897 {
9898 .eraseblocks = { {4 * 1024, 256} },
9899 .block_erase = spi_block_erase_20,
9900 }, {
9901 .eraseblocks = { {64 * 1024, 16} },
9902 .block_erase = spi_block_erase_52,
9903 }, {
9904 .eraseblocks = { {64 * 1024, 16} },
9905 .block_erase = spi_block_erase_d8,
9906 }, {
9907 .eraseblocks = { {1024 * 1024, 1} },
9908 .block_erase = spi_block_erase_60,
9909 }, {
9910 .eraseblocks = { {1024 * 1024, 1} },
9911 .block_erase = spi_block_erase_c7,
9912 },
9913 },
9914 .printlock = spi_prettyprint_status_register_bp2_srwd,
9915 .unlock = spi_disable_blockprotect,
9916 .write = spi_chip_write_256,
Nico Huber46552c82024-03-27 01:18:12 +01009917 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009918 .voltage = {2700, 3600}, /* 2.35-3.6V for MX25V8005 */
9919 },
9920
9921 {
9922 .vendor = "Macronix",
sibradzicf62623c2020-03-14 17:21:34 +09009923 .name = "MX25R3235F",
9924 .bustype = BUS_SPI,
9925 .manufacture_id = MACRONIX_ID,
9926 .model_id = MACRONIX_MX25R3235F,
9927 .total_size = 4096,
9928 .page_size = 256,
9929 /* OTP: 1024B total; enter 0xB1, exit 0xC1 */
Nico Huber5f509992024-03-27 01:18:12 +01009930 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QIO,
sibradzicf62623c2020-03-14 17:21:34 +09009931 .tested = TEST_OK_PREW,
9932 .probe = probe_spi_rdid,
9933 .probe_timing = TIMING_ZERO,
9934 .block_erasers =
9935 {
9936 {
9937 .eraseblocks = { {4 * 1024, 1024} },
9938 .block_erase = spi_block_erase_20,
9939 }, {
sibradzicf62623c2020-03-14 17:21:34 +09009940 .eraseblocks = { {32 * 1024, 128} },
9941 .block_erase = spi_block_erase_52,
9942 }, {
Aarya Chaumal478e1792022-06-04 01:34:44 +05309943 .eraseblocks = { {64 * 1024, 64} },
9944 .block_erase = spi_block_erase_d8,
9945 }, {
sibradzicf62623c2020-03-14 17:21:34 +09009946 .eraseblocks = { {4 * 1024 * 1024, 1} },
9947 .block_erase = spi_block_erase_60,
9948 }, {
9949 .eraseblocks = { {4 * 1024 * 1024, 1} },
9950 .block_erase = spi_block_erase_c7,
9951 }
9952 },
Nico Huber5f509992024-03-27 01:18:12 +01009953 .reg_bits =
9954 {
9955 .qe = {STATUS1, 6, RW},
9956 },
9957 .printlock = spi_prettyprint_status_register_bp3_srwd,
sibradzicf62623c2020-03-14 17:21:34 +09009958 .unlock = spi_disable_blockprotect_bp3_srwd,
9959 .write = spi_chip_write_256,
Nico Huber5f509992024-03-27 01:18:12 +01009960 .read = spi_chip_read,
sibradzicf62623c2020-03-14 17:21:34 +09009961 .voltage = {1650, 3600},
Nico Huber930d4212024-05-04 18:59:15 +02009962 .prepare_access = spi_prepare_io,
9963 .finish_access = spi_finish_io,
sibradzicf62623c2020-03-14 17:21:34 +09009964 },
9965
9966 {
9967 .vendor = "Macronix",
Alan Green1f9cc7d2019-07-01 11:10:45 +10009968 .name = "MX25R6435F",
9969 .bustype = BUS_SPI,
9970 .manufacture_id = MACRONIX_ID,
9971 .model_id = MACRONIX_MX25R6435F,
9972 .total_size = 8192,
9973 .page_size = 256,
9974 /* OTP: 1024B total; enter 0xB1, exit 0xC1 */
Nico Huber5f509992024-03-27 01:18:12 +01009975 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +10009976 .tested = TEST_OK_PREW,
9977 .probe = probe_spi_rdid,
9978 .probe_timing = TIMING_ZERO,
9979 .block_erasers =
9980 {
9981 {
9982 .eraseblocks = { {4 * 1024, 2048} },
9983 .block_erase = spi_block_erase_20,
9984 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009985 .eraseblocks = { {32 * 1024, 256} },
9986 .block_erase = spi_block_erase_52,
9987 }, {
Aarya Chaumal478e1792022-06-04 01:34:44 +05309988 .eraseblocks = { {64 * 1024, 128} },
9989 .block_erase = spi_block_erase_d8,
9990 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +10009991 .eraseblocks = { {8 * 1024 * 1024, 1} },
9992 .block_erase = spi_block_erase_60,
9993 }, {
9994 .eraseblocks = { {8 * 1024 * 1024, 1} },
9995 .block_erase = spi_block_erase_c7,
9996 }
9997 },
Nico Huber5f509992024-03-27 01:18:12 +01009998 .reg_bits =
9999 {
10000 .qe = {STATUS1, 6, RW},
10001 },
10002 .printlock = spi_prettyprint_status_register_bp3_srwd,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010003 .unlock = spi_disable_blockprotect_bp3_srwd,
10004 .write = spi_chip_write_256,
Nico Huber5f509992024-03-27 01:18:12 +010010005 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010006 .voltage = {1650, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020010007 .prepare_access = spi_prepare_io,
10008 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010009 },
10010
10011 {
10012 .vendor = "Macronix",
10013 .name = "MX25U12835F",
10014 .bustype = BUS_SPI,
10015 .manufacture_id = MACRONIX_ID,
10016 .model_id = MACRONIX_MX25U12835E,
Stefan Tauner5c316f92015-02-08 21:57:52 +000010017 .total_size = 16384,
10018 .page_size = 256,
10019 /* OTP: 512B total; enter 0xB1, exit 0xC1 */
Nico Huber1412d9f2024-01-06 18:25:49 +010010020 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QPI_35,
10021 .dummy_cycles =
10022 {
10023 /* 133MHz version has configuration register
10024 bit to toggle 8 dummy cycles for QIO, defaults: */
10025 .qpi_fast_read = 4,
10026 .qpi_fast_read_qio = 6,
10027 },
Stefan Tauner5c316f92015-02-08 21:57:52 +000010028 .tested = TEST_OK_PREW,
10029 .probe = probe_spi_rdid,
10030 .probe_timing = TIMING_ZERO,
10031 .block_erasers =
10032 {
10033 {
10034 .eraseblocks = { {4 * 1024, 4096} },
10035 .block_erase = spi_block_erase_20,
10036 }, {
10037 .eraseblocks = { {32 * 1024, 512} },
10038 .block_erase = spi_block_erase_52,
10039 }, {
10040 .eraseblocks = { {64 * 1024, 256} },
10041 .block_erase = spi_block_erase_d8,
10042 }, {
10043 .eraseblocks = { {16 * 1024 * 1024, 1} },
10044 .block_erase = spi_block_erase_60,
10045 }, {
10046 .eraseblocks = { {16 * 1024 * 1024, 1} },
10047 .block_erase = spi_block_erase_c7,
10048 }
10049 },
Angel Ponsf112e242018-09-30 20:14:17 +020010050 /* TODO: security register */
Nico Huber4fa39c52024-03-27 01:18:12 +010010051 .reg_bits =
10052 {
10053 .qe = {STATUS1, 6, RW},
10054 },
10055 .printlock = spi_prettyprint_status_register_bp3_srwd,
Angel Ponsf112e242018-09-30 20:14:17 +020010056 .unlock = spi_disable_blockprotect_bp3_srwd,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010057 .write = spi_chip_write_256, /* Multi I/O supported */
Nico Huber1412d9f2024-01-06 18:25:49 +010010058 .read = spi_chip_read,
Angel Ponsf112e242018-09-30 20:14:17 +020010059 .voltage = {1650, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020010060 .prepare_access = spi_prepare_io,
10061 .finish_access = spi_finish_io,
Angel Ponsf112e242018-09-30 20:14:17 +020010062 },
10063
10064 {
10065 .vendor = "Macronix",
Vincent Palatinf800f552013-03-15 02:03:16 +000010066 .name = "MX25U1635E",
10067 .bustype = BUS_SPI,
10068 .manufacture_id = MACRONIX_ID,
10069 .model_id = MACRONIX_MX25U1635E,
10070 .total_size = 2048,
10071 .page_size = 256,
10072 /* OTP: 512B total; enter 0xB1, exit 0xC1 */
Nico Huber1412d9f2024-01-06 18:25:49 +010010073 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_FAST_READ |
10074 FEATURE_FAST_READ_DIO | FEATURE_FAST_READ_QIO | FEATURE_QPI_35_F5,
10075 .dummy_cycles =
10076 {
10077 .qpi_fast_read = 4,
10078 .qpi_fast_read_qio = 6,
10079 },
Stefan Tauner5c316f92015-02-08 21:57:52 +000010080 .tested = TEST_OK_PR,
Vincent Palatinf800f552013-03-15 02:03:16 +000010081 .probe = probe_spi_rdid,
10082 .probe_timing = TIMING_ZERO,
10083 .block_erasers =
10084 {
10085 {
10086 .eraseblocks = { {4 * 1024, 512} },
10087 .block_erase = spi_block_erase_20,
10088 }, {
10089 .eraseblocks = { {32 * 1024, 64} },
10090 .block_erase = spi_block_erase_52,
10091 }, {
10092 .eraseblocks = { {64 * 1024, 32} },
10093 .block_erase = spi_block_erase_d8,
10094 }, {
10095 .eraseblocks = { {2 * 1024 * 1024, 1} },
10096 .block_erase = spi_block_erase_60,
10097 }, {
10098 .eraseblocks = { {2 * 1024 * 1024, 1} },
10099 .block_erase = spi_block_erase_c7,
10100 }
10101 },
10102 /* TODO: security register */
Nico Huber4fa39c52024-03-27 01:18:12 +010010103 .reg_bits =
10104 {
10105 .qe = {STATUS1, 6, RW},
10106 },
10107 .printlock = spi_prettyprint_status_register_bp3_srwd,
Stefan Tauner5c316f92015-02-08 21:57:52 +000010108 .unlock = spi_disable_blockprotect_bp3_srwd,
Vincent Palatinf800f552013-03-15 02:03:16 +000010109 .write = spi_chip_write_256,
Nico Huber1412d9f2024-01-06 18:25:49 +010010110 .read = spi_chip_read,
Vincent Palatinf800f552013-03-15 02:03:16 +000010111 .voltage = {1650, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020010112 .prepare_access = spi_prepare_io,
10113 .finish_access = spi_finish_io,
Vincent Palatinf800f552013-03-15 02:03:16 +000010114 },
10115
10116 {
10117 .vendor = "Macronix",
David Tomaschikf75d8c52019-06-20 09:49:01 -070010118 .name = "MX25U25635F",
10119 .bustype = BUS_SPI,
10120 .manufacture_id = MACRONIX_ID,
10121 .model_id = MACRONIX_MX25U25635F,
10122 .total_size = 32768,
10123 .page_size = 256,
10124 /* OTP: 512B total; enter 0xB1, exit 0xC1 */
Nico Huber1412d9f2024-01-06 18:25:49 +010010125 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP |
10126 FEATURE_4BA | FEATURE_QPI_35 | FEATURE_FAST_READ_QPI4B,
10127 .dummy_cycles = { .qpi_read_params = { 6, 4, 8, 10 } },
Nikolai Artemiev148254b2021-03-23 17:21:10 +110010128 .tested = TEST_OK_PREW,
David Tomaschikf75d8c52019-06-20 09:49:01 -070010129 .probe = probe_spi_rdid,
10130 .probe_timing = TIMING_ZERO,
10131 .block_erasers =
10132 {
10133 {
10134 .eraseblocks = { {4 * 1024, 8192} },
10135 .block_erase = spi_block_erase_21,
10136 }, {
10137 .eraseblocks = { {4 * 1024, 8192} },
10138 .block_erase = spi_block_erase_20,
10139 }, {
10140 .eraseblocks = { {32 * 1024, 1024} },
10141 .block_erase = spi_block_erase_5c,
10142 }, {
10143 .eraseblocks = { {32 * 1024, 1024} },
10144 .block_erase = spi_block_erase_52,
10145 }, {
10146 .eraseblocks = { {64 * 1024, 512} },
10147 .block_erase = spi_block_erase_dc,
10148 }, {
10149 .eraseblocks = { {64 * 1024, 512} },
10150 .block_erase = spi_block_erase_d8,
10151 }, {
10152 .eraseblocks = { {32 * 1024 * 1024, 1} },
10153 .block_erase = spi_block_erase_60,
10154 }, {
10155 .eraseblocks = { {32 * 1024 * 1024, 1} },
10156 .block_erase = spi_block_erase_c7,
10157 }
10158 },
10159 /* TODO: security register */
Nico Huber1412d9f2024-01-06 18:25:49 +010010160 .reg_bits =
10161 {
Nico Huber4fa39c52024-03-27 01:18:12 +010010162 .qe = {STATUS1, 6, RW},
Nico Huber1412d9f2024-01-06 18:25:49 +010010163 .dc = {{CONFIG, 6, RW}, {CONFIG, 7, RW}},
10164 },
Nico Huber4fa39c52024-03-27 01:18:12 +010010165 .printlock = spi_prettyprint_status_register_bp3_srwd,
David Tomaschikf75d8c52019-06-20 09:49:01 -070010166 .unlock = spi_disable_blockprotect_bp3_srwd,
10167 .write = spi_chip_write_256, /* Multi I/O supported */
Nico Huber1412d9f2024-01-06 18:25:49 +010010168 .read = spi_chip_read,
David Tomaschikf75d8c52019-06-20 09:49:01 -070010169 .voltage = {1650, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020010170 .prepare_access = spi_prepare_io,
10171 .finish_access = spi_finish_io,
David Tomaschikf75d8c52019-06-20 09:49:01 -070010172 },
10173
10174 {
10175 .vendor = "Macronix",
Alan Green1f9cc7d2019-07-01 11:10:45 +100010176 .name = "MX25U3235E/F",
10177 .bustype = BUS_SPI,
10178 .manufacture_id = MACRONIX_ID,
10179 .model_id = MACRONIX_MX25U3235E,
10180 .total_size = 4096,
10181 .page_size = 256,
Nico Huber1412d9f2024-01-06 18:25:49 +010010182 /* F model supports SFDP, FAST_READ_DOUT/_QOUT */
Alan Green1f9cc7d2019-07-01 11:10:45 +100010183 /* OTP: 512B total; enter 0xB1, exit 0xC1 */
Nico Huber1412d9f2024-01-06 18:25:49 +010010184 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_FAST_READ |
10185 FEATURE_FAST_READ_DIO | FEATURE_FAST_READ_QIO | FEATURE_QPI_35_F5,
10186 .dummy_cycles =
10187 {
10188 .qpi_fast_read = 4,
10189 .qpi_fast_read_qio = 6,
10190 },
Alan Green1f9cc7d2019-07-01 11:10:45 +100010191 .tested = TEST_OK_PREW,
10192 .probe = probe_spi_rdid,
10193 .probe_timing = TIMING_ZERO,
10194 .block_erasers =
10195 {
10196 {
10197 .eraseblocks = { {4 * 1024, 1024} },
10198 .block_erase = spi_block_erase_20,
10199 }, {
10200 .eraseblocks = { {32 * 1024, 128} },
10201 .block_erase = spi_block_erase_52,
10202 }, {
10203 .eraseblocks = { {64 * 1024, 64} },
10204 .block_erase = spi_block_erase_d8,
10205 }, {
10206 .eraseblocks = { {4 * 1024 * 1024, 1} },
10207 .block_erase = spi_block_erase_60,
10208 }, {
10209 .eraseblocks = { {4 * 1024 * 1024, 1} },
10210 .block_erase = spi_block_erase_c7,
10211 }
10212 },
10213 /* TODO: security register */
Nico Huber4fa39c52024-03-27 01:18:12 +010010214 .reg_bits =
10215 {
10216 .qe = {STATUS1, 6, RW},
10217 },
10218 .printlock = spi_prettyprint_status_register_bp3_srwd,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010219 .unlock = spi_disable_blockprotect_bp3_srwd,
10220 .write = spi_chip_write_256,
Nico Huber1412d9f2024-01-06 18:25:49 +010010221 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010222 .voltage = {1650, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020010223 .prepare_access = spi_prepare_io,
10224 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010225 },
10226
10227 {
10228 .vendor = "Macronix",
Daniel Thompsoncadd4202018-06-04 13:52:22 +010010229 .name = "MX25U51245G",
10230 .bustype = BUS_SPI,
10231 .manufacture_id = MACRONIX_ID,
10232 .model_id = MACRONIX_MX25U51245G,
10233 .total_size = 65536,
10234 .page_size = 256,
10235 /* OTP: 512B factory programmed and 512B customer programmed; enter 0xB1, exit 0xC1 */
Nico Huber1412d9f2024-01-06 18:25:49 +010010236 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP |
10237 FEATURE_4BA | FEATURE_QPI_35 | FEATURE_FAST_READ_QPI4B,
10238 .dummy_cycles = { .qpi_read_params = { 6, 4, 8, 10 } },
Daniel Thompsoncadd4202018-06-04 13:52:22 +010010239 .tested = TEST_OK_PREW,
10240 .probe = probe_spi_rdid,
10241 .probe_timing = TIMING_ZERO,
10242 .block_erasers =
10243 {
10244 {
10245 .eraseblocks = { {4 * 1024, 16384} },
10246 .block_erase = spi_block_erase_21,
10247 }, {
10248 .eraseblocks = { {4 * 1024, 16384} },
10249 .block_erase = spi_block_erase_20,
10250 }, {
10251 .eraseblocks = { {32 * 1024, 2048} },
10252 .block_erase = spi_block_erase_5c,
10253 }, {
10254 .eraseblocks = { {32 * 1024, 2048} },
10255 .block_erase = spi_block_erase_52,
10256 }, {
10257 .eraseblocks = { {64 * 1024, 1024} },
10258 .block_erase = spi_block_erase_dc,
10259 }, {
10260 .eraseblocks = { {64 * 1024, 1024} },
10261 .block_erase = spi_block_erase_d8,
10262 }, {
10263 .eraseblocks = { {64 * 1024 * 1024, 1} },
10264 .block_erase = spi_block_erase_60,
10265 }, {
10266 .eraseblocks = { {64 * 1024 * 1024, 1} },
10267 .block_erase = spi_block_erase_c7,
10268 }
10269 },
10270 /* TODO: security register */
Nico Huber1412d9f2024-01-06 18:25:49 +010010271 .reg_bits =
10272 {
Nico Huber4fa39c52024-03-27 01:18:12 +010010273 .qe = {STATUS1, 6, RW},
Nico Huber1412d9f2024-01-06 18:25:49 +010010274 .dc = {{CONFIG, 6, RW}, {CONFIG, 7, RW}},
10275 },
Nico Huber4fa39c52024-03-27 01:18:12 +010010276 .printlock = spi_prettyprint_status_register_bp3_srwd,
Daniel Thompsoncadd4202018-06-04 13:52:22 +010010277 .unlock = spi_disable_blockprotect_bp3_srwd,
10278 .write = spi_chip_write_256, /* Multi I/O supported */
Nico Huber1412d9f2024-01-06 18:25:49 +010010279 .read = spi_chip_read,
Daniel Thompsoncadd4202018-06-04 13:52:22 +010010280 .voltage = {1650, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020010281 .prepare_access = spi_prepare_io,
10282 .finish_access = spi_finish_io,
Daniel Thompsoncadd4202018-06-04 13:52:22 +010010283 },
10284
10285 {
10286 .vendor = "Macronix",
Alan Green1f9cc7d2019-07-01 11:10:45 +100010287 .name = "MX25U6435E/F",
Stefan Tauner40bc96f2015-01-10 09:33:14 +000010288 .bustype = BUS_SPI,
10289 .manufacture_id = MACRONIX_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010290 .model_id = MACRONIX_MX25U6435E,
Stefan Tauner40bc96f2015-01-10 09:33:14 +000010291 .total_size = 8192,
10292 .page_size = 256,
Nico Huber1412d9f2024-01-06 18:25:49 +010010293 /* F model supports SFDP, FAST_READ_DOUT/_QOUT */
Alan Green1f9cc7d2019-07-01 11:10:45 +100010294 /* OTP: 512B total; enter 0xB1, exit 0xC1 */
Nico Huber1412d9f2024-01-06 18:25:49 +010010295 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_FAST_READ |
10296 FEATURE_FAST_READ_DIO | FEATURE_FAST_READ_QIO | FEATURE_QPI_35_F5,
10297 .dummy_cycles =
10298 {
10299 .qpi_fast_read = 4,
10300 .qpi_fast_read_qio = 6,
10301 },
Stefan Tauner40bc96f2015-01-10 09:33:14 +000010302 .tested = TEST_OK_PREW,
10303 .probe = probe_spi_rdid,
10304 .probe_timing = TIMING_ZERO,
10305 .block_erasers =
10306 {
10307 {
10308 .eraseblocks = { {4 * 1024, 2048} },
10309 .block_erase = spi_block_erase_20,
10310 }, {
Stefan Tauner40bc96f2015-01-10 09:33:14 +000010311 .eraseblocks = { {32 * 1024, 256} },
10312 .block_erase = spi_block_erase_52,
10313 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100010314 .eraseblocks = { {64 * 1024, 128} },
10315 .block_erase = spi_block_erase_d8,
10316 }, {
Stefan Tauner40bc96f2015-01-10 09:33:14 +000010317 .eraseblocks = { {8 * 1024 * 1024, 1} },
10318 .block_erase = spi_block_erase_60,
10319 }, {
10320 .eraseblocks = { {8 * 1024 * 1024, 1} },
10321 .block_erase = spi_block_erase_c7,
10322 }
10323 },
Alan Green1f9cc7d2019-07-01 11:10:45 +100010324 /* TODO: security register */
Nico Huber4fa39c52024-03-27 01:18:12 +010010325 .reg_bits =
10326 {
10327 .qe = {STATUS1, 6, RW},
10328 },
10329 .printlock = spi_prettyprint_status_register_bp3_srwd,
Nathan Rennie-Waldock5a7f9422018-08-10 15:35:23 +010010330 .unlock = spi_disable_blockprotect_bp3_srwd,
10331 .write = spi_chip_write_256,
Nico Huber1412d9f2024-01-06 18:25:49 +010010332 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010333 .voltage = {1650, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020010334 .prepare_access = spi_prepare_io,
10335 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010336 },
10337
10338 {
10339 .vendor = "Macronix",
10340 .name = "MX25U8032E",
10341 .bustype = BUS_SPI,
10342 .manufacture_id = MACRONIX_ID,
10343 .model_id = MACRONIX_MX25U8032E,
10344 .total_size = 1024,
10345 .page_size = 256,
10346 /* OTP: 512B total; enter 0xB1, exit 0xC1 */
Nico Huber4fa39c52024-03-27 01:18:12 +010010347 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP |
10348 FEATURE_FAST_READ | FEATURE_FAST_READ_DIO | FEATURE_FAST_READ_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010349 .tested = TEST_OK_PREW,
10350 .probe = probe_spi_rdid,
10351 .probe_timing = TIMING_ZERO,
10352 .block_erasers =
10353 {
10354 {
10355 .eraseblocks = { {4 * 1024, 256} },
10356 .block_erase = spi_block_erase_20,
10357 }, {
10358 .eraseblocks = { {32 * 1024, 32} },
10359 .block_erase = spi_block_erase_52,
10360 }, {
10361 .eraseblocks = { {64 * 1024, 16} },
10362 .block_erase = spi_block_erase_d8,
10363 }, {
10364 .eraseblocks = { {1024 * 1024, 1} },
10365 .block_erase = spi_block_erase_60,
10366 }, {
10367 .eraseblocks = { {1024 * 1024, 1} },
10368 .block_erase = spi_block_erase_c7,
10369 }
10370 },
10371 /* TODO: security register */
Nico Huber4fa39c52024-03-27 01:18:12 +010010372 .reg_bits =
10373 {
10374 .qe = {STATUS1, 6, RW},
10375 },
10376 .printlock = spi_prettyprint_status_register_bp3_srwd,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010377 .unlock = spi_disable_blockprotect_bp3_srwd,
10378 .write = spi_chip_write_256,
Nico Huber4fa39c52024-03-27 01:18:12 +010010379 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010380 .voltage = {1650, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020010381 .prepare_access = spi_prepare_io,
10382 .finish_access = spi_finish_io,
Nathan Rennie-Waldock5a7f9422018-08-10 15:35:23 +010010383 },
10384
10385 {
10386 .vendor = "Macronix",
Mark Panajotovic502a9132009-08-24 01:42:24 +000010387 .name = "MX29F001B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000010388 .bustype = BUS_PARALLEL,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000010389 .manufacture_id = MACRONIX_ID,
10390 .model_id = MACRONIX_MX29F001B,
Mark Panajotovic502a9132009-08-24 01:42:24 +000010391 .total_size = 128,
10392 .page_size = 32 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000010393 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
10394 .tested = TEST_UNTESTED,
10395 .probe = probe_jedec,
David Borg204f4652010-12-04 03:26:40 +000010396 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +000010397 .block_erasers =
10398 {
10399 {
Stefan Tauner0554ca52013-07-25 22:54:25 +000010400 .eraseblocks = {
Sean Nelson54596372010-01-09 05:30:14 +000010401 {8 * 1024, 1},
10402 {4 * 1024, 2},
10403 {8 * 1024, 2},
10404 {32 * 1024, 1},
10405 {64 * 1024, 1},
10406 },
Sean Nelson35727f72010-01-28 23:55:12 +000010407 .block_erase = erase_sector_jedec,
Sean Nelson54596372010-01-09 05:30:14 +000010408 }, {
10409 .eraseblocks = { {128 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +000010410 .block_erase = erase_chip_block_jedec,
Sean Nelson54596372010-01-09 05:30:14 +000010411 }
10412 },
Michael Karcher1c296ca2009-11-27 17:49:42 +000010413 .write = write_jedec_1,
Mark Panajotovic502a9132009-08-24 01:42:24 +000010414 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000010415 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010010416 .prepare_access = prepare_memory_access,
10417 .finish_access = finish_memory_access,
Mark Panajotovic502a9132009-08-24 01:42:24 +000010418 },
10419
10420 {
10421 .vendor = "Macronix",
10422 .name = "MX29F001T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000010423 .bustype = BUS_PARALLEL,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000010424 .manufacture_id = MACRONIX_ID,
10425 .model_id = MACRONIX_MX29F001T,
Mark Panajotovic502a9132009-08-24 01:42:24 +000010426 .total_size = 128,
10427 .page_size = 32 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000010428 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
Stefan Tauner74c6ec62011-05-18 01:31:46 +000010429 .tested = TEST_OK_PREW,
Sean Nelson35727f72010-01-28 23:55:12 +000010430 .probe = probe_jedec,
David Borg204f4652010-12-04 03:26:40 +000010431 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +000010432 .block_erasers =
10433 {
10434 {
Stefan Tauner0554ca52013-07-25 22:54:25 +000010435 .eraseblocks = {
Sean Nelson54596372010-01-09 05:30:14 +000010436 {64 * 1024, 1},
10437 {32 * 1024, 1},
10438 {8 * 1024, 2},
10439 {4 * 1024, 2},
10440 {8 * 1024, 1},
10441 },
Sean Nelson35727f72010-01-28 23:55:12 +000010442 .block_erase = erase_sector_jedec,
Sean Nelson54596372010-01-09 05:30:14 +000010443 }, {
10444 .eraseblocks = { {128 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +000010445 .block_erase = erase_chip_block_jedec,
Sean Nelson54596372010-01-09 05:30:14 +000010446 }
10447 },
Michael Karcher1c296ca2009-11-27 17:49:42 +000010448 .write = write_jedec_1,
Mark Panajotovic502a9132009-08-24 01:42:24 +000010449 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000010450 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010010451 .prepare_access = prepare_memory_access,
10452 .finish_access = finish_memory_access,
Mark Panajotovic502a9132009-08-24 01:42:24 +000010453 },
10454
10455 {
10456 .vendor = "Macronix",
Sylvain "ythier" Hitier3093f8f2011-09-03 11:22:27 +000010457 .name = "MX29F002(N)B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000010458 .bustype = BUS_PARALLEL,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000010459 .manufacture_id = MACRONIX_ID,
10460 .model_id = MACRONIX_MX29F002B,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000010461 .total_size = 256,
10462 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000010463 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000010464 .tested = TEST_UNTESTED,
Sean Nelson35727f72010-01-28 23:55:12 +000010465 .probe = probe_jedec,
David Borg204f4652010-12-04 03:26:40 +000010466 .probe_timing = TIMING_ZERO,
Sean Nelson6b11ad22009-12-23 17:05:59 +000010467 .block_erasers =
10468 {
10469 {
10470 .eraseblocks = {
10471 {16 * 1024, 1},
10472 {8 * 1024, 2},
10473 {32 * 1024, 1},
10474 {64 * 1024, 3},
10475 },
Sean Nelson35727f72010-01-28 23:55:12 +000010476 .block_erase = erase_sector_jedec,
Sean Nelson6b11ad22009-12-23 17:05:59 +000010477 }, {
10478 .eraseblocks = { {256 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +000010479 .block_erase = erase_chip_block_jedec,
Sean Nelson6b11ad22009-12-23 17:05:59 +000010480 },
10481 },
Michael Karcher1c296ca2009-11-27 17:49:42 +000010482 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000010483 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000010484 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010010485 .prepare_access = prepare_memory_access,
10486 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000010487 },
10488
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000010489 {
10490 .vendor = "Macronix",
Sylvain "ythier" Hitier3093f8f2011-09-03 11:22:27 +000010491 .name = "MX29F002(N)T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000010492 .bustype = BUS_PARALLEL,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000010493 .manufacture_id = MACRONIX_ID,
10494 .model_id = MACRONIX_MX29F002T,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000010495 .total_size = 256,
10496 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000010497 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
Paul Menzel018d4822011-10-21 12:33:07 +000010498 .tested = TEST_OK_PREW,
Sean Nelson35727f72010-01-28 23:55:12 +000010499 .probe = probe_jedec,
David Borg204f4652010-12-04 03:26:40 +000010500 .probe_timing = TIMING_ZERO,
Sean Nelson6b11ad22009-12-23 17:05:59 +000010501 .block_erasers =
10502 {
10503 {
10504 .eraseblocks = {
10505 {64 * 1024, 3},
10506 {32 * 1024, 1},
10507 {8 * 1024, 2},
10508 {16 * 1024, 1},
10509 },
Sean Nelson35727f72010-01-28 23:55:12 +000010510 .block_erase = erase_sector_jedec,
Sean Nelson6b11ad22009-12-23 17:05:59 +000010511 }, {
10512 .eraseblocks = { {256 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +000010513 .block_erase = erase_chip_block_jedec,
Sean Nelson6b11ad22009-12-23 17:05:59 +000010514 },
10515 },
Michael Karcher1c296ca2009-11-27 17:49:42 +000010516 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000010517 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000010518 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010010519 .prepare_access = prepare_memory_access,
10520 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000010521 },
10522
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000010523 {
10524 .vendor = "Macronix",
Daniele Forsi6a18a932014-07-13 14:53:45 +000010525 .name = "MX29F022(N)B",
10526 .bustype = BUS_PARALLEL,
10527 .manufacture_id = MACRONIX_ID,
10528 .model_id = MACRONIX_MX29F022B,
10529 .total_size = 256,
10530 .page_size = 0, /* unused */
10531 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
10532 .tested = TEST_UNTESTED,
10533 .probe = probe_jedec,
10534 .probe_timing = TIMING_ZERO,
10535 .block_erasers =
10536 {
10537 {
10538 .eraseblocks = {
10539 {16 * 1024, 1},
10540 {8 * 1024, 2},
10541 {32 * 1024, 1},
10542 {64 * 1024, 3},
10543 },
10544 .block_erase = erase_sector_jedec,
10545 }, {
10546 .eraseblocks = { {256 * 1024, 1} },
10547 .block_erase = erase_chip_block_jedec,
10548 }
10549 },
10550 .write = write_jedec_1,
10551 .read = read_memmapped,
10552 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010010553 .prepare_access = prepare_memory_access,
10554 .finish_access = finish_memory_access,
Daniele Forsi6a18a932014-07-13 14:53:45 +000010555 },
10556
10557 {
10558 .vendor = "Macronix",
10559 .name = "MX29F022(N)T",
10560 .bustype = BUS_PARALLEL,
10561 .manufacture_id = MACRONIX_ID,
10562 .model_id = MACRONIX_MX29F022T,
10563 .total_size = 256,
10564 .page_size = 0, /* unused */
10565 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
10566 .tested = TEST_OK_PREW,
10567 .probe = probe_jedec,
10568 .probe_timing = TIMING_ZERO,
10569 .block_erasers =
10570 {
10571 {
10572 .eraseblocks = {
10573 {64 * 1024, 3},
10574 {32 * 1024, 1},
10575 {8 * 1024, 2},
10576 {16 * 1024, 1},
10577 },
10578 .block_erase = erase_sector_jedec,
10579 }, {
10580 .eraseblocks = { {256 * 1024, 1} },
10581 .block_erase = erase_chip_block_jedec,
10582 }
10583 },
10584 .write = write_jedec_1,
10585 .read = read_memmapped,
10586 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010010587 .prepare_access = prepare_memory_access,
10588 .finish_access = finish_memory_access,
Daniele Forsi6a18a932014-07-13 14:53:45 +000010589 },
10590
10591 {
10592 .vendor = "Macronix",
Joshua Roysf1324e02010-09-16 00:51:51 +000010593 .name = "MX29F040",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000010594 .bustype = BUS_PARALLEL,
Joshua Roysf1324e02010-09-16 00:51:51 +000010595 .manufacture_id = MACRONIX_ID,
10596 .model_id = MACRONIX_MX29F040,
10597 .total_size = 512,
10598 .page_size = 64 * 1024,
10599 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
10600 .tested = TEST_UNTESTED,
10601 .probe = probe_jedec,
10602 .probe_timing = TIMING_ZERO,
10603 .block_erasers =
10604 {
10605 {
10606 .eraseblocks = { {64 * 1024, 8} },
10607 .block_erase = erase_sector_jedec,
10608 }, {
10609 .eraseblocks = { {512 * 1024, 1} },
10610 .block_erase = erase_chip_block_jedec,
10611 },
10612 },
10613 .write = write_jedec_1,
10614 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +000010615 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010010616 .prepare_access = prepare_memory_access,
10617 .finish_access = finish_memory_access,
Joshua Roysf1324e02010-09-16 00:51:51 +000010618 },
10619
10620 {
10621 .vendor = "Macronix",
Alan Green1f9cc7d2019-07-01 11:10:45 +100010622 .name = "MX29GL128F",
10623 .bustype = BUS_PARALLEL,
10624 .manufacture_id = MACRONIX_ID,
10625 .model_id = MACRONIX_MX29GL128F,
10626 .total_size = 16384,
10627 .page_size = 128 * 1024, /* actual page size is 16 */
10628 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
10629 .tested = TEST_UNTESTED,
10630 .probe = probe_jedec_29gl,
10631 .probe_timing = TIMING_ZERO,
10632 .block_erasers =
10633 {
10634 {
10635 .eraseblocks = { {128 * 1024, 128} },
10636 .block_erase = erase_sector_jedec,
10637 }, {
10638 .eraseblocks = { {16 * 1024 * 1024, 1} },
10639 .block_erase = erase_chip_block_jedec,
10640 },
10641 },
10642 .write = write_jedec_1,
10643 .read = read_memmapped,
10644 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010010645 .prepare_access = prepare_memory_access,
10646 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010647 },
10648
10649 {
10650 .vendor = "Macronix",
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000010651 .name = "MX29GL320EB",
10652 .bustype = BUS_PARALLEL,
10653 .manufacture_id = MACRONIX_ID,
10654 .model_id = MACRONIX_MX29GL320EB,
10655 .total_size = 4096,
10656 .page_size = 128 * 1024, /* actual page size is 16 */
10657 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
10658 .tested = TEST_UNTESTED,
10659 .probe = probe_jedec_29gl,
10660 .probe_timing = TIMING_ZERO,
10661 .block_erasers =
10662 {
10663 {
10664 .eraseblocks = {
10665 {8 * 1024, 8},
10666 {64 * 1024, 63},
10667 },
10668 .block_erase = erase_sector_jedec,
10669 }, {
10670 .eraseblocks = { {4 * 1024 * 1024, 1} },
10671 .block_erase = erase_chip_block_jedec,
10672 },
10673 },
10674 .write = write_jedec_1,
10675 .read = read_memmapped,
10676 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010010677 .prepare_access = prepare_memory_access,
10678 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000010679 },
10680
10681 {
10682 .vendor = "Macronix",
Alan Green1f9cc7d2019-07-01 11:10:45 +100010683 .name = "MX29GL320EH/L",
10684 .bustype = BUS_PARALLEL,
10685 .manufacture_id = MACRONIX_ID,
10686 .model_id = MACRONIX_MX29GL320EHL,
10687 .total_size = 4096,
10688 .page_size = 128 * 1024, /* actual page size is 16 */
10689 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
10690 .tested = TEST_UNTESTED,
10691 .probe = probe_jedec_29gl,
10692 .probe_timing = TIMING_ZERO,
10693 .block_erasers =
10694 {
10695 {
10696 .eraseblocks = { {64 * 1024, 64} },
10697 .block_erase = erase_sector_jedec,
10698 }, {
10699 .eraseblocks = { {4 * 1024 * 1024, 1} },
10700 .block_erase = erase_chip_block_jedec,
10701 },
10702 },
10703 .write = write_jedec_1,
10704 .read = read_memmapped,
10705 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010010706 .prepare_access = prepare_memory_access,
10707 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010708 },
10709
10710 {
10711 .vendor = "Macronix",
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000010712 .name = "MX29GL320ET",
10713 .bustype = BUS_PARALLEL,
10714 .manufacture_id = MACRONIX_ID,
10715 .model_id = MACRONIX_MX29GL320ET,
10716 .total_size = 4096,
10717 .page_size = 128 * 1024, /* actual page size is 16 */
10718 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
10719 .tested = TEST_UNTESTED,
10720 .probe = probe_jedec_29gl,
10721 .probe_timing = TIMING_ZERO,
10722 .block_erasers =
10723 {
10724 {
10725 .eraseblocks = {
10726 {64 * 1024, 63},
10727 {8 * 1024, 8},
10728 },
10729 .block_erase = erase_sector_jedec,
10730 }, {
10731 .eraseblocks = { {4 * 1024 * 1024, 1} },
10732 .block_erase = erase_chip_block_jedec,
10733 },
10734 },
10735 .write = write_jedec_1,
10736 .read = read_memmapped,
10737 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010010738 .prepare_access = prepare_memory_access,
10739 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000010740 },
10741
10742 {
10743 .vendor = "Macronix",
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000010744 .name = "MX29GL640EB",
10745 .bustype = BUS_PARALLEL,
10746 .manufacture_id = MACRONIX_ID,
10747 .model_id = MACRONIX_MX29GL640EB,
10748 .total_size = 8192,
10749 .page_size = 128 * 1024, /* actual page size is 16 */
10750 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
10751 .tested = TEST_UNTESTED,
10752 .probe = probe_jedec_29gl,
10753 .probe_timing = TIMING_ZERO,
10754 .block_erasers =
10755 {
10756 {
10757 .eraseblocks = {
10758 {8 * 1024, 8},
10759 {64 * 1024, 127},
10760 },
10761 .block_erase = erase_sector_jedec,
10762 }, {
10763 .eraseblocks = { {8 * 1024 * 1024, 1} },
10764 .block_erase = erase_chip_block_jedec,
10765 },
10766 },
10767 .write = write_jedec_1,
10768 .read = read_memmapped,
10769 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010010770 .prepare_access = prepare_memory_access,
10771 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000010772 },
10773
10774 {
10775 .vendor = "Macronix",
Alan Green1f9cc7d2019-07-01 11:10:45 +100010776 .name = "MX29GL640EH/L",
10777 .bustype = BUS_PARALLEL,
10778 .manufacture_id = MACRONIX_ID,
10779 .model_id = MACRONIX_MX29GL640EHL,
10780 .total_size = 8192,
10781 .page_size = 128 * 1024, /* actual page size is 16 */
10782 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
10783 .tested = TEST_UNTESTED,
10784 .probe = probe_jedec_29gl,
10785 .probe_timing = TIMING_ZERO,
10786 .block_erasers =
10787 {
10788 {
10789 .eraseblocks = { {64 * 1024, 128} },
10790 .block_erase = erase_sector_jedec,
10791 }, {
10792 .eraseblocks = { {8 * 1024 * 1024, 1} },
10793 .block_erase = erase_chip_block_jedec,
10794 },
10795 },
10796 .write = write_jedec_1,
10797 .read = read_memmapped,
10798 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010010799 .prepare_access = prepare_memory_access,
10800 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010801 },
10802
10803 {
10804 .vendor = "Macronix",
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000010805 .name = "MX29GL640ET",
10806 .bustype = BUS_PARALLEL,
10807 .manufacture_id = MACRONIX_ID,
10808 .model_id = MACRONIX_MX29GL640ET,
10809 .total_size = 8192,
10810 .page_size = 128 * 1024, /* actual page size is 16 */
10811 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
10812 .tested = TEST_UNTESTED,
10813 .probe = probe_jedec_29gl,
10814 .probe_timing = TIMING_ZERO,
10815 .block_erasers =
10816 {
10817 {
10818 .eraseblocks = {
10819 {64 * 1024, 127},
10820 {8 * 1024, 8},
10821 },
10822 .block_erase = erase_sector_jedec,
10823 }, {
10824 .eraseblocks = { {8 * 1024 * 1024, 1} },
10825 .block_erase = erase_chip_block_jedec,
10826 },
10827 },
10828 .write = write_jedec_1,
10829 .read = read_memmapped,
10830 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010010831 .prepare_access = prepare_memory_access,
10832 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000010833 },
10834
10835 {
10836 .vendor = "Macronix",
Carl-Daniel Hailfinger350a0c32009-07-24 13:59:27 +000010837 .name = "MX29LV040",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000010838 .bustype = BUS_PARALLEL,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000010839 .manufacture_id = MACRONIX_ID,
10840 .model_id = MACRONIX_MX29LV040,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000010841 .total_size = 512,
10842 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000010843 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
10844 .tested = TEST_UNTESTED,
10845 .probe = probe_jedec,
David Borg204f4652010-12-04 03:26:40 +000010846 .probe_timing = TIMING_ZERO,
Sean Nelson54596372010-01-09 05:30:14 +000010847 .block_erasers =
10848 {
10849 {
Stefan Tauner6697f712014-08-06 15:09:15 +000010850 .eraseblocks = { {64 * 1024, 8} },
Sean Nelson35727f72010-01-28 23:55:12 +000010851 .block_erase = erase_sector_jedec,
Sean Nelson54596372010-01-09 05:30:14 +000010852 }, {
10853 .eraseblocks = { {512 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +000010854 .block_erase = erase_chip_block_jedec,
Sean Nelson54596372010-01-09 05:30:14 +000010855 },
10856 },
Michael Karcher1c296ca2009-11-27 17:49:42 +000010857 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000010858 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000010859 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010010860 .prepare_access = prepare_memory_access,
10861 .finish_access = finish_memory_access,
Carl-Daniel Hailfinger7de86392008-12-10 10:32:05 +000010862 },
10863
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000010864 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100010865 .vendor = "Macronix",
Hemanth Guruva Reddya136d422019-07-11 11:08:27 +020010866 .name = "MX66L51235F/MX25L51245G",
Stefan Tauner1aa80b02013-07-25 22:58:51 +000010867 .bustype = BUS_SPI,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010868 .manufacture_id = MACRONIX_ID,
10869 .model_id = MACRONIX_MX66L51235F,
10870 .total_size = 65536,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000010871 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010872 /* OTP: 512B total; enter 0xB1, exit 0xC1 */
10873 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000010874 .tested = TEST_OK_PREW,
10875 .probe = probe_spi_rdid,
10876 .probe_timing = TIMING_ZERO,
10877 .block_erasers =
10878 {
10879 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100010880 .eraseblocks = { {4 * 1024, 16384} },
10881 .block_erase = spi_block_erase_21,
10882 }, {
10883 .eraseblocks = { {4 * 1024, 16384} },
10884 .block_erase = spi_block_erase_20,
10885 }, {
10886 .eraseblocks = { {32 * 1024, 2048} },
10887 .block_erase = spi_block_erase_5c,
10888 }, {
10889 .eraseblocks = { {32 * 1024, 2048} },
10890 .block_erase = spi_block_erase_52,
10891 }, {
10892 .eraseblocks = { {64 * 1024, 1024} },
10893 .block_erase = spi_block_erase_dc,
10894 }, {
10895 .eraseblocks = { {64 * 1024, 1024} },
Stefan Tauner1aa80b02013-07-25 22:58:51 +000010896 .block_erase = spi_block_erase_d8,
10897 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100010898 .eraseblocks = { {64 * 1024 * 1024, 1} },
10899 .block_erase = spi_block_erase_60,
10900 }, {
10901 .eraseblocks = { {64 * 1024 * 1024, 1} },
Stefan Tauner1aa80b02013-07-25 22:58:51 +000010902 .block_erase = spi_block_erase_c7,
10903 }
10904 },
Alan Green1f9cc7d2019-07-01 11:10:45 +100010905 /* TODO: security register and SBLK/SBULK; MX25L12835F: configuration register */
10906 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enable */
Stefan Tauner5c316f92015-02-08 21:57:52 +000010907 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000010908 .write = spi_chip_write_256,
Alan Green1f9cc7d2019-07-01 11:10:45 +100010909 .read = spi_chip_read, /* Fast read (0x0B) supported */
Stefan Tauner1aa80b02013-07-25 22:58:51 +000010910 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020010911 .prepare_access = spi_prepare_io,
10912 .finish_access = spi_finish_io,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000010913 },
10914
Patrick Rudolph3ba83152021-06-08 10:52:19 +020010915 {
10916 .vendor = "Macronix",
10917 .name = "MX66L1G45G",
10918 .bustype = BUS_SPI,
10919 .manufacture_id = MACRONIX_ID,
10920 .model_id = MACRONIX_MX66L1G45G,
10921 .total_size = 131072,
10922 .page_size = 256,
10923 /* OTP: 512B total; enter 0xB1, exit 0xC1 */
10924 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA,
10925 .tested = TEST_OK_PREW,
10926 .probe = probe_spi_rdid,
10927 .probe_timing = TIMING_ZERO,
10928 .block_erasers =
10929 {
10930 {
10931 .eraseblocks = { {4 * 1024, 32768} },
10932 .block_erase = spi_block_erase_21,
10933 }, {
10934 .eraseblocks = { {4 * 1024, 32768} },
10935 .block_erase = spi_block_erase_20,
10936 }, {
10937 .eraseblocks = { {32 * 1024, 4096} },
10938 .block_erase = spi_block_erase_5c,
10939 }, {
10940 .eraseblocks = { {32 * 1024, 4096} },
10941 .block_erase = spi_block_erase_52,
10942 }, {
10943 .eraseblocks = { {64 * 1024, 2048} },
10944 .block_erase = spi_block_erase_dc,
10945 }, {
10946 .eraseblocks = { {64 * 1024, 2048} },
10947 .block_erase = spi_block_erase_d8,
10948 }, {
10949 .eraseblocks = { {128 * 1024 * 1024, 1} },
10950 .block_erase = spi_block_erase_60,
10951 }, {
10952 .eraseblocks = { {128 * 1024 * 1024, 1} },
10953 .block_erase = spi_block_erase_c7,
10954 }
10955 },
10956 /* TODO: security register and SBLK/SBULK, configuration register */
10957 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enable */
10958 .unlock = spi_disable_blockprotect_bp3_srwd,
10959 .write = spi_chip_write_256,
10960 .read = spi_chip_read, /* Fast read (0x0B) supported */
10961 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020010962 .prepare_access = spi_prepare_io,
10963 .finish_access = spi_finish_io,
Patrick Rudolph3ba83152021-06-08 10:52:19 +020010964 },
10965
Stefan Tauner1aa80b02013-07-25 22:58:51 +000010966 /* The ST M25P05 is a bit of a problem. It has the same ID as the
10967 * ST M25P05-A in RES mode, but supports only 128 byte writes instead
10968 * of 256 byte writes. We rely heavily on the fact that probe_spi_res1
10969 * only is successful if RDID does not work.
10970 */
10971 {
10972 .vendor = "Micron/Numonyx/ST",
10973 .name = "M25P05",
10974 .bustype = BUS_SPI,
10975 .manufacture_id = 0, /* Not used. */
10976 .model_id = ST_M25P05_RES,
10977 .total_size = 64,
10978 .page_size = 256,
10979 .feature_bits = FEATURE_WRSR_WREN,
10980 .tested = TEST_UNTESTED,
10981 .probe = probe_spi_res1,
10982 .probe_timing = TIMING_ZERO,
10983 .block_erasers =
10984 {
10985 {
10986 .eraseblocks = { {32 * 1024, 2} },
10987 .block_erase = spi_block_erase_d8,
10988 }, {
10989 .eraseblocks = { {64 * 1024, 1} },
10990 .block_erase = spi_block_erase_c7,
10991 }
10992 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000010993 .printlock = spi_prettyprint_status_register_bp3_srwd, /* TODO: check */
Stefan Tauner5c316f92015-02-08 21:57:52 +000010994 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000010995 .write = spi_chip_write_1, /* 128 */
10996 .read = spi_chip_read,
10997 .voltage = {2700, 3600},
10998 },
10999
11000 {
11001 .vendor = "Micron/Numonyx/ST",
Alan Green1f9cc7d2019-07-01 11:10:45 +100011002 .name = "M25P05-A",
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011003 .bustype = BUS_SPI,
11004 .manufacture_id = ST_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +100011005 .model_id = ST_M25P05A,
11006 .total_size = 64,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011007 .page_size = 256,
11008 .feature_bits = FEATURE_WRSR_WREN,
Stefan Tauner23e10b82016-01-23 16:16:49 +000011009 .tested = TEST_OK_PREW,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011010 .probe = probe_spi_rdid,
11011 .probe_timing = TIMING_ZERO,
11012 .block_erasers =
11013 {
11014 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100011015 .eraseblocks = { {32 * 1024, 2} },
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011016 .block_erase = spi_block_erase_d8,
11017 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100011018 .eraseblocks = { {64 * 1024, 1} },
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011019 .block_erase = spi_block_erase_c7,
11020 }
11021 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000011022 .printlock = spi_prettyprint_status_register_bp3_srwd, /* TODO: check */
Stefan Tauner5c316f92015-02-08 21:57:52 +000011023 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011024 .write = spi_chip_write_256,
11025 .read = spi_chip_read,
11026 .voltage = {2700, 3600},
11027 },
11028
11029 /* The ST M25P10 has the same problem as the M25P05. */
11030 {
11031 .vendor = "Micron/Numonyx/ST",
11032 .name = "M25P10",
11033 .bustype = BUS_SPI,
11034 .manufacture_id = 0, /* Not used. */
11035 .model_id = ST_M25P10_RES,
11036 .total_size = 128,
11037 .page_size = 256,
11038 .feature_bits = FEATURE_WRSR_WREN,
11039 .tested = TEST_UNTESTED,
11040 .probe = probe_spi_res1,
11041 .probe_timing = TIMING_ZERO,
11042 .block_erasers =
11043 {
11044 {
11045 .eraseblocks = { {32 * 1024, 4} },
11046 .block_erase = spi_block_erase_d8,
11047 }, {
11048 .eraseblocks = { {128 * 1024, 1} },
11049 .block_erase = spi_block_erase_c7,
11050 }
11051 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000011052 .printlock = spi_prettyprint_status_register_bp3_srwd, /* TODO: check */
Stefan Tauner5c316f92015-02-08 21:57:52 +000011053 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011054 .write = spi_chip_write_1, /* 128 */
11055 .read = spi_chip_read,
11056 .voltage = {2700, 3600},
11057 },
11058
11059 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100011060 .vendor = "Micron/Numonyx/ST",
11061 .name = "M25P10-A",
11062 .bustype = BUS_SPI,
11063 .manufacture_id = ST_ID,
11064 .model_id = ST_M25P10A,
11065 .total_size = 128,
11066 .page_size = 256,
11067 .feature_bits = FEATURE_WRSR_WREN,
11068 .tested = TEST_OK_PREW,
11069 .probe = probe_spi_rdid,
11070 .probe_timing = TIMING_ZERO,
11071 .block_erasers =
11072 {
11073 {
11074 .eraseblocks = { {32 * 1024, 4} },
11075 .block_erase = spi_block_erase_d8,
11076 }, {
11077 .eraseblocks = { {128 * 1024, 1} },
11078 .block_erase = spi_block_erase_c7,
11079 }
11080 },
11081 .printlock = spi_prettyprint_status_register_bp3_srwd, /* TODO: check */
11082 .unlock = spi_disable_blockprotect_bp3_srwd,
11083 .write = spi_chip_write_256,
11084 .read = spi_chip_read,
11085 .voltage = {2700, 3600},
11086 },
11087
11088 {
11089 .vendor = "Micron/Numonyx/ST",
11090 .name = "M25P128",
11091 .bustype = BUS_SPI,
11092 .manufacture_id = ST_ID,
11093 .model_id = ST_M25P128,
11094 .total_size = 16384,
11095 .page_size = 256,
11096 .feature_bits = FEATURE_WRSR_WREN,
11097 .tested = TEST_OK_PREW,
11098 .probe = probe_spi_rdid,
11099 .probe_timing = TIMING_ZERO,
11100 .block_erasers =
11101 {
11102 {
11103 .eraseblocks = { {256 * 1024, 64} },
11104 .block_erase = spi_block_erase_d8,
11105 }, {
11106 .eraseblocks = { {16 * 1024 * 1024, 1} },
11107 .block_erase = spi_block_erase_c7,
11108 }
11109 },
11110 .printlock = spi_prettyprint_status_register_bp3_srwd, /* TODO: check */
11111 .unlock = spi_disable_blockprotect_bp3_srwd,
11112 .write = spi_chip_write_256,
11113 .read = spi_chip_read,
11114 .voltage = {2700, 3600},
11115 },
11116
11117 {
11118 .vendor = "Micron/Numonyx/ST",
11119 .name = "M25P16",
11120 .bustype = BUS_SPI,
11121 .manufacture_id = ST_ID,
11122 .model_id = ST_M25P16,
11123 .total_size = 2048,
11124 .page_size = 256,
11125 .feature_bits = FEATURE_WRSR_WREN,
11126 .tested = TEST_OK_PREW,
11127 .probe = probe_spi_rdid,
11128 .probe_timing = TIMING_ZERO,
11129 .block_erasers =
11130 {
11131 {
11132 .eraseblocks = { {64 * 1024, 32} },
11133 .block_erase = spi_block_erase_d8,
11134 }, {
11135 .eraseblocks = { {2 * 1024 * 1024, 1} },
11136 .block_erase = spi_block_erase_c7,
11137 }
11138 },
11139 .printlock = spi_prettyprint_status_register_bp3_srwd, /* TODO: check */
11140 .unlock = spi_disable_blockprotect_bp3_srwd,
11141 .write = spi_chip_write_256,
11142 .read = spi_chip_read,
11143 .voltage = {2700, 3600},
11144 },
11145
11146 {
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011147 .vendor = "Micron/Numonyx/ST", /* Numonyx */
11148 .name = "M25P20",
11149 .bustype = BUS_SPI,
11150 .manufacture_id = ST_ID,
11151 .model_id = ST_M25P20,
11152 .total_size = 256,
11153 .page_size = 256,
11154 .feature_bits = FEATURE_WRSR_WREN,
11155 .tested = TEST_UNTESTED,
11156 .probe = probe_spi_rdid,
11157 .probe_timing = TIMING_ZERO,
11158 .block_erasers =
11159 {
11160 {
11161 .eraseblocks = { {64 * 1024, 4} },
11162 .block_erase = spi_block_erase_d8,
11163 }, {
11164 .eraseblocks = { {256 * 1024, 1} },
11165 .block_erase = spi_block_erase_c7,
11166 }
11167 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000011168 .printlock = spi_prettyprint_status_register_bp1_srwd,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011169 .unlock = spi_disable_blockprotect,
11170 .write = spi_chip_write_256,
11171 .read = spi_chip_read, /* Fast read (0x0B) supported */
11172 .voltage = {2700, 3600},
11173 },
11174
11175 {
11176 .vendor = "Micron/Numonyx/ST",
11177 .name = "M25P20-old",
11178 .bustype = BUS_SPI,
11179 .manufacture_id = 0, /* Not used. */
11180 .model_id = ST_M25P20_RES,
11181 .total_size = 256,
11182 .page_size = 256,
11183 .feature_bits = FEATURE_WRSR_WREN,
11184 .tested = TEST_OK_PREW,
11185 .probe = probe_spi_res1,
11186 .probe_timing = TIMING_ZERO,
11187 .block_erasers =
11188 {
11189 {
11190 .eraseblocks = { {64 * 1024, 4} },
11191 .block_erase = spi_block_erase_d8,
11192 }, {
11193 .eraseblocks = { {256 * 1024, 1} },
11194 .block_erase = spi_block_erase_c7,
11195 }
11196 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000011197 .printlock = spi_prettyprint_status_register_bp1_srwd,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011198 .unlock = spi_disable_blockprotect,
11199 .write = spi_chip_write_256,
11200 .read = spi_chip_read, /* Fast read (0x0B) supported */
11201 .voltage = {2700, 3600},
11202 },
11203
11204 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100011205 .vendor = "Micron/Numonyx/ST",
11206 .name = "M25P32",
11207 .bustype = BUS_SPI,
11208 .manufacture_id = ST_ID,
11209 .model_id = ST_M25P32,
11210 .total_size = 4096,
11211 .page_size = 256,
11212 .feature_bits = FEATURE_WRSR_WREN,
11213 .tested = TEST_OK_PREW,
11214 .probe = probe_spi_rdid,
11215 .probe_timing = TIMING_ZERO,
11216 .block_erasers =
11217 {
11218 {
11219 .eraseblocks = { {64 * 1024, 64} },
11220 .block_erase = spi_block_erase_d8,
11221 }, {
11222 .eraseblocks = { {4 * 1024 * 1024, 1} },
11223 .block_erase = spi_block_erase_c7,
11224 }
11225 },
11226 .printlock = spi_prettyprint_status_register_bp3_srwd, /* TODO: check */
11227 .unlock = spi_disable_blockprotect_bp3_srwd,
11228 .write = spi_chip_write_256,
11229 .read = spi_chip_read,
11230 .voltage = {2700, 3600},
11231 },
11232
11233 {
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011234 .vendor = "Micron/Numonyx/ST", /* Numonyx */
11235 .name = "M25P40",
11236 .bustype = BUS_SPI,
11237 .manufacture_id = ST_ID,
11238 .model_id = ST_M25P40,
11239 .total_size = 512,
11240 .page_size = 256,
11241 .feature_bits = FEATURE_WRSR_WREN,
11242 .tested = TEST_OK_PREW,
11243 .probe = probe_spi_rdid,
11244 .probe_timing = TIMING_ZERO,
11245 .block_erasers =
11246 {
11247 {
11248 .eraseblocks = { {64 * 1024, 8} },
11249 .block_erase = spi_block_erase_d8,
11250 }, {
11251 .eraseblocks = { {512 * 1024, 1} },
11252 .block_erase = spi_block_erase_c7,
11253 }
11254 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000011255 .printlock = spi_prettyprint_status_register_bp3_srwd, /* TODO: check */
Stefan Tauner5c316f92015-02-08 21:57:52 +000011256 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011257 .write = spi_chip_write_256,
11258 .read = spi_chip_read,
11259 .voltage = {2700, 3600},
11260 },
11261
11262 {
11263 .vendor = "Micron/Numonyx/ST",
11264 .name = "M25P40-old",
11265 .bustype = BUS_SPI,
11266 .manufacture_id = 0, /* Not used. */
11267 .model_id = ST_M25P40_RES,
11268 .total_size = 512,
11269 .page_size = 256,
11270 .feature_bits = FEATURE_WRSR_WREN,
11271 .tested = TEST_UNTESTED,
11272 .probe = probe_spi_res1,
11273 .probe_timing = TIMING_ZERO,
11274 .block_erasers =
11275 {
11276 {
11277 .eraseblocks = { {64 * 1024, 8} },
11278 .block_erase = spi_block_erase_d8,
11279 }, {
11280 .eraseblocks = { {512 * 1024, 1} },
11281 .block_erase = spi_block_erase_c7,
11282 }
11283 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000011284 .printlock = spi_prettyprint_status_register_bp3_srwd, /* TODO: check */
Stefan Tauner5c316f92015-02-08 21:57:52 +000011285 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011286 .write = spi_chip_write_256,
11287 .read = spi_chip_read,
11288 },
11289
11290 {
11291 .vendor = "Micron/Numonyx/ST",
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011292 .name = "M25P64",
11293 .bustype = BUS_SPI,
11294 .manufacture_id = ST_ID,
11295 .model_id = ST_M25P64,
11296 .total_size = 8192,
11297 .page_size = 256,
11298 .feature_bits = FEATURE_WRSR_WREN,
11299 .tested = TEST_OK_PREW,
11300 .probe = probe_spi_rdid,
11301 .probe_timing = TIMING_ZERO,
11302 .block_erasers =
11303 {
11304 {
11305 .eraseblocks = { {64 * 1024, 128} },
11306 .block_erase = spi_block_erase_d8,
11307 }, {
11308 .eraseblocks = { {8 * 1024 * 1024, 1} },
11309 .block_erase = spi_block_erase_c7,
11310 }
11311 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000011312 .printlock = spi_prettyprint_status_register_bp3_srwd, /* TODO: check */
Stefan Tauner5c316f92015-02-08 21:57:52 +000011313 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011314 .write = spi_chip_write_256,
11315 .read = spi_chip_read,
11316 .voltage = {2700, 3600},
11317 },
11318
11319 {
11320 .vendor = "Micron/Numonyx/ST",
Alan Green1f9cc7d2019-07-01 11:10:45 +100011321 .name = "M25P80",
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011322 .bustype = BUS_SPI,
11323 .manufacture_id = ST_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +100011324 .model_id = ST_M25P80,
11325 .total_size = 1024,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011326 .page_size = 256,
11327 .feature_bits = FEATURE_WRSR_WREN,
11328 .tested = TEST_OK_PREW,
11329 .probe = probe_spi_rdid,
11330 .probe_timing = TIMING_ZERO,
11331 .block_erasers =
11332 {
11333 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100011334 .eraseblocks = { {64 * 1024, 16} },
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011335 .block_erase = spi_block_erase_d8,
11336 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100011337 .eraseblocks = { {1024 * 1024, 1} },
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011338 .block_erase = spi_block_erase_c7,
11339 }
11340 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000011341 .printlock = spi_prettyprint_status_register_bp3_srwd, /* TODO: check */
Stefan Tauner5c316f92015-02-08 21:57:52 +000011342 .unlock = spi_disable_blockprotect_bp3_srwd,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011343 .write = spi_chip_write_256,
11344 .read = spi_chip_read,
11345 .voltage = {2700, 3600},
11346 },
11347
11348 {
11349 .vendor = "Micron/Numonyx/ST",
11350 .name = "M25PE10",
11351 .bustype = BUS_SPI,
11352 .manufacture_id = ST_ID,
11353 .model_id = ST_M25PE10,
11354 .total_size = 128,
11355 .page_size = 256,
11356 .feature_bits = FEATURE_WRSR_WREN,
11357 .tested = TEST_UNTESTED,
11358 .probe = probe_spi_rdid,
11359 .probe_timing = TIMING_ZERO,
11360 .block_erasers =
11361 {
11362 {
11363 .eraseblocks = { {4 * 1024, 32} },
11364 .block_erase = spi_block_erase_20,
11365 }, {
11366 .eraseblocks = { {64 * 1024, 2} },
11367 .block_erase = spi_block_erase_d8,
11368 }, {
11369 .eraseblocks = { {128 * 1024, 1} },
11370 .block_erase = spi_block_erase_c7,
11371 }
11372 },
11373 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
11374 .unlock = spi_disable_blockprotect,
11375 .write = spi_chip_write_256,
11376 .read = spi_chip_read,
11377 .voltage = {2700, 3600},
11378 },
11379
11380 {
11381 .vendor = "Micron/Numonyx/ST",
Alan Green1f9cc7d2019-07-01 11:10:45 +100011382 .name = "M25PE16",
11383 .bustype = BUS_SPI,
11384 .manufacture_id = ST_ID,
11385 .model_id = ST_M25PE16,
11386 .total_size = 2048,
11387 .page_size = 256,
11388 .feature_bits = FEATURE_WRSR_WREN,
11389 .tested = TEST_UNTESTED,
11390 .probe = probe_spi_rdid,
11391 .probe_timing = TIMING_ZERO,
11392 .block_erasers =
11393 {
11394 {
11395 .eraseblocks = { {4 * 1024, 512} },
11396 .block_erase = spi_block_erase_20,
11397 }, {
11398 .eraseblocks = { {64 * 1024, 32} },
11399 .block_erase = spi_block_erase_d8,
11400 }, {
11401 .eraseblocks = { {2 * 1024 * 1024, 1} },
11402 .block_erase = spi_block_erase_c7,
11403 }
11404 },
11405 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
11406 .unlock = spi_disable_blockprotect,
11407 .write = spi_chip_write_256,
11408 .read = spi_chip_read,
11409 .voltage = {2700, 3600},
11410 },
11411
11412 {
11413 .vendor = "Micron/Numonyx/ST",
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011414 .name = "M25PE20",
11415 .bustype = BUS_SPI,
11416 .manufacture_id = ST_ID,
11417 .model_id = ST_M25PE20,
11418 .total_size = 256,
11419 .page_size = 256,
11420 .feature_bits = FEATURE_WRSR_WREN,
11421 .tested = TEST_UNTESTED,
11422 .probe = probe_spi_rdid,
11423 .probe_timing = TIMING_ZERO,
11424 .block_erasers =
11425 {
11426 {
11427 .eraseblocks = { {4 * 1024, 64} },
11428 .block_erase = spi_block_erase_20,
11429 }, {
11430 .eraseblocks = { {64 * 1024, 4} },
11431 .block_erase = spi_block_erase_d8,
11432 }, {
11433 .eraseblocks = { {256 * 1024, 1} },
11434 .block_erase = spi_block_erase_c7,
11435 }
11436 },
11437 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
11438 .unlock = spi_disable_blockprotect,
11439 .write = spi_chip_write_256,
11440 .read = spi_chip_read,
11441 .voltage = {2700, 3600},
11442 },
11443
11444 {
11445 .vendor = "Micron/Numonyx/ST",
11446 .name = "M25PE40",
11447 .bustype = BUS_SPI,
11448 .manufacture_id = ST_ID,
11449 .model_id = ST_M25PE40,
11450 .total_size = 512,
11451 .page_size = 256,
11452 .feature_bits = FEATURE_WRSR_WREN,
Stefan Tauner23e10b82016-01-23 16:16:49 +000011453 .tested = TEST_OK_PREW,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011454 .probe = probe_spi_rdid,
11455 .probe_timing = TIMING_ZERO,
11456 .block_erasers =
11457 {
11458 {
11459 .eraseblocks = { {4 * 1024, 128} },
11460 .block_erase = spi_block_erase_20,
11461 }, {
11462 .eraseblocks = { {64 * 1024, 8} },
11463 .block_erase = spi_block_erase_d8,
11464 }, {
11465 .eraseblocks = { {512 * 1024, 1} },
11466 .block_erase = spi_block_erase_c7,
11467 }
11468 },
11469 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
11470 .unlock = spi_disable_blockprotect,
11471 .write = spi_chip_write_256,
11472 .read = spi_chip_read,
11473 .voltage = {2700, 3600},
11474 },
11475
11476 {
11477 .vendor = "Micron/Numonyx/ST",
11478 .name = "M25PE80",
11479 .bustype = BUS_SPI,
11480 .manufacture_id = ST_ID,
11481 .model_id = ST_M25PE80,
11482 .total_size = 1024,
11483 .page_size = 256,
11484 .feature_bits = FEATURE_WRSR_WREN,
11485 .tested = TEST_OK_PREW,
11486 .probe = probe_spi_rdid,
11487 .probe_timing = TIMING_ZERO,
11488 .block_erasers =
11489 {
11490 {
11491 .eraseblocks = { {4 * 1024, 256} },
11492 .block_erase = spi_block_erase_20,
11493 }, {
11494 .eraseblocks = { {64 * 1024, 16} },
11495 .block_erase = spi_block_erase_d8,
11496 }, {
11497 .eraseblocks = { {1024 * 1024, 1} },
11498 .block_erase = spi_block_erase_c7,
11499 }
11500 },
11501 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
11502 .unlock = spi_disable_blockprotect,
11503 .write = spi_chip_write_256,
11504 .read = spi_chip_read,
11505 .voltage = {2700, 3600},
11506 },
11507
11508 {
11509 .vendor = "Micron/Numonyx/ST",
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011510 .name = "M25PX16",
11511 .bustype = BUS_SPI,
11512 .manufacture_id = ST_ID,
11513 .model_id = ST_M25PX16,
11514 .total_size = 2048,
11515 .page_size = 256,
11516 /* OTP: 64B total; read 0x4B; write 0x42 */
11517 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
11518 .tested = TEST_OK_PREW,
11519 .probe = probe_spi_rdid,
11520 .probe_timing = TIMING_ZERO,
11521 .block_erasers =
11522 {
11523 {
11524 .eraseblocks = { { 4 * 1024, 512 } },
11525 .block_erase = spi_block_erase_20,
11526 }, {
11527 .eraseblocks = { {64 * 1024, 32} },
11528 .block_erase = spi_block_erase_d8,
11529 }, {
11530 .eraseblocks = { {2 * 1024 * 1024, 1} },
11531 .block_erase = spi_block_erase_c7,
11532 }
11533 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000011534 .printlock = spi_prettyprint_status_register_bp2_srwd, /* bit5: T/B */
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011535 .unlock = spi_disable_blockprotect_bp2_srwd, /* TODO: per 64kB sector lock registers */
11536 .write = spi_chip_write_256,
11537 .read = spi_chip_read,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +000011538 .voltage = {2300, 3600},
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011539 },
11540
11541 {
11542 .vendor = "Micron/Numonyx/ST",
11543 .name = "M25PX32",
11544 .bustype = BUS_SPI,
11545 .manufacture_id = ST_ID,
11546 .model_id = ST_M25PX32,
11547 .total_size = 4096,
11548 .page_size = 256,
11549 /* OTP: 64B total; read 0x4B; write 0x42 */
11550 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
11551 .tested = TEST_OK_PRE,
11552 .probe = probe_spi_rdid,
11553 .probe_timing = TIMING_ZERO,
11554 .block_erasers =
11555 {
11556 {
11557 .eraseblocks = { { 4 * 1024, 1024 } },
11558 .block_erase = spi_block_erase_20,
11559 }, {
11560 .eraseblocks = { {64 * 1024, 64} },
11561 .block_erase = spi_block_erase_d8,
11562 }, {
11563 .eraseblocks = { {4 * 1024 * 1024, 1} },
11564 .block_erase = spi_block_erase_c7,
11565 }
11566 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000011567 .printlock = spi_prettyprint_status_register_bp2_srwd, /* bit5: T/B */
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011568 .unlock = spi_disable_blockprotect_bp2_srwd, /* TODO: per 64kB sector lock registers */
11569 .write = spi_chip_write_256,
11570 .read = spi_chip_read,
11571 .voltage = {2700, 3600},
11572 },
11573
11574 {
11575 .vendor = "Micron/Numonyx/ST",
11576 .name = "M25PX64",
11577 .bustype = BUS_SPI,
11578 .manufacture_id = ST_ID,
11579 .model_id = ST_M25PX64,
11580 .total_size = 8192,
11581 .page_size = 256,
11582 /* OTP: 64B total; read 0x4B; write 0x42 */
11583 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +000011584 .tested = TEST_OK_PREW,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011585 .probe = probe_spi_rdid,
11586 .probe_timing = TIMING_ZERO,
11587 .block_erasers =
11588 {
11589 {
11590 .eraseblocks = { { 4 * 1024, 2048 } },
11591 .block_erase = spi_block_erase_20,
11592 }, {
11593 .eraseblocks = { {64 * 1024, 128} },
11594 .block_erase = spi_block_erase_d8,
11595 }, {
11596 .eraseblocks = { {8 * 1024 * 1024, 1} },
11597 .block_erase = spi_block_erase_c7,
11598 }
11599 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000011600 .printlock = spi_prettyprint_status_register_bp2_srwd, /* bit5: T/B */
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011601 .unlock = spi_disable_blockprotect_bp2_srwd, /* TODO: per 64kB sector lock registers */
11602 .write = spi_chip_write_256,
11603 .read = spi_chip_read,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +000011604 .voltage = {2700, 3600},
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011605 },
11606
11607 {
11608 .vendor = "Micron/Numonyx/ST",
Alan Green1f9cc7d2019-07-01 11:10:45 +100011609 .name = "M25PX80",
11610 .bustype = BUS_SPI,
11611 .manufacture_id = ST_ID,
11612 .model_id = ST_M25PX80,
11613 .total_size = 1024,
11614 .page_size = 256,
11615 /* OTP: 64B total; read 0x4B, write 0x42 */
11616 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
11617 .tested = TEST_OK_PREW,
11618 .probe = probe_spi_rdid,
11619 .probe_timing = TIMING_ZERO,
11620 .block_erasers =
11621 {
11622 {
11623 .eraseblocks = { { 4 * 1024, 256 } },
11624 .block_erase = spi_block_erase_20,
11625 }, {
11626 .eraseblocks = { {64 * 1024, 16} },
11627 .block_erase = spi_block_erase_d8,
11628 }, {
11629 .eraseblocks = { {1024 * 1024, 1} },
11630 .block_erase = spi_block_erase_c7,
11631 }
11632 },
11633 .printlock = spi_prettyprint_status_register_bp2_srwd, /* bit5: T/B */
11634 .unlock = spi_disable_blockprotect_bp2_srwd, /* TODO: per 64kB sector lock registers */
11635 .write = spi_chip_write_256,
11636 .read = spi_chip_read,
11637 .voltage = {2700, 3600},
11638 },
11639
11640 {
11641 .vendor = "Micron/Numonyx/ST",
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011642 .name = "M45PE10",
11643 .bustype = BUS_SPI,
11644 .manufacture_id = ST_ID,
11645 .model_id = ST_M45PE10,
11646 .total_size = 128,
11647 .page_size = 256,
11648 .tested = TEST_UNTESTED,
11649 .probe = probe_spi_rdid,
11650 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +100011651 .block_erasers =
11652 {
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011653 {
11654 .eraseblocks = { {256, 512} },
11655 .block_erase = spi_block_erase_db,
11656 }, {
11657 .eraseblocks = { {64 * 1024, 2} },
11658 .block_erase = spi_block_erase_d8,
11659 }
11660 },
11661 .printlock = spi_prettyprint_status_register_default_welwip,
11662 .unlock = NULL, /* #WP pin write-protects lower 64kB. */
11663 .write = spi_chip_write_256, /* Page write (similar to PP but allows 0->1 changes) */
11664 .read = spi_chip_read, /* Fast read (0x0B) supported */
11665 .voltage = {2700, 3600},
11666 },
11667
11668 {
11669 .vendor = "Micron/Numonyx/ST",
Alan Green1f9cc7d2019-07-01 11:10:45 +100011670 .name = "M45PE16",
11671 .bustype = BUS_SPI,
11672 .manufacture_id = ST_ID,
11673 .model_id = ST_M45PE16,
11674 .total_size = 2048,
11675 .page_size = 256,
11676 .tested = TEST_UNTESTED,
11677 .probe = probe_spi_rdid,
11678 .probe_timing = TIMING_ZERO,
11679 .block_erasers =
11680 {
11681 {
11682 .eraseblocks = { {256, 8192} },
11683 .block_erase = spi_block_erase_db,
11684 }, {
11685 .eraseblocks = { {64 * 1024, 32} },
11686 .block_erase = spi_block_erase_d8,
11687 }
11688 },
11689 .printlock = spi_prettyprint_status_register_default_welwip,
11690 .unlock = NULL, /* #WP pin write-protects lower 64kB. */
11691 .write = spi_chip_write_256, /* Page write (similar to PP but allows 0->1 changes) */
11692 .read = spi_chip_read, /* Fast read (0x0B) supported */
11693 .voltage = {2700, 3600},
11694 },
11695
11696 {
11697 .vendor = "Micron/Numonyx/ST",
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011698 .name = "M45PE20",
11699 .bustype = BUS_SPI,
11700 .manufacture_id = ST_ID,
11701 .model_id = ST_M45PE20,
11702 .total_size = 256,
11703 .page_size = 256,
11704 .tested = TEST_UNTESTED,
11705 .probe = probe_spi_rdid,
11706 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +100011707 .block_erasers =
11708 {
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011709 {
11710 .eraseblocks = { {256, 1024} },
11711 .block_erase = spi_block_erase_db,
11712 }, {
11713 .eraseblocks = { {64 * 1024, 4} },
11714 .block_erase = spi_block_erase_d8,
11715 }
11716 },
11717 .printlock = spi_prettyprint_status_register_default_welwip,
11718 .unlock = NULL, /* #WP pin write-protects lower 64kB. */
11719 .write = spi_chip_write_256, /* Page write (similar to PP but allows 0->1 changes) */
11720 .read = spi_chip_read, /* Fast read (0x0B) supported */
11721 .voltage = {2700, 3600},
11722 },
11723
11724 {
11725 .vendor = "Micron/Numonyx/ST",
11726 .name = "M45PE40",
11727 .bustype = BUS_SPI,
11728 .manufacture_id = ST_ID,
11729 .model_id = ST_M45PE40,
11730 .total_size = 512,
11731 .page_size = 256,
11732 .tested = TEST_UNTESTED,
11733 .probe = probe_spi_rdid,
11734 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +100011735 .block_erasers =
11736 {
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011737 {
11738 .eraseblocks = { {256, 2048} },
11739 .block_erase = spi_block_erase_db,
11740 }, {
11741 .eraseblocks = { {64 * 1024, 8} },
11742 .block_erase = spi_block_erase_d8,
11743 }
11744 },
11745 .printlock = spi_prettyprint_status_register_default_welwip,
11746 .unlock = NULL, /* #WP pin write-protects lower 64kB. */
Stefan Tauner23e10b82016-01-23 16:16:49 +000011747 .write = spi_chip_write_256, /* Page write supported (similar to PP but allows 0->1 changes) */
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011748 .read = spi_chip_read, /* Fast read (0x0B) supported */
11749 .voltage = {2700, 3600},
11750 },
11751
11752 {
11753 .vendor = "Micron/Numonyx/ST",
11754 .name = "M45PE80",
11755 .bustype = BUS_SPI,
11756 .manufacture_id = ST_ID,
11757 .model_id = ST_M45PE80,
11758 .total_size = 1024,
11759 .page_size = 256,
11760 .tested = TEST_UNTESTED,
11761 .probe = probe_spi_rdid,
11762 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +100011763 .block_erasers =
11764 {
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011765 {
11766 .eraseblocks = { {256, 4096} },
11767 .block_erase = spi_block_erase_db,
11768 }, {
11769 .eraseblocks = { {64 * 1024, 16} },
11770 .block_erase = spi_block_erase_d8,
11771 }
11772 },
11773 .printlock = spi_prettyprint_status_register_default_welwip,
11774 .unlock = NULL, /* #WP pin write-protects lower 64kB. */
11775 .write = spi_chip_write_256, /* Page write (similar to PP but allows 0->1 changes) */
11776 .read = spi_chip_read, /* Fast read (0x0B) supported */
11777 .voltage = {2700, 3600},
11778 },
11779
11780 {
11781 .vendor = "Micron/Numonyx/ST",
Jacob Creedon80e8dc42019-07-22 12:35:30 -070011782 .name = "N25Q00A..1G", /* ..1G = 1.8V, uniform 64KB/4KB blocks/sectors */
11783 .bustype = BUS_SPI,
11784 .manufacture_id = ST_ID,
11785 .model_id = ST_N25Q00A__1G,
11786 .total_size = 131072,
11787 .page_size = 256,
11788 /* supports SFDP */
11789 /* OTP: 64B total; read 0x4B, write 0x42 */
11790 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
11791 .tested = TEST_UNTESTED,
11792 .probe = probe_spi_rdid,
11793 .probe_timing = TIMING_ZERO,
11794 .block_erasers =
11795 {
11796 {
11797 .eraseblocks = { {4 * 1024, 32768} },
11798 .block_erase = spi_block_erase_21,
11799 }, {
11800 .eraseblocks = { {4 * 1024, 32768} },
11801 .block_erase = spi_block_erase_20,
11802 }, {
11803 .eraseblocks = { {64 * 1024, 2048} },
11804 .block_erase = spi_block_erase_dc,
11805 }, {
11806 .eraseblocks = { {64 * 1024, 2048} },
11807 .block_erase = spi_block_erase_d8,
11808 }, {
11809 .eraseblocks = { {32768 * 1024, 4} },
11810 .block_erase = spi_block_erase_c4,
11811 }
11812 },
11813 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
11814 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
11815 .write = spi_chip_write_256, /* Multi I/O supported */
11816 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
11817 .voltage = {1700, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020011818 .prepare_access = spi_prepare_io,
11819 .finish_access = spi_finish_io,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070011820 },
11821
11822 {
11823 .vendor = "Micron/Numonyx/ST",
11824 .name = "N25Q00A..3G", /* ..3G = 3V, uniform 64KB/4KB blocks/sectors */
11825 .bustype = BUS_SPI,
11826 .manufacture_id = ST_ID,
11827 .model_id = ST_N25Q00A__3G,
11828 .total_size = 131072,
11829 .page_size = 256,
11830 /* supports SFDP */
11831 /* OTP: 64B total; read 0x4B, write 0x42 */
11832 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
11833 .tested = TEST_UNTESTED,
11834 .probe = probe_spi_rdid,
11835 .probe_timing = TIMING_ZERO,
11836 .block_erasers =
11837 {
11838 {
11839 .eraseblocks = { {4 * 1024, 32768} },
11840 .block_erase = spi_block_erase_21,
11841 }, {
11842 .eraseblocks = { {4 * 1024, 32768} },
11843 .block_erase = spi_block_erase_20,
11844 }, {
11845 .eraseblocks = { {64 * 1024, 2048} },
11846 .block_erase = spi_block_erase_dc,
11847 }, {
11848 .eraseblocks = { {64 * 1024, 2048} },
11849 .block_erase = spi_block_erase_d8,
11850 }, {
11851 .eraseblocks = { {32768 * 1024, 4} },
11852 .block_erase = spi_block_erase_c4,
11853 }
11854 },
11855 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
11856 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
11857 .write = spi_chip_write_256, /* Multi I/O supported */
11858 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
11859 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020011860 .prepare_access = spi_prepare_io,
11861 .finish_access = spi_finish_io,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070011862 },
11863
11864 {
11865 .vendor = "Micron/Numonyx/ST",
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011866 .name = "N25Q016",
11867 .bustype = BUS_SPI,
11868 .manufacture_id = ST_ID,
11869 .model_id = ST_N25Q016__1E,
11870 .total_size = 2048,
11871 .page_size = 256,
11872 /* supports SFDP */
11873 /* OTP: 64B total; read 0x4B, write 0x42 */
11874 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
11875 .tested = TEST_UNTESTED,
11876 .probe = probe_spi_rdid,
11877 .probe_timing = TIMING_ZERO,
11878 .block_erasers =
11879 {
11880 {
11881 .eraseblocks = { {4 * 1024, 512} },
11882 .block_erase = spi_block_erase_20,
11883 }, {
11884 .eraseblocks = { {32 * 1024, 64} },
11885 .block_erase = spi_block_erase_52,
11886 }, {
11887 .eraseblocks = { {64 * 1024, 32} },
11888 .block_erase = spi_block_erase_d8,
11889 }, {
11890 .eraseblocks = { {2 * 1024 * 1024, 1} },
11891 .block_erase = spi_block_erase_c7,
11892 }
11893 },
11894 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
11895 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
11896 .write = spi_chip_write_256, /* Multi I/O supported */
11897 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
11898 .voltage = {1700, 2000},
11899 },
11900
11901 {
11902 .vendor = "Micron/Numonyx/ST",
11903 .name = "N25Q032..1E",
11904 .bustype = BUS_SPI,
11905 .manufacture_id = ST_ID,
11906 .model_id = ST_N25Q032__1E,
11907 .total_size = 4096,
11908 .page_size = 256,
11909 /* supports SFDP */
11910 /* OTP: 64B total; read 0x4B, write 0x42 */
11911 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
11912 .tested = TEST_UNTESTED,
11913 .probe = probe_spi_rdid,
11914 .probe_timing = TIMING_ZERO,
11915 .block_erasers =
11916 {
11917 {
11918 .eraseblocks = { {4 * 1024, 1024} },
11919 .block_erase = spi_block_erase_20,
11920 }, {
11921 .eraseblocks = { {64 * 1024, 64} },
11922 .block_erase = spi_block_erase_d8,
11923 }, {
11924 .eraseblocks = { {4 * 1024 * 1024, 1} },
11925 .block_erase = spi_block_erase_c7,
11926 }
11927 },
11928 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
11929 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
11930 .write = spi_chip_write_256, /* Multi I/O supported */
11931 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
11932 .voltage = {1700, 2000},
Sergii Dmytrukd5ba24c2022-07-25 00:28:35 +030011933 .reg_bits =
11934 {
11935 /*
11936 * There is also a volatile lock register per 64KiB sector, which is not
11937 * mutually exclusive with BP-based protection.
11938 */
11939 .srp = {STATUS1, 7, RW},
11940 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
11941 .tb = {STATUS1, 5, RW},
11942 },
Nico Huberaabb3e02023-01-13 00:22:30 +010011943 .wp_write_cfg = spi_wp_write_cfg,
11944 .wp_read_cfg = spi_wp_read_cfg,
11945 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukd5ba24c2022-07-25 00:28:35 +030011946 .decode_range = decode_range_spi25,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011947 },
11948
11949 {
11950 .vendor = "Micron/Numonyx/ST",
11951 .name = "N25Q032..3E",
11952 .bustype = BUS_SPI,
11953 .manufacture_id = ST_ID,
11954 .model_id = ST_N25Q032__3E,
11955 .total_size = 4096,
11956 .page_size = 256,
11957 /* supports SFDP */
11958 /* OTP: 64B total; read 0x4B, write 0x42 */
11959 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
11960 .tested = TEST_OK_PREW,
11961 .probe = probe_spi_rdid,
11962 .probe_timing = TIMING_ZERO,
11963 .block_erasers =
11964 {
11965 {
11966 .eraseblocks = { {4 * 1024, 1024} },
11967 .block_erase = spi_block_erase_20,
11968 }, {
11969 .eraseblocks = { {64 * 1024, 64} },
11970 .block_erase = spi_block_erase_d8,
11971 }, {
11972 .eraseblocks = { {4 * 1024 * 1024, 1} },
11973 .block_erase = spi_block_erase_c7,
11974 }
11975 },
11976 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
11977 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
11978 .write = spi_chip_write_256, /* Multi I/O supported */
11979 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
11980 .voltage = {2700, 3600},
Sergii Dmytrukd5ba24c2022-07-25 00:28:35 +030011981 .reg_bits =
11982 {
11983 /*
11984 * There is also a volatile lock register per 64KiB sector, which is not
11985 * mutually exclusive with BP-based protection.
11986 */
11987 .srp = {STATUS1, 7, RW},
11988 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
11989 .tb = {STATUS1, 5, RW},
11990 },
Nico Huberaabb3e02023-01-13 00:22:30 +010011991 .wp_write_cfg = spi_wp_write_cfg,
11992 .wp_read_cfg = spi_wp_read_cfg,
11993 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukd5ba24c2022-07-25 00:28:35 +030011994 .decode_range = decode_range_spi25,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000011995 },
11996
11997 {
11998 .vendor = "Micron/Numonyx/ST",
11999 .name = "N25Q064..1E", /* ..1E = 1.8V, uniform 64KB/4KB blocks/sectors */
12000 .bustype = BUS_SPI,
12001 .manufacture_id = ST_ID,
12002 .model_id = ST_N25Q064__1E,
12003 .total_size = 8192,
12004 .page_size = 256,
12005 /* supports SFDP */
12006 /* OTP: 64B total; read 0x4B, write 0x42 */
12007 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +000012008 .tested = TEST_OK_PREW,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000012009 .probe = probe_spi_rdid,
12010 .probe_timing = TIMING_ZERO,
12011 .block_erasers =
12012 {
12013 {
12014 .eraseblocks = { {4 * 1024, 2048 } },
12015 .block_erase = spi_block_erase_20,
12016 }, {
12017 .eraseblocks = { {64 * 1024, 128} },
12018 .block_erase = spi_block_erase_d8,
12019 }, {
12020 .eraseblocks = { {8 * 1024 * 1024, 1} },
12021 .block_erase = spi_block_erase_c7,
12022 }
12023 },
12024 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12025 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12026 .write = spi_chip_write_256, /* Multi I/O supported */
12027 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12028 .voltage = {1700, 2000},
Sergii Dmytrukd5ba24c2022-07-25 00:28:35 +030012029 .reg_bits =
12030 {
12031 /*
12032 * There is also a volatile lock register per 64KiB sector, which is not
12033 * mutually exclusive with BP-based protection.
12034 */
12035 .srp = {STATUS1, 7, RW},
12036 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}, {STATUS1, 6, RW}},
12037 .tb = {STATUS1, 5, RW},
12038 },
Nico Huberaabb3e02023-01-13 00:22:30 +010012039 .wp_write_cfg = spi_wp_write_cfg,
12040 .wp_read_cfg = spi_wp_read_cfg,
12041 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukd5ba24c2022-07-25 00:28:35 +030012042 .decode_range = decode_range_spi25,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000012043 },
12044
12045 {
12046 .vendor = "Micron/Numonyx/ST",
12047 .name = "N25Q064..3E", /* ..3E = 3V, uniform 64KB/4KB blocks/sectors */
12048 .bustype = BUS_SPI,
Alan Greenfa3fcd32019-06-27 15:41:50 +100012049 .manufacture_id = ST_ID,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000012050 .model_id = ST_N25Q064__3E,
12051 .total_size = 8192,
12052 .page_size = 256,
12053 /* supports SFDP */
12054 /* OTP: 64B total; read 0x4B, write 0x42 */
12055 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
12056 .tested = TEST_OK_PREW,
12057 .probe = probe_spi_rdid,
12058 .probe_timing = TIMING_ZERO,
12059 .block_erasers =
12060 {
12061 {
12062 .eraseblocks = { {4 * 1024, 2048 } },
12063 .block_erase = spi_block_erase_20,
12064 }, {
12065 .eraseblocks = { {64 * 1024, 128} },
12066 .block_erase = spi_block_erase_d8,
12067 }, {
12068 .eraseblocks = { {8 * 1024 * 1024, 1} },
12069 .block_erase = spi_block_erase_c7,
12070 }
12071 },
12072 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12073 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12074 .write = spi_chip_write_256, /* Multi I/O supported */
12075 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12076 .voltage = {2700, 3600},
Sergii Dmytrukd5ba24c2022-07-25 00:28:35 +030012077 .reg_bits =
12078 {
12079 /*
12080 * There is also a volatile lock register per 64KiB sector, which is not
12081 * mutually exclusive with BP-based protection.
12082 */
12083 .srp = {STATUS1, 7, RW},
12084 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}, {STATUS1, 6, RW}},
12085 .tb = {STATUS1, 5, RW},
12086 },
Nico Huberaabb3e02023-01-13 00:22:30 +010012087 .wp_write_cfg = spi_wp_write_cfg,
12088 .wp_read_cfg = spi_wp_read_cfg,
12089 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukd5ba24c2022-07-25 00:28:35 +030012090 .decode_range = decode_range_spi25,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000012091 },
12092
12093 {
12094 .vendor = "Micron/Numonyx/ST",
12095 .name = "N25Q128..1E", /* ..1E = 1.8V, uniform 64KB/4KB blocks/sectors */
12096 .bustype = BUS_SPI,
Alan Greenfa3fcd32019-06-27 15:41:50 +100012097 .manufacture_id = ST_ID,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000012098 .model_id = ST_N25Q128__1E,
12099 .total_size = 16384,
12100 .page_size = 256,
12101 /* supports SFDP */
12102 /* OTP: 64B total; read 0x4B, write 0x42 */
12103 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Stefan Tauner23e10b82016-01-23 16:16:49 +000012104 .tested = TEST_OK_PREW,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000012105 .probe = probe_spi_rdid,
12106 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +100012107 .block_erasers =
12108 {
Stefan Tauner1aa80b02013-07-25 22:58:51 +000012109 {
12110 .eraseblocks = { {4 * 1024, 4096 } },
12111 .block_erase = spi_block_erase_20,
12112 }, {
12113 .eraseblocks = { {64 * 1024, 256} },
12114 .block_erase = spi_block_erase_d8,
12115 }, {
12116 .eraseblocks = { {16384 * 1024, 1} },
12117 .block_erase = spi_block_erase_c7,
12118 }
12119 },
12120 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12121 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12122 .write = spi_chip_write_256, /* Multi I/O supported */
12123 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12124 .voltage = {1700, 2000},
12125 },
12126
12127 {
12128 .vendor = "Micron/Numonyx/ST",
12129 .name = "N25Q128..3E", /* ..3E = 3V, uniform 64KB/4KB blocks/sectors */
12130 .bustype = BUS_SPI,
Alan Greenfa3fcd32019-06-27 15:41:50 +100012131 .manufacture_id = ST_ID,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000012132 .model_id = ST_N25Q128__3E,
12133 .total_size = 16384,
12134 .page_size = 256,
12135 /* supports SFDP */
12136 /* OTP: 64B total; read 0x4B, write 0x42 */
12137 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
12138 .tested = TEST_OK_PREW,
12139 .probe = probe_spi_rdid,
12140 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +100012141 .block_erasers =
12142 {
Stefan Tauner1aa80b02013-07-25 22:58:51 +000012143 {
12144 .eraseblocks = { {4 * 1024, 4096 } },
12145 .block_erase = spi_block_erase_20,
12146 }, {
12147 .eraseblocks = { {64 * 1024, 256} },
12148 .block_erase = spi_block_erase_d8,
12149 }, {
12150 .eraseblocks = { {16384 * 1024, 1} },
12151 .block_erase = spi_block_erase_c7,
12152 }
12153 },
12154 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12155 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12156 .write = spi_chip_write_256, /* Multi I/O supported */
12157 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12158 .voltage = {2700, 3600},
12159 },
12160
12161 {
Jacob Creedon08e9d1d2019-07-22 12:04:40 -070012162 .vendor = "Micron/Numonyx/ST",
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012163 .name = "N25Q256..1E", /* ..1E = 1.8V, uniform 64KB/4KB blocks/sectors */
12164 .bustype = BUS_SPI,
12165 .manufacture_id = ST_ID,
12166 .model_id = ST_N25Q256__1E,
12167 .total_size = 32768,
12168 .page_size = 256,
12169 /* supports SFDP */
12170 /* OTP: 64B total; read 0x4B, write 0x42 */
12171 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
12172 .tested = TEST_UNTESTED,
12173 .probe = probe_spi_rdid,
12174 .probe_timing = TIMING_ZERO,
12175 .block_erasers =
12176 {
12177 {
12178 .eraseblocks = { {4 * 1024, 8192} },
12179 .block_erase = spi_block_erase_21,
12180 }, {
12181 .eraseblocks = { {4 * 1024, 8192} },
12182 .block_erase = spi_block_erase_20,
12183 }, {
12184 .eraseblocks = { {64 * 1024, 512} },
12185 .block_erase = spi_block_erase_dc,
12186 }, {
12187 .eraseblocks = { {64 * 1024, 512} },
12188 .block_erase = spi_block_erase_d8,
12189 }, {
12190 .eraseblocks = { {32768 * 1024, 1} },
12191 .block_erase = spi_block_erase_c7,
12192 }
12193 },
12194 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12195 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12196 .write = spi_chip_write_256, /* Multi I/O supported */
12197 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12198 .voltage = {1700, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020012199 .prepare_access = spi_prepare_io,
12200 .finish_access = spi_finish_io,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012201 },
12202
12203 {
12204 .vendor = "Micron/Numonyx/ST",
Jacob Creedon08e9d1d2019-07-22 12:04:40 -070012205 .name = "N25Q256..3E", /* ..3E = 3V, uniform 64KB/4KB blocks/sectors */
12206 .bustype = BUS_SPI,
12207 .manufacture_id = ST_ID,
12208 .model_id = ST_N25Q256__3E,
12209 .total_size = 32768,
12210 .page_size = 256,
12211 /* supports SFDP */
12212 /* OTP: 64B total; read 0x4B, write 0x42 */
12213 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
12214 .tested = TEST_UNTESTED,
12215 .probe = probe_spi_rdid,
12216 .probe_timing = TIMING_ZERO,
12217 .block_erasers =
12218 {
12219 {
12220 .eraseblocks = { {4 * 1024, 8192} },
12221 .block_erase = spi_block_erase_21,
12222 }, {
12223 .eraseblocks = { {4 * 1024, 8192} },
12224 .block_erase = spi_block_erase_20,
12225 }, {
12226 .eraseblocks = { {64 * 1024, 512} },
12227 .block_erase = spi_block_erase_dc,
12228 }, {
12229 .eraseblocks = { {64 * 1024, 512} },
12230 .block_erase = spi_block_erase_d8,
12231 }, {
12232 .eraseblocks = { {32768 * 1024, 1} },
12233 .block_erase = spi_block_erase_c7,
12234 }
12235 },
12236 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12237 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12238 .write = spi_chip_write_256, /* Multi I/O supported */
12239 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12240 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020012241 .prepare_access = spi_prepare_io,
12242 .finish_access = spi_finish_io,
Jacob Creedon08e9d1d2019-07-22 12:04:40 -070012243 },
12244
12245 {
12246 .vendor = "Micron/Numonyx/ST",
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012247 .name = "N25Q512..1G", /* ..1G = 1.8V, uniform 64KB/4KB blocks/sectors */
Jacob Creedon08e9d1d2019-07-22 12:04:40 -070012248 .bustype = BUS_SPI,
12249 .manufacture_id = ST_ID,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012250 .model_id = ST_N25Q512__1G,
12251 .total_size = 65536,
12252 .page_size = 256,
12253 /* supports SFDP */
12254 /* OTP: 64B total; read 0x4B, write 0x42 */
12255 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
12256 .tested = TEST_UNTESTED,
12257 .probe = probe_spi_rdid,
12258 .probe_timing = TIMING_ZERO,
12259 .block_erasers =
12260 {
12261 {
12262 .eraseblocks = { {4 * 1024, 16384} },
12263 .block_erase = spi_block_erase_21,
12264 }, {
12265 .eraseblocks = { {4 * 1024, 16384} },
12266 .block_erase = spi_block_erase_20,
12267 }, {
12268 .eraseblocks = { {64 * 1024, 1024} },
12269 .block_erase = spi_block_erase_dc,
12270 }, {
12271 .eraseblocks = { {64 * 1024, 1024} },
12272 .block_erase = spi_block_erase_d8,
12273 }, {
12274 .eraseblocks = { {32768 * 1024, 2} },
12275 .block_erase = spi_block_erase_c4,
12276 }
12277 },
12278 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12279 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12280 .write = spi_chip_write_256, /* Multi I/O supported */
12281 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12282 .voltage = {1700, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020012283 .prepare_access = spi_prepare_io,
12284 .finish_access = spi_finish_io,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012285 },
12286
12287 {
12288 .vendor = "Micron/Numonyx/ST",
12289 .name = "N25Q512..3G", /* ..3G = 3V, uniform 64KB/4KB blocks/sectors */
12290 .bustype = BUS_SPI,
12291 .manufacture_id = ST_ID,
12292 .model_id = ST_N25Q512__3G,
Jacob Creedon08e9d1d2019-07-22 12:04:40 -070012293 .total_size = 65536,
12294 .page_size = 256,
12295 /* supports SFDP */
12296 /* OTP: 64B total; read 0x4B, write 0x42 */
12297 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
12298 .tested = TEST_OK_PREW,
12299 .probe = probe_spi_rdid,
12300 .probe_timing = TIMING_ZERO,
12301 .block_erasers =
12302 {
12303 {
12304 .eraseblocks = { {4 * 1024, 16384} },
12305 .block_erase = spi_block_erase_21,
12306 }, {
12307 .eraseblocks = { {4 * 1024, 16384} },
12308 .block_erase = spi_block_erase_20,
12309 }, {
12310 .eraseblocks = { {64 * 1024, 1024} },
12311 .block_erase = spi_block_erase_dc,
12312 }, {
12313 .eraseblocks = { {64 * 1024, 1024} },
12314 .block_erase = spi_block_erase_d8,
12315 }, {
Jacob Creedone8e7b0e2019-07-22 12:21:22 -070012316 .eraseblocks = { {32768 * 1024, 2} },
12317 .block_erase = spi_block_erase_c4,
Jacob Creedon08e9d1d2019-07-22 12:04:40 -070012318 }
12319 },
12320 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12321 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12322 .write = spi_chip_write_256, /* Multi I/O supported */
12323 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12324 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020012325 .prepare_access = spi_prepare_io,
12326 .finish_access = spi_finish_io,
Jacob Creedon08e9d1d2019-07-22 12:04:40 -070012327 },
12328
12329 {
Ed Swierk199ab392017-07-03 13:33:44 -070012330 .vendor = "Micron",
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012331 .name = "MT25QL01G", /* L = 3V, uniform 64KB/4KB blocks/sectors */
12332 .bustype = BUS_SPI,
12333 .manufacture_id = ST_ID,
12334 .model_id = ST_N25Q00A__3G,
12335 .total_size = 131072,
12336 .page_size = 256,
12337 /* supports SFDP */
12338 /* OTP: 64B total; read 0x4B, write 0x42 */
12339 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
12340 .tested = TEST_OK_PREW,
12341 .probe = probe_spi_rdid,
12342 .probe_timing = TIMING_ZERO,
12343 .block_erasers =
12344 {
12345 {
12346 .eraseblocks = { {4 * 1024, 32768} },
12347 .block_erase = spi_block_erase_21,
12348 }, {
12349 .eraseblocks = { {4 * 1024, 32768} },
12350 .block_erase = spi_block_erase_20,
12351 }, {
12352 .eraseblocks = { {32 * 1024, 4096} },
12353 .block_erase = spi_block_erase_5c,
12354 }, {
12355 .eraseblocks = { {32 * 1024, 4096} },
12356 .block_erase = spi_block_erase_52,
12357 }, {
12358 .eraseblocks = { {64 * 1024, 2048} },
12359 .block_erase = spi_block_erase_dc,
12360 }, {
12361 .eraseblocks = { {64 * 1024, 2048} },
12362 .block_erase = spi_block_erase_d8,
12363 }, {
12364 .eraseblocks = { {65536 * 1024, 2} },
12365 .block_erase = spi_block_erase_c4,
12366 }
12367 },
12368 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12369 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12370 .write = spi_chip_write_256, /* Multi I/O supported */
12371 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12372 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020012373 .prepare_access = spi_prepare_io,
12374 .finish_access = spi_finish_io,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012375 },
12376
12377 {
12378 .vendor = "Micron",
12379 .name = "MT25QU01G", /* U = 1.8V, uniform 64KB/4KB blocks/sectors */
12380 .bustype = BUS_SPI,
12381 .manufacture_id = ST_ID,
12382 .model_id = ST_N25Q00A__1G,
12383 .total_size = 131072,
12384 .page_size = 256,
12385 /* supports SFDP */
12386 /* OTP: 64B total; read 0x4B, write 0x42 */
12387 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
12388 .tested = TEST_UNTESTED,
12389 .probe = probe_spi_rdid,
12390 .probe_timing = TIMING_ZERO,
12391 .block_erasers =
12392 {
12393 {
12394 .eraseblocks = { {4 * 1024, 32768} },
12395 .block_erase = spi_block_erase_21,
12396 }, {
12397 .eraseblocks = { {4 * 1024, 32768} },
12398 .block_erase = spi_block_erase_20,
12399 }, {
12400 .eraseblocks = { {32 * 1024, 4096} },
12401 .block_erase = spi_block_erase_5c,
12402 }, {
12403 .eraseblocks = { {32 * 1024, 4096} },
12404 .block_erase = spi_block_erase_52,
12405 }, {
12406 .eraseblocks = { {64 * 1024, 2048} },
12407 .block_erase = spi_block_erase_dc,
12408 }, {
12409 .eraseblocks = { {64 * 1024, 2048} },
12410 .block_erase = spi_block_erase_d8,
12411 }, {
12412 .eraseblocks = { {65536 * 1024, 2} },
12413 .block_erase = spi_block_erase_c4,
12414 }
12415 },
12416 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12417 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12418 .write = spi_chip_write_256, /* Multi I/O supported */
12419 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12420 .voltage = {1700, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020012421 .prepare_access = spi_prepare_io,
12422 .finish_access = spi_finish_io,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012423 },
12424
12425 {
12426 .vendor = "Micron",
12427 .name = "MT25QL02G", /* L = 3V, uniform 64KB/4KB blocks/sectors */
12428 .bustype = BUS_SPI,
12429 .manufacture_id = ST_ID,
12430 .model_id = ST_MT25QL02G,
12431 .total_size = 262144,
12432 .page_size = 256,
12433 /* supports SFDP */
12434 /* OTP: 64B total; read 0x4B, write 0x42 */
12435 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
12436 .tested = TEST_UNTESTED,
12437 .probe = probe_spi_rdid,
12438 .probe_timing = TIMING_ZERO,
12439 .block_erasers =
12440 {
12441 {
12442 .eraseblocks = { {4 * 1024, 65536} },
12443 .block_erase = spi_block_erase_21,
12444 }, {
12445 .eraseblocks = { {4 * 1024, 65536} },
12446 .block_erase = spi_block_erase_20,
12447 }, {
12448 .eraseblocks = { {32 * 1024, 8192} },
12449 .block_erase = spi_block_erase_5c,
12450 }, {
12451 .eraseblocks = { {32 * 1024, 8192} },
12452 .block_erase = spi_block_erase_52,
12453 }, {
12454 .eraseblocks = { {64 * 1024, 4096} },
12455 .block_erase = spi_block_erase_dc,
12456 }, {
12457 .eraseblocks = { {64 * 1024, 4096} },
12458 .block_erase = spi_block_erase_d8,
12459 }, {
12460 .eraseblocks = { {65536 * 1024, 4} },
12461 .block_erase = spi_block_erase_c4,
12462 }
12463 },
12464 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12465 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12466 .write = spi_chip_write_256, /* Multi I/O supported */
12467 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12468 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020012469 .prepare_access = spi_prepare_io,
12470 .finish_access = spi_finish_io,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012471 },
12472
12473 {
12474 .vendor = "Micron",
12475 .name = "MT25QU02G", /* U = 1.8V, uniform 64KB/4KB blocks/sectors */
12476 .bustype = BUS_SPI,
12477 .manufacture_id = ST_ID,
12478 .model_id = ST_MT25QU02G,
12479 .total_size = 262144,
12480 .page_size = 256,
12481 /* supports SFDP */
12482 /* OTP: 64B total; read 0x4B, write 0x42 */
12483 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
12484 .tested = TEST_UNTESTED,
12485 .probe = probe_spi_rdid,
12486 .probe_timing = TIMING_ZERO,
12487 .block_erasers =
12488 {
12489 {
12490 .eraseblocks = { {4 * 1024, 65536} },
12491 .block_erase = spi_block_erase_21,
12492 }, {
12493 .eraseblocks = { {4 * 1024, 65536} },
12494 .block_erase = spi_block_erase_20,
12495 }, {
12496 .eraseblocks = { {32 * 1024, 8192} },
12497 .block_erase = spi_block_erase_5c,
12498 }, {
12499 .eraseblocks = { {32 * 1024, 8192} },
12500 .block_erase = spi_block_erase_52,
12501 }, {
12502 .eraseblocks = { {64 * 1024, 4096} },
12503 .block_erase = spi_block_erase_dc,
12504 }, {
12505 .eraseblocks = { {64 * 1024, 4096} },
12506 .block_erase = spi_block_erase_d8,
12507 }, {
12508 .eraseblocks = { {65536 * 1024, 4} },
12509 .block_erase = spi_block_erase_c4,
12510 }
12511 },
12512 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12513 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12514 .write = spi_chip_write_256, /* Multi I/O supported */
12515 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12516 .voltage = {1700, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020012517 .prepare_access = spi_prepare_io,
12518 .finish_access = spi_finish_io,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012519 },
12520
12521 {
12522 .vendor = "Micron",
12523 .name = "MT25QU128", /* U = 1.8V, uniform 64KB/4KB blocks/sectors */
12524 .bustype = BUS_SPI,
12525 .manufacture_id = ST_ID,
12526 .model_id = ST_N25Q128__1E,
12527 .total_size = 16384,
12528 .page_size = 256,
12529 /* supports SFDP */
12530 /* OTP: 64B total; read 0x4B, write 0x42 */
Nico Huber48dc0902023-03-05 17:20:55 +010012531 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012532 .tested = TEST_UNTESTED,
12533 .probe = probe_spi_rdid,
12534 .probe_timing = TIMING_ZERO,
12535 .block_erasers =
12536 {
12537 {
12538 .eraseblocks = { {4 * 1024, 4096} },
12539 .block_erase = spi_block_erase_20,
12540 }, {
12541 .eraseblocks = { {32 * 1024, 512} },
12542 .block_erase = spi_block_erase_52,
12543 }, {
12544 .eraseblocks = { {64 * 1024, 256} },
12545 .block_erase = spi_block_erase_d8,
12546 }, {
12547 .eraseblocks = { {16384 * 1024, 1} },
12548 .block_erase = spi_block_erase_c7,
12549 }, {
12550 .eraseblocks = { {16384 * 1024, 1} },
12551 .block_erase = spi_block_erase_60,
12552 }
12553 },
12554 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12555 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12556 .write = spi_chip_write_256, /* Multi I/O supported */
12557 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12558 .voltage = {1700, 2000},
12559 },
12560
12561 {
12562 .vendor = "Micron",
12563 .name = "MT25QL128", /* L = 3V, uniform 64KB/4KB blocks/sectors */
12564 .bustype = BUS_SPI,
12565 .manufacture_id = ST_ID,
12566 .model_id = ST_N25Q128__3E,
12567 .total_size = 16384,
12568 .page_size = 256,
12569 /* supports SFDP */
12570 /* OTP: 64B total; read 0x4B, write 0x42 */
Rick Altherr1e563602022-12-22 10:25:34 -080012571 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
12572 .tested = TEST_OK_PREW,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012573 .probe = probe_spi_rdid,
12574 .probe_timing = TIMING_ZERO,
12575 .block_erasers =
12576 {
12577 {
12578 .eraseblocks = { {4 * 1024, 4096} },
12579 .block_erase = spi_block_erase_20,
12580 }, {
12581 .eraseblocks = { {32 * 1024, 512} },
12582 .block_erase = spi_block_erase_52,
12583 }, {
12584 .eraseblocks = { {64 * 1024, 256} },
12585 .block_erase = spi_block_erase_d8,
12586 }, {
12587 .eraseblocks = { {16384 * 1024, 1} },
12588 .block_erase = spi_block_erase_c7,
12589 }, {
12590 .eraseblocks = { {16384 * 1024, 1} },
12591 .block_erase = spi_block_erase_60,
12592 }
12593 },
12594 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12595 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12596 .write = spi_chip_write_256, /* Multi I/O supported */
12597 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12598 .voltage = {2700, 3600},
12599 },
12600
12601 {
12602 .vendor = "Micron",
Jacob Creedon08e9d1d2019-07-22 12:04:40 -070012603 .name = "MT25QL256", /* L = 3V, uniform 64KB/4KB blocks/sectors */
Ed Swierk199ab392017-07-03 13:33:44 -070012604 .bustype = BUS_SPI,
Alan Greenfa3fcd32019-06-27 15:41:50 +100012605 .manufacture_id = ST_ID,
Ed Swierk199ab392017-07-03 13:33:44 -070012606 .model_id = ST_N25Q256__3E,
12607 .total_size = 32768,
12608 .page_size = 256,
12609 /* supports SFDP */
12610 /* OTP: 64B total; read 0x4B, write 0x42 */
Nico Huberaac81422017-11-10 22:54:13 +010012611 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
Simon Buhrowb7014f92021-02-15 13:16:57 +010012612 .tested = TEST_OK_PREW,
Ed Swierk199ab392017-07-03 13:33:44 -070012613 .probe = probe_spi_rdid,
12614 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +100012615 .block_erasers =
12616 {
Ed Swierk199ab392017-07-03 13:33:44 -070012617 {
12618 .eraseblocks = { {4 * 1024, 8192} },
Nico Huber7e3c81a2017-10-14 18:56:50 +020012619 .block_erase = spi_block_erase_21,
Ed Swierk199ab392017-07-03 13:33:44 -070012620 }, {
Nico Huberaac81422017-11-10 22:54:13 +010012621 .eraseblocks = { {4 * 1024, 8192} },
12622 .block_erase = spi_block_erase_20,
12623 }, {
Jacob Creedon045b97e2019-07-22 12:26:56 -070012624 .eraseblocks = { {32 * 1024, 1024} },
12625 .block_erase = spi_block_erase_5c,
12626 }, {
12627 .eraseblocks = { {32 * 1024, 1024} },
12628 .block_erase = spi_block_erase_52,
12629 }, {
Ed Swierk199ab392017-07-03 13:33:44 -070012630 .eraseblocks = { {64 * 1024, 512} },
Nico Huber7e3c81a2017-10-14 18:56:50 +020012631 .block_erase = spi_block_erase_dc,
Ed Swierk199ab392017-07-03 13:33:44 -070012632 }, {
Nico Huberaac81422017-11-10 22:54:13 +010012633 .eraseblocks = { {64 * 1024, 512} },
12634 .block_erase = spi_block_erase_d8,
12635 }, {
Ed Swierk199ab392017-07-03 13:33:44 -070012636 .eraseblocks = { {32768 * 1024, 1} },
12637 .block_erase = spi_block_erase_c7,
Jacob Creedon045b97e2019-07-22 12:26:56 -070012638 }, {
12639 .eraseblocks = { {32768 * 1024, 1} },
12640 .block_erase = spi_block_erase_60,
Ed Swierk199ab392017-07-03 13:33:44 -070012641 }
12642 },
12643 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12644 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12645 .write = spi_chip_write_256, /* Multi I/O supported */
12646 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12647 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020012648 .prepare_access = spi_prepare_io,
12649 .finish_access = spi_finish_io,
Ed Swierk199ab392017-07-03 13:33:44 -070012650 },
12651
12652 {
12653 .vendor = "Micron",
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012654 .name = "MT25QU256", /* U = 1.8V, uniform 64KB/4KB blocks/sectors */
12655 .bustype = BUS_SPI,
12656 .manufacture_id = ST_ID,
12657 .model_id = ST_N25Q256__1E,
12658 .total_size = 32768,
12659 .page_size = 256,
12660 /* supports SFDP */
12661 /* OTP: 64B total; read 0x4B, write 0x42 */
12662 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
Angel Pons59052582022-03-08 15:23:58 +010012663 .tested = TEST_OK_PREW,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012664 .probe = probe_spi_rdid,
12665 .probe_timing = TIMING_ZERO,
12666 .block_erasers =
12667 {
12668 {
12669 .eraseblocks = { {4 * 1024, 8192} },
12670 .block_erase = spi_block_erase_21,
12671 }, {
12672 .eraseblocks = { {4 * 1024, 8192} },
12673 .block_erase = spi_block_erase_20,
12674 }, {
12675 .eraseblocks = { {32 * 1024, 1024} },
12676 .block_erase = spi_block_erase_5c,
12677 }, {
12678 .eraseblocks = { {32 * 1024, 1024} },
12679 .block_erase = spi_block_erase_52,
12680 }, {
12681 .eraseblocks = { {64 * 1024, 512} },
12682 .block_erase = spi_block_erase_dc,
12683 }, {
12684 .eraseblocks = { {64 * 1024, 512} },
12685 .block_erase = spi_block_erase_d8,
12686 }, {
12687 .eraseblocks = { {32768 * 1024, 1} },
12688 .block_erase = spi_block_erase_c7,
12689 }, {
12690 .eraseblocks = { {32768 * 1024, 1} },
12691 .block_erase = spi_block_erase_60,
12692 }
12693 },
12694 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12695 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12696 .write = spi_chip_write_256, /* Multi I/O supported */
12697 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12698 .voltage = {1700, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020012699 .prepare_access = spi_prepare_io,
12700 .finish_access = spi_finish_io,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012701 },
12702
12703 {
12704 .vendor = "Micron",
Jacob Creedon08e9d1d2019-07-22 12:04:40 -070012705 .name = "MT25QL512", /* L = 3V, uniform 64KB/4KB blocks/sectors */
Ed Swierk199ab392017-07-03 13:33:44 -070012706 .bustype = BUS_SPI,
Alan Greenfa3fcd32019-06-27 15:41:50 +100012707 .manufacture_id = ST_ID,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012708 .model_id = ST_N25Q512__3G,
Ed Swierk199ab392017-07-03 13:33:44 -070012709 .total_size = 65536,
12710 .page_size = 256,
12711 /* supports SFDP */
12712 /* OTP: 64B total; read 0x4B, write 0x42 */
Nico Huberaac81422017-11-10 22:54:13 +010012713 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
Angel Pons3ed5a352018-09-30 16:31:09 +020012714 .tested = TEST_OK_PREW,
Ed Swierk199ab392017-07-03 13:33:44 -070012715 .probe = probe_spi_rdid,
12716 .probe_timing = TIMING_ZERO,
Alan Greenfdf5da42019-06-27 16:56:52 +100012717 .block_erasers =
12718 {
Ed Swierk199ab392017-07-03 13:33:44 -070012719 {
12720 .eraseblocks = { {4 * 1024, 16384} },
Nico Huber7e3c81a2017-10-14 18:56:50 +020012721 .block_erase = spi_block_erase_21,
Ed Swierk199ab392017-07-03 13:33:44 -070012722 }, {
Nico Huberaac81422017-11-10 22:54:13 +010012723 .eraseblocks = { {4 * 1024, 16384} },
12724 .block_erase = spi_block_erase_20,
12725 }, {
Jacob Creedon045b97e2019-07-22 12:26:56 -070012726 .eraseblocks = { {32 * 1024, 2048} },
12727 .block_erase = spi_block_erase_5c,
12728 }, {
12729 .eraseblocks = { {32 * 1024, 2048} },
12730 .block_erase = spi_block_erase_52,
12731 }, {
Ed Swierk199ab392017-07-03 13:33:44 -070012732 .eraseblocks = { {64 * 1024, 1024} },
Nico Huber7e3c81a2017-10-14 18:56:50 +020012733 .block_erase = spi_block_erase_dc,
Ed Swierk199ab392017-07-03 13:33:44 -070012734 }, {
Nico Huberaac81422017-11-10 22:54:13 +010012735 .eraseblocks = { {64 * 1024, 1024} },
12736 .block_erase = spi_block_erase_d8,
12737 }, {
Ed Swierk199ab392017-07-03 13:33:44 -070012738 .eraseblocks = { {65536 * 1024, 1} },
12739 .block_erase = spi_block_erase_c7,
Jacob Creedon045b97e2019-07-22 12:26:56 -070012740 }, {
12741 .eraseblocks = { {65536 * 1024, 1} },
12742 .block_erase = spi_block_erase_60,
Ed Swierk199ab392017-07-03 13:33:44 -070012743 }
12744 },
12745 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12746 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12747 .write = spi_chip_write_256, /* Multi I/O supported */
12748 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12749 .voltage = {2700, 3600},
Sergii Dmytrukd5ba24c2022-07-25 00:28:35 +030012750 .reg_bits =
12751 {
12752 .srp = {STATUS1, 7, RW},
12753 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}, {STATUS1, 6, RW}},
12754 .tb = {STATUS1, 5, RW},
12755 },
Nico Huberaabb3e02023-01-13 00:22:30 +010012756 .wp_write_cfg = spi_wp_write_cfg,
12757 .wp_read_cfg = spi_wp_read_cfg,
12758 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukd5ba24c2022-07-25 00:28:35 +030012759 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020012760 .prepare_access = spi_prepare_io,
12761 .finish_access = spi_finish_io,
Ed Swierk199ab392017-07-03 13:33:44 -070012762 },
12763
12764 {
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012765 .vendor = "Micron",
12766 .name = "MT25QU512", /* U = 1.8V, uniform 64KB/4KB blocks/sectors */
12767 .bustype = BUS_SPI,
12768 .manufacture_id = ST_ID,
12769 .model_id = ST_N25Q512__1G,
12770 .total_size = 65536,
12771 .page_size = 256,
12772 /* supports SFDP */
12773 /* OTP: 64B total; read 0x4B, write 0x42 */
12774 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA_WREN,
12775 .tested = TEST_OK_PREW,
12776 .probe = probe_spi_rdid,
12777 .probe_timing = TIMING_ZERO,
12778 .block_erasers =
12779 {
12780 {
12781 .eraseblocks = { {4 * 1024, 16384} },
12782 .block_erase = spi_block_erase_21,
12783 }, {
12784 .eraseblocks = { {4 * 1024, 16384} },
12785 .block_erase = spi_block_erase_20,
12786 }, {
12787 .eraseblocks = { {32 * 1024, 2048} },
12788 .block_erase = spi_block_erase_5c,
12789 }, {
12790 .eraseblocks = { {32 * 1024, 2048} },
12791 .block_erase = spi_block_erase_52,
12792 }, {
12793 .eraseblocks = { {64 * 1024, 1024} },
12794 .block_erase = spi_block_erase_dc,
12795 }, {
12796 .eraseblocks = { {64 * 1024, 1024} },
12797 .block_erase = spi_block_erase_d8,
12798 }, {
12799 .eraseblocks = { {65536 * 1024, 1} },
12800 .block_erase = spi_block_erase_c7,
12801 }, {
12802 .eraseblocks = { {65536 * 1024, 1} },
12803 .block_erase = spi_block_erase_60,
12804 }
12805 },
12806 .printlock = spi_prettyprint_status_register_n25q, /* TODO: config, lock, flag regs */
12807 .unlock = spi_disable_blockprotect_n25q, /* TODO: per 64kB sector lock registers */
12808 .write = spi_chip_write_256, /* Multi I/O supported */
12809 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
12810 .voltage = {1700, 2000},
Nico Huber930d4212024-05-04 18:59:15 +020012811 .prepare_access = spi_prepare_io,
12812 .finish_access = spi_finish_io,
Jacob Creedon80e8dc42019-07-22 12:35:30 -070012813 },
12814
12815 {
Mattias Mattsson4c066502010-07-29 20:01:13 +000012816 .vendor = "MoselVitelic",
12817 .name = "V29C51000B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000012818 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000012819 .manufacture_id = SYNCMOS_MVC_ID,
12820 .model_id = MVC_V29C51000B,
12821 .total_size = 64,
12822 .page_size = 512,
12823 .feature_bits = FEATURE_EITHER_RESET,
12824 .tested = TEST_UNTESTED,
12825 .probe = probe_jedec,
12826 .probe_timing = TIMING_ZERO,
12827 .block_erasers =
12828 {
12829 {
12830 .eraseblocks = { {512, 128} },
12831 .block_erase = erase_sector_jedec,
12832 }, {
12833 .eraseblocks = { {64 * 1024, 1} },
12834 .block_erase = erase_chip_block_jedec,
12835 },
12836 },
12837 .write = write_jedec_1,
12838 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000012839 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010012840 .prepare_access = prepare_memory_access,
12841 .finish_access = finish_memory_access,
Mattias Mattsson4c066502010-07-29 20:01:13 +000012842 },
12843
12844 {
12845 .vendor = "MoselVitelic",
12846 .name = "V29C51000T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000012847 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000012848 .manufacture_id = SYNCMOS_MVC_ID,
12849 .model_id = MVC_V29C51000T,
12850 .total_size = 64,
12851 .page_size = 512,
12852 .feature_bits = FEATURE_EITHER_RESET,
12853 .tested = TEST_UNTESTED,
12854 .probe = probe_jedec,
12855 .probe_timing = TIMING_ZERO,
12856 .block_erasers =
12857 {
12858 {
12859 .eraseblocks = { {512, 128} },
12860 .block_erase = erase_sector_jedec,
12861 }, {
12862 .eraseblocks = { {64 * 1024, 1} },
12863 .block_erase = erase_chip_block_jedec,
12864 },
12865 },
12866 .write = write_jedec_1,
12867 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000012868 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010012869 .prepare_access = prepare_memory_access,
12870 .finish_access = finish_memory_access,
Mattias Mattsson4c066502010-07-29 20:01:13 +000012871 },
12872
12873 {
12874 .vendor = "MoselVitelic",
12875 .name = "V29C51400B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000012876 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000012877 .manufacture_id = SYNCMOS_MVC_ID,
12878 .model_id = MVC_V29C51400B,
12879 .total_size = 512,
12880 .page_size = 1024,
12881 .feature_bits = FEATURE_EITHER_RESET,
12882 .tested = TEST_UNTESTED,
12883 .probe = probe_jedec,
12884 .probe_timing = TIMING_ZERO,
12885 .block_erasers =
12886 {
12887 {
12888 .eraseblocks = { {1024, 512} },
12889 .block_erase = erase_sector_jedec,
12890 }, {
12891 .eraseblocks = { {512 * 1024, 1} },
12892 .block_erase = erase_chip_block_jedec,
12893 },
12894 },
12895 .write = write_jedec_1,
12896 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000012897 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010012898 .prepare_access = prepare_memory_access,
12899 .finish_access = finish_memory_access,
Mattias Mattsson4c066502010-07-29 20:01:13 +000012900 },
12901
12902 {
12903 .vendor = "MoselVitelic",
12904 .name = "V29C51400T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000012905 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000012906 .manufacture_id = SYNCMOS_MVC_ID,
12907 .model_id = MVC_V29C51400T,
12908 .total_size = 512,
12909 .page_size = 1024,
12910 .feature_bits = FEATURE_EITHER_RESET,
12911 .tested = TEST_UNTESTED,
12912 .probe = probe_jedec,
12913 .probe_timing = TIMING_ZERO,
12914 .block_erasers =
12915 {
12916 {
12917 .eraseblocks = { {1024, 512} },
12918 .block_erase = erase_sector_jedec,
12919 }, {
12920 .eraseblocks = { {512 * 1024, 1} },
12921 .block_erase = erase_chip_block_jedec,
12922 },
12923 },
12924 .write = write_jedec_1,
12925 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000012926 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010012927 .prepare_access = prepare_memory_access,
12928 .finish_access = finish_memory_access,
Mattias Mattsson4c066502010-07-29 20:01:13 +000012929 },
12930
12931 {
12932 .vendor = "MoselVitelic",
12933 .name = "V29LC51000",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000012934 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000012935 .manufacture_id = SYNCMOS_MVC_ID,
12936 .model_id = MVC_V29LC51000,
12937 .total_size = 64,
12938 .page_size = 512,
12939 .feature_bits = FEATURE_EITHER_RESET,
12940 .tested = TEST_UNTESTED,
12941 .probe = probe_jedec,
12942 .probe_timing = TIMING_ZERO,
12943 .block_erasers =
12944 {
12945 {
12946 .eraseblocks = { {512, 128} },
12947 .block_erase = erase_sector_jedec,
12948 }, {
12949 .eraseblocks = { {64 * 1024, 1} },
12950 .block_erase = erase_chip_block_jedec,
12951 },
12952 },
12953 .write = write_jedec_1,
12954 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000012955 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010012956 .prepare_access = prepare_memory_access,
12957 .finish_access = finish_memory_access,
Mattias Mattsson4c066502010-07-29 20:01:13 +000012958 },
12959
12960 {
12961 .vendor = "MoselVitelic",
12962 .name = "V29LC51001",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000012963 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000012964 .manufacture_id = SYNCMOS_MVC_ID,
12965 .model_id = MVC_V29LC51001,
12966 .total_size = 128,
12967 .page_size = 512,
12968 .feature_bits = FEATURE_EITHER_RESET,
12969 .tested = TEST_UNTESTED,
12970 .probe = probe_jedec,
12971 .probe_timing = TIMING_ZERO,
12972 .block_erasers =
12973 {
12974 {
12975 .eraseblocks = { {512, 256} },
12976 .block_erase = erase_sector_jedec,
12977 }, {
12978 .eraseblocks = { {128 * 1024, 1} },
12979 .block_erase = erase_chip_block_jedec,
12980 },
12981 },
12982 .write = write_jedec_1,
12983 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000012984 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010012985 .prepare_access = prepare_memory_access,
12986 .finish_access = finish_memory_access,
Mattias Mattsson4c066502010-07-29 20:01:13 +000012987 },
12988
12989 {
12990 .vendor = "MoselVitelic",
12991 .name = "V29LC51002",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000012992 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000012993 .manufacture_id = SYNCMOS_MVC_ID,
12994 .model_id = MVC_V29LC51002,
12995 .total_size = 256,
12996 .page_size = 512,
12997 .feature_bits = FEATURE_EITHER_RESET,
12998 .tested = TEST_UNTESTED,
12999 .probe = probe_jedec,
13000 .probe_timing = TIMING_ZERO,
13001 .block_erasers =
13002 {
13003 {
13004 .eraseblocks = { {512, 512} },
13005 .block_erase = erase_sector_jedec,
13006 }, {
13007 .eraseblocks = { {256 * 1024, 1} },
13008 .block_erase = erase_chip_block_jedec,
13009 },
13010 },
13011 .write = write_jedec_1,
13012 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000013013 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010013014 .prepare_access = prepare_memory_access,
13015 .finish_access = finish_memory_access,
Mattias Mattsson4c066502010-07-29 20:01:13 +000013016 },
13017
13018 {
Stefan Taunerb6b00e92013-06-28 21:28:43 +000013019 .vendor = "Nantronics",
13020 .name = "N25S10",
13021 .bustype = BUS_SPI,
13022 .manufacture_id = NANTRONICS_ID_NOPREFIX,
13023 .model_id = NANTRONICS_N25S10,
13024 .total_size = 128,
13025 .page_size = 256,
13026 .feature_bits = FEATURE_WRSR_WREN,
13027 .tested = TEST_UNTESTED,
13028 .probe = probe_spi_rdid,
13029 .probe_timing = TIMING_ZERO,
13030 .block_erasers =
13031 {
13032 {
13033 .eraseblocks = { {4 * 1024, 32} },
13034 .block_erase = spi_block_erase_20,
13035 }, {
13036 .eraseblocks = { {4 * 1024, 32} },
13037 .block_erase = spi_block_erase_d7,
13038 }, {
13039 .eraseblocks = { {32 * 1024, 4} },
13040 .block_erase = spi_block_erase_52,
13041 }, {
13042 .eraseblocks = { {64 * 1024, 2} },
13043 .block_erase = spi_block_erase_d8,
13044 }, {
13045 .eraseblocks = { {128 * 1024, 1} },
13046 .block_erase = spi_block_erase_60,
13047 }, {
13048 .eraseblocks = { {128 * 1024, 1} },
13049 .block_erase = spi_block_erase_c7,
13050 }
13051 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000013052 .printlock = spi_prettyprint_status_register_bp3_srwd,
Stefan Taunerb6b00e92013-06-28 21:28:43 +000013053 .unlock = spi_disable_blockprotect_bp3_srwd,
13054 .write = spi_chip_write_256,
13055 .read = spi_chip_read, /* Fast read (0x0B), dual I/O read (0x3B) supported */
13056 .voltage = {2700, 3600},
13057 },
13058
13059 {
13060 .vendor = "Nantronics",
Alan Green1f9cc7d2019-07-01 11:10:45 +100013061 .name = "N25S16",
13062 .bustype = BUS_SPI,
13063 .manufacture_id = NANTRONICS_ID_NOPREFIX,
13064 .model_id = NANTRONICS_N25S16,
13065 .total_size = 2048,
13066 .page_size = 256,
13067 .feature_bits = FEATURE_WRSR_WREN,
13068 .tested = TEST_UNTESTED,
13069 .probe = probe_spi_rdid,
13070 .probe_timing = TIMING_ZERO,
13071 .block_erasers =
13072 {
13073 {
13074 .eraseblocks = { {4 * 1024, 512} },
13075 .block_erase = spi_block_erase_20,
13076 }, {
13077 .eraseblocks = { {64 * 1024, 32} },
13078 .block_erase = spi_block_erase_d8,
13079 }, {
13080 .eraseblocks = { {2048 * 1024, 1} },
13081 .block_erase = spi_block_erase_60,
13082 }, {
13083 .eraseblocks = { {2048 * 1024, 1} },
13084 .block_erase = spi_block_erase_c7,
13085 }
13086 },
13087 .printlock = spi_prettyprint_status_register_bp3_srwd,
13088 .unlock = spi_disable_blockprotect_bp3_srwd,
13089 .write = spi_chip_write_256,
13090 .read = spi_chip_read, /* Fast read (0x0B), dual I/O read (0x3B) supported */
13091 .voltage = {2700, 3600},
13092 },
13093
13094 {
13095 .vendor = "Nantronics",
Stefan Taunerb6b00e92013-06-28 21:28:43 +000013096 .name = "N25S20",
13097 .bustype = BUS_SPI,
13098 .manufacture_id = NANTRONICS_ID_NOPREFIX,
13099 .model_id = NANTRONICS_N25S20,
13100 .total_size = 256,
13101 .page_size = 256,
13102 .feature_bits = FEATURE_WRSR_WREN,
13103 .tested = TEST_UNTESTED,
13104 .probe = probe_spi_rdid,
13105 .probe_timing = TIMING_ZERO,
13106 .block_erasers =
13107 {
13108 {
13109 .eraseblocks = { {4 * 1024, 64} },
13110 .block_erase = spi_block_erase_20,
13111 }, {
13112 .eraseblocks = { {4 * 1024, 64} },
13113 .block_erase = spi_block_erase_d7,
13114 }, {
13115 .eraseblocks = { {32 * 1024, 8} },
13116 .block_erase = spi_block_erase_52,
13117 }, {
13118 .eraseblocks = { {64 * 1024, 4} },
13119 .block_erase = spi_block_erase_d8,
13120 }, {
13121 .eraseblocks = { {256 * 1024, 1} },
13122 .block_erase = spi_block_erase_60,
13123 }, {
13124 .eraseblocks = { {256 * 1024, 1} },
13125 .block_erase = spi_block_erase_c7,
13126 }
13127 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000013128 .printlock = spi_prettyprint_status_register_bp3_srwd,
Stefan Taunerb6b00e92013-06-28 21:28:43 +000013129 .unlock = spi_disable_blockprotect_bp3_srwd,
13130 .write = spi_chip_write_256,
13131 .read = spi_chip_read, /* Fast read (0x0B), dual I/O read (0x3B) supported */
13132 .voltage = {2700, 3600},
13133 },
13134
13135 {
13136 .vendor = "Nantronics",
13137 .name = "N25S40",
13138 .bustype = BUS_SPI,
13139 .manufacture_id = NANTRONICS_ID_NOPREFIX,
13140 .model_id = NANTRONICS_N25S40,
13141 .total_size = 512,
13142 .page_size = 256,
13143 .feature_bits = FEATURE_WRSR_WREN,
13144 .tested = TEST_UNTESTED,
13145 .probe = probe_spi_rdid,
13146 .probe_timing = TIMING_ZERO,
13147 .block_erasers =
13148 {
13149 {
13150 .eraseblocks = { {4 * 1024, 128} },
13151 .block_erase = spi_block_erase_20,
13152 }, {
13153 .eraseblocks = { {4 * 1024, 128} },
13154 .block_erase = spi_block_erase_d7,
13155 }, {
13156 .eraseblocks = { {32 * 1024, 16} },
13157 .block_erase = spi_block_erase_52,
13158 }, {
13159 .eraseblocks = { {64 * 1024, 8} },
13160 .block_erase = spi_block_erase_d8,
13161 }, {
13162 .eraseblocks = { {512 * 1024, 1} },
13163 .block_erase = spi_block_erase_60,
13164 }, {
13165 .eraseblocks = { {512 * 1024, 1} },
13166 .block_erase = spi_block_erase_c7,
13167 }
13168 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000013169 .printlock = spi_prettyprint_status_register_bp3_srwd,
Stefan Taunerb6b00e92013-06-28 21:28:43 +000013170 .unlock = spi_disable_blockprotect_bp3_srwd,
13171 .write = spi_chip_write_256,
13172 .read = spi_chip_read, /* Fast read (0x0B), dual I/O read (0x3B) supported */
13173 .voltage = {2700, 3600},
13174 },
13175
13176 {
13177 .vendor = "Nantronics",
13178 .name = "N25S80",
13179 .bustype = BUS_SPI,
13180 .manufacture_id = NANTRONICS_ID_NOPREFIX,
13181 .model_id = NANTRONICS_N25S80,
13182 .total_size = 1024,
13183 .page_size = 256,
13184 .feature_bits = FEATURE_WRSR_WREN,
13185 .tested = TEST_UNTESTED,
13186 .probe = probe_spi_rdid,
13187 .probe_timing = TIMING_ZERO,
13188 .block_erasers =
13189 {
13190 {
13191 .eraseblocks = { {4 * 1024, 256} },
13192 .block_erase = spi_block_erase_20,
13193 }, {
13194 .eraseblocks = { {32 * 1024, 32} },
13195 .block_erase = spi_block_erase_52,
13196 }, {
13197 .eraseblocks = { {64 * 1024, 16} },
13198 .block_erase = spi_block_erase_d8,
13199 }, {
13200 .eraseblocks = { {1024 * 1024, 1} },
13201 .block_erase = spi_block_erase_60,
13202 }, {
13203 .eraseblocks = { {1024 * 1024, 1} },
13204 .block_erase = spi_block_erase_c7,
13205 }
13206 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000013207 .printlock = spi_prettyprint_status_register_bp3_srwd,
Stefan Taunerb6b00e92013-06-28 21:28:43 +000013208 .unlock = spi_disable_blockprotect_bp3_srwd,
13209 .write = spi_chip_write_256,
13210 .read = spi_chip_read, /* Fast read (0x0B), dual I/O read (0x3B) supported */
13211 .voltage = {2700, 3600},
13212 },
13213
13214 {
Stefan Taunerf4451612013-04-19 01:59:15 +000013215 .vendor = "PMC",
13216 .name = "Pm25LD010(C)",
13217 .bustype = BUS_SPI,
13218 .manufacture_id = PMC_ID,
13219 .model_id = PMC_PM25LD010,
13220 .total_size = 128,
13221 .page_size = 256,
13222 .feature_bits = FEATURE_WRSR_WREN,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +000013223 .tested = TEST_OK_PREW,
Stefan Taunerf4451612013-04-19 01:59:15 +000013224 .probe = probe_spi_rdid,
13225 .probe_timing = TIMING_ZERO,
13226 .block_erasers =
13227 {
13228 {
13229 .eraseblocks = { {4 * 1024, 32} },
13230 .block_erase = spi_block_erase_20,
13231 }, {
13232 .eraseblocks = { {4 * 1024, 32} },
13233 .block_erase = spi_block_erase_d7,
13234 }, {
13235 .eraseblocks = { {32 * 1024, 4} },
13236 .block_erase = spi_block_erase_d8,
13237 }, {
13238 .eraseblocks = { {128 * 1024, 1} },
13239 .block_erase = spi_block_erase_60,
13240 }, {
13241 .eraseblocks = { {128 * 1024, 1} },
13242 .block_erase = spi_block_erase_c7,
13243 }
13244 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000013245 .printlock = spi_prettyprint_status_register_bp2_srwd,
Stefan Taunerf4451612013-04-19 01:59:15 +000013246 .unlock = spi_disable_blockprotect, /* FIXME: C version supports "Safe Guard" */
13247 .write = spi_chip_write_256,
13248 .read = spi_chip_read, /* Fast read (0x0B), dual I/O supported */
13249 .voltage = {2700, 3600}, /* 2.3-3.6V for Pm25LD010 */
13250 },
13251
13252 {
13253 .vendor = "PMC",
13254 .name = "Pm25LD020(C)",
13255 .bustype = BUS_SPI,
13256 .manufacture_id = PMC_ID,
13257 .model_id = PMC_PM25LD020,
13258 .total_size = 256,
13259 .page_size = 256,
13260 .feature_bits = FEATURE_WRSR_WREN,
Angel Ponsf5822a82018-09-30 20:09:58 +020013261 .tested = TEST_OK_PREW,
Stefan Taunerf4451612013-04-19 01:59:15 +000013262 .probe = probe_spi_rdid,
13263 .probe_timing = TIMING_ZERO,
13264 .block_erasers =
13265 {
13266 {
13267 .eraseblocks = { {4 * 1024, 64} },
13268 .block_erase = spi_block_erase_20,
13269 }, {
13270 .eraseblocks = { {4 * 1024, 64} },
13271 .block_erase = spi_block_erase_d7,
13272 }, {
13273 .eraseblocks = { {64 * 1024, 4} },
13274 .block_erase = spi_block_erase_d8,
13275 }, {
13276 .eraseblocks = { {256 * 1024, 1} },
13277 .block_erase = spi_block_erase_60,
13278 }, {
13279 .eraseblocks = { {256 * 1024, 1} },
13280 .block_erase = spi_block_erase_c7,
13281 }
13282 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000013283 .printlock = spi_prettyprint_status_register_bp2_srwd,
Stefan Taunerf4451612013-04-19 01:59:15 +000013284 .unlock = spi_disable_blockprotect, /* FIXME: C version supports "Safe Guard" */
13285 .write = spi_chip_write_256,
13286 .read = spi_chip_read, /* Fast read (0x0B), dual I/O supported */
13287 .voltage = {2700, 3600}, /* 2.3-3.6V for Pm25LD020 */
13288 },
13289
13290 {
13291 .vendor = "PMC",
13292 .name = "Pm25LD040(C)",
13293 .bustype = BUS_SPI,
13294 .manufacture_id = PMC_ID,
13295 .model_id = PMC_PM25LV040,
13296 .total_size = 512,
13297 .page_size = 256,
13298 .feature_bits = FEATURE_WRSR_WREN,
Angel Pons05127bf2018-09-30 20:23:24 +020013299 .tested = TEST_OK_PREW,
Stefan Taunerf4451612013-04-19 01:59:15 +000013300 .probe = probe_spi_rdid,
13301 .probe_timing = TIMING_ZERO,
13302 .block_erasers =
13303 {
13304 {
13305 .eraseblocks = { {4 * 1024, 128} },
13306 .block_erase = spi_block_erase_20,
13307 }, {
13308 .eraseblocks = { {4 * 1024, 128} },
13309 .block_erase = spi_block_erase_d7,
13310 }, {
13311 .eraseblocks = { {64 * 1024, 8} },
13312 .block_erase = spi_block_erase_d8,
13313 }, {
13314 .eraseblocks = { {512 * 1024, 1} },
13315 .block_erase = spi_block_erase_60,
13316 }, {
13317 .eraseblocks = { {512 * 1024, 1} },
13318 .block_erase = spi_block_erase_c7,
13319 }
13320 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000013321 .printlock = spi_prettyprint_status_register_bp2_srwd,
Stefan Taunerf4451612013-04-19 01:59:15 +000013322 .unlock = spi_disable_blockprotect,
13323 .write = spi_chip_write_256,
13324 .read = spi_chip_read, /* Fast read (0x0B), dual I/O supported */
13325 .voltage = {2700, 3600}, /* 2.3-3.6V for Pm25LD040 */
13326 },
13327
Steven Honeyman81a8fb72015-06-02 22:32:24 +000013328 {
13329 .vendor = "PMC",
Alan Green1f9cc7d2019-07-01 11:10:45 +100013330 .name = "Pm25LD256C",
13331 .bustype = BUS_SPI,
13332 .manufacture_id = PMC_ID,
13333 .model_id = PMC_PM25LD256C,
13334 .total_size = 32,
13335 .page_size = 256,
13336 .feature_bits = FEATURE_WRSR_WREN,
13337 .tested = TEST_UNTESTED,
13338 .probe = probe_spi_rdid,
13339 .probe_timing = TIMING_ZERO,
13340 .block_erasers =
13341 {
13342 {
13343 .eraseblocks = { {4 * 1024, 8} },
13344 .block_erase = spi_block_erase_20,
13345 }, {
13346 .eraseblocks = { {4 * 1024, 8} },
13347 .block_erase = spi_block_erase_d7,
13348 }, {
13349 .eraseblocks = { {32 * 1024, 1} },
13350 .block_erase = spi_block_erase_d8,
13351 }, {
13352 .eraseblocks = { {32 * 1024, 1} },
13353 .block_erase = spi_block_erase_60,
13354 }, {
13355 .eraseblocks = { {32 * 1024, 1} },
13356 .block_erase = spi_block_erase_c7,
13357 }
13358 },
13359 .printlock = spi_prettyprint_status_register_bp2_srwd,
13360 .unlock = spi_disable_blockprotect,
13361 .write = spi_chip_write_256,
13362 .read = spi_chip_read, /* Fast read (0x0B), dual I/O supported */
13363 .voltage = {2700, 3600},
13364 },
13365
13366 {
13367 .vendor = "PMC",
13368 .name = "Pm25LD512(C)",
13369 .bustype = BUS_SPI,
13370 .manufacture_id = PMC_ID,
13371 .model_id = PMC_PM25LD512,
13372 .total_size = 64,
13373 .page_size = 256,
13374 .feature_bits = FEATURE_WRSR_WREN,
13375 .tested = TEST_OK_PREW,
13376 .probe = probe_spi_rdid,
13377 .probe_timing = TIMING_ZERO,
13378 .block_erasers =
13379 {
13380 {
13381 .eraseblocks = { {4 * 1024, 16} },
13382 .block_erase = spi_block_erase_20,
13383 }, {
13384 .eraseblocks = { {4 * 1024, 16} },
13385 .block_erase = spi_block_erase_d7,
13386 }, {
13387 .eraseblocks = { {32 * 1024, 2} },
13388 .block_erase = spi_block_erase_d8,
13389 }, {
13390 .eraseblocks = { {64 * 1024, 1} },
13391 .block_erase = spi_block_erase_60,
13392 }, {
13393 .eraseblocks = { {64 * 1024, 1} },
13394 .block_erase = spi_block_erase_c7,
13395 }
13396 },
13397 .printlock = spi_prettyprint_status_register_bp2_srwd,
13398 .unlock = spi_disable_blockprotect, /* FIXME: C version supports "Safe Guard" */
13399 .write = spi_chip_write_256,
13400 .read = spi_chip_read, /* Fast read (0x0B), dual I/O supported */
13401 .voltage = {2300, 3600},
13402 },
13403
13404 {
13405 .vendor = "PMC",
13406 .name = "Pm25LQ016",
13407 .bustype = BUS_SPI,
13408 .manufacture_id = PMC_ID,
13409 .model_id = PMC_PM25LQ016,
13410 .total_size = 2048,
13411 .page_size = 256,
13412 /* OTP: 256B total; read 0x4B, write 0xB1 */
13413 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
13414 .tested = TEST_UNTESTED,
13415 .probe = probe_spi_rdid,
13416 .probe_timing = TIMING_ZERO,
13417 .block_erasers =
13418 {
13419 {
13420 .eraseblocks = { {4 * 1024, 512} },
13421 .block_erase = spi_block_erase_20,
13422 }, {
13423 .eraseblocks = { {4 * 1024, 512} },
13424 .block_erase = spi_block_erase_d7,
13425 }, {
13426 .eraseblocks = { {64 * 1024, 32} },
13427 .block_erase = spi_block_erase_d8,
13428 }, {
13429 .eraseblocks = { {2048 * 1024, 1} },
13430 .block_erase = spi_block_erase_60,
13431 }, {
13432 .eraseblocks = { {2048 * 1024, 1} },
13433 .block_erase = spi_block_erase_c7,
13434 }
13435 },
13436 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enable */
13437 .unlock = spi_disable_blockprotect_bp3_srwd,
13438 .write = spi_chip_write_256,
13439 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
13440 .voltage = {2300, 3600},
13441 },
13442
13443 {
13444 .vendor = "PMC",
Steven Honeyman81a8fb72015-06-02 22:32:24 +000013445 .name = "Pm25LQ020",
13446 .bustype = BUS_SPI,
13447 .manufacture_id = PMC_ID,
13448 .model_id = PMC_PM25LQ020,
13449 .total_size = 256,
13450 .page_size = 256,
13451 /* OTP: 256B total; read 0x4B, write 0xB1 */
13452 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
13453 .tested = TEST_UNTESTED,
13454 .probe = probe_spi_rdid,
13455 .probe_timing = TIMING_ZERO,
13456 .block_erasers =
13457 {
13458 {
13459 .eraseblocks = { {4 * 1024, 64} },
13460 .block_erase = spi_block_erase_20,
13461 }, {
13462 .eraseblocks = { {4 * 1024, 64} },
13463 .block_erase = spi_block_erase_d7,
13464 }, {
13465 .eraseblocks = { {64 * 1024, 4} },
13466 .block_erase = spi_block_erase_d8,
13467 }, {
13468 .eraseblocks = { {256 * 1024, 1} },
13469 .block_erase = spi_block_erase_60,
13470 }, {
13471 .eraseblocks = { {256 * 1024, 1} },
13472 .block_erase = spi_block_erase_c7,
13473 }
13474 },
13475 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enable */
13476 .unlock = spi_disable_blockprotect_bp3_srwd,
13477 .write = spi_chip_write_256,
13478 .read = spi_chip_read,
13479 .voltage = {2300, 3600},
13480 },
13481
13482 {
13483 .vendor = "PMC",
Alan Green1f9cc7d2019-07-01 11:10:45 +100013484 .name = "Pm25LQ032C",
13485 .bustype = BUS_SPI,
13486 .manufacture_id = PMC_ID,
13487 .model_id = PMC_PM25LQ032C,
13488 .total_size = 4096,
13489 .page_size = 256,
13490 /* OTP: 64B total; read 0x4B, write 0xB1 */
13491 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
13492 .tested = TEST_OK_PREW,
13493 .probe = probe_spi_rdid,
13494 .probe_timing = TIMING_ZERO,
13495 .block_erasers =
13496 {
13497 {
13498 .eraseblocks = { {4 * 1024, 1024} },
13499 .block_erase = spi_block_erase_20,
13500 }, {
13501 .eraseblocks = { {4 * 1024, 1024} },
13502 .block_erase = spi_block_erase_d7,
13503 }, {
13504 .eraseblocks = { {64 * 1024, 64} },
13505 .block_erase = spi_block_erase_d8,
13506 }, {
13507 .eraseblocks = { {4096 * 1024, 1} },
13508 .block_erase = spi_block_erase_60,
13509 }, {
13510 .eraseblocks = { {4096 * 1024, 1} },
13511 .block_erase = spi_block_erase_c7,
13512 }
13513 },
13514 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enable */
13515 .unlock = spi_disable_blockprotect_bp3_srwd,
13516 .write = spi_chip_write_256,
13517 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
13518 .voltage = {2700, 3600},
13519 },
13520
13521 {
13522 .vendor = "PMC",
Steven Honeyman81a8fb72015-06-02 22:32:24 +000013523 .name = "Pm25LQ040",
13524 .bustype = BUS_SPI,
13525 .manufacture_id = PMC_ID,
13526 .model_id = PMC_PM25LQ040,
13527 .total_size = 512,
13528 .page_size = 256,
13529 /* OTP: 256B total; read 0x4B, write 0xB1 */
13530 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
13531 .tested = TEST_UNTESTED,
13532 .probe = probe_spi_rdid,
13533 .probe_timing = TIMING_ZERO,
13534 .block_erasers =
13535 {
13536 {
13537 .eraseblocks = { {4 * 1024, 128} },
13538 .block_erase = spi_block_erase_20,
13539 }, {
13540 .eraseblocks = { {4 * 1024, 128} },
13541 .block_erase = spi_block_erase_d7,
13542 }, {
13543 .eraseblocks = { {64 * 1024, 8} },
13544 .block_erase = spi_block_erase_d8,
13545 }, {
13546 .eraseblocks = { {512 * 1024, 1} },
13547 .block_erase = spi_block_erase_60,
13548 }, {
13549 .eraseblocks = { {512 * 1024, 1} },
13550 .block_erase = spi_block_erase_c7,
13551 }
13552 },
13553 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enable */
13554 .unlock = spi_disable_blockprotect_bp3_srwd,
13555 .write = spi_chip_write_256,
13556 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
13557 .voltage = {2300, 3600},
13558 },
13559
13560 {
13561 .vendor = "PMC",
13562 .name = "Pm25LQ080",
13563 .bustype = BUS_SPI,
13564 .manufacture_id = PMC_ID,
13565 .model_id = PMC_PM25LQ080,
13566 .total_size = 1024,
13567 .page_size = 256,
13568 /* OTP: 64B total; read 0x4B, write 0xB1 */
13569 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
13570 .tested = TEST_UNTESTED,
13571 .probe = probe_spi_rdid,
13572 .probe_timing = TIMING_ZERO,
13573 .block_erasers =
13574 {
13575 {
13576 .eraseblocks = { {4 * 1024, 256} },
13577 .block_erase = spi_block_erase_20,
13578 }, {
13579 .eraseblocks = { {4 * 1024, 256} },
13580 .block_erase = spi_block_erase_d7,
13581 }, {
13582 .eraseblocks = { {64 * 1024, 16} },
13583 .block_erase = spi_block_erase_d8,
13584 }, {
13585 .eraseblocks = { {1024 * 1024, 1} },
13586 .block_erase = spi_block_erase_60,
13587 }, {
13588 .eraseblocks = { {1024 * 1024, 1} },
13589 .block_erase = spi_block_erase_c7,
13590 }
13591 },
13592 .printlock = spi_prettyprint_status_register_bp3_srwd, /* bit6 is quad enable */
13593 .unlock = spi_disable_blockprotect_bp3_srwd,
13594 .write = spi_chip_write_256,
13595 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
13596 .voltage = {2300, 3600},
13597 },
13598
13599 {
13600 .vendor = "PMC",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013601 .name = "Pm25LV010",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000013602 .bustype = BUS_SPI,
Stefan Taunerbecda742014-05-30 19:34:00 +000013603 .manufacture_id = PMC_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000013604 .model_id = PMC_PM25LV010,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013605 .total_size = 128,
13606 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +000013607 .feature_bits = FEATURE_WRSR_WREN,
Stefan Taunerbecda742014-05-30 19:34:00 +000013608 .tested = TEST_OK_PREW,
13609 .probe = probe_spi_res2, /* The continuation code is transferred as the 3rd byte m( */
Stefan Tauner3f5e35d2013-04-19 01:58:33 +000013610 .probe_timing = TIMING_ZERO,
13611 .block_erasers =
13612 {
13613 {
13614 .eraseblocks = { {4 * 1024, 32} },
13615 .block_erase = spi_block_erase_d7,
13616 }, {
13617 .eraseblocks = { {32 * 1024, 4} },
13618 .block_erase = spi_block_erase_d8,
13619 }, {
13620 .eraseblocks = { {128 * 1024, 1} },
13621 .block_erase = spi_block_erase_c7,
13622 }
13623 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000013624 .printlock = spi_prettyprint_status_register_bp1_srwd,
Stefan Tauner3f5e35d2013-04-19 01:58:33 +000013625 .unlock = spi_disable_blockprotect,
13626 .write = spi_chip_write_256,
13627 .read = spi_chip_read, /* Fast read (0x0B) supported */
13628 .voltage = {2700, 3600},
13629 },
13630
13631 {
13632 .vendor = "PMC",
13633 .name = "Pm25LV010A",
13634 .bustype = BUS_SPI,
13635 .manufacture_id = PMC_ID,
13636 .model_id = PMC_PM25LV010,
13637 .total_size = 128,
13638 .page_size = 256,
13639 .feature_bits = FEATURE_WRSR_WREN,
13640 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013641 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000013642 .probe_timing = TIMING_ZERO,
Sean Nelson5643c072010-01-19 03:23:07 +000013643 .block_erasers =
13644 {
13645 {
13646 .eraseblocks = { {4 * 1024, 32} },
13647 .block_erase = spi_block_erase_d7,
13648 }, {
13649 .eraseblocks = { {32 * 1024, 4} },
13650 .block_erase = spi_block_erase_d8,
13651 }, {
13652 .eraseblocks = { {128 * 1024, 1} },
13653 .block_erase = spi_block_erase_c7,
13654 }
13655 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000013656 .printlock = spi_prettyprint_status_register_bp1_srwd,
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +000013657 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +000013658 .write = spi_chip_write_256,
Stefan Tauner3f5e35d2013-04-19 01:58:33 +000013659 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakulec7d257b42011-07-19 08:50:18 +000013660 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +000013661 },
13662
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013663 {
13664 .vendor = "PMC",
Alan Green1f9cc7d2019-07-01 11:10:45 +100013665 .name = "Pm25LV016B",
13666 .bustype = BUS_SPI,
13667 .manufacture_id = PMC_ID,
13668 .model_id = PMC_PM25LV016B,
13669 .total_size = 2048,
13670 .page_size = 256,
13671 .feature_bits = FEATURE_WRSR_WREN,
13672 .tested = TEST_UNTESTED,
13673 .probe = probe_spi_rdid,
13674 .probe_timing = TIMING_ZERO,
13675 .block_erasers =
13676 {
13677 {
13678 .eraseblocks = { {4 * 1024, 512} },
13679 .block_erase = spi_block_erase_d7,
13680 }, {
13681 .eraseblocks = { {4 * 1024, 512} },
13682 .block_erase = spi_block_erase_20,
13683 }, {
13684 .eraseblocks = { {64 * 1024, 32} },
13685 .block_erase = spi_block_erase_d8,
13686 }, {
13687 .eraseblocks = { {2 * 1024 * 1024, 1} },
13688 .block_erase = spi_block_erase_60,
13689 }, {
13690 .eraseblocks = { {2 * 1024 * 1024, 1} },
13691 .block_erase = spi_block_erase_c7,
13692 }
13693 },
13694 .printlock = spi_prettyprint_status_register_bp2_srwd,
13695 .unlock = spi_disable_blockprotect,
13696 .write = spi_chip_write_256,
13697 .read = spi_chip_read, /* Fast read (0x0B) supported */
13698 .voltage = {2700, 3600},
13699 },
13700
13701 {
13702 .vendor = "PMC",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013703 .name = "Pm25LV020",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000013704 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013705 .manufacture_id = PMC_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000013706 .model_id = PMC_PM25LV020,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013707 .total_size = 256,
13708 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +000013709 .feature_bits = FEATURE_WRSR_WREN,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013710 .tested = TEST_UNTESTED,
13711 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000013712 .probe_timing = TIMING_ZERO,
Sean Nelson5643c072010-01-19 03:23:07 +000013713 .block_erasers =
13714 {
13715 {
13716 .eraseblocks = { {4 * 1024, 64} },
13717 .block_erase = spi_block_erase_d7,
13718 }, {
13719 .eraseblocks = { {64 * 1024, 4} },
13720 .block_erase = spi_block_erase_d8,
13721 }, {
13722 .eraseblocks = { {256 * 1024, 1} },
13723 .block_erase = spi_block_erase_c7,
13724 }
13725 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000013726 .printlock = spi_prettyprint_status_register_bp2_srwd,
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +000013727 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +000013728 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013729 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000013730 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +000013731 },
13732
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013733 {
13734 .vendor = "PMC",
13735 .name = "Pm25LV040",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000013736 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013737 .manufacture_id = PMC_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000013738 .model_id = PMC_PM25LV040,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013739 .total_size = 512,
13740 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +000013741 .feature_bits = FEATURE_WRSR_WREN,
Stefan Tauner716e0982011-07-25 20:38:52 +000013742 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013743 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000013744 .probe_timing = TIMING_ZERO,
Sean Nelson5643c072010-01-19 03:23:07 +000013745 .block_erasers =
13746 {
13747 {
13748 .eraseblocks = { {4 * 1024, 128} },
13749 .block_erase = spi_block_erase_d7,
13750 }, {
13751 .eraseblocks = { {64 * 1024, 8} },
13752 .block_erase = spi_block_erase_d8,
13753 }, {
13754 .eraseblocks = { {512 * 1024, 1} },
13755 .block_erase = spi_block_erase_c7,
13756 }
13757 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000013758 .printlock = spi_prettyprint_status_register_bp2_srwd,
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +000013759 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +000013760 .write = spi_chip_write_256,
Stefan Tauner3f5e35d2013-04-19 01:58:33 +000013761 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +000013762 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +000013763 },
13764
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013765 {
13766 .vendor = "PMC",
13767 .name = "Pm25LV080B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000013768 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013769 .manufacture_id = PMC_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000013770 .model_id = PMC_PM25LV080B,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013771 .total_size = 1024,
13772 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +000013773 .feature_bits = FEATURE_WRSR_WREN,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013774 .tested = TEST_UNTESTED,
13775 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000013776 .probe_timing = TIMING_ZERO,
Sean Nelson5643c072010-01-19 03:23:07 +000013777 .block_erasers =
13778 {
13779 {
13780 .eraseblocks = { {4 * 1024, 256} },
13781 .block_erase = spi_block_erase_d7,
13782 }, {
13783 .eraseblocks = { {4 * 1024, 256} },
13784 .block_erase = spi_block_erase_20,
13785 }, {
13786 .eraseblocks = { {64 * 1024, 16} },
13787 .block_erase = spi_block_erase_d8,
13788 }, {
13789 .eraseblocks = { {1024 * 1024, 1} },
13790 .block_erase = spi_block_erase_60,
13791 }, {
13792 .eraseblocks = { {1024 * 1024, 1} },
13793 .block_erase = spi_block_erase_c7,
13794 }
13795 },
Stefan Tauner12f3d512014-05-27 21:27:27 +000013796 .printlock = spi_prettyprint_status_register_bp2_srwd,
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +000013797 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +000013798 .write = spi_chip_write_256,
Stefan Tauner3f5e35d2013-04-19 01:58:33 +000013799 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakuleccbe370e2011-06-03 07:26:31 +000013800 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +000013801 },
13802
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013803 {
13804 .vendor = "PMC",
Alan Green1f9cc7d2019-07-01 11:10:45 +100013805 .name = "Pm25LV512(A)",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000013806 .bustype = BUS_SPI,
Alan Green1f9cc7d2019-07-01 11:10:45 +100013807 .manufacture_id = PMC_ID_NOPREFIX,
13808 .model_id = PMC_PM25LV512,
13809 .total_size = 64,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013810 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +000013811 .feature_bits = FEATURE_WRSR_WREN,
Alan Green1f9cc7d2019-07-01 11:10:45 +100013812 .tested = TEST_OK_PREW,
13813 .probe = probe_spi_res2, /* The continuation code is transferred as the 3rd byte m( */
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000013814 .probe_timing = TIMING_ZERO,
Sean Nelson5643c072010-01-19 03:23:07 +000013815 .block_erasers =
13816 {
13817 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100013818 .eraseblocks = { {4 * 1024, 16} },
Sean Nelson5643c072010-01-19 03:23:07 +000013819 .block_erase = spi_block_erase_d7,
13820 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100013821 .eraseblocks = { {32 * 1024, 2} },
Sean Nelson5643c072010-01-19 03:23:07 +000013822 .block_erase = spi_block_erase_d8,
13823 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100013824 .eraseblocks = { {64 * 1024, 1} },
Sean Nelson5643c072010-01-19 03:23:07 +000013825 .block_erase = spi_block_erase_c7,
13826 }
13827 },
Alan Green1f9cc7d2019-07-01 11:10:45 +100013828 .printlock = spi_prettyprint_status_register_bp1_srwd,
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +000013829 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +000013830 .write = spi_chip_write_256,
Stefan Tauner3f5e35d2013-04-19 01:58:33 +000013831 .read = spi_chip_read, /* Fast read (0x0B) supported */
Steven Zakulec7d257b42011-07-19 08:50:18 +000013832 .voltage = {2700, 3600},
FENG yu ningff692fb2008-12-08 18:15:10 +000013833 },
13834
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000013835 {
13836 .vendor = "PMC",
Sean Nelson72a9a022009-12-22 22:15:33 +000013837 .name = "Pm29F002B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000013838 .bustype = BUS_PARALLEL,
Uwe Hermannf983d9f2009-06-14 21:53:26 +000013839 .manufacture_id = PMC_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000013840 .model_id = PMC_PM29F002B,
Uwe Hermannf983d9f2009-06-14 21:53:26 +000013841 .total_size = 256,
Sean Nelson72a9a022009-12-22 22:15:33 +000013842 .page_size = 8 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000013843 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Uwe Hermannf983d9f2009-06-14 21:53:26 +000013844 .tested = TEST_UNTESTED,
Sean Nelson35727f72010-01-28 23:55:12 +000013845 .probe = probe_jedec,
Stefan Tauner1aa80b02013-07-25 22:58:51 +000013846 .probe_timing = TIMING_FIXME,
Sean Nelson72a9a022009-12-22 22:15:33 +000013847 .block_erasers =
13848 {
13849 {
13850 .eraseblocks = {
13851 {16 * 1024, 1},
13852 {8 * 1024, 2},
13853 {96 * 1024, 1},
13854 {128 * 1024, 1},
13855 },
Sean Nelson35727f72010-01-28 23:55:12 +000013856 .block_erase = erase_sector_jedec,
Sean Nelson72a9a022009-12-22 22:15:33 +000013857 }, {
13858 .eraseblocks = { {256 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +000013859 .block_erase = erase_chip_block_jedec,
Sean Nelson72a9a022009-12-22 22:15:33 +000013860 },
13861 },
Sean Nelson35727f72010-01-28 23:55:12 +000013862 .write = write_jedec_1,
Uwe Hermannf983d9f2009-06-14 21:53:26 +000013863 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000013864 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010013865 .prepare_access = prepare_memory_access,
13866 .finish_access = finish_memory_access,
Uwe Hermannf983d9f2009-06-14 21:53:26 +000013867 },
13868
13869 {
13870 .vendor = "PMC",
Alan Green1f9cc7d2019-07-01 11:10:45 +100013871 .name = "Pm29F002T",
13872 .bustype = BUS_PARALLEL,
13873 .manufacture_id = PMC_ID_NOPREFIX,
13874 .model_id = PMC_PM29F002T,
13875 .total_size = 256,
13876 .page_size = 8 * 1024,
13877 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
13878 .tested = TEST_OK_PREW,
13879 .probe = probe_jedec,
13880 .probe_timing = TIMING_FIXME,
13881 .block_erasers =
13882 {
13883 {
13884 .eraseblocks = {
13885 {128 * 1024, 1},
13886 {96 * 1024, 1},
13887 {8 * 1024, 2},
13888 {16 * 1024, 1},
13889 },
13890 .block_erase = erase_sector_jedec,
13891 }, {
13892 .eraseblocks = { {256 * 1024, 1} },
13893 .block_erase = erase_chip_block_jedec,
13894 },
13895 },
13896 .write = write_jedec_1,
13897 .read = read_memmapped,
13898 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010013899 .prepare_access = prepare_memory_access,
13900 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100013901 },
13902
13903 {
13904 .vendor = "PMC",
Rudolf Marek50fdf3b2009-05-17 17:02:07 +000013905 .name = "Pm39LV010",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000013906 .bustype = BUS_PARALLEL,
Rudolf Marek50fdf3b2009-05-17 17:02:07 +000013907 .manufacture_id = PMC_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000013908 .model_id = PMC_PM39F010, /* Pm39LV010 and Pm39F010 have identical IDs but different voltage */
Rudolf Marek50fdf3b2009-05-17 17:02:07 +000013909 .total_size = 128,
13910 .page_size = 4096,
Sean Nelson35727f72010-01-28 23:55:12 +000013911 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Paul Menzel018d4822011-10-21 12:33:07 +000013912 .tested = TEST_OK_PREW,
Rudolf Marek50fdf3b2009-05-17 17:02:07 +000013913 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000013914 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson5643c072010-01-19 03:23:07 +000013915 .block_erasers =
13916 {
13917 {
13918 .eraseblocks = { {4 * 1024, 32} },
13919 .block_erase = erase_sector_jedec,
13920 }, {
13921 .eraseblocks = { {64 * 1024, 2} },
13922 .block_erase = erase_block_jedec,
13923 }, {
13924 .eraseblocks = { {128 * 1024, 1} },
13925 .block_erase = erase_chip_block_jedec,
13926 }
13927 },
Sean Nelson35727f72010-01-28 23:55:12 +000013928 .write = write_jedec_1,
Rudolf Marek50fdf3b2009-05-17 17:02:07 +000013929 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000013930 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010013931 .prepare_access = prepare_memory_access,
13932 .finish_access = finish_memory_access,
Rudolf Marek50fdf3b2009-05-17 17:02:07 +000013933 },
13934
13935 {
13936 .vendor = "PMC",
Anders Juel Jensendfdc56f2010-03-27 23:25:14 +000013937 .name = "Pm39LV020",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000013938 .bustype = BUS_PARALLEL,
Anders Juel Jensendfdc56f2010-03-27 23:25:14 +000013939 .manufacture_id = PMC_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000013940 .model_id = PMC_PM39LV020,
Anders Juel Jensendfdc56f2010-03-27 23:25:14 +000013941 .total_size = 256,
13942 .page_size = 4096,
13943 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
13944 .tested = TEST_UNTESTED,
13945 .probe = probe_jedec,
13946 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Alan Greenfa3fcd32019-06-27 15:41:50 +100013947 .block_erasers =
Anders Juel Jensendfdc56f2010-03-27 23:25:14 +000013948 {
13949 {
13950 .eraseblocks = { {4 * 1024, 64} },
13951 .block_erase = erase_sector_jedec,
13952 }, {
13953 .eraseblocks = { {64 * 1024, 4} },
13954 .block_erase = erase_block_jedec,
13955 }, {
13956 .eraseblocks = { {256 * 1024, 1} },
13957 .block_erase = erase_chip_block_jedec,
13958 }
13959 },
13960 .write = write_jedec_1,
13961 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000013962 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010013963 .prepare_access = prepare_memory_access,
13964 .finish_access = finish_memory_access,
Anders Juel Jensendfdc56f2010-03-27 23:25:14 +000013965 },
13966
13967 {
13968 .vendor = "PMC",
13969 .name = "Pm39LV040",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000013970 .bustype = BUS_PARALLEL,
Anders Juel Jensendfdc56f2010-03-27 23:25:14 +000013971 .manufacture_id = PMC_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000013972 .model_id = PMC_PM39LV040,
Anders Juel Jensendfdc56f2010-03-27 23:25:14 +000013973 .total_size = 512,
13974 .page_size = 4096,
13975 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Paul Menzel018d4822011-10-21 12:33:07 +000013976 .tested = TEST_OK_PR,
Anders Juel Jensendfdc56f2010-03-27 23:25:14 +000013977 .probe = probe_jedec,
13978 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Alan Greenfa3fcd32019-06-27 15:41:50 +100013979 .block_erasers =
Anders Juel Jensendfdc56f2010-03-27 23:25:14 +000013980 {
13981 {
13982 .eraseblocks = { {4 * 1024, 128} },
13983 .block_erase = erase_sector_jedec,
13984 }, {
13985 .eraseblocks = { {64 * 1024, 8} },
13986 .block_erase = erase_block_jedec,
13987 }, {
13988 .eraseblocks = { {512 * 1024, 1} },
13989 .block_erase = erase_chip_block_jedec,
13990 }
13991 },
13992 .write = write_jedec_1,
13993 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000013994 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010013995 .prepare_access = prepare_memory_access,
13996 .finish_access = finish_memory_access,
Anders Juel Jensendfdc56f2010-03-27 23:25:14 +000013997 },
Kyösti Mälkkiedab1d22012-05-20 23:32:33 +000013998
13999 {
14000 .vendor = "PMC",
14001 .name = "Pm39LV512",
14002 .bustype = BUS_PARALLEL,
14003 .manufacture_id = PMC_ID_NOPREFIX,
14004 .model_id = PMC_PM39LV512,
14005 .total_size = 64,
14006 .page_size = 4096,
14007 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
14008 .tested = TEST_OK_PREW,
14009 .probe = probe_jedec,
14010 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
14011 .block_erasers =
14012 {
14013 {
14014 .eraseblocks = { {4 * 1024, 16} },
14015 .block_erase = erase_sector_jedec,
14016 }, {
14017 .eraseblocks = { {64 * 1024, 1} },
14018 .block_erase = erase_block_jedec,
14019 }, {
14020 .eraseblocks = { {64 * 1024, 1} },
14021 .block_erase = erase_chip_block_jedec,
14022 }
14023 },
14024 .write = write_jedec_1,
14025 .read = read_memmapped,
14026 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010014027 .prepare_access = prepare_memory_access,
14028 .finish_access = finish_memory_access,
Kyösti Mälkkiedab1d22012-05-20 23:32:33 +000014029 },
14030
Anders Juel Jensendfdc56f2010-03-27 23:25:14 +000014031 {
14032 .vendor = "PMC",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014033 .name = "Pm49FL002",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000014034 .bustype = BUS_LPC | BUS_FWH, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014035 .manufacture_id = PMC_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000014036 .model_id = PMC_PM49FL002,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014037 .total_size = 256,
14038 .page_size = 16 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +010014039 .feature_bits = FEATURE_EITHER_RESET,
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000014040 .tested = TEST_OK_PR,
Carl-Daniel Hailfingere9404662010-01-09 02:24:17 +000014041 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000014042 .probe_timing = TIMING_ZERO, /* routine is wrapper to probe_jedec (pm49fl00x.c) */
Sean Nelson5643c072010-01-19 03:23:07 +000014043 .block_erasers =
14044 {
14045 {
14046 .eraseblocks = { {4 * 1024, 64} },
14047 .block_erase = erase_sector_jedec,
14048 }, {
14049 .eraseblocks = { {16 * 1024, 16} },
14050 .block_erase = erase_block_jedec,
14051 }, {
14052 .eraseblocks = { {256 * 1024, 1} },
14053 .block_erase = erase_chip_block_jedec,
14054 }
14055 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000014056 .unlock = unlock_regspace2_uniform_32k,
Sean Nelson36172342010-02-27 18:01:15 +000014057 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000014058 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000014059 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +010014060 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010014061 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000014062 },
14063
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014064 {
14065 .vendor = "PMC",
14066 .name = "Pm49FL004",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000014067 .bustype = BUS_LPC | BUS_FWH, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014068 .manufacture_id = PMC_ID_NOPREFIX,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000014069 .model_id = PMC_PM49FL004,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014070 .total_size = 512,
14071 .page_size = 64 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +010014072 .feature_bits = FEATURE_EITHER_RESET,
Stefan Tauner74dc73f2015-03-01 22:04:38 +000014073 .tested = TEST_OK_PREW,
Carl-Daniel Hailfingere9404662010-01-09 02:24:17 +000014074 .probe = probe_jedec,
Stefan Tauner74dc73f2015-03-01 22:04:38 +000014075 .probe_timing = TIMING_ZERO,
Sean Nelson5643c072010-01-19 03:23:07 +000014076 .block_erasers =
14077 {
14078 {
14079 .eraseblocks = { {4 * 1024, 128} },
14080 .block_erase = erase_sector_jedec,
14081 }, {
14082 .eraseblocks = { {64 * 1024, 8} },
14083 .block_erase = erase_block_jedec,
14084 }, {
14085 .eraseblocks = { {512 * 1024, 1} },
14086 .block_erase = erase_chip_block_jedec,
14087 }
14088 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000014089 .unlock = unlock_regspace2_uniform_64k,
Sean Nelson36172342010-02-27 18:01:15 +000014090 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000014091 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000014092 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +010014093 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010014094 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000014095 },
14096
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014097 {
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014098 .vendor = "SST",
Idwer Volleringf3607d12014-05-07 15:25:04 +000014099 .name = "SST25LF020A",
14100 .bustype = BUS_SPI,
14101 .manufacture_id = SST_ID,
14102 .model_id = SST_SST25VF020_REMS,
14103 .total_size = 256,
14104 .page_size = 256,
14105 .feature_bits = FEATURE_WRSR_EWSR,
14106 .tested = TEST_OK_PREW,
14107 .probe = probe_spi_rems,
14108 .probe_timing = TIMING_ZERO,
14109 .block_erasers =
14110 {
14111 {
14112 .eraseblocks = { {4 * 1024, 64} },
14113 .block_erase = spi_block_erase_20,
14114 }, {
14115 .eraseblocks = { {32 * 1024, 8} },
14116 .block_erase = spi_block_erase_52,
14117 }, {
14118 .eraseblocks = { {256 * 1024, 1} },
14119 .block_erase = spi_block_erase_60,
14120 },
14121 },
14122 .printlock = spi_prettyprint_status_register_sst25, /* FIXME: No BP2 & 3 */
14123 .unlock = spi_disable_blockprotect,
14124 .write = spi_chip_write_1, /* AAI supported, but opcode is 0xAF */
14125 .read = spi_chip_read, /* Fast read (0x0B) supported */
14126 .voltage = {2700, 3600},
14127 },
14128
14129 {
14130 .vendor = "SST",
Zeus Castro33670ba2011-08-17 09:50:11 +000014131 .name = "SST25LF040A",
14132 .bustype = BUS_SPI,
14133 .manufacture_id = SST_ID,
14134 .model_id = SST_SST25VF040_REMS,
14135 .total_size = 512,
14136 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +000014137 .feature_bits = FEATURE_WRSR_EWSR,
Uwe Hermann4335ec82011-09-07 20:20:25 +000014138 .tested = TEST_OK_PREW,
Zeus Castro33670ba2011-08-17 09:50:11 +000014139 .probe = probe_spi_res2,
14140 .probe_timing = TIMING_ZERO,
14141 .block_erasers =
14142 {
14143 {
14144 .eraseblocks = { {4 * 1024, 128} },
14145 .block_erase = spi_block_erase_20,
14146 }, {
14147 .eraseblocks = { {32 * 1024, 16} },
14148 .block_erase = spi_block_erase_52,
14149 }, {
14150 .eraseblocks = { {512 * 1024, 1} },
14151 .block_erase = spi_block_erase_60,
14152 },
14153 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +000014154 .printlock = spi_prettyprint_status_register_sst25, /* TODO: check */
Zeus Castro33670ba2011-08-17 09:50:11 +000014155 .unlock = spi_disable_blockprotect,
14156 .write = spi_chip_write_1, /* AAI supported, but opcode is 0xAF */
14157 .read = spi_chip_read,
14158 .voltage = {3000, 3600},
14159 },
14160
14161 {
14162 .vendor = "SST",
Stefan Taunere34e3e82013-01-01 00:06:51 +000014163 .name = "SST25LF080(A)",
Zeus Castro33670ba2011-08-17 09:50:11 +000014164 .bustype = BUS_SPI,
14165 .manufacture_id = SST_ID,
14166 .model_id = SST_SST25VF080_REMS,
14167 .total_size = 1024,
14168 .page_size = 256,
Stefan Taunere34e3e82013-01-01 00:06:51 +000014169 .feature_bits = FEATURE_WRSR_EITHER,
Zeus Castro33670ba2011-08-17 09:50:11 +000014170 .tested = TEST_UNTESTED,
14171 .probe = probe_spi_res2,
14172 .probe_timing = TIMING_ZERO,
14173 .block_erasers =
14174 {
14175 {
14176 .eraseblocks = { {4 * 1024, 256} },
14177 .block_erase = spi_block_erase_20,
14178 }, {
14179 .eraseblocks = { {32 * 1024, 32} },
14180 .block_erase = spi_block_erase_52,
14181 }, {
14182 .eraseblocks = { {1024 * 1024, 1} },
14183 .block_erase = spi_block_erase_60,
14184 },
14185 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +000014186 .printlock = spi_prettyprint_status_register_sst25, /* TODO: check */
Zeus Castro33670ba2011-08-17 09:50:11 +000014187 .unlock = spi_disable_blockprotect,
14188 .write = spi_chip_write_1, /* AAI supported, but opcode is 0xAF */
14189 .read = spi_chip_read,
14190 .voltage = {3000, 3600},
14191 },
14192
14193 {
14194 .vendor = "SST",
Stefan Tauner6697f712014-08-06 15:09:15 +000014195 .name = "SST25VF010(A)",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000014196 .bustype = BUS_SPI,
Mark Marshall90021f22010-12-03 14:48:11 +000014197 .manufacture_id = SST_ID,
14198 .model_id = SST_SST25VF010_REMS,
14199 .total_size = 128,
14200 .page_size = 256,
Steven Zakulec3603a282012-05-02 20:07:57 +000014201 .feature_bits = FEATURE_WRSR_EWSR,
Mark Marshall90021f22010-12-03 14:48:11 +000014202 .tested = TEST_OK_PREW,
14203 .probe = probe_spi_rems,
14204 .probe_timing = TIMING_ZERO,
14205 .block_erasers =
14206 {
14207 {
14208 .eraseblocks = { {4 * 1024, 32} },
14209 .block_erase = spi_block_erase_20,
14210 }, {
14211 .eraseblocks = { {32 * 1024, 4} },
14212 .block_erase = spi_block_erase_52,
14213 }, {
Cory Henderson370f5822013-10-19 23:09:16 +000014214 .eraseblocks = { {32 * 1024, 4} },
Stefan Tauner6697f712014-08-06 15:09:15 +000014215 .block_erase = spi_block_erase_d8, /* Supported by SST25VF010A only */
Cory Henderson370f5822013-10-19 23:09:16 +000014216 }, {
Mark Marshall90021f22010-12-03 14:48:11 +000014217 .eraseblocks = { {128 * 1024, 1} },
14218 .block_erase = spi_block_erase_60,
Cory Henderson370f5822013-10-19 23:09:16 +000014219 }, {
14220 .eraseblocks = { {128 * 1024, 1} },
Stefan Tauner6697f712014-08-06 15:09:15 +000014221 .block_erase = spi_block_erase_c7, /* Supported by SST25VF010A only */
Cory Henderson370f5822013-10-19 23:09:16 +000014222 },
14223 },
14224 .printlock = spi_prettyprint_status_register_sst25, /* FIXME: No BP2 & 3 */
14225 .unlock = spi_disable_blockprotect,
14226 .write = spi_chip_write_1, /* AAI supported, but opcode is 0xAF */
Stefan Tauner6697f712014-08-06 15:09:15 +000014227 .read = spi_chip_read, /* Fast read (0x0B) supported by SST25VF010A only */
Cory Henderson370f5822013-10-19 23:09:16 +000014228 .voltage = {2700, 3600},
14229 },
14230
14231 {
14232 .vendor = "SST",
Alan Green1f9cc7d2019-07-01 11:10:45 +100014233 .name = "SST25VF016B",
14234 .bustype = BUS_SPI,
14235 .manufacture_id = SST_ID,
14236 .model_id = SST_SST25VF016B,
14237 .total_size = 2048,
14238 .page_size = 256,
14239 .feature_bits = FEATURE_WRSR_EITHER,
14240 .tested = TEST_OK_PREW,
14241 .probe = probe_spi_rdid,
14242 .probe_timing = TIMING_ZERO,
14243 .block_erasers =
14244 {
14245 {
14246 .eraseblocks = { {4 * 1024, 512} },
14247 .block_erase = spi_block_erase_20,
14248 }, {
14249 .eraseblocks = { {32 * 1024, 64} },
14250 .block_erase = spi_block_erase_52,
14251 }, {
14252 .eraseblocks = { {64 * 1024, 32} },
14253 .block_erase = spi_block_erase_d8,
14254 }, {
14255 .eraseblocks = { {2 * 1024 * 1024, 1} },
14256 .block_erase = spi_block_erase_60,
14257 }, {
14258 .eraseblocks = { {2 * 1024 * 1024, 1} },
14259 .block_erase = spi_block_erase_c7,
14260 },
14261 },
14262 .printlock = spi_prettyprint_status_register_sst25vf016,
14263 .unlock = spi_disable_blockprotect,
14264 .write = spi_aai_write,
14265 .read = spi_chip_read,
14266 .voltage = {2700, 3600},
14267 },
14268
14269 {
14270 .vendor = "SST",
Cory Henderson370f5822013-10-19 23:09:16 +000014271 .name = "SST25VF020",
14272 .bustype = BUS_SPI,
14273 .manufacture_id = SST_ID,
14274 .model_id = SST_SST25VF020_REMS,
14275 .total_size = 256,
14276 .page_size = 256,
14277 .feature_bits = FEATURE_WRSR_EWSR,
14278 .tested = TEST_UNTESTED,
14279 .probe = probe_spi_rems,
14280 .probe_timing = TIMING_ZERO,
14281 .block_erasers =
14282 {
14283 {
14284 .eraseblocks = { {4 * 1024, 64} },
14285 .block_erase = spi_block_erase_20,
14286 }, {
14287 .eraseblocks = { {32 * 1024, 8} },
14288 .block_erase = spi_block_erase_52,
14289 }, {
14290 .eraseblocks = { {256 * 1024, 1} },
14291 .block_erase = spi_block_erase_60,
14292 },
14293 },
14294 .printlock = spi_prettyprint_status_register_sst25, /* FIXME: No BP2 & 3 */
14295 .unlock = spi_disable_blockprotect,
14296 .write = spi_chip_write_1, /* AAI supported, but opcode is 0xAF */
14297 .read = spi_chip_read, /* only */
14298 .voltage = {2700, 3600},
14299 },
14300
14301 {
14302 .vendor = "SST",
14303 .name = "SST25VF020B",
14304 .bustype = BUS_SPI,
14305 .manufacture_id = SST_ID,
14306 .model_id = SST_SST25VF020B,
14307 .total_size = 256,
14308 .page_size = 256,
14309 .feature_bits = FEATURE_WRSR_EWSR,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +000014310 .tested = TEST_OK_PREW,
Cory Henderson370f5822013-10-19 23:09:16 +000014311 .probe = probe_spi_rdid,
14312 .probe_timing = TIMING_ZERO,
14313 .block_erasers =
14314 {
14315 {
14316 .eraseblocks = { {4 * 1024, 64} },
14317 .block_erase = spi_block_erase_20,
14318 }, {
14319 .eraseblocks = { {32 * 1024, 8} },
14320 .block_erase = spi_block_erase_52,
14321 }, {
14322 .eraseblocks = { {64 * 1024, 4} },
14323 .block_erase = spi_block_erase_d8,
14324 }, {
14325 .eraseblocks = { {256 * 1024, 1} },
14326 .block_erase = spi_block_erase_60,
14327 }, {
14328 .eraseblocks = { {256 * 1024, 1} },
14329 .block_erase = spi_block_erase_c7,
14330 },
14331 },
14332 .printlock = spi_prettyprint_status_register_sst25, /* FIXME: No BP2 & 3 and 2nd SR */
14333 .unlock = spi_disable_blockprotect, /* FIXME: 2nd SR */
14334 .write = spi_aai_write, /* AAI supported (0xAD) */
14335 .read = spi_chip_read, /* Fast read (0x0B) supported */
14336 .voltage = {2700, 3600},
14337 },
14338
14339 {
14340 .vendor = "SST",
Alan Green1f9cc7d2019-07-01 11:10:45 +100014341 .name = "SST25VF032B",
14342 .bustype = BUS_SPI,
14343 .manufacture_id = SST_ID,
14344 .model_id = SST_SST25VF032B,
14345 .total_size = 4096,
14346 .page_size = 256,
14347 .feature_bits = FEATURE_WRSR_EWSR,
14348 .tested = TEST_OK_PREW,
14349 .probe = probe_spi_rdid,
14350 .probe_timing = TIMING_ZERO,
14351 .block_erasers =
14352 {
14353 {
14354 .eraseblocks = { {4 * 1024, 1024} },
14355 .block_erase = spi_block_erase_20,
14356 }, {
14357 .eraseblocks = { {32 * 1024, 128} },
14358 .block_erase = spi_block_erase_52,
14359 }, {
14360 .eraseblocks = { {64 * 1024, 64} },
14361 .block_erase = spi_block_erase_d8,
14362 }, {
14363 .eraseblocks = { {4 * 1024 * 1024, 1} },
14364 .block_erase = spi_block_erase_60,
14365 }, {
14366 .eraseblocks = { {4 * 1024 * 1024, 1} },
14367 .block_erase = spi_block_erase_c7,
14368 },
14369 },
14370 .printlock = spi_prettyprint_status_register_sst25, /* TODO: check */
14371 .unlock = spi_disable_blockprotect,
14372 .write = spi_aai_write,
14373 .read = spi_chip_read,
14374 .voltage = {2700, 3600},
14375 },
14376
14377 {
14378 .vendor = "SST",
Cory Henderson370f5822013-10-19 23:09:16 +000014379 .name = "SST25VF040",
14380 .bustype = BUS_SPI,
14381 .manufacture_id = SST_ID,
14382 .model_id = SST_SST25VF040_REMS,
14383 .total_size = 512,
14384 .page_size = 256,
14385 .feature_bits = FEATURE_WRSR_EWSR,
14386 .tested = TEST_OK_PR,
14387 .probe = probe_spi_rems,
14388 .probe_timing = TIMING_ZERO,
14389 .block_erasers =
14390 {
14391 {
14392 .eraseblocks = { {4 * 1024, 128} },
14393 .block_erase = spi_block_erase_20,
14394 }, {
14395 .eraseblocks = { {32 * 1024, 16} },
14396 .block_erase = spi_block_erase_52,
14397 }, {
14398 .eraseblocks = { {512 * 1024, 1} },
14399 .block_erase = spi_block_erase_60,
Mark Marshall90021f22010-12-03 14:48:11 +000014400 },
14401 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +000014402 .printlock = spi_prettyprint_status_register_sst25, /* TODO: check */
Mark Marshall90021f22010-12-03 14:48:11 +000014403 .unlock = spi_disable_blockprotect,
Cory Henderson370f5822013-10-19 23:09:16 +000014404 .write = spi_chip_write_1, /* AAI supported, but opcode is 0xAF */
14405 .read = spi_chip_read,
14406 .voltage = {2700, 3600},
14407 },
14408
14409 {
14410 .vendor = "SST",
14411 .name = "SST25VF040B",
14412 .bustype = BUS_SPI,
14413 .manufacture_id = SST_ID,
14414 .model_id = SST_SST25VF040B,
14415 .total_size = 512,
14416 .page_size = 256,
14417 .feature_bits = FEATURE_WRSR_EWSR,
14418 .tested = TEST_OK_PREW,
14419 .probe = probe_spi_rdid,
14420 .probe_timing = TIMING_ZERO,
14421 .block_erasers =
14422 {
14423 {
14424 .eraseblocks = { {4 * 1024, 128} },
14425 .block_erase = spi_block_erase_20,
14426 }, {
14427 .eraseblocks = { {32 * 1024, 16} },
14428 .block_erase = spi_block_erase_52,
14429 }, {
14430 .eraseblocks = { {64 * 1024, 8} },
14431 .block_erase = spi_block_erase_d8,
14432 }, {
14433 .eraseblocks = { {512 * 1024, 1} },
14434 .block_erase = spi_block_erase_60,
14435 }, {
14436 .eraseblocks = { {512 * 1024, 1} },
14437 .block_erase = spi_block_erase_c7,
14438 },
14439 },
14440 .printlock = spi_prettyprint_status_register_sst25vf040b,
14441 .unlock = spi_disable_blockprotect,
14442 .write = spi_aai_write, /* AAI supported (0xAD) */
14443 .read = spi_chip_read, /* Fast read (0x0B) supported */
14444 .voltage = {2700, 3600},
14445 },
14446
14447 {
14448 .vendor = "SST",
14449 .name = "SST25VF040B.REMS",
14450 .bustype = BUS_SPI,
14451 .manufacture_id = SST_ID,
14452 .model_id = SST_SST25VF040B_REMS,
14453 .total_size = 512,
14454 .page_size = 256,
14455 .feature_bits = FEATURE_WRSR_EWSR,
14456 .tested = TEST_OK_PREW,
14457 .probe = probe_spi_rems,
14458 .probe_timing = TIMING_ZERO,
14459 .block_erasers =
14460 {
14461 {
14462 .eraseblocks = { {4 * 1024, 128} },
14463 .block_erase = spi_block_erase_20,
14464 }, {
14465 .eraseblocks = { {32 * 1024, 16} },
14466 .block_erase = spi_block_erase_52,
14467 }, {
14468 .eraseblocks = { {64 * 1024, 8} },
14469 .block_erase = spi_block_erase_d8,
14470 }, {
14471 .eraseblocks = { {512 * 1024, 1} },
14472 .block_erase = spi_block_erase_60,
14473 }, {
14474 .eraseblocks = { {512 * 1024, 1} },
14475 .block_erase = spi_block_erase_c7,
14476 },
14477 },
14478 .printlock = spi_prettyprint_status_register_sst25vf040b,
14479 .unlock = spi_disable_blockprotect,
14480 .write = spi_aai_write,
14481 .read = spi_chip_read,
14482 .voltage = {2700, 3600},
14483 },
14484
14485 {
14486 .vendor = "SST",
Alan Green1f9cc7d2019-07-01 11:10:45 +100014487 .name = "SST25VF064C",
Ben Gardnerbcf61092015-11-22 02:23:31 +000014488 .bustype = BUS_SPI,
Alan Green1f9cc7d2019-07-01 11:10:45 +100014489 .manufacture_id = SST_ID,
14490 .model_id = SST_SST25VF064C,
14491 .total_size = 8192,
Ben Gardnerbcf61092015-11-22 02:23:31 +000014492 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +100014493 .feature_bits = FEATURE_WRSR_EWSR,
Ben Gardnerbcf61092015-11-22 02:23:31 +000014494 .tested = TEST_OK_PREW,
14495 .probe = probe_spi_rdid,
14496 .probe_timing = TIMING_ZERO,
14497 .block_erasers =
14498 {
14499 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100014500 .eraseblocks = { {4 * 1024, 2048} },
Ben Gardnerbcf61092015-11-22 02:23:31 +000014501 .block_erase = spi_block_erase_20,
14502 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100014503 .eraseblocks = { {32 * 1024, 256} },
14504 .block_erase = spi_block_erase_52,
14505 }, {
14506 .eraseblocks = { {64 * 1024, 128} },
Ben Gardnerbcf61092015-11-22 02:23:31 +000014507 .block_erase = spi_block_erase_d8,
14508 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100014509 .eraseblocks = { {8 * 1024 * 1024, 1} },
Ben Gardnerbcf61092015-11-22 02:23:31 +000014510 .block_erase = spi_block_erase_60,
14511 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100014512 .eraseblocks = { {8 * 1024 * 1024, 1} },
Ben Gardnerbcf61092015-11-22 02:23:31 +000014513 .block_erase = spi_block_erase_c7,
14514 },
14515 },
Alan Green1f9cc7d2019-07-01 11:10:45 +100014516 .printlock = spi_prettyprint_status_register_sst25, /* TODO: check */
14517 .unlock = spi_disable_blockprotect,
Ben Gardnerbcf61092015-11-22 02:23:31 +000014518 .write = spi_chip_write_256,
Alan Green1f9cc7d2019-07-01 11:10:45 +100014519 .read = spi_chip_read,
14520 .voltage = {2700, 3600},
Ben Gardnerbcf61092015-11-22 02:23:31 +000014521 },
14522
14523 {
14524 .vendor = "SST",
Cory Henderson370f5822013-10-19 23:09:16 +000014525 .name = "SST25VF080B",
14526 .bustype = BUS_SPI,
14527 .manufacture_id = SST_ID,
14528 .model_id = SST_SST25VF080B,
14529 .total_size = 1024,
14530 .page_size = 256,
14531 .feature_bits = FEATURE_WRSR_EWSR,
14532 .tested = TEST_OK_PREW,
14533 .probe = probe_spi_rdid,
14534 .probe_timing = TIMING_ZERO,
14535 .block_erasers =
14536 {
14537 {
14538 .eraseblocks = { {4 * 1024, 256} },
14539 .block_erase = spi_block_erase_20,
14540 }, {
14541 .eraseblocks = { {32 * 1024, 32} },
14542 .block_erase = spi_block_erase_52,
14543 }, {
14544 .eraseblocks = { {64 * 1024, 16} },
14545 .block_erase = spi_block_erase_d8,
14546 }, {
14547 .eraseblocks = { {1024 * 1024, 1} },
14548 .block_erase = spi_block_erase_60,
14549 }, {
14550 .eraseblocks = { {1024 * 1024, 1} },
14551 .block_erase = spi_block_erase_c7,
14552 },
14553 },
14554 .printlock = spi_prettyprint_status_register_sst25, /* TODO: check */
14555 .unlock = spi_disable_blockprotect,
14556 .write = spi_aai_write,
Mark Marshall90021f22010-12-03 14:48:11 +000014557 .read = spi_chip_read,
Steven Zakulec7d257b42011-07-19 08:50:18 +000014558 .voltage = {2700, 3600},
Mark Marshall90021f22010-12-03 14:48:11 +000014559 },
14560
14561 {
14562 .vendor = "SST",
Alan Green1f9cc7d2019-07-01 11:10:45 +100014563 .name = "SST25VF512(A)",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000014564 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014565 .manufacture_id = SST_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +100014566 .model_id = SST_SST25VF512_REMS,
14567 .total_size = 64,
14568 .page_size = 256,
14569 .feature_bits = FEATURE_WRSR_EWSR,
14570 .tested = TEST_OK_PREW,
14571 .probe = probe_spi_rems,
14572 .probe_timing = TIMING_ZERO,
14573 .block_erasers =
14574 {
14575 {
14576 .eraseblocks = { {4 * 1024, 16} },
14577 .block_erase = spi_block_erase_20,
14578 }, {
14579 .eraseblocks = { {32 * 1024, 2} },
14580 .block_erase = spi_block_erase_52,
14581 }, {
14582 .eraseblocks = { {32 * 1024, 2} },
14583 .block_erase = spi_block_erase_d8, /* Supported by SST25VF512A only */
14584 }, {
14585 .eraseblocks = { {64 * 1024, 1} },
14586 .block_erase = spi_block_erase_60,
14587 }, {
14588 .eraseblocks = { {64 * 1024, 1} },
14589 .block_erase = spi_block_erase_c7, /* Supported by SST25VF512A only */
14590 },
14591 },
14592 .printlock = spi_prettyprint_status_register_sst25, /* FIXME: No BP2 & 3 */
14593 .unlock = spi_disable_blockprotect,
14594 .write = spi_chip_write_1, /* AAI supported, but opcode is 0xAF */
14595 .read = spi_chip_read, /* Fast read (0x0B) supported by SST25VF512A only */
14596 .voltage = {2700, 3600},
14597 },
14598
14599 {
14600 .vendor = "SST",
14601 .name = "SST25WF010",
14602 .bustype = BUS_SPI,
14603 .manufacture_id = SST_ID,
14604 .model_id = SST_SST25WF010,
14605 .total_size = 128,
14606 .page_size = 256,
14607 .feature_bits = FEATURE_WRSR_EITHER,
14608 .tested = TEST_UNTESTED,
14609 .probe = probe_spi_rdid,
14610 .probe_timing = TIMING_ZERO,
14611 .block_erasers =
14612 {
14613 {
14614 .eraseblocks = { {4 * 1024, 32} },
14615 .block_erase = spi_block_erase_20,
14616 }, {
14617 .eraseblocks = { {32 * 1024, 4} },
14618 .block_erase = spi_block_erase_52,
14619 }, {
14620 .eraseblocks = { {1024 * 128, 1} },
14621 .block_erase = spi_block_erase_60,
14622 }, {
14623 .eraseblocks = { {1024 * 128, 1} },
14624 .block_erase = spi_block_erase_c7,
14625 },
14626 },
14627 .printlock = spi_prettyprint_status_register_sst25, /* FIXME: does not have a BP3 */
14628 .unlock = spi_disable_blockprotect_bp2_srwd,
14629 .write = spi_aai_write,
14630 .read = spi_chip_read, /* Fast read (0x0B) supported */
14631 .voltage = {1650, 1950},
14632 },
14633
14634 {
14635 .vendor = "SST",
14636 .name = "SST25WF020",
14637 .bustype = BUS_SPI,
14638 .manufacture_id = SST_ID,
14639 .model_id = SST_SST25WF020,
14640 .total_size = 256,
14641 .page_size = 256,
14642 .feature_bits = FEATURE_WRSR_EITHER,
14643 .tested = TEST_UNTESTED,
14644 .probe = probe_spi_rdid,
14645 .probe_timing = TIMING_ZERO,
14646 .block_erasers =
14647 {
14648 {
14649 .eraseblocks = { {4 * 1024, 64} },
14650 .block_erase = spi_block_erase_20,
14651 }, {
14652 .eraseblocks = { {32 * 1024, 8} },
14653 .block_erase = spi_block_erase_52,
14654 }, {
14655 .eraseblocks = { {64 * 1024, 4} },
14656 .block_erase = spi_block_erase_d8,
14657 }, {
14658 .eraseblocks = { {1024 * 256, 1} },
14659 .block_erase = spi_block_erase_60,
14660 }, {
14661 .eraseblocks = { {1024 * 256, 1} },
14662 .block_erase = spi_block_erase_c7,
14663 },
14664 },
14665 .printlock = spi_prettyprint_status_register_sst25, /* FIXME: does not have a BP3 */
14666 .unlock = spi_disable_blockprotect_bp2_srwd,
14667 .write = spi_aai_write,
14668 .read = spi_chip_read, /* Fast read (0x0B) supported */
14669 .voltage = {1650, 1950},
14670 },
14671
14672 {
14673 .vendor = "SST",
14674 .name = "SST25WF020A",
14675 .bustype = BUS_SPI,
14676 .manufacture_id = SANYO_ID, /* See flashchips.h */
14677 .model_id = SST_SST25WF020A,
14678 .total_size = 256,
14679 .page_size = 256,
14680 .feature_bits = FEATURE_WRSR_WREN,
14681 .tested = TEST_UNTESTED,
14682 .probe = probe_spi_rdid,
14683 .probe_timing = TIMING_ZERO,
14684 .block_erasers =
14685 {
14686 {
14687 .eraseblocks = { {4 * 1024, 64} },
14688 .block_erase = spi_block_erase_20,
14689 }, {
14690 .eraseblocks = { {64 * 1024, 4} },
14691 .block_erase = spi_block_erase_d8,
14692 }, {
14693 .eraseblocks = { {256 * 1024, 1} },
14694 .block_erase = spi_block_erase_60,
14695 }, {
14696 .eraseblocks = { {256 * 1024, 1} },
14697 .block_erase = spi_block_erase_c7,
14698 },
14699 },
14700 .printlock = spi_prettyprint_status_register_bp2_tb_bpl,
14701 .unlock = spi_disable_blockprotect_bp2_srwd,
14702 .write = spi_chip_write_256,
14703 .read = spi_chip_read, /* Fast read (0x0B) supported */
14704 .voltage = {1650, 1950},
14705 },
14706
14707 {
14708 .vendor = "SST",
14709 .name = "SST25WF040",
14710 .bustype = BUS_SPI,
14711 .manufacture_id = SST_ID,
14712 .model_id = SST_SST25WF040,
14713 .total_size = 512,
14714 .page_size = 256,
14715 .feature_bits = FEATURE_WRSR_EITHER,
14716 .tested = TEST_UNTESTED,
14717 .probe = probe_spi_rdid,
14718 .probe_timing = TIMING_ZERO,
14719 .block_erasers =
14720 {
14721 {
14722 .eraseblocks = { {4 * 1024, 128} },
14723 .block_erase = spi_block_erase_20,
14724 }, {
14725 .eraseblocks = { {32 * 1024, 16} },
14726 .block_erase = spi_block_erase_52,
14727 }, {
14728 .eraseblocks = { {64 * 1024, 8} },
14729 .block_erase = spi_block_erase_d8,
14730 }, {
14731 .eraseblocks = { {1024 * 512, 1} },
14732 .block_erase = spi_block_erase_60,
14733 }, {
14734 .eraseblocks = { {1024 * 512, 1} },
14735 .block_erase = spi_block_erase_c7,
14736 },
14737 },
14738 .printlock = spi_prettyprint_status_register_sst25, /* FIXME: does not have a BP3 */
14739 .unlock = spi_disable_blockprotect_bp2_srwd,
14740 .write = spi_aai_write,
14741 .read = spi_chip_read, /* Fast read (0x0B) supported */
14742 .voltage = {1650, 1950},
14743 },
14744
14745 {
14746 .vendor = "SST",
14747 .name = "SST25WF040B",
14748 .bustype = BUS_SPI,
14749 .manufacture_id = SANYO_ID, /* See flashchips.h */
14750 .model_id = SST_SST25WF040B,
14751 .total_size = 512,
14752 .page_size = 256,
14753 .feature_bits = FEATURE_WRSR_WREN,
14754 .tested = TEST_UNTESTED,
14755 .probe = probe_spi_rdid,
14756 .probe_timing = TIMING_ZERO,
14757 .block_erasers =
14758 {
14759 {
14760 .eraseblocks = { {4 * 1024, 128} },
14761 .block_erase = spi_block_erase_20,
14762 }, {
14763 .eraseblocks = { {64 * 1024, 8} },
14764 .block_erase = spi_block_erase_d8,
14765 }, {
14766 .eraseblocks = { {512 * 1024, 1} },
14767 .block_erase = spi_block_erase_60,
14768 }, {
14769 .eraseblocks = { {512 * 1024, 1} },
14770 .block_erase = spi_block_erase_c7,
14771 },
14772 },
14773 .printlock = spi_prettyprint_status_register_bp2_tb_bpl,
14774 .unlock = spi_disable_blockprotect_bp2_srwd,
14775 .write = spi_chip_write_256,
14776 .read = spi_chip_read, /* Fast read (0x0B), dual O (0x3B), dual I/O read (0xBB) supported */
14777 .voltage = {1650, 1950},
14778 },
14779
14780 {
14781 .vendor = "SST",
14782 .name = "SST25WF080",
14783 .bustype = BUS_SPI,
14784 .manufacture_id = SST_ID,
14785 .model_id = SST_SST25WF080,
14786 .total_size = 1024,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014787 .page_size = 256,
Stefan Taunere34e3e82013-01-01 00:06:51 +000014788 .feature_bits = FEATURE_WRSR_EITHER,
Mark Marshall90021f22010-12-03 14:48:11 +000014789 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014790 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000014791 .probe_timing = TIMING_ZERO,
Carl-Daniel Hailfingerbbfeb702009-12-23 12:16:47 +000014792 .block_erasers =
14793 {
14794 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100014795 .eraseblocks = { {4 * 1024, 256} },
Carl-Daniel Hailfingerbbfeb702009-12-23 12:16:47 +000014796 .block_erase = spi_block_erase_20,
14797 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100014798 .eraseblocks = { {32 * 1024, 32} },
Carl-Daniel Hailfingerbbfeb702009-12-23 12:16:47 +000014799 .block_erase = spi_block_erase_52,
14800 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100014801 .eraseblocks = { {64 * 1024, 16} },
Carl-Daniel Hailfingerbbfeb702009-12-23 12:16:47 +000014802 .block_erase = spi_block_erase_d8,
14803 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100014804 .eraseblocks = { {1024 * 1024, 1} },
Carl-Daniel Hailfingerbbfeb702009-12-23 12:16:47 +000014805 .block_erase = spi_block_erase_60,
14806 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100014807 .eraseblocks = { {1024 * 1024, 1} },
Carl-Daniel Hailfingerbbfeb702009-12-23 12:16:47 +000014808 .block_erase = spi_block_erase_c7,
14809 },
14810 },
Alan Green1f9cc7d2019-07-01 11:10:45 +100014811 .printlock = spi_prettyprint_status_register_sst25, /* *does* have a BP3 but it is useless */
14812 .unlock = spi_disable_blockprotect_bp3_srwd,
Joshua Roys87955bf2011-08-01 18:39:28 +000014813 .write = spi_aai_write,
Alan Green1f9cc7d2019-07-01 11:10:45 +100014814 .read = spi_chip_read, /* Fast read (0x0B) supported */
14815 .voltage = {1650, 1950},
FENG yu ningff692fb2008-12-08 18:15:10 +000014816 },
14817
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014818 {
14819 .vendor = "SST",
Alan Green1f9cc7d2019-07-01 11:10:45 +100014820 .name = "SST25WF080B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000014821 .bustype = BUS_SPI,
Alan Green1f9cc7d2019-07-01 11:10:45 +100014822 .manufacture_id = SANYO_ID, /* See flashchips.h */
14823 .model_id = SST_SST25WF080B,
14824 .total_size = 1024,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014825 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +100014826 .feature_bits = FEATURE_WRSR_WREN,
Stefan Taunerfcf6a8c2011-05-18 01:32:00 +000014827 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000014828 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000014829 .probe_timing = TIMING_ZERO,
Carl-Daniel Hailfingerbbfeb702009-12-23 12:16:47 +000014830 .block_erasers =
14831 {
14832 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100014833 .eraseblocks = { {4 * 1024, 256} },
Carl-Daniel Hailfingerbbfeb702009-12-23 12:16:47 +000014834 .block_erase = spi_block_erase_20,
14835 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100014836 .eraseblocks = { {64 * 1024, 16} },
Carl-Daniel Hailfingerbbfeb702009-12-23 12:16:47 +000014837 .block_erase = spi_block_erase_d8,
14838 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100014839 .eraseblocks = { {1024 * 1024, 1} },
Carl-Daniel Hailfingerbbfeb702009-12-23 12:16:47 +000014840 .block_erase = spi_block_erase_60,
14841 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100014842 .eraseblocks = { {1024 * 1024, 1} },
Carl-Daniel Hailfingerbbfeb702009-12-23 12:16:47 +000014843 .block_erase = spi_block_erase_c7,
14844 },
14845 },
Alan Green1f9cc7d2019-07-01 11:10:45 +100014846 .printlock = spi_prettyprint_status_register_bp2_tb_bpl,
14847 .unlock = spi_disable_blockprotect_bp2_srwd,
Helge Wagner1db7a442010-10-05 22:29:08 +000014848 .write = spi_chip_write_256,
Alan Green1f9cc7d2019-07-01 11:10:45 +100014849 .read = spi_chip_read, /* Fast read (0x0B), dual O (0x3B), dual I/O read (0xBB) supported */
14850 .voltage = {1650, 1950},
14851 },
14852
14853 {
14854 .vendor = "SST",
14855 .name = "SST25WF512",
14856 .bustype = BUS_SPI,
14857 .manufacture_id = SST_ID,
14858 .model_id = SST_SST25WF512,
14859 .total_size = 64,
14860 .page_size = 256,
14861 .feature_bits = FEATURE_WRSR_EITHER,
14862 .tested = TEST_UNTESTED,
14863 .probe = probe_spi_rdid,
14864 .probe_timing = TIMING_ZERO,
14865 .block_erasers =
14866 {
14867 {
14868 .eraseblocks = { {4 * 1024, 16} },
14869 .block_erase = spi_block_erase_20,
14870 }, {
14871 .eraseblocks = { {32 * 1024, 2} },
14872 .block_erase = spi_block_erase_52,
14873 }, {
14874 .eraseblocks = { {1024 * 64, 1} },
14875 .block_erase = spi_block_erase_60,
14876 }, {
14877 .eraseblocks = { {1024 * 64, 1} },
14878 .block_erase = spi_block_erase_c7,
14879 },
14880 },
14881 .printlock = spi_prettyprint_status_register_sst25, /* FIXME: does not have a BP3 */
14882 .unlock = spi_disable_blockprotect_bp2_srwd,
14883 .write = spi_aai_write,
14884 .read = spi_chip_read, /* Fast read (0x0B) supported */
14885 .voltage = {1650, 1950},
Ed Swierk86f4e6d2010-07-21 15:02:22 +000014886 },
14887
14888 {
14889 .vendor = "SST",
Nico Hubera2eaf4a2023-02-15 22:56:53 +010014890 .name = "SST26VF016",
14891 .bustype = BUS_SPI,
14892 .manufacture_id = SST_ID,
14893 .model_id = SST_SST26VF016,
14894 .total_size = 2048,
14895 .page_size = 256,
14896 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
14897 .tested = TEST_UNTESTED,
14898 .probe = probe_spi_rdid,
14899 .probe_timing = TIMING_ZERO,
14900 .block_erasers =
14901 {
14902 {
14903 .eraseblocks = { {4 * 1024, 512} },
14904 .block_erase = spi_block_erase_20,
14905 }, {
14906 .eraseblocks = {
14907 {8 * 1024, 4},
14908 {32 * 1024, 1},
14909 {64 * 1024, 30},
14910 {32 * 1024, 1},
14911 {8 * 1024, 4},
14912 },
14913 .block_erase = spi_block_erase_d8,
14914 }, {
14915 .eraseblocks = { {2 * 1024 * 1024, 1} },
14916 .block_erase = spi_block_erase_c7,
14917 },
14918 },
14919 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
14920 .unlock = spi_disable_blockprotect_sst26_global_unprotect,
14921 .write = spi_chip_write_256, /* Multi I/O supported */
14922 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
14923 .voltage = {2700, 3600},
14924 },
14925
14926 {
14927 .vendor = "SST",
Wei Hu25584de2018-04-30 14:02:08 -070014928 .name = "SST26VF016B(A)",
14929 .bustype = BUS_SPI,
14930 .manufacture_id = SST_ID,
14931 .model_id = SST_SST26VF016B,
14932 .total_size = 2048,
14933 .page_size = 256,
14934 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
14935 .tested = TEST_OK_PREW,
14936 .probe = probe_spi_rdid,
14937 .probe_timing = TIMING_ZERO,
14938 .block_erasers =
14939 {
14940 {
14941 .eraseblocks = { {4 * 1024, 512} },
14942 .block_erase = spi_block_erase_20,
14943 }, {
14944 .eraseblocks = {
14945 {8 * 1024, 4},
14946 {32 * 1024, 1},
14947 {64 * 1024, 30},
14948 {32 * 1024, 1},
14949 {8 * 1024, 4},
14950 },
14951 .block_erase = spi_block_erase_d8,
14952 }, {
14953 .eraseblocks = { {2 * 1024 * 1024, 1} },
14954 .block_erase = spi_block_erase_c7,
14955 },
14956 },
14957 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
14958 .unlock = spi_disable_blockprotect_sst26_global_unprotect,
14959 .write = spi_chip_write_256, /* Multi I/O supported */
14960 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
14961 .voltage = {2700, 3600},
14962 },
Alan Greenfa3fcd32019-06-27 15:41:50 +100014963
Wei Hu25584de2018-04-30 14:02:08 -070014964 {
14965 .vendor = "SST",
Nico Hubera2eaf4a2023-02-15 22:56:53 +010014966 .name = "SST26VF032",
14967 .bustype = BUS_SPI,
14968 .manufacture_id = SST_ID,
14969 .model_id = SST_SST26VF032,
14970 .total_size = 4096,
14971 .page_size = 256,
14972 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
14973 .tested = TEST_UNTESTED,
14974 .probe = probe_spi_rdid,
14975 .probe_timing = TIMING_ZERO,
14976 .block_erasers =
14977 {
14978 {
14979 .eraseblocks = { {4 * 1024, 1024} },
14980 .block_erase = spi_block_erase_20,
14981 }, {
14982 .eraseblocks = {
14983 {8 * 1024, 4},
14984 {32 * 1024, 1},
14985 {64 * 1024, 62},
14986 {32 * 1024, 1},
14987 {8 * 1024, 4},
14988 },
14989 .block_erase = spi_block_erase_d8,
14990 }, {
14991 .eraseblocks = { {4 * 1024 * 1024, 1} },
14992 .block_erase = spi_block_erase_c7,
14993 },
14994 },
14995 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
14996 .unlock = spi_disable_blockprotect_sst26_global_unprotect,
14997 .write = spi_chip_write_256, /* Multi I/O supported */
14998 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
14999 .voltage = {2700, 3600},
15000 },
15001
15002 {
15003 .vendor = "SST",
Wei Hu25584de2018-04-30 14:02:08 -070015004 .name = "SST26VF032B(A)",
15005 .bustype = BUS_SPI,
15006 .manufacture_id = SST_ID,
15007 .model_id = SST_SST26VF032B,
15008 .total_size = 4096,
15009 .page_size = 256,
15010 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
15011 .tested = TEST_UNTESTED,
15012 .probe = probe_spi_rdid,
15013 .probe_timing = TIMING_ZERO,
15014 .block_erasers =
15015 {
15016 {
15017 .eraseblocks = { {4 * 1024, 1024} },
15018 .block_erase = spi_block_erase_20,
15019 }, {
15020 .eraseblocks = {
15021 {8 * 1024, 4},
15022 {32 * 1024, 1},
15023 {64 * 1024, 62},
15024 {32 * 1024, 1},
15025 {8 * 1024, 4},
15026 },
15027 .block_erase = spi_block_erase_d8,
15028 }, {
15029 .eraseblocks = { {4 * 1024 * 1024, 1} },
15030 .block_erase = spi_block_erase_c7,
15031 },
15032 },
15033 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
15034 .unlock = spi_disable_blockprotect_sst26_global_unprotect,
15035 .write = spi_chip_write_256, /* Multi I/O supported */
15036 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
15037 .voltage = {2700, 3600},
15038 },
15039
Wei Hu25584de2018-04-30 14:02:08 -070015040 {
15041 .vendor = "SST",
15042 .name = "SST26VF064B(A)",
15043 .bustype = BUS_SPI,
15044 .manufacture_id = SST_ID,
15045 .model_id = SST_SST26VF064B,
15046 .total_size = 8192,
15047 .page_size = 256,
15048 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
15049 .tested = TEST_OK_PREW,
15050 .probe = probe_spi_rdid,
15051 .probe_timing = TIMING_ZERO,
15052 .block_erasers =
15053 {
15054 {
15055 .eraseblocks = { {4 * 1024, 2048} },
15056 .block_erase = spi_block_erase_20,
15057 }, {
15058 .eraseblocks = {
15059 {8 * 1024, 4},
15060 {32 * 1024, 1},
15061 {64 * 1024, 126},
15062 {32 * 1024, 1},
15063 {8 * 1024, 4},
15064 },
15065 .block_erase = spi_block_erase_d8,
15066 }, {
15067 .eraseblocks = { {8 * 1024 * 1024, 1} },
15068 .block_erase = spi_block_erase_c7,
15069 },
15070 },
15071 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
15072 .unlock = spi_disable_blockprotect_sst26_global_unprotect,
15073 .write = spi_chip_write_256, /* Multi I/O supported */
15074 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
15075 .voltage = {2700, 3600},
15076 },
15077
15078 {
15079 .vendor = "SST",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015080 .name = "SST28SF040A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015081 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015082 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015083 .model_id = SST_SST28SF040,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015084 .total_size = 512,
15085 .page_size = 256,
Sean Nelson35727f72010-01-28 23:55:12 +000015086 .feature_bits = 0,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015087 .tested = TEST_UNTESTED,
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015088 .probe = probe_82802ab,
Paul Menzelc07a41c2011-06-19 17:23:55 +000015089 .probe_timing = TIMING_IGNORED, /* routine doesn't use probe_timing (sst28sf040.c) */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015090 .block_erasers =
15091 {
15092 {
15093 .eraseblocks = { {128, 4096} },
15094 .block_erase = erase_sector_28sf040,
15095 }, {
15096 .eraseblocks = { {512 * 1024, 1} },
15097 .block_erase = erase_chip_28sf040,
15098 }
15099 },
Carl-Daniel Hailfinger79e67572010-10-13 21:49:30 +000015100 .unlock = unprotect_28sf040,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015101 .write = write_28sf040,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015102 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015103 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010015104 .prepare_access = prepare_memory_access,
15105 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015106 },
15107
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015108 {
15109 .vendor = "SST",
15110 .name = "SST29EE010",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015111 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015112 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015113 .model_id = SST_SST29EE010,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015114 .total_size = 128,
15115 .page_size = 128,
Sean Nelson35727f72010-01-28 23:55:12 +000015116 .feature_bits = FEATURE_LONG_RESET,
Carl-Daniel Hailfingerf52f7842010-10-08 18:52:29 +000015117 .tested = TEST_OK_PR,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015118 .probe = probe_jedec,
Stefan Tauner0554ca52013-07-25 22:54:25 +000015119 .probe_timing = 10,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015120 .block_erasers =
15121 {
15122 {
15123 .eraseblocks = { {128 * 1024, 1} },
15124 .block_erase = erase_chip_block_jedec,
15125 }
15126 },
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015127 .write = write_jedec,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015128 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015129 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010015130 .prepare_access = prepare_memory_access,
15131 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015132 },
15133
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015134 {
15135 .vendor = "SST",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015136 .name = "SST29EE020A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015137 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015138 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015139 .model_id = SST_SST29EE020A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015140 .total_size = 256,
15141 .page_size = 128,
Sean Nelson35727f72010-01-28 23:55:12 +000015142 .feature_bits = FEATURE_LONG_RESET,
Carl-Daniel Hailfingerf52f7842010-10-08 18:52:29 +000015143 .tested = TEST_OK_PRE,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015144 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000015145 .probe_timing = 10,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015146 .block_erasers =
15147 {
15148 {
15149 .eraseblocks = { {256 * 1024, 1} },
15150 .block_erase = erase_chip_block_jedec,
15151 }
15152 },
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015153 .write = write_jedec,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015154 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015155 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010015156 .prepare_access = prepare_memory_access,
15157 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015158 },
15159
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015160 {
15161 .vendor = "SST",
Alan Green1f9cc7d2019-07-01 11:10:45 +100015162 .name = "SST29LE010",
15163 .bustype = BUS_PARALLEL,
15164 .manufacture_id = SST_ID,
15165 .model_id = SST_SST29LE010,
15166 .total_size = 128,
15167 .page_size = 128,
15168 .feature_bits = FEATURE_LONG_RESET,
15169 .tested = TEST_UNTESTED,
15170 .probe = probe_jedec,
15171 .probe_timing = 10,
15172 .block_erasers =
15173 {
15174 {
15175 .eraseblocks = { {128 * 1024, 1} },
15176 .block_erase = erase_chip_block_jedec,
15177 }
15178 },
15179 .write = write_jedec,
15180 .read = read_memmapped,
15181 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010015182 .prepare_access = prepare_memory_access,
15183 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100015184 },
15185
15186 {
15187 .vendor = "SST",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015188 .name = "SST29LE020",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015189 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015190 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015191 .model_id = SST_SST29LE020,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015192 .total_size = 256,
15193 .page_size = 128,
Sean Nelson35727f72010-01-28 23:55:12 +000015194 .feature_bits = FEATURE_LONG_RESET,
Carl-Daniel Hailfingerf52f7842010-10-08 18:52:29 +000015195 .tested = TEST_OK_PRE,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015196 .probe = probe_jedec,
Stefan Tauner0554ca52013-07-25 22:54:25 +000015197 .probe_timing = 10,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015198 .block_erasers =
15199 {
15200 {
15201 .eraseblocks = { {256 * 1024, 1} },
15202 .block_erase = erase_chip_block_jedec,
15203 }
15204 },
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015205 .write = write_jedec,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015206 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015207 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010015208 .prepare_access = prepare_memory_access,
15209 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015210 },
15211
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015212 {
15213 .vendor = "SST",
15214 .name = "SST39SF010A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015215 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015216 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015217 .model_id = SST_SST39SF010,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015218 .total_size = 128,
15219 .page_size = 4096,
Sean Nelson35727f72010-01-28 23:55:12 +000015220 .feature_bits = FEATURE_EITHER_RESET,
Cristian Măgherușan-Stanciu9932c7b2011-07-07 19:56:58 +000015221 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015222 .probe = probe_jedec,
Mateusz Murawskie33890d2009-06-12 11:45:10 +000015223 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015224 .block_erasers =
15225 {
15226 {
15227 .eraseblocks = { {4 * 1024, 32} },
15228 .block_erase = erase_sector_jedec,
15229 }, {
15230 .eraseblocks = { {128 * 1024, 1} },
15231 .block_erase = erase_chip_block_jedec,
15232 }
15233 },
Sean Nelson35727f72010-01-28 23:55:12 +000015234 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015235 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015236 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010015237 .prepare_access = prepare_memory_access,
15238 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015239 },
15240
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015241 {
15242 .vendor = "SST",
15243 .name = "SST39SF020A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015244 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015245 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015246 .model_id = SST_SST39SF020,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015247 .total_size = 256,
15248 .page_size = 4096,
Sean Nelson35727f72010-01-28 23:55:12 +000015249 .feature_bits = FEATURE_EITHER_RESET,
Uwe Hermann19f46f22011-06-18 22:56:14 +000015250 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015251 .probe = probe_jedec,
Uwe Hermann431f4f72010-09-05 12:41:25 +000015252 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015253 .block_erasers =
15254 {
15255 {
15256 .eraseblocks = { {4 * 1024, 64} },
15257 .block_erase = erase_sector_jedec,
15258 }, {
15259 .eraseblocks = { {256 * 1024, 1} },
15260 .block_erase = erase_chip_block_jedec,
15261 }
15262 },
Sean Nelson35727f72010-01-28 23:55:12 +000015263 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015264 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015265 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010015266 .prepare_access = prepare_memory_access,
15267 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015268 },
15269
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015270 {
15271 .vendor = "SST",
15272 .name = "SST39SF040",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015273 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015274 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015275 .model_id = SST_SST39SF040,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015276 .total_size = 512,
15277 .page_size = 4096,
Sean Nelson35727f72010-01-28 23:55:12 +000015278 .feature_bits = FEATURE_EITHER_RESET,
Sylvain "ythier" Hitier3093f8f2011-09-03 11:22:27 +000015279 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015280 .probe = probe_jedec,
Uwe Hermann431f4f72010-09-05 12:41:25 +000015281 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015282 .block_erasers =
15283 {
15284 {
15285 .eraseblocks = { {4 * 1024, 128} },
15286 .block_erase = erase_sector_jedec,
15287 }, {
15288 .eraseblocks = { {512 * 1024, 1} },
15289 .block_erase = erase_chip_block_jedec,
15290 }
15291 },
Sean Nelson35727f72010-01-28 23:55:12 +000015292 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015293 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015294 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010015295 .prepare_access = prepare_memory_access,
15296 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015297 },
15298
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015299 {
15300 .vendor = "SST",
Alan Green1f9cc7d2019-07-01 11:10:45 +100015301 .name = "SST39SF512",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015302 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015303 .manufacture_id = SST_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +100015304 .model_id = SST_SST39SF512,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015305 .total_size = 64,
15306 .page_size = 4096,
Sean Nelson35727f72010-01-28 23:55:12 +000015307 .feature_bits = FEATURE_EITHER_RESET,
Stefan Taunerd7d423b2012-10-20 09:13:16 +000015308 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015309 .probe = probe_jedec,
Uwe Hermann431f4f72010-09-05 12:41:25 +000015310 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015311 .block_erasers =
15312 {
15313 {
15314 .eraseblocks = { {4 * 1024, 16} },
15315 .block_erase = erase_sector_jedec,
15316 }, {
15317 .eraseblocks = { {64 * 1024, 1} },
15318 .block_erase = erase_chip_block_jedec,
15319 }
15320 },
Sean Nelson35727f72010-01-28 23:55:12 +000015321 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015322 .read = read_memmapped,
Alan Green1f9cc7d2019-07-01 11:10:45 +100015323 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010015324 .prepare_access = prepare_memory_access,
15325 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015326 },
15327
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015328 {
15329 .vendor = "SST",
15330 .name = "SST39VF010",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015331 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015332 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015333 .model_id = SST_SST39VF010,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015334 .total_size = 128,
15335 .page_size = 4096,
Sean Nelson35727f72010-01-28 23:55:12 +000015336 .feature_bits = FEATURE_EITHER_RESET,
Stefan Taunerd94d25d2012-07-28 03:17:15 +000015337 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015338 .probe = probe_jedec,
Uwe Hermann431f4f72010-09-05 12:41:25 +000015339 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015340 .block_erasers =
15341 {
15342 {
15343 .eraseblocks = { {4 * 1024, 32} },
15344 .block_erase = erase_sector_jedec,
15345 }, {
15346 .eraseblocks = { {128 * 1024, 1} },
15347 .block_erase = erase_chip_block_jedec,
15348 }
15349 },
Sean Nelson35727f72010-01-28 23:55:12 +000015350 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015351 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015352 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010015353 .prepare_access = prepare_memory_access,
15354 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015355 },
15356
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015357 {
15358 .vendor = "SST",
15359 .name = "SST39VF020",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015360 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015361 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015362 .model_id = SST_SST39VF020,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015363 .total_size = 256,
15364 .page_size = 4096,
Sean Nelson35727f72010-01-28 23:55:12 +000015365 .feature_bits = FEATURE_EITHER_RESET,
Stefan Tauner5c316f92015-02-08 21:57:52 +000015366 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015367 .probe = probe_jedec,
Uwe Hermann431f4f72010-09-05 12:41:25 +000015368 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015369 .block_erasers =
15370 {
15371 {
15372 .eraseblocks = { {4 * 1024, 64} },
15373 .block_erase = erase_sector_jedec,
15374 }, {
15375 .eraseblocks = { {256 * 1024, 1} },
15376 .block_erase = erase_chip_block_jedec,
15377 }
15378 },
Sean Nelson35727f72010-01-28 23:55:12 +000015379 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015380 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015381 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010015382 .prepare_access = prepare_memory_access,
15383 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015384 },
15385
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015386 {
15387 .vendor = "SST",
15388 .name = "SST39VF040",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015389 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015390 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015391 .model_id = SST_SST39VF040,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015392 .total_size = 512,
15393 .page_size = 4096,
Sean Nelson35727f72010-01-28 23:55:12 +000015394 .feature_bits = FEATURE_EITHER_RESET,
Stefan Tauner23e10b82016-01-23 16:16:49 +000015395 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015396 .probe = probe_jedec,
Uwe Hermann431f4f72010-09-05 12:41:25 +000015397 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015398 .block_erasers =
15399 {
15400 {
15401 .eraseblocks = { {4 * 1024, 128} },
15402 .block_erase = erase_sector_jedec,
15403 }, {
15404 .eraseblocks = { {512 * 1024, 1} },
15405 .block_erase = erase_chip_block_jedec,
15406 }
15407 },
Sean Nelson35727f72010-01-28 23:55:12 +000015408 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015409 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015410 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010015411 .prepare_access = prepare_memory_access,
15412 .finish_access = finish_memory_access,
Carl-Daniel Hailfinger90eff152008-12-08 23:51:45 +000015413 },
FENG yu ningff692fb2008-12-08 18:15:10 +000015414
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015415 {
15416 .vendor = "SST",
Peter Stuge8440cc02009-01-25 23:55:12 +000015417 .name = "SST39VF080",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015418 .bustype = BUS_PARALLEL,
Mateusz Murawskie33890d2009-06-12 11:45:10 +000015419 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015420 .model_id = SST_SST39VF080,
Peter Stuge8440cc02009-01-25 23:55:12 +000015421 .total_size = 1024,
15422 .page_size = 4096,
Sean Nelson35727f72010-01-28 23:55:12 +000015423 .feature_bits = FEATURE_EITHER_RESET,
Peter Stuge8440cc02009-01-25 23:55:12 +000015424 .tested = TEST_UNTESTED,
15425 .probe = probe_jedec,
Uwe Hermann431f4f72010-09-05 12:41:25 +000015426 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015427 .block_erasers =
15428 {
15429 {
15430 .eraseblocks = { {4 * 1024, 256} },
15431 .block_erase = erase_sector_jedec,
15432 }, {
15433 .eraseblocks = { {64 * 1024, 16} },
15434 .block_erase = erase_block_jedec,
15435 }, {
15436 .eraseblocks = { {1024 * 1024, 1} },
15437 .block_erase = erase_chip_block_jedec,
15438 }
15439 },
Sean Nelson35727f72010-01-28 23:55:12 +000015440 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015441 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015442 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010015443 .prepare_access = prepare_memory_access,
15444 .finish_access = finish_memory_access,
Peter Stuge8440cc02009-01-25 23:55:12 +000015445 },
15446
15447 {
15448 .vendor = "SST",
Alan Green1f9cc7d2019-07-01 11:10:45 +100015449 .name = "SST39VF512",
15450 .bustype = BUS_PARALLEL,
15451 .manufacture_id = SST_ID,
15452 .model_id = SST_SST39VF512,
15453 .total_size = 64,
15454 .page_size = 4096,
15455 .feature_bits = FEATURE_EITHER_RESET,
15456 .tested = TEST_OK_PREW,
15457 .probe = probe_jedec,
15458 .probe_timing = 1, /* 150 ns */
15459 .block_erasers =
15460 {
15461 {
15462 .eraseblocks = { {4 * 1024, 16} },
15463 .block_erase = erase_sector_jedec,
15464 }, {
15465 .eraseblocks = { {64 * 1024, 1} },
15466 .block_erase = erase_chip_block_jedec,
15467 }
15468 },
15469 .write = write_jedec_1,
15470 .read = read_memmapped,
15471 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010015472 .prepare_access = prepare_memory_access,
15473 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100015474 },
15475
15476 {
15477 .vendor = "SST",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015478 .name = "SST49LF002A/B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015479 .bustype = BUS_FWH, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015480 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015481 .model_id = SST_SST49LF002A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015482 .total_size = 256,
15483 .page_size = 16 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +010015484 .feature_bits = FEATURE_EITHER_RESET,
Idwer Vollering67f28142011-03-06 22:26:23 +000015485 .tested = TEST_OK_PREW,
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015486 .probe = probe_jedec,
15487 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015488 .block_erasers =
15489 {
15490 {
15491 .eraseblocks = { {4 * 1024, 64} },
Sean Nelsonccf7a2a2010-03-16 03:09:10 +000015492 .block_erase = erase_sector_jedec,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015493 }, {
15494 .eraseblocks = { {16 * 1024, 16} },
Sean Nelsonccf7a2a2010-03-16 03:09:10 +000015495 .block_erase = erase_block_jedec,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015496 }, {
15497 .eraseblocks = { {256 * 1024, 1} },
15498 .block_erase = NULL, /* AA 55 80 AA 55 10, only in A/A mux mode */
15499 }
15500 },
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015501 .printlock = printlock_sst_fwhub,
Sean Nelsonccf7a2a2010-03-16 03:09:10 +000015502 .unlock = unlock_sst_fwhub,
15503 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015504 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015505 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +010015506 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010015507 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015508 },
15509
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015510 {
15511 .vendor = "SST",
15512 .name = "SST49LF003A/B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015513 .bustype = BUS_FWH, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015514 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015515 .model_id = SST_SST49LF003A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015516 .total_size = 384,
15517 .page_size = 64 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +010015518 .feature_bits = FEATURE_EITHER_RESET,
Stefan Taunereb582572012-09-21 12:52:50 +000015519 .tested = TEST_OK_PREW,
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015520 .probe = probe_jedec,
15521 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015522 .block_erasers =
15523 {
15524 {
15525 .eraseblocks = { {4 * 1024, 96} },
Sean Nelsonccf7a2a2010-03-16 03:09:10 +000015526 .block_erase = erase_sector_jedec,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015527 }, {
15528 .eraseblocks = { {64 * 1024, 6} },
Sean Nelsonccf7a2a2010-03-16 03:09:10 +000015529 .block_erase = erase_block_jedec,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015530 }, {
15531 .eraseblocks = { {384 * 1024, 1} },
15532 .block_erase = NULL, /* AA 55 80 AA 55 10, only in A/A mux mode */
15533 }
15534 },
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015535 .printlock = printlock_sst_fwhub,
Sean Nelsonccf7a2a2010-03-16 03:09:10 +000015536 .unlock = unlock_sst_fwhub,
15537 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015538 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015539 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +010015540 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010015541 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015542 },
15543
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015544 {
Carl-Daniel Hailfingera06287c2009-09-23 22:01:33 +000015545 /* Contrary to the data sheet, TBL# on the SST49LF004B affects the top 128kB (instead of 64kB)
15546 * and is only honored for 64k block erase, but not 4k sector erase.
15547 */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015548 .vendor = "SST",
15549 .name = "SST49LF004A/B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015550 .bustype = BUS_FWH, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015551 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015552 .model_id = SST_SST49LF004A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015553 .total_size = 512,
15554 .page_size = 64 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +010015555 .feature_bits = FEATURE_EITHER_RESET,
Idwer Vollering67f28142011-03-06 22:26:23 +000015556 .tested = TEST_OK_PREW,
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015557 .probe = probe_jedec,
15558 .probe_timing = 1, /* 150 ns */
Carl-Daniel Hailfingera06287c2009-09-23 22:01:33 +000015559 .block_erasers =
15560 {
15561 {
15562 .eraseblocks = { {4 * 1024, 128} },
Sean Nelsonccf7a2a2010-03-16 03:09:10 +000015563 .block_erase = erase_sector_jedec,
Carl-Daniel Hailfingera06287c2009-09-23 22:01:33 +000015564 }, {
15565 .eraseblocks = { {64 * 1024, 8} },
Sean Nelsonccf7a2a2010-03-16 03:09:10 +000015566 .block_erase = erase_block_jedec,
Carl-Daniel Hailfingera06287c2009-09-23 22:01:33 +000015567 }, {
15568 .eraseblocks = { {512 * 1024, 1} },
Sean Nelson51c83fb2010-01-20 20:55:53 +000015569 .block_erase = NULL, /* AA 55 80 AA 55 10, only in A/A mux mode */
Carl-Daniel Hailfingera06287c2009-09-23 22:01:33 +000015570 },
15571 },
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015572 .printlock = printlock_sst_fwhub,
Sean Nelsonccf7a2a2010-03-16 03:09:10 +000015573 .unlock = unlock_sst_fwhub,
15574 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015575 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015576 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +010015577 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010015578 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015579 },
15580
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015581 {
15582 .vendor = "SST",
15583 .name = "SST49LF004C",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015584 .bustype = BUS_FWH,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015585 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015586 .model_id = SST_SST49LF004C,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015587 .total_size = 512,
15588 .page_size = 4 * 1024,
15589 .tested = TEST_UNTESTED,
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015590 .probe = probe_82802ab,
Paul Menzelc07a41c2011-06-19 17:23:55 +000015591 .probe_timing = TIMING_IGNORED, /* routine doesn't use probe_timing (sst49lfxxxc.c) */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015592 .block_erasers =
15593 {
15594 {
15595 .eraseblocks = { {4 * 1024, 128} },
15596 .block_erase = erase_sector_49lfxxxc,
15597 }, {
Stefan Tauner0554ca52013-07-25 22:54:25 +000015598 .eraseblocks = {
Sean Nelson51c83fb2010-01-20 20:55:53 +000015599 {64 * 1024, 7},
15600 {32 * 1024, 1},
15601 {8 * 1024, 2},
15602 {16 * 1024, 1},
15603 },
Sean Nelson69e58112010-03-23 17:10:28 +000015604 .block_erase = erase_block_82802ab,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015605 }
15606 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000015607 .printlock = printlock_regspace2_block_eraser_1,
15608 .unlock = unlock_regspace2_block_eraser_1,
Carl-Daniel Hailfinger79e67572010-10-13 21:49:30 +000015609 .write = write_82802ab,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015610 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015611 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +010015612 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010015613 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015614 },
15615
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015616 {
15617 .vendor = "SST",
15618 .name = "SST49LF008A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015619 .bustype = BUS_FWH, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015620 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015621 .model_id = SST_SST49LF008A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015622 .total_size = 1024,
15623 .page_size = 64 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +010015624 .feature_bits = FEATURE_EITHER_RESET,
Paul Menzel018d4822011-10-21 12:33:07 +000015625 .tested = TEST_OK_PREW,
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015626 .probe = probe_jedec,
15627 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015628 .block_erasers =
15629 {
15630 {
15631 .eraseblocks = { {4 * 1024, 256} },
Sean Nelsonccf7a2a2010-03-16 03:09:10 +000015632 .block_erase = erase_sector_jedec,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015633 }, {
15634 .eraseblocks = { {64 * 1024, 16} },
Sean Nelsonccf7a2a2010-03-16 03:09:10 +000015635 .block_erase = erase_block_jedec,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015636 }, {
15637 .eraseblocks = { {1024 * 1024, 1} },
15638 .block_erase = NULL, /* AA 55 80 AA 55 10, only in A/A mux mode */
15639 }
15640 },
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015641 .printlock = printlock_sst_fwhub,
Sean Nelsonccf7a2a2010-03-16 03:09:10 +000015642 .unlock = unlock_sst_fwhub,
15643 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015644 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015645 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +010015646 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010015647 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015648 },
15649
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015650 {
15651 .vendor = "SST",
15652 .name = "SST49LF008C",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015653 .bustype = BUS_FWH,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015654 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015655 .model_id = SST_SST49LF008C,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015656 .total_size = 1024,
15657 .page_size = 4 * 1024,
15658 .tested = TEST_UNTESTED,
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015659 .probe = probe_82802ab,
Paul Menzelc07a41c2011-06-19 17:23:55 +000015660 .probe_timing = TIMING_IGNORED, /* routine doesn't use probe_timing (sst49lfxxxc.c) */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015661 .block_erasers =
15662 {
15663 {
15664 .eraseblocks = { {4 * 1024, 256} },
15665 .block_erase = erase_sector_49lfxxxc,
15666 }, {
Stefan Tauner0554ca52013-07-25 22:54:25 +000015667 .eraseblocks = {
Sean Nelson51c83fb2010-01-20 20:55:53 +000015668 {64 * 1024, 15},
15669 {32 * 1024, 1},
15670 {8 * 1024, 2},
15671 {16 * 1024, 1},
15672 },
Sean Nelson69e58112010-03-23 17:10:28 +000015673 .block_erase = erase_block_82802ab,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015674 }
15675 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000015676 .printlock = printlock_regspace2_block_eraser_1,
15677 .unlock = unlock_regspace2_block_eraser_1,
Carl-Daniel Hailfinger79e67572010-10-13 21:49:30 +000015678 .write = write_82802ab,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015679 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015680 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +010015681 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010015682 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015683 },
15684
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015685 {
15686 .vendor = "SST",
15687 .name = "SST49LF016C",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015688 .bustype = BUS_FWH,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015689 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015690 .model_id = SST_SST49LF016C,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015691 .total_size = 2048,
15692 .page_size = 4 * 1024,
Stefan Tauner23e10b82016-01-23 16:16:49 +000015693 .tested = TEST_OK_PREW,
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015694 .probe = probe_82802ab,
Paul Menzelc07a41c2011-06-19 17:23:55 +000015695 .probe_timing = TIMING_IGNORED, /* routine doesn't use probe_timing (sst49lfxxxc.c) */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015696 .block_erasers =
15697 {
15698 {
15699 .eraseblocks = { {4 * 1024, 512} },
15700 .block_erase = erase_sector_49lfxxxc,
15701 }, {
Stefan Tauner0554ca52013-07-25 22:54:25 +000015702 .eraseblocks = {
Sean Nelson51c83fb2010-01-20 20:55:53 +000015703 {64 * 1024, 31},
15704 {32 * 1024, 1},
15705 {8 * 1024, 2},
15706 {16 * 1024, 1},
15707 },
Sean Nelson69e58112010-03-23 17:10:28 +000015708 .block_erase = erase_block_82802ab,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015709 }
15710 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000015711 .printlock = printlock_regspace2_block_eraser_1,
15712 .unlock = unlock_regspace2_block_eraser_1,
Carl-Daniel Hailfinger79e67572010-10-13 21:49:30 +000015713 .write = write_82802ab,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015714 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015715 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +010015716 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010015717 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015718 },
15719
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015720 {
15721 .vendor = "SST",
15722 .name = "SST49LF020",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015723 .bustype = BUS_LPC,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015724 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015725 .model_id = SST_SST49LF020,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015726 .total_size = 256,
15727 .page_size = 16 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000015728 .feature_bits = FEATURE_EITHER_RESET,
Stefan Tauner8179be52011-06-04 13:13:34 +000015729 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015730 .probe = probe_jedec,
Uwe Hermann431f4f72010-09-05 12:41:25 +000015731 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015732 .block_erasers =
15733 {
15734 {
15735 .eraseblocks = { {4 * 1024, 64} },
15736 .block_erase = erase_sector_jedec,
15737 }, {
15738 .eraseblocks = { {16 * 1024, 16} },
15739 .block_erase = erase_block_jedec,
15740 }, {
15741 .eraseblocks = { {256 * 1024, 1} },
15742 .block_erase = NULL,
15743 }
15744 },
Sean Nelson35727f72010-01-28 23:55:12 +000015745 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015746 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015747 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010015748 .prepare_access = prepare_memory_access,
15749 .finish_access = finish_memory_access,
Sven Schnellec208dfb2009-01-07 12:35:09 +000015750 },
15751
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015752 {
15753 .vendor = "SST",
15754 .name = "SST49LF020A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015755 .bustype = BUS_LPC,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015756 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015757 .model_id = SST_SST49LF020A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015758 .total_size = 256,
Carl-Daniel Hailfingerda654322009-07-23 01:44:38 +000015759 .page_size = 4 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000015760 .feature_bits = FEATURE_EITHER_RESET,
Carl-Daniel Hailfingerf52f7842010-10-08 18:52:29 +000015761 .tested = TEST_OK_PRE,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015762 .probe = probe_jedec,
Uwe Hermann431f4f72010-09-05 12:41:25 +000015763 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015764 .block_erasers =
15765 {
15766 {
15767 .eraseblocks = { {4 * 1024, 64} },
15768 .block_erase = erase_sector_jedec,
15769 }, {
15770 .eraseblocks = { {16 * 1024, 16} },
15771 .block_erase = erase_block_jedec,
15772 }, {
15773 .eraseblocks = { {256 * 1024, 1} },
15774 .block_erase = NULL,
15775 }
15776 },
Sean Nelson35727f72010-01-28 23:55:12 +000015777 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015778 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015779 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010015780 .prepare_access = prepare_memory_access,
15781 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015782 },
15783
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015784 {
15785 .vendor = "SST",
15786 .name = "SST49LF040",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015787 .bustype = BUS_LPC,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015788 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015789 .model_id = SST_SST49LF040,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015790 .total_size = 512,
15791 .page_size = 4096,
Sean Nelson35727f72010-01-28 23:55:12 +000015792 .feature_bits = FEATURE_EITHER_RESET,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +000015793 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015794 .probe = probe_jedec,
Uwe Hermann431f4f72010-09-05 12:41:25 +000015795 .probe_timing = 1, /* 150 ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015796 .block_erasers =
15797 {
15798 {
15799 .eraseblocks = { {4 * 1024, 128} },
15800 .block_erase = erase_sector_jedec,
15801 }, {
15802 .eraseblocks = { {64 * 1024, 8} },
15803 .block_erase = erase_block_jedec,
15804 }, {
15805 .eraseblocks = { {512 * 1024, 1} },
15806 .block_erase = NULL,
15807 }
15808 },
Sean Nelson35727f72010-01-28 23:55:12 +000015809 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015810 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015811 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010015812 .prepare_access = prepare_memory_access,
15813 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015814 },
15815
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015816 {
15817 .vendor = "SST",
15818 .name = "SST49LF040B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015819 .bustype = BUS_LPC, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015820 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015821 .model_id = SST_SST49LF040B,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015822 .total_size = 512,
15823 .page_size = 64 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +010015824 .feature_bits = FEATURE_EITHER_RESET,
Stefan Tauner23e10b82016-01-23 16:16:49 +000015825 .tested = TEST_OK_PREW,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015826 .probe = probe_jedec,
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015827 .probe_timing = 1, /* 150ns */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015828 .block_erasers =
15829 {
15830 {
15831 .eraseblocks = { {4 * 1024, 128} },
15832 .block_erase = erase_sector_jedec,
15833 }, {
15834 .eraseblocks = { {64 * 1024, 8} },
15835 .block_erase = erase_block_jedec,
15836 }, {
15837 .eraseblocks = { {512 * 1024, 1} },
15838 .block_erase = NULL,
15839 }
15840 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000015841 .unlock = unlock_regspace2_uniform_64k,
Sean Nelson35727f72010-01-28 23:55:12 +000015842 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015843 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015844 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +010015845 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010015846 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015847 },
15848
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015849 {
15850 .vendor = "SST",
15851 .name = "SST49LF080A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015852 .bustype = BUS_LPC, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015853 .manufacture_id = SST_ID,
Elyes HAOUAS124ef382018-03-27 12:15:09 +020015854 .model_id = SST_SST49LF080A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015855 .total_size = 1024,
15856 .page_size = 4096,
Sean Nelson35727f72010-01-28 23:55:12 +000015857 .feature_bits = FEATURE_EITHER_RESET,
Brandon Dowdyf07bf322011-03-06 18:31:11 +000015858 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015859 .probe = probe_jedec,
Stefan Tauner0554ca52013-07-25 22:54:25 +000015860 .probe_timing = TIMING_FIXME,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015861 .block_erasers =
15862 {
15863 {
15864 .eraseblocks = { {4 * 1024, 256} },
15865 .block_erase = erase_sector_jedec,
15866 }, {
15867 .eraseblocks = { {64 * 1024, 16} },
15868 .block_erase = erase_block_jedec,
15869 }, {
15870 .eraseblocks = { {1024 * 1024, 1} },
15871 .block_erase = NULL,
15872 }
15873 },
Sean Nelson35727f72010-01-28 23:55:12 +000015874 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015875 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015876 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010015877 .prepare_access = prepare_memory_access,
15878 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015879 },
15880
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015881 {
15882 .vendor = "SST",
15883 .name = "SST49LF160C",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015884 .bustype = BUS_LPC,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015885 .manufacture_id = SST_ID,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000015886 .model_id = SST_SST49LF160C,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015887 .total_size = 2048,
15888 .page_size = 4 * 1024,
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000015889 .tested = TEST_OK_PR,
Carl-Daniel Hailfinger81449a22010-03-15 03:48:42 +000015890 .probe = probe_82802ab,
Paul Menzelc07a41c2011-06-19 17:23:55 +000015891 .probe_timing = TIMING_IGNORED, /* routine doesn't use probe_timing (sst49lfxxxc.c) */
Sean Nelson51c83fb2010-01-20 20:55:53 +000015892 .block_erasers =
15893 {
15894 {
15895 .eraseblocks = { {4 * 1024, 512} },
15896 .block_erase = erase_sector_49lfxxxc,
15897 }, {
Stefan Tauner0554ca52013-07-25 22:54:25 +000015898 .eraseblocks = {
Sean Nelson51c83fb2010-01-20 20:55:53 +000015899 {64 * 1024, 31},
15900 {32 * 1024, 1},
15901 {8 * 1024, 2},
15902 {16 * 1024, 1},
15903 },
Sean Nelson69e58112010-03-23 17:10:28 +000015904 .block_erase = erase_block_82802ab,
Sean Nelson51c83fb2010-01-20 20:55:53 +000015905 }
15906 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000015907 .printlock = printlock_regspace2_block_eraser_1,
15908 .unlock = unlock_regspace2_block_eraser_1,
Carl-Daniel Hailfinger79e67572010-10-13 21:49:30 +000015909 .write = write_82802ab,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015910 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000015911 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +010015912 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010015913 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015914 },
15915
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015916 {
15917 .vendor = "ST",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015918 .name = "M29F002B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015919 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015920 .manufacture_id = ST_ID,
15921 .model_id = ST_M29F002B,
15922 .total_size = 256,
15923 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000015924 .feature_bits = FEATURE_ADDR_AAA | FEATURE_EITHER_RESET,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015925 .tested = TEST_UNTESTED,
15926 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000015927 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson56358aa2010-01-19 16:08:51 +000015928 .block_erasers =
15929 {
15930 {
15931 .eraseblocks = {
15932 {16 * 1024, 1},
15933 {8 * 1024, 2},
15934 {32 * 1024, 1},
15935 {64 * 1024, 3},
15936 },
15937 .block_erase = erase_sector_jedec,
15938 }, {
15939 .eraseblocks = { {256 * 1024, 1} },
15940 .block_erase = erase_chip_block_jedec,
15941 }
15942 },
Sean Nelson35727f72010-01-28 23:55:12 +000015943 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015944 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +000015945 .voltage = {4750, 5250}, /* 4.75-5.25V for type -X, others 4.5-5.5V */
Nico Huber9eec4072023-01-12 01:17:30 +010015946 .prepare_access = prepare_memory_access,
15947 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015948 },
15949
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015950 {
15951 .vendor = "ST",
15952 .name = "M29F002T/NT",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015953 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015954 .manufacture_id = ST_ID,
15955 .model_id = ST_M29F002T,
15956 .total_size = 256,
15957 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000015958 .feature_bits = FEATURE_ADDR_AAA | FEATURE_EITHER_RESET,
Stefan Taunere34e3e82013-01-01 00:06:51 +000015959 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015960 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000015961 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson56358aa2010-01-19 16:08:51 +000015962 .block_erasers =
15963 {
15964 {
15965 .eraseblocks = {
15966 {64 * 1024, 3},
15967 {32 * 1024, 1},
15968 {8 * 1024, 2},
15969 {16 * 1024, 1},
15970 },
15971 .block_erase = erase_sector_jedec,
15972 }, {
15973 .eraseblocks = { {256 * 1024, 1} },
15974 .block_erase = erase_chip_block_jedec,
15975 }
15976 },
Sean Nelson35727f72010-01-28 23:55:12 +000015977 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000015978 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +000015979 .voltage = {4750, 5250}, /* 4.75-5.25V for type -X, others 4.5-5.5V */
Nico Huber9eec4072023-01-12 01:17:30 +010015980 .prepare_access = prepare_memory_access,
15981 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000015982 },
15983
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015984 {
15985 .vendor = "ST",
15986 .name = "M29F040B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000015987 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000015988 .manufacture_id = ST_ID,
15989 .model_id = ST_M29F040B,
15990 .total_size = 512,
15991 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000015992 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
15993 .tested = TEST_UNTESTED,
15994 .probe = probe_jedec,
David Borg204f4652010-12-04 03:26:40 +000015995 .probe_timing = TIMING_ZERO, /* datasheet specifies no timing */
Sean Nelson56358aa2010-01-19 16:08:51 +000015996 .block_erasers =
15997 {
15998 {
Stefan Tauner6697f712014-08-06 15:09:15 +000015999 .eraseblocks = { {64 * 1024, 8} },
Sean Nelson35727f72010-01-28 23:55:12 +000016000 .block_erase = erase_sector_jedec,
Sean Nelson56358aa2010-01-19 16:08:51 +000016001 }, {
16002 .eraseblocks = { {512 * 1024, 1} },
Sean Nelson35727f72010-01-28 23:55:12 +000016003 .block_erase = erase_chip_block_jedec,
Sean Nelson56358aa2010-01-19 16:08:51 +000016004 }
16005 },
Sean Nelson35727f72010-01-28 23:55:12 +000016006 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000016007 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016008 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010016009 .prepare_access = prepare_memory_access,
16010 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000016011 },
16012
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016013 {
Sean Nelson35727f72010-01-28 23:55:12 +000016014 /* FIXME: this has WORD/BYTE sequences; 2AA for word, 555 for byte */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016015 .vendor = "ST",
Carl-Daniel Hailfinger420cf6f2010-07-16 22:07:20 +000016016 .name = "M29F400BB",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016017 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfinger420cf6f2010-07-16 22:07:20 +000016018 .manufacture_id = ST_ID,
16019 .model_id = ST_M29F400BB,
16020 .total_size = 512,
16021 .page_size = 64 * 1024,
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +000016022 .feature_bits = FEATURE_ADDR_SHIFTED | FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Carl-Daniel Hailfinger79e67572010-10-13 21:49:30 +000016023 .tested = TEST_UNTESTED,
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +000016024 .probe = probe_jedec,
16025 .probe_timing = 10, // FIXME: check datasheet. Using the 10 us from probe_m29f400bt
Carl-Daniel Hailfinger420cf6f2010-07-16 22:07:20 +000016026 .block_erasers =
16027 {
16028 {
16029 .eraseblocks = {
16030 {16 * 1024, 1},
16031 {8 * 1024, 2},
16032 {32 * 1024, 1},
16033 {64 * 1024, 7},
16034 },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +000016035 .block_erase = erase_sector_jedec,
Carl-Daniel Hailfinger420cf6f2010-07-16 22:07:20 +000016036 }, {
16037 .eraseblocks = { {512 * 1024, 1} },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +000016038 .block_erase = erase_chip_block_jedec,
Carl-Daniel Hailfinger420cf6f2010-07-16 22:07:20 +000016039 }
16040 },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +000016041 .write = write_jedec_1,
Carl-Daniel Hailfinger420cf6f2010-07-16 22:07:20 +000016042 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016043 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010016044 .prepare_access = prepare_memory_access,
16045 .finish_access = finish_memory_access,
Carl-Daniel Hailfinger420cf6f2010-07-16 22:07:20 +000016046 },
Alan Greenfa3fcd32019-06-27 15:41:50 +100016047
Carl-Daniel Hailfinger420cf6f2010-07-16 22:07:20 +000016048 {
16049 /* FIXME: this has WORD/BYTE sequences; 2AA for word, 555 for byte */
16050 .vendor = "ST",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016051 .name = "M29F400BT",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016052 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016053 .manufacture_id = ST_ID,
16054 .model_id = ST_M29F400BT,
16055 .total_size = 512,
16056 .page_size = 64 * 1024,
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +000016057 .feature_bits = FEATURE_ADDR_SHIFTED | FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016058 .tested = TEST_UNTESTED,
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +000016059 .probe = probe_jedec,
16060 .probe_timing = 10, // FIXME: check datasheet. Using the 10 us from probe_m29f400bt
Sean Nelson56358aa2010-01-19 16:08:51 +000016061 .block_erasers =
16062 {
16063 {
16064 .eraseblocks = {
16065 {64 * 1024, 7},
16066 {32 * 1024, 1},
16067 {8 * 1024, 2},
16068 {16 * 1024, 1},
16069 },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +000016070 .block_erase = erase_sector_jedec,
Sean Nelson56358aa2010-01-19 16:08:51 +000016071 }, {
16072 .eraseblocks = { {512 * 1024, 1} },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +000016073 .block_erase = erase_chip_block_jedec,
Sean Nelson56358aa2010-01-19 16:08:51 +000016074 }
16075 },
Carl-Daniel Hailfingera8cf3622014-08-08 08:33:01 +000016076 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000016077 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016078 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010016079 .prepare_access = prepare_memory_access,
16080 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000016081 },
16082
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016083 {
16084 .vendor = "ST",
16085 .name = "M29W010B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016086 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016087 .manufacture_id = ST_ID,
16088 .model_id = ST_M29W010B,
16089 .total_size = 128,
16090 .page_size = 16 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000016091 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016092 .tested = TEST_UNTESTED,
16093 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000016094 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson56358aa2010-01-19 16:08:51 +000016095 .block_erasers =
16096 {
16097 {
Stefan Tauner6697f712014-08-06 15:09:15 +000016098 .eraseblocks = { {16 * 1024, 8} },
Sean Nelson56358aa2010-01-19 16:08:51 +000016099 .block_erase = erase_sector_jedec,
16100 }, {
16101 .eraseblocks = { {128 * 1024, 1} },
16102 .block_erase = erase_chip_block_jedec,
16103 }
16104 },
Sean Nelson35727f72010-01-28 23:55:12 +000016105 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000016106 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016107 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010016108 .prepare_access = prepare_memory_access,
16109 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000016110 },
16111
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016112 {
16113 .vendor = "ST",
16114 .name = "M29W040B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016115 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016116 .manufacture_id = ST_ID,
16117 .model_id = ST_M29W040B,
16118 .total_size = 512,
16119 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000016120 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016121 .tested = TEST_UNTESTED,
16122 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000016123 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson56358aa2010-01-19 16:08:51 +000016124 .block_erasers =
16125 {
16126 {
Stefan Tauner6697f712014-08-06 15:09:15 +000016127 .eraseblocks = { {64 * 1024, 8} },
Sean Nelson56358aa2010-01-19 16:08:51 +000016128 .block_erase = erase_sector_jedec,
16129 }, {
16130 .eraseblocks = { {512 * 1024, 1} },
16131 .block_erase = erase_chip_block_jedec,
16132 }
16133 },
Sean Nelson35727f72010-01-28 23:55:12 +000016134 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000016135 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016136 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010016137 .prepare_access = prepare_memory_access,
16138 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000016139 },
16140
Stefan Taunereb582572012-09-21 12:52:50 +000016141 {
16142 .vendor = "ST",
16143 .name = "M29W512B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016144 .bustype = BUS_PARALLEL,
Alan Greenfa3fcd32019-06-27 15:41:50 +100016145 .manufacture_id = ST_ID,
Stefan Taunereb582572012-09-21 12:52:50 +000016146 .model_id = ST_M29W512B,
16147 .total_size = 64,
16148 .page_size = 64 * 1024,
16149 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Stefan Tauner0554ca52013-07-25 22:54:25 +000016150 .tested = TEST_OK_PREW,
Stefan Taunereb582572012-09-21 12:52:50 +000016151 .probe = probe_jedec,
16152 .probe_timing = TIMING_ZERO,
16153 .block_erasers =
16154 {
16155 {
16156 .eraseblocks = { {64 * 1024, 1} },
16157 .block_erase = erase_chip_block_jedec,
16158 }
16159 },
16160 .write = write_jedec_1,
16161 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016162 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010016163 .prepare_access = prepare_memory_access,
16164 .finish_access = finish_memory_access,
Stefan Taunereb582572012-09-21 12:52:50 +000016165 },
Jeffrey A. Kentba7c9222010-02-01 05:49:46 +000016166
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016167 {
16168 .vendor = "ST",
16169 .name = "M50FLW040A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016170 .bustype = BUS_FWH | BUS_LPC, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016171 .manufacture_id = ST_ID,
16172 .model_id = ST_M50FLW040A,
16173 .total_size = 512,
Stefan Tauner4404f732013-09-12 08:28:56 +000016174 .page_size = 0,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016175 .tested = TEST_UNTESTED,
Sean Nelson35727f72010-01-28 23:55:12 +000016176 .probe = probe_82802ab,
Carl-Daniel Hailfinger08fa2f32010-01-10 01:34:00 +000016177 .probe_timing = TIMING_FIXME,
Sean Nelson56358aa2010-01-19 16:08:51 +000016178 .block_erasers =
16179 {
16180 {
Sean Nelson329bde72010-01-19 16:39:19 +000016181 .eraseblocks = {
Uwe Hermann431f4f72010-09-05 12:41:25 +000016182 {4 * 1024, 16}, /* sector */
Sean Nelson329bde72010-01-19 16:39:19 +000016183 {64 * 1024, 5}, /* block */
16184 {4 * 1024, 16}, /* sector */
16185 {4 * 1024, 16}, /* sector */
16186 },
Stefan Taunerbeaffd82013-09-12 08:29:06 +000016187 .block_erase = erase_sector_stm50,
Sean Nelson329bde72010-01-19 16:39:19 +000016188 }, {
Stefan Tauner6697f712014-08-06 15:09:15 +000016189 .eraseblocks = { {64 * 1024, 8} },
Sean Nelson28accc22010-03-19 18:47:06 +000016190 .block_erase = erase_block_82802ab,
Sean Nelson56358aa2010-01-19 16:08:51 +000016191 }
16192 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016193 .unlock = unlock_regspace2_uniform_64k,
Alan Greenc1863ca2019-06-27 15:08:03 +100016194 .write = write_82802ab,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000016195 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016196 .voltage = {3000, 3600}, /* Also has 12V fast program & erase */
Nico Huberb1974022023-01-12 13:13:12 +010016197 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010016198 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000016199 },
16200
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016201 {
16202 .vendor = "ST",
16203 .name = "M50FLW040B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016204 .bustype = BUS_FWH | BUS_LPC, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016205 .manufacture_id = ST_ID,
16206 .model_id = ST_M50FLW040B,
16207 .total_size = 512,
Stefan Tauner4404f732013-09-12 08:28:56 +000016208 .page_size = 0,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016209 .tested = TEST_UNTESTED,
Sean Nelson35727f72010-01-28 23:55:12 +000016210 .probe = probe_82802ab,
Carl-Daniel Hailfinger08fa2f32010-01-10 01:34:00 +000016211 .probe_timing = TIMING_FIXME,
Sean Nelson56358aa2010-01-19 16:08:51 +000016212 .block_erasers =
16213 {
16214 {
Sean Nelson329bde72010-01-19 16:39:19 +000016215 .eraseblocks = {
Uwe Hermann431f4f72010-09-05 12:41:25 +000016216 {4 * 1024, 16}, /* sector */
Sean Nelson329bde72010-01-19 16:39:19 +000016217 {4 * 1024, 16}, /* sector */
16218 {64 * 1024, 5}, /* block */
16219 {4 * 1024, 16}, /* sector */
16220 },
Stefan Taunerbeaffd82013-09-12 08:29:06 +000016221 .block_erase = erase_sector_stm50,
Sean Nelson329bde72010-01-19 16:39:19 +000016222 }, {
Stefan Tauner6697f712014-08-06 15:09:15 +000016223 .eraseblocks = { {64 * 1024, 8} },
Sean Nelson28accc22010-03-19 18:47:06 +000016224 .block_erase = erase_block_82802ab,
Sean Nelson56358aa2010-01-19 16:08:51 +000016225 }
16226 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016227 .unlock = unlock_regspace2_uniform_64k,
Alan Greenc1863ca2019-06-27 15:08:03 +100016228 .write = write_82802ab,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000016229 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016230 .voltage = {3000, 3600}, /* Also has 12V fast program & erase */
Nico Huberb1974022023-01-12 13:13:12 +010016231 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010016232 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000016233 },
16234
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016235 {
16236 .vendor = "ST",
16237 .name = "M50FLW080A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016238 .bustype = BUS_FWH | BUS_LPC, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016239 .manufacture_id = ST_ID,
16240 .model_id = ST_M50FLW080A,
16241 .total_size = 1024,
Stefan Tauner4404f732013-09-12 08:28:56 +000016242 .page_size = 0,
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016243 .tested = TEST_OK_PR,
Sean Nelson35727f72010-01-28 23:55:12 +000016244 .probe = probe_82802ab,
Carl-Daniel Hailfinger08fa2f32010-01-10 01:34:00 +000016245 .probe_timing = TIMING_FIXME,
Sean Nelson56358aa2010-01-19 16:08:51 +000016246 .block_erasers =
16247 {
16248 {
Sean Nelson329bde72010-01-19 16:39:19 +000016249 .eraseblocks = {
Uwe Hermann431f4f72010-09-05 12:41:25 +000016250 {4 * 1024, 16}, /* sector */
Sean Nelson329bde72010-01-19 16:39:19 +000016251 {64 * 1024, 13}, /* block */
16252 {4 * 1024, 16}, /* sector */
16253 {4 * 1024, 16}, /* sector */
16254 },
Stefan Taunerbeaffd82013-09-12 08:29:06 +000016255 .block_erase = erase_sector_stm50,
Sean Nelson329bde72010-01-19 16:39:19 +000016256 }, {
Stefan Tauner6697f712014-08-06 15:09:15 +000016257 .eraseblocks = { {64 * 1024, 16} },
Sean Nelson28accc22010-03-19 18:47:06 +000016258 .block_erase = erase_block_82802ab,
Sean Nelson56358aa2010-01-19 16:08:51 +000016259 }
16260 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016261 .printlock = printlock_regspace2_block_eraser_0,
16262 .unlock = unlock_regspace2_block_eraser_0,
Sean Nelson28accc22010-03-19 18:47:06 +000016263 .write = write_82802ab,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000016264 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016265 .voltage = {3000, 3600}, /* Also has 12V fast program & erase */
Nico Huberb1974022023-01-12 13:13:12 +010016266 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010016267 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000016268 },
16269
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016270 {
16271 .vendor = "ST",
16272 .name = "M50FLW080B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016273 .bustype = BUS_FWH | BUS_LPC, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016274 .manufacture_id = ST_ID,
16275 .model_id = ST_M50FLW080B,
16276 .total_size = 1024,
Stefan Tauner4404f732013-09-12 08:28:56 +000016277 .page_size = 0,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016278 .tested = TEST_UNTESTED,
Sean Nelson35727f72010-01-28 23:55:12 +000016279 .probe = probe_82802ab,
Carl-Daniel Hailfinger08fa2f32010-01-10 01:34:00 +000016280 .probe_timing = TIMING_FIXME,
Sean Nelson56358aa2010-01-19 16:08:51 +000016281 .block_erasers =
16282 {
16283 {
Sean Nelson329bde72010-01-19 16:39:19 +000016284 .eraseblocks = {
Uwe Hermann431f4f72010-09-05 12:41:25 +000016285 {4 * 1024, 16}, /* sector */
Sean Nelson329bde72010-01-19 16:39:19 +000016286 {4 * 1024, 16}, /* sector */
16287 {64 * 1024, 13}, /* block */
16288 {4 * 1024, 16}, /* sector */
16289 },
Stefan Taunerbeaffd82013-09-12 08:29:06 +000016290 .block_erase = erase_sector_stm50,
Sean Nelson329bde72010-01-19 16:39:19 +000016291 }, {
Stefan Tauner6697f712014-08-06 15:09:15 +000016292 .eraseblocks = { {64 * 1024, 16} },
Sean Nelson28accc22010-03-19 18:47:06 +000016293 .block_erase = erase_block_82802ab,
Sean Nelson56358aa2010-01-19 16:08:51 +000016294 }
16295 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016296 .printlock = printlock_regspace2_block_eraser_0,
16297 .unlock = unlock_regspace2_block_eraser_0,
Sean Nelson28accc22010-03-19 18:47:06 +000016298 .write = write_82802ab,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000016299 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016300 .voltage = {3000, 3600}, /* Also has 12V fast program & erase */
Nico Huberb1974022023-01-12 13:13:12 +010016301 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010016302 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000016303 },
16304
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016305 {
16306 .vendor = "ST",
16307 .name = "M50FW002",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016308 .bustype = BUS_FWH, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016309 .manufacture_id = ST_ID,
16310 .model_id = ST_M50FW002,
16311 .total_size = 256,
Stefan Tauner4404f732013-09-12 08:28:56 +000016312 .page_size = 0,
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016313 .tested = TEST_OK_PR,
Sean Nelson35727f72010-01-28 23:55:12 +000016314 .probe = probe_82802ab,
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016315 .probe_timing = TIMING_IGNORED, /* routine doesn't use probe_timing (82802ab.c) */
Sean Nelson56358aa2010-01-19 16:08:51 +000016316 .block_erasers =
16317 {
16318 {
16319 .eraseblocks = {
16320 {64 * 1024, 3},
16321 {32 * 1024, 1},
16322 {8 * 1024, 2},
16323 {16 * 1024, 1},
16324 },
Sean Nelson28accc22010-03-19 18:47:06 +000016325 .block_erase = erase_block_82802ab,
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016326 }, {
Stefan Tauner5c316f92015-02-08 21:57:52 +000016327 .eraseblocks = { {256 * 1024, 1} },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016328 .block_erase = NULL, /* Only in A/A mux mode */
Sean Nelson56358aa2010-01-19 16:08:51 +000016329 }
16330 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016331 .printlock = printlock_regspace2_block_eraser_0,
16332 .unlock = unlock_regspace2_block_eraser_0,
Sean Nelson28accc22010-03-19 18:47:06 +000016333 .write = write_82802ab,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000016334 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016335 .voltage = {3000, 3600}, /* Also has 12V fast program & erase */
Nico Huberb1974022023-01-12 13:13:12 +010016336 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010016337 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000016338 },
16339
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016340 {
16341 .vendor = "ST",
16342 .name = "M50FW016",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016343 .bustype = BUS_FWH, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016344 .manufacture_id = ST_ID,
16345 .model_id = ST_M50FW016,
16346 .total_size = 2048,
Stefan Tauner4404f732013-09-12 08:28:56 +000016347 .page_size = 0,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016348 .tested = TEST_UNTESTED,
16349 .probe = probe_82802ab,
Paul Menzelc07a41c2011-06-19 17:23:55 +000016350 .probe_timing = TIMING_IGNORED, /* routine doesn't use probe_timing (82802ab.c) */
Sean Nelson56358aa2010-01-19 16:08:51 +000016351 .block_erasers =
16352 {
16353 {
Stefan Tauner6697f712014-08-06 15:09:15 +000016354 .eraseblocks = { {64 * 1024, 32} },
Sean Nelson28accc22010-03-19 18:47:06 +000016355 .block_erase = erase_block_82802ab,
Sean Nelson56358aa2010-01-19 16:08:51 +000016356 }
16357 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016358 .unlock = unlock_regspace2_uniform_64k,
Sean Nelson28accc22010-03-19 18:47:06 +000016359 .write = write_82802ab,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000016360 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016361 .voltage = {3000, 3600}, /* Also has 12V fast program & erase */
Nico Huberb1974022023-01-12 13:13:12 +010016362 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010016363 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000016364 },
16365
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016366 {
16367 .vendor = "ST",
16368 .name = "M50FW040",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016369 .bustype = BUS_FWH, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016370 .manufacture_id = ST_ID,
16371 .model_id = ST_M50FW040,
16372 .total_size = 512,
Stefan Tauner4404f732013-09-12 08:28:56 +000016373 .page_size = 0,
Sean Nelson28accc22010-03-19 18:47:06 +000016374 .tested = TEST_OK_PR,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016375 .probe = probe_82802ab,
Paul Menzelc07a41c2011-06-19 17:23:55 +000016376 .probe_timing = TIMING_IGNORED, /* routine doesn't use probe_timing (82802ab.c) */
Sean Nelson56358aa2010-01-19 16:08:51 +000016377 .block_erasers =
16378 {
16379 {
Stefan Tauner6697f712014-08-06 15:09:15 +000016380 .eraseblocks = { {64 * 1024, 8} },
Sean Nelson28accc22010-03-19 18:47:06 +000016381 .block_erase = erase_block_82802ab,
Sean Nelson56358aa2010-01-19 16:08:51 +000016382 }
16383 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016384 .unlock = unlock_regspace2_uniform_64k,
Sean Nelson28accc22010-03-19 18:47:06 +000016385 .write = write_82802ab,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000016386 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016387 .voltage = {3000, 3600}, /* Also has 12V fast program & erase */
Nico Huberb1974022023-01-12 13:13:12 +010016388 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010016389 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000016390 },
16391
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016392 {
16393 .vendor = "ST",
16394 .name = "M50FW080",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016395 .bustype = BUS_FWH, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016396 .manufacture_id = ST_ID,
16397 .model_id = ST_M50FW080,
16398 .total_size = 1024,
Stefan Tauner4404f732013-09-12 08:28:56 +000016399 .page_size = 0,
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016400 .tested = TEST_OK_PR,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016401 .probe = probe_82802ab,
Paul Menzelc07a41c2011-06-19 17:23:55 +000016402 .probe_timing = TIMING_IGNORED, /* routine doesn't use probe_timing (82802ab.c) */
Sean Nelson56358aa2010-01-19 16:08:51 +000016403 .block_erasers =
16404 {
16405 {
Stefan Tauner6697f712014-08-06 15:09:15 +000016406 .eraseblocks = { {64 * 1024, 16} },
Sean Nelson28accc22010-03-19 18:47:06 +000016407 .block_erase = erase_block_82802ab,
Sean Nelson56358aa2010-01-19 16:08:51 +000016408 }
16409 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016410 .unlock = unlock_regspace2_uniform_64k,
Sean Nelson28accc22010-03-19 18:47:06 +000016411 .write = write_82802ab,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000016412 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016413 .voltage = {3000, 3600}, /* Also has 12V fast program & erase */
Nico Huberb1974022023-01-12 13:13:12 +010016414 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010016415 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000016416 },
16417
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016418 {
16419 .vendor = "ST",
Stefan Tauner8c4602b2013-09-12 08:29:00 +000016420 .name = "M50LPW080",
16421 .bustype = BUS_LPC, /* A/A Mux */
16422 .manufacture_id = ST_ID,
16423 .model_id = ST_M50LPW080,
16424 .total_size = 1024,
16425 .page_size = 0,
Stefan Tauner8c4602b2013-09-12 08:29:00 +000016426 .tested = TEST_UNTESTED,
16427 .probe = probe_82802ab,
16428 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
16429 .block_erasers =
16430 {
16431 {
Stefan Tauner6697f712014-08-06 15:09:15 +000016432 .eraseblocks = { {64 * 1024, 16} },
Stefan Tauner8c4602b2013-09-12 08:29:00 +000016433 .block_erase = erase_block_82802ab,
16434 }
16435 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016436 .unlock = unlock_regspace2_uniform_64k,
Stefan Tauner8c4602b2013-09-12 08:29:00 +000016437 .write = write_82802ab,
16438 .read = read_memmapped,
16439 .voltage = {3000, 3600}, /* Also has 12V fast program & erase */
Nico Huberb1974022023-01-12 13:13:12 +010016440 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010016441 .finish_access = finish_memory_access,
Stefan Tauner8c4602b2013-09-12 08:29:00 +000016442 },
16443
16444 {
16445 .vendor = "ST",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016446 .name = "M50LPW116",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000016447 .bustype = BUS_LPC, /* A/A Mux */
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016448 .manufacture_id = ST_ID,
16449 .model_id = ST_M50LPW116,
16450 .total_size = 2048,
Stefan Tauner4404f732013-09-12 08:28:56 +000016451 .page_size = 0,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016452 .tested = TEST_UNTESTED,
Sean Nelson35727f72010-01-28 23:55:12 +000016453 .probe = probe_82802ab,
Udu Ogahc04ee222009-09-05 01:31:32 +000016454 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson56358aa2010-01-19 16:08:51 +000016455 .block_erasers =
16456 {
16457 {
16458 .eraseblocks = {
16459 {4 * 1024, 16},
16460 {64 * 1024, 30},
16461 {32 * 1024, 1},
16462 {8 * 1024, 2},
16463 {16 * 1024, 1},
16464 },
Sean Nelson28accc22010-03-19 18:47:06 +000016465 .block_erase = erase_block_82802ab,
Sean Nelson56358aa2010-01-19 16:08:51 +000016466 }
16467 },
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000016468 .printlock = printlock_regspace2_block_eraser_0,
16469 .unlock = unlock_regspace2_block_eraser_0,
Sean Nelson28accc22010-03-19 18:47:06 +000016470 .write = write_82802ab,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000016471 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000016472 .voltage = {3000, 3600}, /* Also has 12V fast program & erase */
Nico Huberb1974022023-01-12 13:13:12 +010016473 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010016474 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000016475 },
16476
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000016477 {
Konstantin Grudnev3d8868c2019-07-23 00:48:54 +030016478 .vendor = "ST",
16479 .name = "M95M02",
16480 .bustype = BUS_SPI,
16481 .manufacture_id = ST_ID,
16482 .model_id = ST_M95M02,
16483 .total_size = 256,
16484 .page_size = 256,
16485 .feature_bits = FEATURE_WRSR_WREN | FEATURE_NO_ERASE | FEATURE_ERASED_ZERO,
16486 .tested = TEST_OK_PREW,
Nico Huber54557862023-05-15 12:01:04 +020016487 .spi_cmd_set = SPI95,
Konstantin Grudnev3d8868c2019-07-23 00:48:54 +030016488 .probe = probe_spi_st95,
16489 .probe_timing = TIMING_ZERO,
16490 .block_erasers =
16491 {
16492 {
16493 .eraseblocks = { {256 * 1024, 1} },
16494 .block_erase = spi_block_erase_emulation,
16495 }
16496 },
16497
16498 .printlock = spi_prettyprint_status_register_bp1_srwd,
16499 .unlock = spi_disable_blockprotect_bp1_srwd,
16500 .write = spi_chip_write_256,
16501 .read = spi_chip_read,
16502 .voltage = {2500, 5500},
16503 },
16504
16505 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100016506 .vendor = "Sanyo",
16507 .name = "LE25FU106B",
16508 .bustype = BUS_SPI,
16509 .manufacture_id = SANYO_ID,
16510 .model_id = SANYO_LE25FU106B,
16511 .total_size = 128,
16512 .page_size = 256,
16513 .feature_bits = FEATURE_WRSR_WREN,
16514 .tested = TEST_UNTESTED,
16515 .probe = probe_spi_res2,
16516 .probe_timing = TIMING_ZERO,
16517 .block_erasers =
16518 {
16519 /* FIXME: Is this correct?
16520 {
16521 .eraseblocks = { {2 * 1024, 64} },
16522 .block_erase = spi_block_erase_d7,
16523 },*/
16524 {
16525 .eraseblocks = { {32 * 1024, 4} },
16526 .block_erase = spi_block_erase_d8,
16527 }, {
16528 .eraseblocks = { {128 * 1024, 1} },
16529 .block_erase = spi_block_erase_c7,
16530 }
16531 },
16532 .printlock = spi_prettyprint_status_register_bp1_srwd,
16533 .unlock = spi_disable_blockprotect_bp1_srwd,
16534 .write = spi_chip_write_256,
16535 .read = spi_chip_read,
16536 .voltage = {2300, 3600},
16537 },
16538
16539 {
16540 .vendor = "Sanyo",
16541 .name = "LE25FU206",
16542 .bustype = BUS_SPI,
16543 .manufacture_id = SANYO_ID,
16544 .model_id = SANYO_LE25FU206,
16545 .total_size = 256,
16546 .page_size = 256,
16547 .feature_bits = FEATURE_WRSR_WREN,
16548 .tested = TEST_UNTESTED,
16549 .probe = probe_spi_res2,
16550 .probe_timing = TIMING_ZERO,
16551 .block_erasers =
16552 {
16553 {
16554 .eraseblocks = { {4 * 1024, 64} },
16555 .block_erase = spi_block_erase_d7,
16556 }, {
16557 .eraseblocks = { {64 * 1024, 4} },
16558 .block_erase = spi_block_erase_d8,
16559 }, {
16560 .eraseblocks = { {256 * 1024, 1} },
16561 .block_erase = spi_block_erase_c7,
16562 }
16563 },
16564 .printlock = spi_prettyprint_status_register_bp1_srwd,
16565 .unlock = spi_disable_blockprotect_bp1_srwd,
16566 .write = spi_chip_write_256,
16567 .read = spi_chip_read,
16568 .voltage = {2300, 3600},
16569 },
16570
16571 {
16572 .vendor = "Sanyo",
16573 .name = "LE25FU206A",
16574 .bustype = BUS_SPI,
16575 .manufacture_id = SANYO_ID,
16576 .model_id = SANYO_LE25FU206A,
16577 .total_size = 256,
16578 .page_size = 256,
16579 .tested = TEST_UNTESTED,
16580 .probe = probe_spi_rdid,
16581 .probe_timing = TIMING_ZERO,
16582 .block_erasers =
16583 {
16584 {
16585 .eraseblocks = { {4 * 1024, 64} },
16586 .block_erase = spi_block_erase_20,
16587 }, {
16588 .eraseblocks = { {4 * 1024, 64} },
16589 .block_erase = spi_block_erase_d7,
16590 }, {
16591 .eraseblocks = { {64 * 1024, 4} },
16592 .block_erase = spi_block_erase_d8,
16593 }, {
16594 .eraseblocks = { {256 * 1024, 1} },
16595 .block_erase = spi_block_erase_60,
16596 }, {
16597 .eraseblocks = { {256 * 1024, 1} },
16598 .block_erase = spi_block_erase_c7,
16599 }
16600 },
16601 .printlock = spi_prettyprint_status_register_bp2_srwd,
16602 .unlock = spi_disable_blockprotect, /* #WP pin write-protects SRWP bit. */
16603 .write = spi_chip_write_256,
16604 .read = spi_chip_read,
16605 .voltage = {2300, 3600},
16606 },
16607
16608 {
16609 .vendor = "Sanyo",
16610 .name = "LE25FU406B",
16611 .bustype = BUS_SPI,
16612 .manufacture_id = SANYO_ID,
16613 .model_id = SANYO_LE25FU406B,
16614 .total_size = 512,
16615 .page_size = 256,
16616 .feature_bits = FEATURE_WRSR_WREN,
16617 .tested = TEST_OK_PREW,
16618 .probe = probe_spi_res2,
16619 .probe_timing = TIMING_ZERO,
16620 .block_erasers =
16621 {
16622 {
16623 .eraseblocks = { {4 * 1024, 128} },
16624 .block_erase = spi_block_erase_d7,
16625 }, {
16626 .eraseblocks = { {64 * 1024, 8} },
16627 .block_erase = spi_block_erase_d8,
16628 }, {
16629 .eraseblocks = { {512 * 1024, 1} },
16630 .block_erase = spi_block_erase_c7,
16631 }
16632 },
16633 .printlock = spi_prettyprint_status_register_bp2_srwd,
16634 .unlock = spi_disable_blockprotect, /* #WP pin write-protects SRWP bit. */
16635 .write = spi_chip_write_256,
16636 .read = spi_chip_read,
16637 .voltage = {2300, 3600},
16638 },
16639
16640 {
16641 .vendor = "Sanyo",
16642 .name = "LE25FU406C/LE25U40CMC",
16643 .bustype = BUS_SPI,
16644 .manufacture_id = SANYO_ID,
16645 .model_id = SANYO_LE25FU406C,
16646 .total_size = 512,
16647 .page_size = 256,
16648 .feature_bits = FEATURE_WRSR_WREN,
16649 .tested = TEST_OK_PREW,
16650 .probe = probe_spi_rdid,
16651 .probe_timing = TIMING_ZERO,
16652 .block_erasers =
16653 {
16654 {
16655 .eraseblocks = { {4 * 1024, 128} },
16656 .block_erase = spi_block_erase_20,
16657 }, {
16658 .eraseblocks = { {4 * 1024, 128} },
16659 .block_erase = spi_block_erase_d7,
16660 }, {
16661 .eraseblocks = { {64 * 1024, 8} },
16662 .block_erase = spi_block_erase_d8,
16663 }, {
16664 .eraseblocks = { {512 * 1024, 1} },
16665 .block_erase = spi_block_erase_60,
16666 }, {
16667 .eraseblocks = { {512 * 1024, 1} },
16668 .block_erase = spi_block_erase_c7,
16669 }
16670 },
16671 .printlock = spi_prettyprint_status_register_bp2_srwd,
16672 .unlock = spi_disable_blockprotect_bp2_srwd,
16673 .write = spi_chip_write_256,
16674 .read = spi_chip_read, /* Fast read (0x0B), dual read (0x3B) and dual I/O (0xBB) supported */
16675 .voltage = {2300, 3600},
16676 },
16677
16678 {
16679 .vendor = "Sanyo",
16680 .name = "LE25FW106",
16681 .bustype = BUS_SPI,
16682 .manufacture_id = SANYO_ID,
16683 .model_id = SANYO_LE25FW106,
16684 .total_size = 128,
16685 .page_size = 256,
16686 .feature_bits = FEATURE_WRSR_WREN,
16687 .tested = TEST_OK_PREW,
16688 .probe = probe_spi_res2,
16689 .probe_timing = TIMING_ZERO,
16690 .block_erasers =
16691 {
16692 {
16693 .eraseblocks = { {2 * 1024, 64} },
16694 .block_erase = spi_block_erase_d7,
16695 }, {
16696 .eraseblocks = { {32 * 1024, 4} },
16697 .block_erase = spi_block_erase_d8,
16698 }, {
16699 .eraseblocks = { {128 * 1024, 1} },
16700 .block_erase = spi_block_erase_c7,
16701 }
16702 },
16703 .printlock = spi_prettyprint_status_register_bp1_srwd, /* FIXME: Add ERSER error flag. */
16704 .unlock = spi_disable_blockprotect_bp1_srwd,
16705 .write = spi_chip_write_256,
16706 .read = spi_chip_read,
16707 .voltage = {2700, 3600},
16708 },
16709
16710 {
16711 .vendor = "Sanyo",
16712 .name = "LE25FW203A",
16713 .bustype = BUS_SPI,
16714 .manufacture_id = SANYO_ID,
16715 .model_id = SANYO_LE25FW203A,
16716 .total_size = 256,
16717 .page_size = 256,
16718 .tested = TEST_UNTESTED,
16719 .probe = probe_spi_rdid,
16720 .probe_timing = TIMING_ZERO,
16721 .block_erasers =
16722 {
16723 {
16724 .eraseblocks = { {256, 1024} },
16725 .block_erase = spi_block_erase_db,
16726 }, {
16727 .eraseblocks = { {64 * 1024, 4} },
16728 .block_erase = spi_block_erase_d8,
16729 }, {
16730 .eraseblocks = { {256 * 1024, 1} },
16731 .block_erase = spi_block_erase_c7,
16732 }
16733 },
16734 .printlock = spi_prettyprint_status_register_default_welwip,
16735 .unlock = NULL, /* #WP pin write-protects lower 64kB. */
16736 .write = spi_chip_write_256,
16737 .read = spi_chip_read,
16738 .voltage = {2700, 3600},
16739 },
16740
16741 {
16742 .vendor = "Sanyo",
16743 .name = "LE25FW403A",
16744 .bustype = BUS_SPI,
16745 .manufacture_id = SANYO_ID,
16746 .model_id = SANYO_LE25FW403A,
16747 .total_size = 512,
16748 .page_size = 256,
16749 .tested = TEST_UNTESTED,
16750 .probe = probe_spi_rdid,
16751 .probe_timing = TIMING_ZERO,
16752 .block_erasers =
16753 {
16754 {
16755 .eraseblocks = { {256, 2 * 1024} },
16756 .block_erase = spi_block_erase_db,
16757 }, {
16758 .eraseblocks = { {64 * 1024, 8} },
16759 .block_erase = spi_block_erase_d8,
16760 }, {
16761 .eraseblocks = { {512 * 1024, 1} },
16762 .block_erase = spi_block_erase_c7,
16763 }
16764 },
16765 .printlock = spi_prettyprint_status_register_default_welwip,
16766 .unlock = NULL, /* #WP pin write-protects lower 64kB. */
16767 .write = spi_chip_write_256,
16768 .read = spi_chip_read,
16769 .voltage = {2700, 3600},
16770 },
16771
16772 {
16773 .vendor = "Sanyo",
16774 .name = "LE25FW406A",
16775 .bustype = BUS_SPI,
16776 .manufacture_id = SANYO_ID,
16777 .model_id = SANYO_LE25FW406A,
16778 .total_size = 512,
16779 .page_size = 256,
16780 .feature_bits = FEATURE_WRSR_WREN,
16781 .tested = TEST_OK_PREW,
16782 .probe = probe_spi_res2,
16783 .probe_timing = TIMING_ZERO,
16784 .block_erasers =
16785 {
16786 {
16787 .eraseblocks = { {4 * 1024, 128} },
16788 .block_erase = spi_block_erase_d7,
16789 }, {
16790 .eraseblocks = { {64 * 1024, 8} },
16791 .block_erase = spi_block_erase_d8,
16792 }, {
16793 .eraseblocks = { {512 * 1024, 1} },
16794 .block_erase = spi_block_erase_c7,
16795 }
16796 },
16797 .printlock = spi_prettyprint_status_register_plain,
16798 .unlock = spi_disable_blockprotect,
16799 .write = spi_chip_write_256,
16800 .read = spi_chip_read,
16801 .voltage = {2700, 3600},
16802 },
16803
16804 {
16805 .vendor = "Sanyo",
16806 .name = "LE25FW418A",
16807 .bustype = BUS_SPI,
16808 .manufacture_id = SANYO_ID,
16809 .model_id = SANYO_LE25FW418A,
16810 .total_size = 512,
16811 .page_size = 256,
16812 .feature_bits = FEATURE_WRSR_WREN,
16813 .tested = TEST_UNTESTED,
16814 .probe = probe_spi_res2,
16815 .probe_timing = TIMING_ZERO,
16816 .block_erasers =
16817 {
16818 {
16819 .eraseblocks = { {4 * 1024, 128} },
16820 .block_erase = spi_block_erase_d7,
16821 }, {
16822 .eraseblocks = { {64 * 1024, 8} },
16823 .block_erase = spi_block_erase_d8,
16824 }, {
16825 .eraseblocks = { {512 * 1024, 1} },
16826 .block_erase = spi_block_erase_c7,
16827 }
16828 },
16829 .printlock = spi_prettyprint_status_register_bp2_srwd,
16830 .unlock = spi_disable_blockprotect, /* #WP pin write-protects SRWP bit. */
16831 .write = spi_chip_write_256,
16832 .read = spi_chip_read, /* some quad-read supported ("HD_READ mode") */
16833 .voltage = {2700, 3600},
16834 },
16835
16836 {
16837 .vendor = "Sanyo",
16838 .name = "LE25FW806",
16839 .bustype = BUS_SPI,
16840 .manufacture_id = SANYO_ID,
16841 .model_id = SANYO_LE25FW806,
16842 .total_size = 1024,
16843 .page_size = 256,
16844 .feature_bits = FEATURE_WRSR_WREN,
16845 .tested = TEST_UNTESTED,
16846 .probe = probe_spi_res2,
16847 .probe_timing = TIMING_ZERO,
16848 .block_erasers =
16849 {
16850 {
16851 .eraseblocks = { {4 * 1024, 256} },
16852 .block_erase = spi_block_erase_20,
16853 }, {
16854 .eraseblocks = { {4 * 1024, 256} },
16855 .block_erase = spi_block_erase_d7,
16856 }, {
16857 .eraseblocks = { {64 * 1024, 16} },
16858 .block_erase = spi_block_erase_d8,
16859 }, {
16860 .eraseblocks = { {1024 * 1024, 1} },
16861 .block_erase = spi_block_erase_c7,
16862 }
16863 },
16864 .printlock = spi_prettyprint_status_register_bp2_srwd,
16865 .unlock = spi_disable_blockprotect, /* #WP pin write-protects SRWP bit. */
16866 .write = spi_chip_write_256,
16867 .read = spi_chip_read,
16868 .voltage = {2700, 3600},
16869 },
16870
16871 {
16872 .vendor = "Sanyo",
16873 .name = "LE25FW808",
16874 .bustype = BUS_SPI,
16875 .manufacture_id = SANYO_ID,
16876 .model_id = SANYO_LE25FW808,
16877 .total_size = 1024,
16878 .page_size = 256,
16879 .feature_bits = FEATURE_WRSR_WREN,
16880 .tested = TEST_UNTESTED,
16881 .probe = probe_spi_res2,
16882 .probe_timing = TIMING_ZERO,
16883 .block_erasers =
16884 {
16885 {
16886 .eraseblocks = { {8 * 1024, 128} },
16887 .block_erase = spi_block_erase_d7,
16888 }, {
16889 .eraseblocks = { {64 * 1024, 16} },
16890 .block_erase = spi_block_erase_d8,
16891 }, {
16892 .eraseblocks = { {1024 * 1024, 1} },
16893 .block_erase = spi_block_erase_c7,
16894 }
16895 },
16896 .printlock = spi_prettyprint_status_register_bp2_srwd,
16897 .unlock = spi_disable_blockprotect, /* #WP pin write-protects SRWP bit. */
16898 .write = spi_chip_write_256,
16899 .read = spi_chip_read, /* some quad-read supported ("HD_READ mode") */
16900 .voltage = {2700, 3600},
16901 },
16902
16903 {
16904 .vendor = "Sharp",
16905 .name = "LH28F008BJT-BTLZ1",
16906 .bustype = BUS_PARALLEL,
16907 .manufacture_id = SHARP_ID,
16908 .model_id = SHARP_LH28F008BJ__PB,
16909 .total_size = 1024,
16910 .page_size = 64 * 1024,
16911 .tested = TEST_OK_PREW,
16912 .probe = probe_82802ab,
16913 .probe_timing = TIMING_ZERO,
16914 .block_erasers =
16915 {
16916 {
16917 .eraseblocks = {
16918 {8 * 1024, 8},
16919 {64 * 1024, 15}
16920 },
16921 .block_erase = erase_block_82802ab,
16922 }, {
16923 .eraseblocks = { {1024 * 1024, 1} },
16924 .block_erase = erase_sector_49lfxxxc,
16925 }
16926 },
16927 .unlock = unlock_lh28f008bjt,
16928 .write = write_82802ab,
16929 .read = read_memmapped,
16930 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010016931 .prepare_access = prepare_memory_access,
16932 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100016933 },
16934
16935 {
16936 .vendor = "Sharp",
16937 .name = "LHF00L04",
16938 .bustype = BUS_FWH, /* A/A Mux */
16939 .manufacture_id = SHARP_ID,
16940 .model_id = SHARP_LHF00L04,
16941 .total_size = 1024,
16942 .page_size = 64 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +010016943 .feature_bits = FEATURE_EITHER_RESET,
Alan Green1f9cc7d2019-07-01 11:10:45 +100016944 .tested = TEST_UNTESTED,
16945 .probe = probe_82802ab,
16946 .probe_timing = TIMING_ZERO,
16947 .block_erasers =
16948 {
16949 {
16950 .eraseblocks = {
16951 {64 * 1024, 15},
16952 {8 * 1024, 8}
16953 },
16954 .block_erase = erase_block_82802ab,
16955 }, {
16956 .eraseblocks = {
16957 {1024 * 1024, 1}
16958 },
16959 .block_erase = NULL, /* 30 D0, only in A/A mux mode */
16960 },
16961 },
16962 .unlock = unlock_regspace2_uniform_64k,
16963 .write = write_82802ab,
16964 .read = read_memmapped,
16965 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +010016966 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010016967 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100016968 },
16969
16970 {
16971 .vendor = "Spansion",
16972 .name = "S25FL004A",
16973 .bustype = BUS_SPI,
16974 .manufacture_id = SPANSION_ID,
16975 .model_id = SPANSION_S25FL004A,
16976 .total_size = 512,
16977 .page_size = 256,
16978 .feature_bits = FEATURE_WRSR_WREN,
16979 .tested = TEST_UNTESTED,
16980 .probe = probe_spi_rdid,
16981 .probe_timing = TIMING_ZERO,
16982 .block_erasers =
16983 {
16984 {
16985 .eraseblocks = { {64 * 1024, 8} },
16986 .block_erase = spi_block_erase_d8,
16987 }, {
16988 .eraseblocks = { {512 * 1024, 1} },
16989 .block_erase = spi_block_erase_c7,
16990 }
16991 },
16992 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
16993 .unlock = spi_disable_blockprotect,
16994 .write = spi_chip_write_256,
16995 .read = spi_chip_read,
16996 .voltage = {2700, 3600},
16997 },
16998
16999 {
17000 .vendor = "Spansion",
17001 .name = "S25FL008A",
17002 .bustype = BUS_SPI,
17003 .manufacture_id = SPANSION_ID,
17004 .model_id = SPANSION_S25FL008A,
17005 .total_size = 1024,
17006 .page_size = 256,
17007 .feature_bits = FEATURE_WRSR_WREN,
17008 .tested = TEST_OK_PRE,
17009 .probe = probe_spi_rdid,
17010 .probe_timing = TIMING_ZERO,
17011 .block_erasers =
17012 {
17013 {
17014 .eraseblocks = { {64 * 1024, 16} },
17015 .block_erase = spi_block_erase_d8,
17016 }, {
17017 .eraseblocks = { {1024 * 1024, 1} },
17018 .block_erase = spi_block_erase_c7,
17019 }
17020 },
17021 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
17022 .unlock = spi_disable_blockprotect,
17023 .write = spi_chip_write_256,
17024 .read = spi_chip_read,
17025 .voltage = {2700, 3600},
17026 },
17027
17028 {
17029 .vendor = "Spansion",
17030 .name = "S25FL016A",
17031 .bustype = BUS_SPI,
17032 .manufacture_id = SPANSION_ID,
17033 .model_id = SPANSION_S25FL016A,
17034 .total_size = 2048,
17035 .page_size = 256,
17036 .feature_bits = FEATURE_WRSR_WREN,
17037 .tested = TEST_OK_PREW,
17038 .probe = probe_spi_rdid,
17039 .probe_timing = TIMING_ZERO,
17040 .block_erasers =
17041 {
17042 {
17043 .eraseblocks = { {64 * 1024, 32} },
17044 .block_erase = spi_block_erase_d8,
17045 }, {
17046 .eraseblocks = { {2 * 1024 * 1024, 1} },
17047 .block_erase = spi_block_erase_c7,
17048 }
17049 },
17050 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
17051 .unlock = spi_disable_blockprotect,
17052 .write = spi_chip_write_256,
17053 .read = spi_chip_read,
17054 .voltage = {2700, 3600},
17055 },
17056
17057 {
17058 .vendor = "Spansion",
17059 .name = "S25FL032A/P",
17060 .bustype = BUS_SPI,
17061 .manufacture_id = SPANSION_ID,
17062 .model_id = SPANSION_S25FL032A,
17063 .total_size = 4096,
17064 .page_size = 256,
17065 .feature_bits = FEATURE_WRSR_WREN,
17066 .tested = TEST_OK_PREW,
17067 .probe = probe_spi_rdid,
17068 .probe_timing = TIMING_ZERO,
17069 .block_erasers =
17070 {
17071 {
17072 .eraseblocks = { {64 * 1024, 64} },
17073 .block_erase = spi_block_erase_d8,
17074 }, {
17075 .eraseblocks = { {4 * 1024 * 1024, 1} },
17076 .block_erase = spi_block_erase_c7,
17077 }
17078 },
17079 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
17080 .unlock = spi_disable_blockprotect,
17081 .write = spi_chip_write_256,
17082 .read = spi_chip_read,
17083 .voltage = {2700, 3600},
17084 },
17085
17086 {
17087 .vendor = "Spansion",
17088 .name = "S25FL064A/P",
17089 .bustype = BUS_SPI,
17090 .manufacture_id = SPANSION_ID,
17091 .model_id = SPANSION_S25FL064A,
17092 .total_size = 8192,
17093 .page_size = 256,
17094 .feature_bits = FEATURE_WRSR_WREN,
17095 .tested = TEST_OK_PREW,
17096 .probe = probe_spi_rdid,
17097 .probe_timing = TIMING_ZERO,
17098 .block_erasers =
17099 {
17100 {
17101 .eraseblocks = { {64 * 1024, 128} },
17102 .block_erase = spi_block_erase_d8,
17103 }, {
17104 .eraseblocks = { {8 * 1024 * 1024, 1} },
17105 .block_erase = spi_block_erase_c7,
17106 }
17107 },
17108 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
17109 .unlock = spi_disable_blockprotect,
17110 .write = spi_chip_write_256,
17111 .read = spi_chip_read,
17112 .voltage = {2700, 3600},
17113 },
17114
17115 {
17116 .vendor = "Spansion",
17117 .name = "S25FL116K/S25FL216K", /* FIXME: separate them */
17118 .bustype = BUS_SPI,
17119 .manufacture_id = SPANSION_ID,
17120 .model_id = SPANSION_S25FL216,
17121 .total_size = 2048,
17122 .page_size = 256,
17123 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44 (S25FL116K only) */
17124 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
17125 .tested = TEST_UNTESTED,
17126 .probe = probe_spi_rdid,
17127 .probe_timing = TIMING_ZERO,
17128 .block_erasers =
17129 {
17130 {
17131 .eraseblocks = { {4 * 1024, 512} },
17132 .block_erase = spi_block_erase_20,
17133 }, {
17134 .eraseblocks = { {64 * 1024, 32} },
17135 .block_erase = spi_block_erase_d8,
17136 }, {
17137 .eraseblocks = { { 2048 * 1024, 1} },
17138 .block_erase = spi_block_erase_60,
17139 }, {
17140 .eraseblocks = { { 2048 * 1024, 1} },
17141 .block_erase = spi_block_erase_c7,
17142 }
17143 },
17144 .printlock = spi_prettyprint_status_register_bp3_srwd,
17145 .unlock = spi_disable_blockprotect_bp3_srwd, /* #WP pin write-protects SRWP bit. */
17146 .write = spi_chip_write_256,
17147 .read = spi_chip_read, /* Fast read (0x0B) and dual I/O (0x3B) supported */
17148 .voltage = {2700, 3600},
17149 },
17150
17151 {
17152 .vendor = "Spansion",
17153 .name = "S25FL127S-256kB", /* uniform 256kB sectors */
17154 .bustype = BUS_SPI,
17155 .manufacture_id = SPANSION_ID,
17156 .model_id = SPANSION_S25FL128,
17157 .total_size = 16384,
17158 .page_size = 512,
17159 /* supports 4B addressing */
17160 /* OTP: 1024B total, 32B reserved; read 0x4B; write 0x42 */
17161 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
17162 .tested = TEST_UNTESTED,
17163 .probe = probe_spi_rdid,
17164 .probe_timing = TIMING_ZERO,
17165 .block_erasers =
17166 {
17167 {
17168 .eraseblocks = { {256 * 1024, 64} },
17169 .block_erase = spi_block_erase_d8,
17170 }, {
17171 .eraseblocks = { { 16384 * 1024, 1} },
17172 .block_erase = spi_block_erase_60,
17173 }, {
17174 .eraseblocks = { { 16384 * 1024, 1} },
17175 .block_erase = spi_block_erase_c7,
17176 }
17177 },
17178 .printlock = spi_prettyprint_status_register_bp2_srwd,
17179 .unlock = spi_disable_blockprotect_bp2_srwd, /* #WP pin write-protects SRWP bit. */
17180 .write = spi_chip_write_256, /* Multi I/O supported */
17181 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
17182 .voltage = {2700, 3600},
17183 },
17184
17185 {
17186 .vendor = "Spansion",
17187 .name = "S25FL127S-64kB", /* hybrid: 32 (top or bottom) 4 kB sub-sectors + 64 kB sectors */
17188 .bustype = BUS_SPI,
17189 .manufacture_id = SPANSION_ID,
17190 .model_id = SPANSION_S25FL128,
17191 .total_size = 16384,
17192 .page_size = 256,
17193 /* supports 4B addressing */
17194 /* OTP: 1024B total, 32B reserved; read 0x4B; write 0x42 */
17195 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
17196 .tested = TEST_OK_PREW,
17197 /* FIXME: we should distinguish the configuration on probing time like we do for AT45DB chips */
17198 .probe = probe_spi_rdid,
17199 .probe_timing = TIMING_ZERO,
17200 .block_erasers =
17201 {
17202 {
17203 /* This chip supports erasing of 32 so-called "parameter sectors" with
17204 * opcode 0x20 which may be configured to be on top or bottom of the address
17205 * space. Trying to access an address outside these 4kB blocks does have no
17206 * effect on the memory contents, e.g.
17207 .eraseblocks = {
17208 {4 * 1024, 32},
17209 {64 * 1024, 254} // inaccessible
17210 },
17211 .block_erase = spi_block_erase_20,
17212 }, { */
17213 .eraseblocks = { { 64 * 1024, 256} },
17214 .block_erase = spi_block_erase_d8,
17215 }, {
17216 .eraseblocks = { { 16384 * 1024, 1} },
17217 .block_erase = spi_block_erase_60,
17218 }, {
17219 .eraseblocks = { { 16384 * 1024, 1} },
17220 .block_erase = spi_block_erase_c7,
17221 }
17222 },
17223 .printlock = spi_prettyprint_status_register_bp2_srwd,
17224 .unlock = spi_disable_blockprotect_bp2_srwd, /* #WP pin write-protects SRWP bit. */
17225 .write = spi_chip_write_256, /* Multi I/O supported */
17226 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
17227 .voltage = {2700, 3600},
17228 },
17229
17230 {
17231 .vendor = "Spansion",
Nico Huberfffc48d2022-05-28 14:26:06 +020017232 .name = "S25FL128L",
17233 .bustype = BUS_SPI,
17234 .manufacture_id = SPANSION_ID,
17235 .model_id = SPANSION_S25FL128L,
17236 .total_size = 16384,
17237 .page_size = 256,
17238 /* 4 x 256B Security Region (OTP) */
17239 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT3 | FEATURE_OTP,
17240 .tested = TEST_UNTESTED,
17241 .probe = probe_spi_rdid,
17242 .probe_timing = TIMING_ZERO,
17243 .block_erasers =
17244 {
17245 {
17246 .eraseblocks = { {4 * 1024, 4096} },
17247 .block_erase = spi_block_erase_20,
17248 }, {
17249 .eraseblocks = { {32 * 1024, 512} },
17250 .block_erase = spi_block_erase_52,
17251 }, {
17252 .eraseblocks = { {64 * 1024, 256} },
17253 .block_erase = spi_block_erase_d8,
17254 }, {
17255 .eraseblocks = { {16384 * 1024, 1} },
17256 .block_erase = spi_block_erase_60,
17257 }, {
17258 .eraseblocks = { {16384 * 1024, 1} },
17259 .block_erase = spi_block_erase_c7,
17260 }
17261 },
17262 .printlock = spi_prettyprint_status_register_bp2_srwd,
17263 .unlock = spi_disable_blockprotect_bp2_srwd,
17264 .write = spi_chip_write_256,
17265 .read = spi_chip_read, /* Fast read (0x0B) supported */
17266 .voltage = {2700, 3600},
17267 .reg_bits =
17268 {
17269 /*
17270 * Note: This chip has a read-only Status Register 2 that is not
17271 * counted here. Registers are mapped as follows:
17272 * STATUS1 ... Status Register 1
17273 * STATUS2 ... Configuration Register 1
17274 * STATUS3 ... Configuration Register 2
17275 */
17276 .srp = {STATUS1, 7, RW},
17277 .srl = {STATUS2, 0, RW},
17278 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
17279 .tb = {STATUS1, 5, RW},
17280 .sec = {STATUS1, 6, RW},
17281 .cmp = {STATUS2, 6, RW},
17282 .wps = {STATUS3, 2, RW},
17283 },
Nico Huberaabb3e02023-01-13 00:22:30 +010017284 .wp_write_cfg = spi_wp_write_cfg,
17285 .wp_read_cfg = spi_wp_read_cfg,
17286 .wp_get_ranges = spi_wp_get_available_ranges,
Nico Huberfffc48d2022-05-28 14:26:06 +020017287 .decode_range = decode_range_spi25,
17288 },
17289
17290 {
17291 .vendor = "Spansion",
Alan Green1f9cc7d2019-07-01 11:10:45 +100017292 .name = "S25FL128P......0", /* uniform 64 kB sectors */
17293 .bustype = BUS_SPI,
17294 .manufacture_id = SPANSION_ID,
17295 .model_id = SPANSION_S25FL128,
17296 .total_size = 16384,
17297 .page_size = 256,
17298 .feature_bits = FEATURE_WRSR_WREN,
17299 .tested = TEST_OK_PREW,
17300 .probe = probe_spi_rdid,
17301 .probe_timing = TIMING_ZERO,
17302 .block_erasers =
17303 {
17304 {
17305 .eraseblocks = { {64 * 1024, 256} },
17306 .block_erase = spi_block_erase_20,
17307 }, {
17308 .eraseblocks = { {64 * 1024, 256} },
17309 .block_erase = spi_block_erase_d8,
17310 }, {
17311 .eraseblocks = { { 16384 * 1024, 1} },
17312 .block_erase = spi_block_erase_60,
17313 }, {
17314 .eraseblocks = { { 16384 * 1024, 1} },
17315 .block_erase = spi_block_erase_c7,
17316 }
17317 },
17318 .printlock = spi_prettyprint_status_register_bp3_srwd,
17319 .unlock = spi_disable_blockprotect_bp3_srwd,
17320 .write = spi_chip_write_256,
17321 .read = spi_chip_read, /* Fast read (0x0B) supported */
17322 .voltage = {2700, 3600},
17323 },
17324
17325 {
17326 .vendor = "Spansion",
17327 .name = "S25FL128P......1", /* uniform 256kB sectors */
17328 .bustype = BUS_SPI,
17329 .manufacture_id = SPANSION_ID,
17330 .model_id = SPANSION_S25FL128,
17331 .total_size = 16384,
17332 .page_size = 256,
17333 .feature_bits = FEATURE_WRSR_WREN,
17334 .tested = TEST_UNTESTED,
17335 .probe = probe_spi_rdid,
17336 .probe_timing = TIMING_ZERO,
17337 .block_erasers =
17338 {
17339 {
17340 .eraseblocks = { {256 * 1024, 64} },
17341 .block_erase = spi_block_erase_d8,
17342 }, {
17343 .eraseblocks = { { 16384 * 1024, 1} },
17344 .block_erase = spi_block_erase_c7,
17345 }
17346 },
17347 .printlock = spi_prettyprint_status_register_bp2_srwd,
17348 .unlock = spi_disable_blockprotect_bp2_srwd,
17349 .write = spi_chip_write_256,
17350 .read = spi_chip_read, /* Fast read (0x0B) supported */
17351 .voltage = {2700, 3600},
17352 },
17353
17354 {
17355 .vendor = "Spansion",
17356 .name = "S25FL128S......0", /* hybrid: 32 (top or bottom) 4 kB sub-sectors + 64 kB sectors */
17357 .bustype = BUS_SPI,
17358 .manufacture_id = SPANSION_ID,
17359 .model_id = SPANSION_S25FL128,
17360 .total_size = 16384,
17361 .page_size = 256,
17362 /* supports 4B addressing */
17363 /* OTP: 1024B total, 32B reserved; read 0x4B; write 0x42 */
17364 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
17365 .tested = TEST_OK_PREW,
17366 .probe = probe_spi_rdid,
17367 .probe_timing = TIMING_ZERO,
17368 .block_erasers =
17369 {
17370 {
17371 /* This chip supports erasing of the 32 so-called "parameter sectors" with
17372 * opcode 0x20. Trying to access an address outside these 4kB blocks does
17373 * have no effect on the memory contents, but sets a flag in the SR.
17374 .eraseblocks = {
17375 {4 * 1024, 32},
17376 {64 * 1024, 254} // inaccessible
17377 },
17378 .block_erase = spi_block_erase_20,
17379 }, { */
17380 .eraseblocks = { { 64 * 1024, 256} },
17381 .block_erase = spi_block_erase_d8,
17382 }, {
17383 .eraseblocks = { { 16384 * 1024, 1} },
17384 .block_erase = spi_block_erase_60,
17385 }, {
17386 .eraseblocks = { { 16384 * 1024, 1} },
17387 .block_erase = spi_block_erase_c7,
17388 }
17389 },
17390 .printlock = spi_prettyprint_status_register_bp2_ep_srwd, /* TODO: SR2 and many others */
17391 .unlock = spi_disable_blockprotect_bp2_srwd, /* TODO: various other locks */
17392 .write = spi_chip_write_256, /* Multi I/O supported */
17393 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
17394 .voltage = {2700, 3600},
17395 },
17396
17397 {
17398 .vendor = "Spansion",
17399 .name = "S25FL128S......1", /* uniform 256 kB sectors */
17400 .bustype = BUS_SPI,
17401 .manufacture_id = SPANSION_ID,
17402 .model_id = SPANSION_S25FL128,
17403 .total_size = 16384,
17404 .page_size = 512,
17405 /* supports 4B addressing */
17406 /* OTP: 1024B total, 32B reserved; read 0x4B; write 0x42 */
17407 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
17408 .tested = TEST_UNTESTED,
17409 .probe = probe_spi_rdid,
17410 .probe_timing = TIMING_ZERO,
17411 .block_erasers =
17412 {
17413 {
17414 .eraseblocks = { {256 * 1024, 64} },
17415 .block_erase = spi_block_erase_d8,
17416 }, {
17417 .eraseblocks = { { 16384 * 1024, 1} },
17418 .block_erase = spi_block_erase_60,
17419 }, {
17420 .eraseblocks = { { 16384 * 1024, 1} },
17421 .block_erase = spi_block_erase_c7,
17422 }
17423 },
17424 .printlock = spi_prettyprint_status_register_bp2_ep_srwd, /* TODO: SR2 and many others */
17425 .unlock = spi_disable_blockprotect_bp2_srwd, /* TODO: various other locks */
17426 .write = spi_chip_write_256, /* Multi I/O supported */
17427 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
17428 .voltage = {2700, 3600},
17429 },
17430
17431 {
17432 .vendor = "Spansion",
17433 .name = "S25FL129P......0", /* hybrid: 32 (top or bottom) 4 kB sub-sectors + 64 kB sectors */
17434 .bustype = BUS_SPI,
17435 .manufacture_id = SPANSION_ID,
17436 .model_id = SPANSION_S25FL128,
17437 .total_size = 16384,
17438 .page_size = 256,
17439 /* OTP: 506B total, 16B reserved; read 0x4B; write 0x42 */
17440 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
17441 .tested = TEST_OK_PREW,
17442 .probe = probe_spi_rdid,
17443 .probe_timing = TIMING_ZERO,
17444 .block_erasers =
17445 {
17446 {
17447 /* FIXME: This chip supports erasing of the 32 so-called "parameter sectors" with
17448 * opcode 0x20. Trying to access an address outside these 4kB blocks does have no
17449 * effect on the memory contents, but sets a flag in the SR.
17450 .eraseblocks = {
17451 {4 * 1024, 32},
17452 {64 * 1024, 254} // inaccessible
17453 },
17454 .block_erase = spi_block_erase_20,
17455 }, { */
17456 /* FIXME: Additionally it also supports erase opcode 40h for the respective 2*4 kB pairs
17457 .eraseblocks = {
17458 {8 * 1024, 16},
17459 {64 * 1024, 254} // inaccessible
17460 },
17461 .block_erase = spi_block_erase_40,
17462 }, { */
17463 .eraseblocks = { { 64 * 1024, 256} },
17464 .block_erase = spi_block_erase_d8,
17465 }, {
17466 .eraseblocks = { { 16384 * 1024, 1} },
17467 .block_erase = spi_block_erase_60,
17468 }, {
17469 .eraseblocks = { { 16384 * 1024, 1} },
17470 .block_erase = spi_block_erase_c7,
17471 }
17472 },
17473 .printlock = spi_prettyprint_status_register_bp2_ep_srwd, /* TODO: Configuration register */
17474 .unlock = spi_disable_blockprotect_bp2_srwd,
17475 .write = spi_chip_write_256, /* Multi I/O supported */
17476 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
17477 .voltage = {2700, 3600},
17478 },
17479
17480 {
17481 .vendor = "Spansion",
17482 .name = "S25FL129P......1", /* uniform 256 kB sectors */
17483 .bustype = BUS_SPI,
17484 .manufacture_id = SPANSION_ID,
17485 .model_id = SPANSION_S25FL128,
17486 .total_size = 16384,
17487 .page_size = 256,
17488 /* OTP: 506B total, 16B reserved; read 0x4B; write 0x42 */
17489 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
17490 .tested = TEST_UNTESTED,
17491 .probe = probe_spi_rdid,
17492 .probe_timing = TIMING_ZERO,
17493 .block_erasers =
17494 {
17495 {
17496 .eraseblocks = { {256 * 1024, 64} },
17497 .block_erase = spi_block_erase_d8,
17498 }, {
17499 .eraseblocks = { { 16384 * 1024, 1} },
17500 .block_erase = spi_block_erase_60,
17501 }, {
17502 .eraseblocks = { { 16384 * 1024, 1} },
17503 .block_erase = spi_block_erase_c7,
17504 }
17505 },
17506 .printlock = spi_prettyprint_status_register_bp2_ep_srwd, /* TODO: Configuration register */
17507 .unlock = spi_disable_blockprotect_bp2_srwd,
17508 .write = spi_chip_write_256, /* Multi I/O supported */
17509 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
17510 .voltage = {2700, 3600},
17511 },
17512
17513 {
17514 .vendor = "Spansion",
17515 .name = "S25FL132K",
17516 .bustype = BUS_SPI,
17517 .manufacture_id = SPANSION_ID,
17518 .model_id = SPANSION_S25FL132K,
17519 .total_size = 4096,
17520 .page_size = 256,
17521 /* OTP: 768B total, 256B reserved; read 0x48; write 0x42, erase 0x44 */
17522 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
17523 .tested = TEST_UNTESTED,
17524 .probe = probe_spi_rdid,
17525 .probe_timing = TIMING_ZERO,
17526 .block_erasers =
17527 {
17528 {
17529 .eraseblocks = { {4 * 1024, 1024} },
17530 .block_erase = spi_block_erase_20,
17531 }, {
17532 .eraseblocks = { {64 * 1024, 64} },
17533 .block_erase = spi_block_erase_d8,
17534 }, {
17535 .eraseblocks = { { 4096 * 1024, 1} },
17536 .block_erase = spi_block_erase_60,
17537 }, {
17538 .eraseblocks = { { 4096 * 1024, 1} },
17539 .block_erase = spi_block_erase_c7,
17540 }
17541 },
17542 .printlock = spi_prettyprint_status_register_bp2_srwd, /* TODO: improve */
17543 .unlock = spi_disable_blockprotect_bp2_srwd, /* #WP pin write-protects SRWP bit. */
17544 .write = spi_chip_write_256,
17545 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
17546 .voltage = {2700, 3600},
17547 },
17548
17549 {
17550 .vendor = "Spansion",
17551 .name = "S25FL164K",
17552 .bustype = BUS_SPI,
17553 .manufacture_id = SPANSION_ID,
17554 .model_id = SPANSION_S25FL164K,
17555 .total_size = 8192,
17556 .page_size = 256,
17557 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44 */
17558 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP,
17559 .tested = TEST_OK_PREW,
17560 .probe = probe_spi_rdid,
17561 .probe_timing = TIMING_ZERO,
17562 .block_erasers =
17563 {
17564 {
17565 .eraseblocks = { {4 * 1024, 2048} },
17566 .block_erase = spi_block_erase_20,
17567 }, {
17568 .eraseblocks = { {64 * 1024, 128} },
17569 .block_erase = spi_block_erase_d8,
17570 }, {
17571 .eraseblocks = { { 8192 * 1024, 1} },
17572 .block_erase = spi_block_erase_60,
17573 }, {
17574 .eraseblocks = { { 8192 * 1024, 1} },
17575 .block_erase = spi_block_erase_c7,
17576 }
17577 },
17578 .printlock = spi_prettyprint_status_register_bp2_srwd, /* TODO: improve */
17579 .unlock = spi_disable_blockprotect_bp2_srwd, /* #WP pin write-protects SRWP bit. */
17580 .write = spi_chip_write_256,
17581 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
17582 .voltage = {2700, 3600},
17583 },
17584
17585 {
17586 .vendor = "Spansion",
17587 .name = "S25FL204K",
17588 .bustype = BUS_SPI,
17589 .manufacture_id = SPANSION_ID,
17590 .model_id = SPANSION_S25FL204,
17591 .total_size = 512,
17592 .page_size = 256,
17593 .feature_bits = FEATURE_WRSR_WREN,
17594 .tested = TEST_OK_PR,
17595 .probe = probe_spi_rdid,
17596 .probe_timing = TIMING_ZERO,
17597 .block_erasers =
17598 {
17599 {
17600 .eraseblocks = { {4 * 1024, 128} },
17601 .block_erase = spi_block_erase_20,
17602 }, {
17603 .eraseblocks = { {64 * 1024, 8} },
17604 .block_erase = spi_block_erase_d8,
17605 }, {
17606 .eraseblocks = { { 512 * 1024, 1} },
17607 .block_erase = spi_block_erase_60,
17608 }, {
17609 .eraseblocks = { { 512 * 1024, 1} },
17610 .block_erase = spi_block_erase_c7,
17611 }
17612 },
17613 .printlock = spi_prettyprint_status_register_bp3_srwd,
17614 .unlock = spi_disable_blockprotect_bp3_srwd, /* #WP pin write-protects SRWP bit. */
17615 .write = spi_chip_write_256,
17616 .read = spi_chip_read, /* Fast read (0x0B) and dual I/O (0x3B) supported */
17617 .voltage = {2700, 3600},
17618 },
17619
17620 {
17621 .vendor = "Spansion",
17622 .name = "S25FL208K",
17623 .bustype = BUS_SPI,
17624 .manufacture_id = SPANSION_ID,
17625 .model_id = SPANSION_S25FL208,
17626 .total_size = 1024,
17627 .page_size = 256,
17628 .feature_bits = FEATURE_WRSR_WREN,
17629 .tested = TEST_OK_PREW,
17630 .probe = probe_spi_rdid,
17631 .probe_timing = TIMING_ZERO,
17632 .block_erasers =
17633 {
17634 {
17635 .eraseblocks = { {4 * 1024, 256} },
17636 .block_erase = spi_block_erase_20,
17637 }, {
17638 .eraseblocks = { {64 * 1024, 16} },
17639 .block_erase = spi_block_erase_d8,
17640 }, {
17641 .eraseblocks = { { 1024 * 1024, 1} },
17642 .block_erase = spi_block_erase_60,
17643 }, {
17644 .eraseblocks = { { 1024 * 1024, 1} },
17645 .block_erase = spi_block_erase_c7,
17646 }
17647 },
17648 .printlock = spi_prettyprint_status_register_bp3_srwd,
17649 .unlock = spi_disable_blockprotect_bp3_srwd, /* #WP pin write-protects SRWP bit. */
17650 .write = spi_chip_write_256,
17651 .read = spi_chip_read, /* Fast read (0x0B) and dual I/O (0x3B) supported */
17652 .voltage = {2700, 3600},
17653 },
17654
17655 {
17656 .vendor = "Spansion",
Nico Huberfffc48d2022-05-28 14:26:06 +020017657 .name = "S25FL256L",
17658 .bustype = BUS_SPI,
17659 .manufacture_id = SPANSION_ID,
17660 .model_id = SPANSION_S25FL256L,
17661 .total_size = 32768,
17662 .page_size = 256,
17663 /* 4 x 256B Security Region (OTP) */
17664 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT3 | FEATURE_OTP |
17665 FEATURE_4BA_ENTER | FEATURE_4BA_NATIVE,
17666 .tested = TEST_UNTESTED,
17667 .probe = probe_spi_rdid,
17668 .probe_timing = TIMING_ZERO,
17669 .block_erasers =
17670 {
17671 {
17672 .eraseblocks = { {4 * 1024, 8192} },
17673 .block_erase = spi_block_erase_21,
17674 }, {
17675 .eraseblocks = { {4 * 1024, 8192} },
17676 .block_erase = spi_block_erase_20,
17677 }, {
17678 .eraseblocks = { {32 * 1024, 1024} },
17679 .block_erase = spi_block_erase_53,
17680 }, {
17681 .eraseblocks = { {32 * 1024, 1024} },
17682 .block_erase = spi_block_erase_52,
17683 }, {
17684 .eraseblocks = { {64 * 1024, 512} },
17685 .block_erase = spi_block_erase_dc,
17686 }, {
17687 .eraseblocks = { {64 * 1024, 512} },
17688 .block_erase = spi_block_erase_d8,
17689 }, {
17690 .eraseblocks = { {32768 * 1024, 1} },
17691 .block_erase = spi_block_erase_60,
17692 }, {
17693 .eraseblocks = { {32768 * 1024, 1} },
17694 .block_erase = spi_block_erase_c7,
17695 }
17696 },
17697 .printlock = spi_prettyprint_status_register_bp3_srwd,
17698 .unlock = spi_disable_blockprotect_bp3_srwd,
17699 .write = spi_chip_write_256,
17700 .read = spi_chip_read, /* Fast read (0x0B) supported */
17701 .voltage = {2700, 3600},
17702 .reg_bits =
17703 {
17704 /*
17705 * Note: This chip has a read-only Status Register 2 that is not
17706 * counted here. Registers are mapped as follows:
17707 * STATUS1 ... Status Register 1
17708 * STATUS2 ... Configuration Register 1
17709 * STATUS3 ... Configuration Register 2
17710 */
17711 .srp = {STATUS1, 7, RW},
17712 .srl = {STATUS2, 0, RW},
17713 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}, {STATUS1, 5, RW}},
17714 .tb = {STATUS1, 6, RW},
17715 .cmp = {STATUS2, 6, RW},
17716 .wps = {STATUS3, 2, RW},
17717 },
Nico Huberaabb3e02023-01-13 00:22:30 +010017718 .wp_write_cfg = spi_wp_write_cfg,
17719 .wp_read_cfg = spi_wp_read_cfg,
17720 .wp_get_ranges = spi_wp_get_available_ranges,
Nico Huberfffc48d2022-05-28 14:26:06 +020017721 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020017722 .prepare_access = spi_prepare_io,
17723 .finish_access = spi_finish_io,
Nico Huberfffc48d2022-05-28 14:26:06 +020017724 },
17725
17726 {
17727 .vendor = "Spansion",
Alan Green1f9cc7d2019-07-01 11:10:45 +100017728 .name = "S25FL256S......0", /* hybrid: 32 (top or bottom) 4 kB sub-sectors + 64 kB sectors */
17729 .bustype = BUS_SPI,
17730 .manufacture_id = SPANSION_ID,
17731 .model_id = SPANSION_S25FL256,
17732 .total_size = 32768,
17733 .page_size = 256,
17734 /* OTP: 1024B total, 32B reserved; read 0x4B; write 0x42 */
Nico Huber9bb8a322022-05-24 15:07:34 +020017735 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP |
17736 FEATURE_4BA_NATIVE | FEATURE_4BA_ENTER_EAR7 | FEATURE_4BA_EAR_1716,
Alan Green1f9cc7d2019-07-01 11:10:45 +100017737 .tested = TEST_OK_PREW,
17738 .probe = probe_spi_rdid,
17739 .probe_timing = TIMING_ZERO,
17740 .block_erasers =
17741 {
17742 {
17743 /* This chip supports erasing of the 32 so-called "parameter sectors" with
17744 * opcode 0x20. Trying to access an address outside these 4kB blocks does
17745 * have no effect on the memory contents, but sets a flag in the SR.
17746 .eraseblocks = {
17747 {4 * 1024, 32},
17748 {64 * 1024, 254} // inaccessible
17749 },
17750 .block_erase = spi_block_erase_20,
17751 }, { */
17752 .eraseblocks = { { 64 * 1024, 512} },
17753 .block_erase = spi_block_erase_dc,
17754 }, {
17755 .eraseblocks = { { 64 * 1024, 512} },
17756 .block_erase = spi_block_erase_d8,
17757 }, {
17758 .eraseblocks = { { 32768 * 1024, 1} },
17759 .block_erase = spi_block_erase_60,
17760 }, {
17761 .eraseblocks = { { 32768 * 1024, 1} },
17762 .block_erase = spi_block_erase_c7,
17763 }
17764 },
17765 .printlock = spi_prettyprint_status_register_bp2_ep_srwd, /* TODO: SR2 and many others */
17766 .unlock = spi_disable_blockprotect_bp2_srwd, /* TODO: various other locks */
17767 .write = spi_chip_write_256, /* Multi I/O supported */
17768 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
17769 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020017770 .prepare_access = spi_prepare_io,
17771 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100017772 },
17773
17774 {
Bernhard Urban-Forster05c629b2020-02-02 21:29:48 +010017775 .vendor = "Spansion",
17776 .name = "S25FL512S",
17777 .bustype = BUS_SPI,
17778 .manufacture_id = SPANSION_ID,
17779 .model_id = SPANSION_S25FL512,
17780 .total_size = 65536, /* 512 Mb (=> 64 MB)) */
17781 .page_size = 256,
17782 /* OTP: 1024B total, 32B reserved; read 0x4B; write 0x42 */
Nico Huber26237922022-06-20 19:37:37 +020017783 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP |
17784 FEATURE_4BA_NATIVE | FEATURE_4BA_ENTER_EAR7 | FEATURE_4BA_EAR_1716,
17785 .tested = TEST_UNTESTED,
Bernhard Urban-Forster05c629b2020-02-02 21:29:48 +010017786 .probe = probe_spi_rdid,
17787 .probe_timing = TIMING_ZERO,
17788 .block_erasers =
17789 {
17790 {
17791 .eraseblocks = { { 256 * 1024, 256} },
17792 .block_erase = spi_block_erase_dc,
17793 }, {
Nico Huberbb608ff2022-05-24 15:33:26 +020017794 .eraseblocks = { { 256 * 1024, 256} },
17795 .block_erase = spi_block_erase_d8,
17796 }, {
Bernhard Urban-Forster05c629b2020-02-02 21:29:48 +010017797 .eraseblocks = { { 65536 * 1024, 1} },
17798 .block_erase = spi_block_erase_60,
17799 }, {
17800 .eraseblocks = { { 65536 * 1024, 1} },
17801 .block_erase = spi_block_erase_c7,
17802 }
17803 },
17804 .printlock = spi_prettyprint_status_register_bp2_ep_srwd, /* TODO: SR2 and many others */
17805 .unlock = spi_disable_blockprotect_bp2_srwd, /* TODO: various other locks */
17806 .write = spi_chip_write_256, /* Multi I/O supported, IGNORE for now */
17807 .read = spi_chip_read, /* Fast read (0x0B) and multi I/O supported */
17808 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020017809 .prepare_access = spi_prepare_io,
17810 .finish_access = spi_finish_io,
Bernhard Urban-Forster05c629b2020-02-02 21:29:48 +010017811 },
17812
17813 {
Mattias Mattsson4c066502010-07-29 20:01:13 +000017814 .vendor = "SyncMOS/MoselVitelic",
17815 .name = "{F,S,V}29C51001B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000017816 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017817 .manufacture_id = SYNCMOS_MVC_ID,
17818 .model_id = SM_MVC_29C51001B,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000017819 .total_size = 128,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017820 .page_size = 512,
Sean Nelson35727f72010-01-28 23:55:12 +000017821 .feature_bits = FEATURE_EITHER_RESET,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000017822 .tested = TEST_UNTESTED,
17823 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000017824 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson56358aa2010-01-19 16:08:51 +000017825 .block_erasers =
17826 {
17827 {
17828 .eraseblocks = { {512, 256} },
17829 .block_erase = erase_sector_jedec,
17830 }, {
17831 .eraseblocks = { {128 * 1024, 1} },
17832 .block_erase = erase_chip_block_jedec,
17833 },
17834 },
Sean Nelson35727f72010-01-28 23:55:12 +000017835 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000017836 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000017837 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010017838 .prepare_access = prepare_memory_access,
17839 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000017840 },
17841
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000017842 {
Mattias Mattsson4c066502010-07-29 20:01:13 +000017843 .vendor = "SyncMOS/MoselVitelic",
17844 .name = "{F,S,V}29C51001T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000017845 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017846 .manufacture_id = SYNCMOS_MVC_ID,
17847 .model_id = SM_MVC_29C51001T,
17848 .total_size = 128,
17849 .page_size = 512,
Sean Nelson35727f72010-01-28 23:55:12 +000017850 .feature_bits = FEATURE_EITHER_RESET,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017851 .tested = TEST_UNTESTED,
17852 .probe = probe_jedec,
17853 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
17854 .block_erasers =
17855 {
17856 {
17857 .eraseblocks = { {512, 256} },
17858 .block_erase = erase_sector_jedec,
17859 }, {
17860 .eraseblocks = { {128 * 1024, 1} },
17861 .block_erase = erase_chip_block_jedec,
17862 },
17863 },
17864 .write = write_jedec_1,
17865 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000017866 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010017867 .prepare_access = prepare_memory_access,
17868 .finish_access = finish_memory_access,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017869 },
17870
17871 {
17872 .vendor = "SyncMOS/MoselVitelic",
17873 .name = "{F,S,V}29C51002B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000017874 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017875 .manufacture_id = SYNCMOS_MVC_ID,
17876 .model_id = SM_MVC_29C51002B,
17877 .total_size = 256,
17878 .page_size = 512,
17879 .feature_bits = FEATURE_EITHER_RESET,
17880 .tested = TEST_UNTESTED,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000017881 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000017882 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson56358aa2010-01-19 16:08:51 +000017883 .block_erasers =
17884 {
17885 {
17886 .eraseblocks = { {512, 512} },
17887 .block_erase = erase_sector_jedec,
17888 }, {
17889 .eraseblocks = { {256 * 1024, 1} },
17890 .block_erase = erase_chip_block_jedec,
17891 },
17892 },
Sean Nelson35727f72010-01-28 23:55:12 +000017893 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000017894 .read = read_memmapped,
Nico Huber9eec4072023-01-12 01:17:30 +010017895 .prepare_access = prepare_memory_access,
17896 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000017897 },
17898
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000017899 {
Mattias Mattsson4c066502010-07-29 20:01:13 +000017900 .vendor = "SyncMOS/MoselVitelic",
17901 .name = "{F,S,V}29C51002T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000017902 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017903 .manufacture_id = SYNCMOS_MVC_ID,
17904 .model_id = SM_MVC_29C51002T,
17905 .total_size = 256,
17906 .page_size = 512,
17907 .feature_bits = FEATURE_EITHER_RESET,
Paul Menzel018d4822011-10-21 12:33:07 +000017908 .tested = TEST_OK_PREW,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017909 .probe = probe_jedec,
17910 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
17911 .block_erasers =
17912 {
17913 {
17914 .eraseblocks = { {512, 512} },
17915 .block_erase = erase_sector_jedec,
17916 }, {
17917 .eraseblocks = { {256 * 1024, 1} },
17918 .block_erase = erase_chip_block_jedec,
17919 },
17920 },
17921 .write = write_jedec_1,
17922 .read = read_memmapped,
Nico Huber9eec4072023-01-12 01:17:30 +010017923 .prepare_access = prepare_memory_access,
17924 .finish_access = finish_memory_access,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017925 },
17926
17927 {
17928 .vendor = "SyncMOS/MoselVitelic",
17929 .name = "{F,S,V}29C51004B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000017930 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017931 .manufacture_id = SYNCMOS_MVC_ID,
17932 .model_id = SM_MVC_29C51004B,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000017933 .total_size = 512,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017934 .page_size = 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000017935 .feature_bits = FEATURE_EITHER_RESET,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000017936 .tested = TEST_UNTESTED,
17937 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000017938 .probe_timing = TIMING_ZERO,
Sean Nelson56358aa2010-01-19 16:08:51 +000017939 .block_erasers =
17940 {
17941 {
Mattias Mattsson4c066502010-07-29 20:01:13 +000017942 .eraseblocks = { {1024, 512} },
17943 .block_erase = erase_sector_jedec,
17944 }, {
17945 .eraseblocks = { {512 * 1024, 1} },
17946 .block_erase = erase_chip_block_jedec,
17947 },
17948 },
17949 .write = write_jedec_1,
17950 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000017951 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010017952 .prepare_access = prepare_memory_access,
17953 .finish_access = finish_memory_access,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017954 },
17955
17956 {
17957 .vendor = "SyncMOS/MoselVitelic",
17958 .name = "{F,S,V}29C51004T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000017959 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017960 .manufacture_id = SYNCMOS_MVC_ID,
17961 .model_id = SM_MVC_29C51004T,
17962 .total_size = 512,
17963 .page_size = 1024,
17964 .feature_bits = FEATURE_EITHER_RESET,
17965 .tested = TEST_UNTESTED,
17966 .probe = probe_jedec,
17967 .probe_timing = TIMING_ZERO,
17968 .block_erasers =
17969 {
17970 {
17971 .eraseblocks = { {1024, 512} },
17972 .block_erase = erase_sector_jedec,
17973 }, {
17974 .eraseblocks = { {512 * 1024, 1} },
17975 .block_erase = erase_chip_block_jedec,
17976 },
17977 },
17978 .write = write_jedec_1,
17979 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000017980 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010017981 .prepare_access = prepare_memory_access,
17982 .finish_access = finish_memory_access,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017983 },
17984
17985 {
17986 .vendor = "SyncMOS/MoselVitelic",
17987 .name = "{S,V}29C31004B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000017988 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000017989 .manufacture_id = SYNCMOS_MVC_ID,
17990 .model_id = SM_MVC_29C31004B,
17991 .total_size = 512,
17992 .page_size = 1024,
17993 .feature_bits = FEATURE_EITHER_RESET,
17994 .tested = TEST_UNTESTED,
17995 .probe = probe_jedec,
17996 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
17997 .block_erasers =
17998 {
17999 {
18000 .eraseblocks = { {1024, 512} },
18001 .block_erase = erase_sector_jedec,
18002 }, {
18003 .eraseblocks = { {512 * 1024, 1} },
18004 .block_erase = erase_chip_block_jedec,
18005 },
18006 },
18007 .write = write_jedec_1,
18008 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000018009 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010018010 .prepare_access = prepare_memory_access,
18011 .finish_access = finish_memory_access,
Mattias Mattsson4c066502010-07-29 20:01:13 +000018012 },
18013
18014 {
18015 .vendor = "SyncMOS/MoselVitelic",
18016 .name = "{S,V}29C31004T",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000018017 .bustype = BUS_PARALLEL,
Mattias Mattsson4c066502010-07-29 20:01:13 +000018018 .manufacture_id = SYNCMOS_MVC_ID,
18019 .model_id = SM_MVC_29C31004T,
18020 .total_size = 512,
18021 .page_size = 1024,
18022 .feature_bits = FEATURE_EITHER_RESET,
18023 .tested = TEST_UNTESTED,
18024 .probe = probe_jedec,
18025 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
18026 .block_erasers =
18027 {
18028 {
18029 .eraseblocks = { {1024, 512} },
Sean Nelson56358aa2010-01-19 16:08:51 +000018030 .block_erase = erase_sector_jedec,
18031 }, {
18032 .eraseblocks = { {512 * 1024, 1} },
18033 .block_erase = erase_chip_block_jedec,
18034 },
18035 },
Sean Nelson35727f72010-01-28 23:55:12 +000018036 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000018037 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000018038 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010018039 .prepare_access = prepare_memory_access,
18040 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000018041 },
18042
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000018043 {
Uwe Hermanna106d152009-05-27 23:17:40 +000018044 .vendor = "TI",
Carl-Daniel Hailfinger09b4fb72009-05-26 21:26:23 +000018045 .name = "TMS29F002RB",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000018046 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfinger09b4fb72009-05-26 21:26:23 +000018047 .manufacture_id = TI_OLD_ID,
18048 .model_id = TI_TMS29F002RB,
18049 .total_size = 256,
18050 .page_size = 16384, /* Non-uniform sectors */
Sean Nelson35727f72010-01-28 23:55:12 +000018051 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Carl-Daniel Hailfinger09b4fb72009-05-26 21:26:23 +000018052 .tested = TEST_UNTESTED,
18053 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000018054 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson56358aa2010-01-19 16:08:51 +000018055 .block_erasers =
18056 {
18057 {
18058 .eraseblocks = {
18059 {16 * 1024, 1},
18060 {8 * 1024, 2},
18061 {32 * 1024, 1},
18062 {64 * 1024, 3},
18063 },
18064 .block_erase = erase_sector_jedec,
18065 }, {
18066 .eraseblocks = { {256 * 1024, 1} },
18067 .block_erase = erase_chip_block_jedec,
18068 },
18069 },
Sean Nelson35727f72010-01-28 23:55:12 +000018070 .write = write_jedec_1,
Carl-Daniel Hailfinger09b4fb72009-05-26 21:26:23 +000018071 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000018072 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010018073 .prepare_access = prepare_memory_access,
18074 .finish_access = finish_memory_access,
Carl-Daniel Hailfinger09b4fb72009-05-26 21:26:23 +000018075 },
18076
18077 {
Uwe Hermanna106d152009-05-27 23:17:40 +000018078 .vendor = "TI",
Carl-Daniel Hailfinger09b4fb72009-05-26 21:26:23 +000018079 .name = "TMS29F002RT",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000018080 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfinger09b4fb72009-05-26 21:26:23 +000018081 .manufacture_id = TI_OLD_ID,
18082 .model_id = TI_TMS29F002RT,
18083 .total_size = 256,
18084 .page_size = 16384, /* Non-uniform sectors */
Sean Nelson35727f72010-01-28 23:55:12 +000018085 .feature_bits = FEATURE_ADDR_2AA | FEATURE_EITHER_RESET,
Carl-Daniel Hailfinger09b4fb72009-05-26 21:26:23 +000018086 .tested = TEST_UNTESTED,
18087 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000018088 .probe_timing = TIMING_ZERO, /* Datasheet has no timing info specified */
Sean Nelson56358aa2010-01-19 16:08:51 +000018089 .block_erasers =
18090 {
18091 {
18092 .eraseblocks = {
18093 {64 * 1024, 3},
18094 {32 * 1024, 1},
18095 {8 * 1024, 2},
18096 {16 * 1024, 1},
18097 },
18098 .block_erase = erase_sector_jedec,
18099 }, {
18100 .eraseblocks = { {256 * 1024, 1} },
18101 .block_erase = erase_chip_block_jedec,
18102 },
18103 },
Sean Nelson35727f72010-01-28 23:55:12 +000018104 .write = write_jedec_1,
Carl-Daniel Hailfinger09b4fb72009-05-26 21:26:23 +000018105 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000018106 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010018107 .prepare_access = prepare_memory_access,
18108 .finish_access = finish_memory_access,
Carl-Daniel Hailfinger09b4fb72009-05-26 21:26:23 +000018109 },
18110
18111 {
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000018112 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100018113 .name = "W25P16",
Stefan Tauner5e27b0b2014-09-09 23:03:32 +000018114 .bustype = BUS_SPI,
18115 .manufacture_id = WINBOND_NEX_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018116 .model_id = WINBOND_NEX_W25P16,
18117 .total_size = 2048,
Stefan Tauner5e27b0b2014-09-09 23:03:32 +000018118 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018119 .feature_bits = FEATURE_WRSR_WREN,
18120 .tested = TEST_UNTESTED,
Stefan Tauner5e27b0b2014-09-09 23:03:32 +000018121 .probe = probe_spi_rdid,
18122 .probe_timing = TIMING_ZERO,
18123 .block_erasers =
18124 {
18125 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100018126 .eraseblocks = { {64 * 1024, 32} },
Stefan Tauner5e27b0b2014-09-09 23:03:32 +000018127 .block_erase = spi_block_erase_d8,
18128 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100018129 .eraseblocks = { {2048 * 1024, 1} },
Stefan Tauner5e27b0b2014-09-09 23:03:32 +000018130 .block_erase = spi_block_erase_c7,
18131 }
18132 },
18133 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18134 .unlock = spi_disable_blockprotect,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018135 .write = spi_chip_write_256,
18136 .read = spi_chip_read, /* Fast read (0x0B) supported */
Stefan Tauner5e27b0b2014-09-09 23:03:32 +000018137 .voltage = {2700, 3600},
18138 },
18139
18140 {
18141 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100018142 .name = "W25P32",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000018143 .bustype = BUS_SPI,
Rudolf Marekce1c7982010-04-20 19:34:31 +000018144 .manufacture_id = WINBOND_NEX_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018145 .model_id = WINBOND_NEX_W25P32,
18146 .total_size = 4096,
Rudolf Marekce1c7982010-04-20 19:34:31 +000018147 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018148 .feature_bits = FEATURE_WRSR_WREN,
18149 .tested = TEST_UNTESTED,
Rudolf Marekce1c7982010-04-20 19:34:31 +000018150 .probe = probe_spi_rdid,
18151 .probe_timing = TIMING_ZERO,
18152 .block_erasers =
18153 {
18154 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100018155 .eraseblocks = { {64 * 1024, 64} },
18156 .block_erase = spi_block_erase_d8,
Rudolf Marekce1c7982010-04-20 19:34:31 +000018157 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100018158 .eraseblocks = { {4096 * 1024, 1} },
18159 .block_erase = spi_block_erase_c7,
18160 }
18161 },
18162 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18163 .unlock = spi_disable_blockprotect,
18164 .write = spi_chip_write_256,
18165 .read = spi_chip_read, /* Fast read (0x0B) supported */
18166 .voltage = {2700, 3600},
18167 },
18168
18169 {
18170 .vendor = "Winbond",
18171 .name = "W25P80",
18172 .bustype = BUS_SPI,
18173 .manufacture_id = WINBOND_NEX_ID,
18174 .model_id = WINBOND_NEX_W25P80,
18175 .total_size = 1024,
18176 .page_size = 256,
18177 .feature_bits = FEATURE_WRSR_WREN,
18178 .tested = TEST_UNTESTED,
18179 .probe = probe_spi_rdid,
18180 .probe_timing = TIMING_ZERO,
18181 .block_erasers =
18182 {
18183 {
Rudolf Marekce1c7982010-04-20 19:34:31 +000018184 .eraseblocks = { {64 * 1024, 16} },
18185 .block_erase = spi_block_erase_d8,
18186 }, {
18187 .eraseblocks = { {1024 * 1024, 1} },
Rudolf Marekce1c7982010-04-20 19:34:31 +000018188 .block_erase = spi_block_erase_c7,
18189 }
18190 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +000018191 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +000018192 .unlock = spi_disable_blockprotect,
Rudolf Marekce1c7982010-04-20 19:34:31 +000018193 .write = spi_chip_write_256,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018194 .read = spi_chip_read, /* Fast read (0x0B) supported */
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000018195 .voltage = {2700, 3600},
David Hendricksc4acec92010-06-24 11:39:57 +000018196 },
18197
18198 {
18199 .vendor = "Winbond",
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000018200 .name = "W25Q128.V",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000018201 .bustype = BUS_SPI,
Antony Rheneus0fbba982011-05-26 14:28:51 +000018202 .manufacture_id = WINBOND_NEX_ID,
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000018203 .model_id = WINBOND_NEX_W25Q128_V,
Antony Rheneus0fbba982011-05-26 14:28:51 +000018204 .total_size = 16384,
18205 .page_size = 256,
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000018206 /* supports SFDP */
18207 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010018208 /* QPI: only FV & JV..M versions */
Nico Huber98970632024-08-30 02:14:05 +020018209 .feature_bits = FEATURE_WRSR_EITHER | FEATURE_OTP | FEATURE_QIO |
Nico Huber3f3c1f32022-05-28 16:48:26 +020018210 FEATURE_WRSR_EXT2 | FEATURE_WRSR2 | FEATURE_WRSR3,
Edward O'Callaghana97e3532022-12-16 15:41:05 +110018211 .tested = TEST_OK_PREWB,
Antony Rheneus0fbba982011-05-26 14:28:51 +000018212 .probe = probe_spi_rdid,
18213 .probe_timing = TIMING_ZERO,
18214 .block_erasers =
18215 {
18216 {
18217 .eraseblocks = { {4 * 1024, 4096} },
18218 .block_erase = spi_block_erase_20,
18219 }, {
18220 .eraseblocks = { {32 * 1024, 512} },
18221 .block_erase = spi_block_erase_52,
18222 }, {
18223 .eraseblocks = { {64 * 1024, 256} },
18224 .block_erase = spi_block_erase_d8,
18225 }, {
18226 .eraseblocks = { {16 * 1024 * 1024, 1} },
18227 .block_erase = spi_block_erase_60,
18228 }, {
18229 .eraseblocks = { {16 * 1024 * 1024, 1} },
18230 .block_erase = spi_block_erase_c7,
18231 }
18232 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +000018233 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Antony Rheneus0fbba982011-05-26 14:28:51 +000018234 .unlock = spi_disable_blockprotect,
18235 .write = spi_chip_write_256,
18236 .read = spi_chip_read,
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000018237 .voltage = {2700, 3600},
Sergii Dmytrukd1af3072021-11-08 00:00:43 +020018238 /* FIXME: Older versions (e.g. 25Q128BV) use WRSR_EXT and have no WPS. */
18239 .reg_bits =
18240 {
Nico Huber2133f592024-01-06 18:30:01 +010018241 .qe = {STATUS2, 1, RW},
Sergii Dmytrukd1af3072021-11-08 00:00:43 +020018242 .srp = {STATUS1, 7, RW},
18243 .srl = {STATUS2, 0, RW},
18244 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
18245 .tb = {STATUS1, 5, RW},
18246 .sec = {STATUS1, 6, RW},
18247 .cmp = {STATUS2, 6, RW},
18248 .wps = {STATUS3, 2, RW},
18249 },
Nico Huberaabb3e02023-01-13 00:22:30 +010018250 .wp_write_cfg = spi_wp_write_cfg,
18251 .wp_read_cfg = spi_wp_read_cfg,
18252 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukd1af3072021-11-08 00:00:43 +020018253 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020018254 .prepare_access = spi_prepare_io,
18255 .finish_access = spi_finish_io,
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000018256 },
18257
18258 {
18259 .vendor = "Winbond",
Patrick Rudolph34323492018-10-04 14:59:40 +020018260 .name = "W25Q128.V..M",
18261 .bustype = BUS_SPI,
18262 .manufacture_id = WINBOND_NEX_ID,
18263 .model_id = WINBOND_NEX_W25Q128_V_M,
18264 .total_size = 16384,
18265 .page_size = 256,
Nico Huber1412d9f2024-01-06 18:25:49 +010018266 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP | FEATURE_QPI_SRP,
18267 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Sergii Dmytrukc74eac22022-10-06 18:17:58 +030018268 .tested = TEST_OK_PREWB,
Patrick Rudolph34323492018-10-04 14:59:40 +020018269 .probe = probe_spi_rdid,
18270 .probe_timing = TIMING_ZERO,
18271 .block_erasers =
18272 {
18273 {
18274 .eraseblocks = { {4 * 1024, 4096} },
18275 .block_erase = spi_block_erase_20,
18276 }, {
18277 .eraseblocks = { {32 * 1024, 512} },
18278 .block_erase = spi_block_erase_52,
18279 }, {
18280 .eraseblocks = { {64 * 1024, 256} },
18281 .block_erase = spi_block_erase_d8,
18282 }, {
18283 .eraseblocks = { {16 * 1024 * 1024, 1} },
18284 .block_erase = spi_block_erase_60,
18285 }, {
18286 .eraseblocks = { {16 * 1024 * 1024, 1} },
18287 .block_erase = spi_block_erase_c7,
18288 }
18289 },
Alan Greena1fc01d2019-09-23 17:12:44 +100018290 .printlock = spi_prettyprint_status_register_plain,
Patrick Rudolph34323492018-10-04 14:59:40 +020018291 .unlock = spi_disable_blockprotect,
18292 .write = spi_chip_write_256,
18293 .read = spi_chip_read,
18294 .voltage = {2700, 3600},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018295 .reg_bits =
18296 {
Nico Huber2133f592024-01-06 18:30:01 +010018297 .qe = {STATUS2, 1, RW},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018298 .srp = {STATUS1, 7, RW},
18299 .srl = {STATUS2, 0, RW},
18300 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
18301 .tb = {STATUS1, 5, RW},
18302 .sec = {STATUS1, 6, RW},
18303 .cmp = {STATUS2, 6, RW},
18304 },
Nico Huberaabb3e02023-01-13 00:22:30 +010018305 .wp_write_cfg = spi_wp_write_cfg,
18306 .wp_read_cfg = spi_wp_read_cfg,
18307 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018308 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020018309 .prepare_access = spi_prepare_io,
18310 .finish_access = spi_finish_io,
Patrick Rudolph34323492018-10-04 14:59:40 +020018311 },
18312
18313 {
18314 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100018315 .name = "W25Q128.W",
18316 .bustype = BUS_SPI,
18317 .manufacture_id = WINBOND_NEX_ID,
18318 .model_id = WINBOND_NEX_W25Q128_W,
18319 .total_size = 16384,
18320 .page_size = 256,
18321 /* supports SFDP */
18322 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber1412d9f2024-01-06 18:25:49 +010018323 /* QPI: only FW & JW..M versions */
18324 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018325 .tested = TEST_OK_PREW,
18326 .probe = probe_spi_rdid,
18327 .probe_timing = TIMING_ZERO,
18328 .block_erasers =
18329 {
18330 {
18331 .eraseblocks = { {4 * 1024, 4096} },
18332 .block_erase = spi_block_erase_20,
18333 }, {
18334 .eraseblocks = { {32 * 1024, 512} },
18335 .block_erase = spi_block_erase_52,
18336 }, {
18337 .eraseblocks = { {64 * 1024, 256} },
18338 .block_erase = spi_block_erase_d8,
18339 }, {
18340 .eraseblocks = { {16 * 1024 * 1024, 1} },
18341 .block_erase = spi_block_erase_60,
18342 }, {
18343 .eraseblocks = { {16 * 1024 * 1024, 1} },
18344 .block_erase = spi_block_erase_c7,
18345 }
18346 },
18347 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18348 .unlock = spi_disable_blockprotect,
18349 .write = spi_chip_write_256,
18350 .read = spi_chip_read,
18351 .voltage = {1650, 1950},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018352 .reg_bits =
18353 {
Nico Huber2133f592024-01-06 18:30:01 +010018354 .qe = {STATUS2, 1, RW},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018355 .srp = {STATUS1, 7, RW},
18356 .srl = {STATUS2, 0, RW},
18357 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
18358 .tb = {STATUS1, 5, RW},
18359 .sec = {STATUS1, 6, RW},
18360 .cmp = {STATUS2, 6, RW},
18361 },
Nico Huberaabb3e02023-01-13 00:22:30 +010018362 .wp_write_cfg = spi_wp_write_cfg,
18363 .wp_read_cfg = spi_wp_read_cfg,
18364 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018365 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020018366 .prepare_access = spi_prepare_io,
18367 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018368 },
18369
18370 {
18371 .vendor = "Winbond",
Peichao Wang1a119492019-11-11 15:26:41 +080018372 .name = "W25Q128.JW.DTR",
18373 .bustype = BUS_SPI,
18374 .manufacture_id = WINBOND_NEX_ID,
18375 .model_id = WINBOND_NEX_W25Q128_DTR,
18376 .total_size = 16384,
18377 .page_size = 256,
Nico Huber1412d9f2024-01-06 18:25:49 +010018378 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP | FEATURE_QPI_SRP,
18379 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Peichao Wang1a119492019-11-11 15:26:41 +080018380 .tested = TEST_OK_PREW,
18381 .probe = probe_spi_rdid,
18382 .probe_timing = TIMING_ZERO,
18383 .block_erasers =
18384 {
18385 {
18386 .eraseblocks = { {4 * 1024, 4096} },
18387 .block_erase = spi_block_erase_20,
18388 }, {
18389 .eraseblocks = { {32 * 1024, 512} },
18390 .block_erase = spi_block_erase_52,
18391 }, {
18392 .eraseblocks = { {64 * 1024, 256} },
18393 .block_erase = spi_block_erase_d8,
18394 }, {
18395 .eraseblocks = { {16 * 1024 * 1024, 1} },
18396 .block_erase = spi_block_erase_60,
18397 }, {
18398 .eraseblocks = { {16 * 1024 * 1024, 1} },
18399 .block_erase = spi_block_erase_c7,
18400 }
18401 },
18402 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18403 .unlock = spi_disable_blockprotect,
18404 .write = spi_chip_write_256,
18405 .read = spi_chip_read,
18406 .voltage = {1650, 1950},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018407 .reg_bits =
18408 {
Nico Huber2133f592024-01-06 18:30:01 +010018409 .qe = {STATUS2, 1, RW},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018410 .srp = {STATUS1, 7, RW},
18411 .srl = {STATUS2, 0, RW},
18412 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
18413 .tb = {STATUS1, 5, RW},
18414 .sec = {STATUS1, 6, RW},
18415 .cmp = {STATUS2, 6, RW},
18416 },
Nico Huberaabb3e02023-01-13 00:22:30 +010018417 .wp_write_cfg = spi_wp_write_cfg,
18418 .wp_read_cfg = spi_wp_read_cfg,
18419 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018420 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020018421 .prepare_access = spi_prepare_io,
18422 .finish_access = spi_finish_io,
Peichao Wang1a119492019-11-11 15:26:41 +080018423 },
18424
18425 {
18426 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100018427 .name = "W25Q16.V",
18428 .bustype = BUS_SPI,
18429 .manufacture_id = WINBOND_NEX_ID,
18430 .model_id = WINBOND_NEX_W25Q16_V,
18431 .total_size = 2048,
18432 .page_size = 256,
18433 /* supports SFDP */
18434 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010018435 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018436 .tested = TEST_OK_PREW,
18437 .probe = probe_spi_rdid,
18438 .probe_timing = TIMING_ZERO,
18439 .block_erasers =
18440 {
18441 {
18442 .eraseblocks = { {4 * 1024, 512} },
18443 .block_erase = spi_block_erase_20,
18444 }, {
18445 .eraseblocks = { {32 * 1024, 64} },
18446 .block_erase = spi_block_erase_52,
18447 }, {
18448 .eraseblocks = { {64 * 1024, 32} },
18449 .block_erase = spi_block_erase_d8,
18450 }, {
18451 .eraseblocks = { {2 * 1024 * 1024, 1} },
18452 .block_erase = spi_block_erase_60,
18453 }, {
18454 .eraseblocks = { {2 * 1024 * 1024, 1} },
18455 .block_erase = spi_block_erase_c7,
18456 }
18457 },
Nico Huber2133f592024-01-06 18:30:01 +010018458 .reg_bits =
18459 {
18460 .qe = {STATUS2, 1, RW},
18461 },
Alan Green1f9cc7d2019-07-01 11:10:45 +100018462 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18463 .unlock = spi_disable_blockprotect,
18464 .write = spi_chip_write_256,
18465 .read = spi_chip_read,
18466 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020018467 .prepare_access = spi_prepare_io,
18468 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018469 },
18470
18471 {
18472 .vendor = "Winbond",
18473 .name = "W25Q16.W",
18474 .bustype = BUS_SPI,
18475 .manufacture_id = WINBOND_NEX_ID,
18476 .model_id = WINBOND_NEX_W25Q16_W,
18477 .total_size = 2048,
18478 .page_size = 256,
18479 /* OTP: 256B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber1412d9f2024-01-06 18:25:49 +010018480 /* QPI: only FW & JW..M versions .qpi_read_params = { 2, 4, 6, 8 } */
18481 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018482 .tested = TEST_UNTESTED,
18483 .probe = probe_spi_rdid,
18484 .probe_timing = TIMING_ZERO,
18485 .block_erasers =
18486 {
18487 {
18488 .eraseblocks = { {4 * 1024, 512} },
18489 .block_erase = spi_block_erase_20,
18490 }, {
18491 .eraseblocks = { {32 * 1024, 64} },
18492 .block_erase = spi_block_erase_52,
18493 }, {
18494 .eraseblocks = { {64 * 1024, 32} },
18495 .block_erase = spi_block_erase_d8,
18496 }, {
18497 .eraseblocks = { {2 * 1024 * 1024, 1} },
18498 .block_erase = spi_block_erase_60,
18499 }, {
18500 .eraseblocks = { {2 * 1024 * 1024, 1} },
18501 .block_erase = spi_block_erase_c7,
18502 }
18503 },
Nico Huber2133f592024-01-06 18:30:01 +010018504 .reg_bits =
18505 {
18506 .qe = {STATUS2, 1, RW},
18507 },
Alan Green1f9cc7d2019-07-01 11:10:45 +100018508 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18509 .unlock = spi_disable_blockprotect,
18510 .write = spi_chip_write_256,
18511 .read = spi_chip_read,
Nico Huber1412d9f2024-01-06 18:25:49 +010018512 .voltage = {1700, 1950},
Nico Huber930d4212024-05-04 18:59:15 +020018513 .prepare_access = spi_prepare_io,
18514 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018515 },
18516
18517 {
18518 .vendor = "Winbond",
18519 .name = "W25Q20.W",
18520 .bustype = BUS_SPI,
18521 .manufacture_id = WINBOND_NEX_ID,
18522 .model_id = WINBOND_NEX_W25Q20_W,
18523 .total_size = 256,
18524 .page_size = 256,
18525 /* OTP: 256B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010018526 /* W25Q20EW: FEATURE_WRSR2 */
18527 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018528 .tested = TEST_UNTESTED,
18529 .probe = probe_spi_rdid,
18530 .probe_timing = TIMING_ZERO,
18531 .block_erasers =
18532 {
18533 {
18534 .eraseblocks = { {4 * 1024, 64} },
18535 .block_erase = spi_block_erase_20,
18536 }, {
18537 .eraseblocks = { {32 * 1024, 8} },
18538 .block_erase = spi_block_erase_52,
18539 }, {
18540 .eraseblocks = { {64 * 1024, 4} },
18541 .block_erase = spi_block_erase_d8,
18542 }, {
18543 .eraseblocks = { {256 * 1024, 1} },
18544 .block_erase = spi_block_erase_60,
18545 }, {
18546 .eraseblocks = { {256 * 1024, 1} },
18547 .block_erase = spi_block_erase_c7,
18548 }
18549 },
Nico Huber2133f592024-01-06 18:30:01 +010018550 .reg_bits =
18551 {
18552 .qe = {STATUS2, 1, RW},
18553 },
Alan Green1f9cc7d2019-07-01 11:10:45 +100018554 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18555 .unlock = spi_disable_blockprotect,
18556 .write = spi_chip_write_256,
18557 .read = spi_chip_read,
Nico Huber2133f592024-01-06 18:30:01 +010018558 .voltage = {1700, 1950},
Nico Huber930d4212024-05-04 18:59:15 +020018559 .prepare_access = spi_prepare_io,
18560 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018561 },
18562
18563 {
18564 .vendor = "Winbond",
Nico Huber5215eab2022-05-23 15:13:07 +020018565 .name = "W25Q256FV",
Boris Baykovaa6c3742016-06-11 18:29:01 +020018566 .bustype = BUS_SPI,
18567 .manufacture_id = WINBOND_NEX_ID,
18568 .model_id = WINBOND_NEX_W25Q256_V,
18569 .total_size = 32768,
18570 .page_size = 256,
18571 /* supports SFDP */
18572 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010018573 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP |
18574 FEATURE_4BA_ENTER_WREN | FEATURE_4BA_EAR_C5C8 |
18575 FEATURE_4BA_READ | FEATURE_4BA_FAST_READ |
18576 FEATURE_QPI_SRP,
18577 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Angel Pons3130cbd2018-09-30 19:32:30 +020018578 .tested = TEST_OK_PREW,
Boris Baykovaa6c3742016-06-11 18:29:01 +020018579 .probe = probe_spi_rdid,
18580 .probe_timing = TIMING_ZERO,
18581 .block_erasers =
18582 {
18583 {
18584 .eraseblocks = { {4 * 1024, 8192} },
Nico Huber7a077222017-10-14 18:18:30 +020018585 .block_erase = spi_block_erase_20,
Boris Baykovaa6c3742016-06-11 18:29:01 +020018586 }, {
18587 .eraseblocks = { {32 * 1024, 1024} },
Nico Huber7a077222017-10-14 18:18:30 +020018588 .block_erase = spi_block_erase_52,
Boris Baykovaa6c3742016-06-11 18:29:01 +020018589 }, {
18590 .eraseblocks = { {64 * 1024, 512} },
Nico Huber7a077222017-10-14 18:18:30 +020018591 .block_erase = spi_block_erase_d8,
Boris Baykovaa6c3742016-06-11 18:29:01 +020018592 }, {
18593 .eraseblocks = { {32 * 1024 * 1024, 1} },
18594 .block_erase = spi_block_erase_60,
18595 }, {
18596 .eraseblocks = { {32 * 1024 * 1024, 1} },
18597 .block_erase = spi_block_erase_c7,
18598 }
18599 },
18600 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18601 .unlock = spi_disable_blockprotect,
18602 .write = spi_chip_write_256,
18603 .read = spi_chip_read,
18604 .voltage = {2700, 3600},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018605 .reg_bits =
18606 {
Nico Huber2133f592024-01-06 18:30:01 +010018607 .qe = {STATUS2, 1, RW},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018608 .srp = {STATUS1, 7, RW},
18609 .srl = {STATUS2, 0, RW},
18610 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}, {STATUS1, 5, RW}},
18611 .tb = {STATUS1, 6, RW},
18612 .cmp = {STATUS2, 6, RW},
18613 },
Nico Huberaabb3e02023-01-13 00:22:30 +010018614 .wp_write_cfg = spi_wp_write_cfg,
18615 .wp_read_cfg = spi_wp_read_cfg,
18616 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018617 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020018618 .prepare_access = spi_prepare_io,
18619 .finish_access = spi_finish_io,
Boris Baykovaa6c3742016-06-11 18:29:01 +020018620 },
18621
18622 {
18623 .vendor = "Winbond",
Nico Huber5215eab2022-05-23 15:13:07 +020018624 .name = "W25Q256JV_Q",
18625 .bustype = BUS_SPI,
18626 .manufacture_id = WINBOND_NEX_ID,
18627 .model_id = WINBOND_NEX_W25Q256_V,
18628 .total_size = 32768,
18629 .page_size = 256,
18630 /* supports SFDP */
18631 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010018632 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP | FEATURE_4BA | FEATURE_QIO,
Nico Huberddfbbe82023-12-21 16:31:27 +010018633 .tested = TEST_OK_PREW,
Nico Huber5215eab2022-05-23 15:13:07 +020018634 .probe = probe_spi_rdid,
18635 .probe_timing = TIMING_ZERO,
18636 .block_erasers =
18637 {
18638 {
18639 .eraseblocks = { {4 * 1024, 8192} },
18640 .block_erase = spi_block_erase_21,
18641 }, {
18642 .eraseblocks = { {4 * 1024, 8192} },
18643 .block_erase = spi_block_erase_20,
18644 }, {
18645 .eraseblocks = { {32 * 1024, 1024} },
18646 .block_erase = spi_block_erase_52,
18647 }, {
18648 .eraseblocks = { {64 * 1024, 512} },
18649 .block_erase = spi_block_erase_dc,
18650 }, {
18651 .eraseblocks = { {64 * 1024, 512} },
18652 .block_erase = spi_block_erase_d8,
18653 }, {
18654 .eraseblocks = { {32 * 1024 * 1024, 1} },
18655 .block_erase = spi_block_erase_60,
18656 }, {
18657 .eraseblocks = { {32 * 1024 * 1024, 1} },
18658 .block_erase = spi_block_erase_c7,
18659 }
18660 },
18661 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18662 .unlock = spi_disable_blockprotect,
18663 .write = spi_chip_write_256,
18664 .read = spi_chip_read,
18665 .voltage = {2700, 3600},
18666 .reg_bits =
18667 {
Nico Huber2133f592024-01-06 18:30:01 +010018668 .qe = {STATUS2, 1, RW},
Nico Huber5215eab2022-05-23 15:13:07 +020018669 .srp = {STATUS1, 7, RW},
18670 .srl = {STATUS2, 0, RW},
18671 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}, {STATUS1, 5, RW}},
18672 .tb = {STATUS1, 6, RW},
18673 .cmp = {STATUS2, 6, RW},
18674 },
Nico Huberaabb3e02023-01-13 00:22:30 +010018675 .wp_write_cfg = spi_wp_write_cfg,
18676 .wp_read_cfg = spi_wp_read_cfg,
18677 .wp_get_ranges = spi_wp_get_available_ranges,
Nico Huber5215eab2022-05-23 15:13:07 +020018678 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020018679 .prepare_access = spi_prepare_io,
18680 .finish_access = spi_finish_io,
Nico Huber5215eab2022-05-23 15:13:07 +020018681 },
18682
18683 {
18684 .vendor = "Winbond",
David Hendricks49876792018-10-27 20:19:42 +000018685 .name = "W25Q256JV_M",
18686 .bustype = BUS_SPI,
18687 .manufacture_id = WINBOND_NEX_ID,
18688 .model_id = WINBOND_NEX_W25Q256JV_M,
18689 .total_size = 32768,
18690 .page_size = 256,
18691 /* supports SFDP */
18692 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010018693 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP |
18694 FEATURE_4BA | FEATURE_QPI_SRP,
18695 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
David Hendricks49876792018-10-27 20:19:42 +000018696 .tested = TEST_OK_PREW,
18697 .probe = probe_spi_rdid,
18698 .probe_timing = TIMING_ZERO,
18699 .block_erasers =
18700 {
18701 {
18702 .eraseblocks = { {4 * 1024, 8192} },
18703 .block_erase = spi_block_erase_21,
18704 }, {
18705 .eraseblocks = { {4 * 1024, 8192} },
18706 .block_erase = spi_block_erase_20,
18707 }, {
18708 .eraseblocks = { {32 * 1024, 1024} },
18709 .block_erase = spi_block_erase_52,
18710 }, {
18711 .eraseblocks = { {64 * 1024, 512} },
18712 .block_erase = spi_block_erase_dc,
18713 }, {
18714 .eraseblocks = { {64 * 1024, 512} },
18715 .block_erase = spi_block_erase_d8,
18716 }, {
18717 .eraseblocks = { {32 * 1024 * 1024, 1} },
18718 .block_erase = spi_block_erase_60,
18719 }, {
18720 .eraseblocks = { {32 * 1024 * 1024, 1} },
18721 .block_erase = spi_block_erase_c7,
18722 }
18723 },
18724 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18725 .unlock = spi_disable_blockprotect,
18726 .write = spi_chip_write_256,
18727 .read = spi_chip_read,
18728 .voltage = {2700, 3600},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018729 .reg_bits =
18730 {
Nico Huber2133f592024-01-06 18:30:01 +010018731 .qe = {STATUS2, 1, RW},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018732 .srp = {STATUS1, 7, RW},
18733 .srl = {STATUS2, 0, RW},
18734 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}, {STATUS1, 5, RW}},
18735 .tb = {STATUS1, 6, RW},
18736 .cmp = {STATUS2, 6, RW},
18737 },
Nico Huberaabb3e02023-01-13 00:22:30 +010018738 .wp_write_cfg = spi_wp_write_cfg,
18739 .wp_read_cfg = spi_wp_read_cfg,
18740 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110018741 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020018742 .prepare_access = spi_prepare_io,
18743 .finish_access = spi_finish_io,
David Hendricks49876792018-10-27 20:19:42 +000018744 },
18745
18746 {
18747 .vendor = "Winbond",
Patrick Rudolph8f5bd982020-08-26 09:15:53 +020018748 .name = "W25Q256JW",
el-coderon01209852020-04-29 12:12:53 +020018749 .bustype = BUS_SPI,
18750 .manufacture_id = WINBOND_NEX_ID,
18751 .model_id = WINBOND_NEX_W25Q256_W,
18752 .total_size = 32768,
18753 .page_size = 256,
18754 /* supports SFDP */
18755 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010018756 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_WRSR3 |
18757 FEATURE_OTP | FEATURE_4BA | FEATURE_QIO,
el-coderon01209852020-04-29 12:12:53 +020018758 .tested = TEST_OK_PREW,
18759 .probe = probe_spi_rdid,
18760 .probe_timing = TIMING_ZERO,
18761 .block_erasers =
18762 {
18763 {
18764 .eraseblocks = { {4 * 1024, 8192} },
Patrick Rudolph8f5bd982020-08-26 09:15:53 +020018765 .block_erase = spi_block_erase_21,
18766 }, {
18767 .eraseblocks = { {4 * 1024, 8192} },
el-coderon01209852020-04-29 12:12:53 +020018768 .block_erase = spi_block_erase_20,
18769 }, {
18770 .eraseblocks = { {32 * 1024, 1024} },
18771 .block_erase = spi_block_erase_52,
18772 }, {
18773 .eraseblocks = { {64 * 1024, 512} },
Patrick Rudolph8f5bd982020-08-26 09:15:53 +020018774 .block_erase = spi_block_erase_dc,
18775 }, {
18776 .eraseblocks = { {64 * 1024, 512} },
el-coderon01209852020-04-29 12:12:53 +020018777 .block_erase = spi_block_erase_d8,
18778 }, {
18779 .eraseblocks = { {32 * 1024 * 1024, 1} },
18780 .block_erase = spi_block_erase_60,
18781 }, {
18782 .eraseblocks = { {32 * 1024 * 1024, 1} },
18783 .block_erase = spi_block_erase_c7,
18784 }
18785 },
Nico Huber2133f592024-01-06 18:30:01 +010018786 .reg_bits =
18787 {
18788 .qe = {STATUS2, 1, RW},
18789 },
el-coderon01209852020-04-29 12:12:53 +020018790 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18791 .unlock = spi_disable_blockprotect,
18792 .write = spi_chip_write_256,
18793 .read = spi_chip_read,
18794 .voltage = {1650, 1950},
Nico Huber930d4212024-05-04 18:59:15 +020018795 .prepare_access = spi_prepare_io,
18796 .finish_access = spi_finish_io,
el-coderon01209852020-04-29 12:12:53 +020018797 },
18798
18799 {
18800 .vendor = "Winbond",
David Hendricks31532602020-08-16 17:14:56 -070018801 .name = "W25Q256JW_DTR",
18802 .bustype = BUS_SPI,
18803 .manufacture_id = WINBOND_NEX_ID,
18804 .model_id = WINBOND_NEX_W25Q256_DTR,
18805 .total_size = 32768,
18806 .page_size = 256,
18807 /* supports SFDP */
18808 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010018809 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_WRSR3 |
18810 FEATURE_OTP | FEATURE_4BA | FEATURE_QPI_SRP,
18811 .dummy_cycles =
18812 {
18813 .qpi_read_params = {
18814 2, /* Datasheet Rev.K says 4 is the default, though.
18815 Will assume that the text is wrong, if not,
18816 we'll know why it doesn't work. */
18817 4, 6, 8
18818 },
18819 },
Kapil Porwal111c3802022-12-09 19:41:27 +053018820 .tested = TEST_OK_PREWB,
David Hendricks31532602020-08-16 17:14:56 -070018821 .probe = probe_spi_rdid,
18822 .probe_timing = TIMING_ZERO,
18823 .block_erasers =
18824 {
18825 {
18826 .eraseblocks = { {4 * 1024, 8192} },
18827 .block_erase = spi_block_erase_21,
18828 }, {
18829 .eraseblocks = { {4 * 1024, 8192} },
18830 .block_erase = spi_block_erase_20,
18831 }, {
18832 .eraseblocks = { {32 * 1024, 1024} },
18833 .block_erase = spi_block_erase_52,
18834 }, {
18835 .eraseblocks = { {64 * 1024, 512} },
18836 .block_erase = spi_block_erase_dc,
18837 }, {
18838 .eraseblocks = { {64 * 1024, 512} },
18839 .block_erase = spi_block_erase_d8,
18840 }, {
18841 .eraseblocks = { {32 * 1024 * 1024, 1} },
18842 .block_erase = spi_block_erase_60,
18843 }, {
18844 .eraseblocks = { {32 * 1024 * 1024, 1} },
18845 .block_erase = spi_block_erase_c7,
18846 }
18847 },
18848 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18849 .unlock = spi_disable_blockprotect,
18850 .write = spi_chip_write_256,
18851 .read = spi_chip_read,
18852 .voltage = {1700, 1950},
Kapil Porwal111c3802022-12-09 19:41:27 +053018853 .reg_bits =
18854 {
Nico Huber2133f592024-01-06 18:30:01 +010018855 .qe = {STATUS2, 1, RW},
Kapil Porwal111c3802022-12-09 19:41:27 +053018856 .srp = {STATUS1, 7, RW},
18857 .srl = {STATUS2, 0, RW},
18858 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}, {STATUS1, 5, RW}},
18859 .tb = {STATUS1, 6, RW},
18860 .cmp = {STATUS2, 6, RW},
18861 .wps = {STATUS3, 2, RW},
18862 },
Nico Huberaabb3e02023-01-13 00:22:30 +010018863 .wp_write_cfg = spi_wp_write_cfg,
18864 .wp_read_cfg = spi_wp_read_cfg,
18865 .wp_get_ranges = spi_wp_get_available_ranges,
Kapil Porwal111c3802022-12-09 19:41:27 +053018866 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020018867 .prepare_access = spi_prepare_io,
18868 .finish_access = spi_finish_io,
David Hendricks31532602020-08-16 17:14:56 -070018869 },
18870
18871 {
18872 .vendor = "Winbond",
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030018873 .name = "W25Q32BV/W25Q32CV/W25Q32DV",
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000018874 .bustype = BUS_SPI,
18875 .manufacture_id = WINBOND_NEX_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018876 .model_id = WINBOND_NEX_W25Q32_V,
18877 .total_size = 4096,
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000018878 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018879 /* supports SFDP */
18880 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010018881 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018882 .tested = TEST_OK_PREW,
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000018883 .probe = probe_spi_rdid,
18884 .probe_timing = TIMING_ZERO,
18885 .block_erasers =
18886 {
18887 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100018888 .eraseblocks = { {4 * 1024, 1024} },
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000018889 .block_erase = spi_block_erase_20,
18890 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100018891 .eraseblocks = { {32 * 1024, 128} },
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000018892 .block_erase = spi_block_erase_52,
18893 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100018894 .eraseblocks = { {64 * 1024, 64} },
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000018895 .block_erase = spi_block_erase_d8,
18896 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100018897 .eraseblocks = { {4 * 1024 * 1024, 1} },
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000018898 .block_erase = spi_block_erase_60,
18899 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100018900 .eraseblocks = { {4 * 1024 * 1024, 1} },
18901 .block_erase = spi_block_erase_c7,
18902 }
18903 },
18904 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18905 .unlock = spi_disable_blockprotect,
18906 .write = spi_chip_write_256,
18907 .read = spi_chip_read,
18908 .voltage = {2700, 3600},
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030018909 .reg_bits =
18910 {
Nico Huber2133f592024-01-06 18:30:01 +010018911 .qe = {STATUS2, 1, RW},
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030018912 .srp = {STATUS1, 7, RW},
18913 .srl = {STATUS2, 0, RW},
18914 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
18915 .tb = {STATUS1, 5, RW},
18916 .sec = {STATUS1, 6, RW},
18917 .cmp = {STATUS2, 6, RW},
18918 },
Nico Huberaabb3e02023-01-13 00:22:30 +010018919 .wp_write_cfg = spi_wp_write_cfg,
18920 .wp_read_cfg = spi_wp_read_cfg,
18921 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030018922 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020018923 .prepare_access = spi_prepare_io,
18924 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100018925 },
18926
18927 {
18928 .vendor = "Winbond",
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030018929 .name = "W25Q32FV",
18930 .bustype = BUS_SPI,
18931 .manufacture_id = WINBOND_NEX_ID,
18932 .model_id = WINBOND_NEX_W25Q32_V,
18933 .total_size = 4096,
18934 .page_size = 256,
18935 /* supports SFDP */
18936 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber1412d9f2024-01-06 18:25:49 +010018937 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QPI_SRP |
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030018938 FEATURE_WRSR_EXT2 | FEATURE_WRSR2 | FEATURE_WRSR3,
Nico Huber1412d9f2024-01-06 18:25:49 +010018939 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030018940 .tested = TEST_OK_PREW,
18941 .probe = probe_spi_rdid,
18942 .probe_timing = TIMING_ZERO,
18943 .block_erasers =
18944 {
18945 {
18946 .eraseblocks = { {4 * 1024, 1024} },
18947 .block_erase = spi_block_erase_20,
18948 }, {
18949 .eraseblocks = { {32 * 1024, 128} },
18950 .block_erase = spi_block_erase_52,
18951 }, {
18952 .eraseblocks = { {64 * 1024, 64} },
18953 .block_erase = spi_block_erase_d8,
18954 }, {
18955 .eraseblocks = { {4 * 1024 * 1024, 1} },
18956 .block_erase = spi_block_erase_60,
18957 }, {
18958 .eraseblocks = { {4 * 1024 * 1024, 1} },
18959 .block_erase = spi_block_erase_c7,
18960 }
18961 },
18962 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
18963 .unlock = spi_disable_blockprotect,
18964 .write = spi_chip_write_256,
18965 .read = spi_chip_read,
18966 .voltage = {2700, 3600},
18967 .reg_bits =
18968 {
Nico Huber2133f592024-01-06 18:30:01 +010018969 .qe = {STATUS2, 1, RW},
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030018970 .srp = {STATUS1, 7, RW},
18971 .srl = {STATUS2, 0, RW},
18972 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
18973 .tb = {STATUS1, 5, RW},
18974 .sec = {STATUS1, 6, RW},
18975 .cmp = {STATUS2, 6, RW},
18976 .wps = {STATUS3, 2, RW},
18977 },
Nico Huberaabb3e02023-01-13 00:22:30 +010018978 .wp_write_cfg = spi_wp_write_cfg,
18979 .wp_read_cfg = spi_wp_read_cfg,
18980 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030018981 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020018982 .prepare_access = spi_prepare_io,
18983 .finish_access = spi_finish_io,
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030018984 },
18985
18986 {
18987 .vendor = "Winbond",
18988 .name = "W25Q32JV",
18989 .bustype = BUS_SPI,
18990 .manufacture_id = WINBOND_NEX_ID,
18991 .model_id = WINBOND_NEX_W25Q32_V,
18992 .total_size = 4096,
18993 .page_size = 256,
18994 /* supports SFDP */
18995 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010018996 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QIO |
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030018997 FEATURE_WRSR_EXT2 | FEATURE_WRSR2 | FEATURE_WRSR3,
18998 .tested = TEST_OK_PREW,
18999 .probe = probe_spi_rdid,
19000 .probe_timing = TIMING_ZERO,
19001 .block_erasers =
19002 {
19003 {
19004 .eraseblocks = { {4 * 1024, 1024} },
19005 .block_erase = spi_block_erase_20,
19006 }, {
19007 .eraseblocks = { {32 * 1024, 128} },
19008 .block_erase = spi_block_erase_52,
19009 }, {
19010 .eraseblocks = { {64 * 1024, 64} },
19011 .block_erase = spi_block_erase_d8,
19012 }, {
19013 .eraseblocks = { {4 * 1024 * 1024, 1} },
19014 .block_erase = spi_block_erase_60,
19015 }, {
19016 .eraseblocks = { {4 * 1024 * 1024, 1} },
19017 .block_erase = spi_block_erase_c7,
19018 }
19019 },
19020 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
19021 .unlock = spi_disable_blockprotect,
19022 .write = spi_chip_write_256,
19023 .read = spi_chip_read,
19024 .voltage = {2700, 3600},
19025 .reg_bits =
19026 {
Nico Huber2133f592024-01-06 18:30:01 +010019027 .qe = {STATUS2, 1, RW},
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019028 .srp = {STATUS1, 7, RW},
19029 .srl = {STATUS2, 0, RW},
19030 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
19031 .tb = {STATUS1, 5, RW},
19032 .sec = {STATUS1, 6, RW},
19033 .cmp = {STATUS2, 6, RW},
19034 .wps = {STATUS3, 2, RW},
19035 },
Nico Huberaabb3e02023-01-13 00:22:30 +010019036 .wp_write_cfg = spi_wp_write_cfg,
19037 .wp_read_cfg = spi_wp_read_cfg,
19038 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019039 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020019040 .prepare_access = spi_prepare_io,
19041 .finish_access = spi_finish_io,
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019042 },
19043
19044 {
19045 .vendor = "Winbond",
Angel Pons0d4354e2024-05-26 16:33:51 +020019046 .name = "W25Q32JV-.M",
19047 .bustype = BUS_SPI,
19048 .manufacture_id = WINBOND_NEX_ID,
19049 .model_id = WINBOND_NEX_W25Q32JV,
19050 .total_size = 4096,
19051 .page_size = 256,
19052 /* supports SFDP */
Nico Huber1412d9f2024-01-06 18:25:49 +010019053 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QPI_SRP |
Angel Pons0d4354e2024-05-26 16:33:51 +020019054 FEATURE_WRSR_EXT2 | FEATURE_WRSR2 | FEATURE_WRSR3,
Nico Huber1412d9f2024-01-06 18:25:49 +010019055 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Angel Pons0d4354e2024-05-26 16:33:51 +020019056 .tested = TEST_OK_PREW,
19057 .probe = probe_spi_rdid,
19058 .probe_timing = TIMING_ZERO,
19059 .block_erasers =
19060 {
19061 {
19062 .eraseblocks = { {4 * 1024, 1024} },
19063 .block_erase = spi_block_erase_20,
19064 }, {
19065 .eraseblocks = { {32 * 1024, 128} },
19066 .block_erase = spi_block_erase_52,
19067 }, {
19068 .eraseblocks = { {64 * 1024, 64} },
19069 .block_erase = spi_block_erase_d8,
19070 }, {
19071 .eraseblocks = { {4 * 1024 * 1024, 1} },
19072 .block_erase = spi_block_erase_60,
19073 }, {
19074 .eraseblocks = { {4 * 1024 * 1024, 1} },
19075 .block_erase = spi_block_erase_c7,
19076 }
19077 },
19078 .printlock = spi_prettyprint_status_register_bp2_tb_bpl,
19079 .unlock = spi_disable_blockprotect_bp2_srwd,
19080 .write = spi_chip_write_256,
19081 .read = spi_chip_read,
19082 .voltage = {2700, 3600},
19083 .reg_bits =
19084 {
Nico Huber2133f592024-01-06 18:30:01 +010019085 .qe = {STATUS2, 1, RW},
Angel Pons0d4354e2024-05-26 16:33:51 +020019086 .srp = {STATUS1, 7, RW},
19087 .srl = {STATUS2, 0, RW},
19088 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
19089 .tb = {STATUS1, 5, RW},
19090 .sec = {STATUS1, 6, RW},
19091 .cmp = {STATUS2, 6, RW},
19092 .wps = {STATUS3, 2, RW},
19093 },
19094 .wp_write_cfg = spi_wp_write_cfg,
19095 .wp_read_cfg = spi_wp_read_cfg,
19096 .wp_get_ranges = spi_wp_get_available_ranges,
19097 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020019098 .prepare_access = spi_prepare_io,
19099 .finish_access = spi_finish_io,
Angel Pons0d4354e2024-05-26 16:33:51 +020019100 },
19101
19102 {
19103 .vendor = "Winbond",
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019104 .name = "W25Q32BW/W25Q32CW/W25Q32DW",
Alan Green1f9cc7d2019-07-01 11:10:45 +100019105 .bustype = BUS_SPI,
19106 .manufacture_id = WINBOND_NEX_ID,
19107 .model_id = WINBOND_NEX_W25Q32_W,
19108 .total_size = 4096,
19109 .page_size = 256,
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019110 /* OTP: 1024B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber1412d9f2024-01-06 18:25:49 +010019111 /* QPI: only DW version */
19112 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +100019113 .tested = TEST_OK_PREW,
19114 .probe = probe_spi_rdid,
19115 .probe_timing = TIMING_ZERO,
19116 .block_erasers =
19117 {
19118 {
19119 .eraseblocks = { {4 * 1024, 1024} },
19120 .block_erase = spi_block_erase_20,
19121 }, {
19122 .eraseblocks = { {32 * 1024, 128} },
19123 .block_erase = spi_block_erase_52,
19124 }, {
19125 .eraseblocks = { {64 * 1024, 64} },
19126 .block_erase = spi_block_erase_d8,
19127 }, {
19128 .eraseblocks = { {4 * 1024 * 1024, 1} },
19129 .block_erase = spi_block_erase_60,
19130 }, {
19131 .eraseblocks = { {4 * 1024 * 1024, 1} },
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000019132 .block_erase = spi_block_erase_c7,
19133 }
19134 },
19135 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
19136 .unlock = spi_disable_blockprotect,
19137 .write = spi_chip_write_256,
19138 .read = spi_chip_read,
Nico Huber1412d9f2024-01-06 18:25:49 +010019139 .voltage = {1700, 1950},
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019140 .reg_bits =
19141 {
Nico Huber2133f592024-01-06 18:30:01 +010019142 .qe = {STATUS2, 1, RW},
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019143 .srp = {STATUS1, 7, RW},
19144 .srl = {STATUS2, 0, RW},
19145 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
19146 .tb = {STATUS1, 5, RW},
19147 .sec = {STATUS1, 6, RW},
19148 .cmp = {STATUS2, 6, RW},
19149 },
Nico Huberaabb3e02023-01-13 00:22:30 +010019150 .wp_write_cfg = spi_wp_write_cfg,
19151 .wp_read_cfg = spi_wp_read_cfg,
19152 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019153 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020019154 .prepare_access = spi_prepare_io,
19155 .finish_access = spi_finish_io,
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019156 },
19157
19158 {
19159 .vendor = "Winbond",
19160 .name = "W25Q32FW",
19161 .bustype = BUS_SPI,
19162 .manufacture_id = WINBOND_NEX_ID,
19163 .model_id = WINBOND_NEX_W25Q32_W,
19164 .total_size = 4096,
19165 .page_size = 256,
19166 /* OTP: 768B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber1412d9f2024-01-06 18:25:49 +010019167 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QPI_SRP |
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019168 FEATURE_WRSR_EXT2 | FEATURE_WRSR2 | FEATURE_WRSR3,
Nico Huber1412d9f2024-01-06 18:25:49 +010019169 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019170 .tested = TEST_OK_PREW,
19171 .probe = probe_spi_rdid,
19172 .probe_timing = TIMING_ZERO,
19173 .block_erasers =
19174 {
19175 {
19176 .eraseblocks = { {4 * 1024, 1024} },
19177 .block_erase = spi_block_erase_20,
19178 }, {
19179 .eraseblocks = { {32 * 1024, 128} },
19180 .block_erase = spi_block_erase_52,
19181 }, {
19182 .eraseblocks = { {64 * 1024, 64} },
19183 .block_erase = spi_block_erase_d8,
19184 }, {
19185 .eraseblocks = { {4 * 1024 * 1024, 1} },
19186 .block_erase = spi_block_erase_60,
19187 }, {
19188 .eraseblocks = { {4 * 1024 * 1024, 1} },
19189 .block_erase = spi_block_erase_c7,
19190 }
19191 },
19192 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
19193 .unlock = spi_disable_blockprotect,
19194 .write = spi_chip_write_256,
19195 .read = spi_chip_read,
Nico Huber1412d9f2024-01-06 18:25:49 +010019196 .voltage = {1700, 1950},
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019197 .reg_bits =
19198 {
Nico Huber2133f592024-01-06 18:30:01 +010019199 .qe = {STATUS2, 1, RW},
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019200 .srp = {STATUS1, 7, RW},
19201 .srl = {STATUS2, 0, RW},
19202 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
19203 .tb = {STATUS1, 5, RW},
19204 .sec = {STATUS1, 6, RW},
19205 .cmp = {STATUS2, 6, RW},
19206 .wps = {STATUS3, 2, RW},
19207 },
Nico Huberaabb3e02023-01-13 00:22:30 +010019208 .wp_write_cfg = spi_wp_write_cfg,
19209 .wp_read_cfg = spi_wp_read_cfg,
19210 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019211 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020019212 .prepare_access = spi_prepare_io,
19213 .finish_access = spi_finish_io,
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019214 },
19215
19216 {
19217 .vendor = "Winbond",
19218 .name = "W25Q32JW...Q",
19219 .bustype = BUS_SPI,
19220 .manufacture_id = WINBOND_NEX_ID,
19221 .model_id = WINBOND_NEX_W25Q32_W,
19222 .total_size = 4096,
19223 .page_size = 256,
19224 /* OTP: 768B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
19225 /* QPI enable 0x38, disable 0xFF */
Nico Huber2133f592024-01-06 18:30:01 +010019226 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QIO |
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019227 FEATURE_WRSR_EXT2 | FEATURE_WRSR2 | FEATURE_WRSR3,
19228 .tested = TEST_OK_PREW,
19229 .probe = probe_spi_rdid,
19230 .probe_timing = TIMING_ZERO,
19231 .block_erasers =
19232 {
19233 {
19234 .eraseblocks = { {4 * 1024, 1024} },
19235 .block_erase = spi_block_erase_20,
19236 }, {
19237 .eraseblocks = { {32 * 1024, 128} },
19238 .block_erase = spi_block_erase_52,
19239 }, {
19240 .eraseblocks = { {64 * 1024, 64} },
19241 .block_erase = spi_block_erase_d8,
19242 }, {
19243 .eraseblocks = { {4 * 1024 * 1024, 1} },
19244 .block_erase = spi_block_erase_60,
19245 }, {
19246 .eraseblocks = { {4 * 1024 * 1024, 1} },
19247 .block_erase = spi_block_erase_c7,
19248 }
19249 },
19250 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
19251 .unlock = spi_disable_blockprotect,
19252 .write = spi_chip_write_256,
19253 .read = spi_chip_read,
Nico Huber2133f592024-01-06 18:30:01 +010019254 .voltage = {1700, 1950},
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019255 .reg_bits =
19256 {
19257 .srp = {STATUS1, 7, RW},
19258 .srl = {STATUS2, 0, RW},
19259 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
19260 .tb = {STATUS1, 5, RW},
19261 .sec = {STATUS1, 6, RW},
19262 .cmp = {STATUS2, 6, RW},
19263 .wps = {STATUS3, 2, RW},
19264 },
Nico Huberaabb3e02023-01-13 00:22:30 +010019265 .wp_write_cfg = spi_wp_write_cfg,
19266 .wp_read_cfg = spi_wp_read_cfg,
19267 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019268 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020019269 .prepare_access = spi_prepare_io,
19270 .finish_access = spi_finish_io,
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000019271 },
19272
19273 {
19274 .vendor = "Winbond",
Nikolai Artemiev6ae79b12021-05-08 17:31:23 +100019275 .name = "W25Q32JW...M",
19276 .bustype = BUS_SPI,
19277 .manufacture_id = WINBOND_NEX_ID,
19278 .model_id = WINBOND_NEX_W25Q32JW_M,
19279 .total_size = 4096,
19280 .page_size = 256,
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019281 /* OTP: 768B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
19282 /* QPI enable 0x38, disable 0xFF */
Nico Huber2133f592024-01-06 18:30:01 +010019283 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QPI_SRP |
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019284 FEATURE_WRSR2 | FEATURE_WRSR3 | FEATURE_WRSR_EXT2,
Nico Huber2133f592024-01-06 18:30:01 +010019285 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Nikolai Artemiev6ae79b12021-05-08 17:31:23 +100019286 .tested = TEST_OK_PREW,
19287 .probe = probe_spi_rdid,
19288 .probe_timing = TIMING_ZERO,
19289 .block_erasers =
19290 {
19291 {
19292 .eraseblocks = { {4 * 1024, 1024} },
19293 .block_erase = spi_block_erase_20,
19294 }, {
19295 .eraseblocks = { {32 * 1024, 128} },
19296 .block_erase = spi_block_erase_52,
19297 }, {
19298 .eraseblocks = { {64 * 1024, 64} },
19299 .block_erase = spi_block_erase_d8,
19300 }, {
19301 .eraseblocks = { {4 * 1024 * 1024, 1} },
19302 .block_erase = spi_block_erase_60,
19303 }, {
19304 .eraseblocks = { {4 * 1024 * 1024, 1} },
19305 .block_erase = spi_block_erase_c7,
19306 }
19307 },
19308 .printlock = spi_prettyprint_status_register_bp2_tb_bpl,
19309 .unlock = spi_disable_blockprotect_bp2_srwd,
19310 .write = spi_chip_write_256,
19311 .read = spi_chip_read,
19312 .voltage = {1700, 1950},
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019313 .reg_bits =
19314 {
Nico Huber2133f592024-01-06 18:30:01 +010019315 .qe = {STATUS2, 1, RW},
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019316 .srp = {STATUS1, 7, RW},
19317 .srl = {STATUS2, 0, RW},
19318 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
19319 .tb = {STATUS1, 5, RW},
19320 .sec = {STATUS1, 6, RW},
19321 .cmp = {STATUS2, 6, RW},
19322 .wps = {STATUS3, 2, RW},
19323 },
Nico Huberaabb3e02023-01-13 00:22:30 +010019324 .wp_write_cfg = spi_wp_write_cfg,
19325 .wp_read_cfg = spi_wp_read_cfg,
19326 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukb1fb3f72022-07-25 00:27:37 +030019327 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020019328 .prepare_access = spi_prepare_io,
19329 .finish_access = spi_finish_io,
Nikolai Artemiev6ae79b12021-05-08 17:31:23 +100019330 },
19331
19332 {
19333 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100019334 .name = "W25Q40.V",
19335 .bustype = BUS_SPI,
19336 .manufacture_id = WINBOND_NEX_ID,
19337 .model_id = WINBOND_NEX_W25Q40_V,
19338 .total_size = 512,
19339 .page_size = 256,
19340 /* supports SFDP */
19341 /* OTP: 756B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010019342 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +100019343 .tested = TEST_OK_PREW,
19344 .probe = probe_spi_rdid,
19345 .probe_timing = TIMING_ZERO,
19346 .block_erasers =
19347 {
19348 {
19349 .eraseblocks = { {4 * 1024, 128} },
19350 .block_erase = spi_block_erase_20,
19351 }, {
19352 .eraseblocks = { {32 * 1024, 16} },
19353 .block_erase = spi_block_erase_52,
19354 }, {
19355 .eraseblocks = { {64 * 1024, 8} },
19356 .block_erase = spi_block_erase_d8,
19357 }, {
19358 .eraseblocks = { {512 * 1024, 1} },
19359 .block_erase = spi_block_erase_60,
19360 }, {
19361 .eraseblocks = { {512 * 1024, 1} },
19362 .block_erase = spi_block_erase_c7,
19363 }
19364 },
Nico Huber2133f592024-01-06 18:30:01 +010019365 .reg_bits =
19366 {
19367 .qe = {STATUS2, 1, RW},
19368 },
Alan Green1f9cc7d2019-07-01 11:10:45 +100019369 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
19370 .unlock = spi_disable_blockprotect,
19371 .write = spi_chip_write_256, /* Multi I/O supported */
Nico Huber2133f592024-01-06 18:30:01 +010019372 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +100019373 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020019374 .prepare_access = spi_prepare_io,
19375 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100019376 },
19377
19378 {
19379 .vendor = "Winbond",
Nico Huber25683572018-03-30 13:50:13 +020019380 .name = "W25Q40BW",
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000019381 .bustype = BUS_SPI,
19382 .manufacture_id = WINBOND_NEX_ID,
Nico Huber25683572018-03-30 13:50:13 +020019383 .model_id = WINBOND_NEX_W25Q40BW,
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000019384 .total_size = 512,
19385 .page_size = 256,
19386 /* OTP: 256B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010019387 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Angel Pons3164a0c2018-09-30 20:26:06 +020019388 .tested = TEST_OK_PREW,
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000019389 .probe = probe_spi_rdid,
19390 .probe_timing = TIMING_ZERO,
19391 .block_erasers =
19392 {
19393 {
19394 .eraseblocks = { {4 * 1024, 128} },
19395 .block_erase = spi_block_erase_20,
19396 }, {
19397 .eraseblocks = { {32 * 1024, 16} },
19398 .block_erase = spi_block_erase_52,
19399 }, {
19400 .eraseblocks = { {64 * 1024, 8} },
19401 .block_erase = spi_block_erase_d8,
19402 }, {
19403 .eraseblocks = { {512 * 1024, 1} },
19404 .block_erase = spi_block_erase_60,
19405 }, {
19406 .eraseblocks = { {512 * 1024, 1} },
19407 .block_erase = spi_block_erase_c7,
19408 }
19409 },
Nico Huber2133f592024-01-06 18:30:01 +010019410 .reg_bits =
19411 {
19412 .qe = {STATUS2, 1, RW},
19413 },
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000019414 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
19415 .unlock = spi_disable_blockprotect,
19416 .write = spi_chip_write_256,
19417 .read = spi_chip_read,
Nico Huber2133f592024-01-06 18:30:01 +010019418 .voltage = {1700, 1950},
Nico Huber930d4212024-05-04 18:59:15 +020019419 .prepare_access = spi_prepare_io,
19420 .finish_access = spi_finish_io,
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000019421 },
19422
19423 {
19424 .vendor = "Winbond",
Nico Huber25683572018-03-30 13:50:13 +020019425 .name = "W25Q40EW",
19426 .bustype = BUS_SPI,
19427 .manufacture_id = WINBOND_NEX_ID,
19428 .model_id = WINBOND_NEX_W25Q40EW,
19429 .total_size = 512,
19430 .page_size = 256,
19431 /* OTP: 3*256B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010019432 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_WRSR2 |
19433 FEATURE_OTP | FEATURE_QPI_SRP,
19434 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Alan Green07b8a172019-09-23 16:47:05 +100019435 .tested = TEST_OK_PREW,
Nico Huber25683572018-03-30 13:50:13 +020019436 .probe = probe_spi_rdid,
19437 .probe_timing = TIMING_ZERO,
19438 .block_erasers =
19439 {
19440 {
19441 .eraseblocks = { {4 * 1024, 128} },
19442 .block_erase = spi_block_erase_20,
19443 }, {
19444 .eraseblocks = { {32 * 1024, 16} },
19445 .block_erase = spi_block_erase_52,
19446 }, {
19447 .eraseblocks = { {64 * 1024, 8} },
19448 .block_erase = spi_block_erase_d8,
19449 }, {
19450 .eraseblocks = { {512 * 1024, 1} },
19451 .block_erase = spi_block_erase_60,
19452 }, {
19453 .eraseblocks = { {512 * 1024, 1} },
19454 .block_erase = spi_block_erase_c7,
19455 }
19456 },
Nico Huber2133f592024-01-06 18:30:01 +010019457 .reg_bits =
19458 {
19459 .qe = {STATUS2, 1, RW},
19460 },
Nico Huber25683572018-03-30 13:50:13 +020019461 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
19462 .unlock = spi_disable_blockprotect,
19463 .write = spi_chip_write_256,
19464 .read = spi_chip_read,
Nico Huber2133f592024-01-06 18:30:01 +010019465 .voltage = {1650, 1950},
Nico Huber930d4212024-05-04 18:59:15 +020019466 .prepare_access = spi_prepare_io,
19467 .finish_access = spi_finish_io,
Nico Huber25683572018-03-30 13:50:13 +020019468 },
19469
Stanislav Sedovf5775442018-03-07 14:16:51 -080019470 {
19471 .vendor = "Winbond",
Joel Stanley55439612019-07-27 19:25:35 +093019472 .name = "W25Q512JV",
19473 .bustype = BUS_SPI,
19474 .manufacture_id = WINBOND_NEX_ID,
19475 .model_id = WINBOND_NEX_W25Q512JV,
19476 .total_size = 64 * 1024,
19477 .page_size = 256,
Nico Huber2133f592024-01-06 18:30:01 +010019478 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_WRSR2 | FEATURE_WRSR3 |
19479 FEATURE_OTP | FEATURE_4BA | FEATURE_QIO,
Joel Stanley55439612019-07-27 19:25:35 +093019480 .tested = TEST_OK_PREW,
19481 .probe = probe_spi_rdid,
19482 .probe_timing = TIMING_ZERO,
19483 .block_erasers =
19484 {
19485 {
19486 .eraseblocks = { {4 * 1024, 16384} },
19487 .block_erase = spi_block_erase_21,
19488 }, {
19489 .eraseblocks = { {4 * 1024, 16384} },
19490 .block_erase = spi_block_erase_20,
19491 }, {
19492 .eraseblocks = { {32 * 1024, 2048} },
19493 .block_erase = spi_block_erase_52,
19494 }, {
19495 .eraseblocks = { {64 * 1024, 1024} },
19496 .block_erase = spi_block_erase_dc,
19497 }, {
19498 .eraseblocks = { {64 * 1024, 1024} },
19499 .block_erase = spi_block_erase_d8,
19500 }, {
19501 .eraseblocks = { {64 * 1024 * 1024, 1} },
19502 .block_erase = spi_block_erase_60,
19503 }, {
19504 .eraseblocks = { {64 * 1024 * 1024, 1} },
19505 .block_erase = spi_block_erase_c7,
19506 }
19507 },
Nico Huber2133f592024-01-06 18:30:01 +010019508 .reg_bits =
19509 {
19510 .qe = {STATUS2, 1, RW},
19511 },
Joel Stanley55439612019-07-27 19:25:35 +093019512 .printlock = spi_prettyprint_status_register_plain,
19513 .unlock = spi_disable_blockprotect,
19514 .write = spi_chip_write_256,
19515 .read = spi_chip_read,
19516 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020019517 .prepare_access = spi_prepare_io,
19518 .finish_access = spi_finish_io,
Joel Stanley55439612019-07-27 19:25:35 +093019519 },
19520
19521 {
Alexandru M Stan6ce26a72024-10-11 22:47:24 -070019522 .vendor = "Winbond",
19523 .name = "W25R512NW/W74M51NW",
19524 .bustype = BUS_SPI,
19525 .manufacture_id = WINBOND_NEX_ID,
19526 .model_id = WINBOND_NEX_W25R512NW,
19527 .total_size = 65536,
19528 .page_size = 256,
19529 /* supports SFDP */
19530 /* OTP: 3X256B; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
19531 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_4BA,
19532 .tested = TEST_OK_PREW,
19533 .probe = probe_spi_rdid,
19534 .probe_timing = TIMING_ZERO,
19535 .block_erasers =
19536 {
19537 {
19538 .eraseblocks = { {4 * 1024, 16384} },
19539 .block_erase = spi_block_erase_21,
19540 }, {
19541 .eraseblocks = { {4 * 1024, 16384} },
19542 .block_erase = spi_block_erase_20,
19543 }, {
19544 .eraseblocks = { {32 * 1024, 2048} },
19545 .block_erase = spi_block_erase_52,
19546 }, {
19547 .eraseblocks = { {64 * 1024, 1024} },
19548 .block_erase = spi_block_erase_dc,
19549 }, {
19550 .eraseblocks = { {64 * 1024, 1024} },
19551 .block_erase = spi_block_erase_d8,
19552 }, {
19553 .eraseblocks = { {64 * 1024 * 1024, 1} },
19554 .block_erase = spi_block_erase_60,
19555 }, {
19556 .eraseblocks = { {64 * 1024 * 1024, 1} },
19557 .block_erase = spi_block_erase_c7,
19558 }
19559 },
19560 .printlock = spi_prettyprint_status_register_bp3_srwd,
19561 .unlock = spi_disable_blockprotect,
19562 .write = spi_chip_write_256,
19563 .read = spi_chip_read,
19564 .voltage = {1700, 1950},
19565 .prepare_access = spi_prepare_io,
19566 .finish_access = spi_finish_io,
19567 },
19568
19569 {
Felix Singer3c9bdb92022-12-15 23:30:16 +010019570 .vendor = "Winbond",
19571 .name = "W25Q512NW-IM",
19572 .bustype = BUS_SPI,
19573 .manufacture_id = WINBOND_NEX_ID,
19574 .model_id = WINBOND_NEX_W25Q512NW_IM,
19575 .total_size = 64 * 1024,
19576 .page_size = 256,
Nico Huber2133f592024-01-06 18:30:01 +010019577 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_WRSR3 |
19578 FEATURE_OTP | FEATURE_4BA | FEATURE_QPI_SRP,
19579 .dummy_cycles =
19580 {
19581 /* Actually has 3 parameter bits, but higher values only help with DTR. */
19582 .qpi_read_params = { 2, 4, 6, 8 },
19583 },
Subrata Banikf5bffd92022-12-14 12:30:43 +053019584 .tested = TEST_OK_PREWB,
Felix Singer3c9bdb92022-12-15 23:30:16 +010019585 .probe = probe_spi_rdid,
19586 .probe_timing = TIMING_ZERO,
19587 .block_erasers =
Atul Dhudase2502dbd2021-09-21 10:02:20 +053019588 {
Felix Singer3c9bdb92022-12-15 23:30:16 +010019589 {
19590 .eraseblocks = { {4 * 1024, 16384} },
19591 .block_erase = spi_block_erase_21,
19592 }, {
19593 .eraseblocks = { {4 * 1024, 16384} },
19594 .block_erase = spi_block_erase_20,
19595 }, {
19596 .eraseblocks = { {32 * 1024, 2048} },
19597 .block_erase = spi_block_erase_52,
19598 }, {
19599 .eraseblocks = { {64 * 1024, 1024} },
19600 .block_erase = spi_block_erase_dc,
19601 }, {
19602 .eraseblocks = { {64 * 1024, 1024} },
19603 .block_erase = spi_block_erase_d8,
19604 }, {
19605 .eraseblocks = { {64 * 1024 * 1024, 1} },
19606 .block_erase = spi_block_erase_60,
19607 }, {
19608 .eraseblocks = { {64 * 1024 * 1024, 1} },
19609 .block_erase = spi_block_erase_c7,
19610 }
19611 },
19612 .unlock = spi_disable_blockprotect,
19613 .write = spi_chip_write_256,
19614 .read = spi_chip_read,
19615 .voltage = {1650, 1950},
Subrata Banikf5bffd92022-12-14 12:30:43 +053019616 .reg_bits =
19617 {
Nico Huber2133f592024-01-06 18:30:01 +010019618 .qe = {STATUS2, 1, RW},
Subrata Banikf5bffd92022-12-14 12:30:43 +053019619 .srp = {STATUS1, 7, RW},
19620 .srl = {STATUS2, 0, RW},
19621 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}, {STATUS1, 5, RW}},
19622 .tb = {STATUS1, 6, RW},
19623 .cmp = {STATUS2, 6, RW},
19624 .wps = {STATUS3, 2, RW},
19625 },
Nico Huberaabb3e02023-01-13 00:22:30 +010019626 .wp_write_cfg = spi_wp_write_cfg,
19627 .wp_read_cfg = spi_wp_read_cfg,
19628 .wp_get_ranges = spi_wp_get_available_ranges,
Subrata Banikf5bffd92022-12-14 12:30:43 +053019629 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020019630 .prepare_access = spi_prepare_io,
19631 .finish_access = spi_finish_io,
Atul Dhudase2502dbd2021-09-21 10:02:20 +053019632 },
19633
19634 {
Joel Stanley55439612019-07-27 19:25:35 +093019635 .vendor = "Winbond",
Sergii Dmytrukd1af3072021-11-08 00:00:43 +020019636 .name = "W25Q64BV/W25Q64CV/W25Q64FV",
Stanislav Sedovf5775442018-03-07 14:16:51 -080019637 .bustype = BUS_SPI,
19638 .manufacture_id = WINBOND_NEX_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +100019639 .model_id = WINBOND_NEX_W25Q64_V,
19640 .total_size = 8192,
Stanislav Sedovf5775442018-03-07 14:16:51 -080019641 .page_size = 256,
Alan Green1f9cc7d2019-07-01 11:10:45 +100019642 /* supports SFDP */
19643 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010019644 /* QPI: only FV version */
19645 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Sergii Dmytrukc74eac22022-10-06 18:17:58 +030019646 .tested = TEST_OK_PREWB,
Stanislav Sedovf5775442018-03-07 14:16:51 -080019647 .probe = probe_spi_rdid,
19648 .probe_timing = TIMING_ZERO,
19649 .block_erasers =
19650 {
19651 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100019652 .eraseblocks = { {4 * 1024, 2048} },
Stanislav Sedovf5775442018-03-07 14:16:51 -080019653 .block_erase = spi_block_erase_20,
19654 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100019655 .eraseblocks = { {32 * 1024, 256} },
Stanislav Sedovf5775442018-03-07 14:16:51 -080019656 .block_erase = spi_block_erase_52,
19657 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100019658 .eraseblocks = { {64 * 1024, 128} },
Stanislav Sedovf5775442018-03-07 14:16:51 -080019659 .block_erase = spi_block_erase_d8,
19660 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100019661 .eraseblocks = { {8 * 1024 * 1024, 1} },
Stanislav Sedovf5775442018-03-07 14:16:51 -080019662 .block_erase = spi_block_erase_60,
19663 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100019664 .eraseblocks = { {8 * 1024 * 1024, 1} },
Stanislav Sedovf5775442018-03-07 14:16:51 -080019665 .block_erase = spi_block_erase_c7,
19666 }
19667 },
19668 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
19669 .unlock = spi_disable_blockprotect,
19670 .write = spi_chip_write_256,
19671 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +100019672 .voltage = {2700, 3600},
Sergii Dmytrukd1af3072021-11-08 00:00:43 +020019673 .reg_bits =
19674 {
Nico Huber2133f592024-01-06 18:30:01 +010019675 .qe = {STATUS2, 1, RW},
Sergii Dmytrukd1af3072021-11-08 00:00:43 +020019676 .srp = {STATUS1, 7, RW},
19677 .srl = {STATUS2, 0, RW},
19678 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
19679 .tb = {STATUS1, 5, RW},
19680 .sec = {STATUS1, 6, RW},
19681 .cmp = {STATUS2, 6, RW},
19682 },
Nico Huberaabb3e02023-01-13 00:22:30 +010019683 .wp_write_cfg = spi_wp_write_cfg,
19684 .wp_read_cfg = spi_wp_read_cfg,
19685 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukd1af3072021-11-08 00:00:43 +020019686 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020019687 .prepare_access = spi_prepare_io,
19688 .finish_access = spi_finish_io,
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000019689 },
19690
19691 {
19692 .vendor = "Winbond",
Sergii Dmytrukd1af3072021-11-08 00:00:43 +020019693 .name = "W25Q64JV-.Q",
19694 .bustype = BUS_SPI,
19695 .manufacture_id = WINBOND_NEX_ID,
19696 .model_id = WINBOND_NEX_W25Q64_V,
19697 .total_size = 8192,
19698 .page_size = 256,
19699 /* supports SFDP */
19700 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010019701 .feature_bits = FEATURE_WRSR_WREN | FEATURE_OTP | FEATURE_QIO |
Nico Huber3f3c1f32022-05-28 16:48:26 +020019702 FEATURE_WRSR_EXT2 | FEATURE_WRSR2 | FEATURE_WRSR3,
Sergii Dmytrukd1af3072021-11-08 00:00:43 +020019703 .tested = TEST_OK_PREW,
19704 .probe = probe_spi_rdid,
19705 .probe_timing = TIMING_ZERO,
19706 .block_erasers =
19707 {
19708 {
19709 .eraseblocks = { {4 * 1024, 2048} },
19710 .block_erase = spi_block_erase_20,
19711 }, {
19712 .eraseblocks = { {32 * 1024, 256} },
19713 .block_erase = spi_block_erase_52,
19714 }, {
19715 .eraseblocks = { {64 * 1024, 128} },
19716 .block_erase = spi_block_erase_d8,
19717 }, {
19718 .eraseblocks = { {8 * 1024 * 1024, 1} },
19719 .block_erase = spi_block_erase_60,
19720 }, {
19721 .eraseblocks = { {8 * 1024 * 1024, 1} },
19722 .block_erase = spi_block_erase_c7,
19723 }
19724 },
19725 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
19726 .unlock = spi_disable_blockprotect,
19727 .write = spi_chip_write_256,
19728 .read = spi_chip_read,
19729 .voltage = {2700, 3600},
19730 .reg_bits =
19731 {
Nico Huber2133f592024-01-06 18:30:01 +010019732 .qe = {STATUS2, 1, RW},
Sergii Dmytrukd1af3072021-11-08 00:00:43 +020019733 .srp = {STATUS1, 7, RW},
19734 .srl = {STATUS2, 0, RW},
19735 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
19736 .tb = {STATUS1, 5, RW},
19737 .sec = {STATUS1, 6, RW},
19738 .cmp = {STATUS2, 6, RW},
19739 .wps = {STATUS3, 2, RW},
19740 },
Nico Huberaabb3e02023-01-13 00:22:30 +010019741 .wp_write_cfg = spi_wp_write_cfg,
19742 .wp_read_cfg = spi_wp_read_cfg,
19743 .wp_get_ranges = spi_wp_get_available_ranges,
Sergii Dmytrukd1af3072021-11-08 00:00:43 +020019744 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020019745 .prepare_access = spi_prepare_io,
19746 .finish_access = spi_finish_io,
Sergii Dmytrukd1af3072021-11-08 00:00:43 +020019747 },
19748
19749 {
19750 .vendor = "Winbond",
19751 .name = "W25Q64JV-.M",
Simon Buhrow236a38c2021-11-05 11:48:30 +010019752 .bustype = BUS_SPI,
19753 .manufacture_id = WINBOND_NEX_ID,
19754 .model_id = WINBOND_NEX_W25Q64JV,
19755 .total_size = 8192,
19756 .page_size = 256,
19757 /* supports SFDP */
Nico Huber2133f592024-01-06 18:30:01 +010019758 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_WRSR2 | FEATURE_WRSR3 |
19759 FEATURE_OTP | FEATURE_QPI_SRP,
Nico Huber1412d9f2024-01-06 18:25:49 +010019760 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Simon Buhrow236a38c2021-11-05 11:48:30 +010019761 .tested = TEST_OK_PREW,
19762 .probe = probe_spi_rdid,
19763 .probe_timing = TIMING_ZERO,
19764 .block_erasers =
19765 {
19766 {
19767 .eraseblocks = { {4 * 1024, 2048} },
19768 .block_erase = spi_block_erase_20,
19769 }, {
19770 .eraseblocks = { {32 * 1024, 256} },
19771 .block_erase = spi_block_erase_52,
19772 }, {
19773 .eraseblocks = { {64 * 1024, 128} },
19774 .block_erase = spi_block_erase_d8,
19775 }, {
19776 .eraseblocks = { {8 * 1024 * 1024, 1} },
19777 .block_erase = spi_block_erase_60,
19778 }, {
19779 .eraseblocks = { {8 * 1024 * 1024, 1} },
19780 .block_erase = spi_block_erase_c7,
19781 }
19782 },
Nico Huber2133f592024-01-06 18:30:01 +010019783 .reg_bits =
19784 {
19785 .qe = {STATUS2, 1, RW},
19786 },
Simon Buhrow236a38c2021-11-05 11:48:30 +010019787 .printlock = spi_prettyprint_status_register_bp2_tb_bpl,
19788 .unlock = spi_disable_blockprotect_bp2_srwd,
19789 .write = spi_chip_write_256,
19790 .read = spi_chip_read,
19791 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020019792 .prepare_access = spi_prepare_io,
19793 .finish_access = spi_finish_io,
Simon Buhrow236a38c2021-11-05 11:48:30 +010019794 },
19795
19796 {
19797 .vendor = "Winbond",
Nico Hubera358b142024-04-14 18:29:06 +020019798 .name = "W25Q64DW",
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000019799 .bustype = BUS_SPI,
19800 .manufacture_id = WINBOND_NEX_ID,
19801 .model_id = WINBOND_NEX_W25Q64_W,
19802 .total_size = 8192,
19803 .page_size = 256,
19804 /* OTP: 256B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber1412d9f2024-01-06 18:25:49 +010019805 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QPI_SRP,
19806 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Nico Hubera358b142024-04-14 18:29:06 +020019807 .tested = TEST_OK_PREW,
19808 .probe = probe_spi_rdid,
19809 .probe_timing = TIMING_ZERO,
19810 .block_erasers =
19811 {
19812 {
19813 .eraseblocks = { {4 * 1024, 2048} },
19814 .block_erase = spi_block_erase_20,
19815 }, {
19816 .eraseblocks = { {32 * 1024, 256} },
19817 .block_erase = spi_block_erase_52,
19818 }, {
19819 .eraseblocks = { {64 * 1024, 128} },
19820 .block_erase = spi_block_erase_d8,
19821 }, {
19822 .eraseblocks = { {8 * 1024 * 1024, 1} },
19823 .block_erase = spi_block_erase_60,
19824 }, {
19825 .eraseblocks = { {8 * 1024 * 1024, 1} },
19826 .block_erase = spi_block_erase_c7,
19827 }
19828 },
19829 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
19830 .unlock = spi_disable_blockprotect,
19831 .write = spi_chip_write_256,
19832 .read = spi_chip_read,
19833 .voltage = {1700, 1950}, /* Fast read (0x0B) and multi I/O supported */
19834 .reg_bits =
19835 {
19836 .srp = {STATUS1, 7, RW},
19837 .srl = {STATUS2, 0, RW},
19838 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
19839 .tb = {STATUS1, 5, RW},
19840 .sec = {STATUS1, 6, RW},
19841 .cmp = {STATUS2, 6, RW},
19842 },
19843 .wp_write_cfg = spi_wp_write_cfg,
19844 .wp_read_cfg = spi_wp_read_cfg,
19845 .wp_get_ranges = spi_wp_get_available_ranges,
19846 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020019847 .prepare_access = spi_prepare_io,
19848 .finish_access = spi_finish_io,
Nico Hubera358b142024-04-14 18:29:06 +020019849 },
19850
19851 {
19852 .vendor = "Winbond",
19853 .name = "W25Q64FW/W25Q64JW...Q",
19854 .bustype = BUS_SPI,
19855 .manufacture_id = WINBOND_NEX_ID,
19856 .model_id = WINBOND_NEX_W25Q64_W,
19857 .total_size = 8192,
19858 .page_size = 256,
19859 /* OTP: 256B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber1412d9f2024-01-06 18:25:49 +010019860 /* FEATURE_QPI_SRP (2, 4, 6, 8): only FW version */
Nico Hubera358b142024-04-14 18:29:06 +020019861 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_WRSR3 |
Nico Huber1412d9f2024-01-06 18:25:49 +010019862 FEATURE_OTP | FEATURE_QIO,
Sergii Dmytrukc74eac22022-10-06 18:17:58 +030019863 .tested = TEST_OK_PREWB,
Yung-Chieh Lob13d4e62013-06-09 14:00:46 +000019864 .probe = probe_spi_rdid,
19865 .probe_timing = TIMING_ZERO,
19866 .block_erasers =
19867 {
19868 {
19869 .eraseblocks = { {4 * 1024, 2048} },
19870 .block_erase = spi_block_erase_20,
19871 }, {
19872 .eraseblocks = { {32 * 1024, 256} },
19873 .block_erase = spi_block_erase_52,
19874 }, {
19875 .eraseblocks = { {64 * 1024, 128} },
19876 .block_erase = spi_block_erase_d8,
19877 }, {
19878 .eraseblocks = { {8 * 1024 * 1024, 1} },
19879 .block_erase = spi_block_erase_60,
19880 }, {
19881 .eraseblocks = { {8 * 1024 * 1024, 1} },
19882 .block_erase = spi_block_erase_c7,
19883 }
19884 },
19885 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
19886 .unlock = spi_disable_blockprotect,
19887 .write = spi_chip_write_256,
19888 .read = spi_chip_read,
Nico Huber1412d9f2024-01-06 18:25:49 +010019889 .voltage = {1700, 1950},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110019890 .reg_bits =
19891 {
Nico Huber2133f592024-01-06 18:30:01 +010019892 .qe = {STATUS2, 1, RW},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110019893 .srp = {STATUS1, 7, RW},
19894 .srl = {STATUS2, 0, RW},
19895 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
19896 .tb = {STATUS1, 5, RW},
19897 .sec = {STATUS1, 6, RW},
19898 .cmp = {STATUS2, 6, RW},
19899 },
Nico Huberaabb3e02023-01-13 00:22:30 +010019900 .wp_write_cfg = spi_wp_write_cfg,
19901 .wp_read_cfg = spi_wp_read_cfg,
19902 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110019903 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020019904 .prepare_access = spi_prepare_io,
19905 .finish_access = spi_finish_io,
Antony Rheneus0fbba982011-05-26 14:28:51 +000019906 },
19907
19908 {
19909 .vendor = "Winbond",
Nikolai Artemiev5fa05052021-05-14 15:26:47 +100019910 .name = "W25Q64JW...M",
Scott Chao1bbc5012020-04-08 22:10:50 +080019911 .bustype = BUS_SPI,
19912 .manufacture_id = WINBOND_NEX_ID,
Nikolai Artemiev5fa05052021-05-14 15:26:47 +100019913 .model_id = WINBOND_NEX_W25Q64JW_M,
Scott Chao1bbc5012020-04-08 22:10:50 +080019914 .total_size = 8192,
19915 .page_size = 256,
19916 /* OTP: 256B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
19917 /* QPI enable 0x38, disable 0xFF */
Nico Huber1412d9f2024-01-06 18:25:49 +010019918 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_WRSR3 |
19919 FEATURE_OTP | FEATURE_QPI_SRP,
19920 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Scott Chao1bbc5012020-04-08 22:10:50 +080019921 .tested = TEST_OK_PREW,
19922 .probe = probe_spi_rdid,
19923 .probe_timing = TIMING_ZERO,
19924 .block_erasers =
19925 {
19926 {
19927 .eraseblocks = { {4 * 1024, 2048} },
19928 .block_erase = spi_block_erase_20,
19929 }, {
19930 .eraseblocks = { {32 * 1024, 256} },
19931 .block_erase = spi_block_erase_52,
19932 }, {
19933 .eraseblocks = { {64 * 1024, 128} },
19934 .block_erase = spi_block_erase_d8,
19935 }, {
19936 .eraseblocks = { {8 * 1024 * 1024, 1} },
19937 .block_erase = spi_block_erase_60,
19938 }, {
19939 .eraseblocks = { {8 * 1024 * 1024, 1} },
19940 .block_erase = spi_block_erase_c7,
19941 }
19942 },
19943 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
19944 .unlock = spi_disable_blockprotect,
19945 .write = spi_chip_write_256,
19946 .read = spi_chip_read,
Nico Huber1412d9f2024-01-06 18:25:49 +010019947 .voltage = {1700, 1950},
Evan Benn29c8b5d2022-09-13 16:01:10 +100019948 .reg_bits =
19949 {
Nico Huber2133f592024-01-06 18:30:01 +010019950 .qe = {STATUS2, 1, RW},
Evan Benn29c8b5d2022-09-13 16:01:10 +100019951 .srp = {STATUS1, 7, RW},
19952 .srl = {STATUS2, 0, RW},
19953 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
19954 .tb = {STATUS1, 5, RW},
19955 .sec = {STATUS1, 6, RW},
19956 .cmp = {STATUS2, 6, RW},
19957 .wps = {STATUS3, 2, RW},
19958 },
Nico Huberaabb3e02023-01-13 00:22:30 +010019959 .wp_write_cfg = spi_wp_write_cfg,
19960 .wp_read_cfg = spi_wp_read_cfg,
19961 .wp_get_ranges = spi_wp_get_available_ranges,
Evan Benn29c8b5d2022-09-13 16:01:10 +100019962 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020019963 .prepare_access = spi_prepare_io,
19964 .finish_access = spi_finish_io,
Scott Chao1bbc5012020-04-08 22:10:50 +080019965 },
19966
19967 {
19968 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100019969 .name = "W25Q80.V",
Nico Huber70eed9f2017-04-24 22:19:27 +020019970 .bustype = BUS_SPI,
19971 .manufacture_id = WINBOND_NEX_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +100019972 .model_id = WINBOND_NEX_W25Q80_V,
19973 .total_size = 1024,
Nico Huber70eed9f2017-04-24 22:19:27 +020019974 .page_size = 256,
19975 /* supports SFDP */
19976 /* OTP: 1024B total, 256B reserved; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010019977 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
David Hendricks48729d32017-12-08 14:44:07 -080019978 .tested = TEST_OK_PREW,
Nico Huber70eed9f2017-04-24 22:19:27 +020019979 .probe = probe_spi_rdid,
19980 .probe_timing = TIMING_ZERO,
19981 .block_erasers =
19982 {
19983 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100019984 .eraseblocks = { {4 * 1024, 256} },
Nico Huber70eed9f2017-04-24 22:19:27 +020019985 .block_erase = spi_block_erase_20,
19986 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100019987 .eraseblocks = { {32 * 1024, 32} },
Nico Huber70eed9f2017-04-24 22:19:27 +020019988 .block_erase = spi_block_erase_52,
19989 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100019990 .eraseblocks = { {64 * 1024, 16} },
Nico Huber70eed9f2017-04-24 22:19:27 +020019991 .block_erase = spi_block_erase_d8,
19992 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100019993 .eraseblocks = { {1024 * 1024, 1} },
Nico Huber70eed9f2017-04-24 22:19:27 +020019994 .block_erase = spi_block_erase_60,
19995 }, {
Alan Green1f9cc7d2019-07-01 11:10:45 +100019996 .eraseblocks = { {1024 * 1024, 1} },
Nico Huber70eed9f2017-04-24 22:19:27 +020019997 .block_erase = spi_block_erase_c7,
19998 }
19999 },
Nico Huber2133f592024-01-06 18:30:01 +010020000 .reg_bits =
20001 {
20002 .qe = {STATUS2, 1, RW},
20003 },
Nico Huber70eed9f2017-04-24 22:19:27 +020020004 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
20005 .unlock = spi_disable_blockprotect,
20006 .write = spi_chip_write_256,
20007 .read = spi_chip_read,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020008 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020020009 .prepare_access = spi_prepare_io,
20010 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020011 },
20012
20013 {
20014 .vendor = "Winbond",
20015 .name = "W25Q80BW",
20016 .bustype = BUS_SPI,
20017 .manufacture_id = WINBOND_NEX_ID,
20018 .model_id = WINBOND_NEX_W25Q80BW,
20019 .total_size = 1024,
20020 .page_size = 256,
20021 /* OTP: 256B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010020022 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_OTP | FEATURE_QIO,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020023 .tested = TEST_OK_PREW,
20024 .probe = probe_spi_rdid,
20025 .probe_timing = TIMING_ZERO,
20026 .block_erasers =
20027 {
20028 {
20029 .eraseblocks = { {4 * 1024, 256} },
20030 .block_erase = spi_block_erase_20,
20031 }, {
20032 .eraseblocks = { {32 * 1024, 32} },
20033 .block_erase = spi_block_erase_52,
20034 }, {
20035 .eraseblocks = { {64 * 1024, 16} },
20036 .block_erase = spi_block_erase_d8,
20037 }, {
20038 .eraseblocks = { {1 * 1024 * 1024, 1} },
20039 .block_erase = spi_block_erase_60,
20040 }, {
20041 .eraseblocks = { {1 * 1024 * 1024, 1} },
20042 .block_erase = spi_block_erase_c7,
20043 }
20044 },
Nico Huber2133f592024-01-06 18:30:01 +010020045 .reg_bits =
20046 {
20047 .qe = {STATUS2, 1, RW},
20048 },
Alan Green1f9cc7d2019-07-01 11:10:45 +100020049 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
20050 .unlock = spi_disable_blockprotect,
20051 .write = spi_chip_write_256,
20052 .read = spi_chip_read,
Nico Huber2133f592024-01-06 18:30:01 +010020053 .voltage = {1700, 1950},
Nico Huber930d4212024-05-04 18:59:15 +020020054 .prepare_access = spi_prepare_io,
20055 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020056 },
20057
20058 {
20059 .vendor = "Winbond",
20060 .name = "W25Q80EW",
20061 .bustype = BUS_SPI,
20062 .manufacture_id = WINBOND_NEX_ID,
20063 .model_id = WINBOND_NEX_W25Q80EW,
20064 .total_size = 1024,
20065 .page_size = 256,
20066 /* OTP: 3*256B total; read 0x48; write 0x42, erase 0x44, read ID 0x4B */
Nico Huber2133f592024-01-06 18:30:01 +010020067 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR_EXT2 | FEATURE_WRSR2 |
20068 FEATURE_OTP | FEATURE_QPI_SRP,
20069 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
Alan Green1f9cc7d2019-07-01 11:10:45 +100020070 .tested = TEST_OK_PREW,
20071 .probe = probe_spi_rdid,
20072 .probe_timing = TIMING_ZERO,
20073 .block_erasers =
20074 {
20075 {
20076 .eraseblocks = { {4 * 1024, 256} },
20077 .block_erase = spi_block_erase_20,
20078 }, {
20079 .eraseblocks = { {32 * 1024, 32} },
20080 .block_erase = spi_block_erase_52,
20081 }, {
20082 .eraseblocks = { {64 * 1024, 16} },
20083 .block_erase = spi_block_erase_d8,
20084 }, {
20085 .eraseblocks = { {1 * 1024 * 1024, 1} },
20086 .block_erase = spi_block_erase_60,
20087 }, {
20088 .eraseblocks = { {1 * 1024 * 1024, 1} },
20089 .block_erase = spi_block_erase_c7,
20090 }
20091 },
Nico Huber2133f592024-01-06 18:30:01 +010020092 .reg_bits =
20093 {
20094 .qe = {STATUS2, 1, RW},
20095 },
Alan Green1f9cc7d2019-07-01 11:10:45 +100020096 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
20097 .unlock = spi_disable_blockprotect,
20098 .write = spi_chip_write_256,
20099 .read = spi_chip_read,
Nico Huber2133f592024-01-06 18:30:01 +010020100 .voltage = {1650, 1950},
Nico Huber930d4212024-05-04 18:59:15 +020020101 .prepare_access = spi_prepare_io,
20102 .finish_access = spi_finish_io,
Nico Huber70eed9f2017-04-24 22:19:27 +020020103 },
20104
20105 {
20106 .vendor = "Winbond",
Jacob Appelbaumebbdc022019-09-02 09:10:43 -040020107 .name = "W25X05",
20108 .bustype = BUS_SPI,
20109 .manufacture_id = WINBOND_NEX_ID,
20110 .model_id = WINBOND_NEX_W25X05,
20111 .total_size = 64,
20112 .page_size = 256,
Nico Hubera26a3c62024-04-12 19:28:28 +020020113 /* FEATURE_FAST_READ_DIO since W25X05B */
20114 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ_DOUT,
Jacob Appelbaumebbdc022019-09-02 09:10:43 -040020115 .tested = TEST_OK_PREW,
20116 .probe = probe_spi_rdid,
20117 .probe_timing = TIMING_ZERO,
20118 .block_erasers =
20119 {
20120 {
20121 .eraseblocks = { {4 * 1024, 16} },
20122 .block_erase = spi_block_erase_20,
20123 }, {
20124 .eraseblocks = { {32 * 1024, 2} },
20125 .block_erase = spi_block_erase_52,
20126 }, {
20127 .eraseblocks = { {64 * 1024, 1} },
20128 .block_erase = spi_block_erase_d8,
20129 }
20130 },
20131 .printlock = spi_prettyprint_status_register_plain,
20132 .unlock = spi_disable_blockprotect,
20133 .write = spi_chip_write_256,
20134 .read = spi_chip_read,
20135 .voltage = {2300, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020020136 .prepare_access = spi_prepare_io,
20137 .finish_access = spi_finish_io,
Jacob Appelbaumebbdc022019-09-02 09:10:43 -040020138 },
20139
20140 {
20141 .vendor = "Winbond",
Cristian Măgherușan-Stanciu9932c7b2011-07-07 19:56:58 +000020142 .name = "W25X10",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000020143 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020144 .manufacture_id = WINBOND_NEX_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000020145 .model_id = WINBOND_NEX_W25X10,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020146 .total_size = 128,
20147 .page_size = 256,
Nico Hubera26a3c62024-04-12 19:28:28 +020020148 /* FEATURE_FAST_READ_DIO since W25X10B */
20149 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ_DOUT,
Stefan Taunere34e3e82013-01-01 00:06:51 +000020150 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020151 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000020152 .probe_timing = TIMING_ZERO,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020153 .block_erasers =
20154 {
20155 {
20156 .eraseblocks = { {4 * 1024, 32} },
20157 .block_erase = spi_block_erase_20,
20158 }, {
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020159 .eraseblocks = { {64 * 1024, 2} },
20160 .block_erase = spi_block_erase_d8,
20161 }, {
20162 .eraseblocks = { {128 * 1024, 1} },
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020163 .block_erase = spi_block_erase_c7,
20164 }
20165 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +000020166 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +000020167 .unlock = spi_disable_blockprotect,
Carl-Daniel Hailfinger8d497012009-05-09 02:34:18 +000020168 .write = spi_chip_write_256,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020169 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000020170 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020020171 .prepare_access = spi_prepare_io,
20172 .finish_access = spi_finish_io,
FENG yu ningff692fb2008-12-08 18:15:10 +000020173 },
20174
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020175 {
20176 .vendor = "Winbond",
Cristian Măgherușan-Stanciu9932c7b2011-07-07 19:56:58 +000020177 .name = "W25X16",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000020178 .bustype = BUS_SPI,
Hector Martina721ae22009-07-11 19:39:11 +000020179 .manufacture_id = WINBOND_NEX_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000020180 .model_id = WINBOND_NEX_W25X16,
Hector Martina721ae22009-07-11 19:39:11 +000020181 .total_size = 2048,
20182 .page_size = 256,
Nico Hubera26a3c62024-04-12 19:28:28 +020020183 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ_DOUT,
Stefan Tauner8179be52011-06-04 13:13:34 +000020184 .tested = TEST_OK_PREW,
Hector Martina721ae22009-07-11 19:39:11 +000020185 .probe = probe_spi_rdid,
20186 .probe_timing = TIMING_ZERO,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020187 .block_erasers =
20188 {
20189 {
20190 .eraseblocks = { {4 * 1024, 512} },
20191 .block_erase = spi_block_erase_20,
20192 }, {
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020193 .eraseblocks = { {64 * 1024, 32} },
20194 .block_erase = spi_block_erase_d8,
20195 }, {
20196 .eraseblocks = { {2 * 1024 * 1024, 1} },
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020197 .block_erase = spi_block_erase_c7,
20198 }
20199 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +000020200 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +000020201 .unlock = spi_disable_blockprotect,
Hector Martina721ae22009-07-11 19:39:11 +000020202 .write = spi_chip_write_256,
20203 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000020204 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020020205 .prepare_access = spi_prepare_io,
20206 .finish_access = spi_finish_io,
Hector Martina721ae22009-07-11 19:39:11 +000020207 },
20208
20209 {
20210 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100020211 .name = "W25X20",
20212 .bustype = BUS_SPI,
20213 .manufacture_id = WINBOND_NEX_ID,
20214 .model_id = WINBOND_NEX_W25X20,
20215 .total_size = 256,
20216 .page_size = 256,
Nico Hubera26a3c62024-04-12 19:28:28 +020020217 /* FEATURE_FAST_READ_DIO since W25X20B */
20218 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ_DOUT,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020219 .tested = TEST_OK_PREW,
20220 .probe = probe_spi_rdid,
20221 .probe_timing = TIMING_ZERO,
20222 .block_erasers =
20223 {
20224 {
20225 .eraseblocks = { {4 * 1024, 64} },
20226 .block_erase = spi_block_erase_20,
20227 }, {
20228 .eraseblocks = { {64 * 1024, 4} },
20229 .block_erase = spi_block_erase_d8,
20230 }, {
20231 .eraseblocks = { {256 * 1024, 1} },
20232 .block_erase = spi_block_erase_c7,
20233 }
20234 },
20235 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
20236 .unlock = spi_disable_blockprotect,
20237 .write = spi_chip_write_256,
20238 .read = spi_chip_read,
20239 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020020240 .prepare_access = spi_prepare_io,
20241 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020242 },
20243
20244 {
20245 .vendor = "Winbond",
Cristian Măgherușan-Stanciu9932c7b2011-07-07 19:56:58 +000020246 .name = "W25X32",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000020247 .bustype = BUS_SPI,
Zheng Bao1db2b752009-11-26 11:05:01 +000020248 .manufacture_id = WINBOND_NEX_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000020249 .model_id = WINBOND_NEX_W25X32,
Zheng Bao1db2b752009-11-26 11:05:01 +000020250 .total_size = 4096,
20251 .page_size = 256,
Nico Hubera26a3c62024-04-12 19:28:28 +020020252 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ_DOUT,
Stefan Taunerc2eec2c2014-05-03 21:33:01 +000020253 .tested = TEST_OK_PREW,
Zheng Bao1db2b752009-11-26 11:05:01 +000020254 .probe = probe_spi_rdid,
20255 .probe_timing = TIMING_ZERO,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020256 .block_erasers =
20257 {
20258 {
20259 .eraseblocks = { {4 * 1024, 1024} },
20260 .block_erase = spi_block_erase_20,
20261 }, {
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020262 .eraseblocks = { {64 * 1024, 64} },
20263 .block_erase = spi_block_erase_d8,
20264 }, {
20265 .eraseblocks = { {4 * 1024 * 1024, 1} },
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020266 .block_erase = spi_block_erase_c7,
20267 }
20268 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +000020269 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +000020270 .unlock = spi_disable_blockprotect,
Zheng Bao1db2b752009-11-26 11:05:01 +000020271 .write = spi_chip_write_256,
20272 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000020273 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020020274 .prepare_access = spi_prepare_io,
20275 .finish_access = spi_finish_io,
Zheng Bao1db2b752009-11-26 11:05:01 +000020276 },
20277
20278 {
20279 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100020280 .name = "W25X40",
20281 .bustype = BUS_SPI,
20282 .manufacture_id = WINBOND_NEX_ID,
20283 .model_id = WINBOND_NEX_W25X40,
20284 .total_size = 512,
20285 .page_size = 256,
Nico Hubera26a3c62024-04-12 19:28:28 +020020286 /* FEATURE_FAST_READ_DIO since W25X40B */
20287 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ_DOUT,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020288 .tested = TEST_OK_PREW,
20289 .probe = probe_spi_rdid,
20290 .probe_timing = TIMING_ZERO,
20291 .block_erasers =
20292 {
20293 {
20294 .eraseblocks = { {4 * 1024, 128} },
20295 .block_erase = spi_block_erase_20,
20296 }, {
20297 .eraseblocks = { {64 * 1024, 8} },
20298 .block_erase = spi_block_erase_d8,
20299 }, {
20300 .eraseblocks = { {512 * 1024, 1} },
20301 .block_erase = spi_block_erase_c7,
20302 }
20303 },
20304 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
20305 .unlock = spi_disable_blockprotect,
20306 .write = spi_chip_write_256,
20307 .read = spi_chip_read,
20308 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020020309 .prepare_access = spi_prepare_io,
20310 .finish_access = spi_finish_io,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020311 },
20312
20313 {
20314 .vendor = "Winbond",
Cristian Măgherușan-Stanciu9932c7b2011-07-07 19:56:58 +000020315 .name = "W25X64",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000020316 .bustype = BUS_SPI,
Zheng Bao1db2b752009-11-26 11:05:01 +000020317 .manufacture_id = WINBOND_NEX_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000020318 .model_id = WINBOND_NEX_W25X64,
Zheng Bao1db2b752009-11-26 11:05:01 +000020319 .total_size = 8192,
20320 .page_size = 256,
Nico Hubera26a3c62024-04-12 19:28:28 +020020321 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ_DOUT,
Stefan Tauner23e10b82016-01-23 16:16:49 +000020322 .tested = TEST_OK_PREW,
Zheng Bao1db2b752009-11-26 11:05:01 +000020323 .probe = probe_spi_rdid,
20324 .probe_timing = TIMING_ZERO,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020325 .block_erasers =
20326 {
20327 {
20328 .eraseblocks = { {4 * 1024, 2048} },
20329 .block_erase = spi_block_erase_20,
20330 }, {
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020331 .eraseblocks = { {64 * 1024, 128} },
20332 .block_erase = spi_block_erase_d8,
20333 }, {
20334 .eraseblocks = { {8 * 1024 * 1024, 1} },
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020335 .block_erase = spi_block_erase_c7,
20336 }
20337 },
Stefan Tauner6ee37e22012-12-29 15:03:51 +000020338 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
Carl-Daniel Hailfinger29a1c662010-07-14 20:21:22 +000020339 .unlock = spi_disable_blockprotect,
Zheng Bao1db2b752009-11-26 11:05:01 +000020340 .write = spi_chip_write_256,
20341 .read = spi_chip_read,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000020342 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020020343 .prepare_access = spi_prepare_io,
20344 .finish_access = spi_finish_io,
Zheng Bao1db2b752009-11-26 11:05:01 +000020345 },
20346
20347 {
Alan Greenfa3fcd32019-06-27 15:41:50 +100020348 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100020349 .name = "W25X80",
Alan Greenfa3fcd32019-06-27 15:41:50 +100020350 .bustype = BUS_SPI,
20351 .manufacture_id = WINBOND_NEX_ID,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020352 .model_id = WINBOND_NEX_W25X80,
Alan Greenfa3fcd32019-06-27 15:41:50 +100020353 .total_size = 1024,
20354 .page_size = 256,
Nico Hubera26a3c62024-04-12 19:28:28 +020020355 /* FEATURE_FAST_READ_DIO since W25X80B */
20356 .feature_bits = FEATURE_WRSR_WREN | FEATURE_FAST_READ_DOUT,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020357 .tested = TEST_OK_PREW,
Alan Greenfa3fcd32019-06-27 15:41:50 +100020358 .probe = probe_spi_rdid,
20359 .probe_timing = TIMING_ZERO,
20360 .block_erasers =
David Hendricksc9ee0ed2018-02-11 17:40:53 -080020361 {
20362 {
Alan Green1f9cc7d2019-07-01 11:10:45 +100020363 .eraseblocks = { {4 * 1024, 256} },
20364 .block_erase = spi_block_erase_20,
20365 }, {
David Hendricksc9ee0ed2018-02-11 17:40:53 -080020366 .eraseblocks = { {64 * 1024, 16} },
20367 .block_erase = spi_block_erase_d8,
20368 }, {
20369 .eraseblocks = { {1024 * 1024, 1} },
20370 .block_erase = spi_block_erase_c7,
20371 }
20372 },
Alan Greenfa3fcd32019-06-27 15:41:50 +100020373 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
20374 .unlock = spi_disable_blockprotect,
20375 .write = spi_chip_write_256,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020376 .read = spi_chip_read,
Alan Greenfa3fcd32019-06-27 15:41:50 +100020377 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020020378 .prepare_access = spi_prepare_io,
20379 .finish_access = spi_finish_io,
David Hendricksc9ee0ed2018-02-11 17:40:53 -080020380 },
20381
Alan Greenf29ea362019-06-27 17:14:02 +100020382 /* W29EE011, W29EE012, W29C010M, W29C011A do not support probe_jedec according to the datasheet, but it works for newer(?) steppings. */
20383 {
Carl-Daniel Hailfinger2e88a9f2011-07-26 14:18:52 +000020384 .vendor = "Winbond",
Mattias Mattssona745cf42010-09-14 23:56:56 +000020385 .name = "W29C010(M)/W29C011A/W29EE011/W29EE012",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000020386 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020387 .manufacture_id = WINBOND_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000020388 .model_id = WINBOND_W29C010,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020389 .total_size = 128,
20390 .page_size = 128,
Sean Nelson35727f72010-01-28 23:55:12 +000020391 .feature_bits = FEATURE_LONG_RESET,
David Hendricks567b7b82011-05-18 01:31:03 +000020392 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020393 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000020394 .probe_timing = 10, /* used datasheet for the W29C011A */
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020395 .block_erasers =
20396 {
20397 {
20398 .eraseblocks = { {128 * 1024, 1} },
20399 .block_erase = erase_chip_block_jedec,
20400 }
20401 },
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020402 .write = write_jedec,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000020403 .read = read_memmapped,
Nico Huber9eec4072023-01-12 01:17:30 +010020404 .prepare_access = prepare_memory_access,
20405 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000020406 },
20407
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020408 {
20409 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100020410 .name = "W29C010(M)/W29C011A/W29EE011/W29EE012-old",
20411 .bustype = BUS_PARALLEL,
20412 .manufacture_id = WINBOND_ID,
20413 .model_id = WINBOND_W29C010,
20414 .total_size = 128,
20415 .page_size = 128,
20416 .feature_bits = FEATURE_LONG_RESET,
20417 .tested = TEST_OK_PREW,
20418 .probe = probe_w29ee011,
20419 .probe_timing = TIMING_IGNORED, /* routine doesn't use probe_timing (w29ee011.c) */
20420 .block_erasers =
20421 {
20422 {
20423 .eraseblocks = { {128 * 1024, 1} },
20424 .block_erase = erase_chip_block_jedec,
20425 }
20426 },
20427 .write = write_jedec,
20428 .read = read_memmapped,
Nico Huber9eec4072023-01-12 01:17:30 +010020429 .prepare_access = prepare_memory_access,
20430 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020431 },
20432
20433 {
20434 .vendor = "Winbond",
Mattias Mattssona745cf42010-09-14 23:56:56 +000020435 .name = "W29C020(C)/W29C022",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000020436 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020437 .manufacture_id = WINBOND_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000020438 .model_id = WINBOND_W29C020,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020439 .total_size = 256,
20440 .page_size = 128,
Sean Nelson35727f72010-01-28 23:55:12 +000020441 .feature_bits = FEATURE_LONG_RESET,
Cristian Măgherușan-Stanciu9932c7b2011-07-07 19:56:58 +000020442 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020443 .probe = probe_jedec,
Cristian Măgherușan-Stanciu9932c7b2011-07-07 19:56:58 +000020444 .probe_timing = 10,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020445 .block_erasers =
20446 {
20447 {
20448 .eraseblocks = { {256 * 1024, 1} },
20449 .block_erase = erase_chip_block_jedec,
20450 }
20451 },
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020452 .write = write_jedec,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000020453 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000020454 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010020455 .prepare_access = prepare_memory_access,
20456 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000020457 },
20458
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020459 {
20460 .vendor = "Winbond",
Mattias Mattssona745cf42010-09-14 23:56:56 +000020461 .name = "W29C040/P",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000020462 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020463 .manufacture_id = WINBOND_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000020464 .model_id = WINBOND_W29C040,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020465 .total_size = 512,
20466 .page_size = 256,
Sean Nelson35727f72010-01-28 23:55:12 +000020467 .feature_bits = FEATURE_LONG_RESET,
20468 .tested = TEST_UNTESTED,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020469 .probe = probe_jedec,
Stefan Tauner0554ca52013-07-25 22:54:25 +000020470 .probe_timing = 10,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020471 .block_erasers =
20472 {
20473 {
20474 .eraseblocks = { {512 * 1024, 1} },
20475 .block_erase = erase_chip_block_jedec,
20476 }
20477 },
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020478 .write = write_jedec,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000020479 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000020480 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010020481 .prepare_access = prepare_memory_access,
20482 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000020483 },
20484
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020485 {
20486 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100020487 .name = "W29C512A/W29EE512",
20488 .bustype = BUS_PARALLEL,
20489 .manufacture_id = WINBOND_ID,
20490 .model_id = WINBOND_W29C512A,
20491 .total_size = 64,
20492 .page_size = 128,
20493 .feature_bits = FEATURE_LONG_RESET,
20494 .tested = TEST_OK_PREW,
20495 .probe = probe_jedec,
20496 .probe_timing = 10,
20497 .block_erasers =
20498 {
20499 {
20500 .eraseblocks = { {64 * 1024, 1} },
20501 .block_erase = erase_chip_block_jedec,
20502 }
20503 },
20504 .write = write_jedec,
20505 .read = read_memmapped,
20506 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010020507 .prepare_access = prepare_memory_access,
20508 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020509 },
20510
20511 {
20512 .vendor = "Winbond",
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000020513 .name = "W29GL032CB",
20514 .bustype = BUS_PARALLEL,
20515 .manufacture_id = AMD_ID, /* WTF: "Industry Standard compatible Manufacturer ID code of 01h" */
20516 .model_id = WINBOND_W29GL032CB,
20517 .total_size = 4096,
20518 .page_size = 128 * 1024, /* actual page size is 16 */
20519 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
20520 .tested = TEST_UNTESTED,
20521 .probe = probe_jedec_29gl,
20522 .probe_timing = TIMING_ZERO,
20523 .block_erasers =
20524 {
20525 {
20526 .eraseblocks = {
20527 {8 * 1024, 8},
20528 {64 * 1024, 63},
20529 },
20530 .block_erase = erase_sector_jedec,
20531 }, {
20532 .eraseblocks = { {4 * 1024 * 1024, 1} },
20533 .block_erase = erase_chip_block_jedec,
20534 },
20535 },
20536 .write = write_jedec_1,
20537 .read = read_memmapped,
20538 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010020539 .prepare_access = prepare_memory_access,
20540 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000020541 },
20542
20543 {
20544 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100020545 .name = "W29GL032CH/L",
20546 .bustype = BUS_PARALLEL,
20547 .manufacture_id = AMD_ID, /* WTF: "Industry Standard compatible Manufacturer ID code of 01h" */
20548 .model_id = WINBOND_W29GL032CHL,
20549 .total_size = 4096,
20550 .page_size = 128 * 1024, /* actual page size is 16 */
20551 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
20552 .tested = TEST_UNTESTED,
20553 .probe = probe_jedec_29gl,
20554 .probe_timing = TIMING_ZERO,
20555 .block_erasers =
20556 {
20557 {
20558 .eraseblocks = { {64 * 1024, 64} },
20559 .block_erase = erase_sector_jedec,
20560 }, {
20561 .eraseblocks = { {4 * 1024 * 1024, 1} },
20562 .block_erase = erase_chip_block_jedec,
20563 },
20564 },
20565 .write = write_jedec_1,
20566 .read = read_memmapped,
20567 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010020568 .prepare_access = prepare_memory_access,
20569 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020570 },
20571
20572 {
20573 .vendor = "Winbond",
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000020574 .name = "W29GL032CT",
20575 .bustype = BUS_PARALLEL,
20576 .manufacture_id = AMD_ID, /* WTF: "Industry Standard compatible Manufacturer ID code of 01h" */
20577 .model_id = WINBOND_W29GL032CT,
20578 .total_size = 4096,
20579 .page_size = 128 * 1024, /* actual page size is 16 */
20580 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
20581 .tested = TEST_UNTESTED,
20582 .probe = probe_jedec_29gl,
20583 .probe_timing = TIMING_ZERO,
20584 .block_erasers =
20585 {
20586 {
20587 .eraseblocks = {
20588 {64 * 1024, 63},
20589 {8 * 1024, 8},
20590 },
20591 .block_erase = erase_sector_jedec,
20592 }, {
20593 .eraseblocks = { {4 * 1024 * 1024, 1} },
20594 .block_erase = erase_chip_block_jedec,
20595 },
20596 },
20597 .write = write_jedec_1,
20598 .read = read_memmapped,
20599 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010020600 .prepare_access = prepare_memory_access,
20601 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000020602 },
20603
20604 {
20605 .vendor = "Winbond",
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000020606 .name = "W29GL064CB",
20607 .bustype = BUS_PARALLEL,
20608 .manufacture_id = AMD_ID, /* WTF: "Industry Standard compatible Manufacturer ID code of 01h" */
20609 .model_id = WINBOND_W29GL064CB,
20610 .total_size = 8192,
20611 .page_size = 128 * 1024, /* actual page size is 16 */
20612 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
20613 .tested = TEST_UNTESTED,
20614 .probe = probe_jedec_29gl,
20615 .probe_timing = TIMING_ZERO,
20616 .block_erasers =
20617 {
20618 {
20619 .eraseblocks = {
20620 {8 * 1024, 8},
20621 {64 * 1024, 127},
20622 },
20623 .block_erase = erase_sector_jedec,
20624 }, {
20625 .eraseblocks = { {8 * 1024 * 1024, 1} },
20626 .block_erase = erase_chip_block_jedec,
20627 },
20628 },
20629 .write = write_jedec_1,
20630 .read = read_memmapped,
20631 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010020632 .prepare_access = prepare_memory_access,
20633 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000020634 },
20635
20636 {
20637 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100020638 .name = "W29GL064CH/L",
20639 .bustype = BUS_PARALLEL,
20640 .manufacture_id = AMD_ID, /* WTF: "Industry Standard compatible Manufacturer ID code of 01h" */
20641 .model_id = WINBOND_W29GL064CHL,
20642 .total_size = 8192,
20643 .page_size = 128 * 1024, /* actual page size is 16 */
20644 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
20645 .tested = TEST_UNTESTED,
20646 .probe = probe_jedec_29gl,
20647 .probe_timing = TIMING_ZERO,
20648 .block_erasers =
20649 {
20650 {
20651 .eraseblocks = { {64 * 1024, 128} },
20652 .block_erase = erase_sector_jedec,
20653 }, {
20654 .eraseblocks = { {8 * 1024 * 1024, 1} },
20655 .block_erase = erase_chip_block_jedec,
20656 },
20657 },
20658 .write = write_jedec_1,
20659 .read = read_memmapped,
20660 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010020661 .prepare_access = prepare_memory_access,
20662 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100020663 },
20664
20665 {
20666 .vendor = "Winbond",
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000020667 .name = "W29GL064CT",
20668 .bustype = BUS_PARALLEL,
20669 .manufacture_id = AMD_ID, /* WTF: "Industry Standard compatible Manufacturer ID code of 01h" */
20670 .model_id = WINBOND_W29GL064CT,
20671 .total_size = 8192,
20672 .page_size = 128 * 1024, /* actual page size is 16 */
20673 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
20674 .tested = TEST_UNTESTED,
20675 .probe = probe_jedec_29gl,
20676 .probe_timing = TIMING_ZERO,
20677 .block_erasers =
20678 {
20679 {
20680 .eraseblocks = {
20681 {64 * 1024, 127},
20682 {8 * 1024, 8},
20683 },
20684 .block_erase = erase_sector_jedec,
20685 }, {
20686 .eraseblocks = { {8 * 1024 * 1024, 1} },
20687 .block_erase = erase_chip_block_jedec,
20688 },
20689 },
20690 .write = write_jedec_1,
20691 .read = read_memmapped,
20692 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010020693 .prepare_access = prepare_memory_access,
20694 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000020695 },
20696
20697 {
20698 .vendor = "Winbond",
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000020699 .name = "W29GL128C",
20700 .bustype = BUS_PARALLEL,
20701 .manufacture_id = AMD_ID, /* WTF: "Industry Standard compatible Manufacturer ID code of 01h" */
20702 .model_id = WINBOND_W29GL128CHL,
20703 .total_size = 16384,
20704 .page_size = 128 * 1024, /* actual page size is 16 */
20705 .feature_bits = FEATURE_ADDR_2AA | FEATURE_SHORT_RESET,
20706 .tested = TEST_UNTESTED,
20707 .probe = probe_jedec_29gl,
20708 .probe_timing = TIMING_ZERO,
20709 .block_erasers =
20710 {
20711 {
20712 .eraseblocks = { {128 * 1024, 128} },
20713 .block_erase = erase_sector_jedec,
20714 }, {
20715 .eraseblocks = { {16 * 1024 * 1024, 1} },
20716 .block_erase = erase_chip_block_jedec,
20717 },
20718 },
20719 .write = write_jedec_1,
20720 .read = read_memmapped,
20721 .voltage = {2700, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010020722 .prepare_access = prepare_memory_access,
20723 .finish_access = finish_memory_access,
Stefan Tauner03a9c3c2014-08-03 14:15:14 +000020724 },
20725
20726 {
20727 .vendor = "Winbond",
Kyösti Mälkkic31243e2012-10-28 01:50:08 +000020728 .name = "W39F010",
20729 .bustype = BUS_PARALLEL,
20730 .manufacture_id = WINBOND_ID,
20731 .model_id = WINBOND_W39F010,
20732 .total_size = 128,
20733 .page_size = 4 * 1024,
20734 .feature_bits = FEATURE_EITHER_RESET,
20735 .tested = TEST_OK_PREW,
20736 .probe = probe_jedec,
20737 .probe_timing = 10,
20738 .block_erasers =
20739 {
20740 {
20741 .eraseblocks = { {4 * 1024, 32} },
20742 .block_erase = erase_block_jedec,
20743 }, {
20744 .eraseblocks = { {128 * 1024, 1} },
20745 .block_erase = erase_chip_block_jedec,
20746 }
20747 },
20748 .printlock = printlock_w39f010,
20749 .write = write_jedec_1,
20750 .read = read_memmapped,
20751 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010020752 .prepare_access = prepare_memory_access,
20753 .finish_access = finish_memory_access,
Kyösti Mälkkic31243e2012-10-28 01:50:08 +000020754 },
20755
20756 {
20757 .vendor = "Winbond",
20758 .name = "W39L010",
20759 .bustype = BUS_PARALLEL,
20760 .manufacture_id = WINBOND_ID,
20761 .model_id = WINBOND_W39L010,
20762 .total_size = 128,
20763 .page_size = 4 * 1024,
20764 .feature_bits = FEATURE_EITHER_RESET,
20765 .tested = TEST_UNTESTED,
20766 .probe = probe_jedec,
20767 .probe_timing = 10,
20768 .block_erasers =
20769 {
20770 {
20771 .eraseblocks = { {4 * 1024, 32} },
20772 .block_erase = erase_block_jedec,
20773 }, {
20774 .eraseblocks = { {128 * 1024, 1} },
20775 .block_erase = erase_chip_block_jedec,
20776 }
20777 },
20778 .printlock = printlock_w39l010,
20779 .write = write_jedec_1,
20780 .read = read_memmapped,
20781 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010020782 .prepare_access = prepare_memory_access,
20783 .finish_access = finish_memory_access,
Kyösti Mälkkic31243e2012-10-28 01:50:08 +000020784 },
20785
20786 {
20787 .vendor = "Winbond",
20788 .name = "W39L020",
20789 .bustype = BUS_PARALLEL,
20790 .manufacture_id = WINBOND_ID,
20791 .model_id = WINBOND_W39L020,
20792 .total_size = 256,
20793 .page_size = 4 * 1024,
20794 .feature_bits = FEATURE_EITHER_RESET,
20795 .tested = TEST_UNTESTED,
20796 .probe = probe_jedec,
20797 .probe_timing = 10,
20798 .block_erasers =
20799 {
20800 {
20801 .eraseblocks = { {4 * 1024, 64} },
20802 .block_erase = erase_block_jedec,
20803 }, {
20804 .eraseblocks = { {64 * 1024, 4} },
20805 .block_erase = erase_sector_jedec,
20806 }, {
20807 .eraseblocks = { {256 * 1024, 1} },
20808 .block_erase = erase_chip_block_jedec,
20809 }
20810 },
20811 .printlock = printlock_w39l020,
20812 .write = write_jedec_1,
20813 .read = read_memmapped,
20814 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010020815 .prepare_access = prepare_memory_access,
20816 .finish_access = finish_memory_access,
Kyösti Mälkkic31243e2012-10-28 01:50:08 +000020817 },
20818
20819 {
20820 .vendor = "Winbond",
Michael Karcher19e0aac2011-03-06 17:58:05 +000020821 .name = "W39L040",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000020822 .bustype = BUS_PARALLEL,
Michael Karcher19e0aac2011-03-06 17:58:05 +000020823 .manufacture_id = WINBOND_ID,
20824 .model_id = WINBOND_W39L040,
20825 .total_size = 512,
20826 .page_size = 64 * 1024,
20827 .feature_bits = FEATURE_EITHER_RESET,
20828 .tested = TEST_OK_PR,
20829 .probe = probe_jedec,
20830 .probe_timing = 10,
20831 .block_erasers =
20832 {
20833 {
20834 .eraseblocks = { {4 * 1024, 128} },
20835 .block_erase = erase_block_jedec,
20836 }, {
20837 .eraseblocks = { {64 * 1024, 8} },
20838 .block_erase = erase_sector_jedec,
20839 }, {
20840 .eraseblocks = { {512 * 1024, 1} },
20841 .block_erase = erase_chip_block_jedec,
20842 }
20843 },
20844 .printlock = printlock_w39l040,
20845 .write = write_jedec_1,
20846 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +000020847 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010020848 .prepare_access = prepare_memory_access,
20849 .finish_access = finish_memory_access,
Michael Karcher19e0aac2011-03-06 17:58:05 +000020850 },
20851
20852 {
20853 .vendor = "Winbond",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020854 .name = "W39V040A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000020855 .bustype = BUS_LPC,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020856 .manufacture_id = WINBOND_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000020857 .model_id = WINBOND_W39V040A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020858 .total_size = 512,
Sean Nelson72a9a022009-12-22 22:15:33 +000020859 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000020860 .feature_bits = FEATURE_EITHER_RESET,
Stefan Tauner716e0982011-07-25 20:38:52 +000020861 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020862 .probe = probe_jedec,
Stefan Tauner716e0982011-07-25 20:38:52 +000020863 .probe_timing = 10,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020864 .block_erasers =
20865 {
20866 {
20867 .eraseblocks = { {64 * 1024, 8} },
20868 .block_erase = erase_sector_jedec,
20869 }, {
20870 .eraseblocks = { {512 * 1024, 1} },
20871 .block_erase = erase_chip_block_jedec,
20872 }
20873 },
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000020874 .printlock = printlock_w39v040a,
Sean Nelson35727f72010-01-28 23:55:12 +000020875 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000020876 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000020877 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010020878 .prepare_access = prepare_memory_access,
20879 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000020880 },
20881
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020882 {
20883 .vendor = "Winbond",
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000020884 .name = "W39V040B",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000020885 .bustype = BUS_LPC,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020886 .manufacture_id = WINBOND_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000020887 .model_id = WINBOND_W39V040B,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020888 .total_size = 512,
Sean Nelson72a9a022009-12-22 22:15:33 +000020889 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000020890 .feature_bits = FEATURE_EITHER_RESET,
Paul Menzel018d4822011-10-21 12:33:07 +000020891 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020892 .probe = probe_jedec,
Paul Menzel018d4822011-10-21 12:33:07 +000020893 .probe_timing = 10,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020894 .block_erasers =
20895 {
20896 {
20897 .eraseblocks = { {64 * 1024, 8} },
20898 .block_erase = erase_sector_jedec,
20899 }, {
20900 .eraseblocks = { {512 * 1024, 1} },
20901 .block_erase = erase_chip_block_jedec,
20902 }
20903 },
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000020904 .printlock = printlock_w39v040b,
Sean Nelson35727f72010-01-28 23:55:12 +000020905 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000020906 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000020907 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010020908 .prepare_access = prepare_memory_access,
20909 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000020910 },
20911
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020912 {
20913 .vendor = "Winbond",
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000020914 .name = "W39V040C",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000020915 .bustype = BUS_LPC,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020916 .manufacture_id = WINBOND_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000020917 .model_id = WINBOND_W39V040C,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020918 .total_size = 512,
Sean Nelson72a9a022009-12-22 22:15:33 +000020919 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000020920 .feature_bits = FEATURE_EITHER_RESET,
Paul Menzel018d4822011-10-21 12:33:07 +000020921 .tested = TEST_OK_PREW,
Sean Nelson35727f72010-01-28 23:55:12 +000020922 .probe = probe_jedec,
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000020923 .probe_timing = 10,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020924 .block_erasers =
20925 {
20926 {
20927 .eraseblocks = { {64 * 1024, 8} },
20928 .block_erase = erase_sector_jedec,
20929 }, {
20930 .eraseblocks = { {512 * 1024, 1} },
20931 .block_erase = erase_chip_block_jedec,
20932 }
20933 },
Sean Nelson6e0b9122010-02-19 00:52:10 +000020934 .printlock = printlock_w39v040c,
Sean Nelson35727f72010-01-28 23:55:12 +000020935 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000020936 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000020937 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010020938 .prepare_access = prepare_memory_access,
20939 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000020940 },
20941
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020942 {
20943 .vendor = "Winbond",
20944 .name = "W39V040FA",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000020945 .bustype = BUS_FWH,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020946 .manufacture_id = WINBOND_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000020947 .model_id = WINBOND_W39V040FA,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020948 .total_size = 512,
Sean Nelson72a9a022009-12-22 22:15:33 +000020949 .page_size = 64 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +010020950 .feature_bits = FEATURE_EITHER_RESET,
Stefan Tauner23e10b82016-01-23 16:16:49 +000020951 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020952 .probe = probe_jedec,
Antony Rheneus0fbba982011-05-26 14:28:51 +000020953 .probe_timing = 10,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000020954 .block_erasers =
20955 {
20956 {
20957 .eraseblocks = { {4 * 1024, 128} },
20958 .block_erase = erase_block_jedec,
20959 }, {
20960 .eraseblocks = { {64 * 1024, 8} },
20961 .block_erase = erase_sector_jedec,
20962 }, {
20963 .eraseblocks = { {512 * 1024, 1} },
20964 .block_erase = erase_chip_block_jedec,
20965 }
20966 },
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000020967 .printlock = printlock_w39v040fa,
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000020968 .unlock = unlock_regspace2_uniform_64k,
Sean Nelson35727f72010-01-28 23:55:12 +000020969 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000020970 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000020971 .voltage = {3000, 3600},
Nico Huberb1974022023-01-12 13:13:12 +010020972 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010020973 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000020974 },
20975
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000020976 {
20977 .vendor = "Winbond",
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000020978 .name = "W39V040FB",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000020979 .bustype = BUS_FWH,
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000020980 .manufacture_id = WINBOND_ID,
20981 .model_id = WINBOND_W39V040B,
20982 .total_size = 512,
20983 .page_size = 64 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +010020984 .feature_bits = FEATURE_EITHER_RESET,
Stefan Tauner0be072c2016-03-13 15:16:30 +000020985 .tested = TEST_OK_PREW,
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000020986 .probe = probe_jedec,
Stefan Tauner0554ca52013-07-25 22:54:25 +000020987 .probe_timing = 10,
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000020988 .block_erasers =
20989 {
20990 {
20991 .eraseblocks = { {64 * 1024, 8} },
20992 .block_erase = erase_sector_jedec,
20993 }, {
20994 .eraseblocks = { {512 * 1024, 1} },
20995 .block_erase = erase_chip_block_jedec,
20996 }
20997 },
20998 .printlock = printlock_w39v040fb,
Carl-Daniel Hailfingeref3ac8a2014-08-03 13:05:34 +000020999 .unlock = unlock_regspace2_uniform_64k,
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000021000 .write = write_jedec_1,
21001 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +000021002 .voltage = {3000, 3600}, /* Also has 12V fast program */
Nico Huberb1974022023-01-12 13:13:12 +010021003 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010021004 .finish_access = finish_memory_access,
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000021005 },
21006
21007 {
21008 .vendor = "Winbond",
21009 .name = "W39V040FC",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021010 .bustype = BUS_FWH,
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000021011 .manufacture_id = WINBOND_ID,
21012 .model_id = WINBOND_W39V040C,
21013 .total_size = 512,
21014 .page_size = 64 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +010021015 .feature_bits = FEATURE_EITHER_RESET,
Stefan Tauneraf2db612011-12-02 21:48:17 +000021016 .tested = TEST_OK_PREW,
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000021017 .probe = probe_jedec,
21018 .probe_timing = 10,
21019 .block_erasers =
21020 {
21021 {
21022 .eraseblocks = { {64 * 1024, 8} },
21023 .block_erase = erase_sector_jedec,
21024 }, {
21025 .eraseblocks = { {512 * 1024, 1} },
21026 .block_erase = erase_chip_block_jedec,
21027 }
21028 },
21029 .printlock = printlock_w39v040fc,
21030 .write = write_jedec_1,
21031 .read = read_memmapped,
Steven Zakulec7d257b42011-07-19 08:50:18 +000021032 .voltage = {3000, 3600}, /* Also has 12V fast program */
Nico Huberb1974022023-01-12 13:13:12 +010021033 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010021034 .finish_access = finish_memory_access,
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000021035 },
21036
21037 {
21038 .vendor = "Winbond",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021039 .name = "W39V080A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021040 .bustype = BUS_LPC,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021041 .manufacture_id = WINBOND_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000021042 .model_id = WINBOND_W39V080A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021043 .total_size = 1024,
Sean Nelson72a9a022009-12-22 22:15:33 +000021044 .page_size = 64 * 1024,
Sean Nelson35727f72010-01-28 23:55:12 +000021045 .feature_bits = FEATURE_EITHER_RESET,
Paul Menzelac427b22012-02-16 21:07:07 +000021046 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021047 .probe = probe_jedec,
Paul Menzelac427b22012-02-16 21:07:07 +000021048 .probe_timing = 10,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000021049 .block_erasers =
21050 {
21051 {
21052 .eraseblocks = { {64 * 1024, 16} },
21053 .block_erase = erase_sector_jedec,
21054 }, {
21055 .eraseblocks = { {1024 * 1024, 1} },
21056 .block_erase = erase_chip_block_jedec,
21057 }
21058 },
Carl-Daniel Hailfinger91882402010-12-05 16:33:59 +000021059 .printlock = printlock_w39v080a,
Sean Nelson35727f72010-01-28 23:55:12 +000021060 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000021061 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000021062 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010021063 .prepare_access = prepare_memory_access,
21064 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000021065 },
21066
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021067 {
21068 .vendor = "Winbond",
Alan Green1f9cc7d2019-07-01 11:10:45 +100021069 .name = "W39V080FA",
21070 .bustype = BUS_FWH,
21071 .manufacture_id = WINBOND_ID,
21072 .model_id = WINBOND_W39V080FA,
21073 .total_size = 1024,
21074 .page_size = 64 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +010021075 .feature_bits = FEATURE_EITHER_RESET,
Alan Green1f9cc7d2019-07-01 11:10:45 +100021076 .tested = TEST_OK_PREW,
21077 .probe = probe_jedec,
21078 .probe_timing = 10,
21079 .block_erasers =
21080 {
21081 {
21082 .eraseblocks = { {64 * 1024, 16} },
21083 .block_erase = erase_sector_jedec,
21084 }, {
21085 .eraseblocks = { {1024 * 1024, 1} },
21086 .block_erase = erase_chip_block_jedec,
21087 }
21088 },
21089 .printlock = printlock_w39v080fa,
21090 .unlock = unlock_regspace2_uniform_64k,
21091 .write = write_jedec_1,
21092 .read = read_memmapped,
21093 .voltage = {3000, 3600}, /* Also has 12V fast program */
Nico Huberb1974022023-01-12 13:13:12 +010021094 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010021095 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100021096 },
21097
21098 {
21099 .vendor = "Winbond",
21100 .name = "W39V080FA (dual mode)",
21101 .bustype = BUS_FWH,
21102 .manufacture_id = WINBOND_ID,
21103 .model_id = WINBOND_W39V080FA_DM,
21104 .total_size = 512,
21105 .page_size = 64 * 1024,
Nico Huberb1974022023-01-12 13:13:12 +010021106 .feature_bits = FEATURE_EITHER_RESET,
Alan Green1f9cc7d2019-07-01 11:10:45 +100021107 .tested = TEST_UNTESTED,
21108 .probe = probe_jedec,
21109 .probe_timing = 10,
21110 .block_erasers =
21111 {
21112 {
21113 .eraseblocks = { {64 * 1024, 8} },
21114 .block_erase = erase_sector_jedec,
21115 }, {
21116 .eraseblocks = { {512 * 1024, 1} },
21117 .block_erase = erase_chip_block_jedec,
21118 }
21119 },
21120 .printlock = printlock_w39v080fa_dual,
21121 .write = write_jedec_1,
21122 .read = read_memmapped,
21123 .voltage = {3000, 3600}, /* Also has 12V fast program */
Nico Huberb1974022023-01-12 13:13:12 +010021124 .prepare_access = prepare_memory_register_access,
Nico Huber9eec4072023-01-12 01:17:30 +010021125 .finish_access = finish_memory_access,
Alan Green1f9cc7d2019-07-01 11:10:45 +100021126 },
21127
21128 {
21129 .vendor = "Winbond",
Mattias Mattssona745cf42010-09-14 23:56:56 +000021130 .name = "W49F002U/N",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021131 .bustype = BUS_PARALLEL,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021132 .manufacture_id = WINBOND_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000021133 .model_id = WINBOND_W49F002U,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021134 .total_size = 256,
21135 .page_size = 128,
Sean Nelson35727f72010-01-28 23:55:12 +000021136 .feature_bits = FEATURE_EITHER_RESET,
Stefan Tauner716e0982011-07-25 20:38:52 +000021137 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021138 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000021139 .probe_timing = 10,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000021140 .block_erasers =
21141 {
21142 {
21143 .eraseblocks = {
21144 {128 * 1024, 1},
21145 {96 * 1024, 1},
21146 {8 * 1024, 2},
21147 {16 * 1024, 1},
21148 },
21149 .block_erase = erase_sector_jedec,
21150 }, {
21151 .eraseblocks = { {256 * 1024, 1} },
21152 .block_erase = erase_chip_block_jedec,
21153 }
21154 },
Sean Nelson35727f72010-01-28 23:55:12 +000021155 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000021156 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000021157 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010021158 .prepare_access = prepare_memory_access,
21159 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000021160 },
21161
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021162 {
21163 .vendor = "Winbond",
Carl-Daniel Hailfingerabebe6b2010-07-17 13:45:42 +000021164 .name = "W49F020",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021165 .bustype = BUS_PARALLEL,
Carl-Daniel Hailfingerabebe6b2010-07-17 13:45:42 +000021166 .manufacture_id = WINBOND_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000021167 .model_id = WINBOND_W49F020,
Carl-Daniel Hailfingerabebe6b2010-07-17 13:45:42 +000021168 .total_size = 256,
21169 .page_size = 128,
21170 .feature_bits = FEATURE_EITHER_RESET,
21171 .tested = TEST_OK_PROBE,
21172 .probe = probe_jedec,
21173 .probe_timing = 10,
21174 .block_erasers =
21175 {
21176 {
21177 .eraseblocks = { {256 * 1024, 1} },
21178 .block_erase = erase_chip_block_jedec,
21179 }
21180 },
21181 .write = write_jedec_1,
21182 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000021183 .voltage = {4500, 5500},
Nico Huber9eec4072023-01-12 01:17:30 +010021184 .prepare_access = prepare_memory_access,
21185 .finish_access = finish_memory_access,
Carl-Daniel Hailfingerabebe6b2010-07-17 13:45:42 +000021186 },
21187
21188 {
21189 .vendor = "Winbond",
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021190 .name = "W49V002A",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021191 .bustype = BUS_LPC,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021192 .manufacture_id = WINBOND_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000021193 .model_id = WINBOND_W49V002A,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021194 .total_size = 256,
21195 .page_size = 128,
Sean Nelson35727f72010-01-28 23:55:12 +000021196 .feature_bits = FEATURE_EITHER_RESET,
Cristian Măgherușan-Stanciu9932c7b2011-07-07 19:56:58 +000021197 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021198 .probe = probe_jedec,
Cristian Măgherușan-Stanciu9932c7b2011-07-07 19:56:58 +000021199 .probe_timing = 10,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000021200 .block_erasers =
21201 {
21202 {
21203 .eraseblocks = {
21204 {64 * 1024, 3},
21205 {32 * 1024, 1},
21206 {8 * 1024, 2},
21207 {16 * 1024, 1},
21208 },
21209 .block_erase = erase_sector_jedec,
21210 }, {
21211 .eraseblocks = { {256 * 1024, 1} },
21212 .block_erase = erase_chip_block_jedec,
21213 }
21214 },
Sean Nelson35727f72010-01-28 23:55:12 +000021215 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000021216 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000021217 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010021218 .prepare_access = prepare_memory_access,
21219 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000021220 },
21221
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021222 {
21223 .vendor = "Winbond",
21224 .name = "W49V002FA",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021225 .bustype = BUS_FWH,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021226 .manufacture_id = WINBOND_ID,
Mattias Mattssona745cf42010-09-14 23:56:56 +000021227 .model_id = WINBOND_W49V002FA,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021228 .total_size = 256,
21229 .page_size = 128,
Sean Nelson35727f72010-01-28 23:55:12 +000021230 .feature_bits = FEATURE_EITHER_RESET,
Stefan Taunereb582572012-09-21 12:52:50 +000021231 .tested = TEST_OK_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021232 .probe = probe_jedec,
Udu Ogahc04ee222009-09-05 01:31:32 +000021233 .probe_timing = 10,
Sean Nelsoncfc35cd2010-01-19 03:24:55 +000021234 .block_erasers =
21235 {
21236 {
21237 .eraseblocks = {
21238 {64 * 1024, 3},
21239 {32 * 1024, 1},
21240 {8 * 1024, 2},
21241 {16 * 1024, 1},
21242 },
21243 .block_erase = erase_sector_jedec,
21244 }, {
21245 .eraseblocks = { {256 * 1024, 1} },
21246 .block_erase = erase_chip_block_jedec,
21247 }
21248 },
Sean Nelson35727f72010-01-28 23:55:12 +000021249 .write = write_jedec_1,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000021250 .read = read_memmapped,
Steven Zakuleccbe370e2011-06-03 07:26:31 +000021251 .voltage = {3000, 3600},
Nico Huber9eec4072023-01-12 01:17:30 +010021252 .prepare_access = prepare_memory_access,
21253 .finish_access = finish_memory_access,
FENG yu ningff692fb2008-12-08 18:15:10 +000021254 },
21255
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021256 {
luke heef884232020-12-28 18:22:21 +080021257 .vendor = "XMC",
21258 .name = "XM25QH128C",
21259 .bustype = BUS_SPI,
21260 .manufacture_id = ST_ID,
21261 .model_id = XMC_XM25QH128C,
21262 .total_size = 16384,
21263 .page_size = 256,
Nico Huber1412d9f2024-01-06 18:25:49 +010021264 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP | FEATURE_QPI_SRP,
21265 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
luke heef884232020-12-28 18:22:21 +080021266 .tested = TEST_UNTESTED,
21267 .probe = probe_spi_rdid,
21268 .probe_timing = TIMING_ZERO,
21269 .block_erasers =
21270 {
21271 {
21272 .eraseblocks = { {4 * 1024, 4096} },
21273 .block_erase = spi_block_erase_20,
21274 }, {
21275 .eraseblocks = { {32 * 1024, 512} },
21276 .block_erase = spi_block_erase_52,
21277 }, {
21278 .eraseblocks = { {64 * 1024, 256} },
21279 .block_erase = spi_block_erase_d8,
21280 }, {
21281 .eraseblocks = { {16 * 1024 * 1024, 1} },
21282 .block_erase = spi_block_erase_60,
21283 }, {
21284 .eraseblocks = { {16 * 1024 * 1024, 1} },
21285 .block_erase = spi_block_erase_c7,
21286 }
21287 },
21288 .printlock = spi_prettyprint_status_register_plain,
21289 .unlock = spi_disable_blockprotect,
21290 .write = spi_chip_write_256,
21291 .read = spi_chip_read,
21292 .voltage = {2700, 3600},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110021293 .reg_bits =
21294 {
Nico Huber96786d02024-01-06 18:30:15 +010021295 .qe = {STATUS2, 1, RW},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110021296 .srp = {STATUS1, 7, RW},
21297 .srl = {STATUS2, 0, RW},
21298 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}},
21299 .tb = {STATUS1, 5, RW},
21300 .sec = {STATUS1, 6, RW},
21301 .cmp = {STATUS2, 6, RW},
21302 },
Nico Huberaabb3e02023-01-13 00:22:30 +010021303 .wp_write_cfg = spi_wp_write_cfg,
21304 .wp_read_cfg = spi_wp_read_cfg,
21305 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110021306 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020021307 .prepare_access = spi_prepare_io,
21308 .finish_access = spi_finish_io,
luke heef884232020-12-28 18:22:21 +080021309 },
21310
21311 {
21312 .vendor = "XMC",
21313 .name = "XM25QH256C",
21314 .bustype = BUS_SPI,
21315 .manufacture_id = ST_ID,
21316 .model_id = XMC_XM25QH256C,
21317 .total_size = 32768,
21318 .page_size = 256,
21319 /* supports SFDP */
Nico Huber96786d02024-01-06 18:30:15 +010021320 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP |
21321 FEATURE_4BA_WREN | FEATURE_QPI_SRP,
21322 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
luke heef884232020-12-28 18:22:21 +080021323 .tested = TEST_UNTESTED,
21324 .probe = probe_spi_rdid,
21325 .probe_timing = TIMING_ZERO,
21326 .block_erasers =
21327 {
21328 {
21329 .eraseblocks = { {4 * 1024, 8192} },
21330 .block_erase = spi_block_erase_21,
21331 }, {
21332 .eraseblocks = { {4 * 1024, 8192} },
21333 .block_erase = spi_block_erase_20,
21334 }, {
21335 .eraseblocks = { {32 * 1024, 1024} },
21336 .block_erase = spi_block_erase_52,
21337 }, {
21338 .eraseblocks = { {64 * 1024, 512} },
21339 .block_erase = spi_block_erase_dc,
21340 }, {
21341 .eraseblocks = { {64 * 1024, 512} },
21342 .block_erase = spi_block_erase_d8,
21343 }, {
21344 .eraseblocks = { {32 * 1024 * 1024, 1} },
21345 .block_erase = spi_block_erase_60,
21346 }, {
21347 .eraseblocks = { {32 * 1024 * 1024, 1} },
21348 .block_erase = spi_block_erase_c7,
21349 }
21350 },
21351 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
21352 .unlock = spi_disable_blockprotect,
21353 .write = spi_chip_write_256,
21354 .read = spi_chip_read,
21355 .voltage = {2700, 3600},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110021356 .reg_bits =
21357 {
Nico Huber96786d02024-01-06 18:30:15 +010021358 .qe = {STATUS2, 1, RW},
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110021359 .srp = {STATUS1, 7, RW},
21360 .srl = {STATUS2, 0, RW},
21361 .bp = {{STATUS1, 2, RW}, {STATUS1, 3, RW}, {STATUS1, 4, RW}, {STATUS1, 5, RW}},
21362 .tb = {STATUS1, 6, RW},
21363 },
Nico Huberaabb3e02023-01-13 00:22:30 +010021364 .wp_write_cfg = spi_wp_write_cfg,
21365 .wp_read_cfg = spi_wp_read_cfg,
21366 .wp_get_ranges = spi_wp_get_available_ranges,
Nikolai Artemievd32e18b2022-02-15 18:06:55 +110021367 .decode_range = decode_range_spi25,
Nico Huber930d4212024-05-04 18:59:15 +020021368 .prepare_access = spi_prepare_io,
21369 .finish_access = spi_finish_io,
luke heef884232020-12-28 18:22:21 +080021370 },
21371
21372 {
21373 .vendor = "XMC",
21374 .name = "XM25QH64C",
21375 .bustype = BUS_SPI,
21376 .manufacture_id = ST_ID,
21377 .model_id = XMC_XM25QH64C,
21378 .total_size = 8192,
21379 .page_size = 256,
Nico Huber96786d02024-01-06 18:30:15 +010021380 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP | FEATURE_QPI_SRP,
Nico Huber1412d9f2024-01-06 18:25:49 +010021381 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
luke heef884232020-12-28 18:22:21 +080021382 .tested = TEST_UNTESTED,
21383 .probe = probe_spi_rdid,
21384 .probe_timing = TIMING_ZERO,
21385 .block_erasers =
21386 {
21387 {
21388 .eraseblocks = { {4 * 1024, 2048} },
21389 .block_erase = spi_block_erase_20,
21390 }, {
21391 .eraseblocks = { {32 * 1024, 256} },
21392 .block_erase = spi_block_erase_52,
21393 }, {
21394 .eraseblocks = { {64 * 1024, 128} },
21395 .block_erase = spi_block_erase_d8,
21396 }, {
21397 .eraseblocks = { {8 * 1024 * 1024, 1} },
21398 .block_erase = spi_block_erase_60,
21399 }, {
21400 .eraseblocks = { {8 * 1024 * 1024, 1} },
21401 .block_erase = spi_block_erase_c7,
21402 }
21403 },
Nico Huber96786d02024-01-06 18:30:15 +010021404 .reg_bits =
21405 {
21406 .qe = {STATUS2, 1, RW},
21407 },
luke heef884232020-12-28 18:22:21 +080021408 .printlock = spi_prettyprint_status_register_plain,
21409 .unlock = spi_disable_blockprotect,
21410 .write = spi_chip_write_256,
21411 .read = spi_chip_read,
21412 .voltage = {2700, 3600},
Nico Huber930d4212024-05-04 18:59:15 +020021413 .prepare_access = spi_prepare_io,
21414 .finish_access = spi_finish_io,
luke heef884232020-12-28 18:22:21 +080021415 },
21416
21417 {
21418 .vendor = "XMC",
21419 .name = "XM25QU128C",
21420 .bustype = BUS_SPI,
21421 .manufacture_id = ST_ID,
21422 .model_id = XMC_XM25QU128C,
21423 .total_size = 16384,
21424 .page_size = 256,
21425 /* supports SFDP */
Nico Huber96786d02024-01-06 18:30:15 +010021426 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP | FEATURE_QPI_SRP,
Nico Huber1412d9f2024-01-06 18:25:49 +010021427 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
luke heef884232020-12-28 18:22:21 +080021428 .tested = TEST_UNTESTED,
21429 .probe = probe_spi_rdid,
21430 .probe_timing = TIMING_ZERO,
21431 .block_erasers =
21432 {
21433 {
21434 .eraseblocks = { {4 * 1024, 4096} },
21435 .block_erase = spi_block_erase_20,
21436 }, {
21437 .eraseblocks = { {32 * 1024, 512} },
21438 .block_erase = spi_block_erase_52,
21439 }, {
21440 .eraseblocks = { {64 * 1024, 256} },
21441 .block_erase = spi_block_erase_d8,
21442 }, {
21443 .eraseblocks = { {16 * 1024 * 1024, 1} },
21444 .block_erase = spi_block_erase_60,
21445 }, {
21446 .eraseblocks = { {16 * 1024 * 1024, 1} },
21447 .block_erase = spi_block_erase_c7,
21448 }
21449 },
Nico Huber96786d02024-01-06 18:30:15 +010021450 .reg_bits =
21451 {
21452 .qe = {STATUS2, 1, RW},
21453 },
luke heef884232020-12-28 18:22:21 +080021454 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
21455 .unlock = spi_disable_blockprotect,
21456 .write = spi_chip_write_256,
21457 .read = spi_chip_read,
21458 .voltage = {1650, 1950},
Nico Huber930d4212024-05-04 18:59:15 +020021459 .prepare_access = spi_prepare_io,
21460 .finish_access = spi_finish_io,
luke heef884232020-12-28 18:22:21 +080021461 },
21462
21463 {
21464 .vendor = "XMC",
21465 .name = "XM25QU256C",
21466 .bustype = BUS_SPI,
21467 .manufacture_id = ST_ID,
21468 .model_id = XMC_XM25QU256C,
21469 .total_size = 32768,
21470 .page_size = 256,
21471 /* supports SFDP */
Nico Huber96786d02024-01-06 18:30:15 +010021472 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP |
21473 FEATURE_4BA_WREN | FEATURE_QPI_SRP,
21474 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
luke heef884232020-12-28 18:22:21 +080021475 .tested = TEST_UNTESTED,
21476 .probe = probe_spi_rdid,
21477 .probe_timing = TIMING_ZERO,
21478 .block_erasers =
21479 {
21480 {
21481 .eraseblocks = { {4 * 1024, 8192} },
21482 .block_erase = spi_block_erase_21,
21483 }, {
21484 .eraseblocks = { {4 * 1024, 8192} },
21485 .block_erase = spi_block_erase_20,
21486 }, {
21487 .eraseblocks = { {32 * 1024, 1024} },
21488 .block_erase = spi_block_erase_52,
21489 }, {
21490 .eraseblocks = { {64 * 1024, 512} },
21491 .block_erase = spi_block_erase_dc,
21492 }, {
21493 .eraseblocks = { {64 * 1024, 512} },
21494 .block_erase = spi_block_erase_d8,
21495 }, {
21496 .eraseblocks = { {32 * 1024 * 1024, 1} },
21497 .block_erase = spi_block_erase_60,
21498 }, {
21499 .eraseblocks = { {32 * 1024 * 1024, 1} },
21500 .block_erase = spi_block_erase_c7,
21501 }
21502 },
Nico Huber96786d02024-01-06 18:30:15 +010021503 .reg_bits =
21504 {
21505 .qe = {STATUS2, 1, RW},
21506 },
luke heef884232020-12-28 18:22:21 +080021507 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
21508 .unlock = spi_disable_blockprotect,
21509 .write = spi_chip_write_256,
21510 .read = spi_chip_read,
21511 .voltage = {1650, 1950},
Nico Huber930d4212024-05-04 18:59:15 +020021512 .prepare_access = spi_prepare_io,
21513 .finish_access = spi_finish_io,
luke heef884232020-12-28 18:22:21 +080021514 },
21515
21516 {
21517 .vendor = "XMC",
21518 .name = "XM25QU64C",
21519 .bustype = BUS_SPI,
21520 .manufacture_id = ST_ID,
21521 .model_id = XMC_XM25QU64C,
21522 .total_size = 8192,
21523 .page_size = 256,
Nico Huber96786d02024-01-06 18:30:15 +010021524 .feature_bits = FEATURE_WRSR_WREN | FEATURE_WRSR2 | FEATURE_OTP | FEATURE_QPI_SRP,
Nico Huber1412d9f2024-01-06 18:25:49 +010021525 .dummy_cycles = { .qpi_read_params = { 2, 4, 6, 8 } },
luke heef884232020-12-28 18:22:21 +080021526 .tested = TEST_UNTESTED,
21527 .probe = probe_spi_rdid,
21528 .probe_timing = TIMING_ZERO,
21529 .block_erasers =
21530 {
21531 {
21532 .eraseblocks = { {4 * 1024, 2048} },
21533 .block_erase = spi_block_erase_20,
21534 }, {
21535 .eraseblocks = { {32 * 1024, 256} },
21536 .block_erase = spi_block_erase_52,
21537 }, {
21538 .eraseblocks = { {64 * 1024, 128} },
21539 .block_erase = spi_block_erase_d8,
21540 }, {
21541 .eraseblocks = { {8 * 1024 * 1024, 1} },
21542 .block_erase = spi_block_erase_60,
21543 }, {
21544 .eraseblocks = { {8 * 1024 * 1024, 1} },
21545 .block_erase = spi_block_erase_c7,
21546 }
21547 },
Nico Huber96786d02024-01-06 18:30:15 +010021548 .reg_bits =
21549 {
21550 .qe = {STATUS2, 1, RW},
21551 },
luke heef884232020-12-28 18:22:21 +080021552 .printlock = spi_prettyprint_status_register_plain,
21553 .unlock = spi_disable_blockprotect,
21554 .write = spi_chip_write_256,
21555 .read = spi_chip_read,
21556 .voltage = {1650, 1950},
Nico Huber930d4212024-05-04 18:59:15 +020021557 .prepare_access = spi_prepare_io,
21558 .finish_access = spi_finish_io,
luke heef884232020-12-28 18:22:21 +080021559 },
21560
21561 {
Alan Greenfa3fcd32019-06-27 15:41:50 +100021562 .vendor = "Zetta Device",
21563 .name = "ZD25D20",
21564 .bustype = BUS_SPI,
21565 .manufacture_id = ZETTADEVICE_ID,
21566 .model_id = ZETTADEVICE_ZD25D20,
21567 .total_size = 256,
21568 .page_size = 256,
21569 .feature_bits = FEATURE_WRSR_WREN,
21570 .tested = TEST_UNTESTED,
21571 .probe = probe_spi_rdid,
21572 .probe_timing = TIMING_ZERO,
21573 .block_erasers =
David Hendricksa72d5a92018-02-11 17:58:44 -080021574 {
21575 {
21576 .eraseblocks = { {4 * 1024, 64} },
21577 .block_erase = spi_block_erase_20,
21578 }, {
21579 .eraseblocks = { {32 * 1024, 8} },
21580 .block_erase = spi_block_erase_52,
21581 }, {
21582 .eraseblocks = { {64 * 1024, 4} },
21583 .block_erase = spi_block_erase_d8,
21584 }, {
21585 .eraseblocks = { {256 * 1024, 1} },
21586 .block_erase = spi_block_erase_60,
21587 }, {
21588 .eraseblocks = { {256 * 1024, 1} },
21589 .block_erase = spi_block_erase_c7,
21590 }
21591 },
Alan Greenfa3fcd32019-06-27 15:41:50 +100021592 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
21593 .unlock = spi_disable_blockprotect,
21594 .write = spi_chip_write_256,
21595 .read = spi_chip_read,
21596 .voltage = {2700, 3600},
David Hendricksa72d5a92018-02-11 17:58:44 -080021597 },
21598
21599 {
Alan Greenfa3fcd32019-06-27 15:41:50 +100021600 .vendor = "Zetta Device",
21601 .name = "ZD25D40",
21602 .bustype = BUS_SPI,
21603 .manufacture_id = ZETTADEVICE_ID,
21604 .model_id = ZETTADEVICE_ZD25D40,
21605 .total_size = 512,
21606 .page_size = 256,
21607 .feature_bits = FEATURE_WRSR_WREN,
21608 .tested = TEST_UNTESTED,
21609 .probe = probe_spi_rdid,
21610 .probe_timing = TIMING_ZERO,
21611 .block_erasers =
nybashcbb46e22018-02-11 17:53:49 -080021612 {
21613 {
21614 .eraseblocks = { {4 * 1024, 128} },
21615 .block_erase = spi_block_erase_20,
21616 }, {
21617 .eraseblocks = { {32 * 1024, 16} },
21618 .block_erase = spi_block_erase_52,
21619 }, {
21620 .eraseblocks = { {64 * 1024, 8} },
21621 .block_erase = spi_block_erase_d8,
21622 }, {
21623 .eraseblocks = { {512 * 1024, 1} },
21624 .block_erase = spi_block_erase_60,
21625 }, {
21626 .eraseblocks = { {512 * 1024, 1} },
21627 .block_erase = spi_block_erase_c7,
21628 }
21629 },
Alan Greenfa3fcd32019-06-27 15:41:50 +100021630 .printlock = spi_prettyprint_status_register_plain, /* TODO: improve */
21631 .unlock = spi_disable_blockprotect,
21632 .write = spi_chip_write_256,
21633 .read = spi_chip_read,
21634 .voltage = {2700, 3600},
nybashcbb46e22018-02-11 17:53:49 -080021635 },
21636
Stefan Taunerac1b4c82012-02-17 14:51:04 +000021637 {
Alan Greendd592202019-08-23 10:11:37 +100021638 .vendor = "Unknown",
21639 .name = "SFDP-capable chip",
21640 .bustype = BUS_SPI,
21641 .manufacture_id = GENERIC_MANUF_ID,
21642 .model_id = SFDP_DEVICE_ID,
21643 .total_size = 0, /* set by probing function */
21644 .page_size = 0, /* set by probing function */
21645 .feature_bits = 0, /* set by probing function */
21646 /* We present our own "report this" text hence we do not */
21647 /* want the default "This flash part has status UNTESTED..." */
21648 /* text to be printed. */
21649 .tested = TEST_OK_PREW,
21650 .probe = probe_spi_sfdp,
21651 .block_erasers = {}, /* set by probing function */
21652 .unlock = spi_disable_blockprotect, /* is this safe? */
21653 .write = NULL, /* set by probing function */
21654 .read = spi_chip_read,
21655 /* FIXME: some vendor extensions define this */
21656 .voltage = {0},
21657 },
21658
21659 {
Carl-Daniel Hailfinger532c7172011-11-04 21:35:26 +000021660 .vendor = "Programmer",
21661 .name = "Opaque flash chip",
21662 .bustype = BUS_PROG,
21663 .manufacture_id = PROGMANUF_ID,
21664 .model_id = PROGDEV_ID,
21665 .total_size = 0,
21666 .page_size = 256,
21667 /* probe is assumed to work, rest will be filled in by probe */
21668 .tested = TEST_OK_PROBE,
21669 .probe = probe_opaque,
21670 /* eraseblock sizes will be set by the probing function */
21671 .block_erasers =
21672 {
21673 {
21674 .block_erase = erase_opaque,
21675 }
21676 },
21677 .write = write_opaque,
21678 .read = read_opaque,
21679 },
21680
21681 {
Daniel Lenskidf90d3a2010-07-22 11:44:38 +000021682 .vendor = "AMIC",
21683 .name = "unknown AMIC SPI chip",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021684 .bustype = BUS_SPI,
Daniel Lenskidf90d3a2010-07-22 11:44:38 +000021685 .manufacture_id = AMIC_ID,
21686 .model_id = GENERIC_DEVICE_ID,
21687 .total_size = 0,
21688 .page_size = 256,
21689 .tested = TEST_BAD_PREW,
21690 .probe = probe_spi_rdid4,
21691 .probe_timing = TIMING_ZERO,
21692 .write = NULL,
21693 .read = NULL,
21694 },
21695
21696 {
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021697 .vendor = "Atmel",
21698 .name = "unknown Atmel SPI chip",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021699 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021700 .manufacture_id = ATMEL_ID,
21701 .model_id = GENERIC_DEVICE_ID,
21702 .total_size = 0,
21703 .page_size = 256,
Carl-Daniel Hailfinger42882fd2009-04-22 13:33:43 +000021704 .tested = TEST_BAD_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021705 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000021706 .probe_timing = TIMING_ZERO,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021707 .write = NULL,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000021708 .read = NULL,
FENG yu ningff692fb2008-12-08 18:15:10 +000021709 },
21710
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021711 {
Carl-Daniel Hailfingerf792c7d2010-07-28 22:20:20 +000021712 .vendor = "Eon",
21713 .name = "unknown Eon SPI chip",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021714 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021715 .manufacture_id = EON_ID_NOPREFIX,
21716 .model_id = GENERIC_DEVICE_ID,
21717 .total_size = 0,
21718 .page_size = 256,
Carl-Daniel Hailfinger42882fd2009-04-22 13:33:43 +000021719 .tested = TEST_BAD_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021720 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000021721 .probe_timing = TIMING_ZERO,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021722 .write = NULL,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000021723 .read = NULL,
FENG yu ningff692fb2008-12-08 18:15:10 +000021724 },
21725
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021726 {
21727 .vendor = "Macronix",
21728 .name = "unknown Macronix SPI chip",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021729 .bustype = BUS_SPI,
Mattias Mattsson6eabe282010-09-15 23:31:03 +000021730 .manufacture_id = MACRONIX_ID,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021731 .model_id = GENERIC_DEVICE_ID,
21732 .total_size = 0,
21733 .page_size = 256,
Carl-Daniel Hailfinger42882fd2009-04-22 13:33:43 +000021734 .tested = TEST_BAD_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021735 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000021736 .probe_timing = TIMING_ZERO,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021737 .write = NULL,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000021738 .read = NULL,
FENG yu ningff692fb2008-12-08 18:15:10 +000021739 },
21740
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021741 {
21742 .vendor = "PMC",
21743 .name = "unknown PMC SPI chip",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021744 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021745 .manufacture_id = PMC_ID,
21746 .model_id = GENERIC_DEVICE_ID,
21747 .total_size = 0,
21748 .page_size = 256,
Carl-Daniel Hailfinger42882fd2009-04-22 13:33:43 +000021749 .tested = TEST_BAD_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021750 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000021751 .probe_timing = TIMING_ZERO,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021752 .write = NULL,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000021753 .read = NULL,
FENG yu ningff692fb2008-12-08 18:15:10 +000021754 },
21755
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021756 {
21757 .vendor = "SST",
21758 .name = "unknown SST SPI chip",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021759 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021760 .manufacture_id = SST_ID,
21761 .model_id = GENERIC_DEVICE_ID,
21762 .total_size = 0,
21763 .page_size = 256,
Carl-Daniel Hailfinger42882fd2009-04-22 13:33:43 +000021764 .tested = TEST_BAD_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021765 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000021766 .probe_timing = TIMING_ZERO,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021767 .write = NULL,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000021768 .read = NULL,
FENG yu ningff692fb2008-12-08 18:15:10 +000021769 },
21770
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021771 {
21772 .vendor = "ST",
21773 .name = "unknown ST SPI chip",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021774 .bustype = BUS_SPI,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021775 .manufacture_id = ST_ID,
21776 .model_id = GENERIC_DEVICE_ID,
21777 .total_size = 0,
21778 .page_size = 256,
Carl-Daniel Hailfinger42882fd2009-04-22 13:33:43 +000021779 .tested = TEST_BAD_PREW,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021780 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger2bc020b2009-06-05 13:46:17 +000021781 .probe_timing = TIMING_ZERO,
Stephan Guilloux5c5b5252009-01-08 03:40:17 +000021782 .write = NULL,
Carl-Daniel Hailfinger03b4e712009-05-08 12:49:03 +000021783 .read = NULL,
FENG yu ningff692fb2008-12-08 18:15:10 +000021784 },
Uwe Hermannfc425e82008-03-16 02:06:25 +000021785
Carl-Daniel Hailfinger01d49ed2009-11-20 01:12:45 +000021786 {
Sean Nelson118e1d62009-11-24 02:08:11 +000021787 .vendor = "Sanyo",
21788 .name = "unknown Sanyo SPI chip",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021789 .bustype = BUS_SPI,
Sean Nelson118e1d62009-11-24 02:08:11 +000021790 .manufacture_id = SANYO_ID,
21791 .model_id = GENERIC_DEVICE_ID,
21792 .total_size = 0,
21793 .page_size = 256,
21794 .tested = TEST_BAD_PREW,
21795 .probe = probe_spi_rdid,
21796 .probe_timing = TIMING_ZERO,
Sean Nelson118e1d62009-11-24 02:08:11 +000021797 .write = NULL,
21798 .read = NULL,
21799 },
21800
21801 {
Stefan Taunereb582572012-09-21 12:52:50 +000021802 .vendor = "Winbond",
21803 .name = "unknown Winbond (ex Nexcom) SPI chip",
21804 .bustype = BUS_SPI,
21805 .manufacture_id = WINBOND_NEX_ID,
21806 .model_id = GENERIC_DEVICE_ID,
21807 .total_size = 0,
21808 .page_size = 256,
21809 .tested = TEST_BAD_PREW,
21810 .probe = probe_spi_rdid,
21811 .probe_timing = TIMING_ZERO,
21812 .write = NULL,
21813 .read = NULL,
21814 },
21815
21816 {
Carl-Daniel Hailfinger01d49ed2009-11-20 01:12:45 +000021817 .vendor = "Generic",
21818 .name = "unknown SPI chip (RDID)",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021819 .bustype = BUS_SPI,
Carl-Daniel Hailfinger01d49ed2009-11-20 01:12:45 +000021820 .manufacture_id = GENERIC_MANUF_ID,
21821 .model_id = GENERIC_DEVICE_ID,
21822 .total_size = 0,
21823 .page_size = 256,
21824 .tested = TEST_BAD_PREW,
21825 .probe = probe_spi_rdid,
Carl-Daniel Hailfinger01d49ed2009-11-20 01:12:45 +000021826 .write = NULL,
21827 },
Stefan Tauneraf2db612011-12-02 21:48:17 +000021828
Carl-Daniel Hailfinger01d49ed2009-11-20 01:12:45 +000021829 {
21830 .vendor = "Generic",
21831 .name = "unknown SPI chip (REMS)",
Carl-Daniel Hailfinger1a227952011-07-27 07:13:06 +000021832 .bustype = BUS_SPI,
Carl-Daniel Hailfinger01d49ed2009-11-20 01:12:45 +000021833 .manufacture_id = GENERIC_MANUF_ID,
21834 .model_id = GENERIC_DEVICE_ID,
21835 .total_size = 0,
21836 .page_size = 256,
21837 .tested = TEST_BAD_PREW,
21838 .probe = probe_spi_rems,
Carl-Daniel Hailfinger01d49ed2009-11-20 01:12:45 +000021839 .write = NULL,
21840 },
21841
Stefan Tauner96658be2014-05-26 22:05:31 +000021842 {0}
Stephan Guilloux72cf5652009-04-21 01:46:07 +000021843};
Stefan Tauner96658be2014-05-26 22:05:31 +000021844
21845const unsigned int flashchips_size = ARRAY_SIZE(flashchips);