summaryrefslogtreecommitdiff
path: root/Documentation/devicetree/bindings/eeprom/microchip,93lc46b.yaml
blob: 144e86ce5c0a3274ffa496059819e192e08b55eb (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
# SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
%YAML 1.2
---
$id: http://devicetree.org/schemas/eeprom/microchip,93lc46b.yaml#
$schema: http://devicetree.org/meta-schemas/core.yaml#

title: Microchip 93xx46 SPI compatible EEPROM family

maintainers:
  - Cory Tusar <cory.tusar@pid1solutions.com>

properties:
  compatible:
    enum:
      - atmel,at93c46
      - atmel,at93c46d
      - atmel,at93c56
      - atmel,at93c66
      - eeprom-93xx46
      - microchip,93lc46b

  data-size:
    description: number of data bits per word
    $ref: /schemas/types.yaml#/definitions/uint32
    enum: [8, 16]

  reg:
    description: chip select of EEPROM
    maxItems: 1

  read-only:
    description:
      parameter-less property which disables writes to the EEPROM
    type: boolean

  select-gpios:
    description:
      specifies the GPIO that needs to be asserted prior to each access
      of EEPROM (e.g. for SPI bus multiplexing)
    maxItems: 1

required:
  - compatible
  - reg
  - data-size
  - spi-max-frequency

allOf:
  - $ref: /schemas/spi/spi-peripheral-props.yaml#
  - $ref: /schemas/nvmem/nvmem.yaml

unevaluatedProperties: false

examples:
  - |
    #include <dt-bindings/gpio/gpio.h>

    spi {
      #address-cells = <1>;
      #size-cells = <0>;

      eeprom@0 {
        compatible = "eeprom-93xx46";
        reg = <0>;
        spi-max-frequency = <1000000>;
        spi-cs-high;
        data-size = <8>;
        select-gpios = <&gpio4 4 GPIO_ACTIVE_HIGH>;
      };
    };