Skip to contentSkip to conversation

mtd: spi-nor: Correct spi-nor-ids.c license to GPL-2.0

PATCH New Alper Nebi Yasak 2 participants 3 messages Oct 31, 2020 – Feb 26, 2021 Memory technology devices (MTD)

lore
Share & tools
lore
#0 lore raw

PATCH 1/2 mtd: spi-nor: Correct spi-nor-ids.c license to GPL-2.0

The contents of this file were introduced in commit 7aeedac01534 ("mtd:
spi: Port SPI NOR framework from Linux") to spi-nor-core.c under GPL-2.0; then moved with some modifications into a new spi-nor-ids.c file in commit 778572d7cb1e ("mtd: spi: Add lightweight SPI flash stack for SPL") which marked the then-new file incorrectly as GPL-2.0+.

This corrects the file's license header to GPL-2.0, which is also necessary to sync further changes from Linux.

---

 drivers/mtd/spi/spi-nor-ids.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/mtd/spi/spi-nor-ids.c +1 -1
index bc9d4f7e9f86..4de60b0165fd 100644
@@ -1,4 +1,4 @@
-// SPDX-License-Identifier: GPL-2.0+
+// SPDX-License-Identifier: GPL-2.0
 /*
  *
  * Copyright (C) 2013 Jagannadha Sutradharudu Teki, Xilinx Inc.
Signature · 1 line
2.29.1
#1 lore raw

PATCH 2/2 mtd: spi-nor-ids: Add Gigadevice GD25LQ64C

Add GD25LQ24C 64Mbit chip to spi-nor id table. This chip is used on rk3399-gru-kevin:

    => sf probe
    SF: Detected gd25lq64c with page size 256 Bytes, erase size 4 KiB, total 8 MiB
    => sf erase 0x600000 0x200000
    SF: 2097152 bytes @ 0x600000 Erased: OK
    => sf test 0x700000 0x1000
    SPI flash test:
    0 erase: 52 ticks, 76 KiB/s 0.608 Mbps
    1 check: 5 ticks, 800 KiB/s 6.400 Mbps
    2 write: 14 ticks, 285 KiB/s 2.280 Mbps
    3 read: 3 ticks, 1333 KiB/s 10.664 Mbps
    Test passed
    0 erase: 52 ticks, 76 KiB/s 0.608 Mbps
    1 check: 5 ticks, 800 KiB/s 6.400 Mbps
    2 write: 14 ticks, 285 KiB/s 2.280 Mbps
    3 read: 3 ticks, 1333 KiB/s 10.664 Mbps

The values are the same as in Linux, except adjusted for the U-Boot definition of INFO().

---
This is from Linux's drivers/mtd/spi-nor/gigadevice.c which is GPL-2.0, but the U-Boot file is marked as GPL-2.0+ (which is AFAICT incorrect, see the previous patch).

 drivers/mtd/spi/spi-nor-ids.c | 5 +++++
 1 file changed, 5 insertions(+)
drivers/mtd/spi/spi-nor-ids.c +5 -0
index 4de60b0165fd..cc3a54eaf563 100644
@@ -107,6 +107,11 @@ const struct flash_info spi_nor_ids[] = {
 			SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
 			SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB)
 	},
+	{
+		INFO("gd25lq64c", 0xc86017, 0, 64 * 1024, 128,
+			SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
+			SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB)
+	},
 	{
 		INFO("gd25q128", 0xc84018, 0, 64 * 1024, 256,
 			SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
Signature · 1 line
2.29.1
#2 lore raw

PATCH 2/2 mtd: spi-nor-ids: Add Gigadevice GD25LQ64C

Quoted 20 lines · Alper Nebi Yasak

Add GD25LQ24C 64Mbit chip to spi-nor id table. This chip is used on rk3399-gru-kevin:

    => sf probe
    SF: Detected gd25lq64c with page size 256 Bytes, erase size 4 KiB, total 8 MiB
    => sf erase 0x600000 0x200000
    SF: 2097152 bytes @ 0x600000 Erased: OK
    => sf test 0x700000 0x1000
    SPI flash test:
    0 erase: 52 ticks, 76 KiB/s 0.608 Mbps
    1 check: 5 ticks, 800 KiB/s 6.400 Mbps
    2 write: 14 ticks, 285 KiB/s 2.280 Mbps
    3 read: 3 ticks, 1333 KiB/s 10.664 Mbps
    Test passed
    0 erase: 52 ticks, 76 KiB/s 0.608 Mbps
    1 check: 5 ticks, 800 KiB/s 6.400 Mbps
    2 write: 14 ticks, 285 KiB/s 2.280 Mbps
    3 read: 3 ticks, 1333 KiB/s 10.664 Mbps
Quoted 5 lines

The values are the same as in Linux, except adjusted for the U-Boot definition of INFO().

---

Applied to u-boot-spi/master