linux-mtd.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mtd: m25p80: Disable 4K erase for s25sl032p, s25sl064p
@ 2012-09-04  3:31 Marek Vasut
  2012-09-17 14:09 ` Marek Vasut
  2012-09-21 13:12 ` Artem Bityutskiy
  0 siblings, 2 replies; 4+ messages in thread
From: Marek Vasut @ 2012-09-04  3:31 UTC (permalink / raw)
  To: linux-mtd; +Cc: Marek Vasut, Artem Bityutskiy, David Woodhouse

Quoting from the datasheet for S25FL064P, rev. 05, Nov 18 2011,
section 9.17:

A 64 kB sector erase (D8h) command issued on 4 kB or 8 kB erase
sectors will erase all sectors in the specified 64 kB region.
However, please note that a 4 kB sector erase (20h) or 8 kB
sector erase (40h) command will not work on a 64 kB sector.

Refering further to Table 8.1 and Table 8.2, it is clearly seen
that most of the sectors are 64kB, therefore disable this 4K
erase support since it's valid only on first/last sectors.

Signed-off-by: Marek Vasut <marex@denx.de>
Cc: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Cc: David Woodhouse <david.woodhouse@intel.com>
---
 drivers/mtd/devices/m25p80.c |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/mtd/devices/m25p80.c b/drivers/mtd/devices/m25p80.c
index c433051..9930e23 100644
--- a/drivers/mtd/devices/m25p80.c
+++ b/drivers/mtd/devices/m25p80.c
@@ -661,8 +661,8 @@ static const struct spi_device_id m25p_ids[] = {
 	/* Spansion -- single (large) sector size only, at least
 	 * for the chips listed here (without boot sectors).
 	 */
-	{ "s25sl032p",  INFO(0x010215, 0x4d00,  64 * 1024,  64, SECT_4K) },
-	{ "s25sl064p",  INFO(0x010216, 0x4d00,  64 * 1024, 128, SECT_4K) },
+	{ "s25sl032p",  INFO(0x010215, 0x4d00,  64 * 1024,  64, 0) },
+	{ "s25sl064p",  INFO(0x010216, 0x4d00,  64 * 1024, 128, 0) },
 	{ "s25fl256s0", INFO(0x010219, 0x4d00, 256 * 1024, 128, 0) },
 	{ "s25fl256s1", INFO(0x010219, 0x4d01,  64 * 1024, 512, 0) },
 	{ "s25fl512s",  INFO(0x010220, 0x4d00, 256 * 1024, 256, 0) },
-- 
1.7.10.4

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] mtd: m25p80: Disable 4K erase for s25sl032p, s25sl064p
  2012-09-04  3:31 [PATCH] mtd: m25p80: Disable 4K erase for s25sl032p, s25sl064p Marek Vasut
@ 2012-09-17 14:09 ` Marek Vasut
  2012-09-21 13:12 ` Artem Bityutskiy
  1 sibling, 0 replies; 4+ messages in thread
From: Marek Vasut @ 2012-09-17 14:09 UTC (permalink / raw)
  To: linux-mtd; +Cc: Artem Bityutskiy, David Woodhouse

Bump, do you think this can be queued for 3.7 please?

> Quoting from the datasheet for S25FL064P, rev. 05, Nov 18 2011,
> section 9.17:
> 
> A 64 kB sector erase (D8h) command issued on 4 kB or 8 kB erase
> sectors will erase all sectors in the specified 64 kB region.
> However, please note that a 4 kB sector erase (20h) or 8 kB
> sector erase (40h) command will not work on a 64 kB sector.
> 
> Refering further to Table 8.1 and Table 8.2, it is clearly seen
> that most of the sectors are 64kB, therefore disable this 4K
> erase support since it's valid only on first/last sectors.
> 
> Signed-off-by: Marek Vasut <marex@denx.de>
> Cc: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
> Cc: David Woodhouse <david.woodhouse@intel.com>
> ---
>  drivers/mtd/devices/m25p80.c |    4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/drivers/mtd/devices/m25p80.c b/drivers/mtd/devices/m25p80.c
> index c433051..9930e23 100644
> --- a/drivers/mtd/devices/m25p80.c
> +++ b/drivers/mtd/devices/m25p80.c
> @@ -661,8 +661,8 @@ static const struct spi_device_id m25p_ids[] = {
>  	/* Spansion -- single (large) sector size only, at least
>  	 * for the chips listed here (without boot sectors).
>  	 */
> -	{ "s25sl032p",  INFO(0x010215, 0x4d00,  64 * 1024,  64, SECT_4K) },
> -	{ "s25sl064p",  INFO(0x010216, 0x4d00,  64 * 1024, 128, SECT_4K) },
> +	{ "s25sl032p",  INFO(0x010215, 0x4d00,  64 * 1024,  64, 0) },
> +	{ "s25sl064p",  INFO(0x010216, 0x4d00,  64 * 1024, 128, 0) },
>  	{ "s25fl256s0", INFO(0x010219, 0x4d00, 256 * 1024, 128, 0) },
>  	{ "s25fl256s1", INFO(0x010219, 0x4d01,  64 * 1024, 512, 0) },
>  	{ "s25fl512s",  INFO(0x010220, 0x4d00, 256 * 1024, 256, 0) },

Best regards,
Marek Vasut

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] mtd: m25p80: Disable 4K erase for s25sl032p, s25sl064p
  2012-09-04  3:31 [PATCH] mtd: m25p80: Disable 4K erase for s25sl032p, s25sl064p Marek Vasut
  2012-09-17 14:09 ` Marek Vasut
@ 2012-09-21 13:12 ` Artem Bityutskiy
  2012-09-21 13:39   ` Marek Vasut
  1 sibling, 1 reply; 4+ messages in thread
From: Artem Bityutskiy @ 2012-09-21 13:12 UTC (permalink / raw)
  To: Marek Vasut; +Cc: linux-mtd, David Woodhouse

[-- Attachment #1: Type: text/plain, Size: 671 bytes --]

On Tue, 2012-09-04 at 05:31 +0200, Marek Vasut wrote:
> Quoting from the datasheet for S25FL064P, rev. 05, Nov 18 2011,
> section 9.17:
> 
> A 64 kB sector erase (D8h) command issued on 4 kB or 8 kB erase
> sectors will erase all sectors in the specified 64 kB region.
> However, please note that a 4 kB sector erase (20h) or 8 kB
> sector erase (40h) command will not work on a 64 kB sector.
> 
> Refering further to Table 8.1 and Table 8.2, it is clearly seen
> that most of the sectors are 64kB, therefore disable this 4K
> erase support since it's valid only on first/last sectors.

Pushed to l2-mtd.git, thanks!

-- 
Best Regards,
Artem Bityutskiy

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 836 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] mtd: m25p80: Disable 4K erase for s25sl032p, s25sl064p
  2012-09-21 13:12 ` Artem Bityutskiy
@ 2012-09-21 13:39   ` Marek Vasut
  0 siblings, 0 replies; 4+ messages in thread
From: Marek Vasut @ 2012-09-21 13:39 UTC (permalink / raw)
  To: artem.bityutskiy; +Cc: linux-mtd, David Woodhouse

Dear Artem Bityutskiy,

> On Tue, 2012-09-04 at 05:31 +0200, Marek Vasut wrote:
> > Quoting from the datasheet for S25FL064P, rev. 05, Nov 18 2011,
> > section 9.17:
> > 
> > A 64 kB sector erase (D8h) command issued on 4 kB or 8 kB erase
> > sectors will erase all sectors in the specified 64 kB region.
> > However, please note that a 4 kB sector erase (20h) or 8 kB
> > sector erase (40h) command will not work on a 64 kB sector.
> > 
> > Refering further to Table 8.1 and Table 8.2, it is clearly seen
> > that most of the sectors are 64kB, therefore disable this 4K
> > erase support since it's valid only on first/last sectors.
> 
> Pushed to l2-mtd.git, thanks!

Thank you!

Best regards,
Marek Vasut

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-09-21 13:39 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-09-04  3:31 [PATCH] mtd: m25p80: Disable 4K erase for s25sl032p, s25sl064p Marek Vasut
2012-09-17 14:09 ` Marek Vasut
2012-09-21 13:12 ` Artem Bityutskiy
2012-09-21 13:39   ` Marek Vasut

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).