Patchwork support for MX251635E

login
register
about
Submitter David Borg
Date 2010-09-13 15:03:56
Message ID <AANLkTik6Kg0A+mh=9QnKCxexU6J4E-537Hos83xuJo1d@mail.gmail.com>
Download mbox | patch
Permalink /patch/1924/
State Accepted
Commit 1162
Headers show

Comments

David Borg - 2010-09-13 15:03:56
Updated against revision 1159.

David

On 9 September 2010 21:39, Stephan GUILLOUX <stephan.guilloux@free.fr> wrote:
>
>
>  Hello,
>
> Below, a patch to allow MX25L1635E support, as discussed with Carldani.
> It is also available in attachment.
>
> This one is working fine on our system, with flashrom 0.9.2
>
> Sorry for the patch, but I do not have svn anymore.
> I had to use a standard diff -c.
>
> Make good use of it;-)
>
>  Stephan.
>
> Signed-off-by: Stephan Guilloux<stephan.guilloux@free.fr>
> --- ./flashrom-0.9.2.org/flashchips.h   2010-04-20 21:34:31.000000000 +0200
> +++ ./flashrom-0.9.2.new/flashchips.h   2010-09-03 09:37:39.386013000 +0200
> @@ -284,7 +284,8 @@
>  #define MX_25L6405             0x2017  /* MX25L3205{,D} */
>  #define MX_25L12805            0x2018  /* MX25L12805 */
>  #define MX_25L1635D            0x2415
> +#define MX_25L1635E            0x2515  /* MX25L1635{E} */
>  #define MX_25L3235D            0x5E16  /* MX25L3225D/MX25L3235D/MX25L3237D
> */
>  #define MX_29F001B             0x19
>  #define MX_29F001T             0x18
> --- ./flashrom-0.9.2.org/flashchips.c   2010-04-20 21:34:31.000000000 +0200
> +++ ./flashrom-0.9.2.new/flashchips.c   2010-09-03 09:38:44.637466000 +0200
> @@ -2775,6 +2775,37 @@
>
>        {
>                .vendor         = "Macronix",
> +               .name           = "MX25L1635E",
> +               .bustype        = CHIP_BUSTYPE_SPI,
> +               .manufacture_id = MX_ID,
> +               .model_id       = MX_25L1635E,
> +               .total_size     = 2048,
> +               .page_size      = 256,
> +               .tested         = TEST_UNTESTED,
> +               .probe          = probe_spi_rdid,
> +               .probe_timing   = TIMING_ZERO,
> +               .block_erasers  =
> +               {
> +                       {
> +                               .eraseblocks = { {4 * 1024, 512} },
> +                               .block_erase = spi_block_erase_20,
> +                       }, {
> +                               .eraseblocks = { {64 * 1024, 32} },
> +                               .block_erase = spi_block_erase_d8,
> +                       }, {
> +                               .eraseblocks = { {2 * 1024 * 1024, 1} },
> +                               .block_erase = spi_block_erase_60,
> +                       }, {
> +                               .eraseblocks = { {2 * 1024 * 1024, 1} },
> +                               .block_erase = spi_block_erase_c7,
> +                       }
> +               },
> +               .write          = spi_chip_write_256,
> +               .read           = spi_chip_read,
> +       },
> +
> +       {
> +               .vendor         = "Macronix",
>                .name           = "MX25L3205",
>                .bustype        = CHIP_BUSTYPE_SPI,
>                .manufacture_id = MX_ID,
>
>
>
> _______________________________________________
> flashrom mailing list
> flashrom@flashrom.org
> http://www.flashrom.org/mailman/listinfo/flashrom
>
Paul Menzel - 2010-09-13 18:31:48
Am Montag, den 13.09.2010, 17:03 +0200 schrieb David Borg:
> Updated against revision 1159.

Both times a Signed-off-by line is missing [1] as far as I can see.

[…]


Thanks,

Paul


[1] http://flashrom.org/Development_Guidelines
Uwe Hermann - 2010-09-13 20:12:07
On Mon, Sep 13, 2010 at 08:31:48PM +0200, Paul Menzel wrote:
> Am Montag, den 13.09.2010, 17:03 +0200 schrieb David Borg:
> > Updated against revision 1159.

Thanks for the patch and for updating it.

Committed in r1162 with two changes: I added the following lines as per
datasheet:

+               .feature_bits   = FEATURE_WRSR_WREN,
+               .unlock         = spi_disable_blockprotect,

Please let us know if the current svn version works for you
on hardware, if possible send "./flashrom -V -w foo.bin" output, thanks.
We can then mark the chip as tested.

 
> Both times a Signed-off-by line is missing [1] as far as I can see.

The original patch has a Signed-off-by, it's just a bit hidden.


Uwe.

Patch

Index: flashchips.c
===================================================================
--- flashchips.c	(revision 1159)
+++ flashchips.c	(working copy)
@@ -3623,6 +3623,37 @@ 
 
 	{
 		.vendor		= "Macronix",
+		.name		= "MX25L1635E",
+		.bustype	= CHIP_BUSTYPE_SPI,
+		.manufacture_id	= MX_ID,
+		.model_id	= MX_25L1635E,
+		.total_size	= 2048,
+		.page_size	= 256,
+		.tested		= TEST_UNTESTED,
+		.probe		= probe_spi_rdid,
+		.probe_timing	= TIMING_ZERO,
+		.block_erasers	=
+		{
+			{
+				.eraseblocks = { {4 * 1024, 512} },
+				.block_erase = spi_block_erase_20,
+			}, {
+				.eraseblocks = { {64 * 1024, 32} },
+				.block_erase = spi_block_erase_d8,
+			}, {
+				.eraseblocks = { {2 * 1024 * 1024, 1} },
+				.block_erase = spi_block_erase_60,
+			}, {
+				.eraseblocks = { {2 * 1024 * 1024, 1} },
+				.block_erase = spi_block_erase_c7,
+			}
+		},
+		.write		= spi_chip_write_256,
+		.read		= spi_chip_read,
+	},
+
+	{
+		.vendor		= "Macronix",
 		.name		= "MX25L3205",
 		.bustype	= CHIP_BUSTYPE_SPI,
 		.manufacture_id	= MX_ID,
Index: flashchips.h
===================================================================
--- flashchips.h	(revision 1159)
+++ flashchips.h	(working copy)
@@ -316,6 +316,7 @@ 
 #define MX_25L6405		0x2017	/* MX25L3205{,D} */
 #define MX_25L12805		0x2018	/* MX25L12805 */
 #define MX_25L1635D		0x2415
+#define MX_25L1635E		0x2515	/* MX25L1635{E} */
 #define MX_25L3235D		0x5E16	/* MX25L3225D/MX25L3235D/MX25L3237D */
 #define MX_29F001B		0x19
 #define MX_29F001T		0x18