On Mon, Nov 5, 2018 at 9:05 PM Paul Knox-Kennedy
<paul(a)the-kennedys.me.uk> wrote:
I have tried using a gpio group that my user is a member, and setting
/dev/gpiochip0 gid and pid to my non root user, and both result
in the same issue.
Maybe it could be an issue related to selinux?
This line is grabbed from journalctl on the base system:
Nov 06 22:17:32 arpi3 audit[5956]: AVC avc: denied { getattr } for
pid=5956 comm="ls" path="/dev/gpiochip0" dev="devtmpfs"
ino=12498
scontext=system_u:system_r:container_t:s0:c188,c581
tcontext=system_u:object_r:gpio_device_t:s0 tclass=chr_file
permissive=0
Adding --security-opt label=disable to podman, even if I don't
understand the effects, now the permission of /dev/gpiochip0 are:
crw-rw----. 1 nobody nobody 254, 0 Oct 29 00:29 /dev/gpiochip0
Btw, using gpiodetect I get
gpiodetect: unable to access GPIO chips: Permission denied
Of course, if in the base system I change the /dev/gpiochip0 to 666,
I'm able to query the device with gpiodetect.
Said that, I need to study podman a little more.
Ciao,
A.