[PATCH v3] mtd: spi-nor: add dt support for Everspin MRAMs

Subsystems: memory technology devices (mtd), open firmware and flattened device tree bindings, the rest

STALE3557d

4 messages, 3 authors, 2017-01-20 · open the first message on its own page

[PATCH v3] mtd: spi-nor: add dt support for Everspin MRAMs

From: Uwe Kleine-König <hidden>
Date: 2017-01-17 11:03:38

The MR25 family doesn't support JEDEC, so they need explicit mentioning
in the list of supported spi IDs. This makes it possible to add these
using for example:

	compatible = "everspin,mr25h40";

There was already an entry for mr25h256. Move that one out of the "keep
for compatibility" section and put in a new group for Everspin MRAMs.

Signed-off-by: Uwe Kleine-König <redacted>
---
Changes since (implicit) v1:

 - use Kib instead of kib

Changes since v2:

 - update dt docs
 - handle already existing mr25h256 in m25p_ids[]

Thanks to Cyrille for catching these.

 Documentation/devicetree/bindings/mtd/jedec,spi-nor.txt | 2 ++
 drivers/mtd/devices/m25p80.c                            | 6 +++++-
 2 files changed, 7 insertions(+), 1 deletion(-)
diff --git a/Documentation/devicetree/bindings/mtd/jedec,spi-nor.txt b/Documentation/devicetree/bindings/mtd/jedec,spi-nor.txt
index 2c91c03e7eb0..3e920ec5c4d3 100644
--- a/Documentation/devicetree/bindings/mtd/jedec,spi-nor.txt
+++ b/Documentation/devicetree/bindings/mtd/jedec,spi-nor.txt
@@ -14,6 +14,8 @@ Required properties:
                  at25df641
                  at26df081a
                  mr25h256
+                 mr25h10
+                 mr25h40
                  mx25l4005a
                  mx25l1606e
                  mx25l6405d
diff --git a/drivers/mtd/devices/m25p80.c b/drivers/mtd/devices/m25p80.c
index 9cf7fcd28034..0e2d3a64651a 100644
--- a/drivers/mtd/devices/m25p80.c
+++ b/drivers/mtd/devices/m25p80.c
@@ -288,7 +288,6 @@ static const struct spi_device_id m25p_ids[] = {
 	 * should be kept for backward compatibility.
 	 */
 	{"at25df321a"},	{"at25df641"},	{"at26df081a"},
-	{"mr25h256"},
 	{"mx25l4005a"},	{"mx25l1606e"},	{"mx25l6405d"},	{"mx25l12805d"},
 	{"mx25l25635e"},{"mx66l51235l"},
 	{"n25q064"},	{"n25q128a11"},	{"n25q128a13"},	{"n25q512a"},
@@ -305,6 +304,11 @@ static const struct spi_device_id m25p_ids[] = {
 	{"m25p40-nonjedec"},	{"m25p80-nonjedec"},	{"m25p16-nonjedec"},
 	{"m25p32-nonjedec"},	{"m25p64-nonjedec"},	{"m25p128-nonjedec"},
 
+	/* Everspin MRAMs (non-JEDEC) */
+	{ "mr25h256" }, /* 256 Kib, 40 MHz */
+	{ "mr25h10" },  /*   1 Mib, 40 MHz */
+	{ "mr25h40" },  /*   4 Mib, 40 MHz */
+
 	{ },
 };
 MODULE_DEVICE_TABLE(spi, m25p_ids);
-- 
2.11.0

--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Re: [PATCH v3] mtd: spi-nor: add dt support for Everspin MRAMs

From: Cyrille Pitchen <hidden>
Date: 2017-01-17 13:04:29

Le 17/01/2017 à 12:03, Uwe Kleine-König a écrit :
The MR25 family doesn't support JEDEC, so they need explicit mentioning
in the list of supported spi IDs. This makes it possible to add these
using for example:

	compatible = "everspin,mr25h40";

There was already an entry for mr25h256. Move that one out of the "keep
for compatibility" section and put in a new group for Everspin MRAMs.

Signed-off-by: Uwe Kleine-König <redacted>
Acked-by: Cyrille Pitchen <redacted>

By the way, you've forgotten to collect Marek's ack from v1 but no need to
resend for that. I wait a little bit more for some DT guy ack if they want
but otherwise I think this patch is ready to be merged into the spi-nor tree.

Thanks !
quoted hunk
---
Changes since (implicit) v1:

 - use Kib instead of kib

Changes since v2:

 - update dt docs
 - handle already existing mr25h256 in m25p_ids[]

Thanks to Cyrille for catching these.

 Documentation/devicetree/bindings/mtd/jedec,spi-nor.txt | 2 ++
 drivers/mtd/devices/m25p80.c                            | 6 +++++-
 2 files changed, 7 insertions(+), 1 deletion(-)
diff --git a/Documentation/devicetree/bindings/mtd/jedec,spi-nor.txt b/Documentation/devicetree/bindings/mtd/jedec,spi-nor.txt
index 2c91c03e7eb0..3e920ec5c4d3 100644
--- a/Documentation/devicetree/bindings/mtd/jedec,spi-nor.txt
+++ b/Documentation/devicetree/bindings/mtd/jedec,spi-nor.txt
@@ -14,6 +14,8 @@ Required properties:
                  at25df641
                  at26df081a
                  mr25h256
+                 mr25h10
+                 mr25h40
                  mx25l4005a
                  mx25l1606e
                  mx25l6405d
diff --git a/drivers/mtd/devices/m25p80.c b/drivers/mtd/devices/m25p80.c
index 9cf7fcd28034..0e2d3a64651a 100644
--- a/drivers/mtd/devices/m25p80.c
+++ b/drivers/mtd/devices/m25p80.c
@@ -288,7 +288,6 @@ static const struct spi_device_id m25p_ids[] = {
 	 * should be kept for backward compatibility.
 	 */
 	{"at25df321a"},	{"at25df641"},	{"at26df081a"},
-	{"mr25h256"},
 	{"mx25l4005a"},	{"mx25l1606e"},	{"mx25l6405d"},	{"mx25l12805d"},
 	{"mx25l25635e"},{"mx66l51235l"},
 	{"n25q064"},	{"n25q128a11"},	{"n25q128a13"},	{"n25q512a"},
@@ -305,6 +304,11 @@ static const struct spi_device_id m25p_ids[] = {
 	{"m25p40-nonjedec"},	{"m25p80-nonjedec"},	{"m25p16-nonjedec"},
 	{"m25p32-nonjedec"},	{"m25p64-nonjedec"},	{"m25p128-nonjedec"},
 
+	/* Everspin MRAMs (non-JEDEC) */
+	{ "mr25h256" }, /* 256 Kib, 40 MHz */
+	{ "mr25h10" },  /*   1 Mib, 40 MHz */
+	{ "mr25h40" },  /*   4 Mib, 40 MHz */
+
 	{ },
 };
 MODULE_DEVICE_TABLE(spi, m25p_ids);

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

Re: [PATCH v3] mtd: spi-nor: add dt support for Everspin MRAMs

From: Rob Herring <robh@kernel.org>
Date: 2017-01-19 17:56:08

On Tue, Jan 17, 2017 at 12:03:38PM +0100, Uwe Kleine-König wrote:
The MR25 family doesn't support JEDEC, so they need explicit mentioning
in the list of supported spi IDs. This makes it possible to add these
using for example:

	compatible = "everspin,mr25h40";

There was already an entry for mr25h256. Move that one out of the "keep
for compatibility" section and put in a new group for Everspin MRAMs.

Signed-off-by: Uwe Kleine-König <redacted>
---
Changes since (implicit) v1:

 - use Kib instead of kib

Changes since v2:

 - update dt docs
 - handle already existing mr25h256 in m25p_ids[]

Thanks to Cyrille for catching these.

 Documentation/devicetree/bindings/mtd/jedec,spi-nor.txt | 2 ++
 drivers/mtd/devices/m25p80.c                            | 6 +++++-
 2 files changed, 7 insertions(+), 1 deletion(-)
Acked-by: Rob Herring <robh@kernel.org>

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

Re: [PATCH v3] mtd: spi-nor: add dt support for Everspin MRAMs

From: Cyrille Pitchen <hidden>
Date: 2017-01-20 12:57:41

Le 19/01/2017 à 18:56, Rob Herring a écrit :
On Tue, Jan 17, 2017 at 12:03:38PM +0100, Uwe Kleine-König wrote:
quoted
The MR25 family doesn't support JEDEC, so they need explicit mentioning
in the list of supported spi IDs. This makes it possible to add these
using for example:

	compatible = "everspin,mr25h40";

There was already an entry for mr25h256. Move that one out of the "keep
for compatibility" section and put in a new group for Everspin MRAMs.

Signed-off-by: Uwe Kleine-König <redacted>
---
Changes since (implicit) v1:

 - use Kib instead of kib

Changes since v2:

 - update dt docs
 - handle already existing mr25h256 in m25p_ids[]

Thanks to Cyrille for catching these.

 Documentation/devicetree/bindings/mtd/jedec,spi-nor.txt | 2 ++
 drivers/mtd/devices/m25p80.c                            | 6 +++++-
 2 files changed, 7 insertions(+), 1 deletion(-)
Acked-by: Rob Herring <robh@kernel.org>
Applied to git://github.com/spi-nor/linux.git

Thanks!


______________________________________________________
Linux MTD discussion mailing list
http://lists.infradead.org/mailman/listinfo/linux-mtd/
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help