diff options
author | Vadym Kochan <vadym.kochan@plvision.eu> | 2020-09-16 20:09:31 +0300 |
---|---|---|
committer | Bartosz Golaszewski <bgolaszewski@baylibre.com> | 2020-09-17 10:05:20 +0200 |
commit | 774b9f43716d5a79272e052bcae2f3939b02a2c6 (patch) | |
tree | fd2550faff8ced7572faec254cd25ca8069f983b /drivers | |
parent | 99363d1c26c825055f8a879d9d5c2b78168cf655 (diff) |
eeprom: at24: set type id as EEPROM
Set type as NVMEM_TYPE_EEPROM to expose this info via
sysfs:
$ cat /sys/bus/nvmem/devices/{DEVICE}/type
EEPROM
Signed-off-by: Vadym Kochan <vadym.kochan@plvision.eu>
Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/misc/eeprom/at24.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/misc/eeprom/at24.c b/drivers/misc/eeprom/at24.c index 8f5de5f10bbe..00c8ac0677b4 100644 --- a/drivers/misc/eeprom/at24.c +++ b/drivers/misc/eeprom/at24.c @@ -713,6 +713,7 @@ static int at24_probe(struct i2c_client *client) return err; } + nvmem_config.type = NVMEM_TYPE_EEPROM; nvmem_config.name = dev_name(dev); nvmem_config.dev = dev; nvmem_config.read_only = !writable; |