nvmem: core: Add nvmem_cell_read_u8()
Complement the u16, u32 and u64 helpers with a u8 variant to ease accessing byte-sized values. This helper will be useful for Realtek Digital Home Center platforms, which store some byte and sub-byte sized values in non-volatile memory. Signed-off-by: Andreas Färber <afaerber@suse.de> Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> Link: https://lore.kernel.org/r/20200722100705.7772-7-srinivas.kandagatla@linaro.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:

committed by
Greg Kroah-Hartman

parent
3a7580710b
commit
5037d368b2
@@ -61,6 +61,7 @@ void nvmem_cell_put(struct nvmem_cell *cell);
|
||||
void devm_nvmem_cell_put(struct device *dev, struct nvmem_cell *cell);
|
||||
void *nvmem_cell_read(struct nvmem_cell *cell, size_t *len);
|
||||
int nvmem_cell_write(struct nvmem_cell *cell, void *buf, size_t len);
|
||||
int nvmem_cell_read_u8(struct device *dev, const char *cell_id, u8 *val);
|
||||
int nvmem_cell_read_u16(struct device *dev, const char *cell_id, u16 *val);
|
||||
int nvmem_cell_read_u32(struct device *dev, const char *cell_id, u32 *val);
|
||||
int nvmem_cell_read_u64(struct device *dev, const char *cell_id, u64 *val);
|
||||
|
Reference in New Issue
Block a user