diff options
author | Rafał Miłecki <rafal@milecki.pl> | 2023-12-21 18:34:17 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2024-01-04 17:01:13 +0100 |
commit | 33cf42e68efc8ff529a7eee08a4f0ba8c8d0a207 (patch) | |
tree | ab6de4481b3080c1e5db3a4a51182e6738126ff6 /include/linux/nvmem-consumer.h | |
parent | 43f60e3fb62edc7bd8891de8779fb422f4ae23ae (diff) |
nvmem: core: add nvmem_dev_size() helper
This is required by layouts that need to read whole NVMEM content. It's
especially useful for NVMEM devices without hardcoded layout (like
U-Boot environment data block).
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
Reviewed-by: Miquel Raynal <miquel.raynal@bootlin.com>
Link: https://lore.kernel.org/r/20231221173421.13737-2-zajec5@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/nvmem-consumer.h')
-rw-r--r-- | include/linux/nvmem-consumer.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/nvmem-consumer.h b/include/linux/nvmem-consumer.h index 2d306fa13b1a..34c0e58dfa26 100644 --- a/include/linux/nvmem-consumer.h +++ b/include/linux/nvmem-consumer.h @@ -81,6 +81,7 @@ int nvmem_device_cell_write(struct nvmem_device *nvmem, struct nvmem_cell_info *info, void *buf); const char *nvmem_dev_name(struct nvmem_device *nvmem); +size_t nvmem_dev_size(struct nvmem_device *nvmem); void nvmem_add_cell_lookups(struct nvmem_cell_lookup *entries, size_t nentries); |