[Linuxptp-users] clockid, uds as simple user
PTP IEEE 1588 stack for Linux
Brought to you by:
rcochran
From: Cyril B. <cyr...@gm...> - 2015-08-04 14:25:45
|
Hi, In my application, I need to know the status of the local PTP clock. So I opened a Unix domain socket to "/var/run/ptp4l" and asks for the magement messages. But this only works as root. Is there a way to make this, for simple user, for GET action ? I also need to get the clockid on /dev /ptp0. For now I use the macro #define CLOCKFD 3 #define FD_TO_CLOCKID (fd) ((~ (clockid_t) (fd) << 3) | CLOCKFD) but I can not get the file descriptor to /dev/ptp0 that as root. Can we make a clock_gettime() on /dev/ptp0 as simple user ? Perhaps with cabability ? Thank you |