I am working on Linux 3.14.28
, build with buildroot
for an embeded system.
How can I read the file /sys/devices/i2c.4/i2c-1/1-0052/eeprom
without root privilege?
Is there a solution to permanently change permission instead of changing it on each reboot of Linux with a script.
I'm not using udev
but static table
. I easily manage to change permission:
- using
device_table_dev.txt
for/dev
files - using
device_table.txt
for/home/files
But it has no effect on /sys/devices/i2c.4/i2c-1/1-0052/eeprom
First and foremost, don't use static table. It really doesn't make any sense to not use devtmpfs these days, unless you're using a kernel older than 2.6.32.
Then, the device table is about changing permission of files in /dev. The permission of files in /sys is directly controlled by the kernel itself.