aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/devicetree/bindings
diff options
context:
space:
mode:
authorBrian Norris <computersforpeace@gmail.com>2015-03-27 13:29:49 -0400
committerBrian Norris <computersforpeace@gmail.com>2015-04-05 21:56:21 -0400
commit8ff16cf77ce314c20d7bd57c788f5b7719b450e1 (patch)
treeaf87664493601e40ac34d7f594dc3db6c7b1b3e0 /Documentation/devicetree/bindings
parent2a6a28e7922c07c116ba8f2aa3682c03ef8be678 (diff)
Documentation: devicetree: m25p80: add "nor-jedec" binding
Almost all flash that are "compatible" with m25p80 support the JEDEC READ ID opcode (0x9F), and in fact, that is often the only thing that is used to differentiate them. Let's add a compatible string that represents this lowest common denominator of compatibility. Device trees can still specify manufacturer/device names in addition, but (until some reason is found to differentiate between them through device tree) software will likely want to bind just against the generic name, and avoid unnecessarily growing its device ID binding tables. This is related to the work of commit a5b7616c55e1 ("mtd: m25p80,spi-nor: Fix module aliases for m25p80"), which showed that maintaining these device tables as stable device-tree/modalias binding tables is not a worthwhile burden for mostly-comptatible flash. At the same time, let's update the binding doc to point to the m25p_ids[] ID list instead of spi_nor_ids[]. The former can be used for device tree bindings, but the latter cannot. In the future, we should pare down the m25p_ids[] list to only those IDs which are actually used in device trees. Signed-off-by: Brian Norris <computersforpeace@gmail.com> Cc: Rafał Miłecki <zajec5@gmail.com> Reviewed-by: Marek Vasut <marex@denx.de>
Diffstat (limited to 'Documentation/devicetree/bindings')
-rw-r--r--Documentation/devicetree/bindings/mtd/m25p80.txt13
1 files changed, 8 insertions, 5 deletions
diff --git a/Documentation/devicetree/bindings/mtd/m25p80.txt b/Documentation/devicetree/bindings/mtd/m25p80.txt
index 4611aa83531b..f20b111b502a 100644
--- a/Documentation/devicetree/bindings/mtd/m25p80.txt
+++ b/Documentation/devicetree/bindings/mtd/m25p80.txt
@@ -3,10 +3,13 @@
3Required properties: 3Required properties:
4- #address-cells, #size-cells : Must be present if the device has sub-nodes 4- #address-cells, #size-cells : Must be present if the device has sub-nodes
5 representing partitions. 5 representing partitions.
6- compatible : Should be the manufacturer and the name of the chip. Bear in mind 6- compatible : May include a device-specific string consisting of the
7 the DT binding is not Linux-only, but in case of Linux, see the 7 manufacturer and name of the chip. Bear in mind the DT binding
8 "spi_nor_ids" table in drivers/mtd/spi-nor/spi-nor.c for the list 8 is not Linux-only, but in case of Linux, see the "m25p_ids"
9 of supported chips. 9 table in drivers/mtd/devices/m25p80.c for the list of supported
10 chips.
11 Must also include "nor-jedec" for any SPI NOR flash that can be
12 identified by the JEDEC READ ID opcode (0x9F).
10- reg : Chip-Select number 13- reg : Chip-Select number
11- spi-max-frequency : Maximum frequency of the SPI bus the chip can operate at 14- spi-max-frequency : Maximum frequency of the SPI bus the chip can operate at
12 15
@@ -22,7 +25,7 @@ Example:
22 flash: m25p80@0 { 25 flash: m25p80@0 {
23 #address-cells = <1>; 26 #address-cells = <1>;
24 #size-cells = <1>; 27 #size-cells = <1>;
25 compatible = "spansion,m25p80"; 28 compatible = "spansion,m25p80", "nor-jedec";
26 reg = <0>; 29 reg = <0>;
27 spi-max-frequency = <40000000>; 30 spi-max-frequency = <40000000>;
28 m25p,fast-read; 31 m25p,fast-read;