Commit 1d62a2ce authored by Vadym Kochan's avatar Vadym Kochan Committed by Greg Kroah-Hartman

eeprom: 93xx46: 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: default avatarVadym Kochan <vadym.kochan@plvision.eu>
Link: https://lore.kernel.org/r/20200916170933.20302-4-vadym.kochan@plvision.euSigned-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 5e180e6f
...@@ -455,6 +455,7 @@ static int eeprom_93xx46_probe(struct spi_device *spi) ...@@ -455,6 +455,7 @@ static int eeprom_93xx46_probe(struct spi_device *spi)
edev->pdata = pd; edev->pdata = pd;
edev->size = 128; edev->size = 128;
edev->nvmem_config.type = NVMEM_TYPE_EEPROM;
edev->nvmem_config.name = dev_name(&spi->dev); edev->nvmem_config.name = dev_name(&spi->dev);
edev->nvmem_config.dev = &spi->dev; edev->nvmem_config.dev = &spi->dev;
edev->nvmem_config.read_only = pd->flags & EE_READONLY; edev->nvmem_config.read_only = pd->flags & EE_READONLY;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment