Home
last modified time | relevance | path

Searched full:nvmem (Results 1 – 25 of 316) sorted by relevance

12345678910>>...13

/kernel/linux/linux-5.10/drivers/nvmem/
Dcore.c3 * nvmem framework core.
16 #include <linux/nvmem-consumer.h>
17 #include <linux/nvmem-provider.h>
54 struct nvmem_device *nvmem; member
69 static int nvmem_reg_read(struct nvmem_device *nvmem, unsigned int offset, in nvmem_reg_read() argument
72 if (nvmem->reg_read) in nvmem_reg_read()
73 return nvmem->reg_read(nvmem->priv, offset, val, bytes); in nvmem_reg_read()
78 static int nvmem_reg_write(struct nvmem_device *nvmem, unsigned int offset, in nvmem_reg_write() argument
83 if (nvmem->reg_write) { in nvmem_reg_write()
84 gpiod_set_value_cansleep(nvmem->wp_gpio, 0); in nvmem_reg_write()
[all …]
DMakefile3 # Makefile for nvmem drivers.
10 obj-$(CONFIG_NVMEM_BCM_OCOTP) += nvmem-bcm-ocotp.o
11 nvmem-bcm-ocotp-y := bcm-ocotp.o
12 obj-$(CONFIG_NVMEM_IMX_IIM) += nvmem-imx-iim.o
13 nvmem-imx-iim-y := imx-iim.o
14 obj-$(CONFIG_NVMEM_IMX_OCOTP) += nvmem-imx-ocotp.o
15 nvmem-imx-ocotp-y := imx-ocotp.o
16 obj-$(CONFIG_NVMEM_IMX_OCOTP_SCU) += nvmem-imx-ocotp-scu.o
17 nvmem-imx-ocotp-scu-y := imx-ocotp-scu.o
24 obj-$(CONFIG_NVMEM_MXS_OCOTP) += nvmem-mxs-ocotp.o
[all …]
DKconfig2 menuconfig NVMEM config
3 bool "NVMEM Support"
5 Support for NVMEM(Non Volatile Memory) devices like EEPROM, EFUSES...
7 This framework is designed to provide a generic interface to NVMEM
12 if NVMEM
15 bool "/sys/bus/nvmem/devices/*/nvmem (sysfs interface)"
19 Say Y here to add a sysfs interface for NVMEM.
22 read/write directly into nvmem.
33 will be called nvmem-imx-iim.
45 will be called nvmem-imx-ocotp.
[all …]
Dzynqmp_nvmem.c7 #include <linux/nvmem-provider.h>
16 struct nvmem_device *nvmem; member
37 .name = "zynqmp-nvmem",
45 { .compatible = "xlnx,zynqmp-nvmem-fw", },
64 priv->nvmem = devm_nvmem_register(dev, &econfig); in zynqmp_nvmem_probe()
66 return PTR_ERR_OR_ZERO(priv->nvmem); in zynqmp_nvmem_probe()
72 .name = "zynqmp-nvmem",
80 MODULE_DESCRIPTION("ZynqMP NVMEM driver");
/kernel/linux/linux-4.19/drivers/nvmem/
Dcore.c2 * nvmem framework core.
23 #include <linux/nvmem-consumer.h>
24 #include <linux/nvmem-provider.h>
54 struct nvmem_device *nvmem; member
69 static int nvmem_reg_read(struct nvmem_device *nvmem, unsigned int offset, in nvmem_reg_read() argument
72 if (nvmem->reg_read) in nvmem_reg_read()
73 return nvmem->reg_read(nvmem->priv, offset, val, bytes); in nvmem_reg_read()
78 static int nvmem_reg_write(struct nvmem_device *nvmem, unsigned int offset, in nvmem_reg_write() argument
81 if (nvmem->reg_write) in nvmem_reg_write()
82 return nvmem->reg_write(nvmem->priv, offset, val, bytes); in nvmem_reg_write()
[all …]
DMakefile3 # Makefile for nvmem drivers.
10 obj-$(CONFIG_NVMEM_BCM_OCOTP) += nvmem-bcm-ocotp.o
11 nvmem-bcm-ocotp-y := bcm-ocotp.o
12 obj-$(CONFIG_NVMEM_IMX_IIM) += nvmem-imx-iim.o
13 nvmem-imx-iim-y := imx-iim.o
14 obj-$(CONFIG_NVMEM_IMX_OCOTP) += nvmem-imx-ocotp.o
15 nvmem-imx-ocotp-y := imx-ocotp.o
20 obj-$(CONFIG_NVMEM_MXS_OCOTP) += nvmem-mxs-ocotp.o
21 nvmem-mxs-ocotp-y := mxs-ocotp.o
30 obj-$(CONFIG_UNIPHIER_EFUSE) += nvmem-uniphier-efuse.o
[all …]
DKconfig1 menuconfig NVMEM config
2 bool "NVMEM Support"
4 Support for NVMEM(Non Volatile Memory) devices like EEPROM, EFUSES...
6 This framework is designed to provide a generic interface to NVMEM
14 if NVMEM
25 will be called nvmem-imx-iim.
37 will be called nvmem-imx-ocotp.
69 will be called nvmem-mxs-ocotp.
88 functions for QFPROM data to rest of the drivers via nvmem interface.
114 will be called nvmem-bcm-ocotp.
[all …]
/kernel/linux/linux-4.19/Documentation/nvmem/
Dnvmem.txt1 NVMEM SUBSYSTEM
4 This document explains the NVMEM Framework along with the APIs provided,
9 *NVMEM* is the abbreviation for Non Volatile Memory layer. It is used to
13 Before this framework existed, NVMEM drivers like eeprom were stored in
28 NVMEM Providers
31 NVMEM provider refers to an entity that implements methods to initialize, read
34 2. Registering/Unregistering the NVMEM provider
37 A NVMEM provider can register with NVMEM core by supplying relevant
38 nvmem configuration to nvmem_register(), on success core would return a valid
41 nvmem_unregister(nvmem) is used to unregister a previously registered provider.
[all …]
/kernel/linux/linux-5.10/Documentation/driver-api/
Dnvmem.rst4 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
33 NVMEM Providers
36 NVMEM provider refers to an entity that implements methods to initialize, read
39 2. Registering/Unregistering the NVMEM provider
42 A NVMEM provider can register with NVMEM core by supplying relevant
43 nvmem configuration to nvmem_register(), on success core would return a valid
46 nvmem_unregister(nvmem) is used to unregister a previously registered provider.
[all …]
/kernel/linux/linux-5.10/Documentation/devicetree/bindings/nvmem/
Dnvmem-consumer.yaml4 $id: http://devicetree.org/schemas/nvmem/nvmem-consumer.yaml#
7 title: NVMEM (Non Volatile Memory) Consumer Device Tree Bindings
15 nvmem:
18 List of phandle to the nvmem providers.
20 nvmem-cells:
23 List of phandle to the nvmem data cells.
25 nvmem-names:
28 Names for the each nvmem provider.
30 nvmem-cell-names:
33 Names for each nvmem-cells specified.
[all …]
Dxlnx,zynqmp-nvmem.txt2 = Zynq UltraScale+ MPSoC nvmem firmware driver binding =
8 - compatible: should be "xlnx,zynqmp-nvmem-fw"
12 bindings/nvmem/nvmem.txt
23 compatible = "xlnx,zynqmp-nvmem-fw";
36 Are device nodes which consume nvmem data cells.
42 nvmem-cells = <&soc_revision>;
43 nvmem-cell-names = "soc_revision";
/kernel/linux/linux-4.19/Documentation/devicetree/bindings/nvmem/
Dnvmem.txt1 = NVMEM(Non Volatile Memory) Data Device Tree Bindings =
7 some data on NVMEM, for the OS to be able to retrieve these information
22 information like offset and size in nvmem provider.
63 Are device nodes which consume nvmem data cells/providers.
66 nvmem-cells: list of phandle to the nvmem data cells.
67 nvmem-cell-names: names for the each nvmem-cells specified. Required if
68 nvmem-cells is used.
71 nvmem : list of phandles to nvmem providers.
72 nvmem-names: names for the each nvmem provider. required if nvmem is used.
78 nvmem-cells = <&tsens_calibration>;
[all …]
/kernel/linux/linux-5.10/Documentation/devicetree/bindings/thermal/
Dsprd-thermal.yaml28 nvmem-cells:
31 Reference to nvmem nodes for the calibration data.
33 nvmem-cell-names:
58 nvmem-cells:
61 Reference to an nvmem node for the calibration data.
63 nvmem-cell-names:
68 - nvmem-cells
69 - nvmem-cell-names
78 - nvmem-cells
79 - nvmem-cell-names
[all …]
/kernel/linux/linux-5.10/drivers/thunderbolt/
Dnvm.c46 * tb_nvm_add_active() - Adds active NVMem device to NVM
50 * NVMem device)
52 * Registers new active NVmem device for @nvm. The @reg_read is called
53 * directly from NVMem so it must handle possible concurrent access if
60 struct nvmem_device *nvmem; in tb_nvm_add_active() local
75 nvmem = nvmem_register(&config); in tb_nvm_add_active()
76 if (IS_ERR(nvmem)) in tb_nvm_add_active()
77 return PTR_ERR(nvmem); in tb_nvm_add_active()
79 nvm->active = nvmem; in tb_nvm_add_active()
110 * tb_nvm_add_non_active() - Adds non-active NVMem device to NVM
[all …]
/kernel/linux/linux-5.10/Documentation/devicetree/bindings/power/reset/
Dnvmem-reboot-mode.txt1 NVMEM reboot mode driver
4 and stores it in a NVMEM cell named "reboot-mode". Then the bootloader
9 - compatible: should be "nvmem-reboot-mode".
10 - nvmem-cells: A phandle to the reboot mode provided by a nvmem device.
11 - nvmem-cell-names: Should be "reboot-mode".
18 compatible = "nvmem-reboot-mode";
19 nvmem-cells = <&reboot_mode>;
20 nvmem-cell-names = "reboot-mode";
/kernel/linux/linux-5.10/include/linux/
Dnvmem-consumer.h3 * nvmem framework consumer.
34 * @cell_name: Name of the nvmem cell as defined in the name field of
69 /* direct nvmem device read/write interface */
73 void nvmem_device_put(struct nvmem_device *nvmem);
74 void devm_nvmem_device_put(struct device *dev, struct nvmem_device *nvmem);
75 int nvmem_device_read(struct nvmem_device *nvmem, unsigned int offset,
77 int nvmem_device_write(struct nvmem_device *nvmem, unsigned int offset,
79 ssize_t nvmem_device_cell_read(struct nvmem_device *nvmem,
81 int nvmem_device_cell_write(struct nvmem_device *nvmem,
84 const char *nvmem_dev_name(struct nvmem_device *nvmem);
[all …]
Dnvmem-provider.h3 * nvmem framework provider.
34 * struct nvmem_config - NVMEM device configuration
40 * @cells: Optional array of pre-defined NVMEM cells.
42 * @type: Type of the nvmem storage
54 * Note: A default "nvmem<id>" name will be assigned to the device if
85 * struct nvmem_cell_table - NVMEM cell definitions for given provider
93 * that don't can't access the nvmem provided structure but wish to register
106 void nvmem_unregister(struct nvmem_device *nvmem);
111 int devm_nvmem_unregister(struct device *dev, struct nvmem_device *nvmem);
123 static inline void nvmem_unregister(struct nvmem_device *nvmem) {} in nvmem_unregister() argument
[all …]
/kernel/linux/linux-4.19/drivers/rtc/
Dnvmem.c2 * RTC subsystem, nvmem interface
13 #include <linux/nvmem-consumer.h>
21 static const char nvram_warning[] = "Deprecated ABI, please use nvmem";
32 return nvmem_device_read(rtc->nvmem, off, count, buf); in rtc_nvram_read()
44 return nvmem_device_write(rtc->nvmem, off, count, buf); in rtc_nvram_write()
83 * New ABI, uses nvmem
88 if (!IS_ERR_OR_NULL(rtc->nvmem)) in rtc_nvmem_register()
96 rtc->nvmem = nvmem_register(nvmem_config); in rtc_nvmem_register()
97 if (IS_ERR(rtc->nvmem)) in rtc_nvmem_register()
98 return PTR_ERR(rtc->nvmem); in rtc_nvmem_register()
[all …]
/kernel/linux/linux-4.19/include/linux/
Dnvmem-consumer.h2 * nvmem framework consumer.
43 /* direct nvmem device read/write interface */
47 void nvmem_device_put(struct nvmem_device *nvmem);
48 void devm_nvmem_device_put(struct device *dev, struct nvmem_device *nvmem);
49 int nvmem_device_read(struct nvmem_device *nvmem, unsigned int offset,
51 int nvmem_device_write(struct nvmem_device *nvmem, unsigned int offset,
53 ssize_t nvmem_device_cell_read(struct nvmem_device *nvmem,
55 int nvmem_device_cell_write(struct nvmem_device *nvmem,
110 static inline void nvmem_device_put(struct nvmem_device *nvmem) in nvmem_device_put() argument
115 struct nvmem_device *nvmem) in devm_nvmem_device_put() argument
[all …]
Dnvmem-provider.h2 * nvmem framework provider.
26 * struct nvmem_config - NVMEM device configuration
32 * @cells: Optional array of pre-defined NVMEM cells.
43 * Note: A default "nvmem<id>" name will be assigned to the device if
73 int nvmem_unregister(struct nvmem_device *nvmem);
78 int devm_nvmem_unregister(struct device *dev, struct nvmem_device *nvmem);
80 int nvmem_add_cells(struct nvmem_device *nvmem,
90 static inline int nvmem_unregister(struct nvmem_device *nvmem) in nvmem_unregister() argument
102 devm_nvmem_unregister(struct device *dev, struct nvmem_device *nvmem) in devm_nvmem_unregister() argument
104 return nvmem_unregister(nvmem); in devm_nvmem_unregister()
[all …]
/kernel/linux/linux-5.10/drivers/rtc/
Dnvmem.c3 * RTC subsystem, nvmem interface
10 #include <linux/nvmem-consumer.h>
19 static const char nvram_warning[] = "Deprecated ABI, please use nvmem";
42 struct nvmem_device *nvmem, size_t size) in rtc_nvram_register() argument
52 rtc->nvram->private = nvmem; in rtc_nvram_register()
78 * New ABI, uses nvmem
83 struct nvmem_device *nvmem; in rtc_nvmem_register() local
90 nvmem = devm_nvmem_register(rtc->dev.parent, nvmem_config); in rtc_nvmem_register()
91 if (IS_ERR(nvmem)) in rtc_nvmem_register()
92 return PTR_ERR(nvmem); in rtc_nvmem_register()
[all …]
/kernel/linux/linux-5.10/drivers/soc/tegra/fuse/
Dfuse-tegra.c11 #include <linux/nvmem-consumer.h>
12 #include <linux/nvmem-provider.h>
186 struct nvmem_config nvmem; in tegra_fuse_probe() local
219 memset(&nvmem, 0, sizeof(nvmem)); in tegra_fuse_probe()
220 nvmem.dev = &pdev->dev; in tegra_fuse_probe()
221 nvmem.name = "fuse"; in tegra_fuse_probe()
222 nvmem.id = -1; in tegra_fuse_probe()
223 nvmem.owner = THIS_MODULE; in tegra_fuse_probe()
224 nvmem.cells = tegra_fuse_cells; in tegra_fuse_probe()
225 nvmem.ncells = ARRAY_SIZE(tegra_fuse_cells); in tegra_fuse_probe()
[all …]
/kernel/linux/linux-4.19/Documentation/ABI/stable/
Dsysfs-bus-nvmem1 What: /sys/bus/nvmem/devices/.../nvmem
6 This file allows user to read/write the raw NVMEM contents.
7 Permissions for write to this file depends on the nvmem
11 hexdump /sys/bus/nvmem/devices/qfprom0/nvmem
/kernel/linux/linux-5.10/Documentation/devicetree/bindings/net/
Dnixge.txt15 - nvmem-cells: Phandle of nvmem cell containing the MAC address
16 - nvmem-cell-names: Should be "address"
31 nvmem-cells = <&eth1_addr>;
32 nvmem-cell-names = "address";
54 nvmem-cells = <&eth1_addr>;
55 nvmem-cell-names = "address";
70 nvmem-cells = <&eth1_addr>;
71 nvmem-cell-names = "address";
/kernel/linux/linux-5.10/Documentation/ABI/stable/
Dsysfs-bus-nvmem1 What: /sys/bus/nvmem/devices/.../nvmem
6 This file allows user to read/write the raw NVMEM contents.
7 Permissions for write to this file depends on the nvmem
14 hexdump /sys/bus/nvmem/devices/qfprom0/nvmem

12345678910>>...13