ipdbg: fix double free of virtual-ir data
[openocd.git] / src / flash / nor / spi.c
index ace274f3dd768c95c41966e920e28b8a1a63726d..bf654f9f6b3a1dc7696f98776254a0337d1a0f13 100644 (file)
  /* Shared table of known SPI flash devices for SPI-based flash drivers. Taken
   * from device datasheets and Linux SPI flash drivers. */
 const struct flash_device flash_devices[] = {
-       /* name, read_cmd, qread_cmd, pprog_cmd, erase_cmd, chip_erase_cmd, device_id,
-        * pagesize, sectorsize, size_in_bytes
-        * note: device id is usually 3 bytes long, however the unused highest byte counts
-        * continuation codes for manufacturer id as per JEP106xx */
+       /* Note: device_id is usually 3 bytes long, however the unused highest byte counts
+        * continuation codes for manufacturer id as per JEP106xx.
+        *
+        * All sizes (page, sector/block and flash) are in bytes.
+        *
+        * Guide to select a proper erase command (if both sector and block erase cmds are available):
+        * Use 4kbit sector erase cmd and set erase size to the size of sector for small devices
+        * (4Mbit and less, size <= 0x80000) to prevent too raw erase granularity.
+        * Use 64kbit block erase cmd and set erase size to the size of block for bigger devices
+        * (8Mbit and more, size >= 0x100000) to keep erase speed reasonable.
+        * If the device implements also 32kbit block erase, use it for 8Mbit, size == 0x100000.
+        */
+       /*        name                  read qread  page  erase chip  device_id   page   erase   flash
+        *                              _cmd _cmd   _prog _cmd* _erase            size   size*   size
+        *                                          _cmd        _cmd
+        */
        FLASH_ID("st m25pe10",          0x03, 0x00, 0x02, 0xd8, 0x00, 0x00118020, 0x100, 0x10000, 0x20000),
        FLASH_ID("st m25pe20",          0x03, 0x00, 0x02, 0xd8, 0x00, 0x00128020, 0x100, 0x10000, 0x40000),
        FLASH_ID("st m25pe40",          0x03, 0x00, 0x02, 0xd8, 0x00, 0x00138020, 0x100, 0x10000, 0x80000),
@@ -174,6 +186,11 @@ const struct flash_device flash_devices[] = {
        FLASH_ID("zetta zd25q16",       0x03, 0x00, 0x02, 0xd8, 0xc7, 0x001560ba, 0x100, 0x10000, 0x200000),
 
        /* FRAM, no erase commands, no write page or sectors */
+
+       /*        name                  read qread  page  device_id   total
+        *                              _cmd _cmd   _prog             size
+        *                                          _cmd
+        */
        FRAM_ID("fu mb85rs16n",         0x03, 0,    0x02, 0x00010104, 0x800),
        FRAM_ID("fu mb85rs32v",         0x03, 0,    0x02, 0x00010204, 0x1000), /* exists ? */
        FRAM_ID("fu mb85rs64v",         0x03, 0,    0x02, 0x00020304, 0x2000),

Linking to existing account procedure

If you already have an account and want to add another login method you MUST first sign in with your existing account and then change URL to read https://review.openocd.org/login/?link to get to this page again but this time it'll work for linking. Thank you.

SSH host keys fingerprints

1024 SHA256:YKx8b7u5ZWdcbp7/4AeXNaqElP49m6QrwfXaqQGJAOk gerrit-code-review@openocd.zylin.com (DSA)
384 SHA256:jHIbSQa4REvwCFG4cq5LBlBLxmxSqelQPem/EXIrxjk gerrit-code-review@openocd.org (ECDSA)
521 SHA256:UAOPYkU9Fjtcao0Ul/Rrlnj/OsQvt+pgdYSZ4jOYdgs gerrit-code-review@openocd.org (ECDSA)
256 SHA256:A13M5QlnozFOvTllybRZH6vm7iSt0XLxbA48yfc2yfY gerrit-code-review@openocd.org (ECDSA)
256 SHA256:spYMBqEYoAOtK7yZBrcwE8ZpYt6b68Cfh9yEVetvbXg gerrit-code-review@openocd.org (ED25519)
+--[ED25519 256]--+
|=..              |
|+o..   .         |
|*.o   . .        |
|+B . . .         |
|Bo. = o S        |
|Oo.+ + =         |
|oB=.* = . o      |
| =+=.+   + E     |
|. .=o   . o      |
+----[SHA256]-----+
2048 SHA256:0Onrb7/PHjpo6iVZ7xQX2riKN83FJ3KGU0TvI0TaFG4 gerrit-code-review@openocd.zylin.com (RSA)