Sergey Bugaev, le dim. 27 oct. 2024 21:36:11 +0300, a ecrit:
> You'll also have to
> define _IOT_rtc_time in a C header (rtc.h) next to the struct rtc_time
> definition, using the _IOT macro.

Yes, definitely. Since struct rtc_time is merely 9 ints, that will be
easy.

> 2. just require the caller to have the device node opened for writing,
> and then rely on the Unix file access permissions mechanism to control
> who can do that (e.g. if it's owned by root and the mode is 0644, only
> root can open it for writing, but anyone can read).

That'll probably be simpler, yes.

Samuel

Reply via email to