Home
last modified time | relevance | path

Searched +full:nvmem +full:- +full:layout (Results 1 – 25 of 46) sorted by relevance

12

/linux-6.12.1/drivers/nvmem/
Dlayouts.c1 // SPDX-License-Identifier: GPL-2.0
3 * NVMEM layout bus handling
10 #include <linux/dma-mapping.h>
11 #include <linux/nvmem-consumer.h>
12 #include <linux/nvmem-provider.h>
31 struct nvmem_layout_driver *drv = to_nvmem_layout_driver(dev->driver); in nvmem_layout_bus_probe()
32 struct nvmem_layout *layout = to_nvmem_layout_device(dev); in nvmem_layout_bus_probe() local
34 if (!drv->probe || !drv->remove) in nvmem_layout_bus_probe()
35 return -EINVAL; in nvmem_layout_bus_probe()
37 return drv->probe(layout); in nvmem_layout_bus_probe()
[all …]
Dcore.c1 // SPDX-License-Identifier: GPL-2.0
3 * nvmem framework core.
6 * Copyright (C) 2013 Maxime Ripard <maxime.ripard@free-electrons.com>
16 #include <linux/nvmem-consumer.h>
17 #include <linux/nvmem-provider.h>
37 struct nvmem_device *nvmem; member
58 static int __nvmem_reg_read(struct nvmem_device *nvmem, unsigned int offset, in __nvmem_reg_read() argument
61 if (nvmem->reg_read) in __nvmem_reg_read()
62 return nvmem->reg_read(nvmem->priv, offset, val, bytes); in __nvmem_reg_read()
64 return -EINVAL; in __nvmem_reg_read()
[all …]
Dinternals.h1 /* SPDX-License-Identifier: GPL-2.0 */
7 #include <linux/nvmem-consumer.h>
8 #include <linux/nvmem-provider.h>
26 void (*fixup_dt_cell_info)(struct nvmem_device *nvmem,
33 struct nvmem_layout *layout; member
41 int nvmem_populate_layout(struct nvmem_device *nvmem);
42 void nvmem_destroy_layout(struct nvmem_device *nvmem);
51 static inline int nvmem_populate_layout(struct nvmem_device *nvmem) in nvmem_populate_layout() argument
56 static inline void nvmem_destroy_layout(struct nvmem_device *nvmem) { } in nvmem_destroy_layout() argument
/linux-6.12.1/include/linux/
Dnvmem-provider.h1 /* SPDX-License-Identifier: GPL-2.0 */
3 * nvmem framework provider.
6 * Copyright (C) 2013 Maxime Ripard <maxime.ripard@free-electrons.com>
36 #define NVMEM_DEVID_NONE (-1)
37 #define NVMEM_DEVID_AUTO (-2)
40 * struct nvmem_keepout - NVMEM register keepout range.
53 * struct nvmem_cell_info - NVMEM cell description
55 * @offset: Offset within the NVMEM device.
78 * struct nvmem_config - NVMEM device configuration
84 * @cells: Optional array of pre-defined NVMEM cells.
[all …]
/linux-6.12.1/Documentation/devicetree/bindings/nvmem/layouts/
Dfixed-layout.yaml1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
3 ---
4 $id: http://devicetree.org/schemas/nvmem/layouts/fixed-layout.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: NVMEM layout for fixed NVMEM cells
10 Many NVMEM devices have hardcoded cells layout (offset and size of defined
11 NVMEM content doesn't change).
13 This binding allows defining such NVMEM layout with its cells. It can be used
14 on top of any NVMEM device.
17 - Rafał Miłecki <rafal@milecki.pl>
[all …]
Donie,tlv-layout.yaml1 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
3 ---
4 $id: http://devicetree.org/schemas/nvmem/layouts/onie,tlv-layout.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: NVMEM layout of the ONIE tlv table
10 - Miquel Raynal <miquel.raynal@bootlin.com>
14 infrastructure shall provide a non-volatile memory with a table whose the
26 const: onie,tlv-layout
28 product-name:
32 part-number:
[all …]
Dnvmem-layout.yaml1 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
3 ---
4 $id: http://devicetree.org/schemas/nvmem/layouts/nvmem-layout.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: NVMEM (Non Volatile Memory) layouts
10 - Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
11 - Michael Walle <michael@walle.cc>
12 - Miquel Raynal <miquel.raynal@bootlin.com>
15 Most NVMEM layouts are static and thus do not require additional description
17 define and might require dynamic reading of the NVMEM device in order to
[all …]
Dkontron,sl28-vpd.yaml1 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
3 ---
4 $id: http://devicetree.org/schemas/nvmem/layouts/kontron,sl28-vpd.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: NVMEM layout of the Kontron SMARC-sAL28 vital product data
10 - Michael Walle <michael@walle.cc>
15 on-board ethernet devices are derived from this base MAC address by
22 const: kontron,sl28-vpd
24 serial-number:
30 base-mac-address:
[all …]
Du-boot,env.yaml1 # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
3 ---
4 $id: http://devicetree.org/schemas/nvmem/layouts/u-boot,env.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: U-Boot environment variables layout
10 U-Boot uses environment variables to store device parameters and
14 Data is stored using U-Boot specific formats (variant specific header and NUL
15 separated key-value pairs).
24 Variables can be defined as NVMEM device subnodes.
27 - Rafał Miłecki <rafal@milecki.pl>
[all …]
/linux-6.12.1/drivers/nvmem/layouts/
Donie-tlv.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * ONIE tlv NVMEM cells provider
7 * Based on the nvmem driver written by: Vadym Kochan <vadym.kochan@plvision.eu>
8 * Inspired by the first layout written by: Rafał Miłecki <rafal@milecki.pl>
13 #include <linux/nvmem-consumer.h>
14 #include <linux/nvmem-provider.h>
37 return "product-name"; in onie_tlv_cell_name()
39 return "part-number"; in onie_tlv_cell_name()
41 return "serial-number"; in onie_tlv_cell_name()
43 return "mac-address"; in onie_tlv_cell_name()
[all …]
Dsl28vpd.c1 // SPDX-License-Identifier: GPL-2.0
5 #include <linux/nvmem-consumer.h>
6 #include <linux/nvmem-provider.h>
29 return -EINVAL; in sl28vpd_mac_address_pp()
32 return -EINVAL; in sl28vpd_mac_address_pp()
35 return -EINVAL; in sl28vpd_mac_address_pp()
44 .name = "serial-number",
49 .name = "base-mac-address",
56 static int sl28vpd_v1_check_crc(struct device *dev, struct nvmem_device *nvmem) in sl28vpd_v1_check_crc() argument
65 ret = nvmem_device_read(nvmem, 0, sizeof(data_v1), &data_v1); in sl28vpd_v1_check_crc()
[all …]
Du-boot-env.c1 // SPDX-License-Identifier: GPL-2.0-only
3 * Copyright (C) 2022 - 2023 Rafał Miłecki <rafal@milecki.pl>
10 #include <linux/nvmem-consumer.h>
11 #include <linux/nvmem-provider.h>
15 #include "u-boot-env.h"
40 if (bytes != 3 * ETH_ALEN - 1) in u_boot_env_read_post_process_ethaddr()
41 return -EINVAL; in u_boot_env_read_post_process_ethaddr()
44 return -EINVAL; in u_boot_env_read_post_process_ethaddr()
54 static int u_boot_env_parse_cells(struct device *dev, struct nvmem_device *nvmem, uint8_t *buf, in u_boot_env_parse_cells() argument
73 return -ENOMEM; in u_boot_env_parse_cells()
[all …]
DKconfig1 # SPDX-License-Identifier: GPL-2.0
9 menu "Layout Types"
12 tristate "Kontron sl28 VPD layout support"
15 Say Y here if you want to support the VPD layout of the Kontron
16 SMARC-sAL28 boards.
25 Type-Length-Value standard table.
30 tristate "U-Boot environment variables layout"
34 U-Boot stores its setup as environment variables. This driver adds
36 as NVMEM cells so they can be referenced by other drivers.
/linux-6.12.1/Documentation/devicetree/bindings/nvmem/
Dnvmem.yaml1 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
3 ---
4 $id: http://devicetree.org/schemas/nvmem/nvmem.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: NVMEM (Non Volatile Memory)
10 - Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
17 some data on NVMEM, for the OS to be able to retrieve these
23 "#address-cells":
26 "#size-cells":
29 read-only:
[all …]
Dxlnx,zynqmp-nvmem.yaml1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
3 ---
4 $id: http://devicetree.org/schemas/nvmem/xlnx,zynqmp-nvmem.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
14 - Kalyani Akula <kalyani.akula@amd.com>
15 - Praveen Teja Kundanala <praveen.teja.kundanala@amd.com>
18 - $ref: nvmem.yaml#
22 const: xlnx,zynqmp-nvmem-fw
25 - compatible
30 - |
[all …]
Dnvmem-deprecated-cells.yaml1 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause)
3 ---
4 $id: http://devicetree.org/schemas/nvmem/nvmem-deprecated-cells.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
7 title: NVMEM old syntax for fixed cells
10 - Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
13 Before introducing NVMEM layouts all NVMEM (fixed) cells were defined
14 as direct device subnodes. That syntax was replaced by "fixed-layout"
18 "@[0-9a-f]+(,[0-7])?$":
21 - $ref: layouts/fixed-cell.yaml
[all …]
/linux-6.12.1/Documentation/devicetree/bindings/mtd/partitions/
Dubi-volume.yaml1 # SPDX-License-Identifier: GPL-2.0-only OR BSD-2-Clause
3 ---
4 $id: http://devicetree.org/schemas/mtd/partitions/ubi-volume.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
14 - Daniel Golle <daniel@makrotopia.org>
27 nvmem-layout:
28 $ref: /schemas/nvmem/layouts/nvmem-layout.yaml#
30 This container may reference an NVMEM layout parser.
33 - required:
34 - volid
[all …]
/linux-6.12.1/arch/arm64/boot/dts/mediatek/
Dmt7986a-acelink-ew-7886cax.dts1 // SPDX-License-Identifier: GPL-2.0-only OR MIT
3 /dts-v1/;
4 #include <dt-bindings/input/input.h>
5 #include <dt-bindings/gpio/gpio.h>
6 #include <dt-bindings/leds/common.h>
11 compatible = "acelink,ew-7886cax", "mediatek,mt7986a";
12 model = "Acelink EW-7886CAX";
19 stdout-path = "serial0:115200n8";
28 compatible = "gpio-keys";
30 key-restart {
[all …]
/linux-6.12.1/arch/arm/boot/dts/ti/omap/
Dam335x-bone-common.dtsi1 // SPDX-License-Identifier: GPL-2.0-only
3 * Copyright (C) 2012 Texas Instruments Incorporated - https://www.ti.com/
9 cpu0-supply = <&dcdc2_reg>;
19 stdout-path = &uart0;
23 pinctrl-names = "default";
24 pinctrl-0 = <&user_leds_s0>;
26 compatible = "gpio-leds";
31 linux,default-trigger = "heartbeat";
32 default-state = "off";
38 linux,default-trigger = "mmc0";
[all …]
/linux-6.12.1/Documentation/devicetree/bindings/firmware/xilinx/
Dxlnx,zynqmp-firmware.yaml1 # SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause)
3 ---
4 $id: http://devicetree.org/schemas/firmware/xilinx/xlnx,zynqmp-firmware.yaml#
5 $schema: http://devicetree.org/meta-schemas/core.yaml#
10 - Nava kishore Manne <nava.kishore.manne@amd.com>
12 description: The zynqmp-firmware node describes the interface to platform
23 - description: For implementations complying for Zynq Ultrascale+ MPSoC.
24 const: xlnx,zynqmp-firmware
26 - description: For implementations complying for Versal.
27 const: xlnx,versal-firmware
[all …]
/linux-6.12.1/arch/arm/boot/dts/broadcom/
Dbcm958625-meraki-mx6x-common.dtsi1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
5 * Copyright (C) 2020-2021 Matthew Hagan <mnhagan88@gmail.com>
8 #include "bcm-nsp.dtsi"
9 #include <dt-bindings/gpio/gpio.h>
10 #include <dt-bindings/input/input.h>
11 #include <dt-bindings/leds/common.h>
14 pwm-leds {
15 compatible = "pwm-leds";
17 led-1 {
21 max-brightness = <255>;
[all …]
Dbcm53016-meraki-mr32.dts1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
6 * Copyright (C) 2018-2020 Christian Lamparter <chunkeey@gmail.com>
9 /dts-v1/;
12 #include "bcm5301x-nand-cs0-bch8.dtsi"
13 #include <dt-bindings/leds/common.h>
33 compatible = "gpio-leds";
39 panic-indicator;
49 compatible = "gpio-keys";
51 button-restart {
58 pwm-leds {
[all …]
/linux-6.12.1/drivers/mtd/ubi/
Dnvmem.c1 // SPDX-License-Identifier: GPL-2.0-or-later
6 /* UBI NVMEM provider */
8 #include <linux/nvmem-provider.h>
10 /* List of all NVMEM devices */
15 struct nvmem_device *nvmem; member
32 desc = ubi_open_volume(unv->ubi_num, unv->vol_id, UBI_READONLY); in ubi_nvmem_reg_read()
36 offs = from % unv->usable_leb_size; in ubi_nvmem_reg_read()
37 lnum = from / unv->usable_leb_size; in ubi_nvmem_reg_read()
39 to_read = unv->usable_leb_size - offs; in ubi_nvmem_reg_read()
50 bytes_left -= to_read; in ubi_nvmem_reg_read()
[all …]
/linux-6.12.1/arch/arm64/boot/dts/broadcom/bcmbca/
Dbcm4908-asus-gt-ac5300.dts1 // SPDX-License-Identifier: GPL-2.0-or-later OR MIT
3 #include <dt-bindings/gpio/gpio.h>
4 #include <dt-bindings/input/input.h>
5 #include <dt-bindings/leds/common.h>
10 compatible = "asus,gt-ac5300", "brcm,bcm4908", "brcm,bcmbca";
11 model = "Asus GT-AC5300";
18 gpio-keys-polled {
19 compatible = "gpio-keys-polled";
20 poll-interval = <100>;
22 key-wifi {
[all …]
/linux-6.12.1/Documentation/driver-api/
Dnvmem.rst1 .. SPDX-License-Identifier: GPL-2.0
4 NVMEM Subsystem
9 This document explains the NVMEM Framework along with the APIs provided,
14 *NVMEM* is the abbreviation for Non Volatile Memory layer. It is used to
18 Before this framework existed, NVMEM drivers like eeprom were stored in
20 register a sysfs file, allow in-kernel users to access the content of the
23 This was also a problem as far as other in-kernel users were involved, since
31 NVMEM Providers
34 NVMEM provider refers to an entity that implements methods to initialize, read
35 and write the non-volatile memory.
[all …]

12