Skip to contentSkip to conversation

mtd: spi-nor: gigadevice: add GD25LQ80C

PATCH In review Stijn Tintel 2 participants 4 messages Sep 21, 2020 – Sep 25, 2020

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 mtd: spi-nor: gigadevice: add GD25LQ80C

Tested on a TP-Link OC200.

Datasheet: https://www.gigadevice.com/datasheet/gd25lq80c/

---
 drivers/mtd/spi-nor/gigadevice.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/mtd/spi-nor/gigadevice.c +3 -0
index 447d84bb2128..840fa9f90a67 100644
@@ -24,6 +24,9 @@ static struct spi_nor_fixups gd25q256_fixups = {
 };
 
 static const struct flash_info gigadevice_parts[] = {
+	{ "gd25lq80c", INFO(0xc86014, 0, 64 * 1024, 16,
+			   SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
+			   SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB) },
 	{ "gd25q16", INFO(0xc84015, 0, 64 * 1024,  32,
 			  SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
 			  SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB) },
Signature · 6 lines
2.26.2


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
#1 lore raw

Hi,

Quoted 2 lines · Stijn Tintel

Tested on a TP-Link OC200.

But what was tested? Dual and quad mode tested (as you enable those flags)? And lock/unlock as well?

Could you add this info to commit message?

Quoted 13 lines

Datasheet: https://www.gigadevice.com/datasheet/gd25lq80c/

---
 drivers/mtd/spi-nor/gigadevice.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/mtd/spi-nor/gigadevice.c +0 -0
index 447d84bb2128..840fa9f90a67 100644

drivers/mtd/spi-nor/gigadevice.c static struct spi_nor_fixups gd25q256_fixups = { · line 32

Quoted 9 lines
drivers/mtd/spi-nor/gigadevice.c +3 -0
@@ -24,6 +24,9 @@ static struct spi_nor_fixups gd25q256_fixups = {
 };
 
 static const struct flash_info gigadevice_parts[] = {
+	{ "gd25lq80c", INFO(0xc86014, 0, 64 * 1024, 16,
+			   SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
+			   SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB) },
 	{ "gd25q16", INFO(0xc84015, 0, 64 * 1024,  32,
 			  SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
 			  SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB) },

Regards
Vignesh

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

#2 lore raw
Quoted 9 lines · Vignesh Raghavendra

Hi,

Quoted 2 lines · Stijn Tintel

Tested on a TP-Link OC200.

But what was tested? Dual and quad mode tested (as you enable those flags)? And lock/unlock as well?

Could you add this info to commit message?

I tested read and write with dd, verified the written image afterwards. I enabled those flags based on what's in the datasheet. If this is not enough, please advise an acceptable way to test those flags.

Quoted 15 lines
Quoted 15 lines

Datasheet: https://www.gigadevice.com/datasheet/gd25lq80c/

---
 drivers/mtd/spi-nor/gigadevice.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/mtd/spi-nor/gigadevice.c +0 -0
index 447d84bb2128..840fa9f90a67 100644
@@ -24,6 +24,9 @@ static struct spi_nor_fixups gd25q256_fixups = {
 };
 
Quoted 10 lines

drivers/mtd/spi-nor/gigadevice.c static struct spi_nor_fixups gd25q256_fixups = { · line 32

Quoted 8 lines
drivers/mtd/spi-nor/gigadevice.c +3 -0
 static const struct flash_info gigadevice_parts[] = {
+	{ "gd25lq80c", INFO(0xc86014, 0, 64 * 1024, 16,
+			   SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
+			   SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB) },
 	{ "gd25q16", INFO(0xc84015, 0, 64 * 1024,  32,
 			  SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
 			  SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB) },

Regards
Vignesh

Thanks,
Stijn

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/

#3 lore raw
Quoted 6 lines · Stijn Tintel
Quoted 5 lines · Vignesh Raghavendra

Hi,

Quoted 2 lines · Stijn Tintel

Tested on a TP-Link OC200.

Quoted 8 lines
Quoted 4 lines

But what was tested? Dual and quad mode tested (as you enable those flags)? And lock/unlock as well?

Could you add this info to commit message?

I tested read and write with dd, verified the written image afterwards. I enabled those flags based on what's in the datasheet. If this is not enough, please advise an acceptable way to test those flags.

Quoted 1 line

We want to make sure that entries being added are actually tested on a real HW especially wrt quad mode. Can you confirm quad mode is being used to reading image from the flash?
(you could put prints in spi_nor_read() file and see the opcode being used for read and compare with Datasheet to know the mode).

If you are unable to test quad/dual mode due to limitations then please do not add the flag just based on datasheet.

Regards
Vignesh

Quoted 25 lines
Quoted 14 lines
Quoted 14 lines

Datasheet: https://www.gigadevice.com/datasheet/gd25lq80c/

---
 drivers/mtd/spi-nor/gigadevice.c | 3 +++
 1 file changed, 3 insertions(+)
drivers/mtd/spi-nor/gigadevice.c +0 -0
index 447d84bb2128..840fa9f90a67 100644
@@ -24,6 +24,9 @@ static struct spi_nor_fixups gd25q256_fixups = {
 };
 
Quoted 10 lines

drivers/mtd/spi-nor/gigadevice.c static struct spi_nor_fixups gd25q256_fixups = { · line 32

Quoted 8 lines
drivers/mtd/spi-nor/gigadevice.c +3 -0
 static const struct flash_info gigadevice_parts[] = {
+	{ "gd25lq80c", INFO(0xc86014, 0, 64 * 1024, 16,
+			   SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
+			   SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB) },
 	{ "gd25q16", INFO(0xc84015, 0, 64 * 1024,  32,
 			  SECT_4K | SPI_NOR_DUAL_READ | SPI_NOR_QUAD_READ |
 			  SPI_NOR_HAS_LOCK | SPI_NOR_HAS_TB) },

Regards
Vignesh

Quoted 3 lines

Thanks,
Stijn

______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/