Re: [PATCH v1] ptp: add PTP_MULTI_CLOCK_GET ioctl

From: Richard Cochran
Date: Wed Nov 22 2023 - 17:03:56 EST


On Wed, Nov 22, 2023 at 09:43:52AM +0200, Sagi Maimon wrote:

> @@ -226,6 +238,7 @@ struct ptp_pin_desc {
> _IOWR(PTP_CLK_MAGIC, 18, struct ptp_sys_offset_extended)
> #define PTP_MASK_CLEAR_ALL _IO(PTP_CLK_MAGIC, 19)
> #define PTP_MASK_EN_SINGLE _IOW(PTP_CLK_MAGIC, 20, unsigned int)
> +#define PTP_MULTI_CLOCK_GET _IOWR(PTP_CLK_MAGIC, 21, struct ptp_multi_clock_get)

I like the idea, but let's have it as a new system call.

The system call will accept a list of clockid_t.

That would allow getting CLOCK_MONOTONIC and PHC time stamps, for example.

Thanks,
Richard