1*ce9c0b06SMiquel Raynal# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
2*ce9c0b06SMiquel Raynal%YAML 1.2
3*ce9c0b06SMiquel Raynal---
4*ce9c0b06SMiquel Raynal$id: http://devicetree.org/schemas/nvmem/layouts/onie,tlv-layout.yaml#
5*ce9c0b06SMiquel Raynal$schema: http://devicetree.org/meta-schemas/core.yaml#
6*ce9c0b06SMiquel Raynal
7*ce9c0b06SMiquel Raynaltitle: NVMEM layout of the ONIE tlv table
8*ce9c0b06SMiquel Raynal
9*ce9c0b06SMiquel Raynalmaintainers:
10*ce9c0b06SMiquel Raynal  - Miquel Raynal <miquel.raynal@bootlin.com>
11*ce9c0b06SMiquel Raynal
12*ce9c0b06SMiquel Raynaldescription:
13*ce9c0b06SMiquel Raynal  Modern networking hardware implementing the Open Compute Project ONIE
14*ce9c0b06SMiquel Raynal  infrastructure shall provide a non-volatile memory with a table whose the
15*ce9c0b06SMiquel Raynal  content is well specified and gives many information about the manufacturer
16*ce9c0b06SMiquel Raynal  (name, country of manufacture, etc) as well as device caracteristics (serial
17*ce9c0b06SMiquel Raynal  number, hardware version, mac addresses, etc). The underlaying device type
18*ce9c0b06SMiquel Raynal  (flash, EEPROM,...) is not specified. The exact location of each value is also
19*ce9c0b06SMiquel Raynal  dynamic and should be discovered at run time because it depends on the
20*ce9c0b06SMiquel Raynal  parameters the manufacturer decided to embed.
21*ce9c0b06SMiquel Raynal
22*ce9c0b06SMiquel Raynalselect: false
23*ce9c0b06SMiquel Raynal
24*ce9c0b06SMiquel Raynalproperties:
25*ce9c0b06SMiquel Raynal  compatible:
26*ce9c0b06SMiquel Raynal    const: onie,tlv-layout
27*ce9c0b06SMiquel Raynal
28*ce9c0b06SMiquel Raynal  product-name:
29*ce9c0b06SMiquel Raynal    type: object
30*ce9c0b06SMiquel Raynal    additionalProperties: false
31*ce9c0b06SMiquel Raynal
32*ce9c0b06SMiquel Raynal  part-number:
33*ce9c0b06SMiquel Raynal    type: object
34*ce9c0b06SMiquel Raynal    additionalProperties: false
35*ce9c0b06SMiquel Raynal
36*ce9c0b06SMiquel Raynal  serial-number:
37*ce9c0b06SMiquel Raynal    type: object
38*ce9c0b06SMiquel Raynal    additionalProperties: false
39*ce9c0b06SMiquel Raynal
40*ce9c0b06SMiquel Raynal  mac-address:
41*ce9c0b06SMiquel Raynal    type: object
42*ce9c0b06SMiquel Raynal    description:
43*ce9c0b06SMiquel Raynal      Base MAC address for all on-module network interfaces. The first
44*ce9c0b06SMiquel Raynal      argument of the phandle will be treated as an offset.
45*ce9c0b06SMiquel Raynal
46*ce9c0b06SMiquel Raynal    properties:
47*ce9c0b06SMiquel Raynal      "#nvmem-cell-cells":
48*ce9c0b06SMiquel Raynal        const: 1
49*ce9c0b06SMiquel Raynal
50*ce9c0b06SMiquel Raynal    additionalProperties: false
51*ce9c0b06SMiquel Raynal
52*ce9c0b06SMiquel Raynal  manufacture-date:
53*ce9c0b06SMiquel Raynal    type: object
54*ce9c0b06SMiquel Raynal    additionalProperties: false
55*ce9c0b06SMiquel Raynal
56*ce9c0b06SMiquel Raynal  device-version:
57*ce9c0b06SMiquel Raynal    type: object
58*ce9c0b06SMiquel Raynal    additionalProperties: false
59*ce9c0b06SMiquel Raynal
60*ce9c0b06SMiquel Raynal  label-revision:
61*ce9c0b06SMiquel Raynal    type: object
62*ce9c0b06SMiquel Raynal    additionalProperties: false
63*ce9c0b06SMiquel Raynal
64*ce9c0b06SMiquel Raynal  platforn-name:
65*ce9c0b06SMiquel Raynal    type: object
66*ce9c0b06SMiquel Raynal    additionalProperties: false
67*ce9c0b06SMiquel Raynal
68*ce9c0b06SMiquel Raynal  onie-version:
69*ce9c0b06SMiquel Raynal    type: object
70*ce9c0b06SMiquel Raynal    additionalProperties: false
71*ce9c0b06SMiquel Raynal
72*ce9c0b06SMiquel Raynal  num-macs:
73*ce9c0b06SMiquel Raynal    type: object
74*ce9c0b06SMiquel Raynal    additionalProperties: false
75*ce9c0b06SMiquel Raynal
76*ce9c0b06SMiquel Raynal  manufacturer:
77*ce9c0b06SMiquel Raynal    type: object
78*ce9c0b06SMiquel Raynal    additionalProperties: false
79*ce9c0b06SMiquel Raynal
80*ce9c0b06SMiquel Raynal  country-code:
81*ce9c0b06SMiquel Raynal    type: object
82*ce9c0b06SMiquel Raynal    additionalProperties: false
83*ce9c0b06SMiquel Raynal
84*ce9c0b06SMiquel Raynal  vendor:
85*ce9c0b06SMiquel Raynal    type: object
86*ce9c0b06SMiquel Raynal    additionalProperties: false
87*ce9c0b06SMiquel Raynal
88*ce9c0b06SMiquel Raynal  diag-version:
89*ce9c0b06SMiquel Raynal    type: object
90*ce9c0b06SMiquel Raynal    additionalProperties: false
91*ce9c0b06SMiquel Raynal
92*ce9c0b06SMiquel Raynal  service-tag:
93*ce9c0b06SMiquel Raynal    type: object
94*ce9c0b06SMiquel Raynal    additionalProperties: false
95*ce9c0b06SMiquel Raynal
96*ce9c0b06SMiquel Raynal  vendor-extension:
97*ce9c0b06SMiquel Raynal    type: object
98*ce9c0b06SMiquel Raynal    additionalProperties: false
99*ce9c0b06SMiquel Raynal
100*ce9c0b06SMiquel Raynalrequired:
101*ce9c0b06SMiquel Raynal  - compatible
102*ce9c0b06SMiquel Raynal
103*ce9c0b06SMiquel RaynaladditionalProperties: false
104*ce9c0b06SMiquel Raynal
105*ce9c0b06SMiquel Raynalexamples:
106*ce9c0b06SMiquel Raynal  - |
107*ce9c0b06SMiquel Raynal    spi {
108*ce9c0b06SMiquel Raynal        #address-cells = <1>;
109*ce9c0b06SMiquel Raynal        #size-cells = <0>;
110*ce9c0b06SMiquel Raynal
111*ce9c0b06SMiquel Raynal        eeprom@56 {
112*ce9c0b06SMiquel Raynal            compatible = "atmel,24c64";
113*ce9c0b06SMiquel Raynal            read-only;
114*ce9c0b06SMiquel Raynal            reg = <0x56>;
115*ce9c0b06SMiquel Raynal
116*ce9c0b06SMiquel Raynal            nvmem-layout {
117*ce9c0b06SMiquel Raynal                compatible = "onie,tlv-layout";
118*ce9c0b06SMiquel Raynal
119*ce9c0b06SMiquel Raynal                serial-number {
120*ce9c0b06SMiquel Raynal                };
121*ce9c0b06SMiquel Raynal            };
122*ce9c0b06SMiquel Raynal        };
123*ce9c0b06SMiquel Raynal    };
124*ce9c0b06SMiquel Raynal
125*ce9c0b06SMiquel Raynal  - |
126*ce9c0b06SMiquel Raynal    spi {
127*ce9c0b06SMiquel Raynal        #address-cells = <1>;
128*ce9c0b06SMiquel Raynal        #size-cells = <0>;
129*ce9c0b06SMiquel Raynal
130*ce9c0b06SMiquel Raynal        flash@0 {
131*ce9c0b06SMiquel Raynal            compatible = "m25p80", "jedec,spi-nor";
132*ce9c0b06SMiquel Raynal            reg = <0>;
133*ce9c0b06SMiquel Raynal
134*ce9c0b06SMiquel Raynal            otp {
135*ce9c0b06SMiquel Raynal                compatible = "user-otp";
136*ce9c0b06SMiquel Raynal
137*ce9c0b06SMiquel Raynal                nvmem-layout {
138*ce9c0b06SMiquel Raynal                    compatible = "onie,tlv-layout";
139*ce9c0b06SMiquel Raynal
140*ce9c0b06SMiquel Raynal                    mac-address {
141*ce9c0b06SMiquel Raynal                        #nvmem-cell-cells = <1>;
142*ce9c0b06SMiquel Raynal                    };
143*ce9c0b06SMiquel Raynal                };
144*ce9c0b06SMiquel Raynal            };
145*ce9c0b06SMiquel Raynal        };
146*ce9c0b06SMiquel Raynal    };
147*ce9c0b06SMiquel Raynal...
148