lkml.org 
[lkml]   [2013]   [Jan]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
Subject[RFC] Creating an eeprom class
From
[plaintext and fixed address of David Brownell]

Hi,

Several of the eeprom drivers that live in drivers/misc/eeprom export
a binary sysfs file 'eeprom'. If a userspace program or script wants
to access this file, it needs to know the full path, for example:

/sys/bus/spi/devices/spi32766.0/eeprom

The problem with this approach is that it requires knowledge about the
hardware configuration: is the eeprom on the SPI bus, the I2C bus, or
maybe memory mapped?

It would therefore be more interesting to have a bus-agnostic way to
access this eeprom file, for example:
/sys/class/eeprom/eeprom0/eeprom

Maybe it'd be even better to use a more generic class name than
'eeprom', since there are several types of eeprom-like devices that
you could export this way.

Or should we rather hook the eeprom code into the mtd subsystem?

What is your opinion?

Thanks,
Thomas


\
 
 \ /
  Last update: 2013-01-20 19:41    [W:0.036 / U:0.660 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site